Fix bug #7474 with cursor positioning in overlay strings.
authorEli Zaretskii <eliz@gnu.org>
Thu, 25 Nov 2010 18:38:09 +0000 (20:38 +0200)
committerEli Zaretskii <eliz@gnu.org>
Thu, 25 Nov 2010 18:38:09 +0000 (20:38 +0200)
 xdisp.c (set_cursor_from_row): Don't forget to consider the
 `cursor' property of the first character in overlay strings.

src/ChangeLog
src/xdisp.c

index ba298d8..ce18c71 100644 (file)
@@ -1,3 +1,9 @@
+2010-11-25  Eli Zaretskii  <eliz@gnu.org>
+
+       * xdisp.c (set_cursor_from_row): Don't forget to consider the
+       `cursor' property of the first character in overlay strings.
+       (Bug#7474)
+
 2010-11-24  Jan Djärv  <jan.h.d@swipnet.se>
 
        * nsterm.m (NSLeftControlKeyMask, NSLeftCommandKeyMask)
index b2d81cb..fd80d7a 100644 (file)
@@ -12943,7 +12943,7 @@ set_cursor_from_row (struct window *w, struct glyph_row *row,
 
                          if (tem)
                            cursor = glyph;
-                         for (glyph += incr;
+                         for ( ;
                               (row->reversed_p ? glyph > stop : glyph < stop)
                                 && EQ (glyph->object, str);
                               glyph += incr)