| 1 |
<svg version="1.1" baseProfile="tiny" id="svg-root" |
| 2 |
width="100%" height="100%" viewBox="0 0 480 360" |
| 3 |
xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"> |
| 4 |
<!--======================================================================--> |
| 5 |
<!--= SVG 1.1 2nd Edition Test Case =--> |
| 6 |
<!--======================================================================--> |
| 7 |
<!--= Copyright 2009 World Wide Web Consortium, (Massachusetts =--> |
| 8 |
<!--= Institute of Technology, European Research Consortium for =--> |
| 9 |
<!--= Informatics and Mathematics (ERCIM), Keio University). =--> |
| 10 |
<!--= All Rights Reserved. =--> |
| 11 |
<!--= See http://www.w3.org/Consortium/Legal/. =--> |
| 12 |
<!--======================================================================--> |
| 13 |
<d:SVGTestCase xmlns:d="http://www.w3.org/2000/02/svg/testsuite/description/" |
| 14 |
template-version="1.4" reviewer="SVGWG" author="Chris Lilley" status="accepted" |
| 15 |
version="$Revision: 1.5 $" testname="$RCSfile: styling-inherit-01-b.svg,v $"> |
| 16 |
<d:testDescription xmlns="http://www.w3.org/1999/xhtml" href="http://www.w3.org/TR/SVG11/styling.html#Inheritance"> |
| 17 |
<p> |
| 18 |
Verify property inheritance as required by 6.15 "Property |
| 19 |
inheritance". Since all implementations are required to do this, only |
| 20 |
presentation attributes are used. |
| 21 |
</p> |
| 22 |
</d:testDescription> |
| 23 |
<d:operatorScript xmlns="http://www.w3.org/1999/xhtml"> |
| 24 |
<p> |
| 25 |
Run the test. No interaction required. |
| 26 |
</p> |
| 27 |
</d:operatorScript> |
| 28 |
<d:passCriteria xmlns="http://www.w3.org/1999/xhtml"> |
| 29 |
<p> |
| 30 |
At the center right, there is an ellipse. The fill color is not |
| 31 |
specified on that element but on its parent. The ellipse should be filled a solid yellow |
| 32 |
</p> |
| 33 |
<p> |
| 34 |
At the top left, an oval shape is formed from a rectangle |
| 35 |
with a radial gradient. The color of the middle stop uses the keyword 'inherit' |
| 36 |
and thus takes its parent's value of green, giving a yellow, green, white gradient. |
| 37 |
</p> |
| 38 |
<p> |
| 39 |
At the bottom left, an oval shape is formed from a rectangle |
| 40 |
with a radial gradient. The color of the middle stop uses the value 'currentColor' |
| 41 |
and thus takes the value its parent's color property, a dark red, |
| 42 |
giving a yellow, dark red, white gradient. |
| 43 |
</p> |
| 44 |
</d:passCriteria> |
| 45 |
</d:SVGTestCase> |
| 46 |
<title id="test-title">$RCSfile: styling-inherit-01-b.svg,v $</title> |
| 47 |
<defs> |
| 48 |
<font-face font-family="SVGFreeSansASCII" unicode-range="U+0-7F"> |
| 49 |
<font-face-src> |
| 50 |
<font-face-uri xlink:href="../resources/SVGFreeSans.svg#ascii"/> |
| 51 |
</font-face-src> |
| 52 |
</font-face> |
| 53 |
</defs> |
| 54 |
<g id="test-body-content" font-family="SVGFreeSansASCII,sans-serif" font-size="18"> |
| 55 |
<g fill="yellow"> |
| 56 |
<g stroke="#555"> |
| 57 |
<ellipse rx="90" ry="60" cx="330" cy="140"/> |
| 58 |
</g> |
| 59 |
</g> |
| 60 |
<radialGradient id="ygw" stop-color="green"> |
| 61 |
<stop offset="0%" stop-color="yellow"/> |
| 62 |
<stop offset="50%" stop-color="inherit"/> |
| 63 |
<stop offset="100%" stop-color="white"/> |
| 64 |
</radialGradient> |
| 65 |
<rect width="180" height="120" x="40" y="20" stroke="none" fill="url(#ygw)"/> |
| 66 |
<radialGradient id="yrw" color="#700"> |
| 67 |
<stop offset="0%" stop-color="yellow"/> |
| 68 |
<stop offset="50%" stop-color="currentColor"/> |
| 69 |
<stop offset="100%" stop-color="white"/> |
| 70 |
</radialGradient> |
| 71 |
<rect width="180" height="120" x="40" y="160" stroke="none" fill="url(#yrw)"/> |
| 72 |
</g> |
| 73 |
<g font-family="SVGFreeSansASCII,sans-serif" font-size="32"> |
| 74 |
<text id="revision" x="10" y="340" stroke="none" fill="black">$Revision: 1.5 $</text> |
| 75 |
</g> |
| 76 |
<rect id="test-frame" x="1" y="1" width="478" height="358" fill="none" stroke="#000000"/> |
| 77 |
<!-- comment out this watermark once the test is approved --> |
| 78 |
<!--<g id="draft-watermark"> |
| 79 |
<rect x="1" y="1" width="478" height="20" fill="red" stroke="black" stroke-width="1"/> |
| 80 |
<text font-family="SVGFreeSansASCII,sans-serif" font-weight="bold" font-size="20" x="240" |
| 81 |
text-anchor="middle" y="18" stroke-width="0.5" stroke="black" fill="white">DRAFT</text> |
| 82 |
</g>--> |
| 83 |
</svg> |