96 lines
5.9 KiB
XML
96 lines
5.9 KiB
XML
<?xml version="1.0" encoding="UTF-8"?>
|
|
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1 Basic//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11-basic.dtd">
|
|
|
|
<!--======================================================================-->
|
|
<!--= Copyright 2000 World Wide Web Consortium, (Massachusetts =-->
|
|
<!--= Institute of Technology, Institut National de Recherche en =-->
|
|
<!--= Informatique et en Automatique, Keio University). All Rights =-->
|
|
<!--= Reserved. See http://www.w3.org/Consortium/Legal/. =-->
|
|
<!--======================================================================-->
|
|
<!-- =====================================================================-->
|
|
<!-- -->
|
|
<!-- structure-symbol-BE-05.svg -->
|
|
<!-- renamed to struct-symbol-01-b -->
|
|
<!-- -->
|
|
<!-- Test the creation of symbol elements and the -->
|
|
<!-- instantiation by the use element. -->
|
|
<!-- -->
|
|
<!-- Author : Tim Thompson 3/16/00 -->
|
|
<!-- Revised for 1.1 : Rick Graham Feb/05/2002 -->
|
|
<!-- Revised for Mobile Profiles: Jun Fujisawa 16-Jul-2002 -->
|
|
<!-- -->
|
|
<!-- History: -->
|
|
<!-- 20-mar-2000, test the symbol and use elements -->
|
|
<!-- 09-apr-2000, LH=" fix title" remove nested svg; cmmt DOCTYPE; ser#2.-->
|
|
<!-- 15-may-2000, TT=" changed use to reference symbol not image" ser#3 -->
|
|
<!-- 01-jun-2000 LH=" fix patch for upper-left image" ser#4 -->
|
|
<!-- 03-Aug-2000, LH=" update DOCTYPE for CR DTD, 20000802" ser# . -->
|
|
<!-- 16-Aug-2000, LH="rename" ser#5. -->
|
|
<!-- 15-Nov-2000, LH: add missing test-body-content group. -->
|
|
<!-- -->
|
|
<!-- =====================================================================-->
|
|
<!--======================================================================-->
|
|
<!--= Note. After October 2000, revision history is kept as CVS 'commit' =-->
|
|
<!--= log messages, and therefore is no longer in the preceding preamble.=-->
|
|
<!--======================================================================-->
|
|
<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">
|
|
<SVGTestCase xmlns="http://www.w3.org/2000/02/svg/testsuite/description/">
|
|
<!--nav data here-->
|
|
<OperatorScript version="$Revision: 1.6 $" testname="struct-symbol-01-b.svg">
|
|
<Paragraph>
|
|
The purpose of the symbol test case is to create some symbols and then
|
|
have them rendered when instantiated by the use element. This file
|
|
contains 3 symbol definitions. Only two are ever rendered. There
|
|
is a viewport defined to be 0,0,1000,1000 on the svg element. Each
|
|
symbol has is own viewport of the same dimensions. The symbols are
|
|
scaled when they are instantiated by the use element, The first set
|
|
of symbols is 4 squares, red and yellow in color they should appear
|
|
in the lower right of the view arranged in a checkerboard fashion.
|
|
The second symbol to be used is an image which should appear in the
|
|
upper left of the view area. The symbol that is not used and should
|
|
not be rendered is a large black rectangle. If the symbols don't
|
|
appear, there is something askew with the use statement, if they
|
|
appear but either overlap each other or in some way aren't in the
|
|
correct positions they have not honored either their viewport or
|
|
were not scaled when placed by the use element in the area defined by
|
|
it. If everything is black then perhaps a symbol was rendered that
|
|
should not have been.
|
|
</Paragraph>
|
|
<Paragraph>
|
|
The rendered picture should match the reference image, except for possible
|
|
variations in the labelling text (per CSS2 rules).
|
|
</Paragraph>
|
|
<Paragraph>
|
|
The test uses the 'rect' element, as well as basic fill (solid primary colors),
|
|
stroke (black 1-pixel lines), font-family (Arial) and font-size properties.
|
|
</Paragraph>
|
|
</OperatorScript>
|
|
</SVGTestCase>
|
|
<title id="test-title">struct-symbol-01-b</title>
|
|
<desc id="test-desc">Test the creation of symbol elements and the instantiation by the use element</desc>
|
|
<!--======================================================================-->
|
|
<!--Content of Test Case follows... =====================-->
|
|
<!--======================================================================-->
|
|
<g id="test-body-content">
|
|
<symbol id="imageRef1" viewBox="0 0 1000 1000" preserveAspectRatio="none">
|
|
<image id="image1" x="0" y="0" width="1000" height="1000" xlink:href="resources/struct-symbol-01.png"/>
|
|
</symbol>
|
|
<symbol id="largeRect">
|
|
<rect x="0" y="0" width="1000" height="1000"/>
|
|
</symbol>
|
|
<symbol id="drawRects" viewBox="0 0 1000 1000" preserveAspectRatio="none">
|
|
<rect x="0" y="0" width="500" height="500" fill="yellow" />
|
|
<rect x="500" y="0" width="500" height="500" fill="red" />
|
|
<rect x="0" y="500" width="500" height="500" fill="red" />
|
|
<rect x="500" y="500" width="500" height="500" fill="yellow" />
|
|
</symbol>
|
|
<g id="useNdraw">
|
|
<use id="upperLeft" x="0" y="0" width="240" height="150" xlink:href="#imageRef1"/>
|
|
<use id="lowerRight" x="240" y="150" width="240" height="150" xlink:href="#drawRects"/>
|
|
</g>
|
|
</g>
|
|
<text id="revision" x="10" y="340" font-size="40" stroke="none" fill="black">$Revision: 1.6 $</text>
|
|
<rect id="test-frame" x="1" y="1" width="478" height="358" fill="none" stroke="#000000"/>
|
|
</svg>
|
|
|