From cdba8a5aed3bd66e62f348a7064acece342bb68e Mon Sep 17 00:00:00 2001 From: John Wiegley Date: Fri, 12 Apr 2002 01:17:38 +0000 Subject: *** no comment *** --- chess.el | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) (limited to 'chess.el') diff --git a/chess.el b/chess.el index 9e4e17c..2fb35ad 100644 --- a/chess.el +++ b/chess.el @@ -98,7 +98,7 @@ a0 243 "Default engine to be used when starting a chess session." :type 'sexp :group 'chess) -(defcustom chess-announce-moves t +(defcustom chess-announce-module 'chess-announce (defcustom chess-announce-moves t This happens verbally if 'festival' is installed, otherwise it just prints a message in your minibuffer, which works well for Emacspeak @@ -123,6 +123,14 @@ minibuffer, which works well for Emacspeak users." (display (chess-display-create chess-default-display my-color)) (game (chess-game-create))) + (when (and (eq chess-default-display 'chess-images) + (with-current-buffer display + (null chess-images-size))) + (message "Could not find suitable chess images; using ics1 display") + (chess-display-destroy display) + (require 'chess-ics1) + (setq display (chess-display-create 'chess-ics1 my-color))) + (chess-display-disable-popup display)) (chess-display-set-game display game) @@ -143,9 +151,10 @@ minibuffer, which works well for Emacspeak users." ;; computerized engines fall into this category), we need to ;; let them know we're ready to begin (chess-engine-command engine 'ready)) - (when chess-announce-moves - (require 'chess-announce) - (chess-announce-for-game game)))) + (when chess-announce-module + (require chess-announce-module) + (funcall (intern (concat (symbol-name chess-announce-module) + "-for-game")) game)))) (chess-announce-for-game game))))))) (chess-display-update display t))) (cons display engine))) -- cgit v1.2.3