OLD | NEW |
1 | 1 |
2 <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 400 300" version="1.1"> | 2 <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 400 300" version="1.1"> |
3 <defs> | 3 <defs> |
4 <g id="g" transform="translate(0 50)"> | 4 <g id="g" transform="translate(0 50)"> |
5 <rect id="rect" stroke-width="5px" fill="red" stroke="navy" width="60" hei
ght="10"> | 5 <rect id="rect" stroke-width="5px" fill="red" stroke="navy" width="60" hei
ght="10"> |
6 <html xmlns="http://www.w3.org/1999/xhtml"> | 6 <html xmlns="http://www.w3.org/1999/xhtml"> |
7 <head> | 7 <head> |
8 <title>Syntax and parsing</title> | 8 <title>Syntax and parsing</title> |
9 <meta content="" /> | 9 <meta content="" /> |
10 <link href="" /> | 10 <link href="" /> |
(...skipping 14 matching lines...) Expand all Loading... |
25 </mat:notprsubset> | 25 </mat:notprsubset> |
26 </g> | 26 </g> |
27 </defs> | 27 </defs> |
28 <use x="25" y="25" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="#g"/
> | 28 <use x="25" y="25" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="#g"/
> |
29 <use x="125" y="25" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="#g"
/> | 29 <use x="125" y="25" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="#g"
/> |
30 <text>Survived the crash!</text> | 30 <text>Survived the crash!</text> |
31 <script> | 31 <script> |
32 // | 32 // |
33 | 33 |
34 var useElement = document.getElementsByTagName("use")[1]; | 34 var useElement = document.getElementsByTagName("use")[1]; |
35 var element = useElement.instanceRoot.correspondingElement; | 35 var element = document.getElementById("g"); |
36 | 36 |
37 element.setAttribute("transform", ""); | 37 element.setAttribute("transform", ""); |
38 | 38 |
39 if (window.testRunner) | 39 if (window.testRunner) |
40 testRunner.dumpAsText(); | 40 testRunner.dumpAsText(); |
41 | 41 |
42 </script></svg> | 42 </script></svg> |
OLD | NEW |