[ESS] New key-binding

Steven McKinney smckinney at bccrc.ca
Thu Feb 23 00:48:07 CET 2012


> -----Original Message-----
> From: ess-help-bounces at r-project.org [mailto:ess-help-bounces at r-
> project.org] On Behalf Of Riccardo Romoli
> Sent: February-22-12 3:30 PM
> To: ess-help at r-project.org
> Subject: [ESS] New key-binding
> 
> Hi, I would like to add a new key binding to ESS in my .emacs but
> without success. In particular I would like to define C-c M-k as eval-
> chunk-and-go.
> I'm not expert in lisp programming and I tried some code with no
> results. These are my trials:
> 
> (add-hook 'ess-mode-hook '(lambda ()
>       (define-key ess-mode-map "\C-c \M-k" 'ess-eval-chunk-and-go)))
> ;;
> (add-hook 'ess-mode-hook '(lambda ()
>    (global-set-key "\C-c \M-k" 'ess-eval-chunk-and-go)))
> ;;
> (define-key map "\C-c \M-k" 'ess-eval-chunk-and-go)

Hi Riccardo

Does this work?  I have several similar commands that work on my Mac and a PC.

(global-set-key [C-c M-k] 'ess-eval-chunk-and-go)




Steven McKinney

Statistician
Molecular Oncology and Breast Cancer Program
British Columbia Cancer Research Centre





> 
> None of them gave the expected result. Where I wrong??
> 
> Best
> Riccardo
> 
> ______________________________________________
> ESS-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/ess-help



More information about the ESS-help mailing list