changeset 107102:3554839df1fc

Fix setting family and foundry in set-face-attribute (Bug#5536). * faces.el (set-face-attribute): Allow calling internal-set-lisp-face-attribute with 'unspecified family and foundry argument (Bug#5536).
author Chong Yidong <cyd@stupidchicken.com>
date Sat, 06 Feb 2010 23:14:26 -0500
parents 3b143add1364
children f2353518b994
files lisp/ChangeLog lisp/faces.el
diffstat 2 files changed, 8 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/ChangeLog	Sat Feb 06 17:41:45 2010 -0800
+++ b/lisp/ChangeLog	Sat Feb 06 23:14:26 2010 -0500
@@ -1,3 +1,9 @@
+2010-02-07  sj  <prime.wizard+emacs@gmail.com>  (tiny change)
+
+	* faces.el (set-face-attribute): Allow calling
+	internal-set-lisp-face-attribute with 'unspecified family and
+	foundry argument (Bug#5536).
+
 2010-02-07  Glenn Morris  <rgm@gnu.org>
 
 	* progmodes/f90.el (f90-font-lock-keywords-2)
--- a/lisp/faces.el	Sat Feb 06 17:41:45 2010 -0800
+++ b/lisp/faces.el	Sat Feb 06 23:14:26 2010 -0500
@@ -735,10 +735,10 @@
 	(unless foundry
 	  (setq foundry (match-string 1 family)))
 	(setq family (match-string 2 family)))
-      (when (stringp family)
+      (when (or (stringp family) (eq family 'unspecified))
 	(internal-set-lisp-face-attribute face :family (purecopy family)
 					  where))
-      (when (stringp foundry)
+      (when (or (stringp foundry) (eq foundry 'unspecified))
 	(internal-set-lisp-face-attribute face :foundry (purecopy foundry)
 					  where)))
     (while args