Re: [PATCH] emacs: wash: make word-wrap bound message width
[notmuch-archives.git] / 5a / ad046b9871df5fc8b6e98c497f05f3c5189a9a
1 Return-Path: <dme@dme.org>\r
2 X-Original-To: notmuch@notmuchmail.org\r
3 Delivered-To: notmuch@notmuchmail.org\r
4 Received: from localhost (localhost [127.0.0.1])\r
5         by olra.theworths.org (Postfix) with ESMTP id 4E7844196F3\r
6         for <notmuch@notmuchmail.org>; Wed, 19 May 2010 01:54:08 -0700 (PDT)\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
8 X-Spam-Flag: NO\r
9 X-Spam-Score: -1.9\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=-1.9 tagged_above=-999 required=5\r
12         tests=[BAYES_00=-1.9, RCVD_IN_DNSWL_NONE=-0.0001] autolearn=ham\r
13 Received: from olra.theworths.org ([127.0.0.1])\r
14         by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
15         with ESMTP id OW8gVHBUrwUy for <notmuch@notmuchmail.org>;\r
16         Wed, 19 May 2010 01:53:55 -0700 (PDT)\r
17 Received: from mail-ew0-f213.google.com (mail-ew0-f213.google.com\r
18         [209.85.219.213])\r
19         by olra.theworths.org (Postfix) with ESMTP id 7D0D84196F5\r
20         for <notmuch@notmuchmail.org>; Wed, 19 May 2010 01:53:43 -0700 (PDT)\r
21 Received: by ewy5 with SMTP id 5so1814158ewy.0\r
22         for <notmuch@notmuchmail.org>; Wed, 19 May 2010 01:53:42 -0700 (PDT)\r
23 Received: by 10.213.49.146 with SMTP id v18mr3201090ebf.25.1274259220816;\r
24         Wed, 19 May 2010 01:53:40 -0700 (PDT)\r
25 Received: from ut.hh.sledj.net (host83-217-165-81.dsl.vispa.com\r
26         [83.217.165.81])\r
27         by mx.google.com with ESMTPS id 13sm3502756ewy.13.2010.05.19.01.53.38\r
28         (version=TLSv1/SSLv3 cipher=RC4-MD5);\r
29         Wed, 19 May 2010 01:53:39 -0700 (PDT)\r
30 Received: by ut.hh.sledj.net (Postfix, from userid 1000)\r
31         id 05DD6594082; Wed, 19 May 2010 07:44:25 +0100 (BST)\r
32 From: David Edmondson <dme@dme.org>\r
33 To: notmuch@notmuchmail.org\r
34 Subject: [PATCH] emacs: Allow the display of absolute dates in the header\r
35  line.\r
36 Date: Wed, 19 May 2010 07:44:18 +0100\r
37 Message-Id: <1274251458-31253-1-git-send-email-dme@dme.org>\r
38 X-Mailer: git-send-email 1.7.1\r
39 X-BeenThere: notmuch@notmuchmail.org\r
40 X-Mailman-Version: 2.1.13\r
41 Precedence: list\r
42 List-Id: "Use and development of the notmuch mail system."\r
43         <notmuch.notmuchmail.org>\r
44 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
45         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
46 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
47 List-Post: <mailto:notmuch@notmuchmail.org>\r
48 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
49 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
50         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
51 X-List-Received-Date: Wed, 19 May 2010 08:54:08 -0000\r
52 \r
53 Add `notmuch-show-relative-dates' to control whether the summary line\r
54 in `notmuch-show' mode displays relative dates (e.g. '26 mins. ago') or\r
55 the full date string from the message. Default to `t' for\r
56 compatibility with the previous behaviour.\r
57 ---\r
58 \r
59 Re:\r
60 > <dirkhh> one thing I'd love for 0.4 (and haven't seen a patch for) is the\r
61 >          ability to disable the "xxmins. ago" and simply have it always\r
62 >          display the time a message arrived\r
63 \r
64  emacs/notmuch-show.el |    9 ++++++++-\r
65  1 files changed, 8 insertions(+), 1 deletions(-)\r
66 \r
67 diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el\r
68 index 5b0050a..2a95e62 100644\r
69 --- a/emacs/notmuch-show.el\r
70 +++ b/emacs/notmuch-show.el\r
71 @@ -64,6 +64,11 @@ any given message."\r
72    :group 'notmuch\r
73    :type 'boolean)\r
74  \r
75 +(defcustom notmuch-show-relative-dates t\r
76 +  "Display relative dates in the message summary line."\r
77 +  :group 'notmuch\r
78 +  :type 'boolean)\r
79 +\r
80  (defvar notmuch-show-markup-headers-hook '(notmuch-show-colour-headers)\r
81    "A list of functions called to decorate the headers listed in\r
82  `notmuch-message-headers'.")\r
83 @@ -592,7 +597,9 @@ current buffer, if possible."\r
84      (setq message-start (point-marker))\r
85  \r
86      (notmuch-show-insert-headerline headers\r
87 -                                   (or (plist-get msg :date_relative)\r
88 +                                   (or (if notmuch-show-relative-dates\r
89 +                                           (plist-get msg :date_relative)\r
90 +                                         nil)\r
91                                         (plist-get headers :Date))\r
92                                     (plist-get msg :tags) depth)\r
93  \r
94 -- \r
95 1.7.1\r
96 \r