Thu, 15 Jan 2015 15:55:04 +0100
Back out 97036ab72558 which inappropriately compared turds to third parties.
michael@0 | 1 | <!doctype html> |
michael@0 | 2 | <html class="reftest-wait"> |
michael@0 | 3 | <head> |
michael@0 | 4 | <title>Dynamic ssty tests</title> |
michael@0 | 5 | <!-- See ssty-1-ref.html for an explanation of this font --> |
michael@0 | 6 | <style type="text/css" media="screen, print"> |
michael@0 | 7 | @font-face { |
michael@0 | 8 | font-family: "sstyfont"; |
michael@0 | 9 | src: url("ssty.woff"); |
michael@0 | 10 | } |
michael@0 | 11 | </style> |
michael@0 | 12 | </head> |
michael@0 | 13 | <body> |
michael@0 | 14 | |
michael@0 | 15 | <math> |
michael@0 | 16 | <mstyle style="font-family: 'sstyfont';"> |
michael@0 | 17 | <mfrac id="mfrac0"> |
michael@0 | 18 | <mo>A</mo> |
michael@0 | 19 | </mfrac> |
michael@0 | 20 | </mstyle> |
michael@0 | 21 | </math> |
michael@0 | 22 | |
michael@0 | 23 | <p> |
michael@0 | 24 | |
michael@0 | 25 | <math> |
michael@0 | 26 | <mstyle style="font-family: 'sstyfont';"> |
michael@0 | 27 | <mfrac> |
michael@0 | 28 | <mo>A</mo> |
michael@0 | 29 | <mo id="mo0"></mo> |
michael@0 | 30 | </mfrac> |
michael@0 | 31 | </mstyle> |
michael@0 | 32 | </math> |
michael@0 | 33 | |
michael@0 | 34 | <p> |
michael@0 | 35 | |
michael@0 | 36 | <math> |
michael@0 | 37 | <mstyle style="font-family: 'sstyfont';"> |
michael@0 | 38 | <mfrac> |
michael@0 | 39 | <mo>A</mo> |
michael@0 | 40 | <mo id="mo1">A</mo> |
michael@0 | 41 | </mfrac> |
michael@0 | 42 | </mstyle> |
michael@0 | 43 | </math> |
michael@0 | 44 | |
michael@0 | 45 | <p> |
michael@0 | 46 | |
michael@0 | 47 | <math> |
michael@0 | 48 | <mstyle style="font-family: 'sstyfont';" id="mstyle0"> |
michael@0 | 49 | </mstyle> |
michael@0 | 50 | </math> |
michael@0 | 51 | |
michael@0 | 52 | <p> |
michael@0 | 53 | |
michael@0 | 54 | <math> |
michael@0 | 55 | <mstyle id="mstyle1"> |
michael@0 | 56 | <mfrac> |
michael@0 | 57 | <mfrac> |
michael@0 | 58 | <mo>A</mo> |
michael@0 | 59 | <mo>A</mo> |
michael@0 | 60 | </mfrac> |
michael@0 | 61 | <mfrac> |
michael@0 | 62 | <mo>A</mo> |
michael@0 | 63 | <mo>A</mo> |
michael@0 | 64 | </mfrac> |
michael@0 | 65 | </mfrac> |
michael@0 | 66 | </mstyle> |
michael@0 | 67 | </math> |
michael@0 | 68 | |
michael@0 | 69 | <p> |
michael@0 | 70 | |
michael@0 | 71 | <math> |
michael@0 | 72 | <mstyle id="mstyle2" style="font-family: 'sstyfont';"> |
michael@0 | 73 | <mfrac> |
michael@0 | 74 | <mfrac> |
michael@0 | 75 | <mo>A</mo> |
michael@0 | 76 | <mo>A</mo> |
michael@0 | 77 | </mfrac> |
michael@0 | 78 | <mfrac> |
michael@0 | 79 | <mo>A</mo> |
michael@0 | 80 | <mo>A</mo> |
michael@0 | 81 | </mfrac> |
michael@0 | 82 | </mfrac> |
michael@0 | 83 | </mstyle> |
michael@0 | 84 | </math> |
michael@0 | 85 | |
michael@0 | 86 | <p> |
michael@0 | 87 | |
michael@0 | 88 | <math> |
michael@0 | 89 | <mstyle id="mstyle3" style="font-family: 'sstyfont';"> |
michael@0 | 90 | <mfrac> |
michael@0 | 91 | <mfrac> |
michael@0 | 92 | <mo>A</mo> |
michael@0 | 93 | <mo>A</mo> |
michael@0 | 94 | </mfrac> |
michael@0 | 95 | <mfrac> |
michael@0 | 96 | <mo>A</mo> |
michael@0 | 97 | <mo>A</mo> |
michael@0 | 98 | </mfrac> |
michael@0 | 99 | </mfrac> |
michael@0 | 100 | </mstyle> |
michael@0 | 101 | </math> |
michael@0 | 102 | |
michael@0 | 103 | <p> |
michael@0 | 104 | |
michael@0 | 105 | <math> |
michael@0 | 106 | <mstyle style="font-family: 'sstyfont';"> |
michael@0 | 107 | <mfrac> |
michael@0 | 108 | <mo>A</mo> |
michael@0 | 109 | <mrow> |
michael@0 | 110 | <mrow> |
michael@0 | 111 | <mrow id="mrow0"> |
michael@0 | 112 | </mrow> |
michael@0 | 113 | </mrow> |
michael@0 | 114 | </mrow> |
michael@0 | 115 | </mfrac> |
michael@0 | 116 | </mstyle> |
michael@0 | 117 | </math> |
michael@0 | 118 | |
michael@0 | 119 | <p> |
michael@0 | 120 | |
michael@0 | 121 | <math> |
michael@0 | 122 | <mstyle id="mstyle4" style ="font-family: 'sstyfont'; -moz-font-feature-settings: 'ssty' 0"> |
michael@0 | 123 | <mfrac> |
michael@0 | 124 | <mfrac> |
michael@0 | 125 | <mo>A</mo> |
michael@0 | 126 | <mo>A</mo> |
michael@0 | 127 | </mfrac> |
michael@0 | 128 | <mfrac> |
michael@0 | 129 | <mo>A</mo> |
michael@0 | 130 | <mo>A</mo> |
michael@0 | 131 | </mfrac> |
michael@0 | 132 | </mfrac> |
michael@0 | 133 | </mstyle> |
michael@0 | 134 | </math> |
michael@0 | 135 | |
michael@0 | 136 | <p> |
michael@0 | 137 | |
michael@0 | 138 | <math> |
michael@0 | 139 | <mstyle id="mstyle5" style ="font-family: 'sstyfont';"> |
michael@0 | 140 | <mfrac> |
michael@0 | 141 | <mfrac> |
michael@0 | 142 | <mo>A</mo> |
michael@0 | 143 | <mo>A</mo> |
michael@0 | 144 | </mfrac> |
michael@0 | 145 | <mfrac> |
michael@0 | 146 | <mo>A</mo> |
michael@0 | 147 | <mo>A</mo> |
michael@0 | 148 | </mfrac> |
michael@0 | 149 | </mfrac> |
michael@0 | 150 | </mstyle> |
michael@0 | 151 | </math> |
michael@0 | 152 | |
michael@0 | 153 | <script> |
michael@0 | 154 | function doTest() |
michael@0 | 155 | { |
michael@0 | 156 | var mo = document.createElementNS("http://www.w3.org/1998/Math/MathML", "mo"); |
michael@0 | 157 | mo.innerHTML = "A"; |
michael@0 | 158 | // An added child gets ssty font feature |
michael@0 | 159 | document.getElementById("mfrac0").appendChild(mo); |
michael@0 | 160 | // A child with changed text gets ssty font feature |
michael@0 | 161 | document.getElementById("mo0").innerHTML = "A"; |
michael@0 | 162 | // A relocated child loses ssty font feature setting |
michael@0 | 163 | document.getElementById("mstyle0").appendChild(document.getElementById("mo1")); |
michael@0 | 164 | // A change in style |
michael@0 | 165 | document.getElementById("mstyle1").setAttribute("style", "font-family: 'sstyfont';"); |
michael@0 | 166 | // Changes in script size multiplier affect ssty setting |
michael@0 | 167 | document.getElementById("mstyle2").setAttribute("scriptsizemultiplier", "1.2"); |
michael@0 | 168 | document.getElementById("mstyle3").setAttribute("scriptsizemultiplier", "0.8"); |
michael@0 | 169 | |
michael@0 | 170 | // ssty gets added to descendants as well |
michael@0 | 171 | var mo1 = document.createElementNS("http://www.w3.org/1998/Math/MathML", "mo"); |
michael@0 | 172 | mo1.innerHTML = "A"; |
michael@0 | 173 | document.getElementById("mrow0").appendChild(mo1); |
michael@0 | 174 | // removing explicit ssty setting works |
michael@0 | 175 | document.getElementById("mstyle4").setAttribute( |
michael@0 | 176 | "style", "font-family: 'sstyfont';") |
michael@0 | 177 | // setting an explicit ssty font feature |
michael@0 | 178 | document.getElementById("mstyle5").setAttribute( |
michael@0 | 179 | "style" , "font-family: 'sstyfont'; -moz-font-feature-settings: 'ssty' 0") |
michael@0 | 180 | |
michael@0 | 181 | document.documentElement.removeAttribute("class"); |
michael@0 | 182 | } |
michael@0 | 183 | window.addEventListener("MozReftestInvalidate", doTest, false); |
michael@0 | 184 | </script> |
michael@0 | 185 | </body> |
michael@0 | 186 | </html> |