[newbie] using ElementTree, how to add doctype and xml pi
dave berk
dave.brk at gmail.com
Wed Mar 19 19:53:49 EDT 2008
Hi all
I have an svg file i'm creating on the fly. How do I add the doctype and xml
pi? They're not an element per se, and there is no function to add them. Am
I suppose to add them as elements after all?
I have something like this:
self.svgRoot = ET.Element("svg", xmlns=r'http://www.w3.org/2000/svg')
ET.SubElement(self.svgRoot, "g", transform="scale(1,-1)")
....
....
....
self.tree = ET.ElementTree(self.svgRoot)
...
thanks
dave
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20080320/53c5fb3d/attachment.html>
More information about the Python-list
mailing list