Debian Codegraph @

test_non_regression/svg/text-tref-02-b.svg

raw
1 <!DOCTYPE svg [
2 <!ATTLIST bar id ID #REQUIRED>
3 ]>
4 <svg version="1.1" baseProfile="basic" id="svg-root"
5 width="100%" height="100%" viewBox="0 0 480 360"
6 xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
7 <!--======================================================================-->
8 <!--= SVG 1.1 2nd Edition Test Case =-->
9 <!--======================================================================-->
10 <!--= Copyright 2009 World Wide Web Consortium, (Massachusetts =-->
11 <!--= Institute of Technology, European Research Consortium for =-->
12 <!--= Informatics and Mathematics (ERCIM), Keio University). =-->
13 <!--= All Rights Reserved. =-->
14 <!--= See http://www.w3.org/Consortium/Legal/. =-->
15 <!--======================================================================-->
16 <d:SVGTestCase xmlns:d="http://www.w3.org/2000/02/svg/testsuite/description/"
17 template-version="1.4" reviewer="ED" author="CL" status="accepted"
18 version="$Revision: 1.5 $" testname="$RCSfile: text-tref-02-b.svg,v $">
19 <d:testDescription xmlns="http://www.w3.org/1999/xhtml" href="http://www.w3.org/TR/SVG11/text.html#TRefElement">
20 <p>
21 Test viewer capability to handle 'tref' elements
22 which point to text strings outside the current SVG document fragment.
23 </p>
24 <p>
25 The test case consists of two sub-tests; one results in the word "Hello" and the second, the word "World".
26 </p>
27 </d:testDescription>
28 <d:operatorScript xmlns="http://www.w3.org/1999/xhtml">
29 <p>
30 Run the test. No interaction required.
31 </p>
32 </d:operatorScript>
33 <d:passCriteria xmlns="http://www.w3.org/1999/xhtml">
34 <p>
35 The test is passed if the phrase "Hello World" is displayed, in green.
36 </p>
37 </d:passCriteria>
38 </d:SVGTestCase>
39 <title id="test-title">$RCSfile: text-tref-02-b.svg,v $</title>
40 <defs>
41 <font-face font-family="SVGFreeSansASCII" unicode-range="U+0-7F">
42 <font-face-src>
43 <font-face-uri xlink:href="../resources/SVGFreeSans.svg#ascii"/>
44 </font-face-src>
45 </font-face>
46 </defs>
47 <g id="test-body-content" font-family="SVGFreeSansASCII,sans-serif" font-size="18">
48 <!-- Test case label -->
49 <text x="75" y="25" font-family="SVGFreeSansASCII,sans-serif" font-size="12" fill="blue">Test 'tref' element pointing outside the SVG document fragment.</text>
50
51 <text x="75" y="200" font-size="36" font-family="SVGFreeSansASCII,sans-serif" fill="green">
52 <tref xlink:href="#hello"/>
53 <tref xlink:href="#world"/>
54 </text>
55 <!-- now make a new SVG document fragment, and hide it from being rendered -->
56 <defs>
57 <foreignObject>
58 <svg>
59 <text id="hello">Hello</text>
60 </svg>
61 </foreignObject>
62 </defs>
63 <!-- and another way to make a separate document fragment -->
64 <foo xmlns="http://example.org/foo">
65 <bar id="world">World</bar>
66 </foo>
67
68 </g>
69 <g font-family="SVGFreeSansASCII,sans-serif" font-size="32">
70 <text id="revision" x="10" y="340" stroke="none" fill="black">$Revision: 1.5 $</text>
71 </g>
72 <rect id="test-frame" x="1" y="1" width="478" height="358" fill="none" stroke="#000000"/>
73 <!-- comment out this watermark once the test is approved -->
74 <!--<g id="draft-watermark">
75 <rect x="1" y="1" width="478" height="20" fill="red" stroke="black" stroke-width="1"/>
76 <text font-family="SVGFreeSansASCII,sans-serif" font-weight="bold" font-size="20" x="240"
77 text-anchor="middle" y="18" stroke-width="0.5" stroke="black" fill="white">DRAFT</text>
78 </g>-->
79 </svg>