NeoMutt  2024-04-16-36-g75b6fb
Teaching an old dog new tricks
DOXYGEN
Loading...
Searching...
No Matches
Expando Get Number API

Get some numeric data. More...

+ Collaboration diagram for Expando Get Number API:

Functions

long alias_f_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Alias: Flags - Implements ExpandoRenderData::get_number() -.
 
long alias_n_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Alias: Index number - Implements ExpandoRenderData::get_number() -.
 
long alias_t_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Alias: Tagged char - Implements ExpandoRenderData::get_number() -.
 
long query_c_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Query: Index number - Implements ExpandoRenderData::get_number() -.
 
long query_t_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Query: Tagged char - Implements ExpandoRenderData::get_number() -.
 
long attach_D_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Attachment: Deleted - Implements ExpandoRenderData::get_number() -.
 
long attach_n_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Attachment: Index number - Implements ExpandoRenderData::get_number() -.
 
long attach_Q_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Attachment: Attachment counting - Implements ExpandoRenderData::get_number() -.
 
long attach_s_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Attachment: Size - Implements ExpandoRenderData::get_number() -.
 
long attach_t_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Attachment: Is Tagged - Implements ExpandoRenderData::get_number() -.
 
long attach_u_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Attachment: Unlink flag - Implements ExpandoRenderData::get_number() -.
 
long attach_X_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Attachment: Number of MIME parts - Implements ExpandoRenderData::get_number() -.
 
long autocrypt_n_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Autocrypt: Index number - Implements ExpandoRenderData::get_number() -.
 
long folder_date_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Browser: Last modified (strftime) - Implements ExpandoRenderData::get_number() -.
 
long folder_a_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Browser: Alert for new mail - Implements ExpandoRenderData::get_number() -.
 
long folder_C_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Browser: Index number - Implements ExpandoRenderData::get_number() -.
 
long folder_d_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Browser: Last modified - Implements ExpandoRenderData::get_number() -.
 
long folder_D_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Browser: Last modified ($date_format) - Implements ExpandoRenderData::get_number() -.
 
long folder_l_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Browser: Hard links - Implements ExpandoRenderData::get_number() -.
 
long folder_m_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Browser: Number of messages - Implements ExpandoRenderData::get_number() -.
 
long folder_n_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Browser: Number of unread messages - Implements ExpandoRenderData::get_number() -.
 
long folder_N_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Browser: New mail flag - Implements ExpandoRenderData::get_number() -.
 
long folder_p_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Browser: Poll for new mail - Implements ExpandoRenderData::get_number() -.
 
long folder_s_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Browser: Size in bytes - Implements ExpandoRenderData::get_number() -.
 
long folder_t_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Browser: Is Tagged - Implements ExpandoRenderData::get_number() -.
 
long compose_a_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Compose: Number of attachments - Implements ExpandoRenderData::get_number() -.
 
long compose_l_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Compose: Size in bytes - Implements ExpandoRenderData::get_number() -.
 
long index_date_recv_local_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Index: Local received date and time - Implements ExpandoRenderData::get_number() -.
 
long index_date_local_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Index: Local date and time - Implements ExpandoRenderData::get_number() -.
 
long index_date_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Index: Sender's date and time - Implements ExpandoRenderData::get_number() -.
 
long index_c_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Index: Number of bytes - Implements ExpandoRenderData::get_number() -.
 
long index_C_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Index: Index number - Implements ExpandoRenderData::get_number() -.
 
long index_d_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Index: Senders Date and time - Implements ExpandoRenderData::get_number() -.
 
long index_D_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Index: Local Date and time - Implements ExpandoRenderData::get_number() -.
 
long index_e_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Index: Thread index number - Implements ExpandoRenderData::get_number() -.
 
long index_E_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Index: Number of messages thread - Implements ExpandoRenderData::get_number() -.
 
long index_l_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Index: Number of lines - Implements ExpandoRenderData::get_number() -.
 
long index_m_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Index: Total number of message - Implements ExpandoRenderData::get_number() -.
 
long index_M_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Index: Number of hidden messages - Implements ExpandoRenderData::get_number() -.
 
long index_N_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Index: Message score - Implements ExpandoRenderData::get_number() -.
 
long index_X_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Index: Number of MIME attachments - Implements ExpandoRenderData::get_number() -.
 
long history_C_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 History: Index number - Implements ExpandoRenderData::get_number() -.
 
long mix_n_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Mixmaster: Index number - Implements ExpandoRenderData::get_number() -.
 
long pgp_entry_gpgme_date_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 GPGME: Date of the key - Implements ExpandoRenderData::get_number() -.
 
long pgp_entry_gpgme_n_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 GPGME: Index number - Implements ExpandoRenderData::get_number() -.
 
long pgp_entry_gpgme_l_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 GPGME: Key length - Implements ExpandoRenderData::get_number() -.
 
long pgp_entry_pgp_date_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 PGP: Date of the key - Implements ExpandoRenderData::get_number() -.
 
long pgp_entry_pgp_n_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 PGP: Index number - Implements ExpandoRenderData::get_number() -.
 
long pgp_entry_pgp_l_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 PGP: Key length - Implements ExpandoRenderData::get_number() -.
 
long pgp_entry_pgp_L_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 PGP: Principal Key length - Implements ExpandoRenderData::get_number() -.
 
long group_index_a_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 NNTP: Alert for new mail - Implements ExpandoRenderData::get_number() -.
 
long group_index_C_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 NNTP: Index number - Implements ExpandoRenderData::get_number() -.
 
long group_index_n_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 NNTP: Number of new articles - Implements ExpandoRenderData::get_number() -.
 
long group_index_p_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 NNTP: Poll for new mail - Implements ExpandoRenderData::get_number() -.
 
long group_index_s_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 NNTP: Number of unread articles - Implements ExpandoRenderData::get_number() -.
 
long nntp_p_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Newsrc: Port - Implements ExpandoRenderData::get_number() -.
 
long nntp_P_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Newsrc: Port if specified - Implements ExpandoRenderData::get_number() -.
 
long pattern_n_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Pattern: Index number - Implements ExpandoRenderData::get_number() -.
 
long sidebar_a_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Sidebar: Alert for new mail - Implements ExpandoRenderData::get_number() -.
 
long sidebar_d_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Sidebar: Number of deleted messages - Implements ExpandoRenderData::get_number() -.
 
