Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Apply DesignSpace variable-font's public.fontInfo lib key to variable fonts #816

Merged
merged 6 commits into from
Feb 2, 2024

Conversation

khaledhosny
Copy link
Collaborator

Fixes #812

@khaledhosny
Copy link
Collaborator Author

@anthrotype This is a PoC of using PostProcessor to update the compiled font. The use of OutlineCompiler is essentially a hack to avoid duplicating much logic about building tables, but I don’t like it much. Probably some duplication is OK, or may be we should go back to your initial idea, but I don’t know how to make it work for multiple variable-fonts with the current building and merging logic.

@anthrotype
Copy link
Member

I don't like this conceptually. We should try to see if we can maybe duplicate/make the base master unique before proceeding to compile each VFs

@anthrotype
Copy link
Member

We should try to see if we can maybe duplicate/make the base master unique before proceeding to compile each VFs

argh.. I actually tried and failed, it's too complicated 😢

@anthrotype
Copy link
Member

I'm warming up to the idea that this is best done inside the postProcessor like you're doing here. I don't like it but I dislike the alternative more

@khaledhosny
Copy link
Collaborator Author

We should try to see if we can maybe duplicate/make the base master unique before proceeding to compile each VFs

argh.. I actually tried and failed, it's too complicated 😢

I was trying that as well and it is indeed complicated.

@khaledhosny khaledhosny force-pushed the vf-fontinfo branch 2 times, most recently from 5fd5774 to f8a40e6 Compare January 31, 2024 18:07
@khaledhosny khaledhosny marked this pull request as ready for review January 31, 2024 18:08
@anthrotype
Copy link
Member

looking better now, thanks. Can we add some tests?

Move InfoCompiler into its own module, move all the info update logic
into it, make it explicit what attributes to merge, and handle vhea and
gasp tables.
Defcon does not allow setting Font.info, and copying ufoLib2 Info does
not seem to actually copy the values.

The solutions here seem too convoluted, but I don’t know if there is a
simpler alternative.
@khaledhosny
Copy link
Collaborator Author

Can we add some tests?

Done.

@anthrotype anthrotype merged commit a1ea19b into main Feb 2, 2024
9 checks passed
@anthrotype anthrotype deleted the vf-fontinfo branch February 2, 2024 10:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support public.fontInfo lib key for variable fonts
2 participants