From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Tassilo Horn Newsgroups: gmane.emacs.help Subject: Re: Mode to display information in the topmost line of a window Date: Fri, 31 Jul 2009 09:12:46 +0200 Message-ID: <87tz0tl40h.fsf@thinkpad.tsdh.de> References: <87r5vyw653.fsf@thinkpad.tsdh.de> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1249024421 17630 80.91.229.12 (31 Jul 2009 07:13:41 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 31 Jul 2009 07:13:41 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Jul 31 09:13:34 2009 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1MWmIz-0005sS-9T for geh-help-gnu-emacs@m.gmane.org; Fri, 31 Jul 2009 09:13:29 +0200 Original-Received: from localhost ([127.0.0.1]:37479 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MWmIy-00038m-It for geh-help-gnu-emacs@m.gmane.org; Fri, 31 Jul 2009 03:13:28 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MWmIc-00038g-WC for help-gnu-emacs@gnu.org; Fri, 31 Jul 2009 03:13:07 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MWmIY-00037i-Ie for help-gnu-emacs@gnu.org; Fri, 31 Jul 2009 03:13:06 -0400 Original-Received: from [199.232.76.173] (port=57827 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MWmIY-00037f-Dh for help-gnu-emacs@gnu.org; Fri, 31 Jul 2009 03:13:02 -0400 Original-Received: from mx20.gnu.org ([199.232.41.8]:28655) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1MWmIX-0002Zv-Oq for help-gnu-emacs@gnu.org; Fri, 31 Jul 2009 03:13:02 -0400 Original-Received: from main.gmane.org ([80.91.229.2] helo=ciao.gmane.org) by mx20.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MWmIX-000886-03 for help-gnu-emacs@gnu.org; Fri, 31 Jul 2009 03:13:01 -0400 Original-Received: from list by ciao.gmane.org with local (Exim 4.43) id 1MWmIT-0001KI-EI for help-gnu-emacs@gnu.org; Fri, 31 Jul 2009 07:12:57 +0000 Original-Received: from 141.26.95.166 ([141.26.95.166]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 31 Jul 2009 07:12:57 +0000 Original-Received: from tassilo by 141.26.95.166 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 31 Jul 2009 07:12:57 +0000 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 30 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: 141.26.95.166 User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1.50 (gnu/linux) Cancel-Lock: sha1:OpvBFfmaIUhBvoBAnEFTW3ajS+I= X-Detected-Operating-System: by mx20.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:66555 Archived-At: Kevin Rodgers writes: Hi Kevin, >> What's the prefered way to overwrite a function? Just putting this >> one into .emacs? > > Don't overwrite it, so that you don't have to track changes to its > implementation: > > (defadvice eldoc-message (after header-line-format activate) > "If `eldoc-last-message' is non-nil, set `header-line-format'." > (when eldoc-last-message > (setq header-line-format 'eldoc-last-message) > (force-mode-line-update))) I'd generally agree, but I guess Gerald doesn't want to duplicate the eldoc output in the header line, but instead he wants it to be there only. BTW: In contrast to the echo area, the header-line allows only one single line of content. So you might want to let-bind `eldoc-echo-area-use-multiline-p' to nil. BTW2: I think this eldoc-in-header-line is really nice. Gerald, you might want to built that into eldoc.el directly as an option, and submit a patch to emacs-devel, so that others can share the experience. Bye, Tassilo