emacs-devel
[Top][All Lists]
Advanced

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

Re: bidi-display-reordering is now non-nil by default


From: Eli Zaretskii
Subject: Re: bidi-display-reordering is now non-nil by default
Date: Sun, 31 Jul 2011 05:34:35 -0400

> From: David Kastrup <address@hidden>
> Date: Sun, 31 Jul 2011 11:15:24 +0200
> 
> > The paragraph direction is determined by the paragraph beginning, not
> > by all of it.  The first "strong directional" character in the
> > paragraph, either a left-to-right character or a right-to-left
> > character, will determine the base direction of that paragraph.  E.g.,
> > a single Latin letter is all that's needed for determining that the
> > paragraph direction is left-to-right.
> 
> So we are apparently searching for the paragraph beginning of a
> humongous paragraph for each keystroke.

In the case in point, yes.  Also for each cursor motion command.

> >> It might also be reasonable to set the paragraph boundary detection
> >> regexps to nil in buffers where no paragraphs will ever be found
> >
> > How to detect these buffers?
> 
> I was not suggesting detecting them.  I was suggesting that modes
> creating buffers where paragraphs are not a usable concept disable
> paragraph detection.  Manually.

Setting bidi-paragraph-direction to a non-nil value has precisely the
same effect, except that it will also DTRT when the mode wants all its
paragraphs have right-to-left direction.  Disabling detection of
paragraph direction can only support left-to-right, by contrast (or
some other static default).

> That's another bottomless pit

We could do this through the modes (buffer-menu.el already does), but
my concern was about modes that are not bundled with Emacs, such as
mew, which was what triggered this thread in the first place.  There's
also a bug #9209 about a similar problem with vm, another unbundled
package; I haven't yet heard from the OP in that case, but I presume
the reason is identical.

That is why I suggested to have a list of known names of buffers that
need a certain fixed value of bidi-paragraph-direction.  But that idea
is by no means sacred; if there are better ones, let's hear them.

> but at least it approaches the problem from an angle that is not
> bidi-related and might make sense on versions (including XEmacs)
> that don't bother about bidi at all and consequently don't support
> bidi-paragraph-direction.

bidi-paragraph-direction is a variable.  Setting a variable cannot
hurt, even if the version of Emacs one runs doesn't know about it.  Am
I missing something?



reply via email to

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