Rocco Rutte:
authorpdmef <pdmef@e385b8ad-14ed-0310-8656-cc95a2468c6d>
Sun, 7 Aug 2005 18:10:59 +0000 (18:10 +0000)
committerpdmef <pdmef@e385b8ad-14ed-0310-8656-cc95a2468c6d>
Sun, 7 Aug 2005 18:10:59 +0000 (18:10 +0000)
- revert latest sidebar update to show non-deleted messages instead of total
- add/rename some $sidebar_number_format expandos to get same behavior as for $status_format (see manual and UPGRADING) (old %c and %f still kept)

git-svn-id: svn://svn.berlios.de/mutt-ng/trunk@377 e385b8ad-14ed-0310-8656-cc95a2468c6d

UPGRADING
doc/manual.txt
init.h
sidebar.c

index a88c5b3..a3f0c35 100644 (file)
--- a/UPGRADING
+++ b/UPGRADING
@@ -10,6 +10,12 @@ This document is not the place for verbose documentation; it only offers
 the necessary keywords to look them up in the manual, ChangeLog or other
 sources of information.
 
+2005-08-07:
+
+  For $sidebar_number_format, the expandos %c and %f are replaced with
+  their $status_format pendants %m and %F respectively. Use of %c and
+  %f is deprecated but still kept for compatibility.
+
 2005-08-06:
 
   Due to merging in changes made to mutt where NSS support was dropped,
index 47b941a..6c4d120 100644 (file)
@@ -4,7 +4,7 @@
                       by Andreas Krennmair <ak@synflood.at> and others
                 originally based on _\bm_\bu_\bt_\bt by Michael Elkins <me@cs.hmc.edu> and others
 
-                                        version devel
+                                     version devel-r377
 
                                           A\bAb\bbs\bst\btr\bra\bac\bct\bt
 
        Example: send-hook mutt 'set mime_forward signature='''
 
        Another typical use for this command is to change the values of the _\b$_\ba_\bt_\bt_\br_\bi_\bb_\bu_\b-
-       _\bt_\bi_\bo_\bn (section 6.4.15  , page 84), _\b$_\bs_\bi_\bg_\bn_\ba_\bt_\bu_\br_\be (section 6.4.259  , page 142) and
+       _\bt_\bi_\bo_\bn (section 6.4.15  , page 84), _\b$_\bs_\bi_\bg_\bn_\ba_\bt_\bu_\br_\be (section 6.4.259  , page 143) and
        _\b$_\bl_\bo_\bc_\ba_\bl_\be (section 6.4.114  , page 108) variables in order to change the language
        of the attributions and signatures based upon the recipients.
 
        going messages.  This is probably only useful in connection to the _\bs_\be_\bn_\bd_\b-_\bh_\bo_\bo_\bk
        command.  It can be overridden by use of the _\bp_\bg_\bp_\b-_\bm_\be_\bn_\bu, when encryption is not
        required or signing is requested as well.  If ``_\b$_\bs_\bm_\bi_\bm_\be_\b__\bi_\bs_\b__\bd_\be_\bf_\ba_\bu_\bl_\bt (section
-       6.4.277  , page 146)'' is _\bs_\be_\bt, then OpenSSL is used instead to create S/MIME
+       6.4.277  , page 147)'' is _\bs_\be_\bt, then OpenSSL is used instead to create S/MIME
        messages and settings can be overridden by use of the _\bs_\bm_\bi_\bm_\be_\b-_\bm_\be_\bn_\bu.  (Crypto
        only)
 
        encryption/signing for messages.  See also ``_\b$_\bc_\br_\by_\bp_\bt_\b__\ba_\bu_\bt_\bo_\be_\bn_\bc_\br_\by_\bp_\bt (section
        6.4.34  , page 88)'', ``_\b$_\bc_\br_\by_\bp_\bt_\b__\br_\be_\bp_\bl_\by_\be_\bn_\bc_\br_\by_\bp_\bt (section 6.4.38  , page 89)'',
        ``_\b$_\bc_\br_\by_\bp_\bt_\b__\ba_\bu_\bt_\bo_\bs_\bi_\bg_\bn (section 6.4.36  , page 88)'', ``_\b$_\bc_\br_\by_\bp_\bt_\b__\br_\be_\bp_\bl_\by_\bs_\bi_\bg_\bn (section
-       6.4.39  , page 89)'' and ``_\b$_\bs_\bm_\bi_\bm_\be_\b__\bi_\bs_\b__\bd_\be_\bf_\ba_\bu_\bl_\bt (section 6.4.277  , page 146)''.
+       6.4.39  , page 89)'' and ``_\b$_\bs_\bm_\bi_\bm_\be_\b__\bi_\bs_\b__\bd_\be_\bf_\ba_\bu_\bl_\bt (section 6.4.277  , page 147)''.
 
        _\b6_\b._\b4_\b._\b3_\b6  _\bc_\br_\by_\bp_\bt_\b__\ba_\bu_\bt_\bo_\bs_\bi_\bg_\bn
 
        Setting this variable will cause Mutt-ng to always attempt to cryptographically
        sign outgoing messages.  This can be overridden by use of the _\bp_\bg_\bp_\b-_\bm_\be_\bn_\bu, when
        signing is not required or encryption is requested as well. If
