NeoMutt  2023-05-17-33-gce4425
Teaching an old dog new tricks
hdrline.h File Reference

String processing routines to generate the mail index. More...

#include <stdio.h>
#include "format_flags.h"
+ Include dependency graph for hdrline.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.


void mutt_make_string (char *buf, size_t buflen, int cols, const char *s, struct Mailbox *m, int inpgr, struct Email *e, MuttFormatFlags flags, const char *progress)
 Create formatted strings using mailbox expandos. More...

Detailed Description

String processing routines to generate the mail index.

  • Richard Russon
  • Pietro Cerutti

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program. If not, see

Definition in file hdrline.h.

Function Documentation

◆ mutt_make_string()

void mutt_make_string ( char *  buf,
size_t  buflen,
int  cols,
const char *  s,
struct Mailbox m,
int  inpgr,
struct Email e,
MuttFormatFlags  flags,
const char *  progress 

Create formatted strings using mailbox expandos.

bufBuffer for the result
buflenBuffer length
colsNumber of screen columns (OPTIONAL)
sprintf-line format string
inpgrMessage shown in the pager
flagsFlags, see MuttFormatFlags
progressPager progress string
See also

Definition at line 1489 of file hdrline.c.

1493 struct HdrFormatInfo hfi = { 0 };
1495 = e;
1496 hfi.mailbox = m;
1497 hfi.msg_in_pager = inpgr;
1498 hfi.pager_progress = progress;
1500 mutt_expando_format(buf, buflen, 0, cols, s, index_format_str, (intptr_t) &hfi, flags);
void mutt_expando_format(char *buf, size_t buflen, size_t col, int cols, const char *src, format_t callback, intptr_t data, MuttFormatFlags flags)
Expand expandos (x) in a string -.
Definition: muttlib.c:742
static const char * index_format_str(char *buf, size_t buflen, size_t col, int cols, char op, const char *src, const char *prec, const char *if_str, const char *else_str, intptr_t data, MuttFormatFlags flags)
Format a string for the index list - Implements format_t -.
Definition: hdrline.c:451
Data passed to index_format_str()
Definition: hdrline.c:67
struct Email * email
Current Email.
Definition: hdrline.c:70
int msg_in_pager
Index of Email displayed in the Pager.
Definition: hdrline.c:69
struct Mailbox * mailbox
Current Mailbox.
Definition: hdrline.c:68
const char * pager_progress
String representing Pager position through Email.
Definition: hdrline.c:71
+ Here is the call graph for this function:
+ Here is the caller graph for this function: