Return-Path: X-Original-To: notmuch@notmuchmail.org Delivered-To: notmuch@notmuchmail.org Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id C104D431FBC for ; Tue, 16 Feb 2010 01:51:38 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: -1.127 X-Spam-Level: X-Spam-Status: No, score=-1.127 tagged_above=-999 required=5 tests=[AWL=-0.017, BAYES_05=-1.11] autolearn=ham Received: from olra.theworths.org ([127.0.0.1]) by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id HmKpAeF-Zclq for ; Tue, 16 Feb 2010 01:51:38 -0800 (PST) Received: from homiemail-a11.g.dreamhost.com (caiajhbdcaid.dreamhost.com [208.97.132.83]) by olra.theworths.org (Postfix) with ESMTP id E224B431FAE for ; Tue, 16 Feb 2010 01:51:37 -0800 (PST) Received: from localhost.localdomain (unknown [195.190.178.84]) by homiemail-a11.g.dreamhost.com (Postfix) with ESMTPA id A8A96194058; Tue, 16 Feb 2010 01:51:29 -0800 (PST) From: Sebastian Spaeth To: notmuch@notmuchmail.org Date: Tue, 16 Feb 2010 10:51:20 +0100 Message-Id: <1266313880-16085-1-git-send-email-Sebastian@SSpaeth.de> X-Mailer: git-send-email 1.6.3.3 In-Reply-To: References: Subject: [notmuch] [PATCHv2] notmuch.el: Colour cited regions and signatures with message-cited-text-face. X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Feb 2010 09:51:38 -0000 From: David Edmondson Signed-off-by: Sebastian Spaeth --- This is the fixed up version as elaborated by David. I find it pretty and pretty useful, so applying this makes lots of sense :). notmuch.el | 17 ++++++++++------- 1 files changed, 10 insertions(+), 7 deletions(-) diff --git a/notmuch.el b/notmuch.el index 77f36d8..4cc97de 100644 --- a/notmuch.el +++ b/notmuch.el @@ -761,6 +761,7 @@ is what to put on the button." (let* ((cite-start (match-beginning 0)) (cite-end (match-end 0)) (cite-lines (count-lines cite-start cite-end))) + (overlay-put (make-overlay cite-start cite-end) 'face 'message-cited-text-face) (when (> cite-lines (1+ notmuch-show-citation-lines-prefix)) (goto-char cite-start) (forward-line notmuch-show-citation-lines-prefix) @@ -777,13 +778,15 @@ is what to put on the button." (sig-end (match-end 0)) (sig-lines (1- (count-lines sig-start end)))) (if (<= sig-lines notmuch-show-signature-lines-max) - (notmuch-show-region-to-button - sig-start - end - "signature" - indent - (format notmuch-show-signature-button-format sig-lines) - )))))) + (progn + (overlay-put (make-overlay sig-start end) 'face 'message-cited-text-face) + (notmuch-show-region-to-button + sig-start + end + "signature" + indent + (format notmuch-show-signature-button-format sig-lines) + ))))))) (defun notmuch-show-markup-part (beg end depth) (if (re-search-forward notmuch-show-part-begin-regexp nil t) -- 1.6.3.3