[Top][All Lists]

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

Re: Bidirectional text and URLs

From: Eli Zaretskii
Subject: Re: Bidirectional text and URLs
Date: Sat, 29 Nov 2014 19:11:57 +0200

> Date: Sat, 29 Nov 2014 12:04:17 -0500
> From: Richard Stallman <address@hidden>
> Cc: address@hidden, address@hidden
>   > The RTL flag character in the example isn't part of the URL, it only
>   > precedes it.
> (I couldn't see it in any case.)

It's displayed as a very thin space.

> This suggests we need to provide a primitive to tell Lisp programs a
> guaranteed answer for which direction the text at a certain point is
> displayed in.

The directionality of the text is determined by the display engine,
and by design is not subject to control by Lisp programs, with 2
notable exceptions (none of which are relevant to the issue at hand):

 . Lisp programs can disable bidi reordering in a buffer

 . Lisp programs can define the base paragraph direction

> Also, a primitive to verify that a certain region of text has no
> bidi strangeness within it.

We need to have a good instrumental definition of "bidi strangeness"
for that.  The simple job of determining whether the region of text
includes RTL characters or bidi formatting controls is already
possible by using suitable regular expressions, of course.

> On issues like this, better safe than sorry.  The user who wants to
> override the safety measure can easily do that.  For instance,
> inserting line breaks around the URL would make it be considered safe,
> right?

No.  In fact, it won't change at all the (jumbled) display of the
example presented by Lars.

reply via email to

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