xmlgraphics-batik-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bishop, Michael W. CONTR J9C880" <michael.bishop....@jfcom.mil>
Subject RE: Rendering transform on refresh?
Date Thu, 13 Nov 2008 18:48:07 GMT
No, that was some kind of posting anomaly...let me see if I can post it without the xmlns declarations.
<svg contentScriptType="text/ecmascript" zoomAndPan="magnify" contentStyleType="text/css"
version="1.0" width="640" fill="none" preserveAspectRatio="xMidYMid meet" viewBox="0 0 640
480" height="480"><rect x="-1000%" y="-1000%" fill="white" width="3000%" height="3000%"/></svg>
There, no http problem to mess up the post.
getCTM() doesn't change it.  I think the problem is how I derive my original coordinates.
 Given the above document, I would expect my SVGRect to be 0, 0, 640, 480.  Instead, the percentages
applied to the background rectangle get factored in (based on the log output in my first post).
 If the "starting" document coordinates aren't right, the transformed coordinates wouldn't
be right either.  That's why I think the viewBox somehow needs to be taken into account and
possibly the rendering transform.  By default (i.e., no size preferences set on the JSVGCanvas),
the JSVGCanvas shows this 640x480 document in a (approximately) 200x200 window.


From: Helder Magalhães [mailto:helder.magalhaes@gmail.com]
Sent: Thu 11/13/2008 1:33 PM
To: batik-users@xmlgraphics.apache.org
Subject: Re: Rendering transform on refresh?

> Here's a snippet SVG:
> <rect <http:// <http:///> ><rect>  x="-1000%" y="-1000%" fill="white"
width="3000%" height="3000%"/>

Is the "http:// <http:///> " a new SVG element or did the snippet suffered some
weird transform...? ;-)

> Pushing those through the screenCTM matrix doesn't give me the proper window coordinates
where I "see" the document on the canvas. > I want the coordinates of the document in window
space.  What am I missing?

Are you reffering to "getCTM"?

Hope this helps,

 Helder Magalhães

To unsubscribe, e-mail: batik-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: batik-users-help@xmlgraphics.apache.org

View raw message