unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
From: David Edmondson <dme@dme.org>
To: notmuch@notmuchmail.org
Subject: [PATCH v1 1/3] emacs: Improve crypto button labels.
Date: Tue,  9 Feb 2016 12:23:49 +0000	[thread overview]
Message-ID: <1455020631-15646-2-git-send-email-dme@dme.org> (raw)
In-Reply-To: <1455020631-15646-1-git-send-email-dme@dme.org>

Make the labels for both encryption and signature buttons share a common
format, in which both report the status if it is not one of those known.
---
 emacs/notmuch-crypto.el | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/emacs/notmuch-crypto.el b/emacs/notmuch-crypto.el
index 5233824..73ebf51 100644
--- a/emacs/notmuch-crypto.el
+++ b/emacs/notmuch-crypto.el
@@ -110,8 +110,8 @@ mode."
 	(setq label (concat "Bad signature (claimed key ID " keyid ")"))
 	(setq face 'notmuch-crypto-signature-bad)))
      (t
-      (setq label "Unknown signature status")
-      (if status (setq label (concat label " \"" status "\"")))))
+      (setq label (concat "Unknown signature status"
+			  (if status (concat ": " status))))))
     (insert-button
      (concat "[ " label " ]")
      :type 'notmuch-crypto-status-button-type
@@ -161,7 +161,8 @@ mode."
      ((string= status "bad")
       (setq label "Decryption error"))
      (t
-      (setq label (concat "Unknown encstatus \"" status "\""))))
+      (setq label (concat "Unknown encryption status"
+			  (if status (concat ": " status))))))
     (insert-button
      (concat "[ " label " ]")
      :type 'notmuch-crypto-status-button-type
-- 
2.1.4

  reply	other threads:[~2016-02-09 12:23 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-02-09 12:23 [PATCH v1 0/3] Always insert crypto buttons David Edmondson
2016-02-09 12:23 ` David Edmondson [this message]
2016-03-24 11:01   ` [PATCH v1 1/3] emacs: Improve crypto button labels David Bremner
2016-02-09 12:23 ` [PATCH v1 2/3] emacs: Always insert crypto buttons David Edmondson
2016-03-24 11:00   ` David Bremner
2016-04-03 15:40     ` David Edmondson
2016-02-09 12:23 ` [PATCH v1 3/3] Test: Fix tests David Edmondson

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=1455020631-15646-2-git-send-email-dme@dme.org \
    --to=dme@dme.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).