emacs-bidi
[Top][All Lists]
Advanced

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

Re: [emacs-bidi] bidi categories


From: Ehud Karni
Subject: Re: [emacs-bidi] bidi categories
Date: Sat, 10 Nov 2001 18:37:21 +0200

On Fri, 09 Nov 2001 22:25:52 +0200, Eli Zaretskii <address@hidden> wrote:
> 
> > I looked at UAX#9 again, and while it describes the process of
> > transforming logical to visual order, it a) looks horribly complicated
> > and b) not reversible.  I guess that's old stuff for those who are
> > familiar with it...  :) Since the reverse operation is not defined
> > explicitly (did I miss it?), a certain amount of guess-work will be
> > needed.
> 
> I think that if you implement only the In clauses of UAX#9 (which
> resolve the implicit levels), you will get what you want, since
> visual-order text doesn't have explicit marks.  It seems to me that
> the implicit reordering is reversible.

The reverse process (visual -> logical) is simpler than logical ->
visual (because you can add as much formatting characters as you wish).
A simple way to do it is: 1. Add LRM at both ends of any SLS (strong L
string). 2. For left to right reading paragraph - inverse each of the
SLSs. For right to left reading paragraph - inverse each of the strings
that are NOT SLS. The optimization is to get rid of the redundant LRMs.

Some visual strings can not be represented by logical order without
formatting characters (thats why RLM and LRM where defined in the 1st
place).

Ehud.


-- 
 Ehud Karni     Mivtach - Simon  Insurance   /"\
 Tel: +972-3-7966-561 Fax: +972-3-7966-667   \ /  ASCII Ribbon Campaign
 (USA) Fax and  voice  mail: 1-815-5509341    X   Against  HTML  Mail
     Better     Safe     Than     Sorry      / \
     mailto:address@hidden    http://www.simonwiesel.co.il



reply via email to

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