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

[varLib.mutator] Mutator doesn't evaluate FeatureVariations #1244

Closed
robmck-ms opened this issue Apr 18, 2018 · 7 comments
Closed

[varLib.mutator] Mutator doesn't evaluate FeatureVariations #1244

robmck-ms opened this issue Apr 18, 2018 · 7 comments

Comments

@robmck-ms
Copy link
Contributor

Mutator doesn't evaluate the instance coordinate against FeatureVariations in GPOS/GSUB. So, if you have a font that makes use of FeatureVariations, and generate an instance at a place where something interesting happens (e.g. currency symbols switch to alternate forms that don't have a slash all the way through), you don't get the alternate behavior.

I'd guess that mutator could just evaluate the condition sets and fix up the references to lookup tables accordingly in the instance. Pruning unused lookups might be tricky, but leaving a few unused (and probably small) lookups might not be too bad in the meantime.

@behdad
Copy link
Member

behdad commented Apr 19, 2018

I'd guess that mutator could just evaluate the condition sets and fix up the references to lookup tables accordingly in the instance.

Right.

We should also turn fold 'rvrn' feature into another feature. Not clear what. 'ccmp' maybe. This was one of my issues with introducing a new feature.

Alternatively, if the feature is a single-substitute only, we can apply it to cmap.

Pruning unused lookups might be tricky, but leaving a few unused (and probably small) lookups might not be too bad in the meantime.

We have code for that in the subsetter, so shouldn't be a problem.

@behdad
Copy link
Member

behdad commented Jun 24, 2018

Can you share a test font please?

@justvanrossum
Copy link
Collaborator

I could build one, but that would take a while. Maybe @thundernixon or @petrvanblokland have a test font that uses FeatureVariations that's suitable for testing this? Or @irenevl? Or @thomgb?

@petrvanblokland
Copy link

I'll make one today.

@robmck-ms
Copy link
Contributor Author

You can also use Bahnschrift, which has 10 characters that use feature variations (e.g. dollar, oslash, etc).

Email me privately if you need a copy for testing purposes.

@behdad
Copy link
Member

behdad commented Oct 15, 2018

Any volunteers to take a look at this?

@behdad behdad closed this as completed in c4b4758 Oct 15, 2018
@robmck-ms
Copy link
Contributor Author

Thanks!

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

No branches or pull requests

4 participants