]> git.eshelyaron.com Git - emacs.git/commitdiff
(Finternal_set_lisp_face_attribute): If setting the family, clear the
authorChong Yidong <cyd@stupidchicken.com>
Mon, 12 Jan 2009 02:32:08 +0000 (02:32 +0000)
committerChong Yidong <cyd@stupidchicken.com>
Mon, 12 Jan 2009 02:32:08 +0000 (02:32 +0000)
font width index too.

src/xfaces.c

index 54c317a5ea77d31b3f45eded631ca458179325cc..141d565203fcc9474b0023fb3a6cb36362741611 100644 (file)
@@ -3341,6 +3341,12 @@ FRAME 0 means change the face on all frames, and change the default
         the attribute is mandatory.  Also, clear the average
         width.  */
       font_clear_prop (XVECTOR (lface)->contents, prop_index);
+
+      /* If we are setting QCfamily, clear out FONT_WIDTH_INDEX as
+        well.  This avoids rejecting valid families that lack support
+        for a particular width.  */
+      if (prop_index == FONT_FAMILY_INDEX)
+       font_clear_prop (XVECTOR (lface)->contents, FONT_WIDTH_INDEX);
     }
 
   /* Changing a named face means that all realized faces depending on