googlefonts / fontdiff

tool for finding visual differences between two font versions

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Document how to automate comparison of Glyphs/fontmake output in README

davelab6 opened this issue · comments

To compare the output between Glyphs and fontmake using fontdiff, how can one build fonts with Glyphs using a shell script? Is there a headless version of Glyphsapp?

It would be great to systematically mass-test fontmake on a sizable number of *.glyphs files. This would ensure that fontmake produces fonts that are visually identical to those written in Glyphs.app. fontdiff can definitely play are role in this testing: call it with --before pointing to the {*.otf, *.ttf, *.ttc, *.otc} files produced by Glyphs.app, and --after pointing to the same files produced by fontmake. When there’s no difference, fontdiff will exit with status code zero.

To do this on a large number of fonts, Glyphs.app can probably be scripted. Would you be able to find out how exactly to do this? Some starting points would be here, or just ask on their support list.

I think some of the Google Fonts use the "advanced" Glyphs v2 features like smart components and corner components, but knowing what percentage of the collection can be built with fontmake flawlessly will be 👌

The the fonts that don't build fine would make a good todo list for fontmake.

The the fonts that don't build fine would make a good todo list for fontmake.

Absolutely. Actually, if you could make mini-examples (eg. a small Glyphs source file that has smart components, plus the expected compiled output from this source), they can be added to the fontmake codebase right ahead. fontmake already has continuous testing where a Glyphs file gets compiled with fontmake whenever somebody makes a GitHub pull request to the fontmake source. After building the font, the test compares the resulting binary font with fontdiff against a “golden” file that was originally produced by Glyphs. The test only passes if fontdiff says there is no visual difference between the two font files.

Great, thanks for the link! This is exactly the stuff I'm looking for at the moment.

Closing this bug since (afaik) there’s nothing fontdiff should do differently than now.

@brawer I re-titled the issue to make it clear what action I am proposing; I can make a PR to address this :)

Sure, go ahead. PR welcome.