-       ``_\b$_\bs_\bm_\bi_\bm_\be_\b__\bi_\bs_\b__\bd_\be_\bf_\ba_\bu_\bl_\bt (section 6.4.277  , page 146)'' is _\bs_\be_\bt, then OpenSSL is
+       ``_\b$_\bs_\bm_\bi_\bm_\be_\b__\bi_\bs_\b__\bd_\be_\bf_\ba_\bu_\bl_\bt (section 6.4.277  , page 147)'' is _\bs_\be_\bt, then OpenSSL is
        used instead to create S/MIME messages and settings can be overridden by use of
        the _\bs_\bm_\bi_\bm_\be_\b-_\bm_\be_\bn_\bu.  (Crypto only)
 
        encryption/signing for messages. See also ``_\b$_\bc_\br_\by_\bp_\bt_\b__\ba_\bu_\bt_\bo_\be_\bn_\bc_\br_\by_\bp_\bt (section
        6.4.34  , page 88)'', ``_\b$_\bc_\br_\by_\bp_\bt_\b__\br_\be_\bp_\bl_\by_\be_\bn_\bc_\br_\by_\bp_\bt (section 6.4.38  , page 89)'',
        ``_\b$_\bc_\br_\by_\bp_\bt_\b__\ba_\bu_\bt_\bo_\bs_\bi_\bg_\bn (section 6.4.36  , page 88)'', ``_\b$_\bc_\br_\by_\bp_\bt_\b__\br_\be_\bp_\bl_\by_\bs_\bi_\bg_\bn (section
-       6.4.39  , page 89)'' and ``_\b$_\bs_\bm_\bi_\bm_\be_\b__\bi_\bs_\b__\bd_\be_\bf_\ba_\bu_\bl_\bt (section 6.4.277  , page 146)''.
+       6.4.39  , page 89)'' and ``_\b$_\bs_\bm_\bi_\bm_\be_\b__\bi_\bs_\b__\bd_\be_\bf_\ba_\bu_\bl_\bt (section 6.4.277  , page 147)''.
 
        _\b6_\b._\b4_\b._\b3_\b8  _\bc_\br_\by_\bp_\bt_\b__\br_\be_\bp_\bl_\by_\be_\bn_\bc_\br_\by_\bp_\bt
 
 
        Controls the display of wrapped lines in the internal pager. If set, a ``+''
        marker is displayed at the beginning of wrapped lines. Also see the
-       ``_\b$_\bs_\bm_\ba_\br_\bt_\b__\bw_\br_\ba_\bp (section 6.4.263  , page 143)'' variable.
+       ``_\b$_\bs_\bm_\ba_\br_\bt_\b__\bw_\br_\ba_\bp (section 6.4.263  , page 144)'' variable.
 
        _\b6_\b._\b4_\b._\b1_\b2_\b2  _\bm_\ba_\bs_\bk
 
        When _\bs_\be_\bt, the maximum line length for displaying ``format = flowed'' messages
        is limited to this length. A value of 0 (which is also the default) means that
        the maximum line length is determined by the terminal width and _\b$_\bw_\br_\ba_\bp_\bm_\ba_\br_\bg_\bi_\bn
-       (section 6.4.335  , page 161).
+       (section 6.4.335  , page 162).
 
        _\b6_\b._\b4_\b._\b1_\b2_\b4  _\bm_\bb_\bo_\bx
 
        Default: '.'
 
        When the sidebar is displayed and _\b$_\bs_\bi_\bd_\be_\bb_\ba_\br_\b__\bs_\bh_\bo_\br_\bt_\be_\bn_\b__\bh_\bi_\be_\br_\ba_\br_\bc_\bh_\by (section
-       6.4.254  , page 141) is _\bs_\be_\bt, this variable specifies the characters at which to
+       6.4.254  , page 142) is _\bs_\be_\bt, this variable specifies the characters at which to
        split a folder name into ``hierarchy items.''
 
        _\b6_\b._\b4_\b._\b2_\b5_\b1  _\bs_\bi_\bd_\be_\bb_\ba_\br_\b__\bd_\be_\bl_\bi_\bm
 
        Type: string
 
-       Default: '%c%?n?(%n)?%?f?[%f]?'
+       Default: '%m%?n?(%n)?%?f?[%f]?'
 
        This variable controls how message counts are printed when the sidebar is
        enabled. If this variable is _\be_\bm_\bp_\bt_\by (_\ba_\bn_\bd _\bo_\bn_\bl_\by _\bi_\bf), no numbers will be printed
        _\ba_\bn_\bd mutt-ng won't frequently count mail (which may be a great speedup esp. with
        mbox-style mailboxes.)
 
-       The following printf(3)-like sequences are supported:
+       The following printf(3)-like sequences are supported all of which may be
+       printed non-zero:
 
-             %c
-                   Total number of messages.
+             %d
+                   Number of deleted messages. 1)
 
