aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKarl Heuer1995-01-30 22:39:20 +0000
committerKarl Heuer1995-01-30 22:39:20 +0000
commit66cf1bd7bc531951ac1f68ad009215cb088f45cb (patch)
treee2b1c01033b97287a2d93a4986e0598e7cc21b62
parentc52e9f0b084f4be8b1babb2e662c5277f1a9f687 (diff)
downloademacs-66cf1bd7bc531951ac1f68ad009215cb088f45cb.tar.gz
emacs-66cf1bd7bc531951ac1f68ad009215cb088f45cb.zip
(x-create-frame-with-faces): Assume cursor-color, mouse-color, and
border-color are okay as specified unless they are the same as the new background color.
-rw-r--r--lisp/faces.el26
1 files changed, 15 insertions, 11 deletions
diff --git a/lisp/faces.el b/lisp/faces.el
index 6ee8465b714..75b12fb03ec 100644
--- a/lisp/faces.el
+++ b/lisp/faces.el
@@ -928,17 +928,21 @@ selected frame."
928 (if resource 928 (if resource
929 (cons nil (member (downcase resource) 929 (cons nil (member (downcase resource)
930 '("on" "true"))))))) 930 '("on" "true")))))))
931 (let ((params (frame-parameters frame))) 931 (let* ((params (frame-parameters frame))
932 (modify-frame-parameters 932 (bg (cdr (assq 'foreground-color params)))
933 frame 933 (fg (cdr (assq 'background-color params))))
934 (list (cons 'foreground-color (cdr (assq 'background-color params))) 934 (modify-frame-parameters frame
935 (cons 'background-color (cdr (assq 'foreground-color params))) 935 (list (cons 'foreground-color fg)
936 (cons 'mouse-color (cdr (assq 'background-color params))) 936 (cons 'background-color bg)))
937 (cons 'border-color (cdr (assq 'background-color params))))) 937 (if (equal bg (cdr (assq 'border-color params)))
938 (modify-frame-parameters 938 (modify-frame-parameters frame
939 frame 939 (list (cons 'border-color fg))))
940 (list (cons 'cursor-color (cdr (assq 'background-color params))))))) 940 (if (equal bg (cdr (assq 'mouse-color params)))
941 941 (modify-frame-parameters frame
942 (list (cons 'mouse-color fg))))
943 (if (equal bg (cdr (assq 'cursor-color params)))
944 (modify-frame-parameters frame
945 (list (cons 'cursor-color fg))))))
942 ;; Copy the vectors that represent the faces. 946 ;; Copy the vectors that represent the faces.
943 ;; Also fill them in from X resources. 947 ;; Also fill them in from X resources.
944 (while rest 948 (while rest