Hi, Wade,

When you added new elements or attributes with different name space to
the file, did you use internal DTD to extend SVG DTD? The SVG
specification states it can be done with internal DTD. But I might have
to extend it quite a lot and I do not want to give a big internal
repetitive DTD to each file. Is there a way to do it with external DTD?

Thanks.

Weiming

On Fri, 2003-10-31 at 11:09, [EMAIL PROTECTED] wrote:
> The way I did this on a similar project was to put the
> new elements and attributes in a different namespace.
> 
> Batik does not try to render those elements, but it does
> make them available through the DOM.
> 
> G. Wade
> 
> Weiming Zhang wrote:
> > Hi,
> > 
> > Thank you very much.
> > 
> >>>Is it possible to rendering such svg content with Batik? 
> >>
> >>    Yes, and no.  There are some issues with the above example,
> >>like Batik requires an SVGDocument with a 'getRoot' method that
> >>returns the 'root' SVG element.  So you might be able to write a
> >>'hacked' document object that 'behaved' correctly however...
> > 
> > I tried the sample from SVG specification but it did not work. You are
> > right, it has to have svg element as root for batik rendering.
> > 
> > 
> >>>I want to use
> >>>some custom XML tags to add some extra information to the document. For
> >>>example, I may specify for certain group of graphic shapes, there are
> >>>certain callbacks. Those callbacks will be specified as either elements
> >>>or attributes. 
> >>
> >>    This makes me think that you may want (or at least get away with)
> >>something that looks more like:
> >>
> >>      <svg:svg width="4cm" height="8cm" version="1.1"
> >>          xmlns="http://example.org";
> >>         xmlns:svg="http://www.w3.org/2000/svg";>
> >>        <svg:ellipse cx="2cm" cy="4cm" rx="2cm" ry="1cm">
> >>      <callback-list>
> >>         <!-- callbacks for the ellipse element -->
> >>         <callback name="foo" function="bar"/>
> >>      </callback-list>
> >>        </svg:ellipse>
> >>     </svg:svg>
> >>
> >>    This will work trivially "right out of the box".
> > 
> > This indeed works! But the callback related elements are not in SVG DTD,
> > so batik does not validate the document? If I make a DTD or schema by
> > adding some extra information to SVG DTD (is it possible to do
> > inheritance with a DTD?), how can I let batik know?
> > 
> > Thanks.
> > 
> > wz
> > 
> > 
> > 
> > 
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> > 
> > 
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to