-             %f
+             %F
                    Number of flagged messages.
 
+             %m
+                   Total number of messages.
+
+             %M
+                   Total number of messages shown, i.e. not hidden by a limit. 1)
+
+       The Mutt Next Generation E-Mail Client                                      143
+
              %n
                    Number of new messages.
 
-       The %f and %n expandos may optionally be printed non-zero.
+             %t
+                   Number of tagged messages. 1)
+
+       1) These expandos only have a non-zero value for the current mailbox and will
+       always be zero otherwise.
 
        _\b6_\b._\b4_\b._\b2_\b5_\b4  _\bs_\bi_\bd_\be_\bb_\ba_\br_\b__\bs_\bh_\bo_\br_\bt_\be_\bn_\b__\bh_\bi_\be_\br_\ba_\br_\bc_\bh_\by
 
        Type: boolean
 
-       The Mutt Next Generation E-Mail Client                                      143
-
        Default: no
 
        When _\bs_\be_\bt, the ``hierarchy'' of the sidebar entries will be shortened only if
        Default: yes
 
        If set, a line containing ``-- '' (dash, dash, space) will be inserted before
-       your ``_\b$_\bs_\bi_\bg_\bn_\ba_\bt_\bu_\br_\be (section 6.4.259  , page 142)''.  It is s\bst\btr\bro\bon\bng\bgl\bly\by recommended
+       your ``_\b$_\bs_\bi_\bg_\bn_\ba_\bt_\bu_\br_\be (section 6.4.259  , page 143)''.  It is s\bst\btr\bro\bon\bng\bgl\bly\by recommended
        that you not unset this variable unless your ``signature'' contains just your
        name. The reason for this is because many software packages use ``-- \n'' to
        detect your signature.
 
+       The Mutt Next Generation E-Mail Client                                      144
+
        For example, Mutt-ng has the ability to highlight the signature in a different
        color in the builtin pager.
 
        know what you are doing, and are prepared to take some heat from netiquette
        guardians.
 
-       The Mutt Next Generation E-Mail Client                                      144
-
        _\b6_\b._\b4_\b._\b2_\b5_\b9  _\bs_\bi_\bg_\bn_\ba_\bt_\bu_\br_\be
 
        Type: path
 
        ~f joe | ~s joe
 
+       The Mutt Next Generation E-Mail Client                                      145
+
        _\b6_\b._\b4_\b._\b2_\b6_\b2  _\bs_\bl_\be_\be_\bp_\b__\bt_\bi_\bm_\be
 
        Type: number
 
        Type: boolean
 
-       The Mutt Next Generation E-Mail Client                                      145
-
        Default: yes
 
        Controls the display of lines longer than the screen width in the internal
 
        Type: path
 
+       The Mutt Next Generation E-Mail Client                                      146
+
        Default: ''
 
        Since there is no pubring/secring as with PGP, Mutt-ng has to handle storage
 
        Default: ''
 
-       The Mutt Next Generation E-Mail Client                                      146
-
        This format string specifies a command which is used to decrypt application/x-
        pkcs7-mime attachments.
 
 
        Default: yes
 
+       The Mutt Next Generation E-Mail Client                                      147
+
        If _\bs_\be_\bt (default) this tells Mutt-ng to use the default key for decryption. Oth-
        erwise, if manage multiple certificate-key-pairs, Mutt-ng will try to use the
        mailbox-address to determine the key to use. It will ask you to supply a key,
        This is the default key-pair to use for signing. This must be set to the keyid
        (the hash-value that OpenSSL generates) to work properly (S/MIME only)
 
-       The Mutt Next Generation E-Mail Client                                      147
-
        _\b6_\b._\b4_\b._\b2_\b7_\b1  _\bs_\bm_\bi_\bm_\be_\b__\be_\bn_\bc_\br_\by_\bp_\bt_\b__\bc_\bo_\bm_\bm_\ba_\bn_\bd
 
        Type: string
 
        _\b6_\b._\b4_\b._\b2_\b7_\b5  _\bs_\bm_\bi_\bm_\be_\b__\bg_\be_\bt_\b__\bs_\bi_\bg_\bn_\be_\br_\b__\bc_\be_\br_\bt_\b__\bc_\bo_\bm_\bm_\ba_\bn_\bd
 
+       The Mutt Next Generation E-Mail Client                                      148
+
        Type: string
 
        Default: ''
 
        Default: ''
 
-       The Mutt Next Generation E-Mail Client                                      148
-
        This command is used to import a certificate via smime_keysng.  (S/MIME only)
 
        _\b6_\b._\b4_\b._\b2_\b7_\b7  _\bs_\bm_\bi_\bm_\be_\b__\bi_\bs_\b__\bd_\be_\bf_\ba_\bu_\bl_\bt
        This command is used to extract PKCS7 structures of S/MIME signatures, in order
        to extract the public X509 certificate(s).  (S/MIME only)
 
