67 snprintf(buf, buflen,
"%s%s%s", (method &
SORT_REVERSE) ?
"reverse-" :
"",
79 char tmp[128] = { 0 };
92 char tmp[128] = { 0 };
95 const char *s =
get_sort_str(tmp,
sizeof(tmp), c_sort_aux);
156 const char *s = m->
name;
213 char tmp[128] = { 0 };
215 const off_t num = mailbox_view ? mailbox_view->
vsize : 0;
231 return mailbox_view->
vsize;
244 char tmp[128] = { 0 };
278 char tmp[128] = { 0 };
280 const off_t num = m ? m->
size : 0;
356 if (!c_status_chars || !c_status_chars->
len)
376 if (i >= c_status_chars->
len)
438 const struct Menu *menu = msld->
menu;
442 char tmp[128] = { 0 };
459 snprintf(tmp,
sizeof(tmp),
_(
"%d%%"), count);
472 const struct Menu *menu = msld->
menu;
512 { -1, -1, NULL, NULL },
bool buf_is_empty(const struct Buffer *buf)
Is the Buffer empty?
size_t buf_addstr(struct Buffer *buf, const char *s)
Add a string to a Buffer.
size_t buf_strcpy(struct Buffer *buf, const char *s)
Copy a string into a Buffer.
void mutt_pretty_mailbox(char *buf, size_t buflen)
Shorten a mailbox path using '~' or '='.
struct MbTable * cs_subset_mbtable(const struct ConfigSubset *sub, const char *name)
Get a Multibyte table config item by name.
short cs_subset_sort(const struct ConfigSubset *sub, const char *name)
Get a sort config item by name.
Convenience wrapper for the config headers.
#define SORT_MASK
Mask for the sort id.
#define SORT_LAST
Sort thread by last-X, e.g. received date.
#define SORT_REVERSE
Reverse the order of the sort.
Convenience wrapper for the core headers.
static const char * mailbox_path(const struct Mailbox *m)
Get the Mailbox's path string.
@ MUTT_NOTMUCH
'Notmuch' (virtual) Mailbox type
@ MUTT_IMAP
'IMAP' Mailbox type
@ ED_MENU
Menu ED_MEN_ ExpandoDataMenu.
@ ED_GLOBAL
Global ED_GLO_ ExpandoDataGlobal.
@ ED_INDEX
Index ED_IND_ ExpandoDataIndex.
Structs that make up an email.
EmailSortType
Methods for sorting Emails.
const struct ExpandoRenderCallback StatusRenderCallbacks[]
Callbacks for Status Expandos.
static char * get_sort_str(char *buf, size_t buflen, enum EmailSortType method)
Get the sort method as a string.
static void global_hostname(const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
Status: Local hostname - Implements get_string_t -.
static void global_version(const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
Status: Version string - Implements get_string_t -.
GUI display a user-configurable status line.
char * ShortHostname
Short version of the hostname.
static long index_deleted_count_num(const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
Status: Number of deleted messages - Implements get_number_t -.
static long index_tagged_count_num(const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
Status: Number of tagged messages - Implements get_number_t -.
static long index_limit_size_num(const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
Status: Size of the messages - Implements get_number_t -.
static long index_old_count_num(const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
Status: Number of old messages - Implements get_number_t -.
static long index_limit_count_num(const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
Status: Number of messages - Implements get_number_t -.
static long index_new_count_num(const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
Status: Number of new messages - Implements get_number_t -.
static long index_mailbox_size_num(const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
Status: Size of the current mailbox - Implements get_number_t -.
static long index_postponed_count_num(const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
Status: Number of postponed messages - Implements get_number_t -.
static long index_unread_count_num(const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
Status: Number of unread messages - Implements get_number_t -.
static long index_unread_mailboxes_num(const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
Status: Number of mailboxes with new mail - Implements get_number_t -.
static long index_flagged_count_num(const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
Status: Number of flagged messages - Implements get_number_t -.
static long menu_percentage_num(const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
Status: Percentage through index - Implements get_number_t -.
static long index_message_count_num(const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
Status: Number of messages in the mailbox - Implements get_number_t -.
static long index_read_count_num(const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
Status: Number of read messages - Implements get_number_t -.
static void global_config_sort(const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
Status: Sorting mode - Implements get_string_t -.
static void global_config_sort_aux(const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
Status: Aux sorting method - Implements get_string_t -.
static void index_limit_size(const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
Status: Size of the messages - Implements get_string_t -.
static void index_mailbox_path(const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
Status: pathname of the mailbox - Implements get_string_t -.
static void menu_percentage(const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
Status: Percentage through index - Implements get_string_t -.
static void index_description(const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
Status: Description of the mailbox - Implements get_string_t -.
static void index_readonly(const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
Status: Modified/read-only flag - Implements get_string_t -.
static void index_mailbox_size(const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
Status: Size of the current mailbox - Implements get_string_t -.
static void index_limit_pattern(const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
Status: Active limit pattern - Implements get_string_t -.
static void global_config_use_threads(const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
Status: Current threading mode - Implements get_string_t -.
Data shared between Index, Pager and Sidebar.
@ ED_IND_LIMIT_COUNT
Mailbox.vcount.
@ ED_IND_MAILBOX_PATH
Mailbox.pathbuf, Mailbox.name.
@ ED_IND_DELETED_COUNT
Mailbox.msg_deleted.
@ ED_IND_NEW_COUNT
Mailbox.msg_new.
@ ED_IND_MAILBOX_SIZE
Mailbox.size.
@ ED_IND_LIMIT_PATTERN
MailboxView.pattern.
@ ED_IND_READ_COUNT
Mailbox.msg_count, Mailbox.msg_unread.
@ ED_IND_POSTPONED_COUNT
mutt_num_postponed()
@ ED_IND_FLAGGED_COUNT
Mailbox.msg_flagged.
@ ED_IND_MESSAGE_COUNT
Mailbox.msg_count.
@ ED_IND_OLD_COUNT
Mailbox.msg_unread, Mailbox.msg_new.
@ ED_IND_READONLY
Mailbox.readonly, Mailbox.dontwrite.
@ ED_IND_UNREAD_COUNT
Mailbox.msg_unread.
@ ED_IND_TAGGED_COUNT
Mailbox.msg_tagged.
@ ED_IND_LIMIT_SIZE
MailboxView.vsize.
@ ED_IND_DESCRIPTION
Mailbox.name.
@ ED_IND_UNREAD_MAILBOXES
Mailbox, mutt_mailbox_check()
const struct Mapping SortMethods[]
Sort methods for '$sort' for the index.
const char * mutt_map_get_name(int val, const struct Mapping *map)
Lookup a string for a constant.
Convenience wrapper for the library headers.
size_t mutt_str_copy(char *dest, const char *src, size_t dsize)
Copy a string into a buffer (guaranteeing NUL-termination)
int mutt_mailbox_check(struct Mailbox *m_cur, CheckStatsFlags flags)
Check all all Mailboxes for new mail.
Mailbox helper functions.
const char * get_use_threads_str(enum UseThreads value)
Convert UseThreads enum to string.
enum UseThreads mutt_thread_style(void)
Which threading style is active?
Create/manipulate threading in emails.
UseThreads
Which threading style is active, $use_threads.
const char * mutt_make_version(void)
Generate the NeoMutt version string.
void mutt_str_pretty_size(char *buf, size_t buflen, size_t num)
Display an abbreviated size, like 3.4K.
Some miscellaneous functions.
bool mview_has_limit(const struct MailboxView *mv)
Is a limit active?
#define MUTT_MAILBOX_CHECK_NO_FLAGS
No flags are set.
int mutt_num_postponed(struct Mailbox *m, bool force)
Return the number of postponed messages.
uint8_t MuttFormatFlags
Flags for expando_render(), e.g. MUTT_FORMAT_FORCESUBJ.
String manipulation buffer.
Data shared between Index, Pager and Sidebar.
struct Mailbox * mailbox
Current Mailbox.
bool attach_msg
Are we in "attach message" mode?
struct MailboxView * mailbox_view
Current Mailbox view.
off_t vsize
Size (in bytes) of the messages shown.
char * pattern
Limit pattern string.
int vcount
The number of virtual messages.
bool changed
Mailbox has been modified.
char * realpath
Used for duplicate detection, context comparison, and the sidebar.
int msg_new
Number of new messages.
int msg_count
Total number of messages.
enum MailboxType type
Mailbox type.
char * name
A short name for the Mailbox.
struct Buffer pathbuf
Path of the Mailbox.
int msg_deleted
Number of deleted messages.
bool dontwrite
Don't write the mailbox on close.
off_t size
Size of the Mailbox.
int msg_flagged
Number of flagged messages.
void * compress_info
Compressed mbox module private data.
bool readonly
Don't allow changes to the mailbox.
int msg_tagged
How many messages are tagged?
int msg_unread
Number of unread messages.
Multibyte character table.
int len
Number of characters.
char ** chars
The array of multibyte character strings.
Container for Accounts, Notifications.
struct ConfigSubset * sub
Inherited config items.
@ ED_GLO_CONFIG_USE_THREADS
Value of $use_threads.
@ ED_GLO_CONFIG_SORT
Value of $sort.
@ ED_GLO_VERSION
NeoMutt version.
@ ED_GLO_CONFIG_SORT_AUX
Value of $sort_aux.
@ ED_GLO_HOSTNAME
Local hostname.