[PATCH v2] emacs: Add more processing of displayed headers.

2012-10-12 Thread Ethan Glasser-Camp
Hi! Just going through the patch queue.

This is definitely a nice effect, but I'm not sure of the approach. It
doesn't indent the message's tags, and it doesn't work when you resize the
window. (You can get some very ugly wrapping if you put your mind to
it.)

Is there no better way to do this using visual-line-mode? I know that
the rest of notmuch uses hard filling, but that's no reason to make a
bad situation worse. It looks like you can put wrap-prefix text
properties all over, as done in the adaptive-wrap package:

http://elpa.gnu.org/packages/adaptive-wrap-0.1.el

Slightly more nit-picky comments below.

David Edmondson  writes:

> -(defvar notmuch-show-markup-headers-hook '(notmuch-show-colour-headers)
> +(defcustom notmuch-show-markup-headers-hook '(notmuch-show-colour-headers
> +   notmuch-show-fill-headers
> +   notmuch-show-indent-continuations)
>"A list of functions called to decorate the headers listed in
> -`notmuch-message-headers'.")
> +`notmuch-message-headers'."
> +  :type 'hook
> +  :options '(notmuch-show-colour-headers
> +  notmuch-show-fill-headers
> +  notmuch-show-indent-continuations)
> +  :group 'notmuch-show)

This hook is not normal because it takes an argument, and so should have
a name ending in -hooks or -functions. Also, since it's a defcustom now,
it should probably have a better explanation of how it works, that it
takes an argument, and what that argument means.

It seems extremely dicey to me that you can put
notmuch-show-indent-continuations in this list before, or without,
notmuch-show-fill-headers.