long sidebar_F_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Sidebar: Number of flagged messages - Implements ExpandoRenderData::get_number() -.
 
long sidebar_L_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Sidebar: Number of limited messages - Implements ExpandoRenderData::get_number() -.
 
long sidebar_n_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Sidebar: New mail flag - Implements ExpandoRenderData::get_number() -.
 
long sidebar_N_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Sidebar: Number of unread messages - Implements ExpandoRenderData::get_number() -.
 
long sidebar_o_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Sidebar: Number of old messages - Implements ExpandoRenderData::get_number() -.
 
long sidebar_p_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Sidebar: Poll for new mail - Implements ExpandoRenderData::get_number() -.
 
long sidebar_r_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Sidebar: Number of read messages - Implements ExpandoRenderData::get_number() -.
 
long sidebar_S_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Sidebar: number of messages - Implements ExpandoRenderData::get_number() -.
 
long sidebar_t_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Sidebar: Number of tagged messages - Implements ExpandoRenderData::get_number() -.
 
long sidebar_Z_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Sidebar: Number of new messages - Implements ExpandoRenderData::get_number() -.
 
long status_M_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Status: Number of messages - Implements ExpandoRenderData::get_number() -.
 
long status_m_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Status: Number of messages in the mailbox - Implements ExpandoRenderData::get_number() -.
 
long status_n_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Status: Number of new messages - Implements ExpandoRenderData::get_number() -.
 
long status_o_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Status: Number of old messages - Implements ExpandoRenderData::get_number() -.
 
long status_d_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Status: Number of deleted messages - Implements ExpandoRenderData::get_number() -.
 
long status_F_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Status: Number of flagged messages - Implements ExpandoRenderData::get_number() -.
 
long status_t_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Status: Number of tagged messages - Implements ExpandoRenderData::get_number() -.
 
long status_p_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Status: Number of postponed messages - Implements ExpandoRenderData::get_number() -.
 
long status_b_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Status: Number of mailboxes with new mail - Implements ExpandoRenderData::get_number() -.
 
long status_l_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Status: Size of the current mailbox - Implements ExpandoRenderData::get_number() -.
 
long status_P_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Status: Percentage through index - Implements ExpandoRenderData::get_number() -.
 
long status_L_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Status: Size of the messages - Implements ExpandoRenderData::get_number() -.
 
long status_R_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Status: Number of read messages - Implements ExpandoRenderData::get_number() -.
 
