GNU bug report logs - #8183
isearch yanking

Previous Next

Package: emacs;

Reported by: gnu.emacs.bug <at> wongs.net

Date: Sun, 6 Mar 2011 00:06:02 UTC

Severity: minor

Merged with 7700

Found in version 24.0.50

Done: Stefan Monnier <monnier <at> iro.umontreal.ca>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 8183 in the body.
You can then email your comments to 8183 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to owner <at> debbugs.gnu.org, bug-gnu-emacs <at> gnu.org:
bug#8183; Package emacs. (Sun, 06 Mar 2011 00:06:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to gnu.emacs.bug <at> wongs.net:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Sun, 06 Mar 2011 00:06:02 GMT) Full text and rfc822 format available.

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

From: gnu.emacs.bug <at> wongs.net
To: bug-gnu-emacs <at> gnu.org
Subject: isearch yanking
Date: Sat, 5 Mar 2011 16:03:52 -0800
Hello!

I just spent a while trying to track down a bug in isearch.el that
turned out to be a "feature".  C-y has been hijacked to do some weird
thing where it pastes the entire next line of the buffer instead of
the kill ring. (Wacky!)

Please change it so that C-y works normally.

While I'm sure there's someone in the world who has a use for
searching for the entire next line, there are many, many more people
who find it useful to search for items from the kill ring.

Additionally, the way isearch is remapping the C-y key breaks Emacs's
consistency.  One of the wonderful things about Emacs is that it is
not modal.  The basic keys always work the same regardless of what
"mode" you are in.

If you are not convinced, please consider that cut and paste is
fundamental to Emacs.  C-y is so basic to how Emacs functions that
it's been listed in the Emacs tutorial (C-h t) for a quarter century.
The keybindings mentioned in the tutorial shouldn't be altered
lightly.

And finally, think about what a pain it is to teach people new to
Emacs that C-y works as yank and M-y is yank-pop, EXCEPT when doing a
search where M-y is yank and there is no way to do a yank-pop.  This
one small quirk has added work not only on to people who are trying to
learn Emacs, but on to the people teaching Emacs and trying to write
easy to understand documentation and tutorials.

Fortunately, the fix for this is easy. In isearch.el, just change the
line that defines C-y as isearch-yank-line to isearch-yank-kill.

