On 2/19/24 9:26 PM, Avid Seeker wrote:
When pressing backspace on Arabic ligatures (including characters with diacritics), they are removed as if they are one character.
As you might guess, readline doesn't know much about Arabic, per se. In a UTF-8 locale, for example, it knows base characters and combining characters. The idea is simple: when moving backwards, move one multibyte character at a time, ignoring combining characters, until you get to a character for which wcwidth(x) > 0, and move point there. The algorithm for moving forward is similar. How should this be modified to support Arabic in a portable way? -- ``The lyf so short, the craft so long to lerne.'' - Chaucer ``Ars longa, vita brevis'' - Hippocrates Chet Ramey, UTech, CWRU c...@case.edu http://tiswww.cwru.edu/~chet/
OpenPGP_signature.asc
Description: OpenPGP digital signature