# HG changeset patch # User Gerd Moellmann # Date 977151902 0 # Node ID 4130c0ad0a5eb772e64302283db8df4634df1487 # Parent 34b048e564c0b0b23e9d5edd6d876c31730ad33c (face-spec-set): Interpret a nil in specs for foreground and background colors as `unspecified', for compatibility with 20.x. diff -r 34b048e564c0 -r 4130c0ad0a5e lisp/faces.el --- a/lisp/faces.el Mon Dec 18 13:57:32 2000 +0000 +++ b/lisp/faces.el Mon Dec 18 15:05:02 2000 +0000 @@ -1230,6 +1230,10 @@ (case attribute (:bold (setq attribute :weight value (if value 'bold 'normal))) (:italic (setq attribute :slant value (if value 'italic 'normal))) + ((:foreground :background) + ;; Compatibility with 20.x. Some bogus face specs seem to + ;; exist containing things like `:foreground nil'. + (if (null value) (setq value 'unspecified))) (t (unless (assq attribute face-x-resources) (setq attribute nil)))) (when attribute