Bug 403311 layout/mathml/tests/ : xml pages are not W3C-valid r=karlt
authorFrédéric WANG <fred.wang@free.fr>
Wed, 16 Sep 2009 14:06:39 +1200
changeset 32521 ddcadd5761432adf3d5f495792ab096bd4babc5d
parent 32520 329ff0fcd420c75238f4ec6591b8e745a010b513
child 32522 5c5e2ca2066d15a845e8b704c612187eddb6942f
push idunknown
push userunknown
push dateunknown
reviewerskarlt
bugs403311
milestone1.9.3a1pre
Bug 403311 layout/mathml/tests/ : xml pages are not W3C-valid r=karlt
layout/mathml/tests/all-presentation.xml
layout/mathml/tests/maxwell.xml
layout/mathml/tests/mixing.xml
layout/mathml/tests/stretchy.xml
layout/mathml/tests/symbol.html
layout/mathml/tests/various.xml
--- a/layout/mathml/tests/all-presentation.xml
+++ b/layout/mathml/tests/all-presentation.xml
@@ -43,17 +43,17 @@
    -
    - ***** END LICENSE BLOCK ***** -->
 
 <head>
   <title>Examples of Presentation Markup</title>
 </head>
 <body>
 
-
+<div>
 Testing tensor indices &lt;mmultiscripts&gt;:
 
 <!-- {3 \atop k} R {1 \atop i} {2 \atop j} -->
 <math xmlns="http://www.w3.org/1998/Math/MathML">
 <mmultiscripts>
   <mi>R</mi>
   <mi>i</mi><mi>1</mi>
   <mi>j</mi><mi>2</mi>
@@ -383,13 +383,15 @@ with this &lt;mfrac&gt; hanging here
 
 in the middle of a lot of running text to try to explain what this
 means to those who care to read.
 
 Testing MathML merror, mtext,
 
 <math xmlns="http://www.w3.org/1998/Math/MathML">
 <mtext>This is a text in mtext</mtext>
-<merror>This is a text in merror</merror>
+<merror><mtext>This is a text in merror</mtext></merror>
 </math>
 
+</div>
+
 </body>
 </html>
--- a/layout/mathml/tests/maxwell.xml
+++ b/layout/mathml/tests/maxwell.xml
@@ -34,64 +34,62 @@
    - the provisions above, a recipient may use your version of this file under
    - the terms of any one of the MPL, the GPL or the LGPL.
    -
    - ***** END LICENSE BLOCK ***** -->
 
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1 plus MathML 2.0//EN" 
                "http://www.w3.org/TR/MathML2/dtd/xhtml-math11-f.dtd" [
   <!ENTITY mathml "http://www.w3.org/1998/Math/MathML">
-  <!ENTITY vec "&RightArrow;">
-  <!ENTITY partial "&PartialD;"> 
 ]>
 <html xmlns="http://www.w3.org/1999/xhtml">
 
 <head>
   <title>Maxwell's Equations</title>
 </head>
 
 <body style="background-color: #ffffff">
 <h2>Maxwell's Equations</h2>
 
-<p align='center'>
+<p style="text-align:center">
 <math xmlns='&mathml;'>
   <mstyle displaystyle='true'>
     <mrow>
       <mo>&lbrace;</mo>
       <mtable columnalign='right center left' equalrows='false' equalcolumns='false'>
         <mtr>
           <mtd>
             <mrow>
               <mo>&nabla;</mo>
               <mo>&times;</mo>
               <munderover accent='true'>
                 <mstyle fontweight='bold'>
                   <mi>B</mi>
                 </mstyle>
                 <mrow></mrow>
-                <mo stretchy='true'>&vec;</mo>
+                <mo stretchy='true'>&RightArrow;</mo>
               </munderover>
               <mo>-</mo>
               <mfrac>
                 <mn>1</mn>
                 <mi>c</mi>
               </mfrac>
               <mfrac>
                 <mrow>
-                  <mo>&partial;</mo>
+                  <mo>&PartialD;</mo>
                   <munderover accent='true'>
                     <mstyle fontweight='bold'>
                       <mi>E</mi>
                     </mstyle>
                     <mrow></mrow>
-                    <mo stretchy='true'>&vec;</mo>
+                    <mo stretchy='true'>&RightArrow;</mo>
                   </munderover>
                 </mrow>
                 <mrow>
-                  <mo>&partial;</mo>
+                  <mo>&PartialD;</mo>
                   <mi>t</mi>
                 </mrow>
               </mfrac>
             </mrow>
           </mtd>
           <mtd>
             <mo>=</mo>
           </mtd>
@@ -104,32 +102,32 @@
                 </mrow>
                 <mi>c</mi>
               </mfrac>
               <munderover accent='true'>
                 <mstyle fontweight='bold'>
                   <mi>j</mi>
                 </mstyle>
                 <mrow></mrow>
