diff options
author | Chong Yidong <cyd@stupidchicken.com> | 2005-11-25 18:00:10 +0000 |
---|---|---|
committer | Chong Yidong <cyd@stupidchicken.com> | 2005-11-25 18:00:10 +0000 |
commit | e335f09e0ed1735d4a0f03079db5ba2f6ac5bf59 (patch) | |
tree | e0edfd30f148fda7dd038da29f2377ffc1ecbd64 /lisp/cus-face.el | |
parent | 93a068651db6a8cff364cc38d6813861ed68547b (diff) | |
download | emacs-e335f09e0ed1735d4a0f03079db5ba2f6ac5bf59.tar.gz |
* custom.el (enable-theme): Signal error if argument is not a
theme. Don't recalculate a face if it's not loaded yet.
* cus-face.el (custom-theme-set-faces): Don't change saved-face if
the `user' theme is in effect.
Diffstat (limited to 'lisp/cus-face.el')
-rw-r--r-- | lisp/cus-face.el | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/lisp/cus-face.el b/lisp/cus-face.el index 8a6e77f9805..66713c28661 100644 --- a/lisp/cus-face.el +++ b/lisp/cus-face.el @@ -320,13 +320,18 @@ FACE's list property `theme-face' \(using `custom-push-theme')." (let ((face (nth 0 entry)) (spec (nth 1 entry)) (now (nth 2 entry)) - (comment (nth 3 entry))) + (comment (nth 3 entry)) + oldspec) ;; If FACE is actually an alias, customize the face it ;; is aliased to. (if (get face 'face-alias) (setq face (get face 'face-alias))) - (put face 'saved-face spec) - (put face 'saved-face-comment comment) + + (setq oldspec (get face 'theme-face)) + (when (not (and oldspec (eq 'user (caar oldspec)))) + (put face 'saved-face spec) + (put face 'saved-face-comment comment)) + (custom-push-theme 'theme-face face theme 'set spec) (when (or now immediate) (put face 'force-face (if now 'rogue 'immediate))) |