text-style-01d.svg 595 B

12345678910111213141516171819202122232425262728293031
  1. <!--
  2. Any copyright is dedicated to the Public Domain.
  3. http://creativecommons.org/publicdomain/zero/1.0/
  4. -->
  5. <svg xmlns="http://www.w3.org/2000/svg" onload="m();">
  6. <title>Testcase for style changes</title>
  7. <!-- From https://bugzilla.mozilla.org/show_bug.cgi?id=395155 -->
  8. <style id="s" type="text/css">
  9. * { fill: red; }
  10. </style>
  11. <script>
  12. function m()
  13. {
  14. var s = document.getElementById("s");
  15. s.appendChild(document.createTextNode(""));
  16. s.firstChild.data = "tspan { fill: green }";
  17. }
  18. </script>
  19. <text>
  20. <tspan x="10" y="50">
  21. This should be green
  22. </tspan>
  23. </text>
  24. </svg>