Page MenuHomePhabricator

<math> does not render correctly on Android app preview
Closed, DuplicatePublic

Description

(Reported by @TheLand on a certain social media forum).

The <math> formula in the article [[Geometric mean]] is not rendered correctly.

(May relate to T167593 ?)

Event Timeline

JeanFred created this task.Sep 5 2017, 7:07 PM
Restricted Application added a subscriber: Aklapper. · View Herald Transcript
Deskana added a subscriber: Deskana.Sep 5 2017, 8:25 PM

Looking at the data from the API backing that preview, I'm astounded it doesn't display even worse than this.


https://en.wikipedia.org/w/api.php?action=query&prop=extracts&titles=Geometric_mean&format=json

"extract":"<p>In mathematics, the <b>geometric mean</b> is a type of mean or average, which indicates the central tendency or typical value of a set of numbers by using the product of their values (as opposed to the arithmetic mean which uses their sum). The geometric mean is defined as the <span><i>n</i></span>th root of the product of <span>n</span> numbers, i.e., for a set of numbers <span><i>x</i><sub>1</sub>, <i>x</i><sub>2</sub>, ..., <i>x<sub>n</sub></i></span>, the geometric mean is defined as</p>\n<dl><dd><span><span><math xmlns=\"http://www.w3.org/1998/Math/MathML\">\n  <semantics>\n    <mrow class=\"MJX-TeXAtom-ORD\">\n      <mstyle displaystyle=\"true\" scriptlevel=\"0\">\n        <msup>\n          <mrow>\n            <mo>(</mo>\n            <munderover>\n              <mo>\u220f</mo>\n              <mrow class=\"MJX-TeXAtom-ORD\">\n                <mi>i</mi>\n                <mo>=</mo>\n                <mn>1</mn>\n              </mrow>\n              <mrow class=\"MJX-TeXAtom-ORD\">\n                <mi>n</mi>\n              </mrow>\n            </munderover>\n            <msub>\n              <mi>x</mi>\n              <mrow class=\"MJX-TeXAtom-ORD\">\n                <mi>i</mi>\n              </mrow>\n            </msub>\n            <mo>)</mo>\n          </mrow>\n          <mrow class=\"MJX-TeXAtom-ORD\">\n            <mfrac>\n              <mn>1</mn>\n              <mi>n</mi>\n            </mfrac>\n          </mrow>\n        </msup>\n        <mo>=</mo>\n        <mrow class=\"MJX-TeXAtom-ORD\">\n          <mroot>\n            <mrow>\n              <msub>\n                <mi>x</mi>\n                <mrow class=\"MJX-TeXAtom-ORD\">\n                  <mn>1</mn>\n                </mrow>\n              </msub>\n              <msub>\n                <mi>x</mi>\n                <mrow class=\"MJX-TeXAtom-ORD\">\n                  <mn>2</mn>\n                </mrow>\n              </msub>\n              <mo>\u22ef</mo>\n              <msub>\n                <mi>x</mi>\n                <mrow class=\"MJX-TeXAtom-ORD\">\n                  <mi>n</mi>\n                </mrow>\n              </msub>\n            </mrow>\n            <mrow class=\"MJX-TeXAtom-ORD\">\n              <mi>n</mi>\n            </mrow>\n          </mroot>\n        </mrow>\n      </mstyle>\n    </mrow>\n    <annotation encoding=\"application/x-tex\">{\\displaystyle \\left(\\prod _{i=1}^{n}x_{i}\\right)^{\\frac {1}{n}}={\\sqrt[{n}]{x_{1}x_{2}\\cdots x_{n}}}}</annotation>\n  </semantics></math></span></span></dd>\n</dl>
JeanFred renamed this task from <math> does not render correctly on Android app to <math> does not render correctly on Android app preview.Sep 5 2017, 8:54 PM

@Deskana if you unescape the newlines it's HTML. Are there any plans to support MathML rendering from the Android App? As far as I know the main problem is to install the Math Fonts. @fredw are you aware of an easy solution to enable MathML rendering in Android Apps?

fredw added a comment.Sep 7 2017, 8:01 AM