Mercurial > emacs
changeset 51280:c2efaecb5d8f
(set-face-attribute): Set face-modified prop to t
when we change the new-frame defaults.
(face-spec-set): Set face-modified prop to nil
when we change the new-frame defaults.
author | Richard M. Stallman <rms@gnu.org> |
---|---|
date | Wed, 28 May 2003 11:17:33 +0000 |
parents | 92f5fdc30889 |
children | 0278ce06c1b3 |
files | lisp/faces.el |
diffstat | 1 files changed, 8 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/faces.el Wed May 28 11:16:22 2003 +0000 +++ b/lisp/faces.el Wed May 28 11:17:33 2003 +0000 @@ -664,6 +664,9 @@ like an underlying face would be, with higher priority than underlying faces." (let ((where (if (null frame) 0 frame))) (setq args (purecopy args)) + ;; If we set the new-frame defaults, this face is modified outside Custom. + (if (memq where '(0 t)) + (put face 'face-modified t)) (while args (internal-set-lisp-face-attribute face (car args) (purecopy (cadr args)) @@ -1378,7 +1381,11 @@ (setq attribute nil)))) (when attribute (set-face-attribute face frame attribute value))) - (setq attrs (cdr (cdr attrs)))))) + (setq attrs (cdr (cdr attrs))))) + ;; When we reset the face based on its spec, then it is unmodified + ;; as far as Custom is concerned. + (if (null frame) + (put face 'face-modified nil))) (defun face-attr-match-p (face attrs &optional frame)