changeset 12626:f9a5365b158a

(font-lock-make-faces): Redo logic for whether to call font-lock-make-face for a given face.
author Richard M. Stallman <rms@gnu.org>
date Fri, 21 Jul 1995 05:05:49 +0000
parents e2831d2f5b09
children c7bc7a24b1ff
files lisp/font-lock.el
diffstat 1 files changed, 6 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/font-lock.el	Fri Jul 21 02:05:20 1995 +0000
+++ b/lisp/font-lock.el	Fri Jul 21 05:05:49 1995 +0000
@@ -307,12 +307,12 @@
   ;; Now make the faces if we have to.
   (mapcar (function (lambda (face-attributes)
 	     (let ((face (nth 0 face-attributes)))
-	       (if (and (not override) (facep face))
-		   ;; The face exists.  Only set the variable if it's nil.
-		   (if (or (not (boundp face)) (symbol-value face))
-		       (set face face))
-		 ;; The face doesn't exist or we can stomp all over it anyway.
-		 (font-lock-make-face face-attributes)))))
+               (if override
+                   (font-lock-make-face face-attributes)
+                 (if (not (and (boundp face) (facep (symbol-value face))))
+                     (if (facep face)
+                         (set face face)
+                       (font-lock-make-face face-attributes)))))))
 	  font-lock-face-attributes))
 
 (defun font-lock-make-face (face-attributes)