Comment 0 for bug 1337009

Revision history for this message
Neal Holtz (nholtz-cee) wrote :

When a group with custom attributes, for example

   <g id=".." ice:class="damper-2.5d" ...>...</g>

is converted to a symbol, the custom attributes (in this case 'ice:class') are often
lost. It *appears* as though, if the transform on the <g> is "simple" (ie., just
a translation), a <use> is created with the same transform and the children
of the <g> are re-rooted in a new <symbol><g>...</g></symbol> in the <defs>
section. And the custom attributes are lost.

If the transform is more complex, the original 'g' with all custom attributes
and children is moved to the new <symbol> node and is replaced with
a <use> with no transform. In this case, the custom attributes are
retained as part of the symbol.

I think I would prefer the latter for all cases, but I really want all my
custom attributes kept, somewhere. Actually, now that I think
I bit harder, they do have to be retained on the symbol.

Note, in the above, 'ice' is a proper namespace, properly set in the svg file.