diff options
| author | Chong Yidong | 2006-11-30 20:58:59 +0000 |
|---|---|---|
| committer | Chong Yidong | 2006-11-30 20:58:59 +0000 |
| commit | 2a95eced249db34f681bd139e4bc434281242c63 (patch) | |
| tree | 54fa258b817a3f45d13c53048404a2c7e72d6762 | |
| parent | b88548b12012a35bfc99993dc0119af6612c847c (diff) | |
| download | emacs-2a95eced249db34f681bd139e4bc434281242c63.tar.gz emacs-2a95eced249db34f681bd139e4bc434281242c63.zip | |
(move_it_to): Correctly count tab glyphs for continued lines ending in
tab.
| -rw-r--r-- | src/xdisp.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/xdisp.c b/src/xdisp.c index 909ec688aff..0a2b58761d8 100644 --- a/src/xdisp.c +++ b/src/xdisp.c | |||
| @@ -6828,7 +6828,12 @@ move_it_to (it, to_charpos, to_x, to_y, to_vpos, op) | |||
| 6828 | break; | 6828 | break; |
| 6829 | 6829 | ||
| 6830 | case MOVE_LINE_CONTINUED: | 6830 | case MOVE_LINE_CONTINUED: |
| 6831 | it->continuation_lines_width += it->current_x; | 6831 | /* For continued lines ending in a tab, some of the glyphs |
| 6832 | associated with the tab are displayed on the current | ||
| 6833 | line. Since it->current_x does not include these glyphs, | ||
| 6834 | we use it->last_visible_x instead. */ | ||
| 6835 | it->continuation_lines_width += | ||
| 6836 | (it->c == '\t') ? it->last_visible_x : it->current_x; | ||
| 6832 | break; | 6837 | break; |
| 6833 | 6838 | ||
| 6834 | default: | 6839 | default: |