style: Don't consider system-ui valid for user font prioritization

Since the user can't configure it, at least from the UI (we could add UI
for it but it's unclear it'd be worth it).

Differential Revision: https://phabricator.services.mozilla.com/D125182
This commit is contained in:
Emilio Cobos Álvarez 2023-05-27 07:05:23 +02:00 committed by Oriol Brufau
parent 7108be870d
commit 1e5806610b
2 changed files with 24 additions and 10 deletions

View file

@ -916,12 +916,7 @@ impl<'a, 'b: 'a> Cascade<'a, 'b> {
// we have a generic family to actually replace it with.
let prioritize_user_fonts = !use_document_fonts &&
default_font_type != GenericFontFamily::None &&
matches!(
generic,
GenericFontFamily::None |
GenericFontFamily::Fantasy |
GenericFontFamily::Cursive
);
!generic.valid_for_user_font_prioritization();
if !prioritize_user_fonts && default_font_type == font.mFont.family.families.fallback {
// Nothing to do.