[EMAIL PROTECTED] wrote:
I did not realise that the DTD would be read by a non validating parser.
I did not include a DOCTYPE in my svg so it seems that the
SAXSVGDocumentFactory is including a DTD for me which was another suprise.
Actually, the Batik SVG DOM implementation is providing the default
attribute values. If you use a generic DOM (without a DTD) the info
set will probably be untouched, of course then the document isn't
renderable.
I just wanted to cut down on the file size, looks like I'm going to have
to live with it.
I suppose someone could write a filter that stripped default
attribute values but we have not done that.
-----Original Message-----
From: Thomas DeWeese [mailto:[EMAIL PROTECTED]
Sent: 01 December 2003 14:26
To: Batik Users
Subject: Re: Document bloat
[EMAIL PROTECTED] wrote:
>
>
> Does anybody know what is going on here?
All of these are all defined by the SVG specification. These
are the default values (or fixed values) defined by the DTD.
> I am using SAXSVGDocumentFactory ( initialised with Xerces SAX Parser )
> to load svg file.
>
> SVGDocument doc = fac.createSVGDocument(fileuri);
>
>
> After loading the doc I find that for example
> <svg x="0" y="0">
>
>
> has become
>
> <svg x="0" contentScriptType="text/ecmascript" y="0"
> xmlns:xlink="http://www.w3.org/1999/xlink" zoomAndPan="magnify"
> contentStyleType="text/css" preserveAspectRatio="xMidYMid meet"
> xmlns="http://www.w3.org/2000/svg" version="1.0">
>
> I have these namespaces defined in my outer svg.
> xmlns="http://www.w3.org/2000/svg"
> xmlns:common="http://exslt.org/common"
> xmlns:fo="http://www.w3.org/1999/XSL/Format"
> xmlns:svg="http://www.w3.org/2000/svg"
> xmlns:xalan="http://xml.apache.org"
> xmlns:xlink="http://www.w3.org/1999/xlink">
>
>
> Every element has the same set of extra attributes.
>
> When I save the document again if find that its size has increased
greatly.
>
> Is there a way to stop this behaviour ?
>
> Thanks,
>
> Patrick Egan
>
>
> _____________________________________________________________________
> This e-mail has been scanned for viruses by MCI's Internet Managed
> Scanning Services - powered by MessageLabs. For further information
> visit http://www.mci.com
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
_____________________________________________________________________
This e-mail has been scanned for viruses by MCI's Internet Managed
Scanning Services - powered by MessageLabs. For further information
visit http://www.mci.com
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]