Debian Codegraph @

test_non_regression/svg/color-prop-01-b.svg

raw
1 <svg version="1.1" baseProfile="basic" 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.8 $" testname="$RCSfile: color-prop-01-b.svg,v $">
16 <d:testDescription xmlns="http://www.w3.org/1999/xhtml" href="http://www.w3.org/TR/SVG11/color.html#ColorProperty">
17 <p>
18 This tests the 'color' property and the 'currentColor' value on fill, stroke, and stop-color properties.
19 </p>
20 </d:testDescription>
21 <d:operatorScript xmlns="http://www.w3.org/1999/xhtml">
22 <p>
23 Run the test. No interaction required.
24 </p>
25
26 </d:operatorScript>
27 <d:passCriteria xmlns="http://www.w3.org/1999/xhtml">
28 <p>
29 There are three subtests. The first subtest, to the top left, is passed if the circle has a green fill. The second subtest,
30 to the top right, is passed if the circle has a green stroke. The third subtest shows a rectangle
31 with a gradient fill, which has three stops. The subtest is passed if central stop is green,
32 fading off to blue to the left and pale yellow to the right.
33 </p>
34 </d:passCriteria>
35 </d:SVGTestCase>
36 <title id="test-title">$RCSfile: color-prop-01-b.svg,v $</title>
37 <defs>
38 <font-face font-family="SVGFreeSansASCII" unicode-range="U+0-7F">
39 <font-face-src>
40 <font-face-uri xlink:href="../resources/SVGFreeSans.svg#ascii"/>
41 </font-face-src>
42 </font-face>
43 </defs>
44 <g id="test-body-content" font-family="SVGFreeSansASCII,sans-serif" font-size="18">
45 <defs>
46 <linearGradient id="grad" color="green">
47 <stop offset="5%" stop-color="#60F"/>
48 <stop offset="50%" stop-color="currentColor"/>
49 <stop offset="95%" stop-color="#FF6"/>
50 </linearGradient>
51 </defs>
52 <g color="green">
53 <g color="inherit" fill="none" stroke="none">
54 <!-- inherit to check the property value, not the string, is being used -->
55 <circle cx="130" cy="80" r="60" fill="currentColor"/>
56 <circle cx="350" cy="80" r="60" stroke="currentColor" stroke-width="4"/>
57 </g>
58 </g>
59 <g color="blue">
60 <g color="inherit" fill="none" stroke="none">
61 <!-- blue color used to check color being scoped and inherited correctly -->
62 <rect x="60" y="215" width="360" height="80" fill="url(#grad)"/>
63 </g>
64 </g>
65 <g font-size="30" fill="black">
66 <text x="120" y="170">fill</text>
67 <text x="310" y="170">stroke</text>
68 <text x="180" y="205">stop-color</text>
69 </g>
70 </g>
71 <g font-family="SVGFreeSansASCII,sans-serif" font-size="32">
72 <text id="revision" x="10" y="340" stroke="none" fill="black">$Revision: 1.8 $</text>
73 </g>
74 <rect id="test-frame" x="1" y="1" width="478" height="358" fill="none" stroke="#000000"/>
75 <!-- comment out this watermark once the test is approved -->
76 <!--<g id="draft-watermark">
77 <rect x="1" y="1" width="478" height="20" fill="red" stroke="black" stroke-width="1"/>
78 <text font-family="SVGFreeSansASCII,sans-serif" font-weight="bold" font-size="20" x="240"
79 text-anchor="middle" y="18" stroke-width="0.5" stroke="black" fill="white">DRAFT</text>
80 </g>-->
81 </svg>