OT features for arabic fonts

Options
Hi,
I'm working on implementing some OT features like fractions, (ayah, year, page-number, footnote etc) marks/symbols for arabic type face.
For fractions, I used 'fractions fever' script as a base for my hindi and persian numbers, it works as expected in FontGoggle, but show up inverted in Adobe Indesign/Illustrator and does not work at all in MS Word.
The other marks/symbols work as expected in Indesign/Illustrator CC 2020 but not as expected in MS word and older Adobe apps.
Here is some screenshots:
Fractions in FontGoggle:


Fractions in Adobe CC 2020 apps: As you can see, 'Character Direction' should be set to RTL for the fraction to work, and yet it shows up inverted: ٦٥/٨٧ ٨٩/٧٤



Ayah, year symbols shows up correctly:



In MS Word:


Fractions OT code is automatically generated by a modified version of Fractions Fever. The rest is hand coded. I'm using Glyphs as type design software.
page.txt file contains code used for page symbol that goes under calt feature (I tried to put it under rclt but it did not work)
number.txt file contains code for number symbol with different approach (but it does not work if I use one or two nombers, only works with three numbers)

What do you suggest to improve this? Is it good to put those symbols code under contextual alternates? or you have a better suggestion for them?
And thank you in advance.

Comments

  • Kamal Mansour
    Options
    Note that the RightToLeft flag should only be used in the GPOS cursive lookup (see link below). I can't be sure that it is causing any problems in your page_rclt* lookups, but it's worth removing them to test again. I've had good results putting such lookups under either calt or even rlig

    MS Word is sometime unpredictable with functions like page or ayah. Try running the same tests under Notepad or Wordpad because their OpenType processing is simpler. Sometimes entering the text under Notepad, then pasting it into MS Word, will give better results than doing so directly in Word.

    Unicode classifies Arabic/Hindi numbers as left-to-right, not right-to-left. If you examine the number 1234 or ١٢٣٤, you can see that both forms flow from the left to the right, even in the context of Arabic text. 

    Details on cursive lookups:
    https://docs.microsoft.com/en-us/typography/opentype/spec/gpos#lookup-type-3-cursive-attachment-positioning-subtable