Return-Path: X-Original-To: notmuch@notmuchmail.org Delivered-To: notmuch@notmuchmail.org Received: from localhost (localhost [127.0.0.1]) by arlo.cworth.org (Postfix) with ESMTP id 4A14E6DE17FD for ; Sat, 1 Aug 2015 02:47:21 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at cworth.org X-Spam-Flag: NO X-Spam-Score: 0.153 X-Spam-Level: X-Spam-Status: No, score=0.153 tagged_above=-999 required=5 tests=[AWL=0.143, T_HEADER_FROM_DIFFERENT_DOMAINS=0.01] autolearn=disabled Received: from arlo.cworth.org ([127.0.0.1]) by localhost (arlo.cworth.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id GlOT3I2NMzBG for ; Sat, 1 Aug 2015 02:47:19 -0700 (PDT) Received: from gitolite.debian.net (gitolite.debian.net [87.98.215.224]) by arlo.cworth.org (Postfix) with ESMTPS id A88646DE17F7 for ; Sat, 1 Aug 2015 02:47:19 -0700 (PDT) Received: from remotemail by gitolite.debian.net with local (Exim 4.80) (envelope-from ) id 1ZLTMM-0004tf-Gg; Sat, 01 Aug 2015 09:45:42 +0000 Received: (nullmailer pid 29354 invoked by uid 1000); Sat, 01 Aug 2015 09:45:01 -0000 From: David Bremner To: Mark Walters , notmuch@notmuchmail.org Subject: [PATCH 1/2] emacs: define a notmuch-compose-mode based on message mode. Date: Sat, 1 Aug 2015 11:44:55 +0200 Message-Id: <1438422296-29087-2-git-send-email-david@tethera.net> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1438422296-29087-1-git-send-email-david@tethera.net> References: <87vbdrysd7.fsf@qmul.ac.uk> <1438422296-29087-1-git-send-email-david@tethera.net> X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.18 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: Sat, 01 Aug 2015 09:47:21 -0000 This is to provide a clean way of overriding e.g. keybindings when sending mail from notmuch. --- emacs/notmuch-mua.el | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/emacs/notmuch-mua.el b/emacs/notmuch-mua.el index 33f1399..a7d3eaa 100644 --- a/emacs/notmuch-mua.el +++ b/emacs/notmuch-mua.el @@ -265,6 +265,9 @@ Note that these functions use `mail-citation-hook' if that is non-nil." (message-goto-body) (set-buffer-modified-p nil)) +(define-derived-mode notmuch-compose-mode message-mode "notmuch-compose" + "Notmuch message composition mode. Mostly like `message-mode'") + (defun notmuch-mua-mail (&optional to subject other-headers &rest other-args) "Invoke the notmuch mail composition window. @@ -281,6 +284,7 @@ OTHER-ARGS are passed through to `message-mail'." (notmuch-user-name) " <" (notmuch-user-primary-email) ">")) other-headers)) (apply #'message-mail to subject other-headers other-args) + (notmuch-compose-mode) (message-sort-headers) (message-hide-headers) (set-buffer-modified-p nil) -- 2.1.4