[ESS] Easy argument list: r-autoyas

ottorino ottorino-luca.pantani at unifi.it
Tue Mar 15 15:11:32 CET 2011

Il giorno mar, 15/03/2011 alle 13.08 +0100, Vitalie Spinu ha scritto:

> It's because ESS installs .help.ESS after the post-run hook withought
> waiting for the prompt (thing what I would personally consider to be
> almost a bug). 
> To solve it change the function r-autoyas-inject-commands  to use
> ess-eval-linewise instead of process-send-string:
> (defun r-autoyas-inject-commands ()
>   (ess-eval-linewise
>    "r.autoyas.esc <- function(str) {
>   str <- gsub('$', '\\\\$', str, fixed=TRUE)
>   str <- gsub('`', '\\\\`', str, fixed=TRUE)
> <....>
>   str
>   }\n"
>    t nil nil t)
>   )
> and restart R.
It works fine, but only after restarting emacs + ESS

>         I would rather decide when to invoke yassnippete with C-M tab.
>         But if comment the lines which enable "(" for snippets, it
>         seems that
>         the snippets are not working anymore.
>         They work if I call
>         M-x r-autoyas-expand
>         as suggested by Vitalie. 
> It might be some keyboard thing. This should be enough:
> (define-key ess-mode-map (kbd "<C-M-tab>") 'r-autoyas-expand )
> It might be your keyboard. 
> Try C-h k C-M-<tab> to see to what C-M-<tab> is assigned in your .R
> buffers.
C-h k C-M-<tab> open up an ubuntu frame which allows me to pass from
desktop to cairo-dock to the upper panel
I solved the problem by 

(define-key ess-mode-map (kbd "<C-tab>") 'r-autoyas-expand )

Is it advisable such a combination ?
In my system was not bound to any function.

I would like to be of more help than saying 

More information about the ESS-help mailing list