GNU bug report logs - #27634
25.2.1; C-g does not quit register-read-with-preview

Previous Next

Package: emacs;

Reported by: Paul Rankin <hello <at> paulwrankin.com>

Date: Mon, 10 Jul 2017 04:00:02 UTC

Severity: minor

Merged with 25370

Found in versions 25.1.90, 25.2.1

Done: Tino Calancha <tino.calancha <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


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

From: Paul Rankin <hello <at> paulwrankin.com>
To: Tino Calancha <tino.calancha <at> gmail.com>
Cc: Eli Zaretskii <eliz <at> gnu.org>, 27634 <at> debbugs.gnu.org
Subject: Re: bug#27634: 25.2.1; C-g does not quit register-read-with-preview
Date: Tue, 11 Jul 2017 15:07:43 +1000

> On 11 Jul 2017, at 2:48 pm, Tino Calancha <tino.calancha <at> gmail.com> wrote:
> 
> 
> 
>> On Tue, 11 Jul 2017, Paul Rankin wrote:
>> 
>> One overlooked thing about Tino's solution is that C-g is a keystroke and keyboard-quit is a function, which obviously aren't necessarily equivalent. What if the user remaps keyboard quit to "7"?
> I thought about that, but i discarded because i think binding something
> other that `keyboard-quit' to `C-g' is a misuse.  The Emacs manual is full
> of mentions to `C-g' as `keyboard-quit'.
> There is even the following remark in the tips section:
> 
> "don't bind a key sequence ending in @key{C-g}, since that
> is commonly used to cancel a key sequence."
> 
> If a user want to ignore such kind of advice he/she should
> not expect everything will work the same.

I'm gonna do this just to mess with you 😉

> Maybe we can fix this so that `register-read-with-preview'
> will work with `C-g' bound to `my-cool-foo-command'; but we
> cannot assure that no other Emacs part is affected because such
> misguided `C-g' binding.  We must encourage users to follow
> good practices.

While I think encouragement and enforcement are different things, the point about C-g is more what if the user *also* binds keyboard-quit to "7". In this case the user expects 7 to call keyboard-quit, not just C-g.

Also as Eli said ESC ESC is supposed to keyboard quit I think.

But main thing, as in life, better to look for what what you want than control for what you don't want.




This bug report was last modified 7 years and 305 days ago.

Previous Next


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