unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
* [PATCH v2] emacs: make faces clear on dark backgrounds.
@ 2016-10-20 18:22 Matt Armstrong
  2016-10-20 18:22 ` Matt Armstrong
  0 siblings, 1 reply; 7+ messages in thread
From: Matt Armstrong @ 2016-10-20 18:22 UTC (permalink / raw)
  To: notmuch


I found a multipart/signed message and verified that indeed the "blue"
button created by way of notmuch-crypto-part-header is unreadable on
dark backgrounds.

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [PATCH v2] emacs: make faces clear on dark backgrounds.
  2016-10-20 18:22 [PATCH v2] emacs: make faces clear on dark backgrounds Matt Armstrong
@ 2016-10-20 18:22 ` Matt Armstrong
  2016-10-20 19:58   ` Mark Walters
  2016-10-23  1:46   ` David Bremner
  0 siblings, 2 replies; 7+ messages in thread
From: Matt Armstrong @ 2016-10-20 18:22 UTC (permalink / raw)
  To: notmuch

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

^ permalink raw reply related	[flat|nested] 7+ messages in thread

* Re: [PATCH v2] emacs: make faces clear on dark backgrounds.
  2016-10-20 18:22 ` Matt Armstrong
@ 2016-10-20 19:58   ` Mark Walters
  2016-10-20 21:50     ` Matt Armstrong
  2016-10-20 23:41     ` David Bremner
  2016-10-23  1:46   ` David Bremner
  1 sibling, 2 replies; 7+ messages in thread
From: Mark Walters @ 2016-10-20 19:58 UTC (permalink / raw)
  To: Matt Armstrong, notmuch

On Thu, 20 Oct 2016, Matt Armstrong <marmstrong@google.com> wrote:
> 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.

Hi

Broadly this looks good to me -- though I think blue is OK on some dark
backgrounds so it would be good to have confirmation from some people
who do use a dark background normally as to whether they had to
customise these faces.

One small point: I think I would prefer a ((class color) (background
light)) test for the "light" face so that it is consistent with the other deffaces
which already distinguish between light and dark background.

Best wishes

Mark


> ---
>  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
>
> _______________________________________________
> notmuch mailing list
> notmuch@notmuchmail.org
> https://notmuchmail.org/mailman/listinfo/notmuch

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH v2] emacs: make faces clear on dark backgrounds.
  2016-10-20 19:58   ` Mark Walters
@ 2016-10-20 21:50     ` Matt Armstrong
  2016-10-21 14:09       ` David Bremner
  2016-10-20 23:41     ` David Bremner
  1 sibling, 1 reply; 7+ messages in thread
From: Matt Armstrong @ 2016-10-20 21:50 UTC (permalink / raw)
  To: Mark Walters, notmuch

[-- Attachment #1: Type: text/plain, Size: 902 bytes --]

Mark Walters <markwalters1009@gmail.com> writes:

> Broadly this looks good to me -- though I think blue is OK on some dark
> backgrounds so it would be good to have confirmation from some people
> who do use a dark background normally as to whether they had to
> customise these faces.

I'm happy to wait for further feedback.  See below for what I'm seeing. 


> One small point: I think I would prefer a ((class color) (background
> light)) test for the "light" face so that it is consistent with the other deffaces
> which already distinguish between light and dark background.

I'll send something out in a few days.  I'm thinking, though, that
perhaps options that default "blue" on light backgrounds should default
"light blue" on dark backgrounds.


Attached is a PNG capture of my M-x list-colors-display.  I'm on Ubuntu
trusty.  Attached is a screen capture of what "blue" looks like to me.


[-- Attachment #2: blue on a dark background --]
[-- Type: image/png, Size: 256282 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH v2] emacs: make faces clear on dark backgrounds.
  2016-10-20 19:58   ` Mark Walters
  2016-10-20 21:50     ` Matt Armstrong
@ 2016-10-20 23:41     ` David Bremner
  1 sibling, 0 replies; 7+ messages in thread
From: David Bremner @ 2016-10-20 23:41 UTC (permalink / raw)
  To: Mark Walters, Matt Armstrong, notmuch

Mark Walters <markwalters1009@gmail.com> writes:

> On Thu, 20 Oct 2016, Matt Armstrong <marmstrong@google.com> wrote:
>> 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.
>
> Hi
>
> Broadly this looks good to me -- though I think blue is OK on some dark
> backgrounds so it would be good to have confirmation from some people
> who do use a dark background normally as to whether they had to
> customise these faces.

I did. I first noticed it when we had that swapping of the two faces,
and a bunch of unread things became mostly unreadable.

d

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH v2] emacs: make faces clear on dark backgrounds.
  2016-10-20 21:50     ` Matt Armstrong
@ 2016-10-21 14:09       ` David Bremner
  0 siblings, 0 replies; 7+ messages in thread
From: David Bremner @ 2016-10-21 14:09 UTC (permalink / raw)
  To: Matt Armstrong, Mark Walters, notmuch

Matt Armstrong <marmstrong@google.com> writes:

>
> I'll send something out in a few days.  I'm thinking, though, that
> perhaps options that default "blue" on light backgrounds should default
> "light blue" on dark backgrounds.
>
>
> Attached is a PNG capture of my M-x list-colors-display.  I'm on Ubuntu
> trusty.  Attached is a screen capture of what "blue" looks like to me

This is awesome. We're actually bikeshedding about colours ;).

"deep sky blue" works pretty well for me on dark backgrounds.

d

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH v2] emacs: make faces clear on dark backgrounds.
  2016-10-20 18:22 ` Matt Armstrong
  2016-10-20 19:58   ` Mark Walters
@ 2016-10-23  1:46   ` David Bremner
  1 sibling, 0 replies; 7+ messages in thread
From: David Bremner @ 2016-10-23  1:46 UTC (permalink / raw)
  To: Matt Armstrong, notmuch

Matt Armstrong <marmstrong@google.com> writes:

> 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.

While we're bikeshedding, the word "clear" is pretty confusing when
talking about colours.

d

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2016-10-23  1:46 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-10-20 18:22 [PATCH v2] emacs: make faces clear on dark backgrounds Matt Armstrong
2016-10-20 18:22 ` Matt Armstrong
2016-10-20 19:58   ` Mark Walters
2016-10-20 21:50     ` Matt Armstrong
2016-10-21 14:09       ` David Bremner
2016-10-20 23:41     ` David Bremner
2016-10-23  1:46   ` David Bremner

Code repositories for project(s) associated with this public inbox

	https://yhetil.org/notmuch.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).