Hi Helder,

> Could you provide some more information like the specific Batik
> revision number, Java version and operating system (at a minimum)? A
> reduced test case would  be great! ;-)

[JCT] Sure.  I have just created a fresh folder with the latest SVN build
(revision 772099) so all my local customisations have been blown away.  I am
now using only the SVN source and libraries.  I have tried this build with
Java 6 versions Update 13 and Update 14 (b05) with the same results.  The OS
is Windows Vista.

A "reduced" test case is to simply open an SVG file that contains nothing
more than this: "<svg></svg>".  It used to work but without the "!DOCTYPE"
line it doesn't work anymore.
 
> Works for me. This is pretty weird, so some loose thoughts follow:
>  * Those "at com.sun.org.apache.xerces" suggests you've left Apache
> Xerces out of the class path. Xerces is apparently also shipped with
> older Java versions (although apparently an ancient version of Xerces).
> A related thing was already raised in a previous thread [1];

[JCT] This is a good point.  I was using the internal Xalan and Xerces
packages included with the JRE in order to minimise the overall JAR size for
use in an applet.  However, as I said, I have now reverted to the default
use of these libraries in the latest SVN source and I now get the exception:

org.apache.batik.dom.util.SAXIOException: Document is invalid: no grammar
found.
        at
org.apache.batik.dom.util.SAXDocumentFactory.createDocument(SAXDocumentFacto
ry.java:445)
        at
org.apache.batik.dom.util.SAXDocumentFactory.createDocument(SAXDocumentFacto
ry.java:357)
        at
org.apache.batik.dom.svg.SAXSVGDocumentFactory.createDocument(SAXSVGDocument
Factory.java:201)
        at
org.apache.batik.dom.svg.SAXSVGDocumentFactory.createSVGDocument(SAXSVGDocum
entFactory.java:124)
        at
org.apache.batik.bridge.DocumentLoader.loadDocument(DocumentLoader.java:106)
        at
org.apache.batik.swing.svg.SVGDocumentLoader.run(SVGDocumentLoader.java:84)
Caused by: org.xml.sax.SAXParseException: Document is invalid: no grammar
found.
        at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
        at
org.apache.batik.dom.util.SAXDocumentFactory.createDocument(SAXDocumentFacto
ry.java:439)
        ... 5 more

>  * Have you tried validating the source using the W3C validator? It has
> been (somehow recently [2]) updated and should be a lot better now.

[JCT] No, I haven't tried this.

>  * Are you including an XML preamble? Though I've tested and shouldn't
> make a difference, maybe using non ANSI encodings within the document
> could suggest something as the above);

[JCT] My test case is above.  There is no XML preamble and there never used
to be a requirement for one.

> Although quite off-topic, while in the midst of experiments in order to
> clear up for a possible interaction with SVG version property, I've
> noticed that setting version to "1.2" (attaching a modified version of
> "gradients.svg" of Batik samples) seems to cause clip paths not to be
> applied as expected (note the behavior of radial gradient near the
> bottom versus the original version). Was it some change in the
> specification or did something slip through my mind? I've used Squiggle
> from revision 772054 on Java 1.6 update 12 (Windows Vista
> SP1) for this test. This seems to be in need of further
> investigation...

[JCT] Sorry but I have no knowledge on this matter.

Thanks,

John


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to