+       The Mutt Next Generation E-Mail Client                                      149
+
        _\b6_\b._\b4_\b._\b2_\b8_\b0  _\bs_\bm_\bi_\bm_\be_\b__\bs_\bi_\bg_\bn_\b__\bc_\bo_\bm_\bm_\ba_\bn_\bd
 
        Type: string
 
        Default: ''
 
-       The Mutt Next Generation E-Mail Client                                      149
-
        This command is used to created S/MIME signatures of type application/x-
        pkcs7-signature, which can only be handled by mail clients supporting the
        S/MIME extension.  (S/MIME only)
 
        Availability: SMTP
 
+       The Mutt Next Generation E-Mail Client                                      150
+
        Defines the password to use with SMTP AUTH.  If ``_\b$_\bs_\bm_\bt_\bp_\b__\ba_\bu_\bt_\bh_\b__\bu_\bs_\be_\br_\bn_\ba_\bm_\be (section
        6.4.286  , page 148)'' is set, but this variable is not, you will be prompted
        for a password when sending.
 
        Availability: SMTP
 
-       The Mutt Next Generation E-Mail Client                                      150
-
        Defines the username to use with SMTP AUTH.  Setting this variable will cause
        Mutt-ng to attempt to use SMTP AUTH when sending.
 
 
        Specifies how to sort messages in the _\bi_\bn_\bd_\be_\bx menu.  Valid values are:
 
+       The Mutt Next Generation E-Mail Client                                      151
+
                date or date-sent
                date-received
                from
        You may optionally use the ``reverse-'' prefix to specify reverse sorting order
        (example: set sort=reverse-date-sent).
 
-       The Mutt Next Generation E-Mail Client                                      151
-
        _\b6_\b._\b4_\b._\b2_\b9_\b0  _\bs_\bo_\br_\bt_\b__\ba_\bl_\bi_\ba_\bs
 
        Type: sort order
        (section 6.4.291  , page 150) is reversed again (which is not the right thing
        to do, but kept to not break any existing configuration setting).
 
+       The Mutt Next Generation E-Mail Client                                      152
+
        _\b6_\b._\b4_\b._\b2_\b9_\b2  _\bs_\bo_\br_\bt_\b__\bb_\br_\bo_\bw_\bs_\be_\br
 
        Type: sort order
                size
                unsorted
 
-       The Mutt Next Generation E-Mail Client                                      152
-
        You may optionally use the ``reverse-'' prefix to specify reverse sorting order
        (example: set sort_browser=reverse-date).
 
        This variable is only useful when sorting by threads with ``_\b$_\bs_\bt_\br_\bi_\bc_\bt_\b__\bt_\bh_\br_\be_\ba_\bd_\bs
        (section 6.4.309  , page 156)'' _\bu_\bn_\bs_\be_\bt. In that case, it changes the heuristic
        Mutt-ng uses to thread messages by subject.  With _\b$_\bs_\bo_\br_\bt_\b__\br_\be (section 6.4.293  ,
-       page 150) _\bs_\be_\bt, Mutt-ng will only attach a message as the child of another mes-
+       page 151) _\bs_\be_\bt, Mutt-ng will only attach a message as the child of another mes-
        sage by subject if the subject of the child message starts with a substring
        matching the setting of ``_\b$_\br_\be_\bp_\bl_\by_\b__\br_\be_\bg_\be_\bx_\bp (section 6.4.231  , page 136)''. With
-       _\b$_\bs_\bo_\br_\bt_\b__\br_\be (section 6.4.293  , page 150) _\bu_\bn_\bs_\be_\bt, Mutt-ng will attach the message
+       _\b$_\bs_\bo_\br_\bt_\b__\br_\be (section 6.4.293  , page 151) _\bu_\bn_\bs_\be_\bt, Mutt-ng will attach the message
        whether or not this is the case, as long as the non-``_\b$_\br_\be_\bp_\bl_\by_\b__\br_\be_\bg_\be_\bx_\bp (section
        6.4.231  , page 136)'' parts of both messages are identical.
 
        Default: ''
 
        If your spool mailbox is in a non-default place where Mutt-ng cannot find it,
+
+       The Mutt Next Generation E-Mail Client                                      153
+
        you can specify its location with this variable.  Mutt-ng will automatically
        set this variable to the value of the environment variable $MAIL if it is not
        set.
 
        Example: set ssl_ca_certificates_file=/etc/ssl/certs/ca-certificates.crt
 
-       The Mutt Next Generation E-Mail Client                                      153
-
        _\b6_\b._\b4_\b._\b2_\b9_\b7  _\bs_\bs_\bl_\b__\bc_\bl_\bi_\be_\bn_\bt_\b__\bc_\be_\br_\bt
 
        Type: path
 
        Type: boolean
 
+       The Mutt Next Generation E-Mail Client                                      154
+
        Default: yes
 
        Availability: SSL
 
        Availability: SSL or GNUTLS
 
