Hi!So it appears that the problem is when it is parsing the User Agent Style Sheet.
I have a problem. I am not so sure if it resides in Batic or not...
Ok here the description
I have an application which constructs an svg and Displayes it using Batik. This works fine when using my IDE (Eclipse).
When I use the maven uberjar plugin to create a distribution (copys the dependent batik jars together with my application jar in one jar) my application still generates the same svg file, but the display gets the following error.
java.lang.NullPointerException
at org.apache.batik.css.engine.CSSEngine.parseStyleSheet(Unknown Source)
at org.apache.batik.dom.svg.SVGDOMImplementation.createCSSEngine(Unknown Source)
at org.apache.batik.bridge.BridgeContext.initializeDocument(Unknown Source)
at org.apache.batik.bridge.GVTBuilder.build(Unknown Source)
at org.apache.batik.swing.svg.GVTTreeBuilder.run(Unknown Source)
My thought is that it might be because I jave the batic jars now residing in an other jar. Has anybody experienced something similar?
However I think the problem is really lower down than is indicated and the NPE is
caused when Batik tries to build the SyntaxError message because your
document is from a stream and it has no documentURI ( see line 940 in
CSSEngine.java). You might try replacing 'documentURI.toString()' with:
(documentURI == null)?"<document stream>":documentURI.toString()
And see if you get a better message (you might also stick a ' e.printStackTrace()'
in the catch to see the real 'source' of the problem).
Thanks for your help
Ralf
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
