DirectWrite nsIFontEnumerator.EnumerateFonts needs to recognize aGeneric

NEW
Unassigned

Status

()

9 years ago
8 years ago

People

(Reporter: sid0, Unassigned)

Tracking

(Blocks: 1 bug)

Trunk
x86
Windows 7
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

fe = Components.classes["@mozilla.org/gfx/fontenumerator;1"].createInstance(Components.interfaces.nsIFontEnumerator); fe.EnumerateFonts("x-western", "serif", {})

returns all fonts, whether serif, non-serif or monospace. Only serif fonts are returned with GDI. (This causes the font chooser to be populated with all sorts of fonts for each style.)
This is because gfxDWriteFontEntry does not implement the MatchesGenericFamily method, so it falls back to the base implementation in gfxFontEntry, which always answers "yes".

Comment 3

8 years ago
This happens for me and I think DirectWrite is disabled (at least it says so in about:support).  Related to bug 107888?
You need to log in before you can comment on or make changes to this bug.