diff options
| author | Gerd Moellmann | 2001-04-10 15:39:53 +0000 |
|---|---|---|
| committer | Gerd Moellmann | 2001-04-10 15:39:53 +0000 |
| commit | 202379cf467231fef25ebd78c705e64664495256 (patch) | |
| tree | 2d2976ad627442ff995f9660725883ab4c2cb835 /src/window.c | |
| parent | 8541c92408c12c49dfa5c649dc6b9ddced0fc906 (diff) | |
| download | emacs-202379cf467231fef25ebd78c705e64664495256.tar.gz emacs-202379cf467231fef25ebd78c705e64664495256.zip | |
(window_scroll_pixel_based, Frecenter): Call
window_box_height instead of using it.last_visible_y for the
height of the window.
Diffstat (limited to 'src/window.c')
| -rw-r--r-- | src/window.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/window.c b/src/window.c index d6538976b68..33c99f5cfd2 100644 --- a/src/window.c +++ b/src/window.c | |||
| @@ -3969,7 +3969,7 @@ window_scroll_pixel_based (window, n, whole, noerror) | |||
| 3969 | results for variable height lines. */ | 3969 | results for variable height lines. */ |
| 3970 | init_iterator (&it, w, PT, PT_BYTE, NULL, DEFAULT_FACE_ID); | 3970 | init_iterator (&it, w, PT, PT_BYTE, NULL, DEFAULT_FACE_ID); |
| 3971 | it.current_y = it.last_visible_y; | 3971 | it.current_y = it.last_visible_y; |
| 3972 | move_it_vertically (&it, -it.last_visible_y / 2); | 3972 | move_it_vertically (&it, - window_box_height (w) / 2); |
| 3973 | 3973 | ||
| 3974 | /* The function move_iterator_vertically may move over more than | 3974 | /* The function move_iterator_vertically may move over more than |
| 3975 | the specified y-distance. If it->w is small, e.g. a | 3975 | the specified y-distance. If it->w is small, e.g. a |
| @@ -4002,7 +4002,7 @@ window_scroll_pixel_based (window, n, whole, noerror) | |||
| 4002 | start_display (&it, w, start); | 4002 | start_display (&it, w, start); |
| 4003 | if (whole) | 4003 | if (whole) |
| 4004 | { | 4004 | { |
| 4005 | int screen_full = (it.last_visible_y | 4005 | int screen_full = (window_box_height (w) |
| 4006 | - next_screen_context_lines * CANON_Y_UNIT (it.f)); | 4006 | - next_screen_context_lines * CANON_Y_UNIT (it.f)); |
| 4007 | int direction = n < 0 ? -1 : 1; | 4007 | int direction = n < 0 ? -1 : 1; |
| 4008 | int dy = direction * screen_full; | 4008 | int dy = direction * screen_full; |
| @@ -4583,7 +4583,7 @@ and redisplay normally--don't erase and redraw the frame.") | |||
| 4583 | 4583 | ||
| 4584 | SET_TEXT_POS (pt, PT, PT_BYTE); | 4584 | SET_TEXT_POS (pt, PT, PT_BYTE); |
| 4585 | start_display (&it, w, pt); | 4585 | start_display (&it, w, pt); |
| 4586 | move_it_vertically (&it, - it.last_visible_y / 2); | 4586 | move_it_vertically (&it, - window_box_height (w) / 2); |
| 4587 | charpos = IT_CHARPOS (it); | 4587 | charpos = IT_CHARPOS (it); |
| 4588 | bytepos = IT_BYTEPOS (it); | 4588 | bytepos = IT_BYTEPOS (it); |
| 4589 | } | 4589 | } |