layout/reftests/svg/dynamic-clipPath-02.svg

Wed, 31 Dec 2014 13:27:57 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Wed, 31 Dec 2014 13:27:57 +0100
branch
TOR_BUG_3246
changeset 6
8bccb770b82d
permissions
-rw-r--r--

Ignore runtime configuration files generated during quality assurance.

michael@0 1 <!--
michael@0 2 Any copyright is dedicated to the Public Domain.
michael@0 3 http://creativecommons.org/publicdomain/zero/1.0/
michael@0 4 -->
michael@0 5 <svg xmlns="http://www.w3.org/2000/svg" version="1.1"
michael@0 6 class="reftest-wait"
michael@0 7 onload="startTest()"
michael@0 8 xmlns:xlink="http://www.w3.org/1999/xlink">
michael@0 9 <title>Testing that dynamic changes to the clipPathUnits are reflected in the clipPath</title>
michael@0 10
michael@0 11 <defs>
michael@0 12 <clipPath id="clip1" clipPathUnits="objectBoundingBox">
michael@0 13 <rect width=".1" height=".1"/>
michael@0 14 </clipPath>
michael@0 15 </defs>
michael@0 16
michael@0 17 <rect width="100%" height="100%" fill="lime"/>
michael@0 18
michael@0 19 <g transform="scale(1000)">
michael@0 20 <rect x=".2" y=".2" width=".6" height=".6" fill="red" clip-path="url(#clip1)"/>
michael@0 21 </g>
michael@0 22
michael@0 23 <script>
michael@0 24 function startTest() {
michael@0 25 document.addEventListener("MozReftestInvalidate", doTest, false);
michael@0 26 setTimeout(doTest, 4000); // fallback for running outside reftest
michael@0 27 }
michael@0 28
michael@0 29 function doTest() {
michael@0 30 var clip1 = document.getElementById("clip1");
michael@0 31 clip1.clipPathUnits.baseVal = SVGUnitTypes.SVG_UNIT_TYPE_USERSPACEONUSE;
michael@0 32
michael@0 33 document.documentElement.removeAttribute("class");
michael@0 34 }
michael@0 35 </script>
michael@0 36 </svg>

mercurial