summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Kröning <mkroening@posteo.net>2024-02-02 11:54:05 +0100
committerGitHub <noreply@github.com>2024-02-02 10:54:05 +0000
commit356032bf8cdb759e93c2c6b853fe77b9c5f57c07 (patch)
tree581cc168082e456e9ec3507a0d18344a413e7a47
parentf1ba218e8f05554cbc7ab8901c44b7c91f1d2f89 (diff)
font-exceptions: override weight of Arial Black (#3321)
Signed-off-by: Martin Kröning <martin.kroening@eonerc.rwth-aachen.de>
-rw-r--r--crates/typst/src/text/font/exceptions.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/crates/typst/src/text/font/exceptions.rs b/crates/typst/src/text/font/exceptions.rs
index 4a290e38..738a2e95 100644
--- a/crates/typst/src/text/font/exceptions.rs
+++ b/crates/typst/src/text/font/exceptions.rs
@@ -44,6 +44,10 @@ pub fn find_exception(postscript_name: &str) -> Option<&'static Exception> {
/// A map which keys are PostScript name and values are override entries.
static EXCEPTION_MAP: phf::Map<&'static str, Exception> = phf::phf_map! {
+ // The old version of Arial-Black, published by Microsoft in 1996 in their "core fonts for the web" project, has a wrong weight of 400.
+ // See https://corefonts.sourceforge.net/.
+ "Arial-Black" => Exception::new()
+ .weight(900),
"NewCM08-Book" => Exception::new()
.family("New Computer Modern 08")
.weight(450),