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

font.interpolate with incompatible layerOrders + a public.default layer name #674

Open
typemytype opened this issue Nov 9, 2022 · 1 comment

Comments

@typemytype
Copy link
Member

When two sources have different defaultLayers and different layerOrders and one of the layers is called public.default, it is not possible to write to disk as public.default must be the default layer (see the UFO spec)

Some options:

  • rename the public.default layer name if this is not the default layer
  • only apply interpolation on the defaultLayer (whatever the name is) font.interpolate also means interpolating all layers, so I dont like this option
  • only interpolate layers with the same name (my preference, as you can always do layer.interpolate or glyph.interpolate) + warn missing layer names. This should not break existing implementations.

came up in https://robofontcommunity.slack.com/archives/C03A6AYH6TE/p1667999235159179

@typemytype
Copy link
Member Author

a quick fix as fontParts already does the 3th option: only interpolate layers with the same name (see)

dont set the font.defaultLayerName based on the layerOrder, but check first if "public.default" is available as layer name

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

1 participant