long status_u_num (const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
 Status: Number of unread messages - Implements ExpandoRenderData::get_number() -.
 

Detailed Description

Get some numeric data.

Parameters
[in]nodeExpandoNode containing the callback
[in]dataPrivate data
[in]flagsFlags, see MuttFormatFlags
Return values
numData as a number

Get some numeric data to be formatted.

Function Documentation

◆ alias_f_num()

long alias_f_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Alias: Flags - Implements ExpandoRenderData::get_number() -.

Definition at line 142 of file dlg_alias.c.

143{
144 const struct AliasView *av = data;
145 return av->is_deleted;
146}
GUI data wrapping an Alias.
Definition: gui.h:38
bool is_deleted
Is it deleted?
Definition: gui.h:44

◆ alias_n_num()

long alias_n_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Alias: Index number - Implements ExpandoRenderData::get_number() -.

Definition at line 164 of file dlg_alias.c.

165{
166 const struct AliasView *av = data;
167
168 return av->num + 1;
169}
int num
Index number in list.
Definition: gui.h:39

◆ alias_t_num()

long alias_t_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Alias: Tagged char - Implements ExpandoRenderData::get_number() -.

Definition at line 186 of file dlg_alias.c.

187{
188 const struct AliasView *av = data;
189 return av->is_tagged;
190}
bool is_tagged
Is it tagged?
Definition: gui.h:43

◆ query_c_num()

long query_c_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Query: Index number - Implements ExpandoRenderData::get_number() -.

Definition at line 160 of file dlg_query.c.

161{
162 const struct AliasView *av = data;
163
164 return av->num + 1;
165}

◆ query_t_num()

long query_t_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Query: Tagged char - Implements ExpandoRenderData::get_number() -.

Definition at line 196 of file dlg_query.c.

197{
198 const struct AliasView *av = data;
199 return av->is_tagged;
200}

◆ attach_D_num()

long attach_D_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Attachment: Deleted - Implements ExpandoRenderData::get_number() -.

Definition at line 200 of file dlg_attach.c.

201{
202 const struct AttachPtr *aptr = data;
203 return aptr->body->deleted;
204}
An email to which things will be attached.
Definition: attach.h:37
struct Body * body
Attachment.
Definition: attach.h:38
bool deleted
Attachment marked for deletion.
Definition: body.h:87

◆ attach_n_num()

long attach_n_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Attachment: Index number - Implements ExpandoRenderData::get_number() -.

Definition at line 325 of file dlg_attach.c.

326{
327 const struct AttachPtr *aptr = data;
328
329 return aptr->num + 1;
330}
int num
Attachment index number.
Definition: attach.h:43

◆ attach_Q_num()

long attach_Q_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Attachment: Attachment counting - Implements ExpandoRenderData::get_number() -.

Definition at line 335 of file dlg_attach.c.

336{
337 const struct AttachPtr *aptr = data;
338 return aptr->body->attach_qualifies;
339}
bool attach_qualifies
This attachment should be counted.
Definition: body.h:86

◆ attach_s_num()

long attach_s_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Attachment: Size - Implements ExpandoRenderData::get_number() -.

Definition at line 357 of file dlg_attach.c.

358{
359 const struct AttachPtr *aptr = data;
360
361 if (aptr->body->filename && (flags & MUTT_FORMAT_STAT_FILE))
362 return mutt_file_get_size(aptr->body->filename);
363
364 return aptr->body->length;
365}
long mutt_file_get_size(const char *path)
Get the size of a file.
Definition: file.c:1516
#define MUTT_FORMAT_STAT_FILE
Used by attach_format_str.
Definition: render.h:36
LOFF_T length
length (in bytes) of attachment
Definition: body.h:53
char * filename
When sending a message, this is the file to which this structure refers.
Definition: body.h:58
+ Here is the call graph for this function:

◆ attach_t_num()

long attach_t_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Attachment: Is Tagged - Implements ExpandoRenderData::get_number() -.

Definition at line 394 of file dlg_attach.c.

395{
396 const struct AttachPtr *aptr = data;
397 return aptr->body->tagged;
398}
bool tagged
This attachment is tagged.
Definition: body.h:89

◆ attach_u_num()

long attach_u_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Attachment: Unlink flag - Implements ExpandoRenderData::get_number() -.

Definition at line 430 of file dlg_attach.c.

431{
432 const struct AttachPtr *aptr = data;
433 return aptr->body->unlink;
434}
bool unlink
If true, filename should be unlink()ed before free()ing this structure.
Definition: body.h:67

◆ attach_X_num()

long attach_X_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Attachment: Number of MIME parts - Implements ExpandoRenderData::get_number() -.

Definition at line 452 of file dlg_attach.c.

453{
454 const struct AttachPtr *aptr = data;
455 const struct Body *body = aptr->body;
456
457 return body->attach_count + body->attach_qualifies;
458}
The body of an email.
Definition: body.h:36
signed short attach_count
Number of attachments.
Definition: body.h:90
struct AttachPtr * aptr
Menu information, used in recvattach.c.
Definition: body.h:74

◆ autocrypt_n_num()

long autocrypt_n_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Autocrypt: Index number - Implements ExpandoRenderData::get_number() -.

Definition at line 140 of file dlg_autocrypt.c.

141{
142 const struct AccountEntry *entry = data;
143
144 return entry->num;
145}
An entry in the Autocrypt account Menu.
Definition: private.h:45
int num
Number in the index.
Definition: private.h:46

◆ folder_date_num()

long folder_date_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Browser: Last modified (strftime) - Implements ExpandoRenderData::get_number() -.

Definition at line 195 of file dlg_browser.c.

196{
197 const struct Folder *folder = data;
198
199 if (!folder->ff->local)
200 return 0;
201
202 return folder->ff->mtime;
203}
time_t mtime
Modification time.
Definition: lib.h:81
A folder/dir in the browser.
Definition: lib.h:69
struct FolderFile * ff
File / Dir / Mailbox.
Definition: lib.h:70

◆ folder_a_num()

long folder_a_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Browser: Alert for new mail - Implements ExpandoRenderData::get_number() -.

Definition at line 256 of file dlg_browser.c.

257{
258 const struct Folder *folder = data;
259
260 return folder->ff->notify_user;
261}
bool notify_user
User will be notified of new mail.
Definition: lib.h:100

◆ folder_C_num()

long folder_C_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Browser: Index number - Implements ExpandoRenderData::get_number() -.

Definition at line 266 of file dlg_browser.c.

267{
268 const struct Folder *folder = data;
269
270 return folder->num + 1;
271}
int num
Number in the index.
Definition: lib.h:71

◆ folder_d_num()

long folder_d_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Browser: Last modified - Implements ExpandoRenderData::get_number() -.

Definition at line 276 of file dlg_browser.c.

277{
278 const struct Folder *folder = data;
279 if (!folder->ff->local)
280 return 0;
281
282 return folder->ff->mtime;
283}

◆ folder_D_num()

long folder_D_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Browser: Last modified ($date_format) - Implements ExpandoRenderData::get_number() -.

Definition at line 310 of file dlg_browser.c.

311{
312 const struct Folder *folder = data;
313 if (!folder->ff->local)
314 return 0;
315
316 return folder->ff->mtime;
317}

◆ folder_l_num()

long folder_l_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Browser: Hard links - Implements ExpandoRenderData::get_number() -.

Definition at line 455 of file dlg_browser.c.

456{
457 const struct Folder *folder = data;
458
459 if (folder->ff->local)
460 return folder->ff->nlink;
461
462 return 0;
463}
nlink_t nlink
Number of hard links.
Definition: lib.h:84

◆ folder_m_num()

long folder_m_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Browser: Number of messages - Implements ExpandoRenderData::get_number() -.

Definition at line 481 of file dlg_browser.c.

482{
483 const struct Folder *folder = data;
484
485 if (folder->ff->has_mailbox)
486 return folder->ff->msg_count;
487
488 return 0;
489}
bool has_mailbox
This is a mailbox.
Definition: lib.h:98
int msg_count
total number of messages
Definition: lib.h:90

◆ folder_n_num()

long folder_n_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Browser: Number of unread messages - Implements ExpandoRenderData::get_number() -.

Definition at line 507 of file dlg_browser.c.

508{
509 const struct Folder *folder = data;
510
511 if (folder->ff->has_mailbox)
512 return folder->ff->msg_unread;
513
514 return 0;
515}
int msg_unread
number of unread messages
Definition: lib.h:91

◆ folder_N_num()

long folder_N_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Browser: New mail flag - Implements ExpandoRenderData::get_number() -.

Definition at line 533 of file dlg_browser.c.

534{
535 const struct Folder *folder = data;
536 return folder->ff->has_new_mail;
537}
bool has_new_mail
true if mailbox has "new mail"
Definition: lib.h:89

◆ folder_p_num()

long folder_p_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Browser: Poll for new mail - Implements ExpandoRenderData::get_number() -.

Definition at line 555 of file dlg_browser.c.

556{
557 const struct Folder *folder = data;
558
559 return folder->ff->poll_new_mail;
560}
bool poll_new_mail
Check mailbox for new mail.
Definition: lib.h:101

◆ folder_s_num()

long folder_s_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Browser: Size in bytes - Implements ExpandoRenderData::get_number() -.

Definition at line 565 of file dlg_browser.c.

566{
567 const struct Folder *folder = data;
568 return folder->ff->size;
569}
off_t size
File size.
Definition: lib.h:80

◆ folder_t_num()

long folder_t_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Browser: Is Tagged - Implements ExpandoRenderData::get_number() -.

Definition at line 588 of file dlg_browser.c.

589{
590 const struct Folder *folder = data;
591 return folder->ff->tagged;
592}
bool tagged
Folder is tagged.
Definition: lib.h:102

◆ compose_a_num()

long compose_a_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Compose: Number of attachments - Implements ExpandoRenderData::get_number() -.

Definition at line 98 of file cbar.c.

99{
100 const struct ComposeSharedData *shared = data;
101
102 return num_attachments(shared->adata);
103}
static int num_attachments(const struct ComposeAttachData *adata)
Count the number of attachments.
Definition: cbar.c:88
Shared Compose Data.
Definition: shared_data.h:35
struct ComposeAttachData * adata
Attachments.
Definition: shared_data.h:39
+ Here is the call graph for this function:

◆ compose_l_num()

long compose_l_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Compose: Size in bytes - Implements ExpandoRenderData::get_number() -.

Definition at line 118 of file cbar.c.

119{
120 const struct ComposeSharedData *shared = data;
121 return cum_attachs_size(shared->sub, shared->adata);
122}
unsigned long cum_attachs_size(struct ConfigSubset *sub, struct ComposeAttachData *adata)
Cumulative Attachments Size.
Definition: attach.c:84
struct ConfigSubset * sub
Config set to use.
Definition: shared_data.h:36
+ Here is the call graph for this function:

◆ index_date_recv_local_num()

long index_date_recv_local_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Index: Local received date and time - Implements ExpandoRenderData::get_number() -.

Definition at line 308 of file hdrline.c.

309{
310 const struct HdrFormatInfo *hfi = data;
311 const struct Email *e = hfi->email;
312 if (!e)
313 return 0;
314
315 return e->received;
316}
The envelope/body of an email.
Definition: email.h:39
time_t received
Time when the message was placed in the mailbox.
Definition: email.h:61
Data passed to index_format_str()
Definition: hdrline.c:72
struct Email * email
Current Email.
Definition: hdrline.c:75

◆ index_date_local_num()

long index_date_local_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Index: Local date and time - Implements ExpandoRenderData::get_number() -.

Definition at line 364 of file hdrline.c.

365{
366 const struct HdrFormatInfo *hfi = data;
367 const struct Email *e = hfi->email;
368 if (!e)
369 return 0;
370
371 return e->date_sent;
372}
time_t date_sent
Time when the message was sent (UTC)
Definition: email.h:60

◆ index_date_num()

long index_date_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Index: Sender's date and time - Implements ExpandoRenderData::get_number() -.

Definition at line 420 of file hdrline.c.

421{
422 const struct HdrFormatInfo *hfi = data;
423 const struct Email *e = hfi->email;
424 if (!e)
425 return 0;
426
427 return e->date_sent;
428}

◆ index_c_num()

long index_c_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Index: Number of bytes - Implements ExpandoRenderData::get_number() -.

Definition at line 613 of file hdrline.c.

614{
615 const struct HdrFormatInfo *hfi = data;
616 const struct Email *e = hfi->email;
617 if (!e || !e->body)
618 return 0;
619
620 return e->body->length;
621}
struct Body * body
List of MIME parts.
Definition: email.h:69

◆ index_C_num()

long index_C_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Index: Index number - Implements ExpandoRenderData::get_number() -.

Definition at line 666 of file hdrline.c.

667{
668 const struct HdrFormatInfo *hfi = data;
669 const struct Email *e = hfi->email;
670 if (!e)
671 return 0;
672
673 if (flags & MUTT_FORMAT_INDEX)
675
676 return e->msgno + 1;
677}
@ MT_COLOR_INDEX_NUMBER
Index: index number.
Definition: color.h:89
void node_expando_set_color(const struct ExpandoNode *node, int cid)
Set the colour for an Expando.
Definition: node_expando.c:107
#define MUTT_FORMAT_INDEX
This is a main index entry.
Definition: render.h:38
int msgno
Number displayed to the user.
Definition: email.h:114
+ Here is the call graph for this function:

◆ index_d_num()

long index_d_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Index: Senders Date and time - Implements ExpandoRenderData::get_number() -.

Definition at line 682 of file hdrline.c.

683{
684 const struct HdrFormatInfo *hfi = data;
685 const struct Email *e = hfi->email;
686 if (!e)
687 return 0;
688
689 return e->date_sent;
690}

◆ index_D_num()

long index_D_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Index: Local Date and time - Implements ExpandoRenderData::get_number() -.

Definition at line 740 of file hdrline.c.

741{
742 const struct HdrFormatInfo *hfi = data;
743 const struct Email *e = hfi->email;
744 if (!e)
745 return 0;
746
747 return e->date_sent;
748}

◆ index_e_num()

long index_e_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Index: Thread index number - Implements ExpandoRenderData::get_number() -.

Definition at line 791 of file hdrline.c.

792{
793 const struct HdrFormatInfo *hfi = data;
794 struct Email *e = hfi->email;
795 struct Mailbox *m = hfi->mailbox;
796
798}
int mutt_messages_in_thread(struct Mailbox *m, struct Email *e, enum MessageInThread mit)
Count the messages in a thread.
Definition: mutt_thread.c:1658
@ MIT_POSITION
Our position in the thread.
Definition: mutt_thread.h:90
struct Mailbox * mailbox
Current Mailbox.
Definition: hdrline.c:73
A mailbox.
Definition: mailbox.h:79
+ Here is the call graph for this function:

◆ index_E_num()

long index_E_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Index: Number of messages thread - Implements ExpandoRenderData::get_number() -.

Definition at line 803 of file hdrline.c.

804{
805 const struct HdrFormatInfo *hfi = data;
806 struct Email *e = hfi->email;
807 struct Mailbox *m = hfi->mailbox;
808
810}
@ MIT_NUM_MESSAGES
How many messages are in the thread.
Definition: mutt_thread.h:89
+ Here is the call graph for this function:

◆ index_l_num()

long index_l_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Index: Number of lines - Implements ExpandoRenderData::get_number() -.

Definition at line 1035 of file hdrline.c.

1036{
1037 const struct HdrFormatInfo *hfi = data;
1038 const struct Email *e = hfi->email;
1039 if (!e)
1040 return 0;
1041
1042 if (flags & MUTT_FORMAT_INDEX)
1044
1045 return e->lines;
1046}
@ MT_COLOR_INDEX_SIZE
Index: size field.
Definition: color.h:90
int lines
How many lines in the body of this message?
Definition: email.h:62
+ Here is the call graph for this function:

◆ index_m_num()

long index_m_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Index: Total number of message - Implements ExpandoRenderData::get_number() -.

Definition at line 1071 of file hdrline.c.

1072{
1073 const struct HdrFormatInfo *hfi = data;
1074 const struct Mailbox *m = hfi->mailbox;
1075
1076 if (m)
1077 return m->msg_count;
1078
1079 return 0;
1080}
int msg_count
Total number of messages.
Definition: mailbox.h:88

◆ index_M_num()

long index_M_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Index: Number of hidden messages - Implements ExpandoRenderData::get_number() -.

Definition at line 1115 of file hdrline.c.

1116{
1117 const struct HdrFormatInfo *hfi = data;
1118 const struct Email *e = hfi->email;
1119 if (!e)
1120 return 0;
1121
1122 const bool threads = mutt_using_threads();
1123 const bool is_index = (flags & MUTT_FORMAT_INDEX) != 0;
1124
1125 if (threads && is_index && e->collapsed && (e->num_hidden > 1))
1126 {
1127 if (flags & MUTT_FORMAT_INDEX)
1129 return e->num_hidden;
1130 }
1131
1132 return 0;
1133}
@ MT_COLOR_INDEX_COLLAPSED
Index: number of messages in collapsed thread.
Definition: color.h:85
#define mutt_using_threads()
Definition: mutt_thread.h:114
bool collapsed
Is this message part of a collapsed thread?
Definition: email.h:123
size_t num_hidden
Number of hidden messages in this view (only valid when collapsed is set)
Definition: email.h:126
+ Here is the call graph for this function:

◆ index_N_num()

long index_N_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Index: Message score - Implements ExpandoRenderData::get_number() -.

Definition at line 1158 of file hdrline.c.

1159{
1160 const struct HdrFormatInfo *hfi = data;
1161 const struct Email *e = hfi->email;
1162 if (!e)
1163 return 0;
1164
1165 return e->score;
1166}
int score
Message score.
Definition: email.h:116

◆ index_X_num()

long index_X_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Index: Number of MIME attachments - Implements ExpandoRenderData::get_number() -.

Definition at line 1488 of file hdrline.c.

1489{
1490 const struct HdrFormatInfo *hfi = data;
1491 struct Email *e = hfi->email;
1492 if (!e)
1493 return 0;
1494
1495 struct Mailbox *m = hfi->mailbox;
1496
1497 struct Message *msg = mx_msg_open(m, e);
1498 if (!msg)
1499 return 0;
1500
1501 const int num = mutt_count_body_parts(m, e, msg->fp);
1502 mx_msg_close(m, &msg);
1503 return num;
1504}
int mutt_count_body_parts(const struct Mailbox *m, struct Email *e, FILE *fp)
Count the MIME Body parts.
Definition: attachments.c:252
int mx_msg_close(struct Mailbox *m, struct Message **ptr)
Close a message.
Definition: mx.c:1178
struct Message * mx_msg_open(struct Mailbox *m, struct Email *e)
Return a stream pointer for a message.
Definition: mx.c:1132
A local copy of an email.
Definition: message.h:34
FILE * fp
pointer to the message data
Definition: message.h:35
+ Here is the call graph for this function:

◆ history_C_num()

long history_C_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

History: Index number - Implements ExpandoRenderData::get_number() -.

Definition at line 89 of file dlg_history.c.

90{
91 const struct HistoryEntry *entry = data;
92
93 return entry->num + 1;
94}
A line in the History menu.
Definition: lib.h:65
int num
Index number.
Definition: lib.h:66

◆ mix_n_num()

long mix_n_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Mixmaster: Index number - Implements ExpandoRenderData::get_number() -.

Definition at line 137 of file win_hosts.c.

138{
139 const struct Remailer *remailer = data;
140
141 return remailer->num;
142}
A Mixmaster remailer.
Definition: remailer.h:40
int num
Index number.
Definition: remailer.h:41

◆ pgp_entry_gpgme_date_num()

long pgp_entry_gpgme_date_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

GPGME: Date of the key - Implements ExpandoRenderData::get_number() -.

Definition at line 290 of file dlg_gpgme.c.

291{
292#ifdef HAVE_PKG_GPGME
293 const struct CryptEntry *entry = data;
294 const struct CryptKeyInfo *key = entry->key;
295 return key->kobj->subkeys->timestamp;
296#endif
297 return 0;
298}
An entry in the Select-Key menu.
Definition: crypt_gpgme.h:85
struct CryptKeyInfo * key
Key.
Definition: crypt_gpgme.h:87
A stored PGP key.
Definition: crypt_gpgme.h:44
gpgme_key_t kobj
Definition: crypt_gpgme.h:46

◆ pgp_entry_gpgme_n_num()

long pgp_entry_gpgme_n_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

GPGME: Index number - Implements ExpandoRenderData::get_number() -.

Definition at line 352 of file dlg_gpgme.c.

353{
354#ifdef HAVE_PKG_GPGME
355 const struct CryptEntry *entry = data;
356 return entry->num;
357#else
358 return 0;
359#endif
360}
size_t num
Index number.
Definition: crypt_gpgme.h:86

◆ pgp_entry_gpgme_l_num()

long pgp_entry_gpgme_l_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

GPGME: Key length - Implements ExpandoRenderData::get_number() -.

Definition at line 524 of file dlg_gpgme.c.

525{
526#ifdef HAVE_PKG_GPGME
527 const struct CryptEntry *entry = data;
528 const struct CryptKeyInfo *key = entry->key;
529
530 return key->kobj->subkeys ? key->kobj->subkeys->length : 0;
531#else
532 return 0;
533#endif
534}

◆ pgp_entry_pgp_date_num()

long pgp_entry_pgp_date_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

PGP: Date of the key - Implements ExpandoRenderData::get_number() -.

Definition at line 256 of file dlg_pgp.c.

257{
258#ifdef HAVE_PGP
259 const struct PgpEntry *entry = data;
260 const struct PgpUid *uid = entry->uid;
261 const struct PgpKeyInfo *key = uid->parent;
262
263 return key->gen_time;
264#endif
265 return 0;
266}
An entry in a PGP key menu.
Definition: private.h:39
struct PgpUid * uid
PGP Key info.
Definition: private.h:41
Information about a PGP key.
Definition: pgplib.h:47
time_t gen_time
Definition: pgplib.h:53
PGP User ID.
Definition: pgplib.h:35
struct PgpKeyInfo * parent
Parent key.
Definition: pgplib.h:39

◆ pgp_entry_pgp_n_num()

long pgp_entry_pgp_n_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

PGP: Index number - Implements ExpandoRenderData::get_number() -.

Definition at line 312 of file dlg_pgp.c.

313{
314#ifdef HAVE_PGP
315 const struct PgpEntry *entry = data;
316 return entry->num;
317#else
318 return 0;
319#endif
320}
size_t num
Index number.
Definition: private.h:40

◆ pgp_entry_pgp_l_num()

long pgp_entry_pgp_l_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

PGP: Key length - Implements ExpandoRenderData::get_number() -.

Definition at line 492 of file dlg_pgp.c.

493{
494#ifdef HAVE_PGP
495 const struct PgpEntry *entry = data;
496 const struct PgpUid *uid = entry->uid;
497 const struct PgpKeyInfo *key = uid->parent;
498
499 return key->keylen;
500#else
501 return 0;
502#endif
503}
short keylen
Definition: pgplib.h:52

◆ pgp_entry_pgp_L_num()

long pgp_entry_pgp_L_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

PGP: Principal Key length - Implements ExpandoRenderData::get_number() -.

Definition at line 508 of file dlg_pgp.c.

509{
510#ifdef HAVE_PGP
511 const struct PgpEntry *entry = data;
512 const struct PgpUid *uid = entry->uid;
513 struct PgpKeyInfo *key = uid->parent;
514 struct PgpKeyInfo *pkey = pgp_principal_key(key);
515
516 return pkey->keylen;
517#else
518 return 0;
519#endif
520}
struct PgpKeyInfo * pgp_principal_key(struct PgpKeyInfo *key)
Get the main (parent) PGP key.
Definition: pgpkey.c:91
+ Here is the call graph for this function:

◆ group_index_a_num()

long group_index_a_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

NNTP: Alert for new mail - Implements ExpandoRenderData::get_number() -.

Definition at line 45 of file browse.c.

46{
47 const struct Folder *folder = data;
48
49 return folder->ff->notify_user;
50}

◆ group_index_C_num()

long group_index_C_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

NNTP: Index number - Implements ExpandoRenderData::get_number() -.

Definition at line 55 of file browse.c.

56{
57 const struct Folder *folder = data;
58
59 return folder->num + 1;
60}

◆ group_index_n_num()

long group_index_n_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

NNTP: Number of new articles - Implements ExpandoRenderData::get_number() -.

Definition at line 125 of file browse.c.

126{
127 const struct Folder *folder = data;
128 const struct NntpMboxData *nd = folder->ff->nd;
129
130 const bool c_mark_old = cs_subset_bool(NeoMutt->sub, "mark_old");
131
132 if (c_mark_old && (nd->last_cached >= nd->first_message) &&
133 (nd->last_cached <= nd->last_message))
134 {
135 return nd->last_message - nd->last_cached;
136 }
137
138 return nd->unread;
139}
bool cs_subset_bool(const struct ConfigSubset *sub, const char *name)
Get a boolean config item by name.
Definition: helpers.c:48
struct NntpMboxData * nd
Extra NNTP data.
Definition: lib.h:103
Container for Accounts, Notifications.
Definition: neomutt.h:41
struct ConfigSubset * sub
Inherited config items.
Definition: neomutt.h:45
NNTP-specific Mailbox data -.
Definition: mdata.h:34
anum_t last_cached
Definition: mdata.h:40
anum_t last_message
Definition: mdata.h:38
anum_t unread
Definition: mdata.h:41
anum_t first_message
Definition: mdata.h:37
+ Here is the call graph for this function:

◆ group_index_p_num()

long group_index_p_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

NNTP: Poll for new mail - Implements ExpandoRenderData::get_number() -.

Definition at line 166 of file browse.c.

167{
168 const struct Folder *folder = data;
169
170 return folder->ff->poll_new_mail;
171}

◆ group_index_s_num()

long group_index_s_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

NNTP: Number of unread articles - Implements ExpandoRenderData::get_number() -.

Definition at line 176 of file browse.c.

177{
178 const struct Folder *folder = data;
179
180 // NOTE(g0mb4): is long required for unread?
181 return folder->ff->nd->unread;
182}

◆ nntp_p_num()

long nntp_p_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Newsrc: Port - Implements ExpandoRenderData::get_number() -.

Definition at line 940 of file newsrc.c.

941{
942 const struct NntpAccountData *adata = data;
943 const struct ConnAccount *cac = &adata->conn->account;
944
945 return cac->port;
946}
void * adata
Private data (for Mailbox backends)
Definition: account.h:42
Login details for a remote server.
Definition: connaccount.h:53
unsigned short port
Port to connect to.
Definition: connaccount.h:58
struct ConnAccount account
Account details: username, password, etc.
Definition: connection.h:49
NNTP-specific Account data -.
Definition: adata.h:36
struct Connection * conn
Connection to NNTP Server.
Definition: adata.h:62

◆ nntp_P_num()

long nntp_P_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Newsrc: Port if specified - Implements ExpandoRenderData::get_number() -.

Definition at line 951 of file newsrc.c.

952{
953 const struct NntpAccountData *adata = data;
954 const struct ConnAccount *cac = &adata->conn->account;
955
956 if (cac->flags & MUTT_ACCT_PORT)
957 return cac->port;
958
959 return 0;
960}
#define MUTT_ACCT_PORT
Port field has been set.
Definition: connaccount.h:43
MuttAccountFlags flags
Which fields are initialised, e.g. MUTT_ACCT_USER.
Definition: connaccount.h:60

◆ pattern_n_num()

long pattern_n_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Pattern: Index number - Implements ExpandoRenderData::get_number() -.

Definition at line 124 of file dlg_pattern.c.

125{
126 const struct PatternEntry *entry = data;
127
128 return entry->num;
129}
A line in the Pattern Completion menu.
Definition: private.h:37
int num
Index number.
Definition: private.h:38

◆ sidebar_a_num()

long sidebar_a_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Sidebar: Alert for new mail - Implements ExpandoRenderData::get_number() -.

Definition at line 361 of file window.c.

362{
363 const struct SidebarData *sdata = data;
364 const struct SbEntry *sbe = sdata->entry;
365 const struct Mailbox *m = sbe->mailbox;
366
367 return m->notify_user;
368}
bool notify_user
Notify the user of new mail.
Definition: mailbox.h:113
Info about folders in the sidebar.
Definition: private.h:41
struct Mailbox * mailbox
Mailbox this represents.
Definition: private.h:45
Data passed to sidebar_format_str()
Definition: window.c:89
struct SbEntry * entry
Info about a folder.
Definition: window.c:90

◆ sidebar_d_num()

long sidebar_d_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Sidebar: Number of deleted messages - Implements ExpandoRenderData::get_number() -.

Definition at line 391 of file window.c.

392{
393 const struct SidebarData *sdata = data;
394 const struct SbEntry *sbe = sdata->entry;
395 const struct IndexSharedData *shared = sdata->shared;
396 const struct Mailbox *m = sbe->mailbox;
397 const struct Mailbox *m_cur = shared->mailbox;
398
399 const bool c = m_cur && mutt_str_equal(m_cur->realpath, m->realpath);
400
401 return c ? m_cur->msg_deleted : 0;
402}
bool mutt_str_equal(const char *a, const char *b)
Compare two strings.
Definition: string.c:654
Data shared between Index, Pager and Sidebar.
Definition: shared_data.h:37
struct Mailbox * mailbox
Current Mailbox.
Definition: shared_data.h:41
char * realpath
Used for duplicate detection, context comparison, and the sidebar.
Definition: mailbox.h:81
int msg_deleted
Number of deleted messages.
Definition: mailbox.h:93
struct IndexSharedData * shared
Shared Index Data.
Definition: window.c:91
+ Here is the call graph for this function:

◆ sidebar_F_num()

long sidebar_F_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Sidebar: Number of flagged messages - Implements ExpandoRenderData::get_number() -.

Definition at line 433 of file window.c.

434{
435 const struct SidebarData *sdata = data;
436 const struct SbEntry *sbe = sdata->entry;
437 const struct Mailbox *m = sbe->mailbox;
438
439 return m->msg_flagged;
440}
int msg_flagged
Number of flagged messages.
Definition: mailbox.h:90

◆ sidebar_L_num()

long sidebar_L_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Sidebar: Number of limited messages - Implements ExpandoRenderData::get_number() -.

Definition at line 445 of file window.c.

446{
447 const struct SidebarData *sdata = data;
448 const struct SbEntry *sbe = sdata->entry;
449 const struct IndexSharedData *shared = sdata->shared;
450 const struct Mailbox *m = sbe->mailbox;
451 const struct Mailbox *m_cur = shared->mailbox;
452
453 const bool c = m_cur && mutt_str_equal(m_cur->realpath, m->realpath);
454
455 return c ? m_cur->vcount : m->msg_count;
456}
int vcount
The number of virtual messages.
Definition: mailbox.h:99
+ Here is the call graph for this function:

◆ sidebar_n_num()

long sidebar_n_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Sidebar: New mail flag - Implements ExpandoRenderData::get_number() -.

Definition at line 461 of file window.c.

462{
463 const struct SidebarData *sdata = data;
464 const struct SbEntry *sbe = sdata->entry;
465 const struct Mailbox *m = sbe->mailbox;
466
467 return m->has_new;
468}
bool has_new
Mailbox has new mail.
Definition: mailbox.h:85

◆ sidebar_N_num()

long sidebar_N_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Sidebar: Number of unread messages - Implements ExpandoRenderData::get_number() -.

Definition at line 488 of file window.c.

489{
490 const struct SidebarData *sdata = data;
491 const struct SbEntry *sbe = sdata->entry;
492 const struct Mailbox *m = sbe->mailbox;
493
494 return m->msg_unread;
495}
int msg_unread
Number of unread messages.
Definition: mailbox.h:89

◆ sidebar_o_num()

long sidebar_o_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Sidebar: Number of old messages - Implements ExpandoRenderData::get_number() -.

Definition at line 500 of file window.c.

501{
502 const struct SidebarData *sdata = data;
503 const struct SbEntry *sbe = sdata->entry;
504 const struct Mailbox *m = sbe->mailbox;
505
506 return m->msg_unread - m->msg_new;
507}
int msg_new
Number of new messages.
Definition: mailbox.h:92

◆ sidebar_p_num()

long sidebar_p_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Sidebar: Poll for new mail - Implements ExpandoRenderData::get_number() -.

Definition at line 512 of file window.c.

513{
514 const struct SidebarData *sdata = data;
515 const struct SbEntry *sbe = sdata->entry;
516 const struct Mailbox *m = sbe->mailbox;
517
518 return m->poll_new_mail;
519}
bool poll_new_mail
Check for new mail.
Definition: mailbox.h:115

◆ sidebar_r_num()

long sidebar_r_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Sidebar: Number of read messages - Implements ExpandoRenderData::get_number() -.

Definition at line 524 of file window.c.

525{
526 const struct SidebarData *sdata = data;
527 const struct SbEntry *sbe = sdata->entry;
528 const struct Mailbox *m = sbe->mailbox;
529
530 return m->msg_count - m->msg_unread;
531}

◆ sidebar_S_num()

long sidebar_S_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Sidebar: number of messages - Implements ExpandoRenderData::get_number() -.

Definition at line 536 of file window.c.

537{
538 const struct SidebarData *sdata = data;
539 const struct SbEntry *sbe = sdata->entry;
540 const struct Mailbox *m = sbe->mailbox;
541
542 return m->msg_count;
543}

◆ sidebar_t_num()

long sidebar_t_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Sidebar: Number of tagged messages - Implements ExpandoRenderData::get_number() -.

Definition at line 548 of file window.c.

549{
550 const struct SidebarData *sdata = data;
551 const struct SbEntry *sbe = sdata->entry;
552 const struct IndexSharedData *shared = sdata->shared;
553 const struct Mailbox *m = sbe->mailbox;
554 const struct Mailbox *m_cur = shared->mailbox;
555
556 const bool c = m_cur && mutt_str_equal(m_cur->realpath, m->realpath);
557
558 return c ? m_cur->msg_tagged : 0;
559}
int msg_tagged
How many messages are tagged?
Definition: mailbox.h:94
+ Here is the call graph for this function:

◆ sidebar_Z_num()

long sidebar_Z_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Sidebar: Number of new messages - Implements ExpandoRenderData::get_number() -.

Definition at line 564 of file window.c.

565{
566 const struct SidebarData *sdata = data;
567 const struct SbEntry *sbe = sdata->entry;
568 const struct Mailbox *m = sbe->mailbox;
569
570 return m->msg_new;
571}

◆ status_M_num()

long status_M_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Status: Number of messages - Implements ExpandoRenderData::get_number() -.

Definition at line 172 of file status.c.

173{
174 const struct MenuStatusLineData *msld = data;
175 const struct IndexSharedData *shared = msld->shared;
176 const struct Mailbox *m = shared->mailbox;
177
178 return m ? m->vcount : 0;
179}
Data for creating a Menu line.
Definition: status.c:76
struct IndexSharedData * shared
Data shared between Index, Pager and Sidebar.
Definition: status.c:77

◆ status_m_num()

long status_m_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Status: Number of messages in the mailbox - Implements ExpandoRenderData::get_number() -.

Definition at line 184 of file status.c.

185{
186 const struct MenuStatusLineData *msld = data;
187 const struct IndexSharedData *shared = msld->shared;
188 const struct Mailbox *m = shared->mailbox;
189
190 return m ? m->msg_count : 0;
191}

◆ status_n_num()

long status_n_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Status: Number of new messages - Implements ExpandoRenderData::get_number() -.

Definition at line 196 of file status.c.

197{
198 const struct MenuStatusLineData *msld = data;
199 const struct IndexSharedData *shared = msld->shared;
200 const struct Mailbox *m = shared->mailbox;
201
202 return m ? m->msg_new : 0;
203}

◆ status_o_num()

long status_o_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Status: Number of old messages - Implements ExpandoRenderData::get_number() -.

Definition at line 208 of file status.c.

209{
210 const struct MenuStatusLineData *msld = data;
211 const struct IndexSharedData *shared = msld->shared;
212 const struct Mailbox *m = shared->mailbox;
213
214 return m ? (m->msg_unread - m->msg_new) : 0;
215}

◆ status_d_num()

long status_d_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Status: Number of deleted messages - Implements ExpandoRenderData::get_number() -.

Definition at line 220 of file status.c.

221{
222 const struct MenuStatusLineData *msld = data;
223 const struct IndexSharedData *shared = msld->shared;
224 const struct Mailbox *m = shared->mailbox;
225
226 return m ? m->msg_deleted : 0;
227}

◆ status_F_num()

long status_F_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Status: Number of flagged messages - Implements ExpandoRenderData::get_number() -.

Definition at line 232 of file status.c.

233{
234 const struct MenuStatusLineData *msld = data;
235 const struct IndexSharedData *shared = msld->shared;
236 const struct Mailbox *m = shared->mailbox;
237
238 return m ? m->msg_flagged : 0;
239}

◆ status_t_num()

long status_t_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Status: Number of tagged messages - Implements ExpandoRenderData::get_number() -.

Definition at line 244 of file status.c.

245{
246 const struct MenuStatusLineData *msld = data;
247 const struct IndexSharedData *shared = msld->shared;
248 const struct Mailbox *m = shared->mailbox;
249
250 return m ? m->msg_tagged : 0;
251}

◆ status_p_num()

long status_p_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Status: Number of postponed messages - Implements ExpandoRenderData::get_number() -.

Definition at line 256 of file status.c.

257{
258 const struct MenuStatusLineData *msld = data;
259 const struct IndexSharedData *shared = msld->shared;
260 struct Mailbox *m = shared->mailbox;
261
262 return mutt_num_postponed(m, false);
263}
int mutt_num_postponed(struct Mailbox *m, bool force)
Return the number of postponed messages.
Definition: postpone.c:70
+ Here is the call graph for this function:

◆ status_b_num()

long status_b_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Status: Number of mailboxes with new mail - Implements ExpandoRenderData::get_number() -.

Definition at line 268 of file status.c.

269{
270 const struct MenuStatusLineData *msld = data;
271 const struct IndexSharedData *shared = msld->shared;
272 struct Mailbox *m = shared->mailbox;
273
275}
int mutt_mailbox_check(struct Mailbox *m_cur, CheckStatsFlags flags)
Check all all Mailboxes for new mail.
Definition: mutt_mailbox.c:168
#define MUTT_MAILBOX_CHECK_NO_FLAGS
No flags are set.
Definition: mxapi.h:53
+ Here is the call graph for this function:

◆ status_l_num()

long status_l_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Status: Size of the current mailbox - Implements ExpandoRenderData::get_number() -.

Definition at line 280 of file status.c.

281{
282 const struct MenuStatusLineData *msld = data;
283 const struct IndexSharedData *shared = msld->shared;
284 const struct Mailbox *m = shared->mailbox;
285 if (!m)
286 return 0;
287
288 return m->size;
289}
off_t size
Size of the Mailbox.
Definition: mailbox.h:84

◆ status_P_num()

long status_P_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Status: Percentage through index - Implements ExpandoRenderData::get_number() -.

Definition at line 348 of file status.c.

349{
350 const struct MenuStatusLineData *msld = data;
351 const struct Menu *menu = msld->menu;
352 if (!menu)
353 return 0;
354
355 if (menu->top + menu->page_len >= menu->max)
356 return 100;
357
358 return (100 * (menu->top + menu->page_len)) / menu->max;
359}
struct Menu * menu
Current Menu.
Definition: status.c:78
Definition: lib.h:79
int top
Entry that is the top of the current page.
Definition: lib.h:90
int max
Number of entries in the menu.
Definition: lib.h:81
int page_len
Number of entries per screen.
Definition: lib.h:84

◆ status_L_num()

long status_L_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Status: Size of the messages - Implements ExpandoRenderData::get_number() -.

Definition at line 409 of file status.c.

410{
411 const struct MenuStatusLineData *msld = data;
412 const struct IndexSharedData *shared = msld->shared;
413 const struct MailboxView *mailbox_view = shared->mailbox_view;
414 if (!mailbox_view)
415 return 0;
416
417 return mailbox_view->vsize;
418}
struct MailboxView * mailbox_view
Current Mailbox view.
Definition: shared_data.h:40
View of a Mailbox.
Definition: mview.h:40
off_t vsize
Size (in bytes) of the messages shown.
Definition: mview.h:41

◆ status_R_num()

long status_R_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Status: Number of read messages - Implements ExpandoRenderData::get_number() -.

Definition at line 440 of file status.c.

441{
442 const struct MenuStatusLineData *msld = data;
443 const struct IndexSharedData *shared = msld->shared;
444 const struct Mailbox *m = shared->mailbox;
445
446 return m ? (m->msg_count - m->msg_unread) : 0;
447}

◆ status_u_num()

long status_u_num ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags 
)

Status: Number of unread messages - Implements ExpandoRenderData::get_number() -.

Definition at line 452 of file status.c.

453{
454 const struct MenuStatusLineData *msld = data;
455 const struct IndexSharedData *shared = msld->shared;
456 const struct Mailbox *m = shared->mailbox;
457
458 return m ? m->msg_unread : 0;
459}