From 9f50252b45a42ded27392f946516958d2d2da822 Mon Sep 17 00:00:00 2001 From: Gerd Moellmann Date: Wed, 9 Aug 2000 18:40:39 +0000 Subject: [PATCH] (echo_area_display): Display thoroughly if input is pending. Bind redisplay-dont-pause to t during the redisplay. in case input is pending. --- src/xdisp.c | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/src/xdisp.c b/src/xdisp.c index 3f0cbc58f5c..79717849bd6 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -6239,15 +6239,27 @@ echo_area_display (update_frame_p) if (update_frame_p) { - /* Not called from redisplay_internal. If we changed - window configuration, we must redisplay thoroughly. - Otherwise, we can do with updating what we displayed + /* Not called from redisplay_internal. If we changed window + configuration, we must redisplay thoroughly, of course. + + Likewise if input is pending, because the pending input + can have interrupted a previous redisplay, or redisplay + wasn't called because of the pending input (see + keyboard.c). In both cases, we would display the message + fine, but the rest of the display would be garbage. + + Otherwise, we can do with updating just what we displayed above. */ - if (window_height_changed_p) + + if (window_height_changed_p || detect_input_pending ()) { + int count = specpdl_ptr - specpdl; + + specbind (Qredisplay_dont_pause, Qt); ++windows_or_buffers_changed; ++update_mode_lines; redisplay_internal (0); + unbind_to (count, Qnil); } else if (FRAME_WINDOW_P (f)) { -- 2.39.2