[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: bidi and shaping problems in describe-input-method

From: Kenichi Handa
Subject: Re: bidi and shaping problems in describe-input-method
Date: Fri, 09 Mar 2012 08:48:35 +0900

In article <address@hidden>, Eli Zaretskii <address@hidden> writes:

> > just setting bidi-paragraph-direction to 'left-to-right is
> > not enough, because keyboard cells in a row are still
> > re-ordered.

> Right.  I didn't notice it because I don't read Arabic.

That's re-ordering happens for Hebrew input method too. :-p

> > For this, the easiest fix is to set bidi-display-reordering to nil.
> > But, then we can't use actual Arabic and Hebrew words in the
> > docstrings of those input methods.  What we want is to display bidi
> > reordering only for the keyboard layout part.  Eli, don't you have
> > any good idea?

> Revision 107535 is the best I can do.  I'll let Mohsen judge if it's
> good enough.

If possible, I'd like to avoid inserting LRM
unconditionally.  Is it possible to have this kind of

(defun quail-help-require-LRM (char)
   (or (eq (get-char-code-property char 'bidi-class) 'L)

Then, we can use it in quail-insert-kbd-layout as below:

   (if (quail-help-require-LRM (if (stringp lower) (aref lower 0) lower))
       (insert #x200e))
   (insert lower)
   (if (quail-help-require-LRM (if (stringp upper) (aref upper 0) upper))
       (insert #x200e))
   (insert upper)

Kenichi Handa

reply via email to

[Prev in Thread] Current Thread [Next in Thread]