In Arabic and some other languages a character has two or three forms which will find its appropriate one automatically when you type a word (according to its previous and next characters). How can one change or add these automatic rules?

For example there's no rule for this character and so if I set a key for this character, it will not find its appropriate form in a word, unless I set different keys for different forms . How can I add/program a mapping rule for this character? or set the same rule as this character for it?

I want to know which script, program, etc finds the appropriate form of character (ه) and how can I set the same thing for character (ۀ). there's a key for the first one and if I select Arabic language layout then press the key several times: هههه but for the second: ۀۀۀۀۀ. something is missing for the second character. I want to bridge the gap.

  • Are you looking for a generic implementation that works with multiple programs? As far as I remember from Japanese the composition of characters not found on the keyboard is done by each specific program handling text, not the OS. – Anthon Dec 16 '13 at 5:35
  • The handling of contextual forms is program-specific (rather than operating-system specific), and rather complicated. It is rather unlikely that you could tune such handling except by editing program source code. The issue has really nothing to do with character encoding. You should clarify the question by presenting your specific problem (in the question itself, not just in comments). – Jukka K. Korpela Dec 16 '13 at 8:38
  • I checked that in Windows, the character ۀ works as desired. But when I install that Windows program in wine, typing ۀ cannot find the correct morph. This suggests that it is the OS that decides about character morphs while typing; and not the programs themselves. – user54651 Dec 16 '13 at 11:11

I don't know about a generalized approach, but I managed to achieve what you want in this particular case by using the decomposed form of this grapheme cluster. The site I linked to, for some reason, decomposes it into "Arabic letter AE" (U+06D5) + "Arabic hamza above" (U+0654), which still doesn't give the correct connected forms. If you, however, decompose it as (the more intuitive) "Arabic letter heh" (U+0647) + "Arabic hamza above" (U+0654), you get the required result:


Each one of the above grapheme clusters is (U+0647) followed by (U+0654).

| improve this answer | |
  • a bad thing is that this setting contains 6 characters, dashing any dream of assigning a single key for ۀ. – user54651 Dec 16 '13 at 10:45
  • @MinimusHeximus You can't win 'em all, I guess... – Joseph R. Dec 16 '13 at 10:49

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy