Closed Bug 1014601 Opened 10 years ago Closed 10 years ago

Add some OpenType MATH fonts in mathml.css

Categories

(Core :: MathML, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla32
Tracking Status
firefox31 --- fixed
firefox32 --- fixed

People

(Reporter: fredw, Assigned: fredw)

References

Details

(Whiteboard: [qa-])

Attachments

(1 file, 1 obsolete file)

While updating the MDN doc and the MathML-fonts add-on, I noticed that we can not really recommend the OpenType MATH font for Gecko 31 yet, because mathml.css only has Cambria Math and the default font is not easily configurable (bug 947654). One difficulty is that most fonts have the ascent/descent issue on Windows (bug 1014498).

As a quick fix that could easily be integrated in the Gecko 31 branch, I propose to make font-family start with

"MathJax_Main, STIXGeneral, Cambria Math, XITS, Latin Modern Math, DejaVu Serif, DejaVu Sans..."

so that

1) This still won't change the default preference for people who have already installed the MathJax/STIXGeneral fonts.

and otherwise:

2) On Windows >= 7, the OpenType MATH font "Cambria Math" will be used/installed by default.

3) On other systems, we will recommend people to install one OpenType MATH font (Latin Modern Math or XITS). I put XITS before Latin Modern Math, because it is not affected by bug 1014498, so Windows XP users could still use that font (if e.g. Latin Modern Math is already installed in their TeX distrib that they can't uninstall).
Blocks: 947654, 1014498
Attached patch mathmlcss (obsolete) — Splinter Review
Assignee: nobody → fred.wang
Status: NEW → ASSIGNED
Attached patch Patch V2Splinter Review
Removing the non-MATH "Cambria" caused test failures on Windows 7/8 unaccelerated builds (probably bug 1014498). That one should be better.
Attachment #8427046 - Attachment is obsolete: true
Attachment #8427808 - Flags: review?(karlt) → review+
Keywords: checkin-needed
https://hg.mozilla.org/mozilla-central/rev/f6e8730a1c89
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla32
Comment on attachment 8427808 [details] [diff] [review]
Patch V2

[Approval Request Comment]

See bug 930504 comment 40 for the rationale about Open Type MATH in Gecko 31.

Bug caused by (feature/regressing bug #): We want to deprecate MathJax TeX / STIX General in favor of the OpenType MATH fonts with equivalent styles. However, these new OpenType MATH fonts are not listed in the default font-family of the <math> element, so they are never used by default even when they are installed.

User impact if declined: If they want the Computer Modern / STIX styles, users will need to keep the MathJax TeX / STIX General fonts installed and won't be willing/able to migrate to the new OpenType MATH fonts. Also, Latin Modern Math is installed by default with most TeX distribution so taking this patch will improve the MathML rendering for some users who had not installed old math fonts in the past but have a TeX distribution on their systems.

Testing completed (on m-c, etc.): This patch was tested in try, mozilla-inbound and landed in mozilla-central on Monday morning without causing any regressions. This does not really need any test beside the existing MathML tests: it is just adding two fonts into a font-family rule of the MathML user agent stylesheet.

Risk to taking this patch (and alternatives if risky): very low. This is just modifying a font-family rule in the MathML user agent stylesheet to add two font families (Latin Modern Math and XITS Math) so there are no performance / security risks. This will only affect pages that use MathML when the users have Latin Modern Math / XITS Math installed.

String or IDL/UUID changes made by this patch: None
Attachment #8427808 - Flags: approval-mozilla-aurora?
Comment on attachment 8427808 [details] [diff] [review]
Patch V2

Aurora approval granted in order not to prolong the transition period by keeping these fonts out of ESR for the next 7 releases.
Attachment #8427808 - Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
Whiteboard: [qa-]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: