Re: [PATCH v4 01/16] add util/search-path.{c, h} to test for executables in $PATH
[notmuch-archives.git] / 32 / 275289b01ec2d84ffd17774ea3b9cad066cfb8
1 Return-Path: <amdragon@mit.edu>\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 3BFBE431FAF\r
6         for <notmuch@notmuchmail.org>; Fri,  8 Aug 2014 10:06:21 -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: -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 5Sq+Mqm4ZudP for <notmuch@notmuchmail.org>;\r
16         Fri,  8 Aug 2014 10:06:15 -0700 (PDT)\r
17 Received: from dmz-mailsec-scanner-6.mit.edu (dmz-mailsec-scanner-6.mit.edu\r
18         [18.7.68.35])\r
19         (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits))\r
20         (No client certificate requested)\r
21         by olra.theworths.org (Postfix) with ESMTPS id E43C5431FAE\r
22         for <notmuch@notmuchmail.org>; Fri,  8 Aug 2014 10:06:14 -0700 (PDT)\r
23 X-AuditID: 12074423-f79bf6d000007580-39-53e5038520de\r
24 Received: from mailhub-auth-1.mit.edu ( [18.9.21.35])\r
25         (using TLS with cipher AES256-SHA (256/256 bits))\r
26         (Client did not present a certificate)\r
27         by dmz-mailsec-scanner-6.mit.edu (Symantec Messaging Gateway) with SMTP\r
28         id 38.72.30080.58305E35; Fri,  8 Aug 2014 13:06:13 -0400 (EDT)\r
29 Received: from outgoing.mit.edu (outgoing-auth-1.mit.edu [18.9.28.11])\r
30         by mailhub-auth-1.mit.edu (8.13.8/8.9.2) with ESMTP id s78H69ps025799; \r
31         Fri, 8 Aug 2014 13:06:10 -0400\r
32 Received: from drake.dyndns.org (26-4-172.dynamic.csail.mit.edu [18.26.4.172])\r
33         (authenticated bits=0)\r
34         (User authenticated as amdragon@ATHENA.MIT.EDU)\r
35         by outgoing.mit.edu (8.13.8/8.12.4) with ESMTP id s78H67Ld014615\r
36         (version=TLSv1/SSLv3 cipher=AES256-SHA bits=256 verify=NOT);\r
37         Fri, 8 Aug 2014 13:06:09 -0400\r
38 Received: from amthrax by drake.dyndns.org with local (Exim 4.77)\r
39         (envelope-from <amdragon@mit.edu>)\r
40         id 1XFncF-0006Ot-26; Fri, 08 Aug 2014 13:06:07 -0400\r
41 From: Austin Clements <amdragon@MIT.EDU>\r
42 To: notmuch@notmuchmail.org\r
43 Subject: [PATCH v2] emacs: Improved compatibility for window-body-width in\r
44         Emacs < 24\r
45 Date: Fri,  8 Aug 2014 13:06:05 -0400\r
46 Message-Id: <1407517565-24490-1-git-send-email-amdragon@mit.edu>\r
47 X-Mailer: git-send-email 2.0.0\r
48 In-Reply-To: <1407510680-17576-1-git-send-email-amdragon@mit.edu>\r
49 References: <1407510680-17576-1-git-send-email-amdragon@mit.edu>\r
50 X-Brightmail-Tracker:\r
51  H4sIAAAAAAAAA+NgFtrJIsWRmVeSWpSXmKPExsUixCmqrNvK/DTYYMd7Xoum6c4W12/OZHZg\r
52         8rh1/zW7x7NVt5gDmKK4bFJSczLLUov07RK4Mtaducxa0MdVcWF9SQPjIo4uRk4OCQETiS/P\r
53         dzFD2GISF+6tZ+ti5OIQEpjNJHF52ysoZwOjxJSWHkaQKiGBw0wS/ydXQCTmMko8XHOLBSTB\r
54         JqAhsW3/crAiEQFpiZ13Z7N2MXJwMAuYS9xsiQMJCwuESmxpbgErYRFQlbh2uJUdpIRXwEHi\r
55         1tNAiCPkJBpufGIDsTkFHCVaD11hgljrILFo/0/WCYz8CxgZVjHKpuRW6eYmZuYUpybrFicn\r
56         5uWlFuma6eVmluilppRuYgSFELuL8g7GPweVDjEKcDAq8fAKdD8OFmJNLCuuzD3EKMnBpCTK\r
57         O+vVk2AhvqT8lMqMxOKM+KLSnNTiQ4wSHMxKIrxPHgHleFMSK6tSi/JhUtIcLErivG+trYKF\r
58         BNITS1KzU1MLUotgsjIcHEoSvH+ZngYLCRalpqdWpGXmlCCkmTg4QYbzAA1/BVLDW1yQmFuc\r
59         mQ6RP8WoKCXOGwqSEABJZJTmwfXCYvwVozjQK8K8nMCIF+IBpge47ldAg5mABsuqPgYZXJKI\r
60         kJJqYLz5sDeanUtIQCOuYK5kn4T9FJfZlyySvpZmGQcoypQ8sz9UfqxPvvrB9RfdvpsMM/0v\r
61         nWx8+urDga/a6vbzD9ZEGJnuPsGzc2/aWfM9fuUnVeKLrj7ZvroyelHVl9V+h9qW7j3UV6Ms\r
62         VLrhtpj7JYaEOb01f2t1Y9v2lm0qerf6KEvauziuF0osxRmJhlrMRcWJACqSVG3MAgAA\r
63 X-BeenThere: notmuch@notmuchmail.org\r
64 X-Mailman-Version: 2.1.13\r
65 Precedence: list\r
66 List-Id: "Use and development of the notmuch mail system."\r
67         <notmuch.notmuchmail.org>\r
68 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
69         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
70 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
71 List-Post: <mailto:notmuch@notmuchmail.org>\r
72 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
73 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
74         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
75 X-List-Received-Date: Fri, 08 Aug 2014 17:06:21 -0000\r
76 \r
77 Fix byte compiler warning "Warning: the function `window-body-width'\r
78 is not known to be defined." by moving our compatibility wrapper\r
79 before its use and simplify the definition to a defalias for the old\r
80 name of the function.\r
81 ---\r
82 \r
83 Tomi pointed out that window-body-width simply used to be called\r
84 window-width, so this simplifies the wrapper to a defalias.\r
85 \r
86  emacs/notmuch-jump.el | 10 ++++------\r
87  1 file changed, 4 insertions(+), 6 deletions(-)\r
88 \r
89 diff --git a/emacs/notmuch-jump.el b/emacs/notmuch-jump.el\r
90 index 05bbce5..5eb0949 100644\r
91 --- a/emacs/notmuch-jump.el\r
92 +++ b/emacs/notmuch-jump.el\r
93 @@ -25,6 +25,10 @@\r
94  (require 'notmuch-lib)\r
95  (require 'notmuch-hello)\r
96  \r
97 +(unless (fboundp 'window-body-width)\r
98 +  ;; Compatibility for Emacs pre-24\r
99 +  (defalias 'window-body-width 'window-width))\r
100 +\r
101  ;;;###autoload\r
102  (defun notmuch-jump-search ()\r
103    "Jump to a saved search by shortcut key.\r
104 @@ -165,9 +169,3 @@ (defun notmuch-jump--make-keymap (action-map)\r
105            (setq notmuch-jump--action ',(third action))\r
106            (exit-minibuffer))))\r
107      map))\r
108 -\r
109 -(unless (fboundp 'window-body-width)\r
110 -  ;; Compatibility for Emacs pre-24\r
111 -  (defun window-body-width (&optional window)\r
112 -    (let ((edges (window-inside-edges window)))\r
113 -      (- (caddr edges) (car edges)))))\r
114 -- \r
115 2.0.0\r
116 \r