unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
* [PATCH] emacs: Don't eat last newline character of citations
@ 2009-12-13 16:06 Kan-Ru Chen
  2009-12-13 22:57 ` Carl Worth
  0 siblings, 1 reply; 2+ messages in thread
From: Kan-Ru Chen @ 2009-12-13 16:06 UTC (permalink / raw)
  To: notmuch

In case of a citation following immediately new contents. When the citation
was collapsed:

    [1-line citation. Click/Enter to show.]
Lorem ipsum dolor sit amet, consectetur adipisicin

When it was expanded:

    [10-line citation. Click/Enter to show.]
    >
    Lorem ipsum dolor sit amet, consectetur adipisicin

The indentation was wrong.

Signed-off-by: Kan-Ru Chen <kanru@kanru.info>
---
 notmuch.el |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/notmuch.el b/notmuch.el
index 97914f2..aa6bc60 100644
--- a/notmuch.el
+++ b/notmuch.el
@@ -606,6 +606,7 @@ which this thread was originally shown."
 	    (while (looking-at citation)
 	      (forward-line)
 	      (move-to-column depth))
+	    (end-of-line 0)
 	    (let ((overlay (make-overlay beg-sub (point)))
                   (invis-spec (make-symbol "notmuch-citation-region")))
               (add-to-invisibility-spec invis-spec)
-- 
1.6.5.5

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] emacs: Don't eat last newline character of citations
  2009-12-13 16:06 [PATCH] emacs: Don't eat last newline character of citations Kan-Ru Chen
@ 2009-12-13 22:57 ` Carl Worth
  0 siblings, 0 replies; 2+ messages in thread
From: Carl Worth @ 2009-12-13 22:57 UTC (permalink / raw)
  To: Kan-Ru Chen, notmuch

[-- Attachment #1: Type: text/plain, Size: 711 bytes --]

On Mon, 14 Dec 2009 00:06:53 +0800, Kan-Ru Chen <kanru@kanru.info> wrote:
> In case of a citation following immediately new contents. When the citation
> was collapsed:
> 
>     [1-line citation. Click/Enter to show.]
> Lorem ipsum dolor sit amet, consectetur adipisicin

That's definitely a bug we want to fix, yes.

But the patch also makes many cases display with two lines between the
citation button and the subsequent, non-citation content (where the
original message has just one).

That extra blank line has been annoying me, and it was probably my
effort to get rid of it that introduced the bug above.

If we could get rid of both bugs at the same time, that would be ideal.

-Carl

[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-12-13 22:57 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-12-13 16:06 [PATCH] emacs: Don't eat last newline character of citations Kan-Ru Chen
2009-12-13 22:57 ` Carl Worth

Code repositories for project(s) associated with this public inbox

	https://yhetil.org/notmuch.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).