-       This variables specifies whether to attempt to use SSLv3 in the SSL
-
-       The Mutt Next Generation E-Mail Client                                      154
-
-       authentication process.
+       This variables specifies whether to attempt to use SSLv3 in the SSL authentica-
+       tion process.
 
        _\b6_\b._\b4_\b._\b3_\b0_\b2  _\bs_\bs_\bl_\b__\bu_\bs_\be_\b__\bt_\bl_\bs_\bv_\b1
 
        whether to write changes to a mailbox with the toggle-write operation, bound by
        default to ``%'').  The fourth  is used to indicate that the current folder has
        been opened in attach-message mode (Certain operations like composing a new
+
+       The Mutt Next Generation E-Mail Client                                      155
+
        mail, replying, forwarding, etc. are not permitted in this mode).
 
        _\b6_\b._\b4_\b._\b3_\b0_\b5  _\bs_\bt_\ba_\bt_\bu_\bs_\b__\bf_\bo_\br_\bm_\ba_\bt
              %b
                    number of mailboxes with new mail *
 
-       The Mutt Next Generation E-Mail Client                                      155
-
              %B
                    the short pathname of the current mailbox
 
              %p
                    number of postponed messages *
 
+       The Mutt Next Generation E-Mail Client                                      156
+
              %P
                    percentage of the way through the index
 
              %t
                    number of tagged messages *
 
-       The Mutt Next Generation E-Mail Client                                      156
-
              %u
                    number of unread messages *
 
        %?n?%n new messages.?
 
        Additionally you can switch between two strings, the first one, if a value is
-       zero, the second one, if the value is nonzero, by using the following con-
-       struct:
+       zero, the second one, if the value is nonzero, by using the following
+
+       The Mutt Next Generation E-Mail Client                                      157
+
+       construct:
 
        %?<sequence_char>?<if_string>&<else_string>?
 
 
        Type: boolean
 
-       The Mutt Next Generation E-Mail Client                                      157
-
        Default: no
 
        Setting this variable causes the ``status bar'' to be displayed on the first
        a single space to prevent the display of MIME-encoded ``Subject:'' header field
        from being devided into multiple lines.
 
+       The Mutt Next Generation E-Mail Client                                      158
+
        _\b6_\b._\b4_\b._\b3_\b0_\b9  _\bs_\bt_\br_\bi_\bc_\bt_\b__\bt_\bh_\br_\be_\ba_\bd_\bs
 
        Type: boolean
 
        Default: no
 
-       The Mutt Next Generation E-Mail Client                                      158
-
        When _\bs_\be_\bt, mutt-ng will remove the trailing part of the ``Subject:'' line which
-       matches _\b$_\bs_\bt_\br_\bi_\bp_\b__\bw_\ba_\bs_\b__\br_\be_\bg_\be_\bx (section 6.4.311  , page 156) when replying. This is
+       matches _\b$_\bs_\bt_\br_\bi_\bp_\b__\bw_\ba_\bs_\b__\br_\be_\bg_\be_\bx (section 6.4.311  , page 157) when replying. This is
        useful to properly react on subject changes and reduce ``subject noise.'' (esp.
        in Usenet)
 
        usually CTRL+Z. This is useful if you run Mutt-ng inside an xterm using a com-
        mand like ``xterm -e muttng.''
 
+       The Mutt Next Generation E-Mail Client                                      159
+
        _\b6_\b._\b4_\b._\b3_\b1_\b4  _\bt_\be_\bx_\bt_\b__\bf_\bl_\bo_\bw_\be_\bd
 
        Type: boolean
 
        Default: no
 
-       The Mutt Next Generation E-Mail Client                                      159
-
        Affects the ~b and ~h search operations described in section ``_\bp_\ba_\bt_\bt_\be_\br_\bn_\bs (sec-
        tion 6.2  , page 77)'' above.  If _\bs_\be_\bt, the headers and attachments of messages
        to be searched are decoded before searching.  If _\bu_\bn_\bs_\be_\bt, messages are searched
        pressed in the main menu before timing out and checking for new mail.  A value
        of zero or less will cause Mutt-ng to never time out.
 
+       The Mutt Next Generation E-Mail Client                                      160
+
        _\b6_\b._\b4_\b._\b3_\b1_\b9  _\bt_\bm_\bp_\bd_\bi_\br
 
        Type: path
        acter is the one used when the mail is NOT addressed to your address (default:
        space).  The second is used when you are the only recipient of the message
        (default: +).  The third is when your address appears in the ``To:'' header
-
-       The Mutt Next Generation E-Mail Client                                      160
-
        field, but you are not the only recipient of the message (default: T).  The
        fourth character is used when your address is specified in the ``Cc:'' header
        field, but you are not the only recipient.  The fifth character is used to
        N\bNo\bot\bte\be:\b: For this example to work you must be able to log in to the remote machine
        without having to enter a password.
 
+       The Mutt Next Generation E-Mail Client                                      161
+
        _\b6_\b._\b4_\b._\b3_\b2_\b3  _\bu_\bm_\ba_\bs_\bk
 
        Type: number
 
        Type: boolean
 
-       The Mutt Next Generation E-Mail Client                                      161
-
        Default: no
 
        W\bWa\bar\brn\bni\bin\bng\bg:\b: do not set this variable unless you are using a version of sendmail
 
        Type: boolean
 
+       The Mutt Next Generation E-Mail Client                                      162
+
        Default: yes
 
        Availability: IDN
 
        _\b6_\b._\b4_\b._\b3_\b3_\b0  _\bu_\bs_\be_\br_\b__\ba_\bg_\be_\bn_\bt
 
-       The Mutt Next Generation E-Mail Client                                      162
-
        Type: boolean
 
        Default: yes
        When _\bs_\be_\bt, Mutt-ng will always ask for a key. When _\bu_\bn_\bs_\be_\bt, Mutt-ng will wait for
        a key only if the external command returned a non-zero status.
 
+       The Mutt Next Generation E-Mail Client                                      163
+
        _\b6_\b._\b4_\b._\b3_\b3_\b3  _\bw_\be_\be_\bd
 
        Type: boolean
 
        _\b6_\b._\b4_\b._\b3_\b3_\b5  _\bw_\br_\ba_\bp_\bm_\ba_\br_\bg_\bi_\bn
 
-       The Mutt Next Generation E-Mail Client                                      163
-
        Type: number
 
        Default: 0
 
        Type: string
 
+       The Mutt Next Generation E-Mail Client                                      164
+
        Default: 'M%?n?AIL&ail?'
 
        Controls the format of the X11 icon title, as long as _\b$_\bx_\bt_\be_\br_\bm_\b__\bs_\be_\bt_\b__\bt_\bi_\bt_\bl_\be_\bs (sec-
-       tion 6.4.340  , page 162) is _\bs_\be_\bt. This string is identical in formatting to the
+       tion 6.4.340  , page 163) is _\bs_\be_\bt. This string is identical in formatting to the
        one used by ``_\b$_\bs_\bt_\ba_\bt_\bu_\bs_\b__\bf_\bo_\br_\bm_\ba_\bt (section 6.4.305  , page 153)''.
 
        _\b6_\b._\b4_\b._\b3_\b3_\b9  _\bx_\bt_\be_\br_\bm_\b__\bl_\be_\ba_\bv_\be
 
        Default: ''
 
