From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id WIWVACwfMV9TBQAA0tVLHw (envelope-from ) for ; Mon, 10 Aug 2020 10:19:24 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2 with LMTPS id +FQgOCsfMV9VJgAAB5/wlQ (envelope-from ) for ; Mon, 10 Aug 2020 10:19:23 +0000 Received: from mail.notmuchmail.org (nmbug.tethera.net [144.217.243.247]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (2048 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id B7C95940390 for ; Mon, 10 Aug 2020 10:19:22 +0000 (UTC) Received: from [144.217.243.247] (localhost [127.0.0.1]) by mail.notmuchmail.org (Postfix) with ESMTP id 9BBDE29B03; Mon, 10 Aug 2020 06:19:15 -0400 (EDT) Received: from mail-wm1-x341.google.com (mail-wm1-x341.google.com [IPv6:2a00:1450:4864:20::341]) by mail.notmuchmail.org (Postfix) with ESMTPS id 2AEA71FFA7 for ; Mon, 10 Aug 2020 06:19:13 -0400 (EDT) Received: by mail-wm1-x341.google.com with SMTP id 3so7790009wmi.1 for ; Mon, 10 Aug 2020 03:19:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=dme-org.20150623.gappssmtp.com; s=20150623; h=to:cc:subject:in-reply-to:references:from:date:message-id :mime-version; bh=DdFJ7CXSRrYPLngcUKBeK2JqDHb68SWZ4Qdlxv3WCpQ=; b=nunsXMtspFPxRu2X3QDDYxYtNutIZ2vzrNKDHSB+5DcOpMW4X9AOcAKF1On/falbRN CeId4ivMbQbDiQ9tqgoOB8LzJ54lBno9SwRXAYx9UxTEQhYTKIX3VIgUQBiO13/k7gQV nz6xdXaSuqKrmUudcpzdPPCcqrfCsK0gSdNYzrWTV8YrC3IZoIoQlUDIaP+wjTO3/voH rMeoR+URN+ZT1wdMkUz582PeVRxLgqTv2Z+13rq5RuSuyUlhnsTo52Ki5U2aykVGJTsJ FY8KakqGuvwxMFjBMab//pgqE+6ibYPS94Jhv6bveTcK1578D6QXQo1Ia/dc/8TKKuof 57BA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:to:cc:subject:in-reply-to:references:from:date :message-id:mime-version; bh=DdFJ7CXSRrYPLngcUKBeK2JqDHb68SWZ4Qdlxv3WCpQ=; b=bO0k1SNLQg0qQcGXNfL1x2nDclpmokbvwy/SjXTQXm9iGwORgoHFd3E15CP2SHK0G2 3WG3v4hYFDdxesEYTP4nOmme9C5WDo0lPc5/jYGOTTFI0Vy/Zod89dunsKj859OO8390 47UYtvl/Smj0MkVOxQiGSFO9c5xXIt94dICW5E/E0YtqOgftMDWQm3u0RDC00rqMLk9t wBeyb50RUpeQ60Qh6qxEF2vV3YPRlaEWckFC9eYWrirqYMlmAT54fuAwMBq0KsItVxKh /meiDOBtkOvnGMS8nK8QFHPLZeG2XKgaAnfZYG0hCkC4GoKT04QRQb2tPfjCRKX0bRG1 R7QQ== X-Gm-Message-State: AOAM532izwiNmz0t84eFmqw6zouWx1/u7Gt1upF5vwY+Xd9R763n33Gu RTTmBbh+Dfw/wLDO9h95iWnJBA== X-Google-Smtp-Source: ABdhPJxtO73xjthm6b/UjBHgnoNSD1zLWu9IhyVIp+tr3vpO3fvj3VOVhvaI8ZDN5q98ElmrQsateg== X-Received: by 2002:a7b:c14e:: with SMTP id z14mr25108816wmi.34.1597054752153; Mon, 10 Aug 2020 03:19:12 -0700 (PDT) Received: from disaster-area.hh.sledj.net (8.a.e.d.0.0.0.0.0.0.0.0.4.6.0.0.0.4.1.7.1.7.b.b.0.b.8.0.1.0.0.2.ip6.arpa. [2001:8b0:bb71:7140:64::dea8]) by smtp.gmail.com with ESMTPSA id 32sm23019171wrh.18.2020.08.10.03.19.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 10 Aug 2020 03:19:11 -0700 (PDT) Received: from localhost (disaster-area.hh.sledj.net [local]) by disaster-area.hh.sledj.net (OpenSMTPD) with ESMTPA id 82848933; Mon, 10 Aug 2020 10:19:10 +0000 (UTC) To: Teemu Likonen , notmuch@notmuchmail.org Cc: Teemu Likonen Subject: Re: [PATCH] Emacs: Indent first header line only when indentation is turned on In-Reply-To: <20200809190144.25459-1-tlikonen@iki.fi> References: <20200809190144.25459-1-tlikonen@iki.fi> X-HGTTG: heart-of-gold From: David Edmondson Date: Mon, 10 Aug 2020 11:19:10 +0100 Message-ID: MIME-Version: 1.0 Message-ID-Hash: KVLLE2ETEZIHXOYQSTMSHMQK6AVF7XNR X-Message-ID-Hash: KVLLE2ETEZIHXOYQSTMSHMQK6AVF7XNR X-MailFrom: dme@dme.org X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-notmuch.notmuchmail.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; suspicious-header X-Mailman-Version: 3.2.1 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Help: List-Post: List-Subscribe: List-Unsubscribe: Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Scanner: scn0 Authentication-Results: aspmx1.migadu.com; dkim=fail (body hash did not verify) header.d=dme-org.20150623.gappssmtp.com header.s=20150623 header.b=nunsXMts; dmarc=none; spf=pass (aspmx1.migadu.com: domain of notmuch-bounces@notmuchmail.org designates 144.217.243.247 as permitted sender) smtp.mailfrom=notmuch-bounces@notmuchmail.org X-Spam-Score: 0.03 X-TUID: kp2tdtOrc82E On Sunday, 2020-08-09 at 22:01:44 +03, Teemu Likonen wrote: > Previously in message-show mode message's first header line (From > header) was always indented, even if user had turned thread > indentation off with "<" (notmuch-show-toggle-thread-indentation) > command. > > This change modifies notmuch-show-insert-headerline function so that > it doesn't indent the first header line if notmuch-show-indent-content > variable is nil. > --- > emacs/notmuch-show.el | 5 ++++- > 1 file changed, 4 insertions(+), 1 deletion(-) > > diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el > index 0eb27e33..2310017a 100644 > --- a/emacs/notmuch-show.el > +++ b/emacs/notmuch-show.el > @@ -474,7 +474,10 @@ message at DEPTH in the current thread." > ;; invisible U+200E LEFT-TO-RIGHT MARK character which forces > ;; the header paragraph as left-to-right text. > (insert (propertize (string ?\x200e) 'invisible t))) > - (insert (notmuch-show-spaces-n (* notmuch-show-indent-messages-width depth)) > + (insert (notmuch-show-spaces-n > + (if notmuch-show-indent-content > + (* notmuch-show-indent-messages-width depth) > + 0)) Couldn't you also elide the call to `notmuch-show-spaces-n'? > from > " (" > date > -- > 2.20.1 > _______________________________________________ > notmuch mailing list -- notmuch@notmuchmail.org > To unsubscribe send an email to notmuch-leave@notmuchmail.org dme. -- I walk like a building, I never get wet.