xmlgraphics-fop-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "George, Sobha" <sobha.geo...@jnli.com>
Subject RE: SVG include in FOP
Date Sat, 07 Sep 2002 17:55:30 GMT
Thank you, I moved the reference to xsl:stylesheet and it does work. Thank
you very much for your help!

Now my question is does this actually help me in avoiding "Out of Memory"
exception. I was using <fo:external-graphic ...> and read that since
external graphics are cached in memory it is suggested to use
<fo:instream-foreign-object....>. It turned out that I was able to process
12 records in the first case <fo:external-graphic ...> and only 9 records
with <fo:instream-foreign-object....>

Am I using it in the intended way?

-----Original Message-----
From: J.Pietschmann [mailto:j3322ptm@yahoo.de]
Sent: Saturday, September 07, 2002 1:47 PM
To: fop-user@xml.apache.org
Subject: Re: SVG include in FOP

George, Sobha wrote:
> Hi,
> I am trying to include an image in the PDF file. The image is retrieved
> http request.
> <?xml version="1.0" encoding="UTF-8"?>
> <xsl:stylesheet version="1.0"
> xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
> xmlns:fo="http://www.w3.org/1999/XSL/Format">
> <fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format"
> xmlns:xlink="http://www.w3.org/1999/xlink">
> .......
> <fo:instream-foreign-object>
> 	<svg xmlns="http://www.w3.org/2000/svg" width="60" height="40"
> xml:space="preserve">
> 		<g style="fill:none;stroke:yellow">
> 			<image
> .setcategories()@_SVG" x="10" y="10" width="20" height="20"/>
> 		</g>
> 	</svg>
> </fo:instream-foreign-object>
> ........
> </fo:root>
> </xsl:stylesheet>
> This always gives me the error message that says "the prefix 'xlink' for
> attribute 'xlink:href' is not bound". Can somebody help me figure out what
> am doing wrong here....

Perhaps you have something like this:
   <xsl:template match...>
     <fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format"

   <xsl:template match...>
       <svg xmlns="http://www.w3.org/2000/svg" wid...>
          <g style="fill:none;stroke:yellow">
            <image xlink:href="http://localh...

The scope for the xlink prefix binding is restricted to the
fo:root in the first template, the binding is out of scope
for the second xsl:template with the embedded SVG.
Either move the xmlns:xlink to the xsl:stylesheet element,
or to the svg element, or perhaps even to the image element


View raw message