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

Automatically decompose when 2x2 transforms differ #698

Merged
merged 4 commits into from
Feb 3, 2023
Merged

Conversation

simoncozens
Copy link
Contributor

This fixes #507 (again).

  • Decompose glyphs if they have non-matching transforms
  • Compare the relevant part of the transformation only
  • Add a test

Copy link
Member

@anthrotype anthrotype left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is good, thanks Simon!

@anthrotype
Copy link
Member

can you also check if #695 gets fixed by this too?

@simoncozens
Copy link
Contributor Author

I'm not sure. It looks OK to me, but it also looks OK with the main branch as well. However, it was previously giving

WARNING:fontTools.varLib:glyph Ohorntilde has incompatible masters; skipping

and now it doesn't, so maybe?

@anthrotype
Copy link
Member

anthrotype commented Feb 3, 2023

yeah, that's it! varLib is dropping the variations for that composite glyph because the master components' transforms do not match (I think as result of this recent change in fonttools => fonttools/fonttools#2857)

@simoncozens simoncozens merged commit c84c77f into main Feb 3, 2023
@anthrotype
Copy link
Member

if you drop the font built with this branch in fontgoggles and type "ỡỠ" do both vary as you move along the wght axis? /cc @yanone

in that case, I would mark #695 as fixed by this as well

@anthrotype anthrotype deleted the fix-507-again branch February 3, 2023 12:36
@simoncozens
Copy link
Contributor Author

Yes, they do. But as I said, they seemed to do that for me before. I think it might involve different versions of fonttools too.

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.

decomposeTransformedComponents does not account for variable fonts
2 participants