comparison lisp/term/w32-win.el @ 16596:0f917c0edc53

(x-defined-colors): Use color names from w32-color-map.
author Geoff Voelker <voelker@cs.washington.edu>
date Tue, 19 Nov 1996 07:19:39 +0000
parents 481b7874a1e9
children 8de32e992e4d
comparison
equal deleted inserted replaced
16595:299c63a1e83f 16596:0f917c0edc53
448 (defun x-defined-colors (&optional frame) 448 (defun x-defined-colors (&optional frame)
449 "Return a list of colors supported for a particular frame. 449 "Return a list of colors supported for a particular frame.
450 The argument FRAME specifies which frame to try. 450 The argument FRAME specifies which frame to try.
451 The value may be different for frames on different X displays." 451 The value may be different for frames on different X displays."
452 (or frame (setq frame (selected-frame))) 452 (or frame (setq frame (selected-frame)))
453 (let ((all-colors x-colors) 453 (let* ((color-map-colors (mapcar (lambda (clr) (car clr)) w32-color-map))
454 (this-color nil) 454 (all-colors (or color-map-colors x-colors))
455 (defined-colors nil)) 455 (this-color nil)
456 (defined-colors nil))
457 (message "Defining colors...")
456 (while all-colors 458 (while all-colors
457 (setq this-color (car all-colors) 459 (setq this-color (car all-colors)
458 all-colors (cdr all-colors)) 460 all-colors (cdr all-colors))
459 (and (face-color-supported-p frame this-color t) 461 (and (face-color-supported-p frame this-color t)
460 (setq defined-colors (cons this-color defined-colors)))) 462 (setq defined-colors (cons this-color defined-colors))))