summaryrefslogtreecommitdiff
path: root/lisp/faces.el
diff options
context:
space:
mode:
authorRichard M. Stallman <rms@gnu.org>1994-07-29 21:03:37 +0000
committerRichard M. Stallman <rms@gnu.org>1994-07-29 21:03:37 +0000
commit736e2c341dbc48506fe6e004add5a93f5fe434c4 (patch)
treee0bfe0d34cce44b325dc5efc4fc18b6cf8c6f7fa /lisp/faces.el
parentd854c940a0a4ceaf6874f773dc2d3f83a6a73fdc (diff)
downloademacs-736e2c341dbc48506fe6e004add5a93f5fe434c4.tar.gz
(face-initialize): Use underlining for region face
if there's no gray. (face-try-color-list): Support `underline' in color list.
Diffstat (limited to 'lisp/faces.el')
-rw-r--r--lisp/faces.el20
1 files changed, 13 insertions, 7 deletions
diff --git a/lisp/faces.el b/lisp/faces.el
index 02de5dcc8a1..6eb43677408 100644
--- a/lisp/faces.el
+++ b/lisp/faces.el
@@ -781,7 +781,7 @@ selected frame."
(make-face-bold-italic 'bold-italic t)
(set-face-background 'highlight '("darkseagreen2" "green" t) t)
- (set-face-background 'region '("gray" t) t)
+ (set-face-background 'region '("gray" underline) t)
(set-face-background 'secondary-selection '("paleturquoise" "green" t) t)
(set-face-background 'modeline '(t) t)
(set-face-underline-p 'underline t t)
@@ -924,16 +924,22 @@ selected frame."
;; and set `done' if we succeed.
(condition-case nil
(progn
- (if (eq (car colors) t)
- (invert-face face frame)
- (funcall function face (car colors) frame))
+ (cond ((eq (car colors) t)
+ (invert-face face frame))
+ ((eq (car colors) 'underline)
+ (set-face-underline-p face t frame))
+ (t
+ (funcall function face (car colors) frame)))
(setq done t))
(error nil))
;; If this is the last color, let the error get out if it fails.
;; If it succeeds, we will exit anyway after this iteration.
- (if (eq (car colors) t)
- (invert-face face frame)
- (funcall function face (car colors) frame))))
+ (cond ((eq (car colors) t)
+ (invert-face face frame))
+ ((eq (car colors) 'underline)
+ (set-face-underline-p face t frame))
+ (t
+ (funcall function face (car colors) frame)))))
(setq colors (cdr colors)))))))
;; If we are already using x-window frames, initialize faces for them.