Re: [PATCH v2 3/3] emacs: Process format=flowed text
David Bremner writes: The latter, I think. Thanks for pinging. It looks like that last discussion was my comment about breaking the API. Any feedback on that, either of you? I don't see why making the argument optional wouldn't work. However, I tried applying the patch and am not seeing a change in the display of format=flowed messages. It doesn't reflow to my window width (regardless of whether it is wider or narrower than the soft line breaks in the format=flowed message). (I noticed this patch when considering use of a proportional font for mail reading.) ___ notmuch mailing list notmuch@notmuchmail.org https://notmuchmail.org/mailman/listinfo/notmuch
Re: [PATCH v2 3/3] emacs: Process format=flowed text
Jed Brown writes: > Was this proposal dropped or did it just get lost? > The latter, I think. Thanks for pinging. It looks like that last discussion was my comment about breaking the API. Any feedback on that, either of you? d ___ notmuch mailing list notmuch@notmuchmail.org https://notmuchmail.org/mailman/listinfo/notmuch
Re: [PATCH v2 3/3] emacs: Process format=flowed text
Was this proposal dropped or did it just get lost? David Edmondson writes: > If a text/plain part is declared as format=flowed, apply the > appropriate transformation for display using flow-fill.el. > --- > emacs/notmuch-show.el | 3 ++- > emacs/notmuch-wash.el | 14 ++ > 2 files changed, 16 insertions(+), 1 deletion(-) > > diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el > index b3cefcd9..823a2d19 100644 > --- a/emacs/notmuch-show.el > +++ b/emacs/notmuch-show.el > @@ -90,7 +90,8 @@ visible for any given message." >:group 'notmuch-show >:group 'notmuch-hooks) > > -(defcustom notmuch-show-insert-text/plain-hook '(notmuch-wash-wrap-long-lines > +(defcustom notmuch-show-insert-text/plain-hook '(notmuch-wash-format=flowed > + notmuch-wash-wrap-long-lines >notmuch-wash-tidy-citations >notmuch-wash-elide-blank-lines >notmuch-wash-excerpt-citations) > diff --git a/emacs/notmuch-wash.el b/emacs/notmuch-wash.el > index 54275ec7..d4f0e883 100644 > --- a/emacs/notmuch-wash.el > +++ b/emacs/notmuch-wash.el > @@ -426,6 +426,20 @@ for error." > > ;; > > +(require 'flow-fill) > + > +(defun notmuch-wash-format=flowed (msg part depth) > + "If the current part content-type included 'format=flowed', > +apply the appropriate transformation." > + (when (string= (plist-get part :format) "flowed") > +;; Adjust `fill-flowed-display-column' to allow for the indent > +;; that we will later apply to this content. > +(let ((fill-flowed-display-column (- (eval fill-flowed-display-column) > + (* depth > notmuch-show-indent-messages-width > + (fill-flowed > + > +;; > + > (provide 'notmuch-wash) > > ;;; notmuch-wash.el ends here > -- > 2.11.0 > > ___ > notmuch mailing list > notmuch@notmuchmail.org > https://notmuchmail.org/mailman/listinfo/notmuch ___ notmuch mailing list notmuch@notmuchmail.org https://notmuchmail.org/mailman/listinfo/notmuch
[PATCH v2 3/3] emacs: Process format=flowed text
If a text/plain part is declared as format=flowed, apply the appropriate transformation for display using flow-fill.el. --- emacs/notmuch-show.el | 3 ++- emacs/notmuch-wash.el | 14 ++ 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el index b3cefcd9..823a2d19 100644 --- a/emacs/notmuch-show.el +++ b/emacs/notmuch-show.el @@ -90,7 +90,8 @@ visible for any given message." :group 'notmuch-show :group 'notmuch-hooks) -(defcustom notmuch-show-insert-text/plain-hook '(notmuch-wash-wrap-long-lines +(defcustom notmuch-show-insert-text/plain-hook '(notmuch-wash-format=flowed +notmuch-wash-wrap-long-lines notmuch-wash-tidy-citations notmuch-wash-elide-blank-lines notmuch-wash-excerpt-citations) diff --git a/emacs/notmuch-wash.el b/emacs/notmuch-wash.el index 54275ec7..d4f0e883 100644 --- a/emacs/notmuch-wash.el +++ b/emacs/notmuch-wash.el @@ -426,6 +426,20 @@ for error." ;; +(require 'flow-fill) + +(defun notmuch-wash-format=flowed (msg part depth) + "If the current part content-type included 'format=flowed', +apply the appropriate transformation." + (when (string= (plist-get part :format) "flowed") +;; Adjust `fill-flowed-display-column' to allow for the indent +;; that we will later apply to this content. +(let ((fill-flowed-display-column (- (eval fill-flowed-display-column) +(* depth notmuch-show-indent-messages-width + (fill-flowed + +;; + (provide 'notmuch-wash) ;;; notmuch-wash.el ends here -- 2.11.0 ___ notmuch mailing list notmuch@notmuchmail.org https://notmuchmail.org/mailman/listinfo/notmuch