-                <mo stretchy='true'>&vec;</mo>
+                <mo stretchy='true'>&RightArrow;</mo>
               </munderover>
             </mrow>
           </mtd>
         </mtr>
         <mtr>
           <mtd>
             <mrow>
               <mo>&nabla;</mo>
               <mo>&cdot;</mo>
               <munderover accent='true'>
                 <mstyle fontweight='bold'>
                   <mi>E</mi>
                 </mstyle>
                 <mrow></mrow>
-                <mo stretchy='true'>&vec;</mo>
+                <mo stretchy='true'>&RightArrow;</mo>
               </munderover>
             </mrow>
           </mtd>
           <mtd>
             <mo>=</mo>
           </mtd>
           <mtd>
             <mrow>
@@ -144,65 +142,65 @@
             <mrow>
               <mo>&nabla;</mo>
               <mo>&times;</mo>
               <munderover accent='true'>
                 <mstyle fontweight='bold'>
                   <mi>E</mi>
                 </mstyle>
                 <mrow></mrow>
-                <mo stretchy='true'>&vec;</mo>
+                <mo stretchy='true'>&RightArrow;</mo>
               </munderover>
               <mo>+</mo>
               <mfrac>
                 <mn>1</mn>
                 <mi>c</mi>
               </mfrac>
               <mfrac>
                 <mrow>
-                  <mo>&partial;</mo>
+                  <mo>&PartialD;</mo>
                   <munderover accent='true'>
                     <mstyle fontweight='bold'>
                       <mi>B</mi>
                     </mstyle>
                     <mrow></mrow>
-                    <mo stretchy='true'>&vec;</mo>
+                    <mo stretchy='true'>&RightArrow;</mo>
                   </munderover>
                 </mrow>
                 <mrow>
-                  <mo>&partial;</mo>
+                  <mo>&PartialD;</mo>
                   <mi>t</mi>
                 </mrow>
               </mfrac>
             </mrow>
           </mtd>
           <mtd>
             <mo>=</mo>
           </mtd>
           <mtd>
             <munderover accent='true'>
               <mstyle fontweight='bold'>
                 <mn>0</mn>
               </mstyle>
               <mrow></mrow>
-              <mo stretchy='true'>&vec;</mo>
+              <mo stretchy='true'>&RightArrow;</mo>
             </munderover>
           </mtd>
         </mtr>
         <mtr>
           <mtd>
             <mrow>
               <mo>&nabla;</mo>
               <mo>&cdot;</mo>
               <munderover accent='true'>
                 <mstyle fontweight='bold'>
                   <mi>B</mi>
                 </mstyle>
                 <mrow></mrow>
-                <mo stretchy='true'>&vec;</mo>
+                <mo stretchy='true'>&RightArrow;</mo>
               </munderover>
             </mrow>
           </mtd>
           <mtd>
             <mo>=</mo>
           </mtd>
           <mtd>
             <mn>0</mn>
@@ -211,17 +209,17 @@
       </mtable>
     </mrow>
   </mstyle>
 </math>
 </p>
 
 <h2>Einstein's field equations</h2>
 
-<p align='center'>
+<p style="text-align:center">
 <math xmlns='&mathml;'>
   <mstyle displaystyle='true'>
     <mrow>
       <msubsup>
         <mstyle fontstyle='normal'>
           <mi>R</mi>
         </mstyle>
         <mstyle scriptlevel='1'>
--- a/layout/mathml/tests/mixing.xml
+++ b/layout/mathml/tests/mixing.xml
@@ -55,25 +55,25 @@
       background-color: gold;
       background-image: url(resource:/res/samples/raptor.jpg);
       background-repeat: no-repeat;
       background-attachment: fixed;">
 
 <h2 style="text-align: center; color: blue">
 Mixing MathML markups and other markups to get special effects</h2>
 
-<br />
-
+<div>
 A fraction with the animated throbber as denominator...
 View the source...
 
 <math mode="display" xmlns="http://www.w3.org/1998/Math/MathML">
   <mfrac linethickness="3">
     <mi>a</mi>
-    <html:img src="chrome://communicator/skin/brand/throbber-anim.gif" />
+    <html:img src="chrome://communicator/skin/brand/throbber-anim.gif"
+	      alt="throbber" />
   </mfrac>
 </math>
 
 Fill the gaps in this matrix with input fields
 <math mode="display" xmlns="http://www.w3.org/1998/Math/MathML">
 <mrow>
   <mo>[</mo>
   <mtable>
@@ -174,10 +174,12 @@ And there could be more...
                </mrow> 
             </mstyle> 
          </mfrac>  
       </mrow>
     </math>
   </button>
 </div>
 
+</div>
+
 </body>
 </html>
--- a/layout/mathml/tests/stretchy.xml
+++ b/layout/mathml/tests/stretchy.xml
@@ -43,16 +43,17 @@
 ]>
 <html xmlns="http://www.w3.org/1999/xhtml">
 
 <head>
   <title>Testing stretchy MathML symbols</title>
 </head>
 <body>
 
