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

add convertCubics to compileVariable; check no cubics if glyphDataFormat=0 #769

Merged
merged 2 commits into from
Jul 28, 2023

Conversation

anthrotype
Copy link
Member

compileTTF (for static TTF builds) already have a convertCubics=True that when set to False completely skips the cu2qu.
So I added one for the compileInterpolatableTTF/compileVariableTTF methods as well, so that from fontmake one can request to pass through the cubics unchanged.

Also I made so the OutlineTTFCompiler checks that if glyphDataFormat=0, then no cubic flags are set and raise an error in they do, prompting to either convert to quadratic or to explicitly allow allQuadratic=False (which in turn sets glyphDataFormat=1). This is to prevent from accidentally building glyf v1 table.

compileTTF already had a way to completely skip cu2qu, but the interpolatable/variable compile paths did not. Add it
to prevent one inadvertently produce an invalid TTF
@anthrotype anthrotype merged commit fbd1c5b into main Jul 28, 2023
7 checks passed
@anthrotype anthrotype deleted the no-convert-cubics branch July 28, 2023 16:58
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.

1 participant