aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatt Armstrong <marmstrong@google.com>2016-10-28 15:31:42 -0700
committerDavid Bremner <david@tethera.net>2016-11-02 07:40:20 -0300
commitd62f9dbfc0722d16f4b3a8801967e040c2033ff4 (patch)
treef509de43962dc52f38fce5ba227d2b01df4102c5
parent429c30c2bc6587023f234a8a801f9ad5ce7076c0 (diff)
emacs: make faces readable on dark backgrounds.
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 "LightBlue1" for dark backgrounds. As a side effect, these faces are now no-op definitions for grayscale or mono displays.
-rw-r--r--emacs/notmuch-crypto.el7
-rw-r--r--emacs/notmuch-tag.el7
-rw-r--r--emacs/notmuch.el6
3 files changed, 17 insertions, 3 deletions
diff --git a/emacs/notmuch-crypto.el b/emacs/notmuch-crypto.el
index e376aa80..68a7e9f3 100644
--- a/emacs/notmuch-crypto.el
+++ b/emacs/notmuch-crypto.el
@@ -42,7 +42,12 @@ mode."
:group 'notmuch-crypto)
(defface notmuch-crypto-part-header
- '((t (:foreground "blue")))
+ '((((class color)
+ (background dark))
+ (:foreground "LightBlue1"))
+ (((class color)
+ (background light))
+ (: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 1b2ce5c2..09d182df 100644
--- a/emacs/notmuch-tag.el
+++ b/emacs/notmuch-tag.el
@@ -115,7 +115,12 @@ Used in the default value of `notmuch-tag-formats`."
:group 'notmuch-faces)
(defface notmuch-tag-flagged
- '((t :foreground "blue"))
+ '((((class color)
+ (background dark))
+ (:foreground "LightBlue1"))
+ (((class color)
+ (background light))
+ (: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 ef4bb2b1..44519b7a 100644
--- a/emacs/notmuch.el
+++ b/emacs/notmuch.el
@@ -313,7 +313,11 @@ there will be called at other points of notmuch execution."
:group 'notmuch-faces)
(defface notmuch-search-flagged-face
- '((t
+ '((((class color)
+ (background dark))
+ (:foreground "LightBlue1"))
+ (((class color)
+ (background light))
(:foreground "blue")))
"Face used in search mode face for flagged threads.