diff options
| author | Gerd Moellmann | 2000-11-24 13:16:13 +0000 |
|---|---|---|
| committer | Gerd Moellmann | 2000-11-24 13:16:13 +0000 |
| commit | bdc03dd96f38c4c585319301af690a8a5dc66587 (patch) | |
| tree | a60f5cac5f7b9a72c3ac6fffb2783663ad0f8ef4 | |
| parent | 9aa5f148cad4ca3166c3eb9b4e96db43c3dea079 (diff) | |
| download | emacs-bdc03dd96f38c4c585319301af690a8a5dc66587.tar.gz emacs-bdc03dd96f38c4c585319301af690a8a5dc66587.zip | |
(face-set-after-frame-default): Let face attributes
specified for new frames override frame parameters.
| -rw-r--r-- | lisp/faces.el | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/lisp/faces.el b/lisp/faces.el index 1f86b0c0075..bcf2b8ffdaf 100644 --- a/lisp/faces.el +++ b/lisp/faces.el | |||
| @@ -1488,14 +1488,16 @@ Initialize colors of certain faces from frame parameters." | |||
| 1488 | (scroll-bar-foreground scroll-bar :foreground) | 1488 | (scroll-bar-foreground scroll-bar :foreground) |
| 1489 | (scroll-bar-background scroll-bar :background) | 1489 | (scroll-bar-background scroll-bar :background) |
| 1490 | (mouse-color mouse :background)))) | 1490 | (mouse-color mouse :background)))) |
| 1491 | (while params | 1491 | (dolist (param params) |
| 1492 | (let ((param-name (nth 0 (car params))) | 1492 | (let ((frame-param (frame-parameter frame (nth 0 param))) |
| 1493 | (face (nth 1 (car params))) | 1493 | (face (nth 1 param)) |
| 1494 | (attr (nth 2 (car params))) | 1494 | (attr (nth 2 param))) |
| 1495 | value) | 1495 | (when (and frame-param |
| 1496 | (when (setq value (frame-parameter frame param-name)) | 1496 | ;; Don't override face attributes explicitly |
| 1497 | (set-face-attribute face frame attr value))) | 1497 | ;; specified for new frames. |
| 1498 | (setq params (cdr params))))) | 1498 | (eq (face-attribute face attr t) 'unspecified)) |
| 1499 | (set-face-attribute face frame attr frame-param)))))) | ||
| 1500 | |||
| 1499 | 1501 | ||
| 1500 | (defun tty-handle-reverse-video (frame parameters) | 1502 | (defun tty-handle-reverse-video (frame parameters) |
| 1501 | "Handle the reverse-video frame parameter for terminal frames." | 1503 | "Handle the reverse-video frame parameter for terminal frames." |