Kasper Daniel Hansen | 26 Jun 2012 17:18
Picon

flyspell and Rnw files

(Only tangentially related to ESS, but posted here in case some knows).

I use flyspell-mode to spell check my Rnw files.  I have a number of
custom latex command like
  \Rcode{}
  \Rclass{}
I want to disable flyspell checking of what is inside these commands,
like not spell check 'arg' in
  \Rcode{arg}

Googling suggests that this is not straightforward, but it may be possible.

Answers to a related question, in case other people were wondering:
the following enables flyspell in tex chunks, but disables it in R
chunks

(add-hook 'ess-mode-hook
	  (lambda ()
	    (turn-off-flyspell)
	    ))

(add-hook 'LaTeX-mode-hook
	  (lambda ()
	    (turn-on-flyspell)
	    ))

Kasper

______________________________________________
ESS-help <at> r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/ess-help


Gmane