Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / svg / W3C-SVG-1.1 / linking-uri-02-b.svg
blob84d6ce62fb4f77907ac327cfc73286e02426d117
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1 Basic//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11-basic.dtd">
4 <!--======================================================================-->
5 <!--= Copyright 2000 World Wide Web Consortium, (Massachusetts =-->
6 <!--= Institute of Technology, Institut National de Recherche en =-->
7 <!--= Informatique et en Automatique, Keio University). All Rights =-->
8 <!--= Reserved. See http://www.w3.org/Consortium/Legal/. =-->
9 <!--======================================================================-->
10 <!-- =====================================================================-->
11 <!-- -->
12 <!-- linking-uri-02-b.svg -->
13 <!-- -->
14 <!-- Link test of the 'view' element and its attributes, 2 of 2, external.-->
15 <!-- -->
16 <!-- Note. This is one of a pair, with linking-uri-01-b.svg, which is -->
17 <!-- identical except that all of its links refer to the objects within -->
18 <!-- itself. The links herein refer to the matching objects in uri-01-b. -->
19 <!-- -->
20 <!-- Author : Lee Klosterman 01-February-2002 -->
21 <!-- Revised for Mobile Profiles: Jun Fujisawa 16-Jul-2002 -->
22 <!-- -->
23 <!-- History: -->
24 <!-- -->
25 <!-- =====================================================================-->
26 <!--======================================================================-->
27 <!--= Note. After October 2000, revision history is kept as CVS 'commit' =-->
28 <!--= log messages, and therefore is no longer in the preceding preamble.=-->
29 <!--======================================================================-->
30 <svg version="1.1" baseProfile="basic" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" id="svg-root" width="100%" height="100%" viewBox="0 0 480 360">
32 <SVGTestCase xmlns="http://www.w3.org/2000/02/svg/testsuite/description/" chapter="linking" section="uri" profile="f" index="02" >
34 <!-- For BE-01 case, 'Previous' should target last BE of previous chapter-focus -->
36 <!-- Previous focus="view" BENumber="04" / -->
38 <!-- For last BE of chapter, 'Next' should target first BE of next chapter-focus -->
40 <!-- Next chapter="script" focus="eventDom" BENumber="01" / -->
41 <!-- Parent chapter="toc" / -->
43 <!-- For now, all BE target DT-01 in same chapter-focus as Child -->
45 <!-- Child testType="DT" DTNumber="01" / -->
47 <OperatorScript version="$Revision: 1.7 $" testname="linking-uri-02-b.svg">
48 <Paragraph>
49 Verify the capability to handle links to 'view' elements, and the
50 permissible attributes on those elements. All of the links in this
51 test case are external, i.e., to 'view' elements in another the SVG file.
52 That file is linking-uri-01-b.svg.
53 This test is one of a pair, with linking-view-BE-04, which is substantially
54 identical except that its links are all internal, targeting the same 'view'
55 elements as the corresponding links in this test case,
56 i.e., they are external).
57 </Paragraph>
58 <Paragraph>
59 In the four quadrants of the initial picture are four graphical objects.
60 Clockwise from upper right, they are
61 a red rectangle, blue ellipse, green polygon (pentagon), and yellow
62 circle. Each is labelled and tightly boxes with a rectangular frame.
63 These are identical to their counterparts in linking-uri-01-b.svg, in which
64 file each has an associated 'view' element, with attributes
65 per the labels in the initial picture.
66 </Paragraph>
67 <Paragraph>
68 In the center is a gray box with four lines of text, each of which says
69 "Go to" followed by Rectangle, Ellipse, Polygon, and Circle, respectively.
70 Each of these is contained within an 'a' element, whose xlink:href names
71 the respective 'view' element of the respective graphical object.
72 </Paragraph>
73 <Paragraph>
74 Activating the Rectangle link should cause the whole of linking-uri-01-b.svg to be
75 displayed, which is visually similar similar to linking-uri-02-b.svg. Its
76 'view' element has no attributes (other than id), so the correct view in
77 the frame is of the parent 'svg' element, which is the whole picture.
78 </Paragraph>
79 <Paragraph>
80 Assuming that a "back" action has been requested, activating the Ellipse link
81 should cause the initial picture to be replaced in the
82 frame by the whole ellipse element, uniformly scaled, with its boxing rect
83 just inside the frame.
84 </Paragraph>
85 <Paragraph>
86 Assuming that a "back" action has
87 been requested, activating the Polygon link should cause the initial
88 picture to remain unchanged within the frame, except that the polygon is
89 "highlighted" (the meaning of highlighted is not further specified).
90 </Paragraph>
91 <Paragraph>
92 Assuming that a "back" action has been requested,
93 activating the Circle link should cause the initial picture to be replaced in the
94 frame by the whole whole element, non-uniformly scaled so that it is stretched
95 horizontally into an ellipse, with its boxing rect just inside the frame.
96 </Paragraph>
97 <Paragraph>
98 There are several reference images associated with this test case. The first
99 illustrates the correct initial state of the rendered SVG file, which should
100 also be the correct picture after the Rectangle link is executed.
101 The second, third, and fourth illustrate the correct images as described
102 above after respectively the Ellipse, Polygon, and Circle links are activated.
103 (Note. This harness does not yet provide access to multiple PNGs; the PNG for the
104 initial view is shown.)
105 </Paragraph>
106 <Paragraph>
107 The test uses the 'rect', 'circle', 'ellipse', and 'polygon' elements,
108 as well as basic fill (solid simple colors),
109 stroke (black and colored 1-pixel lines), font-family (Arial) and font-size properties.
110 </Paragraph>
111 </OperatorScript>
113 </SVGTestCase>
115 <title id="test-title">linking-uri-02-b</title>
116 <desc id="test-desc">Link test of the 'view' element and its attributes, 2 of 2, external.</desc>
117 <!--======================================================================-->
118 <!--Content of Test Case follows... =====================-->
119 <!--======================================================================-->
120 <g id="test-body-content">
121 <text x="50" y="16" font-size="12" >Link test of the 'view' element and its attributes, 2 of 2, external.</text>
122 <g transform="translate(-150,75)">
123 <rect x="300" y="55" width="125" height="85" fill="#aaa" />
124 <a xlink:href="resources/linking-uri-01-b.svg#rect-view">
125 <text x="320" y="70" fill="red" >Go to Rectangle</text>
126 </a>
127 <a xlink:href="resources/linking-uri-01-b.svg#ellipse-view">
128 <text x="320" y="90" fill="blue" >Go to Ellipse</text>
129 </a>
130 <a xlink:href="resources/linking-uri-01-b.svg#circle-view">
131 <text x="320" y="110" fill="yellow" >Go to Circle</text>
132 </a>
133 <a xlink:href="resources/linking-uri-01-b.svg#polygon-view">
134 <text x="320" y="130" fill="green" >Go to Polygon</text>
135 </a>
136 <text x="310" y="150" font-size="12" >Click element's line</text>
137 <text x="310" y="162" font-size="12" >to link to its view in</text>
138 <text x="310" y="174" font-size="12" >linking-uri-01-b.</text>
139 </g>
141 <!-- In linking-uri-01-b, there is the following 'view' element. -->
142 <!-- View with no attributes. Picture should not change. -->
143 <!-- <view id="rect-view" /> -->
144 <rect id="rect-object" fill="red" x="295" y="36" width="135" height="68"/>
145 <text id="rect-label" x="340" y="116">Rectangle</text>
146 <rect x="292" y="29" width="141" height="91" fill="none" stroke="black" />
147 <text x="302" y="130" font-size="10" >No view attributes except id.</text>
148 <!-- In linking-uri-01-b, there is the following 'view' element. -->
149 <!-- Test viewBox. Should blow-up the ellipse in the frame. -->
150 <!-- <view id="ellipse-view" viewBox="294 221 152 83"/> -->
151 <ellipse id="ellipse-object" fill="blue" cx="370" cy="251" rx="72" ry="32"/>
152 <text id="ellipse-label" x="355" y="295">Ellipse</text>
153 <rect x="295" y="216" width="150" height="82" fill="none" stroke="black" />
154 <text x="315" y="214" font-size="10" >viewBox, should fill frame.</text>
155 <!-- In linking-uri-01-b, there is the following 'view' element. -->
156 <!-- Test preserveAspectRatio. -->
157 <!-- <view id="circle-view" viewBox="20 29 128 91.5" preserveAspectRatio="none"/> -->
158 <circle id="circle-object" fill="yellow" cx="85" cy="68" r="36"/>
159 <text id="circle-label" x="70" y="116">Circle</text>
160 <rect x="36" y="29" width="98" height="91" fill="none" stroke="black" />
161 <text x="36" y="128" font-size="10" >viewBox &amp; non-uniform</text>
162 <text x="36" y="137" font-size="10" >preserveAspectRatio</text>
163 <!-- In linking-uri-01-b, there is the following 'view' element. -->
164 <!-- Test viewTarget attribute, should highlight the polygon. -->
165 <!-- <view id="polygon-view" viewTarget="polygon-object" /> -->
166 <polygon id="polygon-object" fill="green" points="87,211 134,238 116,283 57,283 39,238 87,211"/>
167 <text id="polygon-label" x="65" y="295">Polygon</text>
168 <rect x="36" y="208" width="100" height="89" fill="none" stroke="black" />
169 <text x="46" y="197" font-size="10" >viewTarget, should</text>
170 <text x="46" y="206" font-size="10" >highlight polygon</text>
171 </g>
173 <text id="revision" x="10" y="340" font-size="40" stroke="none" fill="black">$Revision: 1.7 $</text>
174 <rect id="test-frame" x="1" y="1" width="478" height="358" fill="none" stroke="#000000"/>
175 </svg>