Return-Path: X-Original-To: notmuch@notmuchmail.org Delivered-To: notmuch@notmuchmail.org Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id 27C5B431FD0 for ; Mon, 11 Jul 2011 01:42:17 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: -0.789 X-Spam-Level: X-Spam-Status: No, score=-0.789 tagged_above=-999 required=5 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7, T_MIME_NO_TEXT=0.01] autolearn=disabled Received: from olra.theworths.org ([127.0.0.1]) by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id zt0zKC1kGIq8 for ; Mon, 11 Jul 2011 01:42:14 -0700 (PDT) Received: from mail-ew0-f53.google.com (mail-ew0-f53.google.com [209.85.215.53]) (using TLSv1 with cipher RC4-SHA (128/128 bits)) (No client certificate requested) by olra.theworths.org (Postfix) with ESMTPS id 77E34431FB6 for ; Mon, 11 Jul 2011 01:42:14 -0700 (PDT) Received: by ewy8 with SMTP id 8so1276538ewy.26 for ; Mon, 11 Jul 2011 01:42:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=from:to:subject:user-agent:date:message-id:mime-version :content-type; bh=WmoAGfQC6xRR3R3AYoBRZrjAQS7TZN1pOGnCQ7m7IaI=; b=fpzKG1w9HiMpSSxQx2/AR7IS1ugR/eAA+APDcIKhg4rZzVMdQfxZyaFMT0mfMswHbU FpAahYkPVPUelhDx7TH7El2ZnTYkbcsjrEIafKn1x9tcCw94nlG1RVK7gQrMOV5DfPgb xv2GWOW/xFxQo8zj276i7w1zxYXp4n/8NAYks= Received: by 10.213.9.138 with SMTP id l10mr1351926ebl.84.1310373732901; Mon, 11 Jul 2011 01:42:12 -0700 (PDT) Received: from localhorst.example.com (brln-4dba66f4.pool.mediaWays.net [77.186.102.244]) by mx.google.com with ESMTPS id v36sm1018007eea.37.2011.07.11.01.42.08 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 11 Jul 2011 01:42:11 -0700 (PDT) Received: by localhorst.example.com (Postfix, from userid 501) id 719384671E2E; Mon, 11 Jul 2011 10:42:05 +0200 (CEST) From: Felix Geller To: notmuch@notmuchmail.org Subject: [PATCH] Emacs: Add variable to toggle message indentation in a thread User-Agent: Emacs/23.3.1 (x86_64-apple-darwin10.7.0) Date: Mon, 11 Jul 2011 10:42:04 +0200 Message-ID: MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha1; protocol="application/pgp-signature" X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.13 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: Mon, 11 Jul 2011 08:42:17 -0000 --=-=-= Content-Transfer-Encoding: quoted-printable Hi, I added a variable to toggle message indentation in Emacs. Please let me know what you think. Cheers, Felix diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el index a433dec..8101c27 100644 =2D-- a/emacs/notmuch-show.el +++ b/emacs/notmuch-show.el @@ -90,6 +90,11 @@ any given message." :group 'notmuch :type 'boolean) =20 +(defcustom notmuch-show-indent-messages-in-thread nil + "Should the messages in a thread be indented according to their respecti= ve depth in the thread?" + :group 'notmuch + :type 'boolean) + (defcustom notmuch-show-indent-multipart nil "Should the sub-parts of a multipart/* part be indented?" ;; dme: Not sure which is a good default. @@ -237,7 +242,9 @@ unchanged ADDRESS if parsing fails." "Insert a notmuch style headerline based on HEADERS for a message at DEPTH in the current thread." (let ((start (point))) =2D (insert (notmuch-show-spaces-n depth) + (insert (if notmuch-show-indent-messages-in-thread + (notmuch-show-spaces-n depth) + "") (notmuch-show-clean-address (plist-get headers :From)) " (" date @@ -733,7 +740,8 @@ current buffer, if possible." (setq content-end (point-marker)) =20 ;; Indent according to the depth in the thread. =2D (indent-rigidly content-start content-end depth) + (when notmuch-show-indent-messages-in-thread + (indent-rigidly content-start content-end depth)) =20 (setq message-end (point-max-marker)) =20 --=-=-= Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG/MacGPG2 v2.0.17 (Darwin) iEYEARECAAYFAk4at10ACgkQMxgKfMb9y5aizgCfeYS3jf1guibTT3UR1CfhXkGg fRQAoJYUbqmYSkzKCWB0ruelzsmbogf1 =H3S1 -----END PGP SIGNATURE----- --=-=-=--