Bug 719286 - Tests for objectfill and objectstroke paint values r=roc
@ -3,3 +3,7 @@ pref(gfx.font_rendering.opentype_svg.enabled,true) == svg-glyph-basic.svg svg
|
||||
pref(gfx.font_rendering.opentype_svg.enabled,false) != svg-glyph-positioning.svg svg-glyph-positioning-ref.svg
|
||||
pref(gfx.font_rendering.opentype_svg.enabled,true) == svg-glyph-positioning.svg svg-glyph-positioning-ref.svg
|
||||
pref(gfx.font_rendering.opentype_svg.enabled,true) == svg-glyph-invalid.html svg-glyph-invalid-ref.html
|
||||
pref(gfx.font_rendering.opentype_svg.enabled,true) == svg-glyph-objectfill-solid.svg svg-glyph-objectfill-solid-ref.svg
|
||||
pref(gfx.font_rendering.opentype_svg.enabled,true) == svg-glyph-objectstroke-solid.svg svg-glyph-objectstroke-solid-ref.svg
|
||||
pref(gfx.font_rendering.opentype_svg.enabled,true) == svg-glyph-objectgradient.svg svg-glyph-objectgradient-ref.svg
|
||||
pref(gfx.font_rendering.opentype_svg.enabled,true) == svg-glyph-objectpattern.svg svg-glyph-objectpattern-ref.svg
|
||||
|
@ -0,0 +1,4 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg">
|
||||
<rect x="20" y="20" width="160" height="160" fill="turquoise" />
|
||||
<rect x="10" y="210" width="180" height="180" fill="thistle" />
|
||||
</svg>
|
After Width: | Height: | Size: 181 B |
@ -0,0 +1,27 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg">
|
||||
<!--
|
||||
Test that solid colors are inherited when using the objectFill
|
||||
paint server value in SVG glyphs
|
||||
-->
|
||||
|
||||
<style type="text/css">
|
||||
<![CDATA[
|
||||
@font-face {
|
||||
font-family: "Liberation";
|
||||
src:url(resources/svg.woff);
|
||||
}
|
||||
text
|
||||
{
|
||||
font-family: Liberation;
|
||||
font-size: 200px;
|
||||
}
|
||||
]]>
|
||||
</style>
|
||||
|
||||
<text fill="turquoise" x="0" y="200">
|
||||
N
|
||||
</text>
|
||||
<text fill="thistle" x="0" y="400">
|
||||
O
|
||||
</text>
|
||||
</svg>
|
After Width: | Height: | Size: 527 B |
@ -0,0 +1,25 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg">
|
||||
|
||||
<defs>
|
||||
<linearGradient id="grad" x1="0" y1="0" x2="800" y2="800" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="purple" offset="0%" />
|
||||
<stop stop-color="lime" offset="100%" />
|
||||
</linearGradient>
|
||||
<radialGradient id="grad2" cx="250" cy="400" r="400" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="red" offset="0%" />
|
||||
<stop stop-color="blue" offset="100%" />
|
||||
</radialGradient>
|
||||
</defs>
|
||||
|
||||
<rect x="20" y="20" width="160" height="160" stroke="none"
|
||||
fill="url(#grad)" />
|
||||
|
||||
<rect x="310" y="10" width="180" height="180" fill="url(#grad)"
|
||||
stroke="none" />
|
||||
|
||||
<rect x="20" y="320" width="160" height="160" fill="burlywood"
|
||||
stroke="url(#grad2)" stroke-width="10" />
|
||||
|
||||
<rect x="310" y="310" width="180" height="180" fill="url(#grad2)"
|
||||
stroke="url(#grad)" stroke-width="20" />
|
||||
</svg>
|
After Width: | Height: | Size: 893 B |
36
layout/reftests/text-svgglyphs/svg-glyph-objectgradient.svg
Normal file
@ -0,0 +1,36 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg">
|
||||
<!--
|
||||
Test that gradients are inherited from the outer object when using
|
||||
the objectFill and objectStroke paint server values in SVG glyphs
|
||||
-->
|
||||
|
||||
<style type="text/css"><![CDATA[
|
||||
@font-face {
|
||||
font-family: "Liberation";
|
||||
src:url("resources/svg.woff") format("woff");
|
||||
}
|
||||
|
||||
text {
|
||||
font-family: "Liberation";
|
||||
font-size: 200px;
|
||||
stroke-width: 5;
|
||||
}
|
||||
]]></style>
|
||||
|
||||
<defs>
|
||||
<linearGradient id="grad" x1="0" y1="0" x2="800" y2="800" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="purple" offset="0%" />
|
||||
<stop stop-color="lime" offset="100%" />
|
||||
</linearGradient>
|
||||
<radialGradient id="grad2" cx="250" cy="400" r="400" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="red" offset="0%" />
|
||||
<stop stop-color="blue" offset="100%" />
|
||||
</radialGradient>
|
||||
|
||||
</defs>
|
||||
|
||||
<text x="0" y="200" fill="url(#grad)" stroke="url(#grad2)">N</text>
|
||||
<text x="300" y="200" fill="url(#grad)" stroke="url(#grad2)">O</text>
|
||||
<text x="0" y="500" fill="url(#grad)" stroke="url(#grad2)">P</text>
|
||||
<text x="300" y="500" fill="url(#grad)" stroke="url(#grad2)">Q</text>
|
||||
</svg>
|
After Width: | Height: | Size: 1.2 KiB |
@ -0,0 +1,25 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg">
|
||||
|
||||
<defs>
|
||||
<pattern id="pat" x="0" y="0" width="50" height="50" patternUnits="userSpaceOnUse">
|
||||
<rect x="5" y="5" width="30" height="30" stroke="salmon" stroke-width="5"
|
||||
fill="mistyrose" />
|
||||
</pattern>
|
||||
<pattern id="pat2" x="0" y="0" width="20" height="20" patternUnits="userSpaceOnUse">
|
||||
<rect x="5" y="5" width="10" height="10" stroke="lavenderblush" stroke-width="2"
|
||||
fill="lemonchiffon" />
|
||||
</pattern>
|
||||
</defs>
|
||||
|
||||
<rect x="20" y="20" width="160" height="160" stroke="none"
|
||||
fill="url(#pat)" />
|
||||
|
||||
<rect x="310" y="10" width="180" height="180" fill="url(#pat)"
|
||||
stroke="none" />
|
||||
|
||||
<rect x="20" y="320" width="160" height="160" fill="burlywood"
|
||||
stroke="url(#pat2)" stroke-width="10" />
|
||||
|
||||
<rect x="310" y="310" width="180" height="180" fill="url(#pat2)"
|
||||
stroke="url(#pat)" stroke-width="20" />
|
||||
</svg>
|
After Width: | Height: | Size: 909 B |
35
layout/reftests/text-svgglyphs/svg-glyph-objectpattern.svg
Normal file
@ -0,0 +1,35 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg">
|
||||
<!--
|
||||
Test that patterns are inherited from the outer object when using
|
||||
the objectFill and objectStroke paint server values in SVG glyphs
|
||||
-->
|
||||
|
||||
<style type="text/css"><![CDATA[
|
||||
@font-face {
|
||||
font-family: "Liberation";
|
||||
src:url("resources/svg.woff") format("woff");
|
||||
}
|
||||
|
||||
text {
|
||||
font-family: "Liberation";
|
||||
font-size: 200px;
|
||||
stroke-width: 5;
|
||||
}
|
||||
]]></style>
|
||||
|
||||
<defs>
|
||||
<pattern id="pat" x="0" y="0" width="50" height="50" patternUnits="userSpaceOnUse">
|
||||
<rect x="5" y="5" width="30" height="30" stroke="salmon" stroke-width="5"
|
||||
fill="mistyrose" />
|
||||
</pattern>
|
||||
<pattern id="pat2" x="0" y="0" width="20" height="20" patternUnits="userSpaceOnUse">
|
||||
<rect x="5" y="5" width="10" height="10" stroke="lavenderblush" stroke-width="2"
|
||||
fill="lemonchiffon" />
|
||||
</pattern>
|
||||
</defs>
|
||||
|
||||
<text x="0" y="200" fill="url(#pat)" stroke="url(#pat2)">N</text>
|
||||
<text x="300" y="200" fill="url(#pat)" stroke="url(#pat2)">O</text>
|
||||
<text x="0" y="500" fill="url(#pat)" stroke="url(#pat2)">P</text>
|
||||
<text x="300" y="500" fill="url(#pat)" stroke="url(#pat2)">Q</text>
|
||||
</svg>
|
After Width: | Height: | Size: 1.2 KiB |
@ -0,0 +1,6 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg">
|
||||
<rect x="20" y="20" width="160" height="160"
|
||||
stroke-width="10" stroke="cornflowerblue" fill="burlywood" />
|
||||
<rect x="10" y="210" width="180" height="180"
|
||||
stroke-width="20" stroke="blanchedalmond" fill="darkolivegreen" />
|
||||
</svg>
|
After Width: | Height: | Size: 280 B |
@ -0,0 +1,27 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg">
|
||||
<!--
|
||||
Test that solid colors are inherited when using the objectStroke
|
||||
paint server value in SVG glyphs
|
||||
-->
|
||||
|
||||
<style type="text/css">
|
||||
<![CDATA[
|
||||
@font-face {
|
||||
font-family: "Liberation";
|
||||
src:url(resources/svg.woff);
|
||||
}
|
||||
text
|
||||
{
|
||||
font-family: Liberation;
|
||||
font-size: 200px;
|
||||
}
|
||||
]]>
|
||||
</style>
|
||||
|
||||
<text stroke="cornflowerblue" x="0" y="200">
|
||||
P
|
||||
</text>
|
||||
<text fill="blanchedalmond" stroke="darkolivegreen" x="0" y="400">
|
||||
Q
|
||||
</text>
|
||||
</svg>
|
After Width: | Height: | Size: 567 B |