changeset 63238:5592f504d53f

Revision: miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-398 Remove "-face" suffix from mpuz faces 2005-06-10 Miles Bader <miles@gnu.org> * lisp/play/mpuz.el (mpuz-unsolved, mpuz-solved, mpuz-trivial) (mpuz-text): Remove "-face" suffix from face names. (mpuz-unsolved-face, mpuz-solved-face, mpuz-trivial-face) (mpuz-text-face): New backward-compatibility aliases for renamed faces. (mpuz-create-buffer, mpuz-paint-digit): Use renamed mpuz faces.
author Miles Bader <miles@gnu.org>
date Fri, 10 Jun 2005 11:38:27 +0000
parents 55de715c80dc
children f48178f79206
files lisp/ChangeLog lisp/play/mpuz.el
diffstat 2 files changed, 22 insertions(+), 8 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/ChangeLog	Fri Jun 10 11:38:11 2005 +0000
+++ b/lisp/ChangeLog	Fri Jun 10 11:38:27 2005 +0000
@@ -1,5 +1,11 @@
 2005-06-10  Miles Bader  <miles@gnu.org>
 
+	* play/mpuz.el (mpuz-unsolved, mpuz-solved, mpuz-trivial)
+	(mpuz-text): Remove "-face" suffix from face names.
+	(mpuz-unsolved-face, mpuz-solved-face, mpuz-trivial-face)
+	(mpuz-text-face): New backward-compatibility aliases for renamed faces.
+	(mpuz-create-buffer, mpuz-paint-digit): Use renamed mpuz faces.
+
 	* play/gomoku.el (gomoku-O, gomoku-X):
 	Remove "-face" suffix from face names.
 	(gomoku-font-lock-O-face, gomoku-font-lock-X-face):
--- a/lisp/play/mpuz.el	Fri Jun 10 11:38:11 2005 +0000
+++ b/lisp/play/mpuz.el	Fri Jun 10 11:38:27 2005 +0000
@@ -57,28 +57,36 @@
   :type 'boolean
   :group 'mpuz)
 
-(defface mpuz-unsolved-face
+(defface mpuz-unsolved
   '((((class color)) (:foreground "red1" :bold t))
     (t (:bold t)))
   "*Face to use for letters to be solved."
   :group 'mpuz)
+;; backward-compatibility alias
+(put 'mpuz-unsolved-face 'face-alias 'mpuz-unsolved)
 
-(defface mpuz-solved-face
+(defface mpuz-solved
   '((((class color)) (:foreground "green1" :bold t))
     (t (:bold t)))
   "*Face to use for solved digits."
   :group 'mpuz)
+;; backward-compatibility alias
+(put 'mpuz-solved-face 'face-alias 'mpuz-solved)
 
-(defface mpuz-trivial-face
+(defface mpuz-trivial
   '((((class color)) (:foreground "blue" :bold t))
     (t (:bold t)))
   "*Face to use for trivial digits solved for you."
   :group 'mpuz)
+;; backward-compatibility alias
+(put 'mpuz-trivial-face 'face-alias 'mpuz-trivial)
 
-(defface mpuz-text-face
+(defface mpuz-text
   '((t (:inherit variable-pitch)))
   "*Face to use for text on right."
   :group 'mpuz)
+;; backward-compatibility alias
+(put 'mpuz-text-face 'face-alias 'mpuz-text)
 
 
 ;; Mpuz mode and keymaps
@@ -296,7 +304,7 @@
 (defun mpuz-create-buffer ()
   "Create (or recreate) the puzzle buffer. Return it."
   (let ((buf (get-buffer-create "*Mult Puzzle*"))
-	(face '(face mpuz-text-face))
+	(face '(face mpuz-text))
 	buffer-read-only)
     (save-excursion
       (set-buffer buf)
@@ -347,9 +355,9 @@
 		  (+ digit ?0)
 		(+ (mpuz-to-letter digit) ?A)))
 	(face `(face
-		,(cond ((aref mpuz-trivial-digits digit) 'mpuz-trivial-face)
-		       ((aref mpuz-found-digits digit) 'mpuz-solved-face)
-		       ('mpuz-unsolved-face))))
+		,(cond ((aref mpuz-trivial-digits digit) 'mpuz-trivial)
+		       ((aref mpuz-found-digits digit) 'mpuz-solved)
+		       ('mpuz-unsolved))))
 	buffer-read-only)
     (mapc (lambda (square)
 	    (goto-line (car square))	; line before column!