I'm currently working on a type project that requires some opentype knowledge that I lack.
I would like to create a font that use contextual alternates to swap glyphs based on there occurence in the text.
Therefore the font would have to "count" the number of time a letter appear in the text and switch it if need be.
For exemple I'd like to be able to set an opentype feature that would swap the 25th "a" and 3rd "b" of the text with an alternative "a'' and "b". I'd like the font to be able to evolve depending on the content used and select additional letters based on the number of time that letter was used.
Is there a way to do something like that ?
I'm fairly new to font creation and open type features but I have some basic knowledge of Glyphs and Robotfont.