tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

mathvariant-5.html (2388B)


      1 <!DOCTYPE html>
      2 <html class="reftest-wait">
      3  <head>
      4    <title>Dynamic mathvariant tests</title>
      5    <link rel="match" href="mathvariant-5-ref.html"/>
      6  </head>
      7  <body>
      8    <math>
      9      <mrow>
     10        <mi id="Mi0">A</mi>
     11        <mi id="Mi1">A</mi>
     12        <mi id="Mi2">AA</mi>
     13        <mi id="Mi3" mathvariant="fraktur">A</mi>
     14        <mi id="Mi4" mathvariant="monospace">A</mi>
     15        <mtext id="Mtext0" mathvariant="monospace">A</mtext>
     16        <mtext id="Mtext2" mathvariant="monospace">A</mtext>
     17        <mtext id="Mtext4">A</mtext>
     18      </mrow>
     19    </math>
     20 
     21    <p>
     22 
     23    <math>
     24      <mrow>
     25        <mstyle id="Mstyle0">
     26          <mtext>Hello</mtext>
     27        </mstyle>
     28        <mstyle id="Mstyle1" mathvariant="bold-fraktur">
     29          <mtext>Hello</mtext>
     30        </mstyle>
     31        <mstyle id="Mstyle2" mathvariant="bold">
     32          <mtext>Hello</mtext>
     33        </mstyle>
     34      </mrow>
     35    </math>
     36 
     37    <p>
     38 
     39    <math id="Math0">
     40      <mtext>Hello</mtext>
     41    </math>
     42    <math id="Math1" mathvariant="fraktur">
     43      <mtext>Hello</mtext>
     44    </math>
     45    <math id="Math2" mathvariant="bold">
     46      <mtext>Hello</mtext>
     47    </math>
     48    <script>
     49      function doTest()
     50      {
     51      document.getElementById("Mi0").setAttribute("mathvariant", "script");
     52      document.getElementById("Mi1").innerHTML = "BB";
     53      document.getElementById("Mi2").innerHTML = "B";
     54      document.getElementById("Mi3").removeAttribute("mathvariant");
     55      document.getElementById("Mi4").setAttribute("mathvariant", "script");
     56      document.getElementById("Mtext0").removeAttribute("mathvariant");
     57      document.getElementById("Mtext2").setAttribute("mathvariant", "script");
     58      document.getElementById("Mtext4").setAttribute("mathvariant", "script");
     59      document.getElementById("Mstyle0").setAttribute("mathvariant", "fraktur");
     60      document.getElementById("Mstyle1").setAttribute("mathvariant", "monospace");
     61      document.getElementById("Mstyle2").removeAttribute("mathvariant");
     62      document.getElementById("Math0").setAttribute("mathvariant", "fraktur");
     63      document.getElementById("Math1").setAttribute("mathvariant", "monospace");
     64      document.getElementById("Math2").removeAttribute("mathvariant");
     65 
     66      document.documentElement.removeAttribute("class");
     67      }
     68      document.documentElement.addEventListener("TestRendered", doTest);
     69    </script>
     70  </body>
     71 </html>