Howto: what's the best way to make a Stylistic Set with marks and ligatures

Hi guys,

I’m working on organising my Stylistic Sets and Discretionary Ligatures. I’m wondering what’s the best way to automate the following:

I’ve got a .ss01 class with these glyphs in it:
A.ss01, Aacute.ss01, Abreve.ss01, Acircumflex.ss01, Agrave.ss01, Amacron.ss01, Aogonek.ss01, Aring.ss01, Atilde.ss01

The A is an alternate glyph for the standard A. It’s actually the original A when I first designed the typeface. For the reworked version I’ve decided to go for a new A, but I’d like to keep the original in the font and make it accessible through a stylistic set (for the fan boys).

Now, I’d like to add Ligatures to this set of alternate glyphs, the T_A for instance:

47

This ligature should also have the same marks/accents as the original set above (of course).

What would be the best way to do this? Since the alternate A is called A.ss01 I can’t generate the OT feature with the T-Aacute.ss01 (for instance) automatically. It just won’t take it, presumably because it’s a ligature.

If I turn ‘generate feature automatically’ off, and add the ligature myself, it works just fine.

sub A by A.ss01;
sub Aacute by Aacute.ss01;
sub Abreve by Abreve.ss01;
sub Acircumflex by Acircumflex.ss01;
sub Agrave by Agrave.ss01;
sub Amacron by Amacron.ss01;
sub Aogonek by Aogonek.ss01;
sub Aring by Aring.ss01;
sub Atilde by Atilde.ss01;
sub T A.ss01 by T-A.ss01;

But that’s not really practical. I’f change the group, I’d need to do it all by hand, since the automatic feature is turned off.

Question
What would be the best way to achieve this? Create an OT feature that works automatically, holds the alternate A and the ligatures with their marks.

The name of the Ligature is not correct. It should be T_A.ss01.

Then you need to decide if you have the liga or the ss01 feature first. Normally, ss01 is a simple one to one feature. So you could set it first and then to the ligature in the appropriate liga feature (liga or dlig).

ss01:

sub A by A.ss01;
sub Aacute by Aacute.ss01;
sub Abreve by Abreve.ss01;
...

and dlig:

sub T A.ss01 by T_A.ss01;
sub T Aacute.ss01 by T_Aacute.ss01;
sub T Abreve.ss01 by T_Abreve.ss01;
...

Instead of adding all the accent-ligatures, you could do a decomposition of the accents and then use mark positioning on the base ligature. That will work in browsers but Indesign still needs the “Works
Ready Composer” activated to make his to work.

But do you actually need the ligature? What happens if you just overlap the T and the A.ss01 (and add some kerning)? Or if the “T” looks different, just have a T.ss01?

The last case is the only one where you get away with automatic feature code.

From my understanding, T_Aacute.ss01 won’t automatically generate if you don’t already have T_Aacute built because you need to have a ligature first in order to swap it out for an alternate.

However, if you want your T_Aacute to equal T_Aacute.ss01, then you can generate all of your ligatures with recipes like T+Aacute.ss01=T_Aacute, and so on.

Doing it with overlap and kerning was my first thought, but the geometry doesn’t allow for a clean overlap.

I thought about making a separate glyph from the ‘bridge’ in-between and then do some kerning magic. But I felt this would cause a lot more difficulties then to just create a good ligature and let OT do the job.

But creating a T with a long right arm might just do the job. Good hint. Who will ever notice. :wink:

PS: Usually I’m making my fonts pretty straight forward. I try to make as many glyphs as possible and do OT right. Having all these glyphs in the font makes it easy to swap them out if OT doesn’t work in your app. I know it’s kinda oldskool and automation / positioning / etc does a really good job, but selecting a glyph from the Glyphs panel in Indesign is just a pleasure. I do it all the time. No hassle with looking for the right OT feature.
Having said that, I realise that it just needs to work if you activate an OT feature. Just for playing sake. :wink:

Thanks for your help.

Make an alternate /T with a right top that will overlap the /A; no kerning, just a simple substitution. I would make it the same shape as the regular /T in case a user wants to use it for something else.

Yes, definitely a contextual T. Otherwise you go crazy with diacritics.

If I would make an alternate /T (with a long right leg?) and negative sidebarings, so that the alternate /A would fit in nicely. How would I have to set up the OT feature? What would that look like?

It would need to change the /T and also, contextually, the /A with diacritics.

Just add call it T.ss01. Then it will be active with the A.ss01, unless the user deselects the stylistic set for the T. to cover that, add a

sub T' A.ss01 by T.ss01;

at the end of the ss01 feature.

1 Like

Well… I would not call it T.ss01 because it is supposed to be only in front of the A.ss01 if I understand it correctly. I would add the line above in a lookup at the end of ss01, like this:

lookup alternateT {
   sub @T' @Ass01 by @Talt;
} alternateT;

… and create OT feature classes, T with all default T’s (T, Tcommaccent, Tbar…), Talt with alternate T’s with whichever suffix you choose (T.alt, Tcommaccent.alt, Tbar.alt…) and in Ass01 all the A’s of stylistic set 1.

And then, perhaps, call the lookup again in calt, like this:

lookup alternateT;

…which covers the eventuality where a user adds A.ss01 from a glyph palette, and it happens to end up next to a T. Or where the user only applies ss01 to the A’s.

1 Like