-       If _\b$_\bx_\bt_\be_\br_\bm_\b__\bs_\be_\bt_\b__\bt_\bi_\bt_\bl_\be_\bs (section 6.4.340  , page 162) is _\bs_\be_\bt, this string will be
+       If _\b$_\bx_\bt_\be_\br_\bm_\b__\bs_\be_\bt_\b__\bt_\bi_\bt_\bl_\be_\bs (section 6.4.340  , page 163) is _\bs_\be_\bt, this string will be
        used to set the title when leaving mutt-ng. For terminal-based programs,
        there's no easy and portable way to read the current title so mutt-ng cannot
        read it upon startup and restore it when exiting.
        set xterm_leave = '`test x$DISPLAY != x && xprop -id $WINDOWID | grep WM_NAME |
        cut -d ''' -f 2`'
 
-       The Mutt Next Generation E-Mail Client                                      164
-
        _\b6_\b._\b4_\b._\b3_\b4_\b0  _\bx_\bt_\be_\br_\bm_\b__\bs_\be_\bt_\b__\bt_\bi_\bt_\bl_\be_\bs
 
        Type: boolean
        Default: 'Mutt-ng with %?m?%m messages&no messages?%?n? [%n New]?'
 
        Controls the format of the title bar of the xterm provided that
-       _\b$_\bx_\bt_\be_\br_\bm_\b__\bs_\be_\bt_\b__\bt_\bi_\bt_\bl_\be_\bs (section 6.4.340  , page 162) has been _\bs_\be_\bt. This string is
+       _\b$_\bx_\bt_\be_\br_\bm_\b__\bs_\be_\bt_\b__\bt_\bi_\bt_\bl_\be_\bs (section 6.4.340  , page 163) has been _\bs_\be_\bt. This string is
        identical in formatting to the one used by ``_\b$_\bs_\bt_\ba_\bt_\bu_\bs_\b__\bf_\bo_\br_\bm_\ba_\bt (section 6.4.305  ,
        page 153)''.
 
        _\b6_\b._\b5_\b._\b1  _\bg_\be_\bn_\be_\br_\bi_\bc
 
        The _\bg_\be_\bn_\be_\br_\bi_\bc menu is not a real menu, but specifies common functions (such as
-       movement) available in all menus except for _\bp_\ba_\bg_\be_\br and _\be_\bd_\bi_\bt_\bo_\br.  Changing set-
-       tings for this menu will affect the default bindings for all menus (except as
-       noted).
+       movement) available in all menus except for _\bp_\ba_\bg_\be_\br and _\be_\bd_\bi_\bt_\bo_\br.  Changing
 
        The Mutt Next Generation E-Mail Client                                      165
 
+       settings for this menu will affect the default bindings for all menus (except
+       as noted).
+
             bottom-page                L   move to the bottom of the page
             current-bottom     not bound   move current entry to bottom of page
             current-middle     not bound   move current entry to middle of page
                  6.4.251  sidebar_delim   142
                  6.4.252  sidebar_newmail_only   142
                  6.4.253  sidebar_number_format   142
-                 6.4.254  sidebar_shorten_hierarchy   142
+                 6.4.254  sidebar_shorten_hierarchy   143
                  6.4.255  sidebar_visible   143
                  6.4.256  sidebar_width   143
                  6.4.257  sig_dashes   143
-                 6.4.258  sig_on_top   143
+                 6.4.258  sig_on_top   144
                  6.4.259  signature   144
                  6.4.260  signoff_string   144
                  6.4.261  simple_search   144
-                 6.4.262  sleep_time   144
-                 6.4.263  smart_wrap   144
+                 6.4.262  sleep_time   145
+                 6.4.263  smart_wrap   145
                  6.4.264  smileys   145
                  6.4.265  smime_ask_cert_label   145
                  6.4.266  smime_ca_location   145
                  6.4.267  smime_certificates   145
-                 6.4.268  smime_decrypt_command   145
+                 6.4.268  smime_decrypt_command   146
                  6.4.269  smime_decrypt_use_default_key   146
-                 6.4.270  smime_default_key   146
+                 6.4.270  smime_default_key   147
                  6.4.271  smime_encrypt_command   147
                  6.4.272  smime_encrypt_with   147
                  6.4.273  smime_get_cert_command   147
                  6.4.274  smime_get_cert_email_command   147
                  6.4.275  smime_get_signer_cert_command   147
-                 6.4.276  smime_import_cert_command   147
+                 6.4.276  smime_import_cert_command   148
                  6.4.277  smime_is_default   148
                  6.4.278  smime_keys   148
                  6.4.279  smime_pk7out_command   148
-                 6.4.280  smime_sign_command   148
-                 6.4.281  smime_sign_opaque_command   148
+                 6.4.280  smime_sign_command   149
+                 6.4.281  smime_sign_opaque_command   149
                  6.4.282  smime_timeout   149
                  6.4.283  smime_verify_command   149
                  6.4.284  smime_verify_opaque_command   149
                  6.4.285  smtp_auth_password   149
-                 6.4.286  smtp_auth_username   149
+                 6.4.286  smtp_auth_username   150
                  6.4.287  smtp_host   150
 
                                              viii
                  6.4.289  sort   150
                  6.4.290  sort_alias   151
                  6.4.291  sort_aux   151
-                 6.4.292  sort_browser   151
+                 6.4.292  sort_browser   152
                  6.4.293  sort_re   152
                  6.4.294  spam_separator   152
                  6.4.295  spoolfile   152
-                 6.4.296  ssl_ca_certificates_file   152
+                 6.4.296  ssl_ca_certificates_file   153
                  6.4.297  ssl_client_cert   153
                  6.4.298  ssl_min_dh_prime_bits   153
                  6.4.299  ssl_starttls   153
                  6.4.300  ssl_use_sslv2   153
-                 6.4.301  ssl_use_sslv3   153
+                 6.4.301  ssl_use_sslv3   154
                  6.4.302  ssl_use_tlsv1   154
                  6.4.303  ssl_usesystemcerts   154
                  6.4.304  status_chars   154
-                 6.4.305  status_format   154
-                 6.4.306  status_on_top   156
+                 6.4.305  status_format   155
+                 6.4.306  status_on_top   157
                  6.4.307  strict_mailto   157
                  6.4.308  strict_mime   157
-                 6.4.309  strict_threads   157
-                 6.4.310  strip_was   157
+                 6.4.309  strict_threads   158
+                 6.4.310  strip_was   158
                  6.4.311  strip_was_regex   158
                  6.4.312  stuff_quoted   158
                  6.4.313  suspend   158
-                 6.4.314  text_flowed   158
-                 6.4.315  thorough_search   158
+                 6.4.314  text_flowed   159
+                 6.4.315  thorough_search   159
                  6.4.316  thread_received   159
                  6.4.317  tilde   159
                  6.4.318  timeout   159
-                 6.4.319  tmpdir   159
-                 6.4.320  to_chars   159
+                 6.4.319  tmpdir   160
+                 6.4.320  to_chars   160
                  6.4.321  trash   160
                  6.4.322  tunnel   160
-                 6.4.323  umask   160
-                 6.4.324  uncollapse_jump   160
-                 6.4.325  use_8bitmime   160
+                 6.4.323  umask   161
+                 6.4.324  uncollapse_jump   161
+                 6.4.325  use_8bitmime   161
                  6.4.326  use_domain   161
                  6.4.327  use_from   161
                  6.4.328  use_idn   161
-                 6.4.329  use_ipv6   161
-                 6.4.330  user_agent   161
+                 6.4.329  use_ipv6   162
+                 6.4.330  user_agent   162
                  6.4.331  visual   162
                  6.4.332  wait_key   162
-                 6.4.333  weed   162
-                 6.4.334  wrap_search   162
-                 6.4.335  wrapmargin   162
+                 6.4.333  weed   163
+                 6.4.334  wrap_search   163
+                 6.4.335  wrapmargin   163
                  6.4.336  write_bcc   163
                  6.4.337  write_inc   163
                  6.4.338  xterm_icon   163
-                 6.4.339  xterm_leave   163
+                 6.4.339  xterm_leave   164
                  6.4.340  xterm_set_titles   164
 
                                               ix
diff --git a/init.h b/init.h
index 4e78663..de6c9dc 100644 (file)
--- a/init.h
+++ b/init.h
@@ -1400,7 +1400,7 @@ struct option_t MuttVars[] = {
    ** .pp
    ** If \fIset\fP, only folders with new mail will be shown in the sidebar.
    */
-  {"sidebar_number_format", DT_STR, R_BOTH, UL &SidebarNumberFormat, UL "%c%?n?(%n)?%?f?[%f]?"},
+  {"sidebar_number_format", DT_STR, R_BOTH, UL &SidebarNumberFormat, UL "%m%?n?(%n)?%?f?[%f]?"},
   /*
    ** .pp
    ** This variable controls how message counts are printed when the sidebar
@@ -1408,15 +1408,20 @@ struct option_t MuttVars[] = {
    ** will be printed \fIand\fP mutt-ng won't frequently count mail (which
    ** may be a great speedup esp. with mbox-style mailboxes.)
    ** .pp
-   ** The following \fTprintf(3)\fP-like sequences are supported:
+   ** The following \fTprintf(3)\fP-like sequences are supported all of which
+   ** may be printed non-zero:
    ** .pp
    ** .dl
-   ** .dt %c .dd Total number of messages.
-   ** .dt %f .dd Number of flagged messages.
+   ** .dt %d .dd Number of deleted messages. 1)
+   ** .dt %F .dd Number of flagged messages.
+   ** .dt %m .dd Total number of messages.
+   ** .dt %M .dd Total number of messages shown, i.e. not hidden by a limit. 1)
    ** .dt %n .dd Number of new messages.
+   ** .dt %t .dd Number of tagged messages. 1)
    ** .de
    ** .pp
-   ** The \fT%f\fP and \fT%n\fP expandos may optionally be printed non-zero.
+   ** 1) These expandos only have a non-zero value for the current mailbox and
+   ** will always be zero otherwise.
    */
   {"sidebar_shorten_hierarchy", DT_BOOL, R_NONE, OPTSHORTENHIERARCHY, 0},
   /*
index e2b417e..6fd5ce0 100644 (file)
--- a/sidebar.c
+++ b/sidebar.c
@@ -109,10 +109,41 @@ static const char* sidebar_number_format (char* dest, size_t destlen, char op,
   int c = Context && str_eq (Context->path, b->path);
 
   switch (op) {
-    case 'c':
-      snprintf (tmp, sizeof (tmp), "%%%sd", fmt);
-      snprintf (dest, destlen, tmp, c ? (Context->msgcount - Context->deleted) : b->msgcount);
+    /* deleted */
+    case 'd':
+      if (!opt) {
+        snprintf (tmp, sizeof (tmp), "%%%sd", fmt);
+        snprintf (dest, destlen, tmp, c ? Context->deleted : 0);
+      } else if ((c && Context->deleted == 0) || !c)
+        opt = 0;
+      break;
+    /* flagged */
+    case 'F':
+    case 'f':                   /* for compatibility */
+      if (!opt) {
+        snprintf (tmp, sizeof (tmp), "%%%sd", fmt);
+        snprintf (dest, destlen, tmp, c ? Context->flagged : b->msg_flagged);
+      } else if ((c && Context->flagged == 0) || (!c && b->msg_flagged == 0))
+        opt = 0;
       break;
+    /* total */
+    case 'c':                   /* for compatibility */
+    case 'm':
+      if (!opt) {
+        snprintf (tmp, sizeof (tmp), "%%%sd", fmt);
+        snprintf (dest, destlen, tmp, c ? Context->msgcount : b->msgcount);
+      } else if ((c && Context->msgcount == 0) || (!c && b->msgcount == 0))
+        opt = 0;
+      break;
+    /* total shown, i.e. not hidden by limit */
+    case 'M':
+      if (!opt) {
+        snprintf (tmp, sizeof (tmp), "%%%sd", fmt);
+        snprintf (dest, destlen, tmp, c ? Context->vcount : 0);
+      } else if ((c && Context->vcount == 0) || !c)
+        opt = 0;
+      break;
+    /* new */
     case 'n':
       if (!opt) {
         snprintf (tmp, sizeof (tmp), "%%%sd", fmt);
@@ -120,11 +151,12 @@ static const char* sidebar_number_format (char* dest, size_t destlen, char op,
       } else if ((c && Context->unread == 0) || (!c && b->msg_unread == 0))
         opt = 0;
       break;
-    case 'f':
+    /* tagged */
+    case 't':
       if (!opt) {
         snprintf (tmp, sizeof (tmp), "%%%sd", fmt);
-        snprintf (dest, destlen, tmp, c ? Context->flagged : b->msg_flagged);
-      } else if ((c && Context->flagged == 0) || (!c && b->msg_flagged == 0))
+        snprintf (dest, destlen, tmp, c ? Context->tagged : 0);
+      } else if ((c && Context->tagged == 0) || !c)
         opt = 0;
       break;
   }