From: Jameson Rollins <jrollins@finestructure.net>
Date: Fri, 22 Jan 2010 15:45:53 +0000 (-0500)
Subject: notmuch.el: fontify date in header
X-Git-Tag: 0.2~96
X-Git-Url: https://git.cworth.org/git?a=commitdiff_plain;h=aa531a92aef4c87403cd3be307c05f8a300017c5;p=notmuch-old

notmuch.el: fontify date in header

The date was unfairly left out of getting pretty colors in the
notmuch-show header display.  This fixes that grave injustice.

Signed-off-by: Sebastian Spaeth <Sebastian@SSpaeth.de>
---

diff --git a/emacs/notmuch.el b/emacs/notmuch.el
index 5e479d65..ee5448de 100644
--- a/emacs/notmuch.el
+++ b/emacs/notmuch.el
@@ -152,7 +152,13 @@
 	      (overlay-put (make-overlay (point) (re-search-forward ":"))
 			   'face 'message-header-name)
 	      (overlay-put (make-overlay (point) (re-search-forward ".*$"))
-			   'face 'message-header-other)))))))
+			   'face 'message-header-other))
+	  (if (looking-at "[Dd]ate:")
+             (progn
+               (overlay-put (make-overlay (point) (re-search-forward ":"))
+                            'face 'message-header-name)
+               (overlay-put (make-overlay (point) (re-search-forward ".*$"))
+                            'face 'message-header-other))))))))
 
 (defun notmuch-documentation-first-line (symbol)
   "Return the first line of the documentation string for SYMBOL."