Swapping glyph names systematically for versions

Hello, I think there might already be an answer to this in the forum, I have a simple task and don’t have enough time to QA so be grateful if you can let me know your thoughts on this process.

I have multiple stylistic variants of glyphs:

a a.ss01 a.ss02

And I want to export 3 versions of my typeface for switching it on the web randomly during loading. The versions would be:

V1 (og file)
a a.ss01 a.ss02

V2 (rename 1)
a -> a.ss01 a.ss01 -> a.s002 a.ss02 -> a

V3 (rename 2)
a -> a.ss02 a.ss01 -> a a.ss02 -> a.ss01

It’s important that all the versions inherit their kerning values. Would this work if I perform the name change via opening .glyphs file as text and find-replace names? or is there a cleaner way of doing this?

Thanks!

You could do that with Rename Glyphs parameters in each of the instances. But why not solve it with a single font?

Thank you Rainer, rename glyphs parameter is a great idea. I did not think of that. I want different versions so I can load them randomly.

Just to provide some context, I have a calt feature working on the background to cycle through alternates. I want more variation in the website so the cycling pattern changes on every reload, this will be helpful especially for static text that would load the exact pattern on every visit.

Would love to hear if there is a way to do this in a single font. Anyways, thanks for the quick answer!

You can add stylistic sets that triggers another set of randomness. On the website, set the feature randomly.

What Georg said.

You said kerning was a concern. If you keep it in the single font, you always have kerning between all glyphs. Currently there is no cross-font kerning (except perhaps with Adobe’s optical kerning, but I am not sure).

Rainer and Georg, thank you for answering my question. Both options you laid out will work :pray:

1 Like