Baseline shift with contextual alts

Hi, has anyone experienced this issue? I have a font with two sets of alts for each lowercase glyph, and a Contextual Alternates feature to control them. In InDesign however, with Contextual Alternates switched on, the glyphs revert to the standard glyphs when Baseline Shift is applied. InDesign actually switches my glyphs. Same behaviour in Illustrator, and both are current versions. I have generated the calt feature according to the Glyphs tutorial. The font also contains 3 x stylistic sets. I have never seen this before, any ideas?

OpenType features can and should only work within the same style run. If one glyph has a certain style applied (e.g. baseline shift), it cannot and should not be substitution context for other glyphs with a different style.

If it does not work even though all letters have the same style applied, then it may be an implementation issue in that particular software. If that is the case, then there is not much you can do from within the font.

For clarity, when all text is baseline shifted no substitution occurs. When a word, part of the word, or a single character is baseline shifted, ALL subsequent glyphs substitute whether they are selected or not.

If it does not work even though all letters have the same style applied, then it may be an implementation issue in that particular software.
It does work when all letters have the same style applied. It’s only when part of the text has the style applied that the problem occurs.

This doesn’t seem likely to be an implementation issue in InDesign and Illustrator. Here is my calts code:

sub @DEFAULT @DEFAULT’ by @ALT1;

sub @ALT1 @DEFAULT’ by @ALT2;

sub @Con0 @Con0’ by @Con1;

sub @Con1 @Con0’ by @Con2;

sub @Con0 [@Vow0 @Vow1 @Vow2 @Etc] @Con0’ by @Con1;

sub @Con1 [@Vow0 @Vow1 @Vow2 @Etc] @Con0’ by @Con2;

sub @Con0 [@Vow0 @Vow1 @Vow2 @Etc] [@Vow0 @Vow1 @Vow2 @Etc] @Con0’ by @Con1;

sub @Con1 [@Vow0 @Vow1 @Vow2 @Etc] [@Vow0 @Vow1 @Vow2 @Etc] @Con0’ by @Con2;

# vowel-vowel

sub @Vow0 @Vow0’ by @Vow1;

sub @Vow1 @Vow0’ by @Vow2;

# vowel-other-vowel

sub @Vow0 [@Con0 @Con1 @Con2 @Etc] @Vow0’ by @Vow1;

sub @Vow1 [@Con0 @Con1 @Con2 @Etc] @Vow0’ by @Vow2;

# vowel-other-other-vowel

sub @Vow0 [@Con0 @Con1 @Con2 @Etc] [@Con0 @Con1 @Con2 @Etc] @Vow0’ by @Vow1;

sub @Vow1 [@Con0 @Con1 @Con2 @Etc] [@Con0 @Con1 @Con2 @Etc] @Vow0’ by @Vow2;

# vowel-other-other-other-vowel

sub @Vow0 [@Con0 @Con1 @Con2 @Etc] [@Con0 @Con1 @Con2 @Etc] [@Con0 @Con1 @Con2 @Etc] @Vow0’ by @Vow1;

sub @Vow1 [@Con0 @Con1 @Con2 @Etc] [@Con0 @Con1 @Con2 @Etc] [@Con0 @Con1 @Con2 @Etc] @Vow0’ by @Vow2;

Your font is fine, this is indeed an Adobe issue. Take a look at @LiebeFonts’ video from Typolabs 2018 for potential workarounds:

1 Like

Do you apply the baseline shift in InDesign/Illustrator or through an GPOS feature in your font?

In the app, with the function in the character palette.

1 Like

Yes Ulrike, my client was assuming they can use Baseline Shift in the Character palette of InDesign as normal, but when they did it triggered the behaviour described above. I have watched your excellent TypoLabs presentation but I am unsure whether any of your workarounds will apply in this case. Possibly the rlig feature, but it works only in InDesign which is a concern because my client will expect same behaviour across all Adobe apps. Do you have any suggestions?

1 Like

I think they are out of luck. I assume Opentype substitution features are incompatible with the baseline offset. :confused:

1 Like

The latest version of Illustrator should support rlig.

1 Like

Unfortunately, rlig won’t fix that problem. It will be treated the same as calt.
My suggestion would be to add an OT feature in your font, that triggers a baseline shift, that your client can turn off and on through an stylistic set.

1 Like

Thanks Ulrike :slight_smile:

1 Like