mirror of
https://github.com/typst/typst
synced 2025-05-13 12:36:23 +08:00
Handle New CM Math Book
This commit is contained in:
parent
affb353453
commit
6547c2d6d5
@ -199,7 +199,7 @@ impl FontInfo {
|
|||||||
// up.
|
// up.
|
||||||
let family = {
|
let family = {
|
||||||
let mut family = find_name(ttf, name_id::FAMILY)?;
|
let mut family = find_name(ttf, name_id::FAMILY)?;
|
||||||
if family.starts_with("Noto") {
|
if family.starts_with("Noto") || family.starts_with("NewComputerModern") {
|
||||||
family = find_name(ttf, name_id::FULL_NAME)?;
|
family = find_name(ttf, name_id::FULL_NAME)?;
|
||||||
}
|
}
|
||||||
typographic_family(&family).to_string()
|
typographic_family(&family).to_string()
|
||||||
@ -353,6 +353,7 @@ fn typographic_family(mut family: &str) -> &str {
|
|||||||
// Fix bad names.
|
// Fix bad names.
|
||||||
match &family[..len] {
|
match &family[..len] {
|
||||||
"NewComputerModernMath" => "New Computer Modern Math",
|
"NewComputerModernMath" => "New Computer Modern Math",
|
||||||
|
"NewComputerModernMath-Book" => "New Computer Modern Math Book",
|
||||||
other => other,
|
other => other,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user