W3C home > Mailing lists > Public > svg-testsuite-comments@w3.org > July 2002

SVG Conformance Test - gradPatt-referenc-BE-08

From: Alan Pate <pate@ellipsys.com>
Date: Thu, 11 Jul 2002 14:36:33 -0500
To: <svg-testsuite-comments@w3.org>
Message-ID: <HNEMLFMAGLICDALNJCPPAEPPCKAA.pate@ellipsys.com>


Regarding SVG Conformance Test - gradPatt-referenc-BE-08, which is meant to
test the xlink:href attribute of patterns gradients, the SVG 1.0
specification says:

Any attributes which are defined on the referenced element which are not
defined on this element are inherited by this element. If this element has
no children, and the referenced element does (possibly due to its own href
attribute), then this element inherits the children from the referenced
element. Inheritance can be indirect to an arbitrary level; thus, if the
referenced element inherits attributes or children due to its own href
attribute, then the current element can inherit those attributes or
children.

This test should include color, stroke, and fill attributes in the
referencing element, which should be applied to any children in the
referenced element.  I found this problem in the Adobe viewer which
otherwise passes this test.

Example:

		<pattern id="Pat3a" x="0" y="0" width="20" height="20"
patternUnits="userSpaceOnUse" color="purple">
			<rect x="0" y="0" width="10" height="10" fill="currentColor" />
			<rect x="10" y="0" width="10" height="10" fill="green" />
			<rect x="0" y="10" width="10" height="10" fill="blue" />
			<rect x="10" y="10" width="10" height="10" fill="yellow" />
		</pattern>
		<pattern id="Pat3b" xlink:href="#Pat3a" width="20" height="20"
color="red"/>

Pattern Pat3a sets the color attribute to purple, which is used by the first
rect.
Pattern Pat3b sets the color attribute to red, which should be used by the
first rect in the 2nd pattern (but is not in Adobe's viewer).

Regards,
Alan Pate
Received on Thursday, 11 July 2002 15:37:01 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 8 January 2008 14:25:01 GMT