Skip to content

Conversation

@simoncozens
Copy link
Contributor

This adds a CLI interface to the instantiator; useful for testing/debugging and also actually instantiating UFOs!

Can be used either with an instance name:

% python3 -m fontmake.instantiator --output-dir instance_ufo GlyphsUnitTestSans.designspace Light
Generated instance 'Light'.
Saved to 'instance_ufo/GlyphsUnitTestSans-Light.ufo'.

or with coordinates:

% python3 -m fontmake.instantiator --output-dir instance_ufo GlyphsUnitTestSans.designspace wght=523
Generated instance 'wght=523'.
Saved to 'instance_ufo/GlyphsUnitTestSans-wght523.ufo'.

@anthrotype
Copy link
Member

doesn't the fontmake CLI already allow you to make instance UFOs and select specific named instances? Maybe we could simply add an option to instantiate at some arbitrary location..

@anthrotype
Copy link
Member

i worry that we may then have to support multiple ways to accomplish the same thing, that's all

@simoncozens
Copy link
Contributor Author

That does make sense. I was seeing instantiator as a self-contained bit of code, but of course within fontmake it can do almost all of this.

@anthrotype
Copy link
Member

I actually wanted to move that module out of fontmake (which I see just as the command line front-end) to ufo2ft (which is a library doing most of the building logic), but never got around doing that.

@simoncozens
Copy link
Contributor Author

Could we make it a separate project altogether? That way if we ever need to replace the instantiator with a different implementation it's all nicely compartmentalised...

@anthrotype
Copy link
Member

yeah probably better that way

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.

2 participants