changeset 4947:e495404b5263

(comint-postoutput-scroll-to-bottom): Don't alter point in a window if it's after the process-mark.
author Richard M. Stallman <rms@gnu.org>
date Wed, 10 Nov 1993 00:38:47 +0000
parents 6aeb2c705774
children 7653c78ac0c1
files lisp/comint.el
diffstat 1 files changed, 8 insertions(+), 8 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/comint.el	Wed Nov 10 00:03:54 1993 +0000
+++ b/lisp/comint.el	Wed Nov 10 00:38:47 1993 +0000
@@ -1197,14 +1197,14 @@
 	   (if (eq (window-buffer window) current)
 	       (progn
 		 (select-window window)
-		 (if (or (eq scroll t) (eq scroll 'all)
-			 ;; Maybe user wants point to jump to the end.
-			 (and (eq scroll 'this) (eq selected window))
-			 (and (eq scroll 'others) (not (eq selected window)))
-			 ;; If point was at the end, keep it at the end.
-			 (and (>= (point)
-				  (- (process-mark process) (length string)))
-			      (< (point) (process-mark process))))
+		 (if (and (< (point) (process-mark process))
+			  (or (eq scroll t) (eq scroll 'all)
+			      ;; Maybe user wants point to jump to the end.
+			      (and (eq scroll 'this) (eq selected window))
+			      (and (eq scroll 'others) (not (eq selected window)))
+			      ;; If point was at the end, keep it at the end.
+			      (>= (point)
+				  (- (process-mark process) (length string)))))
 		     (goto-char (process-mark process)))
 		 ;; Optionally scroll so that the text
 		 ;; ends at the bottom of the window.