OpenType feature doesn't work in Adobe Illustrator

Hello everybody!

Can you please help understand what is wrong with OpenType features in my font. I have two features that I’m working on:

  1. feature swsh - which turns 0-9 numbers into swashes if typed before any letter,

  2. feature calt that changes first letter into init shape of letter

All of the features work properly in Glyph. But they don’t work in Adobe Illustrator!! In particular:

  • first letter in any word changes into init - WORKS,
  • number turns into swash when being typed before any letter - WORKS,
  • first letter stay default shape when I type number that turns into swash - DOESN’T WORK. I don’t understand why it still becomes init because it’s no longer the first letter of the word-((

The problem is that I am working on script font now. So initial form doesn’t have this curve at the beginning of the letter where the swash attaches. And thus my swash looks like a separate symbol and it doesn’t attach to the following letter, while it perfectly attaches in case of my default shape of letters.

Any idea what is wrong?

Thank you!!

I don’t understand what that means. Can we see your feature code? And in which feature are you doing this? Does it work in InDesign? AI does not support all features.

Thank you. I don’t have inDesign, but i will try to find it tomorrow. Can I publish a screenshot with feature code here? Is it ok with you?

Can you just paste the code please?

Thank you! Could you please have a look.

This is my salt feature:

# consonant-consonant
sub @Con0 @Con0' by @Con1;
# consonant-other-consonant
sub @Con0 [@Voc0 @Voc1 @Etc] @Con0' by @Con1;
# consonant-other-other-consonant
sub @Con0 [@Voc0 @Voc1 @Etc] [@Voc0 @Voc1 @Etc] @Con0' by @Con1;
# vowel-vowel
sub @Voc0 @Voc0' by @Voc1;
# vowel-other-vowel
sub @Voc0 [@Con0 @Con1 @Etc] @Voc0' by @Voc1;
# vowel-other-other-vowel
sub @Voc0 [@Con0 @Con1 @Etc] [@Con0 @Con1 @Etc] @Voc0' by @Voc1;

In this feature i’m trying to substitute default letter by initial letter in case it follows any letter or number:

lookup InitForms {

	ignore sub [@AnyLetter @Numbers]  @initDef';

	sub @initDef' by @initSub;

} InitForms;

This is my swsh feature substituting any number typed before/after any letter by specially designed swashes:

sub zero' @ALL by zero1.swsh;
sub one' @ALL by one1.swsh;
sub two' @ALL by two1.swsh;
sub three' @ALL by three1.swsh;
sub four' @ALL by four1.swsh;
sub five' @ALL by five1.swsh;
sub six' @ALL by six1.swsh;
sub seven' @ALL by seven1.swsh;
sub eight' @ALL by eight1.swsh;
sub nine' @ALL by nine1.swsh;

sub @ALL one' by one2.swsh;
sub @ALL two' by two2.swsh;
sub @ALL three' by three2.swsh;
sub @ALL four' by four2.swsh;
sub @ALL five' by five2.swsh;
sub @ALL six' by six2.swsh;
sub @ALL seven' by seven2.swsh;
sub @ALL eight' by eight2.swsh;
sub @ALL nine' by nine2.swsh;
sub @ALL zero' by zero2.swsh;

Today I realized my mistake was I didn’t use brackets [ ] in this line:

ignore sub [@AnyLetter @Numbers]  @initDef';

So now it works more or less. But there is another problem - sometimes my initial form doesn’t work at the beginning of the letter. I assume it is because I put the following order in my salt: default - ss01 - default - ss01 etc. So my question is can I somehow exclude space out of default letters? In order to have all my first letters as initial??

1 Like