[ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
14. Yanking
Yanking means reinserting text previously killed. This is what some systems call “pasting.” The usual way to move or copy text is to kill it and then yank it elsewhere one or more times. This is very safe because Emacs remembers many recent kills, not just the last one.
- C-y
Yank last killed text (
yank
).- M-y
Replace text just yanked with an earlier batch of killed text (
yank-pop
).- M-w
Save region as last killed text without actually killing it (
kill-ring-save
). Some systems call this “copying.”- C-M-w
Append next kill to last batch of killed text (
append-next-kill
).
On graphical displays with window systems, if there is a current selection in some other application, and you selected it more recently than you killed any text in Emacs, C-y copies the selection instead of text killed within Emacs.
14.1 The Kill Ring | Where killed text is stored. Basic yanking. | |
14.2 Appending Kills | Several kills in a row all yank together. | |
14.3 Yanking Earlier Kills | Yanking something killed some time ago. |