summaryrefslogtreecommitdiffstats
path: root/layout/reftests/mathml/stretchy-largeop-2.html
diff options
context:
space:
mode:
Diffstat (limited to 'layout/reftests/mathml/stretchy-largeop-2.html')
-rw-r--r--layout/reftests/mathml/stretchy-largeop-2.html137
1 files changed, 137 insertions, 0 deletions
diff --git a/layout/reftests/mathml/stretchy-largeop-2.html b/layout/reftests/mathml/stretchy-largeop-2.html
new file mode 100644
index 0000000000..c7f40580ec
--- /dev/null
+++ b/layout/reftests/mathml/stretchy-largeop-2.html
@@ -0,0 +1,137 @@
+<!DOCTYPE html>
+<!-- Test that non-stretchy largeops are bigger in display mode -->
+
+<html class="reftest-wait">
+ <head>
+ <title>Largeop stretching</title>
+ <meta charset="utf-8"/>
+ <script type="text/javascript">
+
+ function verifyGreaterThan(aElement, aReference) {
+ /* Verify that the height of the element is greater than that of the
+ reference, and otherwise paint the element in red. */
+ var element = document.getElementById(aElement);
+ var ref = document.getElementById(aReference);
+ if (element.getBoundingClientRect().height -
+ ref.getBoundingClientRect().height <= 1) {
+ element.setAttribute("mathcolor", "red");
+ }
+ }
+
+ function doTest() {
+ /* Ensure that largeops are bigger in displaystyle */
+ var numTests = 10; // zero indexed
+ var opPrefix = "mo";
+ var refPrefix = "moRef";
+ for (var i = 0; i < numTests; i++)
+ {
+ verifyGreaterThan(opPrefix + i, refPrefix + i);
+ }
+ document.documentElement.removeAttribute("class");
+
+ }
+ </script>
+ </head>
+ <body onload="doTest();">
+ <p>
+ <math displaystyle="true">
+ <mo id="mo0">&bigodot;</mo>
+ </math>
+ </p>
+ <p>
+ <math displaystyle="true">
+ <mo id="mo1">&bigoplus;</mo>
+ </math>
+ </p>
+ <p>
+ <math displaystyle="true">
+ <mo id="mo2">&#x2a03;</mo>
+ </math>
+ </p>
+ <p>
+ <math displaystyle="true">
+ <mo id="mo3">&#x2a05;</mo>
+ </math>
+ </p>
+ <p>
+ <math displaystyle="true">
+ <mo id="mo4">&#x2a07;</mo>
+ </math>
+ </p>
+ <p>
+ <math displaystyle="true">
+ <mo id="mo5">&#x2a08;</mo>
+ </math>
+ </p>
+ <p>
+ <math displaystyle="true">
+ <mo id="mo6">&#x2a09;</mo>
+ </math>
+ </p>
+ <p>
+ <math displaystyle="true">
+ <mo id="mo7">&#x2a0a;</mo>
+ </math>
+ </p>
+ <p>
+ <math displaystyle="true">
+ <mo id="mo8">&#x2afc;</mo>
+ </math>
+ </p>
+ <p>
+ <math displaystyle="true">
+ <mo id="mo9">&#x2aff;</mo>
+ </math>
+ </p>
+ <p>
+ <math>
+ <mo id="moRef0">&bigodot;</mo>
+ </math>
+ </p>
+ <p>
+ <math>
+ <mo id="moRef1">&bigoplus;</mo>
+ </math>
+ </p>
+ <p>
+ <math>
+ <mo id="moRef2">&#x2a03;</mo>
+ </math>
+ </p>
+ <p>
+ <math>
+ <mo id="moRef3">&#x2a05;</mo>
+ </math>
+ </p>
+ <p>
+ <math>
+ <mo id="moRef4">&#x2a07;</mo>
+ </math>
+ </p>
+ <p>
+ <math>
+ <mo id="moRef5">&#x2a08;</mo>
+ </math>
+ </p>
+ <p>
+ <math>
+ <mo id="moRef6">&#x2a09;</mo>
+ </math>
+ </p>
+ <p>
+ <math>
+ <mo id="moRef7">&#x2a0a;</mo>
+ </math>
+ </p>
+ <p>
+ <math>
+ <mo id="moRef8">&#x2afc;</mo>
+ </math>
+ </p>
+ <p>
+ <math>
+ <mo id="moRef9">&#x2aff;</mo>
+ </math>
+ </p>
+ </body>
+</html>