* mu4e: support the :size field in headers, message view

This commit is contained in:
djcb 2012-09-15 18:24:03 +03:00
parent 0844984095
commit 5a9b867ca8
3 changed files with 9 additions and 5 deletions

View File

@ -462,7 +462,12 @@ headers)."
( :name "Signature"
:shortname "Sgn"
:help "Check for the cryptographic signature"
:sortable nil))
:sortable nil))
(:size .
( :name "Size"
:shortname "Size"
:help "Size of the message"
:sortable t))
(:subject .
( :name "Subject"
:shortname "Subject"

View File

@ -182,9 +182,7 @@ plist."
(if datestr (mu4e~view-construct-header field datestr) "")))
;; size
(:size
(let* (size (mu4e-view-size msg)
(sizestr (when size (format "%d bytes" size))))
(if sizestr (mu4e~view-construct-header field sizestr))))
(mu4e~view-construct-header field (mu4e-display-size fieldval)))
;; attachments
(:attachments (mu4e~view-construct-attachments-header msg))
;; pgp-signatures

View File

@ -533,7 +533,8 @@ Some notes to explain what you see in the example:
@itemize
@item The fields shown in the headers view can be influenced by customizing
the variable @code{mu4e-headers-fields}.
the variable @var{mu4e-headers-fields}; see @var{mu4e-header-info} for the
list of available fields.
@item Instead of showing the @t{From:} and @t{To:} fields separately, you
can use From/To (@t{:from-or-to} in @code{mu4e-headers-fields} as a more
compact way to convey the most important information: it shows @t{From:}