Closed Bug 1717255 Opened 3 years ago Closed 3 years ago

Firefox on MacOS choosing wrong font from font family

Categories

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

Firefox 89
ARM64
macOS
defect

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: rich, Unassigned)

Details

Attachments

(2 files)

User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:89.0) Gecko/20100101 Firefox/89.0

Steps to reproduce:

  1. On MacOS Big Sur, browse to any GitHub code page, such as this one.

Actual results:

  1. The rendered font has a very heavy weight.
  2. In the Inspector, under "Fonts", the font family "SF Mono" has been resolved to "SF Mono Heavy".

Expected results:

  1. The rendered font has a regular weight.
  2. In the Inspector, the font family "SF Mono" has been resolved to "SF Mono Regular".

I'll admit I don't understand the internals of how Firefox, or MacOS, chooses the default weight for a font family that has many font files in it. If I disable SF Mono Heavy in Font Book, then it switches to SF Mono Regular Italic (still wrong).

For reference, here is the list of fonts in the SF Mono family in Big Sur. I don't recall this happening on MacOS Catalina. I can verify from my work computer Monday if no-one else can verify before then.

The Bugbug bot thinks this bug should belong to the 'DevTools::Inspector' component, and is moving the bug to that component. Please revert this change in case you think the bot is wrong.

Component: Untriaged → Inspector
Product: Firefox → DevTools

Kicking this over to Layout:Text and Fonts, which I'm not 100% sure is the right place, but Cunningham's Law will take care of it if not.

Component: Inspector → Layout: Text and Fonts
OS: Unspecified → macOS
Product: DevTools → Core
Hardware: Unspecified → ARM64

This doesn't reproduce for me on Big Sur; I'm seeing SF Mono Regular as expected.

What version of SF Mono is on your system? (The Font Info preview in Font Book should show a version number and filename/location.)

Flags: needinfo?(rich)

Huh, interesting. I have SF Mono 12.0d2e3... OH HEY, it's not the system copy, it's in /Users/rich/Library/Fonts/SFMono-RegularItalic.otf. Let me get rid of that and retry.

Flags: needinfo?(rich)

And with SF Mono upgraded from here I get SF Mono Regular. Apologies for the false alarm! I'll take my findings back to the github forum post about the problem too.

Thanks for following up. I think we can conclude that there's something funky about the old SF Mono fonts you (and another user in that thread) had installed -- probably the various faces don't have the expected style metadata that Firefox depends on to choose among them, and this has been fixed in the more recent version.

So working as expected with Apple's currently-supported font version, as far as I can tell.

Status: UNCONFIRMED → RESOLVED
Closed: 3 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: