Skip to content

Commit

Permalink
Fix broken MathML tags
Browse files Browse the repository at this point in the history
The OpenGL documentation mixes MathML content markup with presentation markup,
which MathJax cannot deal with. Replacing content markup with equivalent
presentation markup fixes the issue.
  • Loading branch information
reima committed Aug 5, 2015
1 parent 2e6fa9a commit ab1e3cb
Show file tree
Hide file tree
Showing 33 changed files with 341 additions and 323 deletions.
8 changes: 4 additions & 4 deletions el3/acos.xhtml
Original file line number Diff line number Diff line change
Expand Up @@ -44,13 +44,13 @@
<mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll"><mml:mi mathvariant="italic">x</mml:mi></mml:math>.
The range of values returned by <code class="function">acos</code> is
<mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll">
<mml:list order="numeric">
<mml:mfenced open="[" close="]">
<mml:mn>0</mml:mn>
<mml:pi definitionURL="" encoding=""/>
</mml:list>
<mml:mi>π</mml:mi>
</mml:mfenced>
</mml:math>.
The result is undefined if
<mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll"><mml:apply><mml:gt definitionURL="" encoding=""/><mml:apply><mml:abs definitionURL="" encoding=""/><mml:mi mathvariant="italic">x</mml:mi></mml:apply><mml:mn>1</mml:mn></mml:apply></mml:math>.
<mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll"><mml:mo>|</mml:mo><mml:mi mathvariant="italic">x</mml:mi><mml:mo>|</mml:mo><mml:mo>&gt;</mml:mo><mml:mn>1</mml:mn></mml:math>.
</p>
</div>
{$pipelinestall}{$examples}
Expand Down
2 changes: 1 addition & 1 deletion el3/acosh.xhtml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
<code class="function">acosh</code> returns the arc hyperbolic cosine of
<mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll"><mml:mi mathvariant="italic">x</mml:mi></mml:math>;
the non-negative inverse of <a class="citerefentry" href="cosh"><span class="citerefentry"><span class="refentrytitle">cosh</span></span></a>. Results
are undefined if <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll"><mml:apply><mml:lt definitionURL="" encoding=""/><mml:mi mathvariant="italic">x</mml:mi><mml:mn>1</mml:mn></mml:apply></mml:math>.
are undefined if <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll"><mml:mi mathvariant="italic">x</mml:mi><mml:mo>&lt;</mml:mo><mml:mn>1</mml:mn></mml:math>.
</p>
</div>
{$pipelinestall}{$examples}
Expand Down
10 changes: 5 additions & 5 deletions el3/asin.xhtml
Original file line number Diff line number Diff line change
Expand Up @@ -44,22 +44,22 @@
<mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll"><mml:mi mathvariant="italic">x</mml:mi></mml:math>.
The range of values returned by <code class="function">asin</code> is
<mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll">
<mml:list order="numeric">
<mml:mfenced open="[" close="]">
<mml:mrow>
<mml:mo></mml:mo>
<mml:mfrac>
<mml:pi definitionURL="" encoding=""/>
<mml:mi>π</mml:mi>
<mml:mn>2</mml:mn>
</mml:mfrac>
</mml:mrow>
<mml:mfrac>
<mml:pi definitionURL="" encoding=""/>
<mml:mi>π</mml:mi>
<mml:mn>2</mml:mn>
</mml:mfrac>
</mml:list>
</mml:mfenced>
</mml:math>.
The result is undefined if
<mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll"><mml:apply><mml:gt definitionURL="" encoding=""/><mml:apply><mml:abs definitionURL="" encoding=""/><mml:mi mathvariant="italic">x</mml:mi></mml:apply><mml:mn>1</mml:mn></mml:apply></mml:math>.
<mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll"><mml:mo>|</mml:mo><mml:mi mathvariant="italic">x</mml:mi><mml:mo>|</mml:mo><mml:mo>&gt;</mml:mo><mml:mn>1</mml:mn></mml:math>.
</p>
</div>
{$pipelinestall}{$examples}
Expand Down
19 changes: 11 additions & 8 deletions el3/atan.xhtml
Original file line number Diff line number Diff line change
Expand Up @@ -94,30 +94,33 @@
and <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll"><mml:mi mathvariant="italic">x</mml:mi></mml:math> are used to determine the quadrant
that the angle lies in. The values returned by <code class="function">atan</code> in this case are in the range
<mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll">
<mml:list order="numeric">
<mml:mrow><mml:mo></mml:mo><mml:pi definitionURL="" encoding=""/></mml:mrow>
<mml:pi definitionURL="" encoding=""/>
</mml:list>
<mml:mfenced open="[" close="]">
<mml:mrow>
<mml:mo></mml:mo>
<mml:mi>π</mml:mi>
</mml:mrow>
<mml:mi>π</mml:mi>
</mml:mfenced>
</mml:math>. Results are undefined if <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll"><mml:mi mathvariant="italic">x</mml:mi></mml:math> is zero.
</p>
<p>
For the second overload, <code class="function">atan</code> returns the angle whose tangent is
<mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll"><mml:mi mathvariant="italic">y_over_x</mml:mi></mml:math>. Values
returned in this case are in the range
<mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll">
<mml:list order="numeric">
<mml:mfenced open="[" close="]">
<mml:mrow>
<mml:mo></mml:mo>
<mml:mfrac>
<mml:pi definitionURL="" encoding=""/>
<mml:mi>π</mml:mi>
<mml:mn>2</mml:mn>
</mml:mfrac>
</mml:mrow>
<mml:mfrac>
<mml:pi definitionURL="" encoding=""/>
<mml:mi>π</mml:mi>
<mml:mn>2</mml:mn>
</mml:mfrac>
</mml:list>
</mml:mfenced>
</mml:math>.
</p>
</div>
Expand Down
2 changes: 1 addition & 1 deletion el3/atanh.xhtml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
<code class="function">atanh</code> returns the arc hyperbolic tangent of
<mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll"><mml:mi mathvariant="italic">x</mml:mi></mml:math>;
the inverse of <a class="citerefentry" href="tanh"><span class="citerefentry"><span class="refentrytitle">tanh</span></span></a>. Results
are undefined if <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll"><mml:apply><mml:gt definitionURL="" encoding=""/><mml:apply><mml:abs definitionURL="" encoding=""/><mml:mi mathvariant="italic">x</mml:mi></mml:apply><mml:mn>1</mml:mn></mml:apply></mml:math>.
are undefined if <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll"><mml:mo>|</mml:mo><mml:mi mathvariant="italic">x</mml:mi><mml:mo>|</mml:mo><mml:mo>&gt;</mml:mo><mml:mn>1</mml:mn></mml:math>.
</p>
</div>
{$pipelinestall}{$examples}
Expand Down
138 changes: 73 additions & 65 deletions el3/cross.xhtml
Original file line number Diff line number Diff line change
Expand Up @@ -60,71 +60,79 @@
</p>
<p>
<mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll">
<mml:vector>
<mml:csymbol encoding="" definitionURL="">
<mml:mi>x</mml:mi>
<mml:mo stretchy="false">[</mml:mo>
<mml:mn>1</mml:mn>
<mml:mo stretchy="false">]</mml:mo>
<mml:mo lspace="2px" rspace="2px"></mml:mo>
<mml:mi>y</mml:mi>
<mml:mo stretchy="false">[</mml:mo>
<mml:mn>2</mml:mn>
<mml:mo stretchy="false">]</mml:mo>
<mml:mo></mml:mo>
<mml:mi>y</mml:mi>
<mml:mo stretchy="false">[</mml:mo>
<mml:mn>1</mml:mn>
<mml:mo stretchy="false">]</mml:mo>
<mml:mo lspace="2px" rspace="2px"></mml:mo>
<mml:mi>x</mml:mi>
<mml:mo stretchy="false">[</mml:mo>
<mml:mn>2</mml:mn>
<mml:mo stretchy="false">]</mml:mo>
</mml:csymbol>
<mml:csymbol encoding="" definitionURL="">
<mml:mi>x</mml:mi>
<mml:mo stretchy="false">[</mml:mo>
<mml:mn>2</mml:mn>
<mml:mo stretchy="false">]</mml:mo>
<mml:mo lspace="2px" rspace="2px"></mml:mo>
<mml:mi>y</mml:mi>
<mml:mo stretchy="false">[</mml:mo>
<mml:mn>0</mml:mn>
<mml:mo stretchy="false">]</mml:mo>
<mml:mo></mml:mo>
<mml:mi>y</mml:mi>
<mml:mo stretchy="false">[</mml:mo>
<mml:mn>2</mml:mn>
<mml:mo stretchy="false">]</mml:mo>
<mml:mo lspace="2px" rspace="2px"></mml:mo>
<mml:mi>x</mml:mi>
<mml:mo stretchy="false">[</mml:mo>
<mml:mn>0</mml:mn>
<mml:mo stretchy="false">]</mml:mo>
</mml:csymbol>
<mml:csymbol encoding="" definitionURL="">
<mml:mi>x</mml:mi>
<mml:mo stretchy="false">[</mml:mo>
<mml:mn>0</mml:mn>
<mml:mo stretchy="false">]</mml:mo>
<mml:mo lspace="2px" rspace="2px"></mml:mo>
<mml:mi>y</mml:mi>
<mml:mo stretchy="false">[</mml:mo>
<mml:mn>1</mml:mn>
<mml:mo stretchy="false">]</mml:mo>
<mml:mo></mml:mo>
<mml:mi>y</mml:mi>
<mml:mo stretchy="false">[</mml:mo>
<mml:mn>1</mml:mn>
<mml:mo stretchy="false">]</mml:mo>
<mml:mo lspace="2px" rspace="2px"></mml:mo>
<mml:mi>x</mml:mi>
<mml:mo stretchy="false">[</mml:mo>
<mml:mn>1</mml:mn>
<mml:mo stretchy="false">]</mml:mo>
</mml:csymbol>
</mml:vector>
<mml:mo>(</mml:mo>
<mml:mtable>
<mml:mtr>
<mml:mtd>
<mml:mi>x</mml:mi>
<mml:mo stretchy="false">[</mml:mo>
<mml:mn>1</mml:mn>
<mml:mo stretchy="false">]</mml:mo>
<mml:mo lspace="2px" rspace="2px"></mml:mo>
<mml:mi>y</mml:mi>
<mml:mo stretchy="false">[</mml:mo>
<mml:mn>2</mml:mn>
<mml:mo stretchy="false">]</mml:mo>
<mml:mo></mml:mo>
<mml:mi>y</mml:mi>
<mml:mo stretchy="false">[</mml:mo>
<mml:mn>1</mml:mn>
<mml:mo stretchy="false">]</mml:mo>
<mml:mo lspace="2px" rspace="2px"></mml:mo>
<mml:mi>x</mml:mi>
<mml:mo stretchy="false">[</mml:mo>
<mml:mn>2</mml:mn>
<mml:mo stretchy="false">]</mml:mo>
</mml:mtd>
</mml:mtr>
<mml:mtr>
<mml:mtd>
<mml:mi>x</mml:mi>
<mml:mo stretchy="false">[</mml:mo>
<mml:mn>2</mml:mn>
<mml:mo stretchy="false">]</mml:mo>
<mml:mo lspace="2px" rspace="2px"></mml:mo>
<mml:mi>y</mml:mi>
<mml:mo stretchy="false">[</mml:mo>
<mml:mn>0</mml:mn>
<mml:mo stretchy="false">]</mml:mo>
<mml:mo></mml:mo>
<mml:mi>y</mml:mi>
<mml:mo stretchy="false">[</mml:mo>
<mml:mn>2</mml:mn>
<mml:mo stretchy="false">]</mml:mo>
<mml:mo lspace="2px" rspace="2px"></mml:mo>
<mml:mi>x</mml:mi>
<mml:mo stretchy="false">[</mml:mo>
<mml:mn>0</mml:mn>
<mml:mo stretchy="false">]</mml:mo>
</mml:mtd>
</mml:mtr>
<mml:mtr>
<mml:mtd>
<mml:mi>x</mml:mi>
<mml:mo stretchy="false">[</mml:mo>
<mml:mn>0</mml:mn>
<mml:mo stretchy="false">]</mml:mo>
<mml:mo lspace="2px" rspace="2px"></mml:mo>
<mml:mi>y</mml:mi>
<mml:mo stretchy="false">[</mml:mo>
<mml:mn>1</mml:mn>
<mml:mo stretchy="false">]</mml:mo>
<mml:mo></mml:mo>
<mml:mi>y</mml:mi>
<mml:mo stretchy="false">[</mml:mo>
<mml:mn>1</mml:mn>
<mml:mo stretchy="false">]</mml:mo>
<mml:mo lspace="2px" rspace="2px"></mml:mo>
<mml:mi>x</mml:mi>
<mml:mo stretchy="false">[</mml:mo>
<mml:mn>1</mml:mn>
<mml:mo stretchy="false">]</mml:mo>
</mml:mtd>
</mml:mtr>
</mml:mtable>
<mml:mo>)</mml:mo>
</mml:math>
</p>
</div>
Expand Down
2 changes: 1 addition & 1 deletion el3/degrees.xhtml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
<mml:mn>180</mml:mn><mml:mo></mml:mo>
<mml:mi mathvariant="italic">radians</mml:mi>
</mml:mrow>
<mml:pi definitionURL="" encoding=""/>
<mml:mi>π</mml:mi>
</mml:mfrac>
</mml:math>.
</p>
Expand Down
2 changes: 1 addition & 1 deletion el3/inversesqrt.xhtml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
<p>
<code class="function">inversesqrt</code> returns the inverse of the square root of <em class="parameter"><code>x</code></em>.
i.e., the value <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll"><mml:mfrac><mml:mn>1</mml:mn><mml:msqrt><mml:mi>x</mml:mi></mml:msqrt></mml:mfrac></mml:math>.
Results are undefined if <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll"><mml:apply><mml:leq definitionURL="" encoding=""/><mml:mi>x</mml:mi><mml:mn>0</mml:mn></mml:apply></mml:math>.
Results are undefined if <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll"><mml:mi>x</mml:mi><mml:mo></mml:mo><mml:mn>0</mml:mn></mml:math>.
</p>
</div>
{$pipelinestall}{$examples}
Expand Down
37 changes: 17 additions & 20 deletions el3/length.xhtml
Original file line number Diff line number Diff line change
Expand Up @@ -42,26 +42,23 @@
<p>
<code class="function">length</code> returns the length of the vector. i.e.,
<mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll">
<mml:apply>
<mml:root definitionURL="" encoding=""/>
<mml:csymbol encoding="" definitionURL="">
<mml:msup>
<mml:mrow>
<mml:mi>x</mml:mi><mml:mo stretchy="false">[</mml:mo><mml:mn>0</mml:mn><mml:mo stretchy="false">]</mml:mo>
</mml:mrow>
<mml:mn>2</mml:mn>
</mml:msup>
<mml:mo>+</mml:mo>
<mml:msup>
<mml:mrow>
<mml:mi>x</mml:mi><mml:mo stretchy="false">[</mml:mo><mml:mn>1</mml:mn><mml:mo stretchy="false">]</mml:mo>
</mml:mrow>
<mml:mn>2</mml:mn>
</mml:msup>
<mml:mo>+</mml:mo>
<mml:mo lspace="0px" form="infix">...</mml:mo>
</mml:csymbol>
</mml:apply>
<mml:msqrt>
<mml:msup>
<mml:mrow>
<mml:mi>x</mml:mi><mml:mo stretchy="false">[</mml:mo><mml:mn>0</mml:mn><mml:mo stretchy="false">]</mml:mo>
</mml:mrow>
<mml:mn>2</mml:mn>
</mml:msup>
<mml:mo>+</mml:mo>
<mml:msup>
<mml:mrow>
<mml:mi>x</mml:mi><mml:mo stretchy="false">[</mml:mo><mml:mn>1</mml:mn><mml:mo stretchy="false">]</mml:mo>
</mml:mrow>
<mml:mn>2</mml:mn>
</mml:msup>
<mml:mo>+</mml:mo>
<mml:mo lspace="0px" form="infix"></mml:mo>
</mml:msqrt>
</mml:math>
</p>
</div>
Expand Down
2 changes: 1 addition & 1 deletion el3/log.xhtml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
<p>
<code class="function">log</code> returns the natural logarithm of <em class="parameter"><code>x</code></em>. i.e., the value
<mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll"><mml:mi>y</mml:mi></mml:math> which satisfies
<mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll"><mml:apply><mml:eq definitionURL="" encoding=""/><mml:mi>x</mml:mi><mml:mrow><mml:msup><mml:mi>e</mml:mi><mml:mi>y</mml:mi></mml:msup></mml:mrow></mml:apply></mml:math>.
<mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll"><mml:mi>x</mml:mi><mml:mo>=</mml:mo><mml:msup><mml:mi>e</mml:mi><mml:mi>y</mml:mi></mml:msup></mml:math>.
Results are undefined if <em class="parameter"><code>x</code></em> ≤ 0.
</p>
</div>
Expand Down
2 changes: 1 addition & 1 deletion el3/log2.xhtml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
<p>
<code class="function">log2</code> returns the base 2 logarithm of <em class="parameter"><code>x</code></em>. i.e., the value
<mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll"><mml:mi>y</mml:mi></mml:math> which satisfies
<mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll"><mml:apply><mml:eq definitionURL="" encoding=""/><mml:mi>x</mml:mi><mml:mrow><mml:msup><mml:mi>2</mml:mi><mml:mi>y</mml:mi></mml:msup></mml:mrow></mml:apply></mml:math>.
<mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll"><mml:mi>x</mml:mi><mml:mo>=</mml:mo><mml:msup><mml:mn>2</mml:mn><mml:mi>y</mml:mi></mml:msup></mml:math>.
Results are undefined if <em class="parameter"><code>x</code></em> ≤ 0.
</p>
</div>
Expand Down
2 changes: 1 addition & 1 deletion el3/radians.xhtml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
<mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" overflow="scroll">
<mml:mfrac>
<mml:mrow>
<mml:pi definitionURL="" encoding=""/><mml:mo></mml:mo><mml:mi mathvariant="italic">degrees</mml:mi>
<mml:mi>π</mml:mi><mml:mo></mml:mo><mml:mi mathvariant="italic">degrees</mml:mi>
</mml:mrow>
<mml:mn>180</mml:mn>
</mml:mfrac>
Expand Down
Loading

0 comments on commit ab1e3cb

Please sign in to comment.