emacs-devel
[Top][All Lists]
Advanced

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

Re: Buffer names with R2L characters


From: Stefan Monnier
Subject: Re: Buffer names with R2L characters
Date: Mon, 20 Jun 2011 14:00:34 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux)

> Once I had this half-working, the first thing I tested was visiting
> files whose names include R2L characters.  It works, but there's one
> problem: the "<N>" tails we attach to buffer names to make them
> unique.  The problem is that the '<' and '>' characters are "other
> neutral", or "ON", in the UAX#9 parlance, and so their directionality
> depends on the surrounding characters.  As result, a buffer name typed
> as ABCDEF<2> is displayed in the mode line like this:

> 2> FEDCBA>

Sounds like the same kind of issue as the one brought up a while ago
about bidi+XML (or any other mark up).

Another important case is when you use uniquify (in which case the
above will happen less frequently since file buffers add the directory
info to disambiguate the name, but may be replace by similar problems
if the separator between the file and directory part (typically /, or
\, or |) doesn't have the "right" bidi behavior).

> I verified this with the Unicode Reference Implementation, and there's
> no bug in bidi.c: this is the correct reordering according to the
> Unicode Bidirectional Algorithm.

> appending a suitable character to the end of the string (after the
> numeric tail) and making it invisible with text properties.  But this

Hmm, I would have expected that adding something at the end of the string
would not work ("too late"), whereas adding it between "ABCDEF" and
"<2>" would have felt very natural to me.
I guess it just shows how little I know of bidi,


        Stefan



reply via email to

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