mathjax / MathJax

Beautiful and accessible math in all browsers
http://www.mathjax.org/
Apache License 2.0
10.23k stars 1.16k forks source link

Difference in size of MathJax with LaTeX in `\scriptstyle\underbrace{X}` #3300

Open hbghlyj opened 1 month ago

hbghlyj commented 1 month ago

Issue Summary

In LaTeX \underbrace and \overbrace seem to reset the style of argument to display-style. (cf. https://github.com/KaTeX/KaTeX/issues/764)

Steps to Reproduce:

${\textstyle\prod}  {\displaystyle\prod}  \underbrace{\prod}$

In LaTeX image

Technical details:

hbghlyj commented 1 month ago

Similar:

$X\scriptstyle\begin{matrix}X\end{matrix}$

LaTeX:

image

MathJax: image

dpvc commented 1 month ago

OK, it looks like under- and overbrace are outliers among the under- and over- macros, as they do seem to reset the style to text-style. I will look into fixing that.

Similarly, the matrix and array environments do seem to reset to text-style as well.

dpvc commented 4 weeks ago

I have made a pull request for v4 that resolves these issues.

dpvc commented 3 weeks ago

The PR I made does set display-style for the under and over braces.