I'm trying to remap <C-right> key action from sp-forward-slurp-sexp, which is set in Prelude by default, to right-word. I tried to put that code in my init.el in .emacs.d/personal folder:

(global-unset-key (kbd "<C-right>"))
(global-set-key (kbd "<C-right>") 'right-word)

But this not work. Other code in init.el works well. Also i tried execute that code manually, via C-x C-e.


Seems like i explained my problem wrong (sry for my bad English).

The problem is: after executing code above, behavior of key binding does not change, it still execute sp-forward-slurp-sexp.

  • 1
    Possible duplicate of How can I use C-<left> C-<right> for backward/forard-word under MacOsX?
    – Heikki
    Commented May 26, 2017 at 16:40
  • 1
    'sp-forward-slurp-sexp' comes from package smartparens, Check that with 'C-h k' and press C-right at the prompt. The output should tell the command and mode it is defined in. I doubt it is global mode and that might be the source of your problem. You'd need to redefine the key in that the same mode. See github.com/Fuco1/smartparens/wiki/Working-with-expressions for a syntax example. I can not easily test that because I use an other package, paredit, that does the same as smartparents.
    – Heikki
    Commented May 26, 2017 at 17:53
  • Also, make sure your modifications load after prelude and modules it uses have been loaded.
    – Heikki
    Commented May 26, 2017 at 18:03

2 Answers 2


This one is slightly convoluted, but you're looking for:

M-x customize-option RET sp-override-key-bindings RET

Add entries for, e.g., String: <C-right> with Symbol: nil to unbind that smartparens key sequence.


Assuming you are in a Mac OS X, the OS assigns C-right to Mission Control and it never reaches emacs.

See How can I use C-<left> C-<right> for backward/forard-word under MacOsX?

  • No, i'm on Linux. updated question.
    – Flowneee
    Commented May 26, 2017 at 17:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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