[ESS] How to improve ESS syntax high-lighting and shortcuts

Neil Shephard nshephard at gmail.com
Wed Jun 20 15:08:34 CEST 2007


Re-sending as the default Reply-to was to the author.

On 6/20/07, Neil Shephard <nshephard at gmail.com> wrote:
> On 6/20/07, Ronaldo Reis Junior <chrysopa at gmail.com> wrote:
> > Hi,
> >
> > I use XEmacs+ESS to work with R. It is possible to improve syntax highlighting
> > to make a more readable code, somethink like highlighting functions, R
> > command and argumments?
> >
> > To comment severals lines I need to use M-x comment-region and C-u M-x
> > comment-region to make it uncommented. It is a very long command, it is
> > possible to assign a shortcut to this, like C-d to comment and C-Shift-d to
> > uncomment the code? Or, it is possible to put a menu entry in ESS menu?
>
> This is something you can do yourself, after all, each person's
> preference for key chains may differ.
>
> You don't mentinon which OS your using, nor versions of XEmacs/ESS/R,
> so I'm assuming your on a *NIX system, if your on M$-windows then you
> will likely have to add it to _emacs, not sure on the location of that
> file though.
>
> Simply add the following constructs to your ~/.emacs file and modify
> them for your desired commands
>
> (define-key keymap "keystroke" 'command-name)
> (global-set-key "keystroke" 'command-name)
> (local-set-key "keystroke" 'command-name)
>
> You will have to substitute 'keymap', 'keystroke' and 'command-name'
> in the above lines to reflect your desired key-mappings.

In addition you may find the thread that started on the 9th April by
Sven Hartenstein who has written some very useful code of interest (I
suspect this functionality may be working its way into ESS at some
point).

See the archives at
https://stat.ethz.ch/pipermail/ess-help/2007-April/thread.html

Neil
-- 
"In mathematics you don't understand things. You just get used to
them."  - Johann von Neumann

Email - nshephard at gmail.com / n.shephard at sheffield.ac.uk
Website - http://slack.ser.man.ac.uk/
Photos - http://www.flickr.com/photos/slackline/




More information about the ESS-help mailing list