[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
god-mode color
From: |
BP |
Subject: |
god-mode color |
Date: |
Tue, 26 Aug 2014 08:49:11 -0700 (PDT) |
User-agent: |
G2/1.0 |
Hi everyone!
I'm trying to make some cosmetic changes of my emacs depending on god-mode
state. For now I have this :
(defun my-update-color ()
(setq cursor-type (if (or god-local-mode buffer-read-only)
'box
'bar))
(set-cursor-color (if (or god-local-mode buffer-read-only)
"firebrick1"
"LawnGreen"))
(set-face-background 'mode-line (if (or god-local-mode buffer-read-only)
"red4"
"DarkCyan")))
(add-hook 'god-mode-enabled-hook 'my-update-color)
(add-hook 'god-mode-disabled-hook 'my-update-color)
However my-update-color is not called when I switch to another buffer and the
appearance of emacs remains unchanged whatever the state of god-mode in the new
buffer.
Does anyone have an idea to make the color update correctly?
Thanks,
BP