<use> with referenced <svg> must set width/height properties

Bug #568833 reported by Mo DeJong
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Inkscape
Confirmed
Undecided
Unassigned

Bug Description

In 5.6 of the SVG spec, the use element is described as:

If the 'use' element references a 'symbol' element:

The referenced 'symbol' and its contents are deep-cloned into the generated tree, with the exception that the 'symbol' is replaced by an 'svg'. This generated 'svg' will always have explicit values for attributes width and height.

Inkscape handles this logic correctly for a referenced <symbol> but, the the case where a <use> references a <svg> node Inkscape needs to explicitly set the width and height properties instead of using the values defined on the linked XML node. The attached example shows the symbol example and the broken svg example along with what the output should look like.

Tags: svg symbols
Revision history for this message
Mo DeJong (mosesdejong) wrote :
Revision history for this message
Mo DeJong (mosesdejong) wrote :

Ack, sorry, I quoted the wrong part of 5.6. Here is the correct bit:

If the 'use' element references an 'svg' element:

If attributes width and/or height are provided on the 'use' element, then these values will override the corresponding attributes on the 'svg' in the generated tree.

su_v (suv-lp)
tags: added: svg
Martin Owens (doctormo)
Changed in inkscape:
status: New → Confirmed
tags: added: symbols
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.