GNU bug report logs - #9406
24.0.50; Use M-p/M-n to navigate through the kill ring

Previous Next

Package: emacs;

Reported by: Dani Moncayo <dmoncayo <at> gmail.com>

Date: Tue, 30 Aug 2011 11:43:02 UTC

Severity: wishlist

Found in version 24.0.50

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

Bug is archived. No further changes may be made.

Full log


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

From: Antoine Levitt <antoine.levitt <at> gmail.com>
To: bug-gnu-emacs <at> gnu.org
Subject: Re: bug#9406: 24.0.50; Use M-p/M-n to navigate through the kill ring
Date: Thu, 01 Sep 2011 11:53:04 +0200
01/09/11 11:13, Dani Moncayo
> On Thu, Sep 1, 2011 at 10:42, Juri Linkov <juri <at> jurta.org> wrote:
>>> WDYT?
>>
>> I think we should not change the traditional behavior of `C-y M-y M-y ...'
>> that many users are accustomed to.
>
> Sorry to hear that.  I agree that it is good to keep the traditional
> behavior as much as possible, but not at the expense of evolving
> positively.
>
>> What we could do is to activate the
>> minibuffer browsing the kill-ring on `M-y' (not preceded by `C-y').
>
> So you want to keep the current behavior of "C-y M-y" for the sake of
> "traditional behavior", so that M-y would do one thing when preceded
> by C-y, and another one (completely different) when not.  IMO, this
> mixing/overloading of functionality in M-y is not clean, and besides,
> one of those two tasks would be already implemented in M-p.  I'd like
> you to reconsider this, please.
>
>> And optionally bind `M-p'/`M-n' after `C-y' to more transient version
>> of the current `M-y' that doesn't require multiple undo (but still
>> you have to undo the first yank inserted by `C-y').
>
> 100% agreement on that (I like your "transient version" improvement).

What about the following UI?

M-y triggers a kind of kill-ring browsing: it opens a small buffer above
the minibuffer with the next killed text (that which would be inserted
by C-y), accessible with M-y or M-n. If the user presses M-y or M-n, the
buffer expands to display the previous killed text as well, accessible
with M-p. In any event, pressing RET inserts the current killed text to
the buffer, and pressing anything other than RET/M-y/M-n/M-p kills the
buffer and resumes normal editing.

C-y M-y directly jumps to the second step of the above, but inserts
automatically the current killed text, preserving backwards
compatibility.

Therefore, C-y M-y M-y ... does the right thing, with the added
convenience of a buffer allowing you to go back to a previous
completion. Also M-y becomes a nice alias for viewing the kill-ring.

This has the merit of not binding M-n / M-p in anything else than the
mode this buffer would be displayed in. Doing it any other way would
probably cause confusion to users/modes who bind M-n/M-p.

The appearance of the small window would be controllable with a boolean
setting.





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

Previous Next


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