From: Karl Heuer Date: Tue, 10 Jan 1995 00:06:50 +0000 (+0000) Subject: (Fscroll_other_window): On small windows, scroll by 1 line. X-Git-Tag: emacs-19.34~5485 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=2f787aa33c86aba7e1254264ae87e31efa90472e;p=emacs.git (Fscroll_other_window): On small windows, scroll by 1 line. --- diff --git a/src/window.c b/src/window.c index 2014e043bae..bb306dd4b8e 100644 --- a/src/window.c +++ b/src/window.c @@ -2580,14 +2580,15 @@ showing that buffer, popping the buffer up if necessary.") register Lisp_Object n; { register Lisp_Object window; - register int ht; + register int defalt; register struct window *w; register int count = specpdl_ptr - specpdl; window = Fother_window_for_scrolling (); w = XWINDOW (window); - ht = window_internal_height (w); + defalt = window_internal_height (w) - next_screen_context_lines; + if (defalt < 1) defalt = 1; /* Don't screw up if window_scroll gets an error. */ record_unwind_protect (save_excursion_restore, save_excursion_save ()); @@ -2596,9 +2597,9 @@ showing that buffer, popping the buffer up if necessary.") SET_PT (marker_position (w->pointm)); if (NILP (n)) - window_scroll (window, ht - next_screen_context_lines, 1); + window_scroll (window, defalt, 1); else if (EQ (n, Qminus)) - window_scroll (window, next_screen_context_lines - ht, 1); + window_scroll (window, -defalt, 1); else { if (CONSP (n))