From 8133b31c7484d64b196c8b0ba053ff631a84616b Mon Sep 17 00:00:00 2001 From: Madhav Agarwal Date: Sun, 15 Nov 2026 14:02:39 +0530 Subject: [PATCH] Text: embedded Noto Sans JP backs up Japanese runs (#2375) --- crates/text/src/fontdb.rs | 3 ++- crates/text/src/fontdb_tests.rs | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/crates/text/src/fontdb.rs b/crates/text/src/fontdb.rs index 65df051e7..f5774307e 100644 --- a/crates/text/src/fontdb.rs +++ b/crates/text/src/fontdb.rs @@ -555,7 +555,7 @@ fn names(f: &skrifa::FontRef) -> (Option, Option) { /// document: the browser has no other fonts. The symbol fonts come last: Apple Symbols (macOS), /// Segoe UI Symbol (Windows) and the Noto symbol and math fonts (Linux), for signs such as ⌖ and ⤒ /// that no text face has. -const FALLBACK_FAMILIES: [&str; 32] = [ +const FALLBACK_FAMILIES: [&str; 33] = [ "Inter", "Helvetica Neue", "Arial", @@ -563,6 +563,7 @@ const FALLBACK_FAMILIES: [&str; 32] = [ "DejaVu Sans", "Noto Sans", "BIZ UDPGothic", + "Noto Sans JP", "Hiragino Sans", "PingFang SC", "Hiragino Sans GB", diff --git a/crates/text/src/fontdb_tests.rs b/crates/text/src/fontdb_tests.rs index bf459fe06..2585ced73 100644 --- a/crates/text/src/fontdb_tests.rs +++ b/crates/text/src/fontdb_tests.rs @@ -604,6 +604,7 @@ fn every_embeddable_script_face_is_a_document_fallback() { "Noto Sans Hebrew", "Noto Sans Devanagari", "Noto Sans Georgian", + "Noto Sans JP", "Noto Sans Symbols", "Noto Sans Symbols 2", ] {