Compile Fontra fonts - #2068
Draft
khaledhosny wants to merge 15 commits into
Draft
Conversation
Rework fontra.rs to mirror current Fontra classes.py as much as possible. This is a rather big change, but Fontra changed quite a bit since this code was initially written, and we can now also parse the whole file format more or less (the .csv files will be handled in later commits). I also drop the “Fontra” prefix from the type names as it felt redundant, and other backends does not have such prefixes. serde(rename_all = "camelCase") is now used to avoid having to manually rename struct members (except for the few cases where camelCase would not give the name Fontra uses). The existing test files were also updated to reflect the current file format.
In preparation for updating and integrating it into Font.
Update parsing glyph-info.csv to match current Fontra and make it populate Font::glyph_map and Font::glyph_infos. Don’t read glyphs files for glyph map, since it can be built from glyph-info.csv already. Update StaticMetadataWork to use Font::glyph_map and Font::glyph_infos.
Font files copied from Fontra repository unchanged.
Update 2glyphs.fontra to have a default source so it doesn’t fail to load.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
(Should be applied after #2064)