diff options
| author | Eli Zaretskii | 2013-07-24 20:36:42 +0300 |
|---|---|---|
| committer | Eli Zaretskii | 2013-07-24 20:36:42 +0300 |
| commit | 999c74e390182b2dc303c8655c505c92c4a7deda (patch) | |
| tree | ff28812b876953d5eeb97907ffb41d42ad751e38 /src | |
| parent | 889acc5ce746cfef19655537557fe32d461057ad (diff) | |
| download | emacs-999c74e390182b2dc303c8655c505c92c4a7deda.tar.gz emacs-999c74e390182b2dc303c8655c505c92c4a7deda.zip | |
Fix bug #14780 with unreachable lines near end of buffer.
src/xdisp.c (redisplay_window): Instead of moving point out of
scroll margin, reject the force_start method, and try scrolling.
Diffstat (limited to 'src')
| -rw-r--r-- | src/ChangeLog | 6 | ||||
| -rw-r--r-- | src/xdisp.c | 15 |
2 files changed, 16 insertions, 5 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index 2f04edc9bec..64b13a5ac28 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,9 @@ | |||
| 1 | 2013-07-24 Eli Zaretskii <eliz@gnu.org> | ||
| 2 | |||
| 3 | * xdisp.c (redisplay_window): Instead of moving point out of | ||
| 4 | scroll margin, reject the force_start method, and try scrolling | ||
| 5 | instead. (Bug#14780) | ||
| 6 | |||
| 1 | 2013-07-24 Ken Brown <kbrown@cornell.edu> | 7 | 2013-07-24 Ken Brown <kbrown@cornell.edu> |
| 2 | 8 | ||
| 3 | * alloc.c (make_save_ptr): Define if HAVE_NTGUI is defined | 9 | * alloc.c (make_save_ptr): Define if HAVE_NTGUI is defined |
diff --git a/src/xdisp.c b/src/xdisp.c index 1a7369d7a45..1da7de5759c 100644 --- a/src/xdisp.c +++ b/src/xdisp.c | |||
| @@ -15608,10 +15608,11 @@ redisplay_window (Lisp_Object window, int just_this_one_p) | |||
| 15608 | the Y coordinate of the _next_ row, see the definition of | 15608 | the Y coordinate of the _next_ row, see the definition of |
| 15609 | MATRIX_ROW_BOTTOM_Y. */ | 15609 | MATRIX_ROW_BOTTOM_Y. */ |
| 15610 | if (w->cursor.vpos < margin + header_line) | 15610 | if (w->cursor.vpos < margin + header_line) |
| 15611 | new_vpos | 15611 | { |
| 15612 | = pixel_margin + (header_line | 15612 | w->cursor.vpos = -1; |
| 15613 | ? CURRENT_HEADER_LINE_HEIGHT (w) | 15613 | clear_glyph_matrix (w->desired_matrix); |
| 15614 | : 0) + frame_line_height; | 15614 | goto try_to_scroll; |
| 15615 | } | ||
| 15615 | else | 15616 | else |
| 15616 | { | 15617 | { |
| 15617 | int window_height = window_box_height (w); | 15618 | int window_height = window_box_height (w); |
| @@ -15619,7 +15620,11 @@ redisplay_window (Lisp_Object window, int just_this_one_p) | |||
| 15619 | if (header_line) | 15620 | if (header_line) |
| 15620 | window_height += CURRENT_HEADER_LINE_HEIGHT (w); | 15621 | window_height += CURRENT_HEADER_LINE_HEIGHT (w); |
| 15621 | if (w->cursor.y >= window_height - pixel_margin) | 15622 | if (w->cursor.y >= window_height - pixel_margin) |
| 15622 | new_vpos = window_height - pixel_margin; | 15623 | { |
| 15624 | w->cursor.vpos = -1; | ||
| 15625 | clear_glyph_matrix (w->desired_matrix); | ||
| 15626 | goto try_to_scroll; | ||
| 15627 | } | ||
| 15623 | } | 15628 | } |
| 15624 | } | 15629 | } |
| 15625 | 15630 | ||