Re: [PATCH 1/2] Add Google Inc. to AUTHORS as a contributor.
[notmuch-archives.git] / 65 / 9a96ad0eaedb70f9954c1e8759a209208abfa1
1 Return-Path: <sojkam1@fel.cvut.cz>\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 18EA5431FBC\r
6         for <notmuch@notmuchmail.org>; Tue, 14 Feb 2012 09:10:17 -0800 (PST)\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
8 X-Spam-Flag: NO\r
9 X-Spam-Score: -2.3\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=-2.3 tagged_above=-999 required=5\r
12         tests=[RCVD_IN_DNSWL_MED=-2.3] autolearn=disabled\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 izw-zVCDOD-M for <notmuch@notmuchmail.org>;\r
16         Tue, 14 Feb 2012 09:10:16 -0800 (PST)\r
17 Received: from max.feld.cvut.cz (max.feld.cvut.cz [147.32.192.36])\r
18         by olra.theworths.org (Postfix) with ESMTP id 4D0D1431FAF\r
19         for <notmuch@notmuchmail.org>; Tue, 14 Feb 2012 09:10:16 -0800 (PST)\r
20 Received: from localhost (unknown [192.168.200.4])\r
21         by max.feld.cvut.cz (Postfix) with ESMTP id 45AE53CFE81;\r
22         Tue, 14 Feb 2012 18:10:15 +0100 (CET)\r
23 X-Virus-Scanned: IMAP AMAVIS\r
24 Received: from max.feld.cvut.cz ([192.168.200.1])\r
25         by localhost (styx.feld.cvut.cz [192.168.200.4]) (amavisd-new,\r
26         port 10044)\r
27         with ESMTP id bHZU3-R4mE6N; Tue, 14 Feb 2012 18:10:11 +0100 (CET)\r
28 Received: from imap.feld.cvut.cz (imap.feld.cvut.cz [147.32.192.34])\r
29         by max.feld.cvut.cz (Postfix) with ESMTP id 4D3303CFE77;\r
30         Tue, 14 Feb 2012 18:10:11 +0100 (CET)\r
31 Received: from steelpick.2x.cz (unknown [141.76.49.23])\r
32         (Authenticated sender: sojkam1)\r
33         by imap.feld.cvut.cz (Postfix) with ESMTPSA id 3B7A9660968;\r
34         Tue, 14 Feb 2012 18:10:11 +0100 (CET)\r
35 Received: from wsh by steelpick.2x.cz with local (Exim 4.77)\r
36         (envelope-from <sojkam1@fel.cvut.cz>)\r
37         id 1RxLtK-0001fk-Uu; Tue, 14 Feb 2012 18:10:10 +0100\r
38 From: Michal Sojka <sojka@os.inf.tu-dresden.de>\r
39 To: notmuch@notmuchmail.org\r
40 Subject: [PATCH v2] emacs: Fix display of highlighted line in notmuch-search\r
41 Date: Tue, 14 Feb 2012 18:09:47 +0100\r
42 Message-Id: <1329239387-6300-1-git-send-email-sojka@os.inf.tu-dresden.de>\r
43 X-Mailer: git-send-email 1.7.7.3\r
44 In-Reply-To: <87mx8lpd5o.fsf@nikula.org>\r
45 References: <87mx8lpd5o.fsf@nikula.org>\r
46 Cc: Michal Sojka <sojka@os.inf.tu-dresden.de>\r
47 X-BeenThere: notmuch@notmuchmail.org\r
48 X-Mailman-Version: 2.1.13\r
49 Precedence: list\r
50 List-Id: "Use and development of the notmuch mail system."\r
51         <notmuch.notmuchmail.org>\r
52 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
53         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
54 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
55 List-Post: <mailto:notmuch@notmuchmail.org>\r
56 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
57 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
58         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
59 X-List-Received-Date: Tue, 14 Feb 2012 17:10:17 -0000\r
60 \r
61 When notmuch-search-line-faces is used to set background color in search\r
62 results, the highlight of the current line is not always displayed\r
63 correctly. This patch fixes that by increasing the priority property of\r
64 the highlight overlay.\r
65 ---\r
66  emacs/notmuch.el |   15 +++++++++++----\r
67  1 files changed, 11 insertions(+), 4 deletions(-)\r
68 \r
69 diff --git a/emacs/notmuch.el b/emacs/notmuch.el\r
70 index 5b4f1c5..f851c6f 100644\r
71 --- a/emacs/notmuch.el\r
72 +++ b/emacs/notmuch.el\r
73 @@ -249,10 +249,17 @@ For a mouse binding, return nil."\r
74        (set-buffer-modified-p nil)\r
75        (view-buffer (current-buffer) 'kill-buffer-if-not-modified))))\r
76  \r
77 -(defcustom notmuch-search-hook '(hl-line-mode)\r
78 +(require 'hl-line)\r
79 +\r
80 +(defun notmuch-hl-line-mode ()\r
81 +  (prog1 (hl-line-mode)\r
82 +    (when hl-line-overlay\r
83 +      (overlay-put hl-line-overlay 'priority 1))))\r
84 +\r
85 +(defcustom notmuch-search-hook '(notmuch-hl-line-mode)\r
86    "List of functions to call when notmuch displays the search results."\r
87    :type 'hook\r
88 -  :options '(hl-line-mode)\r
89 +  :options '(notmuch-hl-line-mode)\r
90    :group 'notmuch-search\r
91    :group 'notmuch-hooks)\r
92  \r
93 @@ -567,7 +574,7 @@ a list of strings of the form \"+TAG\" or \"-TAG\".\r
94  the messages that are about to be tagged"\r
95  \r
96    :type 'hook\r
97 -  :options '(hl-line-mode)\r
98 +  :options '(notmuch-hl-line-mode)\r
99    :group 'notmuch-hooks)\r
100  \r
101  (defcustom notmuch-after-tag-hook nil\r
102 @@ -578,7 +585,7 @@ a list of strings of the form \"+TAG\" or \"-TAG\".\r
103  'query' will be a string containing the search query that determines\r
104  the messages that were tagged"\r
105    :type 'hook\r
106 -  :options '(hl-line-mode)\r
107 +  :options '(notmuch-hl-line-mode)\r
108    :group 'notmuch-hooks)\r
109  \r
110  (defun notmuch-search-set-tags (tags)\r
111 -- \r
112 1.7.7.3\r
113 \r