xmlgraphics-fop-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Baker1, Jeremy" <Jeremy.Bak...@defence.gov.au>
Subject sec unclas: Maximum coordinate size
Date Wed, 02 Jun 2004 05:33:09 GMT



I am attempting to print SVG maps to scale using FOP.  FOP uses Batik to
render SVG.  It appears that Batik cannot handle six digit coordinates.
Unfortunately these are common when dealing with maps using a Universal
Transvers Mercator projection.  For instance the y coordinate of a point is
its distance from either the North or South Pole in metres.
My questions are:
*	am I right in thinking that this limit exists in Batik as used by
FOP?
*	is there any way around it (short of recalculating all the SVG with
all coordinates reduced by a scale factor)?

I have copied some example FOP code below, followed by the embedded svg in a
format that is understandable by the ADOBE SVG viewer. Unless I am
miscalculating the file should produce a vertical line - which is what
happens in the ADOBE viewer, but in FOP the line does not show up.
First the FOP version
<?xml version="1.0" encoding="utf-8"?>
<fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format
<http://www.w3.org/1999/XSL/Format> " xmlns:svg="http://www.w3.org/2000/svg
<http://www.w3.org/2000/svg> " xmlns:xlink="http://www.w3.org/1999/xlink
<http://www.w3.org/1999/xlink> ">  
<fo:layout-master-set>   
<fo:simple-page-master master-name="simple"> 
<fo:region-body margin="0cm"/>    
		</fo:simple-page-master>  
</fo:layout-master-set>  
<fo:page-sequence master-reference="simple">    
<fo:flow flow-name="xsl-region-body"> 
<fo:block border-color="black" border-style="solid" border-width="thin">

<fo:instream-foreign-object width='25cm' height='20cm'>	

		<svg:svg width='25cm' height='20cm' viewBox='300000 100000
25000 20000' preserveAspectRatio="xMinYMin meet">	
<svg:g id='testGroup' style='stroke:black;fill:none;stroke-width:1'> 
				<svg:line x1='310000' x2='310000'
y1='-110000' y2='120000'/>
</svg:g>		
		</svg:svg>		
</fo:instream-foreign-object> 
</fo:block> 
</fo:flow> 
</fo:page-sequence>

</fo:root>

________________________________________________________

And now the same thing in straight SVG

_________________________________________________________

<svg width='25cm' height='20cm' viewBox='300000 100000 25000 20000'
preserveAspectRatio="xMinYMin meet">	
<g id='testGroup' style='stroke:black;fill:none;stroke-width:1'> 
<line x1='310000' x2='310000' y1='-110000' y2='120000'/>
		</g>
</svg>	

Thanks for any help


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-user-unsubscribe@xml.apache.org
For additional commands, e-mail: fop-user-help@xml.apache.org


Mime
View raw message