[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

XSL-FO: Including SVG images

Subject: XSL-FO: Including SVG images
From: Antonio Fiol <fiol@xxxxxxxxxx>
Date: Fri, 05 Jul 2002 09:56:37 +0200
svg images

Hello,



I am using FOP, and I tried the following code to include a dynamically generated SVG image


<xsl:variable name="url">http://......svg...</xsl:variable>
<fo:block>
<fo:instream-foreign-object>
   <xsl:copy-of select="document($url)" />
</fo:instream-foreign-object>
</fo:block>

I thought that this was the "right way" of doing it, but...

What I get is a (square?) *portion* of my original SVG, with some texts and other objects missing (maybe those that would be cut by the right edge?). It looks odd...

With simple SVG code (not dynamically generated, and included directly in the XSL file), such as:

<fo:instream-foreign-object>
 <svg:svg width="400px" height="300px">
   <svg:desc>Graphique des performances de l'URL.
   </svg:desc>
   <svg:image x="0" y="0" width="400px" height="300px"
              xlink:href="http://host/some/image.png">
     <svg:title>My image</svg:title>
   </svg:image>
 </svg:svg>
</fo:instream-foreign-object>

it works great, unless the width and height in the svg element do not match those on the image element, in which case, my image is cropped, as expected.

However, I am not a SVG expert, and I do not fully understand the image I am including. I would like to learn SVG and solve the problem myself, sincerely, but that would take me way too long. (Yes, a lame excuse, I know.)

Does anyone see what my problem is without needing the SVG file?

Or is anyone willing that I send an example generated image to him/her for deeper study?

I know you are all very busy, but any help vould be greatly appreciated.

Thank you very much.


Antonio Fiol



XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list



Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.