Page 1 of 1

Glib error with duplicate attributes in SVG (6.3.2)

Posted: 2012-01-12T15:55:52-07:00
by zgardner
When trying to convert SVG that contains a tag with duplicate attributes, convert is throwing Glib errors about parsing XML data. It's possible that the SVG we're trying to convert isn't valid (coming from an IE innerHTML), but this should be simple to handle.

Try converting the following:

works.svg
<svg xmlns="http://www.w3.org/2000/svg" version="1.1" width="1678" height="853" id="ext-gen1227" style="width: 1678px; height: 853px; "></svg>

doesnt_work.svg
<svg xmlns="http://www.w3.org/2000/svg" version="1.1" width="1678" height="853" id="ext-gen1227" style="width: 1678px; height: 853px; " xmlns="http://www.w3.org/2000/svg" ></svg>


You'll notice that the SVG tag in the second example has two xmlns attributes with the same value. I'm not sure if it's our older version or if IE is wrong, but removing that second xmlns allowed convert to work.

Re: Glib error with duplicate attributes in SVG (6.3.2)

Posted: 2012-01-20T07:13:30-07:00
by Gargantuan
I had this glitch. Thanx, now I solved it)