From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stephen Berman via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#73986: 31.0.50; Allow suppressing message passed to set-transient-map Date: Thu, 24 Oct 2024 20:12:06 +0200 Message-ID: <87zfmtpdzd.fsf@gmx.net> References: <874j51r3xd.fsf@gmx.net> <86cyjps9vv.fsf@mail.linkov.net> Reply-To: Stephen Berman Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="21731"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: 73986@debbugs.gnu.org To: Juri Linkov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Oct 24 20:12:48 2024 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1t42KG-0005VF-3f for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 24 Oct 2024 20:12:48 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1t42K0-00006l-Kk; Thu, 24 Oct 2024 14:12:32 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1t42Jz-00006J-5q for bug-gnu-emacs@gnu.org; Thu, 24 Oct 2024 14:12:31 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1t42Jy-0004y9-TP for bug-gnu-emacs@gnu.org; Thu, 24 Oct 2024 14:12:30 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:Date:References:In-Reply-To:From:To:Subject; bh=L7dm09JR0FyGHwoGWxHRugHr9hJaJsBkWDvd29erZIg=; b=imSnRcStsEY8ARNE714ZD01qCbjnlyGCSbs2IagxsIo4DIUOaqUK8+WTgAnqKeyUBlfyelR4QcWXdtKfjjSLCmFroUQiOgK+OZgVSeeICxJ9DBZjrXQuiU3XpmdG9F1aDsb1PPYG3TrPevDLZxpNHSNQg6TG1RlpjMldnqvLvtzRIdfRdet9MxZ4ITb7As96wt7BHHntxDknWQ+Vl3BrpQRHKLPuiKIML3Kv/7BEuYjhZr8i5Fbb5nWoDVz8uDKmaw3sTwjeNlpc9MVC1zjkRojZxtUace6j+gwlETp9hMOl7TC7Zsocme7i3wv4jOeWVFNEKywM6TnPCUPF60Fwvg==; Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1t42KT-0000dQ-N4 for bug-gnu-emacs@gnu.org; Thu, 24 Oct 2024 14:13:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Stephen Berman Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 24 Oct 2024 18:13:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 73986 X-GNU-PR-Package: emacs Original-Received: via spool by 73986-submit@debbugs.gnu.org id=B73986.17297935722420 (code B ref 73986); Thu, 24 Oct 2024 18:13:01 +0000 Original-Received: (at 73986) by debbugs.gnu.org; 24 Oct 2024 18:12:52 +0000 Original-Received: from localhost ([127.0.0.1]:36134 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1t42KJ-0000cx-I1 for submit@debbugs.gnu.org; Thu, 24 Oct 2024 14:12:52 -0400 Original-Received: from mout.gmx.net ([212.227.15.19]:42381) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1t42KG-0000cf-SG for 73986@debbugs.gnu.org; Thu, 24 Oct 2024 14:12:50 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmx.net; s=s31663417; t=1729793531; x=1730398331; i=stephen.berman@gmx.net; bh=L7dm09JR0FyGHwoGWxHRugHr9hJaJsBkWDvd29erZIg=; h=X-UI-Sender-Class:From:To:Cc:Subject:In-Reply-To:References:Date: Message-ID:MIME-Version:Content-Type:cc:content-transfer-encoding: content-type:date:from:message-id:mime-version:reply-to:subject: to; b=EuKSAdfC79nDFc5S006byKMnRqYgu6m8QryzZtkV87lAPKiZusgRSF0XYUynld8/ QF12XJ8zl1LGAAOPMkWfrv1nldsyDYqnLQa4NiQ1w8WArmo7OpuhhtcIdIYEGm6sd 5+0IR4PRkrGNF4Y4+B3h9AHk1DsjgqkYMw79nZl6+luH/HdAB0vbrwzmRxKz39AwS V606KnAcc2320vvCIUemwPR8++CfGYXe5FI9JQuED/fvaP5L2DK039CjvST7r66/p xD745cTDmRb/rUOKt5dfB2nWI8ky4+64vZPhGXzBOckazhfGQPEl0l8Ruy54XiaqZ Ou/axU6Nx1zftXhf1g== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Original-Received: from strobelfssd ([88.130.48.171]) by mail.gmx.net (mrgmx004 [212.227.17.190]) with ESMTPSA (Nemesis) id 1MryXH-1tiuti1G21-00i9KF; Thu, 24 Oct 2024 20:12:11 +0200 In-Reply-To: <86cyjps9vv.fsf@mail.linkov.net> (Juri Linkov's message of "Thu, 24 Oct 2024 20:12:20 +0300") X-Provags-ID: V03:K1:fx5jiXyCb4L8oQNEPagptyPmFUYYk49+cbcuJu4XDaeC7RaHHjY 09fd7xin/WHzRd/geh1+9r/RWaCemOqVvnM+mRzeRdLOzhHCublumwYPTIWLDtNNqmAEv+9 oqm72QSw97m+twFW4wCTxRCOJVB+9uwHCc0ZPpw5/6Sa1V/ZzoDaBnvi3JwPyTAphPW+po9 HaYDG65SZRzyQczheq3oA== UI-OutboundReport: notjunk:1;M01:P0:Aquritzp0n4=;CaIlGH8fl4VOXEFm8dznYrKwLZU ePQHxMM+vocryFjo+0YGrd0uMJa+JRpeGGl1q/ttmcywGvIDT+mPY1vjthbTNhu3ySSn8OOy+ uN4MtHRzda+iEF+jFuYYfsTTEavB+S7PamSEUuOUOHksXhKtoz0tKbAqV3acsP1mSfy7hqiyV l69QYpIZHvudpucL2THIwIOVfURuFGDrtMZ8yKLr8bMlxicjQleS4XHLYQLmNSX+xehouk6Z6 Pnc1/T5NC+YJ4ZSgDShrO/EEW3Ox6wJ9EEiXsGayoRD5nFOVINboTXh+S9ArhDWMKzyP30wA8 7dZ9XttFSDletAbBbn5T7XpeW7sPCFavUh6w47uCd+qkm6XM4M1y2OHjdvrv8HUPzDOx2muDI 2H3VNH/GsRdEBly14yw1JxdpmGS5luVLltjjwjGfKpMb7/tpTNkWvg754QY9i7zgglPkgdqlg 3rPr+gPwChY4MXTvTPuXACAni7xUJFd1OhFqee1MEEmZsXa9RHGX+4lt59l3WHGZdyq+Uc6jb cPvdlrjF1r/C9Jnyh8RE2oIXeF1uzYzqXXR3OL+6Mu6gaNUZE1MZXvpNV7zj06+LfN8clp7mf EjadX8AIL/2+QqiotfGvwaWXE6yVQNpi0ALNlRuk67W0Kv/sI46tOJsS8QNTfpqrkZztiPsgy ENMI4qThTskk0tfvoA4sbQ5wGl57hKULx/Sv59HBfxXHbHkiInHZwXFxeAtli4OJACaQ0Hmpw dusvCaPLuiSfBIwbpZ7B6C4WHYxoeP6Rz2ZCQY4k9CwkHzxxI8TrIBhghyLmBVATHB/CB8PU X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:294203 Archived-At: On Thu, 24 Oct 2024 20:12:20 +0300 Juri Linkov wrote: >> If a caller of set-transient-map passes a suitable format string, this >> is displayed as a message on activating the transient map. An example >> is text-scale-adjust, which displays the message "Use +, =, -, 0, C-+, >> C-=, C--, C-0 for further adjustment". So if after typing `C-x C-+' you >> immediately type `+ + + - - -', the text size increases three times and >> then decreases three times. But on each key press the message is >> redisplayed, which is slighty annoying (it actually looks like it stays >> in the echo area but there is a brief flicker on each key press); the >> message is helpful the first time, if you're unfamiliar with the >> command, but on repeated uses, it becomes visual noise. So I propose a >> user option to suppress the message, as in the attached patch. > > Instead of adding a myriad of user options for every command > that displays a message, we decided to create a single point > of customization, so you could just set these options: > > (add-to-list 'set-message-functions 'inhibit-message) > (add-to-list 'inhibit-message-regexps "for further adjustment") Ah, thanks, I now vaguely recall seeing these but forgot about them. They indeed do work just as well as my proposed change to set-transient-map for text-scale-adjust as well as two private functions I use that pass a message string matching the same regexp, so that satisfies my immediate wish. Still, there could be any number of callers of set-transient-map that pass message strings users may want to suppress but that require a different regexp, in which case the burden on the user is more than with my patch. But since that's AFAIK currently only a theoretical possibility, I won't pursue the proposal. I'll wait a few days in case someone does chime in favor of my patch, but otherwise I'll then close the bug. Steve Berman