Repository navigation
Introduce override list to FontInfo - #3228
Conversation
|
According to #3213 (comment), both FULL_NAME and checksum matches have pros and cons.
So, is version string also a good matcher to enhance safety of FULL_NAME match? When a font is fixed since some version, we may not need to override the FontInfo anymore. We may safely think of same version implies same checksum, and we can compare version by some rules. |
Yes, I can think of some "conditional" addition in the future: NewCM08-Book:
family: New Computer Modern 08
conditional:
until-version: 5.1
weight: 450But that's out of the scope of this PR. It's just an internal refactoring facilitating future improvements, so it's not suitable to add new features here. |
It seems strange to me that there is |
It's totally a mess. The typst code do not have any code to correct that, so do this PR. By a side effect of removing all NewCM related code from |
|
I'm not super happy about the fact that we're embedding a yaml file in the binary and lazily deserialize it and runtime. It feels wasteful. Considering that |
I'd like to name the module |
|
Maybe |
|
Let's use the term "exception" across the board then, also |
|
Thank you! |
Introduce font override list described in #3213 (comment). This PR is exploratory. If it gets merged, a subsequent PR can be submitted to immediately solve #3213, #576 and #2098 (comment) by just adding a few more lines to
override_list.yml. And after that, further improvements can be made in subsequent PR.Changed implementation
fn typographic_familyandfn from_ttfis removed.Changed behaviors
This PR is a refactoring and should not change anything other than the name of NewCM08 family. To be specific,
typst fontswill have following change in a system with complete NewCM font installed: