tor-browser

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

2d.text.fontVariantCaps.after.reset.font.html (828B)


      1 <!DOCTYPE html>
      2 <!-- DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. -->
      3 <meta charset="UTF-8">
      4 <link rel="match" href="2d.text.fontVariantCaps.after.reset.font-expected.html">
      5 <title>Canvas test: 2d.text.fontVariantCaps.after.reset.font</title>
      6 <h1>2d.text.fontVariantCaps.after.reset.font</h1>
      7 <p class="desc">Testing if the fontVariantCaps is reset after font change</p>
      8 <canvas id="canvas" width="300" height="300">
      9  <p class="fallback">FAIL (fallback content)</p>
     10 </canvas>
     11 <script>
     12  const canvas = document.getElementById("canvas");
     13  const ctx = canvas.getContext('2d');
     14 
     15  ctx.font = "32px serif";
     16  ctx.fontVariantCaps = "small-caps";
     17 
     18  ctx.font = "31px serif";
     19  ctx.fillText("Hello World", 20, 40);
     20  ctx.fontVariantCaps = "small-caps";
     21  ctx.fillText("Hello World", 20, 80);
     22 </script>