aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorGerd Moellmann2001-07-26 09:54:02 +0000
committerGerd Moellmann2001-07-26 09:54:02 +0000
commit2913a9c09beaa82b0742033913392a77ff2b333c (patch)
tree41820c22605874cac8382b63022bb71aed9a8d00 /src
parent6849e6d5ee7f28d6a7061d2381997cc19e918c77 (diff)
downloademacs-2913a9c09beaa82b0742033913392a77ff2b333c.tar.gz
emacs-2913a9c09beaa82b0742033913392a77ff2b333c.zip
(resize_mini_window): Give up when inhibit-redisplay
is non-nil, instead of when redisplaying_p is non-zero. See comment there. (mark_window_display_accurate_1): Add an assertion.
Diffstat (limited to 'src')
-rw-r--r--src/xdisp.c19
1 files changed, 13 insertions, 6 deletions
diff --git a/src/xdisp.c b/src/xdisp.c
index 6a56fe18740..6b382906f58 100644
--- a/src/xdisp.c
+++ b/src/xdisp.c
@@ -1278,7 +1278,7 @@ safe_eval_handler (arg)
1278 1278
1279 1279
1280/* Evaluate SEXPR and return the result, or nil if something went 1280/* Evaluate SEXPR and return the result, or nil if something went
1281 wrong. */ 1281 wrong. Prevent redisplay during the evaluation. */
1282 1282
1283Lisp_Object 1283Lisp_Object
1284safe_eval (sexpr) 1284safe_eval (sexpr)
@@ -1306,7 +1306,8 @@ safe_eval (sexpr)
1306 1306
1307 1307
1308/* Call function ARGS[0] with arguments ARGS[1] to ARGS[NARGS - 1]. 1308/* Call function ARGS[0] with arguments ARGS[1] to ARGS[NARGS - 1].
1309 Return the result, or nil if something went wrong. */ 1309 Return the result, or nil if something went wrong. Prevent
1310 redisplay during the evaluation. */
1310 1311
1311Lisp_Object 1312Lisp_Object
1312safe_call (nargs, args) 1313safe_call (nargs, args)
@@ -6500,10 +6501,13 @@ resize_mini_window (w, exact_p)
6500 6501
6501 xassert (MINI_WINDOW_P (w)); 6502 xassert (MINI_WINDOW_P (w));
6502 6503
6503 /* Don't resize windows while redisplaying; it would confuse 6504 /* Don't resize windows while redisplaying a window; it would
6504 redisplay functions when the size of the window they are 6505 confuse redisplay functions when the size of the window they are
6505 displaying changes from under them. */ 6506 displaying changes from under them. Such a resizing can happen,
6506 if (redisplaying_p) 6507 for instance, when which-func prints a long message while
6508 we are running fontification-functions. We're running these
6509 functions with safe_call which binds inhibit-redisplay to t. */
6510 if (!NILP (Vinhibit_redisplay))
6507 return 0; 6511 return 0;
6508 6512
6509 /* Nil means don't try to resize. */ 6513 /* Nil means don't try to resize. */
@@ -8981,6 +8985,9 @@ mark_window_display_accurate_1 (w, accurate_p)
8981 if (accurate_p) 8985 if (accurate_p)
8982 { 8986 {
8983 w->window_end_valid = w->buffer; 8987 w->window_end_valid = w->buffer;
8988 xassert (XINT (w->window_end_vpos)
8989 < (XINT (w->height)
8990 - (WINDOW_WANTS_MODELINE_P (w) ? 1 : 0)));
8984 w->update_mode_line = Qnil; 8991 w->update_mode_line = Qnil;
8985 } 8992 }
8986} 8993}