In Emacs why can I not paste text C-y into a C-s search box?

link|improve this question

65% accept rate
feedback

2 Answers

up vote 3 down vote accepted

Follow this pattern:

  1. Esc-W // To copy of the selected text into buffer

  2. Ctrl-s Then press return.

  3. Ctrl-y Then press return. // To paste selected text

Then repeat Ctrl-s for incremental search. Similarly for decremental search, use Ctrl-r.

link|improve this answer
1  
Small correction: Esc-W is actually M-w (where Meta can be done with pressing ESC followed by the command key, or by pressing Alt together with the command key; all depending on configuration (and keyboard, if you happen to have a Meta key ;-))) – Jürgen A. Erhard Jan 14 '11 at 18:43
feedback

The command you are looking for is isearch-yank-kill which is bound to M-y when in isearch

M-y runs the command isearch-yank-kill, which is an interactive compiled Lisp function in `isearch.el'.

(isearch-yank-kill)

Pull string from kill ring into search string.

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.