From 1b242afeb3aa2bb180c480886aebd3c9380115dc Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Mon, 21 Apr 2008 20:28:45 +0000 Subject: [PATCH] (term-emulate-terminal): Perform redisplay after the process filter has finished running. --- lisp/term.el | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lisp/term.el b/lisp/term.el index 135f74d4f52..4fe3c4d0532 100644 --- a/lisp/term.el +++ b/lisp/term.el @@ -3049,7 +3049,11 @@ See `term-prompt-regexp'." (forward-line (- term-buffer-maximum-size)) (beginning-of-line) (delete-region (point-min) (point)))) - (set-marker save-marker nil))))) + (set-marker save-marker nil))) + ;; This might be expensive, but we need it to handle something + ;; like `sleep 5 | less -c' in more-or-less real time. + (when (get-buffer-window (current-buffer)) + (redisplay)))) (defun term-handle-deferred-scroll () (let ((count (- (term-current-row) term-height))) -- 2.39.5