summaryrefslogtreecommitdiff
path: root/src/window.c
diff options
context:
space:
mode:
authorGerd Moellmann <gerd@gnu.org>2001-08-15 14:57:20 +0000
committerGerd Moellmann <gerd@gnu.org>2001-08-15 14:57:20 +0000
commit288d4e0606fb974057bee798b9a2e7afbb385b12 (patch)
tree0b3e07ac6dcb856e66672dc16a958c508b0bccff /src/window.c
parent82f053ab598f7e2277836adc474ba8fa29ae6c9d (diff)
downloademacs-288d4e0606fb974057bee798b9a2e7afbb385b12.tar.gz
(window_scroll_pixel_based): Don't recenter if
PT is partially visible in the window.
Diffstat (limited to 'src/window.c')
-rw-r--r--src/window.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/window.c b/src/window.c
index abd2e6230ab..95caf878064 100644
--- a/src/window.c
+++ b/src/window.c
@@ -3960,8 +3960,10 @@ window_scroll_pixel_based (window, n, whole, noerror)
SET_TEXT_POS_FROM_MARKER (start, w->start);
/* If PT is not visible in WINDOW, move back one half of
- the screen. */
- tem = Fpos_visible_in_window_p (make_number (PT), window, Qnil);
+ the screen. Allow PT to be partially visible, otherwise
+ something like (scroll-down 1) with PT in the line before
+ the partially visible one would recenter. */
+ tem = Fpos_visible_in_window_p (make_number (PT), window, Qt);
if (NILP (tem))
{
/* Move backward half the height of the window. Performance note: