aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorChong Yidong2008-09-07 14:16:15 +0000
committerChong Yidong2008-09-07 14:16:15 +0000
commit5b6f0284d0327a15f0e68bb4c4d354846c421dbc (patch)
tree9d25cb8496ba6d7c73e3b70f71e19d0a200ead88 /src
parent0f6c7c7ed8a02f986ed8f715dd7fd10fa5f3683b (diff)
downloademacs-5b6f0284d0327a15f0e68bb4c4d354846c421dbc.tar.gz
emacs-5b6f0284d0327a15f0e68bb4c4d354846c421dbc.zip
(move_it_to): When moving by vpos, ensure that the iterator advances
to the next line if the current line ends in a continued tab.
Diffstat (limited to 'src')
-rw-r--r--src/xdisp.c14
1 files changed, 12 insertions, 2 deletions
diff --git a/src/xdisp.c b/src/xdisp.c
index 82c9e82effa..a6d1a82eb33 100644
--- a/src/xdisp.c
+++ b/src/xdisp.c
@@ -7216,8 +7216,18 @@ move_it_to (it, to_charpos, to_x, to_y, to_vpos, op)
7216 associated with the tab are displayed on the current 7216 associated with the tab are displayed on the current
7217 line. Since it->current_x does not include these glyphs, 7217 line. Since it->current_x does not include these glyphs,
7218 we use it->last_visible_x instead. */ 7218 we use it->last_visible_x instead. */
7219 it->continuation_lines_width += 7219 if (it->c == '\t')
7220 (it->c == '\t') ? it->last_visible_x : it->current_x; 7220 {
7221 it->continuation_lines_width += it->last_visible_x;
7222 /* When moving by vpos, ensure that the iterator really
7223 advances to the next line (bug#847). Fixme: do we
7224 need to do this in other circumstances? */
7225 if ((op & MOVE_TO_VPOS)
7226 && !(op & (MOVE_TO_X | MOVE_TO_POS)))
7227 set_iterator_to_next (it, 0);
7228 }
7229 else
7230 it->continuation_lines_width += it->current_x;
7221 break; 7231 break;
7222 7232
7223 default: 7233 default: