NeoMutt  2024-04-25-76-g20fe7b
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:1519
#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 194 of file dlg_browser.c.

195{
196 const struct Folder *folder = data;
197
198 if (!folder->ff->local)
199 return 0;
200
201 return folder->ff->mtime;
202}
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 255 of file dlg_browser.c.

256{
257 const struct Folder *folder = data;
258
259 return folder->ff->notify_user;
260}
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 265 of file dlg_browser.c.

266{
267 const struct Folder *folder = data;
268
269 return folder->num + 1;
270}
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 275 of file dlg_browser.c.

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

◆ 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 309 of file dlg_browser.c.

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

◆ 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 454 of file dlg_browser.c.

455{
456 const struct Folder *folder = data;
457
458 if (folder->ff->local)
459 return folder->ff->nlink;
460
461 return 0;
462}
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 480 of file dlg_browser.c.

481{
482 const struct Folder *folder = data;
483
484 if (folder->ff->has_mailbox)
485 return folder->ff->msg_count;
486
487 return 0;
488}
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 506 of file dlg_browser.c.

507{
508 const struct Folder *folder = data;
509
510 if (folder->ff->has_mailbox)
511 return folder->ff->msg_unread;
512
513 return 0;
514}
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 532 of file dlg_browser.c.

533{
534 const struct Folder *folder = data;
535 return folder->ff->has_new_mail;
536}
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 554 of file dlg_browser.c.

555{
556 const struct Folder *folder = data;
557
558 return folder->ff->poll_new_mail;
559}
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 564 of file dlg_browser.c.

565{
566 const struct Folder *folder = data;
567 return folder->ff->size;
568}
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 587 of file dlg_browser.c.

588{
589 const struct Folder *folder = data;
590 return folder->ff->tagged;
591}
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 307 of file hdrline.c.

308{
309 const struct HdrFormatInfo *hfi = data;
310 const struct Email *e = hfi->email;
311 if (!e)
312 return 0;
313
314 return e->received;
315}
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:71
struct Email * email
Current Email.
Definition: hdrline.c:74

◆ 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 363 of file hdrline.c.

364{
365 const struct HdrFormatInfo *hfi = data;
366 const struct Email *e = hfi->email;
367 if (!e)
368 return 0;
369
370 return e->date_sent;
371}
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 419 of file hdrline.c.

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

◆ 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 612 of file hdrline.c.

613{
614 const struct HdrFormatInfo *hfi = data;
615 const struct Email *e = hfi->email;
616 if (!e || !e->body)
617 return 0;
618
619 return e->body->length;
620}
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 665 of file hdrline.c.

666{
667 const struct HdrFormatInfo *hfi = data;
668 const struct Email *e = hfi->email;
669 if (!e)
670 return 0;
671
672 if (flags & MUTT_FORMAT_INDEX)
674
675 return e->msgno + 1;
676}
@ 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:106
#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 681 of file hdrline.c.

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

◆ 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 739 of file hdrline.c.

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

◆ 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 790 of file hdrline.c.

791{
792 const struct HdrFormatInfo *hfi = data;
793 struct Email *e = hfi->email;
794 struct Mailbox *m = hfi->mailbox;
795
797}
int mutt_messages_in_thread(struct Mailbox *m, struct Email *e, enum MessageInThread mit)
Count the messages in a thread.
Definition: mutt_thread.c:1657
@ MIT_POSITION
Our position in the thread.
Definition: mutt_thread.h:90
struct Mailbox * mailbox
Current Mailbox.
Definition: hdrline.c:72
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 802 of file hdrline.c.

803{
804 const struct HdrFormatInfo *hfi = data;
805 struct Email *e = hfi->email;
806 struct Mailbox *m = hfi->mailbox;
807
809}
@ 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 1034 of file hdrline.c.

1035{
1036 const struct HdrFormatInfo *hfi = data;
1037 const struct Email *e = hfi->email;
1038 if (!e)
1039 return 0;
1040
1041 if (flags & MUTT_FORMAT_INDEX)
1043
1044 return e->lines;
1045}
@ 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 1070 of file hdrline.c.

1071{
1072 const struct HdrFormatInfo *hfi = data;
1073 const struct Mailbox *m = hfi->mailbox;
1074
1075 if (m)
1076 return m->msg_count;
1077
1078 return 0;
1079}
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 1114 of file hdrline.c.

1115{
1116 const struct HdrFormatInfo *hfi = data;
1117 const struct Email *e = hfi->email;
1118 if (!e)
1119 return 0;
1120
1121 const bool threads = mutt_using_threads();
1122 const bool is_index = (flags & MUTT_FORMAT_INDEX) != 0;
1123
1124 if (threads && is_index && e->collapsed && (e->num_hidden > 1))
1125 {
1126 if (flags & MUTT_FORMAT_INDEX)
1128 return e->num_hidden;
1129 }
1130
1131 return 0;
1132}
@ 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 1157 of file hdrline.c.

1158{
1159 const struct HdrFormatInfo *hfi = data;
1160 const struct Email *e = hfi->email;
1161 if (!e)
1162 return 0;
1163
1164 return e->score;
1165}
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 1487 of file hdrline.c.

