Open Bug 1509155 Opened 6 years ago Updated 2 years ago

Disable GDI fonts

Categories

(Core :: Graphics: Text, enhancement, P3)

enhancement

Tracking

()

People

(Reporter: jrmuizel, Unassigned)

References

(Blocks 1 open bug)

Details

We shouldn't need to use GDI fonts anywhere. It would be nice to delete all of that code. This would also let us avoid having to pass a DrawTarget to gfxFont::GetGlyphWidth() which will let us avoid threading it around a bunch of places.
Jonathan or Lee do you know any reason we shouldn't do this?
Flags: needinfo?(lsalzman)
Flags: needinfo?(jfkthame)
Priority: -- → P3
Blocks: 1509158
It would be nice to get rid of the GDI font code, but I'm a bit concerned we may still be depending on it as a fallback when (for reasons unknown) we fail to use directwrite. E.g. the crash in bug 1505966 appeared to be caused by a failure to get the dwrite system font collection, so we needed to fix the handling of that failure (and we'd then fall back to GDI). If we remove the GDI font code, our only option on failing to initialize dwrite would be to refuse to run at all. I don't know how frequent that scenario is; maybe we should add some telemetry to find out?
Flags: needinfo?(jfkthame)
My initial look at DWRITEFONT_INIT_PROBLEM telemetry suggests we're hitting this on .03% of windows beta users. I'll look more closely at the numbers and confirm.
That would be the main fear, yes, that we are falling back to GDI if DWrite for some reason fails.
Flags: needinfo?(lsalzman)
Depends on: 1619978
Depends on: 1638331
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.