Mercurial > MadButterfly
changeset 1394:4a786de1d62f
Prevent the inkscape:bbox-* from duplicated. This will crash the libxml parser.
author | wycc |
---|---|
date | Wed, 30 Mar 2011 22:24:52 +0800 |
parents | 2d56ed5b0995 |
children | a768d74e5f49 |
files | pyink/mbbbox.py |
diffstat | 1 files changed, 4 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/pyink/mbbbox.py Wed Mar 30 13:42:30 2011 +0800 +++ b/pyink/mbbbox.py Wed Mar 30 22:24:52 2011 +0800 @@ -12,6 +12,8 @@ attrs = [] for attrname in node.allAttributes(): attrvalue = node.getAttribute(attrname) + if attrname[0:13] == 'inkscape:bbox': + continue attr = '%s="%s"' % (attrname, attrvalue) attrs.append(attr) pass @@ -56,6 +58,8 @@ attrs = [] for attrname in node.allAttributes(): + if attrname[0:13] == 'inkscape:bbox': + continue attrvalue = node.getAttribute(attrname) attr = '%s="%s"' % (attrname, attrvalue) attrs.append(attr)