Contextual substitution in Stylistic Sets


I have an Arabic font engineered with a Cursive attachment, with many Glyphs Alternatives and Stylistic sets, All things going well, but I have a small inquiry, how can I make a contextual substitution with Stylistic Sets?

I can’t share any references now for this project, but I made a simple screenshot for you.

here the Rule

lookup returned_yeh {
sub behDotless-ar.init’ [yeh-ar.ss16 alefMaksura-ar.fina.ss16] by behDotless-ar.init.ss16;
} returned_yeh;

so, if you have any advice, it’s well be appreciated.

You don’t need to write your own code, this can be completely automated. Just add the .ss16 glyphs to your font, update the feature code, and make sure the ss16 feature is ordered after the positional features (init, medi, fina, isol).

Thank you @mekkablue

The idea here different from the default process, i have two yeh-ar.fina, one from them is in .ss16 this yeh need specific behDotless-ar.init which i put also in the same stylistic set, i need the yeh-ar.fina.ss16 is work always with behDotless-ar.init.ss16 not with the default behDotless-ar.init

@mekkablue here is the order

In what feature do you have the contextual code?

Then test it in ss16

Is the initial beh (ss16) only for the yeh ss16? Or is it suitable for all ss16 letters?

1 Like

@mekkablue yes, works for yeh ss16 only

@GeorgSeifert @mekkablue
my conclusion now is we can’t make a contextual sub., to a Stylistic set.
the problem is solved when I changed the feature from .ss16 to .cv01

Where did you test this?
Can you send me the font?

1 Like

I was test it through FontGoggles, illustrator & MS Word.
Sure, I’ll send you the file.

Hello @GeorgSeifert George, please check your messages.

I had a look at file. Can you specify what character you typed and what glyphs you expect to show?

great @GeorgSeifert thank you, those connections work well بي

the problem - in attachment - with coding behDotless-ar.init.ss20 + alefMaksura-ar.fina.ss16

@GeorgSeifert @mekkablue issue solved.