1 <?xml version=
"1.0" encoding=
"UTF-8"?>
2 <!--======================================================================-->
3 <!--= Copyright 2004 World Wide Web Consortium, (Massachusetts =-->
4 <!--= Institute of Technology, Institut National de Recherche en =-->
5 <!--= Informatique et en Automatique, Keio University). All Rights =-->
6 <!--= Reserved. See http://www.w3.org/Consortium/Legal/. =-->
7 <!--======================================================================--><!DOCTYPE svg PUBLIC
"-//W3C//DTD SVG 1.1 Tiny//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11-tiny.dtd">
9 <svg xmlns=
"http://www.w3.org/2000/svg" xmlns:
xlink=
"http://www.w3.org/1999/xlink" version=
"1.1" baseProfile=
"tiny" id=
"svg-root" width=
"100%" height=
"100%" viewBox=
"0 0 480 360">
10 <SVGTestCase xmlns:
testcase=
"http://www.w3.org/2000/02/svg/testsuite/description/" xmlns=
"http://www.w3.org/2000/02/svg/testsuite/description/" reviewer=
"CN" owner=
"VH" desc=
"Basic test on the animation's fill attribute" status=
"accepted" version=
"$Revision: 1.7 $" testname=
"$RCSfile: animate-elem-70-t.svg,v $">
13 This tests performs basic tests on the animation's SMIL fill attribute.
16 On the first row, the
<set
> animation has its dur
17 attribute set to '
1s' and its begin attribute set to '
0s;
18 firstSet.end +
1s'. The fill attribute is unspecified, so the
19 the effect is as if it was set to 'remove', because 'remove' is
20 the default value for fill.
22 Consequently, the first interval is (
0s
<= t
< 1s), the second is
23 (
2s
<= t
< 3s), the third, (
4s
<= t
< 5s) etc.. The red rectangle starts on the
24 right position, moves to the left position for one second, moves
25 to the right for
1 second, and so on.
28 On the second row, the
<set
> animation has its dur attribute set to
29 1s and its begin attribute set to '
0s; firstSet.end'. The fill attribute
30 is set to 'remove'. The behavior should be exactly the same as for the previous
31 row, and the rectangle moves from the right position to the left position
35 On the third row, the
<set
> animation has its dur attribute set to
36 1s and its begin attribute set to '
0s; firstSet.end'. The fill attribute
37 is set to 'freeze'. The first interval should be (
0s
<= t
< 1s), the second (
2s
<= t
< 3s),
38 the third (
4s
<= t
< 5s), etc. Between interval, the fill behavior should be applied,
39 so the red rectangle should stay on the right position and never go to the
43 On the fourth row, the
<set
> animation has its dur attribute set to
44 1s and its begin attribute set to '
0s'. The fill attribute
45 is set to 'freeze'. The first interval should be (
0s
<= t
< 1s) and there is no
46 following interval. Because of the fill behavior, the
<set
> should
47 apply the last (and only) animation value after
1s. Consequently, the
48 red rectangle should stay on the right position and never go to the
53 <title id=
"test-title">$RCSfile: animate-elem-
70-t.svg,v $
</title>
55 <!--======================================================================-->
56 <!--Content of Test Case follows... =====================-->
57 <!--======================================================================-->
58 <text id=
"revision" x=
"10" y=
"340" font-size=
"40" stroke=
"none" fill=
"black">$Revision:
1.7 $
</text>
59 <rect id=
"test-frame" x=
"1" y=
"1" width=
"478" height=
"358" fill=
"none" stroke=
"#000"/>
61 <text text-anchor=
"middle" x=
"240" y=
"30" font-size=
"20">fill
</text>
63 <g transform=
"translate(130, 60)">
65 <g transform=
"translate(120,45)" text-anchor=
"end" font-size=
"14">
66 <text>fill unspecified (remove)
</text>
67 <text y=
"25">fill=remove
</text>
70 <text y=
"100">fill=freeze (with restart)
</text>
71 <text y=
"125">fill=freeze (no restart)
</text>
74 <g id=
"timeMarkersText" transform=
"translate(180, 125)" text-anchor=
"middle" font-size=
"14">
75 <text y=
"-15">never
</text>
77 <text y=
"-15" x=
"80">always
</text>
78 <text x=
"80">here
</text>
81 <g transform=
"translate(180,40)" stroke=
"black">
83 <rect id=
"shadow" x=
"-6" y=
"-6" width=
"12" height=
"12" fill=
"#ccc" stroke=
"black" stroke-width=
"1"/>
87 <use xlink:
href=
"#shadow" x=
"0"/>
88 <use xlink:
href=
"#shadow" x=
"80"/>
90 <rect x=
"-6" y=
"-6" width=
"12" height=
"12" fill=
"rgb(204,0,102)">
91 <set id=
"firstSet" attributeName=
"x" to=
"74" begin=
"0s; firstSet.end + 1s" dur=
"1s"/>
96 <g id=
"setTwo" transform=
"translate(0, 25)">
97 <use xlink:
href=
"#shadow" x=
"0"/>
98 <use xlink:
href=
"#shadow" x=
"80"/>
100 <rect x=
"-6" y=
"-6" width=
"12" height=
"12" fill=
"rgb(204,0,102)">
101 <set id=
"secondSet" attributeName=
"x" to=
"74" begin=
"0s; secondSet.end + 1s" dur=
"1s" fill=
"remove"/>
106 <g id=
"setThree" transform=
"translate(0, 100)">
107 <use xlink:
href=
"#shadow" x=
"0"/>
108 <use xlink:
href=
"#shadow" x=
"80"/>
110 <rect x=
"-6" y=
"-6" width=
"12" height=
"12" fill=
"rgb(204,0,102)">
111 <set id=
"thirdSet" attributeName=
"x" to=
"74" begin=
"0s; thirdSet.end + 1s" dur=
"1s" fill=
"freeze"/>
116 <g id=
"setFour" transform=
"translate(0, 125)">
117 <use xlink:
href=
"#shadow" x=
"0"/>
118 <use xlink:
href=
"#shadow" x=
"80"/>
120 <rect x=
"-6" y=
"-6" width=
"12" height=
"12" fill=
"rgb(204,0,102)">
121 <set id=
"fourthSet" attributeName=
"x" to=
"74" begin=
"0s" dur=
"1s" fill=
"freeze"/>