GNU bug report logs - #52053
29.0.50; Nonsensical button "C-x C-f" in scratch buffer

Previous Next

Package: emacs;

Reported by: Po Lu <luangruo <at> yahoo.com>

Date: Tue, 23 Nov 2021 10:06:02 UTC

Severity: normal

Found in version 29.0.50

Fixed in version 29.1

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


Message #11 received at 52053 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Po Lu <luangruo <at> yahoo.com>
Cc: 52053 <at> debbugs.gnu.org
Subject: Re: bug#52053: 29.0.50; Nonsensical button "C-x C-f" in scratch buffer
Date: Wed, 24 Nov 2021 08:53:42 +0100
Po Lu <luangruo <at> yahoo.com> writes:

> Start emacs with `emacs -Q', and click on the "C-x C-f" in the initial
> scratch message.  You will get this nonsensical error:
>
> Debugger entered--Lisp error: (error "Current buffer is not in Help mode")
>   signal(error ("Current buffer is not in Help mode"))
>   error("Current buffer is not in Help mode")
>   help-buffer()
>   help-setup-xref((#f(compiled-function #'buffer #<bytecode -0x1c5aa85c15071043>) find-file #<buffer *scratch*>) nil)
>   describe-function(find-file)
>
> I also don't understand why it makes sense to have a button there.

I don't think we're meant to have a button here, but we're running this:

(defcustom initial-scratch-message (purecopy "\
;; This buffer is for text that is not saved, and for Lisp evaluation.
;; To create a file, visit it with \\[find-file] and enter text in its buffer.

")

through substitute-command-keys so that the find-file is expanded.

The problem is two-fold: substitute-command-keys shouldn't buttonise the
keys here, so perhaps it should grow a new parameter to inhibit that.

The other problem is that the font-locking in the buffer removes the
nice fontification of the key binding, so that should also be fixed.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




This bug report was last modified 3 years and 176 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.