unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
From: Mark Walters <markwalters1009@gmail.com>
To: Daniel Schoepe <daniel@schoepe.org>, notmuch@notmuchmail.org
Subject: Re: [PATCH] emacs: Make highlight-faces for pick configurable
Date: Sun, 12 Feb 2012 15:50:00 +0000	[thread overview]
Message-ID: <87wr7st5jr.fsf@qmul.ac.uk> (raw)
In-Reply-To: <1329058038-6029-2-git-send-email-daniel@schoepe.org>

On Sun, 12 Feb 2012 15:47:18 +0100, Daniel Schoepe <daniel@schoepe.org> wrote:
> ---
>  emacs/notmuch-pick.el |   21 ++++++++++++++++++---
>  1 files changed, 18 insertions(+), 3 deletions(-)
> 
> diff --git a/emacs/notmuch-pick.el b/emacs/notmuch-pick.el
> index 4c91d7c..2bf1ae4 100644
> --- a/emacs/notmuch-pick.el
> +++ b/emacs/notmuch-pick.el
> @@ -42,6 +42,22 @@
>    :group 'notmuch
>    :type 'int)
>  
> +(defface notmuch-pick-match-face
> +  '((((class color)
> +      (background dark))
> +     (:foreground "white"))
> +    (((class color)
> +      (background light))
> +     (:foreground "black"))
> +    (t (:bold t)))
> +  "Face used in pick mode for matching messages."
> +  :group 'notmuch)
> +
> +(defface notmuch-pick-no-match-face
> +  '((t (:foreground "gray")))
> +  "Face used in pick mode for messages not matching the query."
> +  :group 'notmuch)
> +
>  (defvar notmuch-pick-previous-subject "")
>  (make-variable-buffer-local 'notmuch-pick-previous-subject)
>  
> @@ -415,10 +431,9 @@ unchanged ADDRESS if parsing fails."
>  	 (match (plist-get msg :match))
>  	 (tags (plist-get msg :tags))
>  	 (bare-subject (notmuch-show-strip-re (plist-get headers :Subject)))
> -	 ;; Face should be a defcustom or something MJW
>  	 (message-face (if match
> -			   '(:foreground "black")
> -		       '(:foreground "gray"))))
> +			   'notmuch-pick-match-face
> +			 'notmuch-pick-no-match-face)))
>  
>      (insert (propertize (concat
>  			 (notmuch-pick-string-width

This is great. (I had even thought about the hardwired gray: that should
work on both light and dark backgrounds but had forgotten all about the
"black").

Anyway this is the correct fix: thanks!

Mark

  reply	other threads:[~2012-02-12 15:48 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-02-12 10:32 RFC notmuch-pick: an emacs threaded message view with split-pane Mark Walters
2012-02-12 10:36 ` [RFC PATCH 1/3] cli: notmuch-show changes to support pick Mark Walters
2012-02-12 10:36 ` [RFC PATCH 2/3] emacs: changes to other files to support notmuch-pick Mark Walters
2012-02-12 10:36 ` [RFC PATCH 3/3] emacs: add notmuch-pick itself Mark Walters
     [not found] ` <87ehu0cf16.fsf@schoepe.localhost>
2012-02-12 14:31   ` RFC notmuch-pick: an emacs threaded message view with split-pane Daniel Schoepe
2012-02-12 14:47 ` [PATCH 0/1] emacs: Make highlight-faces for pick configurable Daniel Schoepe
2012-02-12 14:47   ` [PATCH] " Daniel Schoepe
2012-02-12 15:50     ` Mark Walters [this message]
2012-02-12 20:46 ` RFC notmuch-pick: an emacs threaded message view with split-pane Jameson Graef Rollins
2012-02-12 20:59   ` Daniel Schoepe
2012-02-12 21:43     ` Mark Walters

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://notmuchmail.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87wr7st5jr.fsf@qmul.ac.uk \
    --to=markwalters1009@gmail.com \
    --cc=daniel@schoepe.org \
    --cc=notmuch@notmuchmail.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).