diff src/faces.c @ 195:a2f645c6b9f8 r20-3b24

Import from CVS: tag r20-3b24
author cvs
date Mon, 13 Aug 2007 09:59:05 +0200
parents 3d6bfa290dbd
children e45d5e7c476e
line wrap: on
line diff
--- a/src/faces.c	Mon Aug 13 09:58:32 2007 +0200
+++ b/src/faces.c	Mon Aug 13 09:59:05 2007 +0200
@@ -1185,6 +1185,26 @@
       FROB (background);
       FROB (display_table);
       FROB (background_pixmap);
+
+      /*
+       * A face's background pixmap will override the face's
+       * background color.  But the background pixmap of the
+       * default face should not override the background color of
+       * a face if the background color has been specified or
+       * inherited.
+       *
+       * To accomplish this we remove the background pixmap of the
+       * cachel and mark it as having been specified so that cachel
+       * merging won't override it later.
+       */
+      if (! default_face
+	  && cachel->background_specified
+	  && ! cachel->background_pixmap_specified)
+	{
+	  cachel->background_pixmap = Qunbound;
+	  cachel->background_pixmap_specified = 1;
+	}
+
 #undef FROB
 
       ensure_face_cachel_contains_charset (cachel, domain, Vcharset_ascii);