Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Is there a hotkey for paste in ubuntu emacs? The terminal hotkey (Crtl-Shift v) for instance does not work.

share|improve this question
Are you running the GUI version, or actually running it in a terminal? – GodEater Dec 29 '09 at 7:23
What version of Emacs? – John T Dec 29 '09 at 7:33

From the Emacs Wiki.

Emacs is customizable, so you can easily modify the behavior. The default behavior is the Kill/Yank method.

If you're using X11 Emacs (version 21.x+), you can enable Emacs to use the clipboard.

x-select-enable-clipboard is a variable defined in `C source code'.

Non-nil means cutting and pasting uses the clipboard.
This is in addition to, but in preference to, the primary selection.

On MS-Windows, this is non-nil by default, since Windows does not
support other types of selections.  (The primary selection that is
set by Emacs is not accessible to other programs on Windows.)

There's additional notes inclusive for Emacs 23.x+ (which is the version on the latest version of Ubuntu).

The following represents something extremely close in “feel” to other modern X11 desktop apps, but with “bonus” kill ring features. “feel”? that is to say, the precise key bindings are different to other X11 apps unless maybe you also turn on cua-mode, but the behaviour is very similar to C-x/C-c/C-v clipboard in other apps:

clipboard and primary X11 selections are kept separate, yet clipboard X11 selection and kill-ring are friends.

The listing for binding the defaults to the clipboard-* functions works well on both Linux and w32 version of Emacs.

In most cases if using either X11 or Emacs within a terminal, the middle mouse button is the customary paste button. The main difference is for graphical Emacs, the paste occurs at the pointer whereas within a terminal the paste occurs at the cursor.

share|improve this answer

By default, GNU Emacs (the default emacs23 package in current Ubuntu) only does X11 clipboard functions through the edit menu, or by directly invoking the "clipboard-*" functions with M-x.

If you would like to have Emacs handle clipboard functions in the same way your terminal does, you can add this to your ~/.emacs file.

(global-set-key [(control shift X)] 'clipboard-kill-region)
(global-set-key [(control shift C)] 'clipboard-kill-ring-save)
(global-set-key [(control shift V)] 'clipboard-yank)

Hope that helps!

Also, if you look around, you may notice that kbd seems to be the preferred function for handling shortcuts in Emacs these days, but I had some problems with it "translating" C-S-X into C-x constantly.

share|improve this answer

S-Insert works for me.

<S-insert> runs the command yank, which is an interactive compiled
Lisp function in `simple.el'.

It is bound to <S-insert>, <S-insertchar>, C-y.

(yank &optional arg)

Reinsert ("paste") the last stretch of killed text.
More precisely, reinsert the stretch of killed text most recently
killed OR yanked.  Put point at end, and set mark at beginning.
With just C-u as argument, same but put point at beginning (and mark at end).
With argument N, reinsert the Nth most recently killed stretch of killed

When this command inserts killed text into the buffer, it honors
`yank-excluded-properties' and `yank-handler' as described in the
doc string for `insert-for-yank-1', which see.

See also the command `yank-pop' (M-y).
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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