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

drop kern pairs with mixed bidi type #361

Merged
merged 2 commits into from
Feb 7, 2020

Conversation

anthrotype
Copy link
Member

... as kerning across direction runs doesn't work in current implementations.
Also, we can't guess the designer's intention as to the "true" direction of these kern pairs with mixed bidi. So for now we warn and prune them. Maybe revise once we'll have defined that new "visual" hkerning.plist.

PTAL @khaledhosny

Incidentally also this fixes #341 because it removes the chance that feaLib will produce two PairPos2 subtables with overlapping coverages.
The split occurs when, within the same FEA lookup block definition, there are mutliple pos rules with different value record format (format A is used for LTR kern pairs [modifying only XAdvance of first glyph], format B for RTL kern pairs[modifying both XAdvance and XPlacement]).
Instead of splitting, feaLib should fill with 0 the missing values then figure out a heuristic to store the matrix optimally (see fonttools/fonttools#1731).

@anthrotype anthrotype merged commit 1c271d3 into googlefonts:master Feb 7, 2020
@anthrotype anthrotype deleted the prune-mixed-bidi-kerns branch February 7, 2020 17:50
@kontur
Copy link
Contributor

kontur commented Feb 10, 2020

@anthrotype Thank you very much for the help debugging this and the quick solution ❤️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants