Debian Codegraph @

samples/tests/spec/filters/svgEnableBackground.svg

raw
1 <?xml version="1.0" standalone="no"?>
2 <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN"
3 "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd" >
4
5 <!--
6 Licensed to the Apache Software Foundation (ASF) under one or more
7 contributor license agreements. See the NOTICE file distributed with
8 this work for additional information regarding copyright ownership.
9 The ASF licenses this file to You under the Apache License, Version 2.0
10 (the "License"); you may not use this file except in compliance with
11 the License. You may obtain a copy of the License at
12
13 http://www.apache.org/licenses/LICENSE-2.0
14
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.
20 -->
21
22 <!-- ========================================================================= -->
23 <!-- @author [email protected] -->
24 <!-- @version $Id $ -->
25 <!-- ========================================================================= -->
26
27
28 <?xml-stylesheet type="text/css" href="../../resources/style/test.css" ?>
29
30
31 <svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" id="body" width="450" height="500" viewBox="0 0 450 500">
32 <title>
33 enable-background Test on&lt;
34 svg>
35 </title>
36
37 <!-- ============================================================= -->
38 <!-- Test content -->
39 <!-- ============================================================= -->
40 <g id="testContent">
41
42 <text x="225" y="40" class="title">
43 Enable-Background Test on&lt;
44 svg>
45 </text>
46
47 <g transform="translate(0, 60)">
48 <defs>
49 <g id="uglyBlobs">
50 <circle id="Circle1" cx="20" cy="65" r="15"
51 style="fill:orange"/>
52
53 <circle id="Circle2" cx="40" cy="55" r="15" style="fill:red"/>
54
55 <rect id="Rect1" x="20" y="35" width="15" height="70"
56 style="fill:DarkBlue"/>
57
58 <rect id="Rect2" x="30" y="15" width="15" height="70"
59 rx="10" ry="10" style="fill:Yellow"/>
60 </g>
61
62 <filter id="OffsetBGX" filterUnits="userSpaceOnUse" x="0" y="0"
63 width="120" height="120">
64 <feOffset in="BackgroundImage" dx="60" dy="0"/>
65 </filter>
66
67 <filter id="OffsetBGY" filterUnits="userSpaceOnUse" x="0" y="0"
68 width="440" height="260">
69 <feOffset in="BackgroundImage" dx="0" dy="140"/>
70 </filter>
71 </defs>
72
73 <g transform="translate(0 40)" class="legend">
74
75 <!-- ============================================== -->
76 <!-- Enable Background_1_* -->
77 <!-- ============================================== -->
78 <svg class="row1" width="421" height="400"
79 style="enable-background:new 19 30 403 60">
80
81 <g transform="translate(20 0)"
82 style="enable-background:new;">
83 <rect x="0" y="0" width="60" height="120"
84 style="fill:Beige"/>
85
86 <use xlink:href="#uglyBlobs"/>
87 <rect x="0" y="0" width="1" height="1"
88 style="filter:url(#OffsetBGX)"/>
89
90 <rect x="0" y="0" width="60" height="120"
91 style="fill:none; stroke:black; stroke-width:2"/>
92 <rect x="60" y="0" width="60" height="120"
93 style="fill:none; stroke:black; stroke-width:2"/>
94 <g transform="translate(60, 135)">
95 <text x="0" y="0" style="text-anchor:middle">
96 Left Copied to right
97 </text>
98 </g>
99 </g>
100
101 <g transform="translate(160 0)">
102 <line x1="-5" y1="20" x2="125" y2="45"
103 style="stroke-width:5; stroke:#AA3333"/>
104
105 <line x1="-5" y1="100" x2="125" y2="75"
106 style="stroke-width:5; stroke:#AA3333"/>
107
108 <g style="enable-background:new">
109 <rect x="0" y="0" width="60" height="120"
110 style="fill:Beige"/>
111 <g style="opacity: 0.75">
112 <rect x="5" y="5" width="50" height="50"
113 style="fill:deepPink"/>
114 <use xlink:href="#uglyBlobs"
115 style="opacity:0.75"/>
116 <rect x="0" y="0" width="120" height="120"
117 style="filter:url(#OffsetBGX)"/>
118 </g>
119 </g>
120
121 <rect x="0" y="0" width="60" height="120"
122 style="fill:none; stroke:black; stroke-width:2"/>
123 <rect x="60" y="0" width="60" height="120"
124 style="fill:none; stroke:black; stroke-width:2"/>
125 <g transform="translate(60, 135)">
126 <text x="0" y="0" style="text-anchor:middle">
127 Right is transparent
128 </text>
129 </g>
130 </g>
131
132 <g transform="translate(300 0)">
133 <line x1="-5" y1="20" x2="125" y2="45"
134 style="stroke-width:5; stroke:#AA3333"/>
135
136 <line x1="-5" y1="100" x2="125" y2="75"
137 style="stroke-width:5; stroke:#AA3333"/>
138
139 <rect x="0" y="0" width="60" height="120"
140 style="fill:Beige"/>
141 <g style="enable-background:new">
142 <ellipse cx="25" cy="45" rx="20" ry="30"
143 style="fill:#AA00CC"/>
144
145 <g style="opacity: 0.75">
146 <use xlink:href="#uglyBlobs"/>
147 <rect x="0" y="0" width="120" height="120"
148 style="filter:url(#OffsetBGX)"/>
149 </g>
150 </g>
151
152 <rect x="0" y="0" width="60" height="120"
153 style="fill:none; stroke:black; stroke-width:2"/>
154 <rect x="60" y="0" width="60" height="120"
155 style="fill:none; stroke:black; stroke-width:2"/>
156 <g transform="translate(60, 135)">
157 <text x="0" y="0" style="text-anchor:middle">
158 Blobs opaquely merged w/ oval
159 </text>
160 </g>
161 </g>
162
163 <!-- ============================================== -->
164 <!-- BGEnable _2_* -->
165 <!-- ============================================== -->
166 <rect x="0" y="0" width="10" height="10"
167 style="filter:url(#OffsetBGY)"/>
168
169 <g transform="translate(220, 270)">
170 <text x="0" y="0" style="text-anchor:middle">
171 Copy of middle of first row (by setting
172 enable-background bounds)
173 </text>
174 </g>
175 </svg>
176
177
178
179
180 </g>
181 </g>
182 </g>
183
184 <!-- ============================================================= -->
185 <!-- Batik sample mark -->
186 <!-- ============================================================= -->
187 <use xlink:href="../../../batikLogo.svg#Batik_Tag_Box"/>
188
189 </svg>