unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: ehud@unix.mvs.co.il
Cc: stephen@xemacs.org, miles@gnu.org, monnier@iro.umontreal.ca,
	cloos@jhcloos.com, emacs-devel@gnu.org
Subject: Re: Buffer names with R2L characters
Date: Tue, 21 Jun 2011 20:24:04 +0300	[thread overview]
Message-ID: <83wrgfumh7.fsf@gnu.org> (raw)
In-Reply-To: <201106211652.p5LGqIGr016636@beta.mvs.co.il>

> Date: Tue, 21 Jun 2011 19:52:18 +0300
> From: "Ehud Karni" <ehud@unix.mvs.co.il>
> Cc: emacs-devel@gnu.org, monnier@iro.umontreal.ca, cloos@jhcloos.com,
>         stephen@xemacs.org, miles@gnu.org
> 
> >   2>FEDCBA>
> >
> > [snip]
> >
> > I can fix this .... by appending a suitable character to the end of
> > the string (after the numeric tail) and making it invisible with text
> > properties.
> 
> The "right" way to fix this is to have the buffer name between 2 zero
> width LRM characters.

First, why do we need the LRM at the beginning?  The mode line is
formatted with L2R "paragraph direction", so the leading LRM is
unneeded (though won't do any harm).  The "*Buffer List*" buffer is
forced to use L2R paragraph direction as well, so the leading LRM is
not needed there as well.

And second, what do you mean by "zero width"?  The current facilities
let me change the LRM display only globally, so I cannot make these
LRM characters zero-width only in the mode line -- they will be
displayed as such in all the buffers and strings.  Moreover, I'm not
sure TTYs support zero-width.

Instead, I propose to make the LRM invisible.  This is supported on
all display types.

> I think Eli is wrong here. An example will help, a file with the
> (logical) name "/abc/def GHIK/LMNO qrst" when uniquified will appear
> as: "def ONML|KIHG qrst" which is clearly wrong.
> 
> My way to solve it is as above, i.e. add zero width LRM on both sides
> of the separator (/ or |) in addition to the enclosing LRMs.

I think this is beginning to become gross.

> The problem is even greater in `dired' with files that have ALL Hebrew
> names. If you have a Hebrew locale, the date has Hebrew in it (the
> month name) then it has some digits and ":" (all neutrals and weak
> L2R ) and then the file name. The bidi algorithm actually exchange
> the month and file name.

Yes, Dired (and other similar modes) will "need work" (TM) to give a
plausible display with bidi.  Patches are welcome.



  reply	other threads:[~2011-06-21 17:24 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-06-20 16:21 Buffer names with R2L characters Eli Zaretskii
2011-06-20 18:00 ` Stefan Monnier
2011-06-20 20:52   ` Eli Zaretskii
2011-06-20 20:13 ` James Cloos
2011-06-20 21:08   ` Eli Zaretskii
2011-06-21  4:26     ` Stephen J. Turnbull
2011-06-21  6:28       ` Eli Zaretskii
2011-06-21  8:44         ` Stephen J. Turnbull
2011-06-21 14:28           ` Eli Zaretskii
2011-06-21  4:33     ` Miles Bader
2011-06-21  6:30       ` Eli Zaretskii
2011-06-21  7:26       ` David Kastrup
2011-06-20 21:06 ` Kalle Olavi Niemitalo
2011-06-21  2:51   ` Eli Zaretskii
2011-06-21 16:52 ` Ehud Karni
2011-06-21 17:24   ` Eli Zaretskii [this message]
2011-06-21 17:59     ` Ehud Karni
2011-06-21 18:10       ` Eli Zaretskii
2011-06-22 22:27       ` Stefan Monnier
2011-06-23  9:16         ` Eli Zaretskii
2011-06-25 13:25           ` Stefan Monnier

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=83wrgfumh7.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=cloos@jhcloos.com \
    --cc=ehud@unix.mvs.co.il \
    --cc=emacs-devel@gnu.org \
    --cc=miles@gnu.org \
    --cc=monnier@iro.umontreal.ca \
    --cc=stephen@xemacs.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).