unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
From: Tomi Ollila <tomi.ollila@iki.fi>
To: Mark Walters <markwalters1009@gmail.com>,
	notmuch@notmuchmail.org, marmstrong@google.com
Subject: Re: [PATCH] emacs: tag deleted face bugfix
Date: Sun, 18 Sep 2016 14:20:46 +0300	[thread overview]
Message-ID: <m2eg4hcv3l.fsf@guru.guru-group.fi> (raw)
In-Reply-To: <1474196252-31700-1-git-send-email-markwalters1009@gmail.com>

On Sun, Sep 18 2016, Mark Walters <markwalters1009@gmail.com> wrote:

> Commit d25d33ff cleaned up some of the tag face code. However, for the
> face notmuch-tag-deleted it used the test
>
> ((class color) (supports :strike-through))
>
> to decide whether to use red strikethrough or inverse-video (emacs in
> a terminal typically doesn't support red strikethrough, but in X it does).
>
> However, it seems that test often returns true even though red
> strikethrough is not supported. This breaks the tag update code -- the
> wrong thing is displayed to the user.
>
> Thus we make the test explicitly more specific, changing the test to
>
> ((class color) (supports :strike-through "red"))
> ---
>
> Tomi found this bug today, and narrowed it down to a recent notmuch
> change. This seems to fix it, and the code now seems to work as
> expected in terminals and in X. However I am not an expert on emacs
> faces so there may be a better way.

The change works for me and IMO it looks sensible

>-  '((((class color) (supports :strike-through)) :strike-through "red")
>+  '((((class color) (supports :strike-through "red")) :strike-through "red")

I tried to look documentation and grepped some emacs (lisp!) source to
verify that this fix is exactly as it should be, but could not find any.
Well, at least it looks better than what it used to be...

+1

Tomi



>
> Best wishes
>
> Mark
>
>
>
> emacs/notmuch-tag.el | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/emacs/notmuch-tag.el b/emacs/notmuch-tag.el
> index 644ce40..e59f148 100644
> --- a/emacs/notmuch-tag.el
> +++ b/emacs/notmuch-tag.el
> @@ -137,7 +137,7 @@ with images."
>    :type 'notmuch-tag-format-type)
>  
>  (defface notmuch-tag-deleted
> -  '((((class color) (supports :strike-through)) :strike-through "red")
> +  '((((class color) (supports :strike-through "red")) :strike-through "red")
>      (t :inverse-video t))
>    "Face used to display deleted tags.
>  
> -- 
> 2.1.4
>
> _______________________________________________
> notmuch mailing list
> notmuch@notmuchmail.org
> https://notmuchmail.org/mailman/listinfo/notmuch

  reply	other threads:[~2016-09-18 11:20 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-08-14 22:17 [PATCH] emacs: make the remaining faces configurable Matt Armstrong
2016-09-12 11:16 ` David Bremner
2016-09-18 10:57 ` [PATCH] emacs: tag deleted face bugfix Mark Walters
2016-09-18 11:20   ` Tomi Ollila [this message]
2016-09-20  0:42   ` Matt Armstrong
2016-09-25 10:52   ` David Bremner

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=m2eg4hcv3l.fsf@guru.guru-group.fi \
    --to=tomi.ollila@iki.fi \
    --cc=markwalters1009@gmail.com \
    --cc=marmstrong@google.com \
    --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).