> +(defun notmuch-show-fill-headers (depth)
> +  "Wrap the text of the current headers."
> +
> +  ;; '-5' to allow for the indentation code.
> +  (let ((fill-column (- (window-width) depth 5)))

It took me a little while to figure out what this meant. How about,
"underfill by 5 so that inserting indentation doesn't cause more
wrapping"? Is it possible to be smart enough to let

> +(defun notmuch-show-indent-continuations (depth)
> +  "Indent any continuation lines."
> +  (goto-char (point-min))
> +  (while (not (eobp))
> +(if (not (looking-at "^[A-Za-z][-A-Za-z0-9]*:"))
> + ;; Four spaces tends to work well with 'To' and 'Cc' headers.
> + (insert ""))
> +(forward-line)))

I'm not crazy about this but I'm not sure I can say why exactly. Why
can't we just run indent-rigidly over the whole thing?

The comment isn't terribly useful. Only those headers? "Tends to work
well"?

>  ;; Override `notmuch-message-headers' to force `From' to be
>  ;; displayed.
>  (let ((notmuch-message-headers '("From" "Subject" "To" "Cc" "Date")))
> -  (notmuch-show-insert-headers (plist-get message :headers)))
> +  (notmuch-show-insert-headers (plist-get message :headers) 0))

This took me a long while to figure out, especially because it looks
like the depth is being passed normally to notmuch-show-insert-bodypart,
just below. A comment like "depth = 0 because we reindent below" would
have been really helpful. A good test message is
id:"87ocabvp0y.fsf at wsheee.2x.cz".

Ethan


Re: [PATCH v2] emacs: Add more processing of displayed headers.

2012-10-12 Thread Ethan Glasser-Camp
Hi! Just going through the patch queue.

This is definitely a nice effect, but I'm not sure of the approach. It
doesn't indent the message's tags, and it doesn't work when you resize the
window. (You can get some very ugly wrapping if you put your mind to
it.)

Is there no better way to do this using visual-line-mode? I know that
the rest of notmuch uses hard filling, but that's no reason to make a
bad situation worse. It looks like you can put wrap-prefix text
properties all over, as done in the adaptive-wrap package:

http://elpa.gnu.org/packages/adaptive-wrap-0.1.el

Slightly more nit-picky comments below.

David Edmondson  writes:

> -(defvar notmuch-show-markup-headers-hook '(notmuch-show-colour-headers)
> +(defcustom notmuch-show-markup-headers-hook '(notmuch-show-colour-headers
> +   notmuch-show-fill-headers
> +   notmuch-show-indent-continuations)
>"A list of functions called to decorate the headers listed in
> -`notmuch-message-headers'.")
> +`notmuch-message-headers'."
> +  :type 'hook
> +  :options '(notmuch-show-colour-headers
> +  notmuch-show-fill-headers
> +  notmuch-show-indent-continuations)
> +  :group 'notmuch-show)

This hook is not normal because it takes an argument, and so should have
a name ending in -hooks or -functions. Also, since it's a defcustom now,
it should probably have a better explanation of how it works, that it
takes an argument, and what that argument means.

It seems extremely dicey to me that you can put
notmuch-show-indent-continuations in this list before, or without,
notmuch-show-fill-headers.

> +(defun notmuch-show-fill-headers (depth)
> +  "Wrap the text of the current headers."
> +
> +  ;; '-5' to allow for the indentation code.
> +  (let ((fill-column (- (window-width) depth 5)))

It took me a little while to figure out what this meant. How about,
"underfill by 5 so that inserting indentation doesn't cause more
wrapping"? Is it possible to be smart enough to let

> +(defun notmuch-show-indent-continuations (depth)
> +  "Indent any continuation lines."
> +  (goto-char (point-min))
> +  (while (not (eobp))
> +(if (not (looking-at "^[A-Za-z][-A-Za-z0-9]*:"))
> + ;; Four spaces tends to work well with 'To' and 'Cc' headers.
> + (insert ""))
> +(forward-line)))

I'm not crazy about this but I'm not sure I can say why exactly. Why
can't we just run indent-rigidly over the whole thing?

The comment isn't terribly useful. Only those headers? "Tends to work
well"?

>  ;; Override `notmuch-message-headers' to force `From' to be
>  ;; displayed.
>  (let ((notmuch-message-headers '("From" "Subject" "To" "Cc" "Date")))
> -  (notmuch-show-insert-headers (plist-get message :headers)))
> +  (notmuch-show-insert-headers (plist-get message :headers) 0))

This took me a long while to figure out, especially because it looks
like the depth is being passed normally to notmuch-show-insert-bodypart,
just below. A comment like "depth = 0 because we reindent below" would
have been really helpful. A good test message is
id:"87ocabvp0y@wsheee.2x.cz".

Ethan
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


[PATCH v2] emacs: Add more processing of displayed headers.

2012-02-14 Thread David Edmondson
* david at tethera.net [2012-02-14 Tue 12:30]
> On Mon,  6 Feb 2012 15:39:05 +, David Edmondson  wrote:
>> Wrap headers to the width of the window and indent continuations.
>
> Hi David;
>
> Not sure what this patch is doing in the middle of this thread?
> Is it meant to be part of this series?

No, it's not related to those others. Mistaken 'In-Reply-To'.
-- next part --
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: 



[PATCH v2] emacs: Add more processing of displayed headers.

2012-02-14 Thread David Bremner
On Mon,  6 Feb 2012 15:39:05 +, David Edmondson  wrote:
> Wrap headers to the width of the window and indent continuations.

Hi David;

Not sure what this patch is doing in the middle of this thread?
Is it meant to be part of this series?

d


Re: [PATCH v2] emacs: Add more processing of displayed headers.

2012-02-14 Thread David Edmondson
* da...@tethera.net [2012-02-14 Tue 12:30]
> On Mon,  6 Feb 2012 15:39:05 +, David Edmondson  wrote:
>> Wrap headers to the width of the window and indent continuations.
>
> Hi David;
>
> Not sure what this patch is doing in the middle of this thread?
> Is it meant to be part of this series?

No, it's not related to those others. Mistaken 'In-Reply-To'.


pgpOYyw50vPUv.pgp
Description: PGP signature
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


Re: [PATCH v2] emacs: Add more processing of displayed headers.

2012-02-14 Thread David Bremner
On Mon,  6 Feb 2012 15:39:05 +, David Edmondson  wrote:
> Wrap headers to the width of the window and indent continuations.

Hi David;

Not sure what this patch is doing in the middle of this thread?
Is it meant to be part of this series?

d
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


[PATCH v2] emacs: Add more processing of displayed headers.

2012-02-06 Thread David Edmondson
Wrap headers to the width of the window and indent continuations.
---
 emacs/notmuch-show.el |   43 ---
 1 files changed, 36 insertions(+), 7 deletions(-)

diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el
index 7469e2e..a589d37 100644
--- a/emacs/notmuch-show.el
+++ b/emacs/notmuch-show.el
@@ -68,9 +68,16 @@ any given message."
   :type 'boolean
   :group 'notmuch-show)

-(defvar notmuch-show-markup-headers-hook '(notmuch-show-colour-headers)
+(defcustom notmuch-show-markup-headers-hook '(notmuch-show-colour-headers
+ notmuch-show-fill-headers
+ notmuch-show-indent-continuations)
   "A list of functions called to decorate the headers listed in
-`notmuch-message-headers'.")
+`notmuch-message-headers'."
+  :type 'hook
+  :options '(notmuch-show-colour-headers
+notmuch-show-fill-headers
+notmuch-show-indent-continuations)
+  :group 'notmuch-show)

 (defcustom notmuch-show-hook '(notmuch-show-turn-on-visual-line-mode)
   "Functions called after populating a `notmuch-show' buffer."
@@ -269,13 +276,35 @@ operation on the contents of the current buffer."
 (overlay-put (make-overlay (point) (re-search-forward ".*$"))
 'face face)))

-(defun notmuch-show-colour-headers ()
+(defun notmuch-show-colour-headers (depth)
   "Apply some colouring to the current headers."
   (goto-char (point-min))
   (while (looking-at "^[A-Za-z][-A-Za-z0-9]*:")
 (notmuch-show-fontify-header)
 (forward-line)))

+(defun notmuch-show-fill-headers (depth)
+  "Wrap the text of the current headers."
+
+  ;; '-5' to allow for the indentation code.
+  (let ((fill-column (- (window-width) depth 5)))
+(goto-char (point-min))
+(while (not (eobp))
+  (let ((start (point)))
+   (end-of-line)
+   ;; We're left at the start of the next line, so there's no need
+   ;; to move forward after filling.
+   (fill-region-as-paragraph start (point))
+
+(defun notmuch-show-indent-continuations (depth)
+  "Indent any continuation lines."
+  (goto-char (point-min))
+  (while (not (eobp))
+(if (not (looking-at "^[A-Za-z][-A-Za-z0-9]*:"))
+   ;; Four spaces tends to work well with 'To' and 'Cc' headers.
+   (insert ""))
+(forward-line)))
+
 (defun notmuch-show-spaces-n (n)
   "Return a string comprised of `n' spaces."
   (make-string n ? ))
@@ -366,7 +395,7 @@ message at DEPTH in the current thread."
   "Insert a single header."
   (insert header ": " header-value "\n"))

-(defun notmuch-show-insert-headers (headers)
+(defun notmuch-show-insert-headers (headers depth)
   "Insert the headers of the current message."
   (let ((start (point)))
 (mapc (lambda (header)
@@ -379,7 +408,7 @@ message at DEPTH in the current thread."
 (save-excursion
   (save-restriction
(narrow-to-region start (point-max))
-   (run-hooks 'notmuch-show-markup-headers-hook)
+   (run-hook-with-args 'notmuch-show-markup-headers-hook depth)

 (define-button-type 'notmuch-show-part-button-type
   'action 'notmuch-show-part-button-default
@@ -671,7 +700,7 @@ current buffer, if possible."
 ;; Override `notmuch-message-headers' to force `From' to be
 ;; displayed.
 (let ((notmuch-message-headers '("From" "Subject" "To" "Cc" "Date")))
-  (notmuch-show-insert-headers (plist-get message :headers)))
+  (notmuch-show-insert-headers (plist-get message :headers) 0))

 ;; Blank line after headers to be compatible with the normal
 ;; message display.
@@ -864,7 +893,7 @@ current buffer, if possible."
 ;; Set `headers-start' to point after the 'Subject:' header to be
 ;; compatible with the existing implementation. This just sets it
 ;; to after the first header.
-(notmuch-show-insert-headers headers)
+(notmuch-show-insert-headers headers depth)
 (save-excursion
   (goto-char content-start)
   ;; If the subject of this message is the same as that of the
-- 
1.7.8.3



[PATCH v2] emacs: Add more processing of displayed headers.

2012-02-06 Thread David Edmondson
Wrap headers to the width of the window and indent continuations.
---
 emacs/notmuch-show.el |   43 ---
 1 files changed, 36 insertions(+), 7 deletions(-)

diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el
index 7469e2e..a589d37 100644
--- a/emacs/notmuch-show.el
+++ b/emacs/notmuch-show.el
@@ -68,9 +68,16 @@ any given message."
   :type 'boolean
   :group 'notmuch-show)

-(defvar notmuch-show-markup-headers-hook '(notmuch-show-colour-headers)
+(defcustom notmuch-show-markup-headers-hook '(notmuch-show-colour-headers
+ notmuch-show-fill-headers
+ notmuch-show-indent-continuations)
   "A list of functions called to decorate the headers listed in
-`notmuch-message-headers'.")
+`notmuch-message-headers'."
+  :type 'hook
+  :options '(notmuch-show-colour-headers
+notmuch-show-fill-headers
+notmuch-show-indent-continuations)
+  :group 'notmuch-show)

 (defcustom notmuch-show-hook '(notmuch-show-turn-on-visual-line-mode)
   "Functions called after populating a `notmuch-show' buffer."
@@ -269,13 +276,35 @@ operation on the contents of the current buffer."
 (overlay-put (make-overlay (point) (re-search-forward ".*$"))
 'face face)))

-(defun notmuch-show-colour-headers ()
+(defun notmuch-show-colour-headers (depth)
   "Apply some colouring to the current headers."
   (goto-char (point-min))
   (while (looking-at "^[A-Za-z][-A-Za-z0-9]*:")
 (notmuch-show-fontify-header)
 (forward-line)))

+(defun notmuch-show-fill-headers (depth)
+  "Wrap the text of the current headers."
+
+  ;; '-5' to allow for the indentation code.
+  (let ((fill-column (- (window-width) depth 5)))
+(goto-char (point-min))
+(while (not (eobp))
+  (let ((start (point)))
+   (end-of-line)
+   ;; We're left at the start of the next line, so there's no need
+   ;; to move forward after filling.
+   (fill-region-as-paragraph start (point))
+
+(defun notmuch-show-indent-continuations (depth)
+  "Indent any continuation lines."
+  (goto-char (point-min))
+  (while (not (eobp))
+(if (not (looking-at "^[A-Za-z][-A-Za-z0-9]*:"))
+   ;; Four spaces tends to work well with 'To' and 'Cc' headers.
+   (insert ""))
+(forward-line)))
+
 (defun notmuch-show-spaces-n (n)
   "Return a string comprised of `n' spaces."
   (make-string n ? ))
@@ -366,7 +395,7 @@ message at DEPTH in the current thread."
   "Insert a single header."
   (insert header ": " header-value "\n"))

-(defun notmuch-show-insert-headers (headers)
+(defun notmuch-show-insert-headers (headers depth)
   "Insert the headers of the current message."
   (let ((start (point)))
 (mapc (lambda (header)
@@ -379,7 +408,7 @@ message at DEPTH in the current thread."
 (save-excursion
   (save-restriction
(narrow-to-region start (point-max))
-   (run-hooks 'notmuch-show-markup-headers-hook)
+   (run-hook-with-args 'notmuch-show-markup-headers-hook depth)

 (define-button-type 'notmuch-show-part-button-type
   'action 'notmuch-show-part-button-default
@@ -671,7 +700,7 @@ current buffer, if possible."
 ;; Override `notmuch-message-headers' to force `From' to be
 ;; displayed.
 (let ((notmuch-message-headers '("From" "Subject" "To" "Cc" "Date")))
-  (notmuch-show-insert-headers (plist-get message :headers)))
+  (notmuch-show-insert-headers (plist-get message :headers) 0))

 ;; Blank line after headers to be compatible with the normal
 ;; message display.
@@ -864,7 +893,7 @@ current buffer, if possible."
 ;; Set `headers-start' to point after the 'Subject:' header to be
 ;; compatible with the existing implementation. This just sets it
 ;; to after the first header.
-(notmuch-show-insert-headers headers)
+(notmuch-show-insert-headers headers depth)
 (save-excursion
   (goto-char content-start)
   ;; If the subject of this message is the same as that of the
-- 
1.7.8.3



[PATCH v2] emacs: Add more processing of displayed headers.

2012-02-06 Thread David Edmondson
Wrap headers to the width of the window and indent continuations.
---
 emacs/notmuch-show.el |   43 ---
 1 files changed, 36 insertions(+), 7 deletions(-)

diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el
index 7469e2e..a589d37 100644
--- a/emacs/notmuch-show.el
+++ b/emacs/notmuch-show.el
@@ -68,9 +68,16 @@ any given message."
   :type 'boolean
   :group 'notmuch-show)
 
-(defvar notmuch-show-markup-headers-hook '(notmuch-show-colour-headers)
+(defcustom notmuch-show-markup-headers-hook '(notmuch-show-colour-headers
+ notmuch-show-fill-headers
+ notmuch-show-indent-continuations)
   "A list of functions called to decorate the headers listed in
-`notmuch-message-headers'.")
+`notmuch-message-headers'."
+  :type 'hook
+  :options '(notmuch-show-colour-headers
+notmuch-show-fill-headers
+notmuch-show-indent-continuations)
+  :group 'notmuch-show)
 
 (defcustom notmuch-show-hook '(notmuch-show-turn-on-visual-line-mode)
   "Functions called after populating a `notmuch-show' buffer."
@@ -269,13 +276,35 @@ operation on the contents of the current buffer."
 (overlay-put (make-overlay (point) (re-search-forward ".*$"))
 'face face)))
 
-(defun notmuch-show-colour-headers ()
+(defun notmuch-show-colour-headers (depth)
   "Apply some colouring to the current headers."
   (goto-char (point-min))
   (while (looking-at "^[A-Za-z][-A-Za-z0-9]*:")
 (notmuch-show-fontify-header)
 (forward-line)))
 
+(defun notmuch-show-fill-headers (depth)
+  "Wrap the text of the current headers."
+
+  ;; '-5' to allow for the indentation code.
+  (let ((fill-column (- (window-width) depth 5)))
+(goto-char (point-min))
+(while (not (eobp))
+  (let ((start (point)))
+   (end-of-line)
+   ;; We're left at the start of the next line, so there's no need
+   ;; to move forward after filling.
+   (fill-region-as-paragraph start (point))
+
+(defun notmuch-show-indent-continuations (depth)
+  "Indent any continuation lines."
+  (goto-char (point-min))
+  (while (not (eobp))
+(if (not (looking-at "^[A-Za-z][-A-Za-z0-9]*:"))
+   ;; Four spaces tends to work well with 'To' and 'Cc' headers.
+   (insert ""))
+(forward-line)))
+
 (defun notmuch-show-spaces-n (n)
   "Return a string comprised of `n' spaces."
   (make-string n ? ))
@@ -366,7 +395,7 @@ message at DEPTH in the current thread."
   "Insert a single header."
   (insert header ": " header-value "\n"))
 
-(defun notmuch-show-insert-headers (headers)
+(defun notmuch-show-insert-headers (headers depth)
   "Insert the headers of the current message."
   (let ((start (point)))
 (mapc (lambda (header)
@@ -379,7 +408,7 @@ message at DEPTH in the current thread."
 (save-excursion
   (save-restriction
(narrow-to-region start (point-max))
-   (run-hooks 'notmuch-show-markup-headers-hook)
+   (run-hook-with-args 'notmuch-show-markup-headers-hook depth)
 
 (define-button-type 'notmuch-show-part-button-type
   'action 'notmuch-show-part-button-default
@@ -671,7 +700,7 @@ current buffer, if possible."
 ;; Override `notmuch-message-headers' to force `From' to be
 ;; displayed.
 (let ((notmuch-message-headers '("From" "Subject" "To" "Cc" "Date")))
-  (notmuch-show-insert-headers (plist-get message :headers)))
+  (notmuch-show-insert-headers (plist-get message :headers) 0))
 
 ;; Blank line after headers to be compatible with the normal
 ;; message display.
@@ -864,7 +893,7 @@ current buffer, if possible."
 ;; Set `headers-start' to point after the 'Subject:' header to be
 ;; compatible with the existing implementation. This just sets it
 ;; to after the first header.
-(notmuch-show-insert-headers headers)
+(notmuch-show-insert-headers headers depth)
 (save-excursion
   (goto-char content-start)
   ;; If the subject of this message is the same as that of the
-- 
1.7.8.3

___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


[PATCH v2] emacs: Add more processing of displayed headers.

2012-02-06 Thread David Edmondson
Wrap headers to the width of the window and indent continuations.
---
 emacs/notmuch-show.el |   43 ---
 1 files changed, 36 insertions(+), 7 deletions(-)

diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el
index 7469e2e..a589d37 100644
--- a/emacs/notmuch-show.el
+++ b/emacs/notmuch-show.el
@@ -68,9 +68,16 @@ any given message."
   :type 'boolean
   :group 'notmuch-show)
 
-(defvar notmuch-show-markup-headers-hook '(notmuch-show-colour-headers)
+(defcustom notmuch-show-markup-headers-hook '(notmuch-show-colour-headers
+ notmuch-show-fill-headers
+ notmuch-show-indent-continuations)
   "A list of functions called to decorate the headers listed in
-`notmuch-message-headers'.")
+`notmuch-message-headers'."
+  :type 'hook
+  :options '(notmuch-show-colour-headers
+notmuch-show-fill-headers
+notmuch-show-indent-continuations)
+  :group 'notmuch-show)
 
 (defcustom notmuch-show-hook '(notmuch-show-turn-on-visual-line-mode)
   "Functions called after populating a `notmuch-show' buffer."
@@ -269,13 +276,35 @@ operation on the contents of the current buffer."
 (overlay-put (make-overlay (point) (re-search-forward ".*$"))
 'face face)))
 
-(defun notmuch-show-colour-headers ()
+(defun notmuch-show-colour-headers (depth)
   "Apply some colouring to the current headers."
   (goto-char (point-min))
   (while (looking-at "^[A-Za-z][-A-Za-z0-9]*:")
 (notmuch-show-fontify-header)
 (forward-line)))
 
+(defun notmuch-show-fill-headers (depth)
+  "Wrap the text of the current headers."
+
+  ;; '-5' to allow for the indentation code.
+  (let ((fill-column (- (window-width) depth 5)))
+(goto-char (point-min))
+(while (not (eobp))
+  (let ((start (point)))
+   (end-of-line)
+   ;; We're left at the start of the next line, so there's no need
+   ;; to move forward after filling.
+   (fill-region-as-paragraph start (point))
+
+(defun notmuch-show-indent-continuations (depth)
+  "Indent any continuation lines."
+  (goto-char (point-min))
+  (while (not (eobp))
+(if (not (looking-at "^[A-Za-z][-A-Za-z0-9]*:"))
+   ;; Four spaces tends to work well with 'To' and 'Cc' headers.
+   (insert ""))
+(forward-line)))
+
 (defun notmuch-show-spaces-n (n)
   "Return a string comprised of `n' spaces."
   (make-string n ? ))
@@ -366,7 +395,7 @@ message at DEPTH in the current thread."
   "Insert a single header."
   (insert header ": " header-value "\n"))
 
-(defun notmuch-show-insert-headers (headers)
+(defun notmuch-show-insert-headers (headers depth)
   "Insert the headers of the current message."
   (let ((start (point)))
 (mapc (lambda (header)
@@ -379,7 +408,7 @@ message at DEPTH in the current thread."
 (save-excursion
   (save-restriction
(narrow-to-region start (point-max))
-   (run-hooks 'notmuch-show-markup-headers-hook)
+   (run-hook-with-args 'notmuch-show-markup-headers-hook depth)
 
 (define-button-type 'notmuch-show-part-button-type
   'action 'notmuch-show-part-button-default
@@ -671,7 +700,7 @@ current buffer, if possible."
 ;; Override `notmuch-message-headers' to force `From' to be
 ;; displayed.
 (let ((notmuch-message-headers '("From" "Subject" "To" "Cc" "Date")))
-  (notmuch-show-insert-headers (plist-get message :headers)))
+  (notmuch-show-insert-headers (plist-get message :headers) 0))
 
 ;; Blank line after headers to be compatible with the normal
 ;; message display.
@@ -864,7 +893,7 @@ current buffer, if possible."
 ;; Set `headers-start' to point after the 'Subject:' header to be
 ;; compatible with the existing implementation. This just sets it
 ;; to after the first header.
-(notmuch-show-insert-headers headers)
+(notmuch-show-insert-headers headers depth)
 (save-excursion
   (goto-char content-start)
   ;; If the subject of this message is the same as that of the
-- 
1.7.8.3

___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch