| 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 |
|
| 7 |
Licensed to the Apache Software Foundation (ASF) under one or more |
| 8 |
contributor license agreements. See the NOTICE file distributed with |
| 9 |
this work for additional information regarding copyright ownership. |
| 10 |
The ASF licenses this file to You under the Apache License, Version 2.0 |
| 11 |
(the "License"); you may not use this file except in compliance with |
| 12 |
the License. You may obtain a copy of the License at |
| 13 |
|
| 14 |
http://www.apache.org/licenses/LICENSE-2.0 |
| 15 |
|
| 16 |
Unless required by applicable law or agreed to in writing, software |
| 17 |
distributed under the License is distributed on an "AS IS" BASIS, |
| 18 |
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 19 |
See the License for the specific language governing permissions and |
| 20 |
limitations under the License. |
| 21 |
|
| 22 |
--> |
| 23 |
<!-- ====================================================================== --> |
| 24 |
<!-- @author [email protected] --> |
| 25 |
<!-- @author [email protected] --> |
| 26 |
<!-- @version $Id$ --> |
| 27 |
<!-- ====================================================================== --> |
| 28 |
<?xml-stylesheet type="text/css" href="../../resources/style/test.css" ?> |
| 29 |
|
| 30 |
<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"> |
| 31 |
|
| 32 |
<title><linearGradient> Repeat Test</title> |
| 33 |
<text class="title" x="50%" y="40"> |
| 34 |
<linearGradient> Repeat Test |
| 35 |
</text> |
| 36 |
|
| 37 |
<style type="text/css"><![CDATA[ |
| 38 |
.speed { clip-path:url(#speedClip); color-rendering:optimizeSpeed; } |
| 39 |
.default { clip-path:url(#defaultClip); color-rendering:auto; } |
| 40 |
.quality { clip-path:url(#qualityClip); |
| 41 |
color-rendering:optimizeQuality; } |
| 42 |
.saqLabel { font-family: Verdana, Helvetica; |
| 43 |
font-size: 5; |
| 44 |
text-anchor: middle; |
| 45 |
fill:black; stroke:none;} |
| 46 |
.line { fill:none; stroke:black; stroke-width:0.25; } |
| 47 |
]]></style> |
| 48 |
|
| 49 |
<defs> |
| 50 |
<!-- Shape filled by linear gradients --> |
| 51 |
<g id="testShape"> |
| 52 |
<rect x="-25" y="-20" width="50" height="40" |
| 53 |
class="quality" /> |
| 54 |
<rect x="-25" y="-20" width="50" height="40" |
| 55 |
class="default" /> |
| 56 |
<rect x="-25" y="-20" width="50" height="40" |
| 57 |
class="speed" /> |
| 58 |
|
| 59 |
<text x="-16.5" y="24" class="saqLabel">Q</text> |
| 60 |
<line x1="-8" x2="-8" y1="20" y2="25" class="line" /> |
| 61 |
<text x="0" y="24" class="saqLabel">A</text> |
| 62 |
<line x1="8" x2="8" y1="20" y2="25" class="line" /> |
| 63 |
<text x="16.5" y="24" class="saqLabel">S</text> |
| 64 |
</g> |
| 65 |
|
| 66 |
<!-- Clip paths for the various color-rendering settings... --> |
| 67 |
<clipPath id="qualityClip"> |
| 68 |
<rect x="-25" y="-20" width="17" height="40"/> |
| 69 |
</clipPath> |
| 70 |
|
| 71 |
<clipPath id="defaultClip"> |
| 72 |
<rect x="-8" y="-20" width="16" height="40"/> |
| 73 |
</clipPath> |
| 74 |
|
| 75 |
<clipPath id="speedClip"> |
| 76 |
<rect x="8" y="-20" width="17" height="40"/> |
| 77 |
</clipPath> |
| 78 |
|
| 79 |
<!-- ========================================== --> |
| 80 |
<!-- Two gradients, one with no values defined --> |
| 81 |
<!-- and one with the default values specified --> |
| 82 |
<!-- They should create the same pattern --> |
| 83 |
<!-- ========================================== --> |
| 84 |
<linearGradient id="lgDefaults" spreadMethod="repeat"> |
| 85 |
<stop offset=".0" stop-color="gold" /> |
| 86 |
<stop offset=".49" stop-color="crimson" /> |
| 87 |
<stop offset=".51" stop-color="gold" /> |
| 88 |
<stop offset="1." stop-color="crimson" /> |
| 89 |
</linearGradient> |
| 90 |
|
| 91 |
<linearGradient id="lgUR" xlink:href="#lgDefaults" |
| 92 |
x1="25%" x2="75%" y1="75%" y2="25%"/> |
| 93 |
|
| 94 |
<linearGradient id="lgU" xlink:href="#lgDefaults" |
| 95 |
x1="25%" x2="25%" y1="75%" y2="25%"/> |
| 96 |
|
| 97 |
<linearGradient id="lgUL" xlink:href="#lgDefaults" |
| 98 |
x1="75%" x2="25%" y1="75%" y2="25%"/> |
| 99 |
|
| 100 |
<linearGradient id="lgL" xlink:href="#lgDefaults" |
| 101 |
x1="75%" x2="25%" y1="25%" y2="25%"/> |
| 102 |
|
| 103 |
<linearGradient id="lgDL" xlink:href="#lgDefaults" |
| 104 |
x1="75%" x2="25%" y1="25%" y2="75%"/> |
| 105 |
|
| 106 |
<linearGradient id="lgD" xlink:href="#lgDefaults" |
| 107 |
x1="25%" x2="25%" y1="25%" y2="75%"/> |
| 108 |
|
| 109 |
<linearGradient id="lgDR" xlink:href="#lgDefaults" |
| 110 |
x1="25%" x2="75%" y1="25%" y2="75%"/> |
| 111 |
|
| 112 |
<linearGradient id="lgR" xlink:href="#lgDefaults" |
| 113 |
x1="25%" x2="75%" y1="25%" y2="25%"/> |
| 114 |
</defs> |
| 115 |
<g transform="translate(70, 110) scale(2)" font-size="8"> |
| 116 |
<g transform="translate(0, 0)" text-anchor="middle"> |
| 117 |
|
| 118 |
<g transform="translate(0, 0)"> |
| 119 |
<use xlink:href="#testShape" fill="url(#lgR)" /> |
| 120 |
<text y="-23">Right</text> |
| 121 |
</g> |
| 122 |
|
| 123 |
<g transform="translate(0, 55)"> |
| 124 |
<use xlink:href="#testShape" fill="url(#lgUR)" /> |
| 125 |
<text y="-23">Up Right</text> |
| 126 |
</g> |
| 127 |
|
| 128 |
<g transform="translate(0, 110)"> |
| 129 |
<use xlink:href="#testShape" fill="url(#lgU)" /> |
| 130 |
<text y="-23">Up</text> |
| 131 |
</g> |
| 132 |
|
| 133 |
<g transform="translate(0, 165)"> |
| 134 |
<use xlink:href="#testShape" fill="url(#lgUL)" /> |
| 135 |
<text y="-23">Up Left</text> |
| 136 |
</g> |
| 137 |
</g> |
| 138 |
<g transform="translate(70, 0)" text-anchor="middle"> |
| 139 |
|
| 140 |
<g transform="translate(0, 0)"> |
| 141 |
<use xlink:href="#testShape" fill="url(#lgL)" /> |
| 142 |
<text y="-23">Left</text> |
| 143 |
</g> |
| 144 |
|
| 145 |
<g transform="translate(0, 55)"> |
| 146 |
<use xlink:href="#testShape" fill="url(#lgDL)" /> |
| 147 |
<text y="-23">Down Left</text> |
| 148 |
</g> |
| 149 |
|
| 150 |
<g transform="translate(0, 110)"> |
| 151 |
<use xlink:href="#testShape" fill="url(#lgD)" /> |
| 152 |
<text y="-23">Down</text> |
| 153 |
</g> |
| 154 |
|
| 155 |
<g transform="translate(0, 165)"> |
| 156 |
<use xlink:href="#testShape" fill="url(#lgDR)" /> |
| 157 |
<text y="-23">Down Right</text> |
| 158 |
</g> |
| 159 |
</g> |
| 160 |
</g> |
| 161 |
</svg> |