empty or non-empty <math> elements have height of 106px
Categories
(Core :: MathML, defect)
Tracking
()
People
(Reporter: user, Unassigned)
Details
Attachments
(4 files)
User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:75.0) Gecko/20100101 Firefox/75.0
Steps to reproduce:
- Open attached test.html file in Firefox.
Actual results:
Notice that second and third div are way too large - 106px high, to be exact. Even the empty <math> has size 0x106px, resulting in incorrect size of the whole line.
Tested on 75.0, 76.2, and Nightly versions.
Expected results:
All three lines should have been of more-or-less same height.
| Reporter | ||
Comment 1•6 years ago
|
||
Here's a screenshot of how the test.html page looks in my browser.
Comment 2•6 years ago
|
||
Bugbug thinks this bug should belong to this component, but please revert this change in case of error.
Comment 3•6 years ago
|
||
Huh, I can't repro this on Nightly at least, will check on other versions later.
Updated•6 years ago
|
Comment 4•6 years ago
|
||
Do you have any special font settings that could affect this?
| Reporter | ||
Comment 5•6 years ago
|
||
Definitely didn't touch any font settings in Firefox. I'm not sure about the system as a whole (I'm using Arch Linux).
I added an external font file to the test case - I still see the same problem. Will attach the new test case file.
| Reporter | ||
Comment 6•6 years ago
|
||
Comment 7•6 years ago
|
||
Is it a duplicate of bug 1208776?
| Reporter | ||
Comment 8•6 years ago
|
||
Indeed it is - I had Latin Modern Math font installed with mathjax 2.7.8, and it doesn't have the USE_TYPO_METRICS bit set.
Comment 9•6 years ago
|
||
(In reply to Platon Pronko from comment #8)
Indeed it is - I had Latin Modern Math font installed with mathjax 2.7.8, and it doesn't have the USE_TYPO_METRICS bit set.
*** This bug has been marked as a duplicate of bug 1208776 ***
(mmh, I'm not sure why Latin Modern Math font is installed with MathJax, are you sure it's not their own modified version?) Are you able to check in the developer tools which is the default font used for a simple <math><mn>123</mn<</math>?
And can you please file a request to Arch Linux so that they upgrade the corresponding math font package? Thanks!
| Reporter | ||
Comment 10•6 years ago
|
||
And can you please file a request to Arch Linux so that they upgrade the corresponding math font package? Thanks!
I looked into that already and thought that nothing can be done, and thus decided to close the issue.
The problem is as follows: Latin Modern Math was installed on my system from mathjax2 package, version 2.7.8. The fonts were included in the release archive (https://github.com/mathjax/MathJax/archive/2.7.8.tar.gz).
The mathjax2 ended up on my system as a dependency for calibre-common (the Calibre ebook reader).
Probably the "proper" solution will be to update the calibre to use the newest version of mathjax (the 3.0.5), but unfortunately 3.x MathJax is a complete rewrite and updating this dependency will be non-trivial (and Calibre has a lot of other problems, they are still on Python 2 and have incedibly huge troubles updating to Python 3).
And Arch Linux policy is to use upstream releases with minimum amount of modifications, preferrably none, thus updating only the font files in mathjax2 package won't be acceptable either.
(mmh, I'm not sure why Latin Modern Math font is installed with MathJax, are you sure it's not their own modified version?)
I actually have no idea, I only know that the font files were included in the release.
Are you able to check in the developer tools which is the default font used for a simple <math><mn>123</mn<</math>?
Yes, I checked that and it was Latin Modern Math. I since changed the default in Firefox prefrences and now math looks okay.
| Reporter | ||
Comment 11•6 years ago
|
||
Also installing otf-latinmodern-math package fixes the issue - the font in this package works correctly and has USE_TYPO_METRICS bit set.
(I now have Larin Modern Math font files both from both packages, but for some reason the otf-latinmodern-math files are chosen - I do not know how the font files are selected in such ambiguous situations)
Comment 12•6 years ago
|
||
(In reply to Platon Pronko from comment #11)
Also installing
otf-latinmodern-mathpackage fixes the issue - the font in this package works correctly and has USE_TYPO_METRICS bit set.(I now have Larin Modern Math font files both from both packages, but for some reason the
otf-latinmodern-mathfiles are chosen - I do not know how the font files are selected in such ambiguous situations)
That's what I was going to suggest. I don't think MathJax uses the official Latin Modern Math fonts so I don't know why it's included in the package in the first place, and Gecko won't use the unofficial package. Anyway, it seems the official otf-latinmodern-math package is already up-to-date. Thanks.
Description
•