MathJax braces with HTML-CSS renderer broken when browser.display.use_document_fonts is 0
Categories
(Core :: Layout: Text and Fonts, defect)
Tracking
()
People
(Reporter: vincent-moz, Unassigned)
Details
Attachments
(2 files)
With MathJax, when the HTML-CSS renderer is used, the horizontal braces are not correctly rendered when browser.display.use_document_fonts is set to 0 (allowing pages to choose their own font is off). Example: https://en.wikipedia.org/wiki/Floating_point (currently in the second paragraph, after "For example:"). See the attached snapshot.
Reporter | ||
Comment 1•10 years ago
|
||
I've attached a second snapshot, showing what is seen when the MathML renderer is used. No problems with this renderer.
![]() |
||
Comment 2•10 years ago
|
||
Isn't the HTML-CSS renderer just depending on particular font metrics that are correct for the font it specifies but not the one used as a fallback when you disallow the document from specifying fonts?
Reporter | ||
Comment 3•10 years ago
|
||
No, if you look at the snapshot, the cause isn't the font metrics since there is really garbage. It seems that undefined Unicode characters are used for that. It appears to be similar to bug 789788.
Updated•2 years ago
|
Comment 4•1 year ago
|
||
Is there a way to workaround this now that bug 1363454 is fixed?
Comment 5•1 year ago
|
||
I'm not sure how to test this right now -- on the Wikipedia page mentioned in comment 0, I'm getting the equation displayed as an image, so it's independent of fonts -- but if you determine which font is involved, you could add it to the browser.display.use_document_fonts.icon_font_allowlist
list in about:config
(even if it's not really an icon font in this case).
Comment 6•1 year ago
|
||
I'm not sure how to test this right now
On https://www.mathjax.org/#samples, set the rendering engine to CommonHTML.
but if you determine which font is involved, you could add it to the
browser.display.use_document_fonts.icon_font_allowlist
I tried but to no avail, maybe I'm missing something?
Comment 7•1 year ago
|
||
After adding MJXZERO, MJXTEX, MJXTEX-I
to the allowlist, it seems to work as expected for me. Which platform are you using? (Did you definitely confirm the change to the list (click the checkmark beside it) after editing it?)
Comment 8•1 year ago
|
||
Well, I missed MJXZERO
when I tried, and after adding that it started to work.
Can we add those to the default and maybe do something for https://katex.org/ as well?
Description
•