Commit 535abaf8 authored by Tebjan Halm's avatar Tebjan Halm
Browse files

Merge pull request #90 from erdomke/master

Initial Work on W3C Test Compliance
parents 4b1ff3d4 bd05ecbc
<?xml version="1.0" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN" "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" id="drawrects-structure-image-BE-06" viewBox="0 0 450 450" width="450" height="450" >
<g id="drawRects">
<rect x="225" y="0" width="225" height="225" style="fill:blue" />
<rect x="0" y="225" width="225" height="225" style="fill:yellow" />
</g>
</svg>
<svg width="80" height="80" viewBox="0 0 80 80"
xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" >
<rect fill="#f63" stroke="none" x="0" y="0" width="40" height="40"/>
<rect fill="#cc9" stroke="none" x="40" y="0" width="40" height="40"/>
<rect fill="#cc9" stroke="none" x="0" y="40" width="40" height="40"/>
<rect fill="#f63" stroke="none" x="40" y="40" width="40" height="40"/>
</svg>
\ No newline at end of file
path
{
fill: green;
}
g svg circle
{
fill: green;
}
g > ellipse
{
fill: green;
}
ellipse + circle
{
fill: green;
}
[id=testAttributeSelector]
{
fill: green;
}
#testIdSelector
{
fill: green;
}
#testPseudoClassSelector:first-child
{
fill: green;
}
path
{
visibility: hidden;
}
g svg circle
{
visibility: hidden;
}
g > ellipse
{
visibility: hidden;
}
ellipse + circle
{
visibility: hidden;
}
[id=testAttributeSelector]
{
visibility: hidden;
}
#testIdSelector
{
visibility: hidden;
}
#testPseudoClassSelector:first-child
{
visibility: hidden;
}
.reference
{
visibility: visible !important;
}
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN" "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg11.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/. =-->
<!-- =====================================================================-->
<!-- =====================================================================-->
<!-- -->
<!-- struct-cond-01-b.svg -->
<!-- Test that viewer has the basic capability -->
<!-- to handle the 'ellipse' element. -->
<!-- Author : V.Katrushenko, BitFlash Inc., 2002 -->
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" id="svg-root" width="160" height="120">
<title id="test-title">shapes-rect-01-b</title>
<desc id="test-desc">Test that viewer has the basic capability to render the 'ellipse'element</desc>
<!--Content of Test Case follows...=======================================-->
<g id="test-body-content">
<ellipse id="default" cx="24" cy="22" rx="14" ry="9"/>
<ellipse id="nofill" stroke="#066" fill="none" cx="60" cy="22" rx="14" ry="9"/>
<text font-size="10" x="12" y="42">default</text>
<ellipse id="nostroke" stroke="none" cx="24" cy="56" rx="14" ry="9" />
<ellipse id="strokeNfill" stroke="#006699" stroke-width="4" fill="#f90" cx="60" cy="56" rx="14" ry="9"/>
<text font-size="10" x="12" y="76">filled</text>
<ellipse id="rxNyx" cx="102" cy="20" rx="12" ry="12"/>
<ellipse id="nofill" stroke="#066" fill="none" cx="136" cy="20" rx="12" ry="12"/>
<text font-size="10" x="88" y="42">'rx'='ry'</text>
<ellipse id="allattr" fill="#f90" stroke="#069" stroke-width="4" cx="120" cy="56" rx="30" ry="9"/>
<text font-size="10" x="88" y="76">all attributes</text>
</g>
<!--======================================================================-->
<!--Legend and frame: Title, suite and SVG document serialization====-->
<!--======================================================================-->
<rect id="slideframe" fill="none" stroke="#000000" stroke-width="1" x="1" y="1" width="158" height="118"/>
<g id="test-legend" fill="black" font-size="10" >
<rect x="3" y="81" width="154" height="36" fill="none" stroke="#000000" />
<text x="8" y="91">SVG v1.1 Conformance Suite</text>
<rect x="3" y="93" width="154" height="12" fill="none" stroke="#000000" />
<text font-size="9" x="8" y="103">shapes-ellipse-01-b</text>
<line stroke="#000000" x1="90" y1="93" x2="90" y2="117" />
<text font-size="9" x="91" y="103">$Revision: 1.1 $</text>
<a xlink:href="copyright-documents-19990405.html">
<text x="20" y="115" fill="blue">&#169;2002 W3C</text>
</a>
<text font-size="9" x="92" y="115">Release 1.0</text>
</g>
</svg>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN" "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.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/. =-->
<!--======================================================================-->
<!-- ===================================================================== -->
<!-- -->
<!-- shapes-ellipse-BE-01.svg -->
<!-- renamed for 1.1 suite to shapes-ellipse-01-f.svg -->
<!-- -->
<!-- Test that viewer has the basic capability to handle the <ellipse> -->
<!-- element. -->
<!-- -->
<!-- Author : Kelvin R. Lawrence, 3-Feb-2000 -->
<!-- -->
<!-- History: -->
<!-- 3-Feb-2000, KRL, Serial#1 created. Matches 20000202 SVG spec. -->
<!-- 27-Feb-2000, LRH, Serial#2, fix TC name, formatting, create .XML -->
<!-- 12-Mar-2000, LH, fix test-framing rect; ser#3 -->
<!-- 04-Jun-2000, LH, fix label in Legend; ser#4 -->
<!-- 03-Aug-2000, LH=" update DOCTYPE for CR DTD, 20000802" ser# . -->
<!-- -->
<!-- ===================================================================== -->
<!--======================================================================-->
<!--= Note. After October 2000, revision history is kept as CVS 'commit' =-->
<!--= log messages, and therefore is no longer in the preceding preamble.=-->
<!--======================================================================-->
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" id="svg-root" width="480" height="360">
<SVGTestCase xmlns="http://www.w3.org/2000/02/svg/testsuite/description/" >
<OperatorScript>
<Paragraph>
Verify the basic capability to handle the 'ellipse'
shape element. Four pairs of ellipses should be displayed in the
four quadrants, with the shapes in each pair being identical. Filling, stroking,
and filling-plus-stroking are applied, and the cx,cy (center position) and
rx,ry (ellipse radii) attributes are varied.
</Paragraph>
<Paragraph>
The rendered picture should match the reference image, except for possible
variations in the labelling text (per CSS2 rules).
</Paragraph>
<Paragraph>
This test uses 'text', 'rect' and 'path' elements, as well as
fill (solid primary colors), stroke (primary colors and wide lines),
font-family ("Helvetica"), and font-size properties within the 'style' attribute.
</Paragraph>
</OperatorScript>
</SVGTestCase>
<title id="test-title">shapes-ellipse-01-f</title>
<desc id="test-desc">Test that viewer has the basic capability to handle the &lt;ellipse&gt; element.</desc>
<!--======================================================================-->
<!--Content of Test Case follows... =====================-->
<!--======================================================================-->
<g id="test-body-content">
<!-- ====================================================================== -->
<!-- First pair of ellipses. -->
<!-- ====================================================================== -->
<text font-family="Helvetica" font-size="12" x="160" y="14">Basic ellipses</text>
<text font-family="Helvetica" font-size="12" x="82" y="20">rx=30</text>
<text font-family="Helvetica" font-size="12" x="82" y="38">ry=50</text>
<ellipse id="ellipse-01" fill="none" stroke="#000000" cx="50" cy="75" rx="30" ry="50"/>
<ellipse id="ellipse-02" fill="red" cx="160" cy="75" rx="30" ry="50"/>
<text font-family="Helvetica" font-size="12" x="32" y="142">stroked</text>
<text font-family="Helvetica" font-size="12" x="148" y="142">filled</text>
<!-- ====================================================================== -->
<!-- Second pair of ellipses, should actually draw circles. -->
<!-- ====================================================================== -->
<text font-family="Helvetica" font-size="12" x="298" y="20">rx=35</text>
<text font-family="Helvetica" font-size="12" x="298" y="38">ry=35</text>
<ellipse id="ellipse-03" fill="none" stroke="#000000" cx="270" cy="80" rx="35" ry="35"/>
<ellipse id="ellipse-04" fill="red" cx="370" cy="80" rx="35" ry="35"/>
<text font-family="Helvetica" font-size="12" x="250" y="142">stroked</text>
<text font-family="Helvetica" font-size="12" x="358" y="142">filled</text>
<!-- ====================================================================== -->
<!-- Third pair of ellipses. -->
<!-- ====================================================================== -->
<text font-family="Helvetica" font-size="12" x="82" y="170">rx=30</text>
<text font-family="Helvetica" font-size="12" x="82" y="186">ry=50</text>
<ellipse id="ellipse-05" fill="none" stroke="#0000FF" stroke-width="8" cx="50" cy="220" rx="30" ry="50"/>
<ellipse id="ellipse-06" fill="#00FF00" stroke="#0000FF" stroke-width="8" cx="160" cy="220" rx="30" ry="50"/>
<text font-family="Helvetica" font-size="12" x="36" y="292">stroked</text>
<text font-family="Helvetica" font-size="12" x="118" y="292">filled &amp; stroked</text>
<!-- ====================================================================== -->
<!-- Fourth pair of ellipses. -->
<!-- ====================================================================== -->
<text font-family="Helvetica" font-size="12" x="242" y="170">rx=70</text>
<text font-family="Helvetica" font-size="12" x="242" y="186">ry=40</text>
<ellipse id="ellipse-07" fill="#00FF00" stroke="#0000FF" stroke-width="8" cx="330" cy="220" rx="70" ry="40"/>
<text font-family="Helvetica" font-size="12" x="292" y="292">filled &amp; stroked</text>
</g>
<!--======================================================================-->
<!--Legend and frame: Title, suite and SVG document serialization====-->
<!--======================================================================-->
<g id="test-legend" fill="black" font-family="Helvetica" font-size="10" >
<rect x="10" y="300" width="275" height="50" fill="none" stroke="#000000" />
<path fill="none" stroke="#000000" d="M10 315 h275 M205 315 v35 M10 336 h195 M205 332 h80"/>
<text x="25" y="311">Scalable Vector Graphics (SVG) v1.1 Conformance Suite</text>
<a xlink:href="copyright-documents-19990405.html">
<text x="12" y="347" fill="blue" >Copyright 2002 W3C. All Rights Reserved.</text>
</a>
<text font-size="12" x="35" y="330">shapes-ellipse-01-f</text>
<text font-size="10" x="210" y="327">$Revision: 1.1 $</text>
<text font-size="10" x="210" y="345">Release 1.0</text>
<rect id="test-frame" x="1" y="1" width="478" height="358" fill="none" stroke="#000000" />
</g>
</svg>
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN" "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg11.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/. =-->
<!-- =====================================================================-->
<!-- =====================================================================-->
<!-- -->
<!-- struct-cond-01-b.svg -->
<!-- Test that viewer has the basic capability -->
<!-- to handle the 'rect' element. -->
<!-- Author : V.Katrushenko, BitFlash Inc., 2002 -->
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" id="svg-root" width="160" height="120">
<title id="test-title">shapes-rect-01-b</title>
<desc id="test-desc">Test that viewer has the basic capability to render the 'rect'element</desc>
<!--Content of Test Case follows...=======================================-->
<g id="test-body-content">
<rect id="default" x="12" y="14" width="24" height="18" />
<rect id="nofill" stroke="#066" fill="none" x="48" y="14" width="24" height="18"/>
<text font-size="10" x="12" y="42">default</text>
<rect id="nostroke" stroke="none" x="12" y="48" width="24" height="18" />
<rect id="stroke-fill" stroke="#006699" stroke-width="4" fill="#f90" x="48" y="48" width="24" height="18"/>
<text font-size="10" x="12" y="76">filled</text>
<rect id="roundcorner1" fill="none" stroke="#000" rx="9" x="88" y="14" width="24" height="18" />
<rect id="roundcorner2" fill="#f90" stroke="#069" stroke-width="4" rx="9" x="124" y="14" width="24" height="18"/>
<text font-size="10" x="88" y="42">rounded 'x'</text>
<rect id="rouncorner1" fill="none" stroke="#000" rx="12" ry="16" x="88" y="48" width="24" height="18" />
<rect id="rouncorner22" fill="#f90" stroke="#069" stroke-width="4" rx="12" ry="16" x="124" y="48" width="24" height="18"/>
<text font-size="10" x="88" y="76">rounded 'x', 'y'</text>
</g>
<!--======================================================================-->
<!--Legend and frame: Title, suite and SVG document serialization====-->
<!--======================================================================-->
<rect id="slideframe" fill="none" stroke="#000000" stroke-width="1" x="1" y="1" width="158" height="118"/>
<g id="test-legend" fill="black" font-size="10" >
<rect x="3" y="81" width="154" height="36" fill="none" stroke="#000000" />
<text x="8" y="91">SVG v1.1 Conformance Suite</text>
<rect x="3" y="93" width="154" height="12" fill="none" stroke="#000000" />
<text x="8" y="103">shapes-rect-01-b</text>
<line stroke="#000000" x1="90" y1="93" x2="90" y2="117" />
<text font-size="9" x="91" y="103">$Revision: 1.1 $</text>
<a xlink:href="copyright-documents-19990405.html">
<text x="20" y="115" fill="blue">&#169;2002 W3C</text>
</a>
<text font-size="9" x="92" y="115">Release 1.0</text>
</g>
</svg>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN" "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.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/. =-->
<!--======================================================================-->
<!-- ===================================================================== -->
<!-- -->
<!-- shapes-rect-BE-01.svg -->
<!-- renamed for 1.1 suite to shapes-rect-01-f.svg -->
<!-- -->
<!-- Test that viewer has the basic capability to handle the <rect> -->
<!-- element. -->
<!-- -->
<!-- Author : Kelvin R. Lawrence, 3-Feb-2000 -->
<!-- -->
<!-- History: -->
<!-- 3-Feb-2000, KRL, Serial#1 created. Matches 20000202 SVG spec. -->
<!-- 27-Feb-2000, LH, Serial#2, fix TC name, formatting, create .XML -->
<!-- 12-Mar-2000, LH, fix test-framing rect; ser#3 -->
<!-- 03-Aug-2000, LH=" update DOCTYPE for CR DTD, 20000802" ser# . -->
<!-- -->
<!-- ===================================================================== -->
<!--======================================================================-->
<!--= Note. After October 2000, revision history is kept as CVS 'commit' =-->
<!--= log messages, and therefore is no longer in the preceding preamble.=-->
<!--======================================================================-->
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" id="svg-root" width="480" height="360">
<SVGTestCase xmlns="http://www.w3.org/2000/02/svg/testsuite/description/">
<OperatorScript>
<Paragraph>
Verify that interpreter/viewer has basic capability to handle the 'rect'
shape element. Four pairs of rectangles should be displayed in the
four quadrants, with the shapes in each pair being identical to each other.
Filling, stroking, and filling-plus-stroking are tested, as are the round-rect
attributes.
</Paragraph>
<Paragraph>
The rendered picture should match the reference image, except for possible
variations in the labelling text (per CSS2 rules).
</Paragraph>
<Paragraph>
This test uses 'text' and 'path' elements, as well as
fill (solid primary colors), stroke (primary colors and wide lines),
font-family ("Helvetica"), and font-size properties within the 'style' attribute.
</Paragraph>
</OperatorScript>
</SVGTestCase>
<title id="test-title">shapes-rect-01-f</title>
<desc id="test-desc">Test that viewer has the basic capability to handle the &lt;rect&gt; element.</desc>
<!--======================================================================-->
<!--Content of Test Case follows... =====================-->
<!--======================================================================-->
<g id="test-body-content">
<!-- ====================================================================== -->
<!-- First of all draw two simple rectangles. One stroked , one filled. -->
<!-- ====================================================================== -->
<text font-family="Helvetica" font-size="12" x="160" y="14">Basic rectangles</text>
<text font-family="Helvetica" font-size="12" x="82" y="20">width=50</text>
<text font-family="Helvetica" font-size="12" x="78" y="36">height=80</text>
<rect id="Simple-rect-no-fill" fill="none" stroke="#000000" x="30" y="46" width="50" height="80"/>
<rect id="Simple-rect-filled" fill="red" x="130" y="46" width="50" height="80"/>
<text font-family="Helvetica" font-size="12" x="36" y="142">stroked</text>
<text font-family="Helvetica" font-size="12" x="142" y="142">filled</text>
<!-- ====================================================================== -->
<!-- Second set of rectangles this time with rounded corners. -->
<!-- ====================================================================== -->
<text font-family="Helvetica" font-size="12" x="302" y="20">width=50</text>
<text font-family="Helvetica" font-size="12" x="298" y="36">height=80</text>
<text font-family="Helvetica" font-size="12" x="310" y="52">rx=30</text>
<rect id="Simple-round-rect-no-fill" fill="none" stroke="#000000" x="250" y="46" width="50" height="80" rx="30"/>
<rect id="Simple-round-rect-filled" fill="red" x="350" y="46" width="50" height="80" rx="30"/>
<text font-family="Helvetica" font-size="12" x="256" y="142">stroked</text>
<text font-family="Helvetica" font-size="12" x="362" y="142">filled</text>
<!-- ====================================================================== -->
<!-- Third set of rectangles. -->
<!-- ====================================================================== -->
<text font-family="Helvetica" font-size="12" x="82" y="170">width=50</text>
<text font-family="Helvetica" font-size="12" x="78" y="186">height=80</text>
<rect id="rect-03" fill="none" stroke="#0000FF" stroke-width="8" x="30" y="196" width="50" height="80"/>
<rect id="rect-04" fill="#00FF00" stroke="#0000FF" stroke-width="8" x="130" y="196" width="50" height="80"/>
<text font-family="Helvetica" font-size="12" x="36" y="292">stroked</text>
<text font-family="Helvetica" font-size="12" x="118" y="292">filled &amp; stroked</text>
<!-- ====================================================================== -->
<!-- Fourth set of rectangles. -->
<!-- ====================================================================== -->
<text font-family="Helvetica" font-size="12" x="272" y="170">width=50, height=80</text>
<text font-family="Helvetica" font-size="12" x="296" y="186">rx=30 ry=50</text>
<rect id="rect-05" fill="none" stroke="#0000FF" stroke-width="8" x="250" y="196" width="50" height="80" rx="30" ry="50"/>
<rect id="rect-06" fill="#00FF00" x="350" y="196" width="50" height="80" rx="30" ry="50"/>
<text font-family="Helvetica" font-size="12" x="256" y="292">stroked</text>
<text font-family="Helvetica" font-size="12" x="362" y="292">filled</text>
</g>
<!--======================================================================-->
<!--Legend and frame: Title, suite and SVG document serialization====-->
<!--======================================================================-->
<g id="test-legend" fill="black" font-family="Helvetica" font-size="10" >
<rect x="10" y="300" width="275" height="50" fill="none" stroke="#000000" />
<path fill="none" stroke="#000000" d="M10 315 h275 M205 315 v35 M10 336 h195 M205 332 h80"/>
<text x="25" y="311">Scalable Vector Graphics (SVG) v1.1 Conformance Suite</text>
<a xlink:href="copyright-documents-19990405.html">
<text x="12" y="347" fill="blue" >Copyright 2002 W3C. All Rights Reserved.</text>
</a>
<text font-size="12" x="35" y="330">shapes-rect-01-f</text>
<text font-size="10" x="210" y="327">$Revision: 1.1 $</text>
<text font-size="10" x="210" y="345">Release 1.0</text>
<rect id="test-frame" x="1" y="1" width="478" height="358" fill="none" stroke="#000000" />
</g>
</svg>
<svg viewBox="0 0 260 260" xmlns="http://www.w3.org/2000/svg">
<defs>
<filter id="blur">
<feGaussianBlur stdDeviation="1.6"/>
</filter>
<linearGradient id="lg1" gradientTransform="matrix(3.5462873,0,0,3.5462873,-877.27083,-952.49474)" x1="393.57144" y1="380.21933" x2="385.35715" y2="413.07648" gradientUnits="userSpaceOnUse">
<stop stop-color="#fff" stop-opacity="0.8" offset="0"/>
<stop stop-color="#fff" stop-opacity="0" offset="1"/>
</linearGradient>
<radialGradient id="rg1" r="32.259853" gradientUnits="userSpaceOnUse" gradientTransform="matrix(-0.7006288,2.6147823,-3.0454274,-0.816019,1468.3216,-225.92549)" cx="303.21429" cy="312.8187" fx="303.21429" fy="312.8187">
<stop stop-color="#ff0" offset="0"/>
<stop stop-color="#ff0" stop-opacity="0" offset="1"/>
</radialGradient>
</defs>
<g transform="translate(-349.57877,-377.71875)">
<path transform="matrix(3.5462873,0,0,3.5462873,-558.10497,-696.65544)" d="M 323,360 L 299,353 L 283,372 L 282,348 L 259,338 L 282,330 L 284,305 L 299,325 L 324,319 L 310,339 L 323,360 z" filter="url(#blur)"/>
<path transform="matrix(3.5462873,0,0,3.5462873,-558.10497,-696.65544)" fill="url(#rg1)" d="M 323,360 L 299,353 L 283,372 L 282,348 L 259,338 L 282,330 L 284,305 L 299,325 L 324,319 L 310,339 L 323,360 z"/>
<path fill="url(#lg1)" d="M 451,387 L 445,474 L 417,485 C 442,492 471,495 501,495 C 519,495 536,494 552,491 L 591,435 L 505,456 L 451,387 z"/>
</g>
</svg>
\ No newline at end of file
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment