# HG changeset patch # User Eli Zaretskii # Date 1012995247 0 # Node ID 7541bec297e37ee0273c49b2b2302e0bb32c9556 # Parent 3c64eaf60ff7482db0a7998df7e4ae7e1f623e38 (gamegrid-display-type): Treat any color-capable display as color-x, if display-color-p is fboundp. (gamegrid-make-color-x-face): Don't call gamegrid-color twice. (gamegrid-make-color-tty-face): Use the value of color, not the symbol itself. Don't call gamegrid-color. diff -r 3c64eaf60ff7 -r 7541bec297e3 lisp/play/gamegrid.el --- a/lisp/play/gamegrid.el Wed Feb 06 08:25:00 2002 +0000 +++ b/lisp/play/gamegrid.el Wed Feb 06 11:34:07 2002 +0000 @@ -166,10 +166,10 @@ face)) (defun gamegrid-make-color-tty-face (color) - (let* ((hex (gamegrid-color color 1.0)) - (name (intern (format "gamegrid-color-tty-face-%s" hex))) + (let* ((color-str (symbol-value color)) + (name (intern (format "gamegrid-color-tty-face-%s" color-str))) (face (make-face name))) - (gamegrid-setup-face face color) + (gamegrid-setup-face face color-str) face)) (defun gamegrid-make-grid-x-face () @@ -190,7 +190,7 @@ (let* ((hex (gamegrid-color color 1.0)) (name (intern (format "gamegrid-color-x-face-%s" hex))) (face (make-face name))) - (gamegrid-setup-face face (gamegrid-color color 1.0)) + (gamegrid-setup-face face hex) face)) (defun gamegrid-make-face (data-spec-list color-spec-list) @@ -257,6 +257,8 @@ (let ((window-system-p (or (and (fboundp 'console-on-window-system-p) (console-on-window-system-p)) + (and (fboundp 'display-color-p) + (display-color-p)) window-system))) (cond ((and gamegrid-use-glyphs window-system-p