From: Richard M. Stallman Date: Fri, 31 Dec 2004 15:21:47 +0000 (+0000) Subject: (read-face-name): Don't treat an attribute spec as a list of faces. X-Git-Tag: ttn-vms-21-2-B4~3003 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=1bd59f82e73f9c00b3de0420b9b50a0d8f13edd5;p=emacs.git (read-face-name): Don't treat an attribute spec as a list of faces. --- diff --git a/lisp/faces.el b/lisp/faces.el index d2ae90805f2..86fda8506d4 100644 --- a/lisp/faces.el +++ b/lisp/faces.el @@ -854,12 +854,15 @@ Otherwise, return a single face." (get-char-property (point) 'face))) faces) ;; Make a list of the named faces that the `face' property uses. - (if (listp faceprop) + (if (and (listp faceprop) + ;; Don't treat an attribute spec as a list of faces. + (not (keywordp (car faceprop))) + (not (memq (car faceprop) '(foreground-color background-color)))) (dolist (f faceprop) (if (symbolp f) (push f faces))) (if (symbolp faceprop) - (setq faces (list faceprop)))) + (push faceprop faces))) ;; If there are none, try to get a face name from the buffer. (if (and (null faces) (memq (intern-soft (thing-at-point 'symbol)) (face-list)))