+<div>
 Testing stretchy symbols -- view the source...
 
 <math xmlns="http://www.w3.org/1998/Math/MathML">
 <msup>
   <mrow>
     <mo symmetric='false' minsize='3'>(</mo>
     <mo>...</mo>
     <msup>
@@ -390,10 +391,12 @@ and elsewhere,
            <mo form="infix">&RightArrow;</mo>
            <mtext> maps to </mtext>
         </mover>
         <mi>y</mi>
 </mrow>
      
 </math>
 
+</div>
+
 </body>
 </html>
--- a/layout/mathml/tests/symbol.html
+++ b/layout/mathml/tests/symbol.html
@@ -1,8 +1,10 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
+      "http://www.w3.org/TR/html4/loose.dtd">
 <html>
 <!-- ***** BEGIN LICENSE BLOCK *****
    - Version: MPL 1.1/GPL 2.0/LGPL 2.1
    -
    - The contents of this file are subject to the Mozilla Public License Version
    - 1.1 (the "License"); you may not use this file except in compliance with
    - the License. You may obtain a copy of the License at
    - http://www.mozilla.org/MPL/
--- a/layout/mathml/tests/various.xml
+++ b/layout/mathml/tests/various.xml
@@ -40,17 +40,17 @@
   "http://www.w3.org/TR/MathML2/dtd/xhtml-math11-f.dtd"
 [
   <!ENTITY mathml "http://www.w3.org/1998/Math/MathML">
 ]>
 <html xmlns="http://www.w3.org/1999/xhtml">
 
 <head>
 <title>Various examples of MathML</title>
-<style>
+<style type="text/css">
 maction {
   background-color: yellow;
 }
 maction:hover  {
   outline: 1px dotted black;
 /*  border: 1px solid black; */
 }
 maction[actiontype="restyle#background"] {
@@ -59,16 +59,17 @@ maction[actiontype="restyle#background"]
 }
 maction[actiontype="restyle#zoom"] {
   font-size: 40pt;
 }
 </style>
 </head>
 <body>
 
+<div>
 Click to toggle between expressions, and watch the satus line onmouseover/onmouseout:
 <br />
 
 <math mode="display" xmlns="&mathml;">
 <maction actiontype="toggle">
   <maction actiontype="statusline#First Expression">
     <mi>statusline#First Expression</mi>
   </maction>
@@ -241,17 +242,17 @@ Click the expression below to see severa
 <!-- {{} \atop i} A {p \atop q} -->
 <mmultiscripts>
     <mi fontweight="bold" fontsize="large">A</mi>
     <mi>q</mi><mi>p</mi>
   <mprescripts/>
     <mi>i</mi><none/>
 </mmultiscripts>
 
-<br />
+<mspace linebreak="newline"/>
 
 <!-- {3 \atop k} R {1 \atop i} {2 \atop j} -->
 <mmultiscripts>
    <mi fontweight="bold">R</mi>
       <mi>i</mi><mi>1</mi>
       <mi>j</mi><mn>230</mn>
       <mi>j</mi><msup><mn>230</mn><mi>y</mi></msup>
       <mi>j</mi><mn>230</mn>
@@ -521,17 +522,17 @@ Click the expression below to see severa
       </mfrac>
    </mrow>
   <mo>=</mo>
   <mn>0</mn>
 </mrow>
 
 
 <mtext>This is a text in mtext</mtext>
-<merror>This is a text in merror</merror>
+<merror><mtext>This is a text in merror</mtext></merror>
 
 <mrow>
   <msub>
      <mi>a</mi>
      <mn>0</mn>
   </msub>
   <mo>+</mo>
   <mfrac>
@@ -587,17 +588,17 @@ Click the expression below to see severa
    <mo>&LeftArrow;</mo>
    <mrow>
       <msub><mi>a</mi><mi>i</mi></msub>
       <mo>*</mo>
       <msub><mi>b</mi><mi>j</mi></msub>
    </mrow>
 </mrow>
 
-<br />
+<mspace linebreak="newline"/>
 
   <mrow> 
       <msup>
          <mi>e</mi>
          <mrow>
             <mi>i</mi>
             <mo>&pi;</mo>
          </mrow>
@@ -626,19 +627,17 @@ Click the expression below to see severa
 </mrow>
 
 <mo>;</mo>
 
 <mrow>
 <mi>t</mi><mo>+=</mo><mi>dt</mi>
 </mrow>
 
-<br /> 
-
-
+<mspace linebreak="newline"/>
 
 <mrow>
       <mi>x</mi>
       <mo>=</mo>
       <mi>a</mi>
       <mo>*</mo>
       <mi>b</mi>
       <mo>+</mo>
@@ -1058,10 +1057,12 @@ And this is from the "Thomson scattering
         </mrow>
       </mtd>
 
     </mtr>
   </mtable>
 </mrow>
 </math>
 
+</div>
+
 </body>
 </html>