]> git.notmuchmail.org Git - notmuch/blobdiff - notmuch.el
notmuch.el: Fix to claim correct number of lines for hidden signature.
[notmuch] / notmuch.el
index de995ecaa014294ddf0f1cd0caeac6cfc6708c2d..0599af5f0139b76846efa60b27eedabdfc0a269c 100644 (file)
@@ -307,7 +307,7 @@ which this thread was originally shown."
          (let ((overlay (make-overlay beg-sub end)))
            (overlay-put overlay 'invisible 'notmuch-show-signature)
            (overlay-put overlay 'before-string
-                        (concat "[" (number-to-string (count-lines beg-sub (point)))
+                        (concat "[" (number-to-string (count-lines beg-sub end))
                                 "-line signature.]"))
            (goto-char end)))
       (next-line))))
@@ -470,9 +470,12 @@ thread from that buffer can be show when done with this one)."
          (progn
            (notmuch-show-next-unread-message)
            ; But if there are no unread messages, go back to the
-           ; beginning of the buffer.
+           ; beginning of the buffer, and open up the bodies of all
+           ; read message.
            (if (not (notmuch-show-message-unread-p))
-               (goto-char (point-min)))))
+               (progn
+                 (goto-char (point-min))
+                 (notmuch-show-toggle-body-read-visible)))))
       )))
 
 (defvar notmuch-search-mode-map