Article View: gnu.emacs.bug
Article #797temp_echo_area_contents failing after message (Emacs 18.57)
From: Joe Wells
Date: Tue, 13 Oct 1992 14:03
Date: Tue, 13 Oct 1992 14:03
42 lines
2217 bytes
2217 bytes
Emacs 18.57.
Problem 1. The function temp_echo_area_contents fails after a message
when echo_area_contents != 0 or prev_echo_area_contents !=0. The
equivalent function in Emacs 18.55, temp_minibuf_message, worked in this
situation. To reproduce the problem, type this:
C-x C-f jkl;asdf;jlk ?
And notice that the message " [No completions]" no longer shows up at the
end of the minibuffer text because the message "Making completion list..."
overrides it.
The fix is to insert these two lines in temp_echo_area_contents:
echo_area_contents = 0;
prev_echo_area_contents = 0;
Problem 2. It is very hard to write your own completion routines that
display such messages after the minibuffer text because
temp_echo_area_contents is not accessible from Lisp. Here is the code
that is currently necessary just to have the effect of clearing
echo_area_contents and prev_echo_area_contents:
;; The purpose is to set echo_area_contents = 0, so that the contents
;; of the minibuffer will show.
;; *** fix this so it doesn't assume RET exits minibuffer
(let ((unread-command-char ?\C-m))
(read-from-minibuffer "" nil nil nil))
;; This sets prev_echo_area_contents = echo_area_contents (which is 0)
;; *** fix this so it doesn't assume RET exits minibuffer
(let ((unread-command-char help-char)
(help-form '(setq unread-command-char ?\C-m)))
(read-key-sequence nil))
As you can easily tell, this is a gross, disgusting hack that is likely to
fail in future versions of Emacs. The fix for this is to make
temp_echo_area_contents work, and make it accessible from Lisp.
--
Joe Wells <jbw@cs.bu.edu>
Member of the League for Programming Freedom --- send e-mail for details
Technical Details
Message-ID:
<9210132203.AA21060@csd.bu.edu>Path:
arc1-ca.pugleaf.net!sparky!uunet!convex!darwin.sura.net!zaphod.mps.ohio-state.edu!cis.ohio-state.edu!cs.bu.edu!jbwShow Full Headers
Complete Article Headers
Newsgroups: gnu.emacs.bug Path: arc1-ca.pugleaf.net!sparky!uunet!convex!darwin.sura.net!zaphod.mps.ohio-state.edu!cis.ohio-state.edu!cs.bu.edu!jbw From: jbw@cs.bu.edu (Joe Wells) Subject: temp_echo_area_contents failing after message (Emacs 18.57) Message-ID: <9210132203.AA21060@csd.bu.edu> Sender: gnulists@ai.mit.edu Organization: GNUs Not Usenet Distribution: gnu Date: Tue, 13 Oct 1992 14:03:10 GMT Approved: bug-gnu-emacs@prep.ai.mit.edu Lines: 43