Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Changing background color of inferior-ess-mode in Emacs

Tags:

emacs

r

ess

As I'm working a lot with Latex and Sweave/knitr, I wondered if there's a possibility to change the background color of different modes in Emacs, e.g. change the background color of inferior-ess-mode (R) or ess-mode (R-Scripts) to black. At first, the following code seems to work. But as soon as I change from ess-mode to other buffers/modes, color settings are applied.

(defun pk-black ()
(set-background-color "black")
(set-foreground-color "white"))
(add-hook 'ess-mode-hook 'pk-black)

Is there a way to change the background color only for ess-mode/inferior-ess-mode in Emacs?

like image 438
beginneR Avatar asked May 08 '12 12:05

beginneR


1 Answers

Maybe useful: BufferBackgroundColor

like image 98
Kevin Wright Avatar answered Nov 06 '22 09:11

Kevin Wright