W3C home > Mailing lists > Public > www-svg@w3.org > August 2002

<use> element and inheritance

From: Sigurd Lerstad <sigler@bredband.no>
Date: Wed, 7 Aug 2002 17:35:35 -0700
Message-ID: <007f01c23e73$82eac3e0$481273d5@mmstudioproj>
To: <www-svg@w3.org>

Hello,

From the SVG spec

5.6 The 'use' element

<...>
Property inheritance, however, works as if the referenced element had been
textually included as a deeply cloned child of the 'use' element. The
referenced element inherits properties from the 'use' element and the 'use'
element's ancestors. An instance of a referenced element does not inherit
properties from the referenced element's original parents.
<...>

<...>
The behavior of the 'visibility' property conforms to this model of property
inheritance. Thus, specifying 'visibility:hidden' on a 'use' element does
not guarantee that the referenced content will not be rendered. If the 'use'
element specifies 'visibility:hidden' and the element it references
specifies 'visibility:hidden' or 'visibility:inherit', then that one element
will be hidden. However, if the referenced element instead specifies
'visibility:visible', then that element will be visible even if the 'use'
element specifies 'visibility:hidden'.
<...>
------------

I don't get the second paragraph...

Why will the use element not always be invisible if it has
'visibility:hidden'? Since property inheritance works as if the referenced
element had been textually included as a deeply cloned CHILD of the 'use'
element.. ?


thanks,

--
Sigurd Lerstad
Received on Wednesday, 7 August 2002 11:33:54 GMT

This archive was generated by hypermail 2.3.1 : Friday, 8 March 2013 15:54:23 GMT