GNU bug report logs - #79143
[PATCH] New user option to inhibit Calc startup message

Previous Next

Package: emacs;

Reported by: Sean Devlin <spd <at> toadstyle.org>

Date: Fri, 1 Aug 2025 22:17:02 UTC

Severity: normal

Tags: patch

Full log


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

From: Sean Devlin <spd <at> toadstyle.org>
To: Christopher Howard <christopher <at> librehacker.com>
Cc: Eli Zaretskii <eliz <at> gnu.org>, 79143 <at> debbugs.gnu.org
Subject: Re: bug#79143: [PATCH] New user option to inhibit Calc startup message
Date: Sun, 3 Aug 2025 10:41:32 -0500
> On Aug 2, 2025, at 8:56 PM, Christopher Howard <christopher <at> librehacker.com> wrote:
> 
>> Christopher, any comments?  (I hope you don't mind being involved in
>> maintenance of Calc by way of reviewing patches of others.)
> 
> The basic idea seems straightforward enough. Just glancing over the patch quickly, I wonder what significance that calc-said-hello variable has and if we are handling that logic for that correctly. But I haven't looked at the larger context.
> 

Hi Christopher,

I investigated this a little while I was developing the change.

Calc-said-hello is a defvar (as opposed to defcustom or defcalcmodevar) with this doc string:

“Non-nil if the welcome message has been displayed.”

It’s referenced only in the calc defun at the end:

        (message (substitute-command-keys
                  (concat "Welcome to the GNU Emacs Calculator!  \\<calc-mode-map>"
                          "Press \\[calc-help] or \\[calc-help-prefix] for help, \\[calc-quit] to quit")))
        ...
        (when (and calc-said-hello interactive)
          (sit-for 2)
          (message ""))
        (setq calc-said-hello t)

Basically, the first time we run M-x calc, the welcome message stays there until the user does something. On subsequent uses of M-x calc (within the same Emacs session), we clear the welcome message after two seconds or when the user does something, whichever comes first.

I think my patch makes sense with respect to managing this variable. If calc-inhibit-startup-message is set, we avoid setting this flag, since Calc hasn’t “said hello” yet. If the user then clears calc-inhibit-startup-message, the next invocation of M-x calc will be the first time the welcome message appears, so presumably we want it to stay there until the user does something and give them time to read it.

What do you think?

Cheers.

> -- 
> Christopher Howard





This bug report was last modified 4 days ago.

Previous Next


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