unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Bidi reordering engine upgraded
@ 2014-10-15 14:51 Eli Zaretskii
  2014-10-15 15:22 ` Dmitry Antipov
  0 siblings, 1 reply; 38+ messages in thread
From: Eli Zaretskii @ 2014-10-15 14:51 UTC (permalink / raw)
  To: emacs-devel

With revision 118121, the upgraded bidi reordering engine landed on
the trunk.  Barring bugs, we are now fully compliant with The Unicode
Bidirectional Algorithm defined by the latest Unicode Standard v7.0,
and even with a few suggestions that will only make it into Unicode
8.0.

The changes in the UBA as defined by the latest Unicode Standard, wrt
to the original UBA we had until and including Unicode 6.2, are
significant.  They required serious refactoring and reimplementation
of several core parts in bidi.c, something that wasn't attempted for
quite a few years.

In addition, one of the new UBA features, the so-called Bidirectional
Parentheses Algorithm (BPA), affects pure-ASCII text as well, and
specifically editing of program sources (which widely use parentheses
and brackets of several kinds).

The result is some small slowdown -- a few percents in my testing --
in redisplay operations.  If more significant slowdown will be
reported in some special cases, I will try to find optimizations to
countermand that.

No matter how much testing I've put into the new code, there will
probably be bugs.  Please be attentive to any display glitches in the
trunk code, let alone crashes etc., and report them as bugs.

Thanks, and enjoy.



^ permalink raw reply	[flat|nested] 38+ messages in thread
* Re: Bidi reordering engine upgraded
@ 2014-10-17 11:12 grischka
  2014-10-17 11:42 ` martin rudalics
  0 siblings, 1 reply; 38+ messages in thread
From: grischka @ 2014-10-17 11:12 UTC (permalink / raw)
  To: emacs-devel

> But there are W+1 pixels in a line that starts at X and ends at X+W.
> W+1, not W.
> 
>> 
>>  | 1         2         3
>>  | 012345678901234567890123456789
>>  |           ***********
>>  |                     ^ out out damned dot!
> 
> Count the stars, and you will see there are 11 of them, not 10.  Where
> did the 11th one come from, when we requested a width of 10?

In general, drawing an horizontal or vertical line of length 10
needs 11 pixels to be set.

This is because to the human eye pixels are similar to points in math
(i.e.has location, does not have extent).  Therefor, a mental "magnifying
glass" (in order to be useful) needs to preserve the point-like property
of pixels unaffected from the "zoom factor".

Which means that what counts for line length is not number of pixels
but the spaces between.  See line of length 10, magnified:

     0   1   2   3   4   5   6   7   8   9   0
     *   *   *   *   *   *   *   *   *   *   *

(Disclaimer:  The above is not meant to necessarily support
conclusions about the behavior of XDrawRectangle or FrameRect,
or specific details thereof. :P)

--- grischka




^ permalink raw reply	[flat|nested] 38+ messages in thread

end of thread, other threads:[~2014-10-19 13:20 UTC | newest]

Thread overview: 38+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-10-15 14:51 Bidi reordering engine upgraded Eli Zaretskii
2014-10-15 15:22 ` Dmitry Antipov
2014-10-15 15:47   ` Eli Zaretskii
2014-10-15 16:00     ` Dmitry Antipov
2014-10-15 16:31       ` Eli Zaretskii
2014-10-15 17:28         ` Eli Zaretskii
2014-10-15 17:50           ` Eli Zaretskii
2014-10-16  3:55             ` Dmitry Antipov
2014-10-16  7:21               ` Eli Zaretskii
2014-10-16  9:42                 ` Thien-Thi Nguyen
2014-10-16 10:15                   ` Eli Zaretskii
2014-10-16 13:27                     ` Thien-Thi Nguyen
2014-10-16 13:51                       ` Eli Zaretskii
2014-10-17  5:42                         ` Thien-Thi Nguyen
2014-10-17  6:16                           ` Eli Zaretskii
2014-10-17  7:50                             ` Thien-Thi Nguyen
2014-10-17  8:25                               ` Eli Zaretskii
2014-10-17 10:27                                 ` Thien-Thi Nguyen
2014-10-17 10:31                                   ` Eli Zaretskii
2014-10-16  9:51                 ` Dmitry Antipov
2014-10-16 10:20                   ` Eli Zaretskii
2014-10-16 11:28                   ` Eli Zaretskii
2014-10-17  6:46                 ` Eli Zaretskii
2014-10-17 17:45                 ` Jan Djärv
2014-10-17 18:45                   ` Eli Zaretskii
2014-10-17 19:32                     ` Stefan Monnier
2014-10-18 12:34                     ` Jan Djärv
2014-10-18 12:54                       ` Eli Zaretskii
2014-10-18 13:13                         ` Eli Zaretskii
2014-10-19 11:45                           ` Jan Djärv
2014-10-19 13:19                             ` Eli Zaretskii
2014-10-19 11:49                           ` Jan Djärv
2014-10-19 13:20                             ` Eli Zaretskii
  -- strict thread matches above, loose matches on Subject: below --
2014-10-17 11:12 grischka
2014-10-17 11:42 ` martin rudalics
2014-10-17 11:47   ` David Kastrup
2014-10-17 13:21   ` grischka
2014-10-17 13:30     ` Eli Zaretskii

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).