Debian Codegraph @

test_non_regression/svg/text-align-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="Jon Ferraiolo" status="accepted"
15 version="$Revision: 1.8 $" testname="$RCSfile: text-align-01-b.svg,v $">
16 <d:testDescription xmlns="http://www.w3.org/1999/xhtml" href="http://www.w3.org/TR/SVG11/text.html#AlignmentProperties">
17 <p>
18 Test 'text-anchor' property (horizontal).
19 </p>
20 <p>
21 The three lines test the three values for property 'text-anchor': start, middle and end.
22 </p>
23 </d:testDescription>
24 <d:operatorScript xmlns="http://www.w3.org/1999/xhtml">
25 <p>
26 Run the test. No interaction required.
27 </p>
28 </d:operatorScript>
29 <d:passCriteria xmlns="http://www.w3.org/1999/xhtml">
30 <p>
31 The lines in pink, 'text-anchor:none' and 'text-anchor:start', should both start from the same horizontal position (indicated by the black circle on each line) and extend to the right.
32 The green line, 'text-anchor:middle', should be centered horizontally around the black circle.
33 The blue line, 'text-anchor:end', should be aligned such that the end of the text meets the black circle.
34 </p>
35 </d:passCriteria>
36 </d:SVGTestCase>
37 <title id="test-title">$RCSfile: text-align-01-b.svg,v $</title>
38 <defs>
39 <font-face font-family="SVGFreeSansASCII" unicode-range="U+0-7F">
40 <font-face-src>
41 <font-face-uri xlink:href="../resources/SVGFreeSans.svg#ascii"/>
42 </font-face-src>
43 </font-face>
44 </defs>
45 <g id="test-body-content" font-family="SVGFreeSansASCII,sans-serif" font-size="18">
46 <text font-size="34" x="5" y="40">Test 'text-anchor' (horizontal)</text>
47 <g id="text-anchor" font-size="14">
48 <g transform="translate(230,130)">
49 <line stroke="black" x2="50"/>
50 <circle r="3"/>
51 <text font-size="30" fill="fuchsia">text-anchor:none</text>
52 </g>
53 <g transform="translate(230,180)">
54 <line stroke="black" x2="50"/>
55 <circle r="3"/>
56 <text font-size="30" text-anchor="start" fill="fuchsia">text-anchor:start</text>
57 </g>
58 <g transform="translate(230,230)">
59 <line stroke="black" x1="-25" x2="25"/>
60 <circle r="3"/>
61 <text font-size="30" text-anchor="middle" fill="green">text-anchor:middle</text>
62 </g>
63 <g transform="translate(230,280)">
64 <line stroke="black" x1="-50" x2="0"/>
65 <circle r="3"/>
66 <text font-size="30" text-anchor="end" fill="blue">text-anchor:end</text>
67 </g>
68 </g>
69 </g>
70 <g font-family="SVGFreeSansASCII,sans-serif" font-size="32">
71 <text id="revision" x="10" y="340" stroke="none" fill="black">$Revision: 1.8 $</text>
72 </g>
73 <rect id="test-frame" x="1" y="1" width="478" height="358" fill="none" stroke="#000000"/>
74 <!-- comment out this watermark once the test is approved -->
75 <!--<g id="draft-watermark">
76 <rect x="1" y="1" width="478" height="20" fill="red" stroke="black" stroke-width="1"/>
77 <text font-family="SVGFreeSansASCII,sans-serif" font-weight="bold" font-size="20" x="240"
78 text-anchor="middle" y="18" stroke-width="0.5" stroke="black" fill="white">DRAFT</text>
79 </g>-->
80 </svg>