Mercurial > hg > xemacs-beta
diff src/cmdloop.c @ 1703:f561c3904bb3
[xemacs-hg @ 2003-09-20 01:46:53 by youngs]
2003-09-20 Ilya N. Golubev <gin@mo.msk.ru>
* simple.el (raw-append-message): Allow user to specify
alternative function for displaying message.
(redisplay-echo-area-function): New.
(clear-message): Allow user to specify function for finishing
message display.
(undisplay-echo-area-function): New.
2003-09-20 Ilya N. Golubev <gin@mo.msk.ru>
* xemacs/mini.texi (Minibuffer): Add customizing message display
reference.
* lispref/display.texi (Customizing Message Display): New,
describe `redisplay-echo-area-function',
`undisplay-echo-area-function', `minibuffer-echo-wait-function'.
(The Echo Area): Add menu.
2003-09-20 Ilya N. Golubev <gin@mo.msk.ru>
* cmdloop.c (Fcommand_loop_1): Allow specifying elisp function for
waiting user input while displaying message while in minibuffer.
(Vminibuffer_echo_wait_function): New, associated variable...
(vars_of_cmdloop): ... initialize it.
author | youngs |
---|---|
date | Sat, 20 Sep 2003 01:47:03 +0000 |
parents | fffe735e63ee |
children | 61855263cb07 |
line wrap: on
line diff
--- a/src/cmdloop.c Sat Sep 20 01:25:48 2003 +0000 +++ b/src/cmdloop.c Sat Sep 20 01:47:03 2003 +0000 @@ -68,6 +68,7 @@ Lisp_Object Qerrors_deactivate_region; Lisp_Object Qtop_level; +Lisp_Object Vminibuffer_echo_wait_function; static Lisp_Object command_loop_1 (Lisp_Object dummy); EXFUN (Fcommand_loop_1, 0); @@ -559,7 +560,10 @@ /* Bind dont_check_for_quit to 1 so that C-g gets read in rather than quitting back to the minibuffer. */ int count = begin_dont_check_for_quit (); - Fsit_for (make_int (2), Qnil); + if (!NILP (Vminibuffer_echo_wait_function)) + call0 (Vminibuffer_echo_wait_function); + else + Fsit_for (make_int (2), Qnil); clear_echo_area (selected_frame (), Qnil, 0); Vquit_flag = Qnil; /* see begin_dont_check_for_quit() */ unbind_to (count); @@ -626,6 +630,15 @@ */ ); Venter_window_hook = Qnil; + DEFVAR_LISP ("minibuffer-echo-wait-function", + &Vminibuffer_echo_wait_function /* +The function called by command loop when minibuffer was active and +message was displayed (text appeared in \" *Echo Area*\" buffer). It +must wait after displaying message so that user can read it. If the +variable value is `nil', the equivalent of `(sit-for 2)' is run. +*/ ); + Vminibuffer_echo_wait_function = Qnil; + #ifndef LISP_COMMAND_LOOP DEFVAR_LISP ("top-level", &Vtop_level /* Form to evaluate when Emacs starts up.