aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGeoff Voelker1995-11-07 07:48:36 +0000
committerGeoff Voelker1995-11-07 07:48:36 +0000
commite80af09c2f58c1d931cbcb016dbd042c348dbf74 (patch)
tree9bc0f4e01a6f853a4c8d617184028d7d13e38a69
parent7b10bca5f78344108ff14399156d40b3407ef465 (diff)
downloademacs-e80af09c2f58c1d931cbcb016dbd042c348dbf74.tar.gz
emacs-e80af09c2f58c1d931cbcb016dbd042c348dbf74.zip
[win32] (face-menu-read-color, list-colors-display, facemenu-color-equal, face-menu-get-face):
Test for 'win32 window system as well as 'x.
-rw-r--r--lisp/facemenu.el10
1 files changed, 5 insertions, 5 deletions
diff --git a/lisp/facemenu.el b/lisp/facemenu.el
index 3b53cb1b834..772aa397c5d 100644
--- a/lisp/facemenu.el
+++ b/lisp/facemenu.el
@@ -412,7 +412,7 @@ These special properties include `invisible', `intangible' and `read-only'."
412 "Read a color using the minibuffer." 412 "Read a color using the minibuffer."
413 (let ((col (completing-read (or prompt "Color: ") 413 (let ((col (completing-read (or prompt "Color: ")
414 (or facemenu-color-alist 414 (or facemenu-color-alist
415 (if (eq 'x window-system) 415 (if (or (eq window-system 'x) (eq window-system 'win32))
416 (mapcar 'list (x-defined-colors)))) 416 (mapcar 'list (x-defined-colors))))
417 nil t))) 417 nil t)))
418 (if (equal "" col) 418 (if (equal "" col)
@@ -426,7 +426,7 @@ If the optional argument LIST is non-nil, it should be a list of
426colors to display. Otherwise, this command computes a list 426colors to display. Otherwise, this command computes a list
427of colors that the current display can handle." 427of colors that the current display can handle."
428 (interactive) 428 (interactive)
429 (if (and (null list) (eq 'x window-system)) 429 (if (and (null list) (or (eq window-system 'x) (eq window-system 'win32)))
430 (progn 430 (progn
431 (setq list (x-defined-colors)) 431 (setq list (x-defined-colors))
432 ;; Delete duplicate colors. 432 ;; Delete duplicate colors.
@@ -461,7 +461,7 @@ This function queries the window-system server to find out what the
461color names mean. It returns nil if the colors differ or if it can't 461color names mean. It returns nil if the colors differ or if it can't
462determine the correct answer." 462determine the correct answer."
463 (cond ((equal a b) t) 463 (cond ((equal a b) t)
464 ((and (eq 'x window-system) 464 ((and (or (eq window-system 'x) (eq window-system 'win32))
465 (equal (x-color-values a) (x-color-values b)))))) 465 (equal (x-color-values a) (x-color-values b))))))
466 466
467(defun facemenu-add-face (face start end) 467(defun facemenu-add-face (face start end)
@@ -523,10 +523,10 @@ or nil if given a bad color."
523 (color (substring name 3))) 523 (color (substring name 3)))
524 (cond ((string-match "^fg:" name) 524 (cond ((string-match "^fg:" name)
525 (set-face-foreground face color) 525 (set-face-foreground face color)
526 (and (eq 'x window-system) (x-color-defined-p color))) 526 (and (or (eq window-system 'x) (eq window-system 'win32)) (x-color-defined-p color)))
527 ((string-match "^bg:" name) 527 ((string-match "^bg:" name)
528 (set-face-background face color) 528 (set-face-background face color)
529 (and (eq 'x window-system) (x-color-defined-p color))) 529 (and (or (eq window-system 'x) (eq window-system 'win32)) (x-color-defined-p color)))
530 (t)))) 530 (t))))
531 symbol)) 531 symbol))
532 532