Ssty feature with single alternate

If I have glyphs with suffixes .ssty1, ssty2, Glyphs will generate alternate substitution feature (see Generating alternate substitution features), which is all good.

Now sometimes a glyph might have one alternate, either with suffix .ssty or .ssty1. In the former case Glyphs will not generate any thing at all, and in the later it will generate alternate substitution with only one alternate:

sub A from [A.ssty1];

Due to the nature of how this feature is used, there should always be two alternates (math engines will apply ssty=1 for first level scripts, and ssty=2 for second level, and if there is only one alternate then the later will fallback to the base glyph which is not desired), so in both cases I think Glyphs should generate something like:

sub A from [A.ssty A.ssty];


sub A from [A.ssty1 A.ssty1];

I implemented the form with .ssty1. Without the number would need more changes. Hope that is OK.

1 Like

Out of curiosity, do you know if there are circumstances where the value 0 and 1 glyphs should differ?

I’d prefer not having to name them with .ssty1 suffix, but it is not a deal breaker.

I’m not sure I get the question.

I just confused myself; the glyph for a feature value of 0 world be the original glyph, not the first in the from class. All is well.

1 Like