[PATCH v2] emacs: make faces clear on dark backgrounds.

Matt Armstrong marmstrong at google.com
Thu Oct 20 11:22:34 PDT 2016


The notmuch-tag-flagged, notmuch-search-flagged-face and
notmuch-crypto-part-header faces defaulted to "blue", which is nearly
unreadable when a dark background is in use.  This is addressed by using
"gold" for dark backgrounds.
---
 emacs/notmuch-crypto.el | 5 ++++-
 emacs/notmuch-tag.el    | 5 ++++-
 emacs/notmuch.el        | 5 ++++-
 3 files changed, 12 insertions(+), 3 deletions(-)

diff --git a/emacs/notmuch-crypto.el b/emacs/notmuch-crypto.el
index e376aa8..3f4b3f6 100644
--- a/emacs/notmuch-crypto.el
+++ b/emacs/notmuch-crypto.el
@@ -42,7 +42,10 @@ mode."
   :group 'notmuch-crypto)
 
 (defface notmuch-crypto-part-header
-  '((t (:foreground "blue")))
+  '((((class color)
+      (background dark))
+     (:foreground "gold"))
+    (t (:foreground "blue")))
   "Face used for crypto parts headers."
   :group 'notmuch-crypto
   :group 'notmuch-faces)
diff --git a/emacs/notmuch-tag.el b/emacs/notmuch-tag.el
index 1b2ce5c..199582b 100644
--- a/emacs/notmuch-tag.el
+++ b/emacs/notmuch-tag.el
@@ -115,7 +115,10 @@ Used in the default value of `notmuch-tag-formats`."
   :group 'notmuch-faces)
 
 (defface notmuch-tag-flagged
-  '((t :foreground "blue"))
+  '((((class color)
+      (background dark))
+     (:foreground "gold"))
+    (t :foreground "blue"))
   "Face used for the flagged tag.
 
 Used in the default value of `notmuch-tag-formats`."
diff --git a/emacs/notmuch.el b/emacs/notmuch.el
index bd08aa0..9246344 100644
--- a/emacs/notmuch.el
+++ b/emacs/notmuch.el
@@ -313,7 +313,10 @@ there will be called at other points of notmuch execution."
   :group 'notmuch-faces)
 
 (defface notmuch-search-flagged-face
-  '((t
+  '((((class color)
+      (background dark))
+     (:foreground "gold"))
+    (t
      (:foreground "blue")))
   "Face used in search mode face for flagged threads.
 
-- 
2.8.0.rc3.226.g39d4020



More information about the notmuch mailing list