-    (define-key map    "\C-y" 'isearch-yank-line)
+    (define-key map    "\C-y" 'isearch-yank-kill)

Thank you,

--B. Wong




Information forwarded to owner <at> debbugs.gnu.org, bug-gnu-emacs <at> gnu.org:
bug#8183; Package emacs. (Sun, 06 Mar 2011 00:24:01 GMT) Full text and rfc822 format available.

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

From: Chong Yidong <cyd <at> stupidchicken.com>
To: emacs-devel <at> gnu.org
Cc: 8183 <at> debbugs.gnu.org, gnu.emacs.bug <at> wongs.net
Subject: Re: bug#8183: isearch yanking
Date: Sat, 05 Mar 2011 19:23:31 -0500
gnu.emacs.bug <at> wongs.net writes:

> I just spent a while trying to track down a bug in isearch.el that
> turned out to be a "feature".  C-y has been hijacked to do some weird
> thing where it pastes the entire next line of the buffer instead of
> the kill ring. (Wacky!)

> Fortunately, the fix for this is easy. In isearch.el, just change the
> line that defines C-y as isearch-yank-line to isearch-yank-kill.

This has been bugging me, and has been discussed before, e.g.

  http://lists.gnu.org/archive/html/emacs-devel/2008-11/msg00485.html

Back in that 2008 thread, Juri Linkov suggested exactly this change, and
moving isearch-yank-line over to M-s C-e.

Nothing seemed to come of that suggestion, maybe due to simple inertia.
I now propose to make it so.  Any objections?




Information forwarded to owner <at> debbugs.gnu.org, bug-gnu-emacs <at> gnu.org:
bug#8183; Package emacs. (Sun, 06 Mar 2011 00:28:01 GMT) Full text and rfc822 format available.

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

From: Lennart Borgman <lennart.borgman <at> gmail.com>
To: Chong Yidong <cyd <at> stupidchicken.com>
Cc: 8183 <at> debbugs.gnu.org, gnu.emacs.bug <at> wongs.net, emacs-devel <at> gnu.org
Subject: Re: bug#8183: isearch yanking
Date: Sun, 6 Mar 2011 01:27:09 +0100
On Sun, Mar 6, 2011 at 1:23 AM, Chong Yidong <cyd <at> stupidchicken.com> wrote:
> gnu.emacs.bug <at> wongs.net writes:
>
>> I just spent a while trying to track down a bug in isearch.el that
>> turned out to be a "feature".  C-y has been hijacked to do some weird
>> thing where it pastes the entire next line of the buffer instead of
>> the kill ring. (Wacky!)
>
>> Fortunately, the fix for this is easy. In isearch.el, just change the
>> line that defines C-y as isearch-yank-line to isearch-yank-kill.
>
> This has been bugging me, and has been discussed before, e.g.
>
>  http://lists.gnu.org/archive/html/emacs-devel/2008-11/msg00485.html
>
> Back in that 2008 thread, Juri Linkov suggested exactly this change, and
> moving isearch-yank-line over to M-s C-e.
>
> Nothing seemed to come of that suggestion, maybe due to simple inertia.
> I now propose to make it so.  Any objections?

It might have stalled because we where discussing other changes to
isearch keymap, but I can see no reason to not make the proposed
change here.




Information forwarded to owner <at> debbugs.gnu.org, bug-gnu-emacs <at> gnu.org:
bug#8183; Package emacs. (Sun, 06 Mar 2011 05:34:01 GMT) Full text and rfc822 format available.

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

From: Stefan Monnier <monnier <at> iro.umontreal.ca>
To: Chong Yidong <cyd <at> stupidchicken.com>
Cc: 8183 <at> debbugs.gnu.org, gnu.emacs.bug <at> wongs.net, emacs-devel <at> gnu.org
Subject: Re: bug#8183: isearch yanking
Date: Sun, 06 Mar 2011 00:33:10 -0500
> Nothing seemed to come of that suggestion, maybe due to simple inertia.
> I now propose to make it so.  Any objections?

Please go ahead,


        Stefan




Information forwarded to owner <at> debbugs.gnu.org, bug-gnu-emacs <at> gnu.org:
bug#8183; Package emacs. (Sun, 06 Mar 2011 14:06:02 GMT) Full text and rfc822 format available.

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

From: Dani Moncayo <dmoncayo <at> gmail.com>
To: Stefan Monnier <monnier <at> iro.umontreal.ca>
Cc: Chong Yidong <cyd <at> stupidchicken.com>, 8183 <at> debbugs.gnu.org,
	gnu.emacs.bug <at> wongs.net, emacs-devel <at> gnu.org
Subject: Re: bug#8183: isearch yanking
Date: Sun, 6 Mar 2011 15:05:31 +0100
On Sun, Mar 6, 2011 at 06:33, Stefan Monnier <monnier <at> iro.umontreal.ca> wrote:
>> Nothing seemed to come of that suggestion, maybe due to simple inertia.
>> I now propose to make it so.  Any objections?
>
> Please go ahead,
>

FWIW, this bug is a duplicate of #7700.

...and what about M-y? If we are looking for consistency, M-y should
also DTRT, i.e., replace the just-yanked (in the Isearch prompt) text
with an earlier entry from the kill-ring.


Regards,

-- 
Dani Moncayo




Forcibly Merged 7700 8183. Request was from Glenn Morris <rgm <at> gnu.org> to control <at> debbugs.gnu.org. (Mon, 07 Mar 2011 02:13:02 GMT) Full text and rfc822 format available.

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Tue, 14 Jun 2011 11:24:04 GMT) Full text and rfc822 format available.

This bug report was last modified 14 years and 8 days ago.

Previous Next


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