1488{
1489 const struct HdrFormatInfo *hfi = data;
1490 struct Email *e = hfi->email;
1491 if (!e)
1492 return 0;
1493
1494 struct Mailbox *m = hfi->mailbox;
1495
1496 struct Message *msg = mx_msg_open(m, e);
1497 if (!msg)
1498 return 0;
1499
1500 const int num = mutt_count_body_parts(m, e, msg->fp);
1501 mx_msg_close(m, &msg);
1502 return num;
1503}
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:1180
struct Message * mx_msg_open(struct Mailbox *m, struct Email *e)
Return a stream pointer for a message.
Definition: mx.c:1134
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 289 of file dlg_gpgme.c.

290{
291#ifdef HAVE_PKG_GPGME
292 const struct CryptEntry *entry = data;
293 const struct CryptKeyInfo *key = entry->key;
294 return key->kobj->subkeys->timestamp;
295#endif
296 return 0;
297}
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 351 of file dlg_gpgme.c.

352{
353#ifdef HAVE_PKG_GPGME
354 const struct CryptEntry *entry = data;
355 return entry->num;
356#else
357 return 0;
358#endif
359}
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 523 of file dlg_gpgme.c.

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

◆ 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 255 of file dlg_pgp.c.

256{
257#ifdef HAVE_PGP
258 const struct PgpEntry *entry = data;
259 const struct PgpUid *uid = entry->uid;
260 const struct PgpKeyInfo *key = uid->parent;
261
262 return key->gen_time;
263#endif
264 return 0;
265}
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 311 of file dlg_pgp.c.

312{
313#ifdef HAVE_PGP
314 const struct PgpEntry *entry = data;
315 return entry->num;
316#else
317 return 0;
318#endif
319}
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 491 of file dlg_pgp.c.

492{
493#ifdef HAVE_PGP
494 const struct PgpEntry *entry = data;
495 const struct PgpUid *uid = entry->uid;
496 const struct PgpKeyInfo *key = uid->parent;
497
498 return key->keylen;
499#else
500 return 0;
501#endif
502}
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 507 of file dlg_pgp.c.

508{
509#ifdef HAVE_PGP
510 const struct PgpEntry *entry = data;
511 const struct PgpUid *uid = entry->uid;
512 struct PgpKeyInfo *key = uid->parent;
513 struct PgpKeyInfo *pkey = pgp_principal_key(key);
514
515 return pkey->keylen;
516#else
517 return 0;
518#endif
519}
struct PgpKeyInfo * pgp_principal_key(struct PgpKeyInfo *key)
Get the main (parent) PGP key.
Definition: pgpkey.c:92
+ 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:47
struct NntpMboxData * nd
Extra NNTP data.
Definition: lib.h:103
Container for Accounts, Notifications.
Definition: neomutt.h:42
struct ConfigSubset * sub
Inherited config items.
Definition: neomutt.h:46
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 939 of file newsrc.c.

940{
941 const struct NntpAccountData *adata = data;
942 const struct ConnAccount *cac = &adata->conn->account;
943
944 return cac->port;
945}
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 950 of file newsrc.c.

951{
952 const struct NntpAccountData *adata = data;
953 const struct ConnAccount *cac = &adata->conn->account;
954
955 if (cac->flags & MUTT_ACCT_PORT)
956 return cac->port;
957
958 return 0;
959}
#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:660
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 173 of file status.c.

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

◆ 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 185 of file status.c.

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

◆ 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 197 of file status.c.

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

◆ 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 209 of file status.c.

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

◆ 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 221 of file status.c.

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

◆ 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 233 of file status.c.

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

◆ 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 245 of file status.c.

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

◆ 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 257 of file status.c.

258{
259 const struct MenuStatusLineData *msld = data;
260 const struct IndexSharedData *shared = msld->shared;
261 struct Mailbox *m = shared->mailbox;
262
263 return mutt_num_postponed(m, false);
264}
int mutt_num_postponed(struct Mailbox *m, bool force)
Return the number of postponed messages.
Definition: postpone.c:71
+ 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 269 of file status.c.

270{
271 const struct MenuStatusLineData *msld = data;
272 const struct IndexSharedData *shared = msld->shared;
273 struct Mailbox *m = shared->mailbox;
274
276}
int mutt_mailbox_check(struct Mailbox *m_cur, CheckStatsFlags flags)
Check all all Mailboxes for new mail.
Definition: mutt_mailbox.c:169
#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 281 of file status.c.

282{
283 const struct MenuStatusLineData *msld = data;
284 const struct IndexSharedData *shared = msld->shared;
285 const struct Mailbox *m = shared->mailbox;
286 if (!m)
287 return 0;
288
289 return m->size;
290}
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 349 of file status.c.

350{
351 const struct MenuStatusLineData *msld = data;
352 const struct Menu *menu = msld->menu;
353 if (!menu)
354 return 0;
355
356 if (menu->top + menu->page_len >= menu->max)
357 return 100;
358
359 return (100 * (menu->top + menu->page_len)) / menu->max;
360}
struct Menu * menu
Current Menu.
Definition: status.c:79
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 410 of file status.c.

411{
412 const struct MenuStatusLineData *msld = data;
413 const struct IndexSharedData *shared = msld->shared;
414 const struct MailboxView *mailbox_view = shared->mailbox_view;
415 if (!mailbox_view)
416 return 0;
417
418 return mailbox_view->vsize;
419}
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 441 of file status.c.

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

◆ 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 453 of file status.c.

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