[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [emacs-bidi] mirroring of glyphs
From: |
Alex Schroeder |
Subject: |
Re: [emacs-bidi] mirroring of glyphs |
Date: |
Sun, 18 Nov 2001 22:15:10 +0100 |
User-agent: |
Gnus/5.090004 (Oort Gnus v0.04) Emacs/21.1 (i686-pc-linux-gnu) |
"Eli Zaretskii" <address@hidden> writes:
>> From: Alex Schroeder <address@hidden>
>> Date: Sat, 17 Nov 2001 15:55:58 +0100
>>
>> Perhaps you see something I am missing. I list various
>> definitions of bidi-visual-to-logical, together with input, output,
>> and expected output.
>
> It's very hard to look at this without a few debugging aids. One such
> tool that helps a lot is to print the input string with final resolved
> levels under every character. Could you add such a feature and post
> the results with the problematic strings?
I have actually resigned myself to the inevitable. It is not
possible. I think Ehud already mentioned this in a previous post.
Anyway, here are some examples to illustrate this. There are certain
logical representations which yield the same visual representation:
(string= (bidi-logical-to-visual "my CAR123")
(bidi-logical-to-visual "my 123CAR"))
=> t
Therefore the reverse operation must only return one of the many
possible logical representations in order to be correct:
(bidi-visual-to-logical
(bidi-logical-to-visual "my CAR123") 'L2R)
=> "my 123CAR"
The same is true for the one remaining problem test case from the PGBA
page:
(bidi-visual-to-logical "<123H/>shalom<123H>" 'R2L)
=> "<Hshalom<123</H123>"
What I didn't appreciate is that this is just one of the many possible
logical representations for the same string:
(bidi-logical-to-visual (bidi-visual-to-logical "<123H/>shalom<123H>" 'R2L))
=> "<123H/>shalom<123H>"
Therefore the current bidi implementation is as good as it gets. :)
--
http://www.emacswiki.org/
- Re: [emacs-bidi] mirroring of glyphs, (continued)
- Re: [emacs-bidi] mirroring of glyphs, Alex Schroeder, 2001/11/18
- Re: [emacs-bidi] mirroring of glyphs, Eli Zaretskii, 2001/11/19
- Re: [emacs-bidi] mirroring of glyphs, Alex Schroeder, 2001/11/19
- Re: [emacs-bidi] mirroring of glyphs, Eli Zaretskii, 2001/11/19
- Re: [emacs-bidi] mirroring of glyphs, Alex Schroeder, 2001/11/19
- Re: [emacs-bidi] mirroring of glyphs, Eli Zaretskii, 2001/11/19
- Re: [emacs-bidi] mirroring of glyphs, Alex Schroeder, 2001/11/19
- Re: [emacs-bidi] mirroring of glyphs, Eli Zaretskii, 2001/11/20
- Re: [emacs-bidi] mirroring of glyphs, Alex Schroeder, 2001/11/20
- Re: [emacs-bidi] mirroring of glyphs, Eli Zaretskii, 2001/11/20
- Re: [emacs-bidi] mirroring of glyphs,
Alex Schroeder <=
- Re: [emacs-bidi] mirroring of glyphs, Eli Zaretskii, 2001/11/19
- Re: [emacs-bidi] debugging visual-to-logical, Alex Schroeder, 2001/11/19
- Re: [emacs-bidi] debugging visual-to-logical, Eli Zaretskii, 2001/11/19
- Re: [emacs-bidi] debugging visual-to-logical, Alex Schroeder, 2001/11/19
- Re: [emacs-bidi] debugging visual-to-logical, Eli Zaretskii, 2001/11/19
- Re: [emacs-bidi] mirroring of glyphs, Yair Friedman (Jerusalem), 2001/11/19
- Re: [emacs-bidi] mirroring of glyphs, Eli Zaretskii, 2001/11/19
- Re: [emacs-bidi] mirroring of glyphs, Yair Friedman (Jerusalem), 2001/11/20
- Re: [emacs-bidi] mirroring of glyphs, Eli Zaretskii, 2001/11/20
- Re: [emacs-bidi] mirroring of glyphs, Yair Friedman (Jerusalem), 2001/11/21