Displaying elements with gradients in on-the-fly build SVGDocument
Maciej Dybał <[email protected]>
| Newsgroups | gmane.text.xml.batik.user |
|---|---|
| Message-ID | <[email protected]> |
Hello!
As this it my first post to this mailing list I would like to welcome
everyone!
I have a problem with properly displaying a SVGDocument (build
on-the-fly) in JSVGCanvas and I would really appreciate some guidance.
I use Java 1.6 on Windows XP. In my app I store SVGConfiguration as a
CLOB in database. In the runtime I get the String from database, create
a SVGDocument and display it on JSVGCanvas. This works fine until I have
some gradients defined in <defs> node. In this case no exception is
thrown but the elements using gradients are not drawn at all.
I tried to find some soultion on the web and in the mailing-list archive
but came out empty-handed. Setting a xml:base with following code did
not help:
URL baseURL = new URL(new java.io.File("").toURL().toExternalForm());
String url = baseURL.toString();
((SVGOMDocument)doc).setURLObject(baseURL);
Neither did adding this URL to <defs> subnodes.
The SVG file I use is attached to this mail (hope attachments are allowed)
Best regards,
Maciek
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
circle.svg
(image/svg+xml, 5.7 KB) - not displayed