From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Drew Adams" Newsgroups: gmane.emacs.devel,gmane.emacs.help Subject: RE: Q on minibuffer-message Date: Fri, 20 Jan 2006 15:08:56 -0800 Message-ID: References: <43D16944.1020407@student.lu.se> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1137802952 14743 80.91.229.2 (21 Jan 2006 00:22:32 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sat, 21 Jan 2006 00:22:32 +0000 (UTC) Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Jan 21 01:22:31 2006 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1F06WQ-0007B6-Re for ged-emacs-devel@m.gmane.org; Sat, 21 Jan 2006 01:22:27 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1F06YI-0006NB-Qp for ged-emacs-devel@m.gmane.org; Fri, 20 Jan 2006 19:24:22 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1F05Py-0002mw-J2 for emacs-devel@gnu.org; Fri, 20 Jan 2006 18:11:42 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1F05Pu-0002kf-Ds for emacs-devel@gnu.org; Fri, 20 Jan 2006 18:11:41 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1F05Pu-0002kY-3F; Fri, 20 Jan 2006 18:11:38 -0500 Original-Received: from [141.146.126.228] (helo=agminet01.oracle.com) by monty-python.gnu.org with esmtp (TLS-1.0:DHE_RSA_3DES_EDE_CBC_SHA:24) (Exim 4.34) id 1F05UB-00055c-IE; Fri, 20 Jan 2006 18:16:03 -0500 Original-Received: from rgmsgw300.us.oracle.com (rgmsgw300.us.oracle.com [138.1.186.49]) by agminet01.oracle.com (Switch-3.1.7/Switch-3.1.7) with ESMTP id k0KN908o017767; Fri, 20 Jan 2006 17:09:00 -0600 Original-Received: from rgmsgw300.us.oracle.com (localhost [127.0.0.1]) by rgmsgw300.us.oracle.com (Switch-3.1.7/Switch-3.1.7) with ESMTP id k0KN8x1C000401; Fri, 20 Jan 2006 16:08:59 -0700 Original-Received: from dradamslap (dhcp-amer-rmdc-csvpn-gw5-141-144-107-196.vpn.oracle.com [141.144.107.196]) by rgmsgw300.us.oracle.com (Switch-3.1.7/Switch-3.1.7) with SMTP id k0KN8x0C000390 (version=TLSv1/SSLv3 cipher=RC4-MD5 bits=128 verify=NO); Fri, 20 Jan 2006 16:08:59 -0700 Original-To: "Help-Gnu-Emacs" , "Emacs Devel" X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.6604 (9.0.2911.0) In-reply-to: <43D16944.1020407@student.lu.se> Importance: Normal X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1506 X-Brightmail-Tracker: AAAAAQAAAAI= X-Whitelist: TRUE X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:49340 gmane.emacs.help:32765 Archived-At: As far as I can see it is a bug, at least in CVS Emacs. `minibuffer-message' uses temp_echo_area_glyphs in minibuf.c and that function calls Fsit_for (make_number (2), Qnil, Qnil); which just sits for 2 seconds. BTW `minibuffer-message' puts the string at the end of the current buffer which is not necessarily the minibuffer. Is not that a bug too? I don't know if those observations indicate bugs, and I'm not sure they're related to my question. I'd just like to know how to inhibit or cancel the 2-second delay. I don't understand this enough to know if it is the presence of bugs that prevents me from doing that. I'd like some input on what might work (modulo bugs). ---- Drew Adams wrote: > I have a command `foo' that calls `minibuffer-message' at various points. > > I want to call this function from another command, `bar', but I don't want > the `minibuffer-message' display to wait for two seconds - I even don't care > if it is displayed at all in this case. > > I could change the definition of command `foo', to pass it a flag to not > call `minibuffer-message' (or to call it only when the command is called > interactively), but I'd rather not have to resort to that. > > `minibuffer-message' displays its message for two seconds, unless an input > event is received during this time. My question is: How can I inhibit the > 2-second wait? Is there, for example, some way I can simulate an input > event? Or is there a simpler, cleaner way? > > In command `bar', just after calling `foo', I tried (sit-for 0), to no > avail. I tried adding a fake event (e.g. a character) to > `unread-command-events', to no avail. I tried binding > `minibuffer-message-timeout' (to nil and to 0), to no avail (it seemed to > have no effect). > > Anyone have a suggestion? >