- From: David Carlisle <davidc@nag.co.uk>
- Date: Fri, 13 Jun 2014 00:29:48 +0100
- To: <www-math@w3.org>
- Message-ID: <539A37EC.3060308@nag.co.uk>

On 12/06/2014 20:54, Frédéric WANG wrote: > Le 11/06/2014 18:37, Neil Soiffer a écrit : >> I concur with David Carlisle: the spec specifically says it is false >> (matches TeX behavior). It is similar to mfrac in that the rules for >> mfrac say "The |mfrac| element sets |displaystyle| to "false". The >> only difference with mtable is that there is an attribute that allows >> you to override the default. > So if we agree about that, my concern is that for things like > > {\displaystyle {\begin{aligned}\Gamma (z)&=\int > _{0}^{x}e^{{-t}}t^{{z-1}}\,{\frac {{\mathrm {d}}t}{t}}+\int > _{x}^{\infty }e^{{-t}}t^{{z+1}}\,{\frac {{\mathrm > {d}}t}{t}}\\&=x^{z}e^{{-x}}\sum _{{n=0}}^{\infty }{\frac > {x^{n}}{z(z+1)\cdots (z+n)}}+\int _{x}^{\infty > }e^{{-t}}t^{{z}}\,{\frac {{\mathrm {d}}t}{t}}.\end{aligned}} > > the aligned environment is transformed into a <mtable> by > LaTeX-to-MathML converters (such as MathJax or itex2MML) and so the > content of the cells are not in displaystyle, contrary to how LaTeX > behaves. That's a bit a pain that aligning with the spec in Gecko 29 > broke compatibility with these converters... > > It seems that LaTeXML knows about the displaystyle context and is able > to propagate <mstyle displaystyle="true"> element inside the <mtable> > cells. However, for parsers like itex2MML, where the content of the > cells is parsed first and directly converted into a string, it might > be a bit tedious to insert such elements. Instead, itex2MML just > inserts the a <mstyle displaystyle="true"> around the <mtable> and > expects that the property will be propagated to cells. So in my > opinion, it would be best if the displaystyle was "inherited" on > <mtable>. It's easier to attach a displaystyle="false" to reset the > property for normal TeX table than to append many new <mstyle> for > <mtable> generated from LaTeX environments similar to \begin{aligned}. > > -- > Frédéric Wang > maths-informatique-jeux.com/blog/frederic > > Unlike array, aligned sets its cells in displaystyle so should map to <mtable displaystyle="true"> which is no harder to generate than <mtable> You don't need to generate many (or any) mstyle elements. It's unfortunate if some convertors get that wrong but it shouldn't be hard for the maintainers to fix them (Davide's already entered a bug for MathJax.) David

Received on Thursday, 12 June 2014 23:30:41 UTC