emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] /srv/bzr/emacs/trunk r99781: Restore original behavior of


From: Eli Zaretskii
Subject: [Emacs-diffs] /srv/bzr/emacs/trunk r99781: Restore original behavior of move_it_in_display_line_to when !bidi_p.
Date: Tue, 30 Mar 2010 15:16:49 -0400
User-agent: Bazaar (2.0.3)

------------------------------------------------------------
revno: 99781
committer: Eli Zaretskii <address@hidden>
branch nick: trunk
timestamp: Tue 2010-03-30 15:16:49 -0400
message:
  Restore original behavior of move_it_in_display_line_to when !bidi_p.
  
   xdisp.c (BUFFER_POS_REACHED_P, move_it_in_display_line_to):
   Restore original behavior when the iterator is not bidi_p.
modified:
  src/ChangeLog
  src/xdisp.c
=== modified file 'src/ChangeLog'
--- a/src/ChangeLog     2010-03-30 17:40:04 +0000
+++ b/src/ChangeLog     2010-03-30 19:16:49 +0000
@@ -1,3 +1,8 @@
+2010-03-30  Eli Zaretskii  <address@hidden>
+
+       * xdisp.c (BUFFER_POS_REACHED_P, move_it_in_display_line_to):
+       Restore original behavior when the iterator is not bidi_p.
+
 2010-03-30  Dan Nicolaescu  <address@hidden>
 
        * xdisp.c (syms_of_xdisp): Use intern_c_string instead of intern.

=== modified file 'src/xdisp.c'
--- a/src/xdisp.c       2010-03-30 17:40:04 +0000
+++ b/src/xdisp.c       2010-03-30 19:16:49 +0000
@@ -6999,7 +6999,8 @@
 #define BUFFER_POS_REACHED_P()                                 \
   ((op & MOVE_TO_POS) != 0                                     \
    && BUFFERP (it->object)                                     \
-   && IT_CHARPOS (*it) == to_charpos                           \
+   && (IT_CHARPOS (*it) == to_charpos                          \
+       || (!it->bidi_p && IT_CHARPOS (*it) > to_charpos))      \
    && (it->method == GET_FROM_BUFFER                           \
        || (it->method == GET_FROM_DISPLAY_VECTOR               \
           && it->dpvec + it->current.dpvec_index + 1 >= it->dpend)))
@@ -7023,14 +7024,16 @@
       if ((op & MOVE_TO_POS) != 0
          && BUFFERP (it->object)
          && it->method == GET_FROM_BUFFER
-         && (prev_method == GET_FROM_IMAGE
-             || prev_method == GET_FROM_STRETCH)
-         /* Passed TO_CHARPOS from left to right.  */
-         && ((prev_pos < to_charpos
-              && IT_CHARPOS (*it) > to_charpos)
-             /* Passed TO_CHARPOS from right to left.  */
-             || (prev_pos > to_charpos)
-                 && IT_CHARPOS (*it) < to_charpos))
+         && ((!it->bidi_p && IT_CHARPOS (*it) > to_charpos)
+             || (it->bidi_p
+                 && (prev_method == GET_FROM_IMAGE
+                     || prev_method == GET_FROM_STRETCH)
+                 /* Passed TO_CHARPOS from left to right.  */
+                 && ((prev_pos < to_charpos
+                      && IT_CHARPOS (*it) > to_charpos)
+                     /* Passed TO_CHARPOS from right to left.  */
+                     || (prev_pos > to_charpos
+                         && IT_CHARPOS (*it) < to_charpos)))))
        {
          if (it->line_wrap != WORD_WRAP || wrap_it.sp < 0)
            {


reply via email to

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