Closed Bug 1850672 Opened 1 year ago Closed 1 year ago

Standard fonts list doesn't contain the localized name

Categories

(Core :: Privacy: Anti-Tracking, defect, P2)

Firefox 118
defect

Tracking

()

VERIFIED FIXED
120 Branch
Tracking Status
firefox-esr115 --- unaffected
firefox118 + verified
firefox119 + verified
firefox120 --- verified

People

(Reporter: 6k64x4ma, Assigned: jfkthame)

References

(Blocks 1 open bug, Regression)

Details

(Keywords: regression, Whiteboard: [fpp:m5])

Attachments

(2 files)

Attached file test.html

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

Steps to reproduce:

  1. Load the attached file in the private window on Windows.

Actual results:

  • Serif font is used for second div because the localized name is not recognized by font visibility restrictions.

Expected results:

  • The Latin name and the localized name should be treated equally.
Component: Layout: Text and Fonts → Graphics: Text
See Also: → 1336208
Component: Graphics: Text → Privacy: Anti-Tracking

Jonathan, is there a way for the font visibility check to match the localized font name with the font name in the list?

Flags: needinfo?(jfkthame)

This bug is seen by more users with the fix for bug 1846224.
For example, if a JA user with ETP set to Strict sets font.name.sans-serif.ja to "BIZ UDPゴシック" through about:preferences, which is the localized font name for the "BIZ UDPGothic" font, "BIZ UDPゴシック" will not match and will use Meiryo font which is set to font.name-list.sans-serif.en for fallback.

See Also: → 1846224
Blocks: 1827475
See Also: → 1849903

(In reply to Tim Huang[:timhuang] from comment #1)

Jonathan, is there a way for the font visibility check to match the localized font name with the font name in the list?

Yeah, I think we should make it so that the same visibility level is used for all localized names of a font family. This looks reasonably straightforward to implement.

Flags: needinfo?(jfkthame)
Assignee: nobody → jfkthame
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true
Whiteboard: [fpp:m5]
Severity: -- → S3
Priority: -- → P2

[Tracking Requested - why for this release]:

  • Significant visual regression occurs on web pages that use localized font names in the font-fmily CSS property.
  • Significant visual regression occurs on web pages when localized font names and strict ETP are set at about:preference.
Pushed by jkew@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/5befb31b3c12 Standard platform font-visibility level should be applied to localized names of the family. r=emilio

Doesn't this also affect 118? Bug 1849903 landed in that version.

[Tracking Requested - why for this release]:

See Also: → 1854950
Status: ASSIGNED → RESOLVED
Closed: 1 year ago
Resolution: --- → FIXED
Target Milestone: --- → 120 Branch

Comment on attachment 9353736 [details]
Bug 1850672 - Standard platform font-visibility level should be applied to localized names of the family. r=#layout-reviewers

Beta/Release Uplift Approval Request

  • User impact if declined: Potential for wrong fonts used in private-browsing windows due to anti-fingerprinting setting - primarily affecting CJK content.
  • Is this code covered by automated tests?: Yes
  • Has the fix been verified in Nightly?: No
  • Needs manual test from QE?: Yes
  • If yes, steps to reproduce: STR in comment 0
  • List of other uplifts needed: None
  • Risk to taking this patch: Low
  • Why is the change risky/not risky? (and alternatives if risky): Minor change during font-list initialization, to ensure all (localized) names of a font are classed as equivalent for lookup
  • String changes made/needed:
  • Is Android affected?: No
Attachment #9353736 - Flags: approval-mozilla-beta?
Flags: qe-verify+

Set release status flags based on info from the regressing bug 1849903

Comment on attachment 9353736 [details]
Bug 1850672 - Standard platform font-visibility level should be applied to localized names of the family. r=#layout-reviewers

Approved for 119.0b3

Attachment #9353736 - Flags: approval-mozilla-beta? → approval-mozilla-beta+
QA Whiteboard: [qa-triaged]

Reproduced this issue on an affected Nightly build from 2023-08-30, on Win 10.
Verified as fixed on latest nightly 120.0a1 (20230928215127) and Firefox 119.0b3 (treeherder build 20230927183607) on Win 10, Ubuntu 20.04 and macOS 10.15.

Jonathan, is this a good candidate for uplifting in our planned dot release? Thanks

Flags: needinfo?(jfkthame)

I don't have a strong opinion one way or the other. On the one hand, I believe the patch has minimal risk, and it will improve the experience for affected users/sites; but on the other hand the "breakage" is cosmetic (wrong/less-desirable font being used) rather than drastic (content unusable).

I guess Japanese & Chinese users might appreciate it being uplifted; they're probably the main communities affected (though by no means all users, as it's only relevant when anti-fingerprinting settings are made stricter, as in private browsing).

Flags: needinfo?(jfkthame)

Comment on attachment 9353736 [details]
Bug 1850672 - Standard platform font-visibility level should be applied to localized names of the family. r=#layout-reviewers

Beta/Release Uplift Approval Request

  • User impact if declined: Some users (especially CJK) may get wrong/undesired fonts when strict anti-fingerprinting is in force.
  • Is this code covered by automated tests?: Yes
  • Has the fix been verified in Nightly?: Yes
  • Needs manual test from QE?: No
  • If yes, steps to reproduce:
  • List of other uplifts needed: None
  • Risk to taking this patch: Low
  • Why is the change risky/not risky? (and alternatives if risky): Patch just changes visibility annotations on localized font names; otherwise, no functional changes.
  • String changes made/needed:
  • Is Android affected?: No
Attachment #9353736 - Flags: approval-mozilla-release?
Duplicate of this bug: 1856186

Comment on attachment 9353736 [details]
Bug 1850672 - Standard platform font-visibility level should be applied to localized names of the family. r=#layout-reviewers

Approved for our next 118 dot release, thanks.

Attachment #9353736 - Flags: approval-mozilla-release? → approval-mozilla-release+
No longer duplicate of this bug: 1856186
Flags: qe-verify+

Verified as fixed on Firefox 118.0.2 (20231009140911) on Windows 10, Ubuntu 20.04 and macOS 10.15.

Status: RESOLVED → VERIFIED
Flags: qe-verify+
Duplicate of this bug: 1858650
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: