Hello,
I have created a very simple class that does some SVG manipulation using
batik and I believe I have found a problem with the DOMUtilities class. I
am loading an SVG file created with Corel Draw and then saving it back out.
The new SVG document is saved using the DOMUtilities.writeDocument()
method. The document that is output is "not well-formed". Here is the
code I am using to perform this operation. Please let me know if I am in
error somehow. I will continue to try and isolate the problem, however,
any help would be greatly appreciated. Also, I did not know if I should
include attachments, so I did not send the SVG file itself.
File svgFile = new File(SVG_FILE);
String svgURL = svgFile.toURL().toString();
SAXSVGDocumentFactory svgDocFactory = new
SAXSVGDocumentFactory(XML_PARSER);
SVGOMDocument svgDoc = svgDocFactory.createDocument(svgURL);
File tmpFile = File.createTempFile("edg-",".svg",new File(TMP_DIR));
FileWriter svgFileWriter = new FileWriter(tmpFile);
DOMUtilities.writeDocument(svgDoc,svgFileWriter);
svgFileWriter.close();
System.out.println("Saved svg file : " + tmpFile.toString());
Thank you,
Kendall Adkins
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]