Closed Bug 1615652 Opened 5 years ago Closed 5 years ago

Firefox renders zh-Hant-HK with a Japanese font instead of a Chinese font.

Categories

(Core :: Layout: Text and Fonts, defect, P3)

73 Branch
defect

Tracking

()

RESOLVED FIXED
mozilla75
Tracking Status
firefox74 --- wontfix
firefox75 --- verified

People

(Reporter: rampaa.01, Assigned: jfkthame)

References

(Blocks 1 open bug)

Details

Attachments

(2 files)

Attached file Test.html

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:73.0) Gecko/20100101 Firefox/73.0

Steps to reproduce:

Visit the following link: https://en.wikipedia.org/wiki/Han_unification#Examples_of_language-dependent_glyphs

Alternatively you can use the Test.html I've provided.

Actual results:

The text in zh-Hant-HK has been rendered with a Japanese font.

Expected results:

The text in zh-Hant-HK should have been rendered with a (traditional) Chinese font.

Bugbug thinks this bug should belong to this component, but please revert this change in case of error.

Component: Untriaged → Layout: Text and Fonts
Product: Firefox → Core

Looks like this happens because the MingLiU font that is configured as default for zh-HK:

  pref("font.name-list.serif.zh-HK", "Times New Roman, MingLiu_HKSCS, Ming(for ISO10646), MingLiU, MingLiU_HKSCS-ExtB");
  pref("font.name-list.sans-serif.zh-HK", "Arial, MingLiU_HKSCS, Ming(for ISO10646), MingLiU, MingLiU_HKSCS-ExtB");
  pref("font.name-list.monospace.zh-HK", "MingLiU_HKSCS, Ming(for ISO10646), MingLiU, MingLiU_HKSCS-ExtB");

is not actually present on a standard English installation of Win10, and so we end up hitting fallback. (The -ExtB fonts are present, but not the base font, in either its _HKSCS or default form.)

Going in to Windows Settings / Language and adding "Chinese (Traditional, Hong Kong SAR)" results in the plain MingLiU being installed, and then the zh-Hant-HK content appears in this font as expected.

Is there a different font that is present by default on all Win10 systems and would be a better (or additional) font to list in the preferences? I guess at least Microsoft JhengHei (which we use for zh-TW) would be an improvement, although being Taiwan-oriented it may not be ideal.

Assignee: nobody → jfkthame
Priority: -- → P3
Blocks: 1473240
Pushed by jkew@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/7c5b2bcf6058 Append Microsoft JhengHei to the end of zh-HK font prefs as a fallback, because MingLiU may not be present on Windows installations where Chinese/HK language support is not specifically installed. r=m_kato
Status: UNCONFIRMED → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla75

Verified the issues with Firefox 75.0b2 on Windows 10 x64 and it is no longer reproducible
The issue is reproducible with 73.0 and 74.0 (20200309095159) as well.
Updating flag status 74.0 as affected.

You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: