Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / svg / batik / text / textAnchor.svg
blob74202a0403413e2e710ddfc07028c11461c34d9a
1 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
2 <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 20010904//EN"
3 "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">
5 <!--
7 Copyright 2001 The Apache Software Foundation
9 Licensed under the Apache License, Version 2.0 (the "License");
10 you may not use this file except in compliance with the License.
11 You may obtain a copy of the License at
13 http://www.apache.org/licenses/LICENSE-2.0
15 Unless required by applicable law or agreed to in writing, software
16 distributed under the License is distributed on an "AS IS" BASIS,
17 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
18 See the License for the specific language governing permissions and
19 limitations under the License.
21 -->
22 <!-- ====================================================================== -->
23 <!-- Tests text-anchor on tspan elements -->
24 <!-- -->
25 <!-- @author tkormann@ilog.fr -->
26 <!-- @version $Id: textAnchor.svg,v 1.4 2005/01/03 10:48:05 deweese Exp $ -->
27 <!-- ====================================================================== -->
28 <?xml-stylesheet type="text/css" href="../resources/test.css" ?>
30 <svg width="450" height="500" viewBox="0 0 450 500"
31 xmlns="http://www.w3.org/2000/svg"
32 xmlns:xlink="http://www.w3.org/1999/xlink" >
34 <text class="title" x="50%" y="40">text-anchor on &lt;tspan&gt;</text>
36 <g id="testContent" transform="translate(56.25, 82.5) scale(.75,.75)">
38 <g transform="translate(0,0)">
39 <rect width="450" height="167" fill="black" opacity=".1" />
40 <rect y="167" width="450" height="167" fill="white" />
41 <rect y="334" width="450" height="166" fill="black" opacity=".1" />
43 <line x1="150" y1="0" x2="150" y2="500" style="stroke:red; fill:none" />
44 <line x1="320" y1="0" x2="320" y2="500" style="stroke:red; fill:none" />
45 <rect width="450" height="500" stroke="red" fill="none" />
46 </g>
48 <g transform="translate(0, 0)">
49 <!-- ############################## -->
50 <!-- textChunk1: text-anchor:start -->
51 <!-- textChunk2: text-anchor:start -->
52 <!-- ############################## -->
53 <g transform="translate(0, 0)">
55 <text y="50">
56 <tspan x="150" style="text-anchor:start">I am the</tspan>
57 <tspan style="fill:red"> same text chunk</tspan>
58 <tspan x="320" y="30" style="text-anchor:start">another text chunk</tspan>
59 </text>
61 </g>
64 <!-- ############################## -->
65 <!-- textChunk1: text-anchor:middle -->
66 <!-- textChunk2: text-anchor:start -->
67 <!-- ############################## -->
68 <g transform="translate(0 40)">
70 <text y="50">
71 <tspan x="150" style="text-anchor:middle">I am the</tspan>
72 <tspan style="fill:red"> same text chunk</tspan>
73 <tspan x="320" y="30" style="text-anchor:start">another text chunk</tspan>
74 </text>
76 </g>
78 <!-- ############################## -->
79 <!-- textChunk1: text-anchor:end -->
80 <!-- textChunk2: text-anchor:start -->
81 <!-- ############################## -->
82 <g transform="translate(0 80)">
84 <text y="50">
85 <tspan x="150" style="text-anchor:end">I am the</tspan>
86 <tspan style="fill:red"> same text chunk</tspan>
87 <tspan x="320" y="30" style="text-anchor:start">another text chunk</tspan>
88 </text>
90 </g>
91 </g>
93 <!-- ############################################################################ -->
94 <!-- ############################################################################ -->
96 <g transform="translate(0 50)">
97 <!-- ############################## -->
98 <!-- textChunk1: text-anchor:start -->
99 <!-- textChunk2: text-anchor:middle -->
100 <!-- ############################## -->
101 <g transform="translate(0 120)">
103 <text y="50">
104 <tspan x="150" style="text-anchor:start">I am the</tspan>
105 <tspan style="fill:red"> same text chunk</tspan>
106 <tspan x="320" y="30" style="text-anchor:middle">another text chunk</tspan>
107 </text>
109 </g>
112 <!-- ############################## -->
113 <!-- textChunk1: text-anchor:middle -->
114 <!-- textChunk2: text-anchor:middle -->
115 <!-- ############################## -->
116 <g transform="translate(0 160)">
118 <text y="50">
119 <tspan x="150" style="text-anchor:middle">I am the</tspan>
120 <tspan style="fill:red"> same text chunk</tspan>
121 <tspan x="320" y="30" style="text-anchor:middle">another text chunk</tspan>
122 </text>
124 </g>
126 <!-- ############################## -->
127 <!-- textChunk1: text-anchor:end -->
128 <!-- textChunk2: text-anchor:middle -->
129 <!-- ############################## -->
130 <g transform="translate(0 200)">
132 <text y="50">
133 <tspan x="150" style="text-anchor:end">I am the</tspan>
134 <tspan style="fill:red"> same text chunk</tspan>
135 <tspan x="320" y="30" style="text-anchor:middle">another text chunk</tspan>
136 </text>
138 </g>
139 </g>
141 <!-- ############################################################################ -->
142 <!-- ############################################################################ -->
143 <g transform="translate(0, 80)">
145 <!-- ############################# -->
146 <!-- textChunk1: text-anchor:start -->
147 <!-- textChunk2: text-anchor:end -->
148 <!-- ############################# -->
149 <g transform="translate(0 260)">
151 <text y="50">
152 <tspan x="150" style="text-anchor:start">I am the</tspan>
153 <tspan style="fill:red"> same text chunk</tspan>
154 <tspan x="320" y="30" style="text-anchor:end">another text chunk</tspan>
155 </text>
157 </g>
160 <!-- ############################## -->
161 <!-- textChunk1: text-anchor:middle -->
162 <!-- textChunk2: text-anchor:end -->
163 <!-- ############################## -->
164 <g transform="translate(0 300)">
166 <text y="50">
167 <tspan x="150" style="text-anchor:middle">I am the</tspan>
168 <tspan style="fill:red"> same text chunk</tspan>
169 <tspan x="320" y="30" style="text-anchor:end">another text chunk</tspan>
170 </text>
172 </g>
174 <!-- ############################## -->
175 <!-- textChunk1: text-anchor:end -->
176 <!-- textChunk2: text-anchor:end -->
177 <!-- ############################## -->
178 <g transform="translate(0 340)">
180 <text y="50">
181 <tspan x="150" style="text-anchor:end">I am the</tspan>
182 <tspan style="fill:red"> same text chunk</tspan>
183 <tspan x="320" y="30" style="text-anchor:end">another text chunk</tspan>
184 </text>
186 </g>
187 </g>
188 </g>
190 <!-- ============================================================= -->
191 <!-- Batik sample mark -->
192 <!-- ============================================================= -->
193 <use xlink:href="../resources/batikLogo.svg#Batik_Tag_Box" />
194 </svg>