diff options
| author | Noam Postavsky | 2017-01-21 13:24:47 -0500 |
|---|---|---|
| committer | Noam Postavsky | 2017-02-02 21:21:18 -0500 |
| commit | b9be4c14e89f5cec08a7a0f0d24033e0e6ff5ef0 (patch) | |
| tree | ba9f3ce95ecfc4f303a06f8e95a28c6cc9125eef /src/window.c | |
| parent | e27a91cddc1a66c25e09d3929c5625637ec34a49 (diff) | |
| download | emacs-b9be4c14e89f5cec08a7a0f0d24033e0e6ff5ef0.tar.gz emacs-b9be4c14e89f5cec08a7a0f0d24033e0e6ff5ef0.zip | |
Fix scrolling with partial lines
* src/xdisp.c (partial_line_height): New function.
(try_scrolling):
* src/window.c (window_scroll_pixel_based): Use it for calculating the
pixel scroll margin correctly in a window with partial lines.
Diffstat (limited to 'src/window.c')
| -rw-r--r-- | src/window.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/window.c b/src/window.c index ba03780f3df..95690443f8e 100644 --- a/src/window.c +++ b/src/window.c | |||
| @@ -5147,7 +5147,7 @@ window_scroll_pixel_based (Lisp_Object window, int n, bool whole, bool noerror) | |||
| 5147 | in the scroll margin at the bottom. */ | 5147 | in the scroll margin at the bottom. */ |
| 5148 | move_it_to (&it, PT, -1, | 5148 | move_it_to (&it, PT, -1, |
| 5149 | (it.last_visible_y - WINDOW_HEADER_LINE_HEIGHT (w) | 5149 | (it.last_visible_y - WINDOW_HEADER_LINE_HEIGHT (w) |
| 5150 | - this_scroll_margin - 1), | 5150 | - partial_line_height (&it) - this_scroll_margin - 1), |
| 5151 | -1, | 5151 | -1, |
| 5152 | MOVE_TO_POS | MOVE_TO_Y); | 5152 | MOVE_TO_POS | MOVE_TO_Y); |
| 5153 | 5153 | ||