From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.devel Subject: Re: major mode in new buffers Date: Fri, 02 Apr 2010 19:04:19 +0300 Organization: JURTA Message-ID: <87eiiy85tg.fsf@mail.jurta.org> References: <2f8988ff1003300457w38ee4bf0h259cd7a7187298e0@mail.gmail.com> <87oci41zrg.fsf@mail.jurta.org> <87fx3f5d15.fsf@mail.jurta.org> <87d3yipzbg.fsf@mail.jurta.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: dough.gmane.org 1270229011 17741 80.91.229.12 (2 Apr 2010 17:23:31 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 2 Apr 2010 17:23:31 +0000 (UTC) Cc: Kyllingstad , Stefan Monnier , =?iso-8859-1?Q?Ren=E9?=, emacs-devel@gnu.org To: Juanma Barranquero Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Apr 02 19:23:27 2010 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Nxkab-0000o5-Qs for ged-emacs-devel@m.gmane.org; Fri, 02 Apr 2010 19:23:26 +0200 Original-Received: from localhost ([127.0.0.1]:41272 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Nxkab-0004q4-2U for ged-emacs-devel@m.gmane.org; Fri, 02 Apr 2010 13:23:25 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NxjXo-0002we-9j for emacs-devel@gnu.org; Fri, 02 Apr 2010 12:16:28 -0400 Original-Received: from [140.186.70.92] (port=32921 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NxjXm-0002vs-Vh for emacs-devel@gnu.org; Fri, 02 Apr 2010 12:16:27 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1NxjXj-0004mu-0v for emacs-devel@gnu.org; Fri, 02 Apr 2010 12:16:26 -0400 Original-Received: from smtp-out1.starman.ee ([85.253.0.3]:55673 helo=mx1.starman.ee) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1NxjXi-0004mb-QY for emacs-devel@gnu.org; Fri, 02 Apr 2010 12:16:22 -0400 X-Virus-Scanned: by Amavisd-New at mx1.starman.ee Original-Received: from mail.starman.ee (82.131.33.32.cable.starman.ee [82.131.33.32]) by mx1.starman.ee (Postfix) with ESMTP id 905F63F40BC; Fri, 2 Apr 2010 19:16:13 +0300 (EEST) In-Reply-To: (Juanma Barranquero's message of "Fri, 2 Apr 2010 01:10:47 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (x86_64-pc-linux-gnu) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) 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:123070 Archived-At: > With your patch applied, do this: > > emacs -Q -l ehelp --eval '(global-set-key [?\C-h] 'ehelp-command)' > C-h f car r ;; now the *help* buffer is help-mode > ==> "End of buffer. Type q to quit viewing" > > so after restoring the previous major mode, *Help* is in help-mode but > the bindings are not OK. The direct call to `help-mode' can't set Help mode correctly. This should be done by calling `with-help-window' that uses `with-output-to-temp-buffer' that calls `help-mode-setup' as one of its hooks in `temp-buffer-setup-hook'. But at least, after the direct call to `help-mode', RET works correctly on links (due to its text property's local keymap). This is most important. It's not a big problem when typing RET outside a link says "End of buffer." instead of "No cross-reference here". -- Juri Linkov http://www.jurta.org/emacs/