NeoMutt  2024-11-14-138-ge5ca67
Teaching an old dog new tricks
DOXYGEN
Loading...
Searching...
No Matches
Expando Get String API

Get some string data. More...

+ Collaboration diagram for Expando Get String API:

Functions

static void alias_address (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Alias: Full Address - Implements get_string_t -.
 
static void alias_alias (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Alias: Alias name - Implements get_string_t -.
 
static void alias_comment (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Alias: Comment - Implements get_string_t -.
 
static void alias_email (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Alias: Email Address - Implements get_string_t -.
 
static void alias_name (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Alias: Personal Name - Implements get_string_t -.
 
static void alias_tags (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Alias: Tags - Implements get_string_t -.
 
static void alias_view_flags (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 AliasView: Flags - Implements get_string_t -.
 
static void alias_view_tagged (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 AliasView: Tagged char - Implements get_string_t -.
 
static void attach_charset (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Attachment: Charset - Implements get_string_t -.
 
static void attach_tree (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Attachment: Tree characters - Implements get_string_t -.
 
static void body_attach_qualifies (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Body: Attachment counting - Implements get_string_t -.
 
static void body_charset_convert (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Body: Requires conversion flag - Implements get_string_t -.
 
static void body_deleted (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Body: Deleted - Implements get_string_t -.
 
static void body_description (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Body: Description - Implements get_string_t -.
 
static void body_disposition (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Body: Disposition flag - Implements get_string_t -.
 
static void body_file (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Body: Filename - Implements get_string_t -.
 
static void body_file_disposition (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Body: Filename in header - Implements get_string_t -.
 
static void body_file_size (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Body: Size - Implements get_string_t -.
 
static void body_mime_encoding (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Body: MIME type - Implements get_string_t -.
 
static void body_mime_major (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Body: Major MIME type - Implements get_string_t -.
 
static void body_mime_minor (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Body: MIME subtype - Implements get_string_t -.
 
static void body_tagged (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Body: Is Tagged - Implements get_string_t -.
 
static void body_unlink (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Body: Unlink flag - Implements get_string_t -.
 
static void autocrypt_address (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Autocrypt: Address - Implements get_string_t -.
 
static void autocrypt_enabled (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Autocrypt: Status flag - Implements get_string_t -.
 
static void autocrypt_keyid (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Autocrypt: GPG Key - Implements get_string_t -.
 
static void autocrypt_prefer_encrypt (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Autocrypt: Prefer-encrypt flag - Implements get_string_t -.
 
static void folder_date (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Browser: Last modified - Implements get_string_t -.
 
static void folder_date_format (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Browser: Last modified ($date_format) - Implements get_string_t -.
 
static void folder_date_strf (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Browser: Last modified (strftime) - Implements get_string_t -.
 
static void folder_description (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Browser: Description - Implements get_string_t -.
 
static void folder_filename (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Browser: Filename - Implements get_string_t -.
 
static void folder_file_group (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Browser: Group name - Implements get_string_t -.
 
static void folder_file_mode (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Browser: File permissions - Implements get_string_t -.
 
static void folder_file_owner (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Browser: Owner name - Implements get_string_t -.
 
static void folder_file_size (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Browser: Size in bytes - Implements get_string_t -.
 
static void folder_hard_links (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Browser: Hard links - Implements get_string_t -.
 
static void folder_message_count (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Browser: Number of messages - Implements get_string_t -.
 
static void folder_new_mail (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Browser: New mail flag - Implements get_string_t -.
 
static void folder_tagged (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Browser: Is Tagged - Implements get_string_t -.
 
static void folder_unread_count (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Browser: Number of unread messages - Implements get_string_t -.
 
static void global_padding_space (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Fixed whitespace - Implements get_string_t -.
 
static void compress_from (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Compress: From filename - Implements get_string_t -.
 
static void compress_to (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Compress: To filename - Implements get_string_t -.
 
static void compose_attach_size (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Compose: Size in bytes - Implements get_string_t -.
 
static void global_hostname (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Compose: Hostname - Implements get_string_t -.
 
static void global_version (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Compose: Version - Implements get_string_t -.
 
static void history_match (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 History: History match - Implements get_string_t -.
 
static void email_body_characters (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Number of raw bytes - Implements get_string_t -.
 
static void email_combined_flags (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Status flags - Implements get_string_t -.
 
static void email_crypto_flags (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Message crypto flags - Implements get_string_t -.
 
static void email_date_format (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Sent date and time - Implements get_string_t -.
 
static void email_date_format_local (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Sent local date and time - Implements get_string_t -.
 
static void email_date_strf (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Sent date and time - Implements get_string_t -.
 
static void email_date_strf_local (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Sent local date and time - Implements get_string_t -.
 
static void email_flag_chars (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Status flag - Implements get_string_t -.
 
static void email_from_list (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: List address - Implements get_string_t -.
 
static void email_index_hook (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: index-format-hook - Implements get_string_t -.
 
static void email_list_or_save_folder (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: List Name or Save folder - Implements get_string_t -.
 
static void email_message_flags (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Message tag flags - Implements get_string_t -.
 
static void email_size (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Number of bytes - Implements get_string_t -.
 
static void email_status_flags (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Message status flags - Implements get_string_t -.
 
static void email_strf_recv_local (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Received local date and time - Implements get_string_t -.
 
static void email_tags (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Message tags - Implements get_string_t -.
 
static void email_tags_transformed (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Individual tag - Implements get_string_t -.
 
static void email_thread_hidden_count (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Number of hidden messages - Implements get_string_t -.
 
static void email_thread_tags (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Tags - Implements get_string_t -.
 
static void email_to_chars (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: $to_chars flag - Implements get_string_t -.
 
static void envelope_cc_all (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Cc recipients - Implements get_string_t -.
 
static void envelope_first_name (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: First name - Implements get_string_t -.
 
static void envelope_from (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Author Address - Implements get_string_t -.
 
static void envelope_from_full (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Sender - Implements get_string_t -.
 
static void envelope_initials (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Initials of author - Implements get_string_t -.
 
static void envelope_list_address (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Email list - Implements get_string_t -.
 
static void envelope_list_empty (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Mailing list - Implements get_string_t -.
 
static void envelope_message_id (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Message-id - Implements get_string_t -.
 
static void envelope_name (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Author's real name - Implements get_string_t -.
 
static void envelope_newsgroup (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Newsgroup name - Implements get_string_t -.
 
static void envelope_organization (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Organization - Implements get_string_t -.
 
static void envelope_reply_to (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Reply-to address - Implements get_string_t -.
 
static void envelope_sender (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Author name - Implements get_string_t -.
 
static void envelope_sender_plain (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Plain author name - Implements get_string_t -.
 
static void envelope_spam (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Spam attributes - Implements get_string_t -.
 
static void envelope_subject (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Subject - Implements get_string_t -.
 
static void envelope_thread_tree (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Thread tree - Implements get_string_t -.
 
static void envelope_thread_x_label (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: X-Label (if different) - Implements get_string_t -.
 
static void envelope_to (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: To field - Implements get_string_t -.
 
static void envelope_to_all (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: To recipients - Implements get_string_t -.
 
static void envelope_username (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: User name - Implements get_string_t -.
 
static void envelope_x_comment_to (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: X-Comment-To - Implements get_string_t -.
 
static void envelope_x_label (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: X-Label - Implements get_string_t -.
 
static void mailbox_mailbox_name (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Filename - Implements get_string_t -.
 
static void mailbox_percentage (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Index: Progress indicator - Implements get_string_t -.
 
static void global_config_sort (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Status: Sorting mode - Implements get_string_t -.
 
static void global_config_sort_aux (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Status: Aux sorting method - Implements get_string_t -.
 
static void global_config_use_threads (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Status: Current threading mode - Implements get_string_t -.
 
static void index_description (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Status: Description of the mailbox - Implements get_string_t -.
 
static void index_limit_pattern (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Status: Active limit pattern - Implements get_string_t -.
 
static void index_limit_size (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Status: Size of the messages - Implements get_string_t -.
 
static void index_mailbox_path (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Status: pathname of the mailbox - Implements get_string_t -.
 
static void index_mailbox_size (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Status: Size of the current mailbox - Implements get_string_t -.
 
static void index_readonly (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Status: Modified/read-only flag - Implements get_string_t -.
 
static void menu_percentage (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Status: Percentage through index - Implements get_string_t -.
 
static void pgp_command_file_message (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 PGP Command: Filename of message - Implements get_string_t -.
 
static void pgp_command_file_signature (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 PGP Command: Filename of signature - Implements get_string_t -.
 
static void pgp_command_key_ids (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 PGP Command: key IDs - Implements get_string_t -.
 
static void pgp_command_need_pass (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 PGP Command: PGPPASSFD=0 if passphrase is needed - Implements get_string_t -.
 
static void pgp_command_sign_as (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 PGP Command: $pgp_sign_as or $pgp_default_key - Implements get_string_t -.
 
static void gpgme_entry_trust (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 GPGME: Trust/validity - Implements get_string_t -.
 
static void gpgme_entry_user_id (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 GPGME: User id - Implements get_string_t -.
 
static void gpgme_key_algorithm (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 GPGME: Key Algorithm - Implements get_string_t -.
 
static void gpgme_key_capabilities (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 GPGME: Key Capabilities - Implements get_string_t -.
 
static void gpgme_key_date (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 GPGME: Date of the key - Implements get_string_t -.
 
static void gpgme_key_fingerprint (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 GPGME: Key fingerprint - Implements get_string_t -.
 
static void gpgme_key_flags (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 GPGME: Key Flags - Implements get_string_t -.
 
static void gpgme_key_id (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 GPGME: Key id - Implements get_string_t -.
 
static void gpgme_key_protocol (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 GPGME: Protocol - Implements get_string_t -.
 
static void pgp_entry_ignore (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 PGP: Field not supported - Implements get_string_t -.
 
static void pgp_entry_trust (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 PGP: Trust/validity - Implements get_string_t -.
 
static void pgp_entry_user_id (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 PGP: User id - Implements get_string_t -.
 
static void pgp_key_algorithm (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 PGP: Key Algorithm - Implements get_string_t -.
 
static void pgp_key_capabilities (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 PGP: Key Capabilities - Implements get_string_t -.
 
static void pgp_key_date (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 PGP: Date of the key - Implements get_string_t -.
 
static void pgp_key_flags (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 PGP: Key Flags - Implements get_string_t -.
 
static void pgp_key_id (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 PGP: Key id - Implements get_string_t -.
 
static void pgp_pkey_algorithm (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 PGP: Principal Key Algorithm - Implements get_string_t -.
 
static void pgp_pkey_capabilities (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 PGP: Principal Key Capabilities - Implements get_string_t -.
 
static void pgp_pkey_flags (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 PGP: Principal Key Flags - Implements get_string_t -.
 
static void pgp_pkey_id (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 PGP: Principal Key id - Implements get_string_t -.
 
static void smime_command_algorithm (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Smime Command: algorithm - Implements get_string_t -.
 
static void smime_command_certificate_ids (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Smime Command: certificate IDs - Implements get_string_t -.
 
static void smime_command_certificate_path (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Smime Command: CA location - Implements get_string_t -.
 
static void smime_command_digest_algorithm (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Smime Command: Message digest algorithm - Implements get_string_t -.
 
static void smime_command_intermediate_ids (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Smime Command: Intermediate certificates - Implements get_string_t -.
 
static void smime_command_key (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Smime Command: Key-pair - Implements get_string_t -.
 
static void smime_command_message_file (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Smime Command: Filename of message - Implements get_string_t -.
 
static void smime_command_signature_file (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Smime Command: Filename of signature - Implements get_string_t -.
 
static void group_index_description (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 NNTP: Description - Implements get_string_t -.
 
static void group_index_flags (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 NNTP: Moderated flag - Implements get_string_t -.
 
static void group_index_flags2 (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 NNTP: New flag - Implements get_string_t -.
 
static void group_index_newsgroup (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 NNTP: Newsgroup name - Implements get_string_t -.
 
static void nntp_account (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Newsrc: Account url - Implements get_string_t -.
 
static void nntp_port_if (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Newsrc: Port if specified - Implements get_string_t -.
 
static void nntp_schema (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Newsrc: Url schema - Implements get_string_t -.
 
static void nntp_server (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Newsrc: News server name - Implements get_string_t -.
 
static void nntp_username (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Newsrc: Username - Implements get_string_t -.
 
static void pattern_description (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Pattern: pattern description - Implements get_string_t -.
 
static void pattern_expression (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Pattern: pattern expression - Implements get_string_t -.
 
static void greeting_real_name (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Greeting: Real name - Implements get_string_t -.
 
static void greeting_login_name (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Greeting: Login name - Implements get_string_t -.
 
static void greeting_first_name (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Greeting: First name - Implements get_string_t -.
 
static void sidebar_description (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Sidebar: Descriptive name - Implements get_string_t -.
 
static void sidebar_flagged (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Sidebar: Flagged flags - Implements get_string_t -.
 
static void sidebar_name (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Sidebar: Name of the mailbox - Implements get_string_t -.
 
static void sidebar_new_mail (const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
 Sidebar: New mail flag - Implements get_string_t -.
 

Detailed Description

Get some string data.

Parameters
[in]nodeExpandoNode containing the callback
[in]dataPrivate data
[in]flagsFlags, see MuttFormatFlags
[out]bufBuffer in which to save string

Get some string data to be formatted.

Function Documentation

◆ alias_address()

static void alias_address ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Alias: Full Address - Implements get_string_t -.

Definition at line 42 of file expando.c.

44{
45 const struct AliasView *av = data;
46 const struct Alias *alias = av->alias;
47
48 mutt_addrlist_write(&alias->addr, buf, true);
49}
size_t mutt_addrlist_write(const struct AddressList *al, struct Buffer *buf, bool display)
Write an Address to a buffer.
Definition: address.c:1206
GUI data wrapping an Alias.
Definition: gui.h:38
struct Alias * alias
Alias.
Definition: gui.h:46
A shortcut for an email address or addresses.
Definition: alias.h:35
struct AddressList addr
List of Addresses the Alias expands to.
Definition: alias.h:37
+ Here is the call graph for this function:

◆ alias_alias()

static void alias_alias ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Alias: Alias name - Implements get_string_t -.

Definition at line 54 of file expando.c.

56{
57 const struct AliasView *av = data;
58 const struct Alias *alias = av->alias;
59
60 const char *s = alias->name;
61 buf_strcpy(buf, s);
62}
size_t buf_strcpy(struct Buffer *buf, const char *s)
Copy a string into a Buffer.
Definition: buffer.c:395
char * name
Short name.
Definition: alias.h:36
+ Here is the call graph for this function:

◆ alias_comment()

static void alias_comment ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Alias: Comment - Implements get_string_t -.

Definition at line 67 of file expando.c.

69{
70 const struct AliasView *av = data;
71 const struct Alias *alias = av->alias;
72
73 const char *s = alias->comment;
74 buf_strcpy(buf, s);
75}
char * comment
Free-form comment string.
Definition: alias.h:38
+ Here is the call graph for this function:

◆ alias_email()

static void alias_email ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Alias: Email Address - Implements get_string_t -.

Definition at line 80 of file expando.c.

82{
83 const struct AliasView *av = data;
84 const struct Alias *alias = av->alias;
85
86 struct Address *a = NULL;
87 TAILQ_FOREACH(a, &alias->addr, entries)
88 {
89 struct Address *next = TAILQ_NEXT(a, entries);
90
91 buf_add_printf(buf, "<%s>", buf_string(a->mailbox));
92 if (next)
93 buf_addstr(buf, ", ");
94 }
95}
int buf_add_printf(struct Buffer *buf, const char *fmt,...)
Format a string appending a Buffer.
Definition: buffer.c:204
size_t buf_addstr(struct Buffer *buf, const char *s)
Add a string to a Buffer.
Definition: buffer.c:226
static const char * buf_string(const struct Buffer *buf)
Convert a buffer to a const char * "string".
Definition: buffer.h:96
#define TAILQ_FOREACH(var, head, field)
Definition: queue.h:743
#define TAILQ_NEXT(elm, field)
Definition: queue.h:850
An email address.
Definition: address.h:36
struct Buffer * mailbox
Mailbox and host address.
Definition: address.h:38
+ Here is the call graph for this function:

◆ alias_name()

static void alias_name ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Alias: Personal Name - Implements get_string_t -.

Definition at line 100 of file expando.c.

102{
103 const struct AliasView *av = data;
104 const struct Alias *alias = av->alias;
105
106 struct Address *a = NULL;
107 TAILQ_FOREACH(a, &alias->addr, entries)
108 {
109 struct Address *next = TAILQ_NEXT(a, entries);
110
112 if (next)
113 buf_addstr(buf, ", ");
114 }
115}
struct Buffer * personal
Real name of address.
Definition: address.h:37
+ Here is the call graph for this function:

◆ alias_tags()

static void alias_tags ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Alias: Tags - Implements get_string_t -.

Definition at line 120 of file expando.c.

122{
123 const struct AliasView *av = data;
124
125 alias_tags_to_buffer(&av->alias->tags, buf);
126}
void alias_tags_to_buffer(struct TagList *tl, struct Buffer *buf)
Write a comma-separated list of tags to a Buffer.
Definition: commands.c:49
struct TagList tags
Tags.
Definition: alias.h:39
+ Here is the call graph for this function:

◆ alias_view_flags()

static void alias_view_flags ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

AliasView: Flags - Implements get_string_t -.

Definition at line 131 of file expando.c.

133{
134 const struct AliasView *av = data;
135
136 // NOTE(g0mb4): use $flag_chars?
137 const char *s = av->is_deleted ? "D" : " ";
138 buf_strcpy(buf, s);
139}
bool is_deleted
Is it deleted?
Definition: gui.h:44
+ Here is the call graph for this function:

◆ alias_view_tagged()

static void alias_view_tagged ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

AliasView: Tagged char - Implements get_string_t -.

Definition at line 163 of file expando.c.

165{
166 const struct AliasView *av = data;
167
168 // NOTE(g0mb4): use $flag_chars?
169 const char *s = av->is_tagged ? "*" : " ";
170 buf_strcpy(buf, s);
171}
bool is_tagged
Is it tagged?
Definition: gui.h:43
+ Here is the call graph for this function:

◆ attach_charset()

static void attach_charset ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Attachment: Charset - Implements get_string_t -.

Definition at line 48 of file expando.c.

50{
51 const struct AttachPtr *aptr = data;
52
53 char tmp[128] = { 0 };
54
55 if (mutt_is_text_part(aptr->body) && mutt_body_get_charset(aptr->body, tmp, sizeof(tmp)))
56 {
57 buf_strcpy(buf, tmp);
58 }
59}
char * mutt_body_get_charset(struct Body *b, char *buf, size_t buflen)
Get a body's character set.
Definition: body.c:133
bool mutt_is_text_part(const struct Body *b)
Is this part of an email in plain text?
Definition: muttlib.c:407
An email to which things will be attached.
Definition: attach.h:35
struct Body * body
Attachment.
Definition: attach.h:36
+ Here is the call graph for this function:

◆ attach_tree()

static void attach_tree ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Attachment: Tree characters - Implements get_string_t -.

Definition at line 74 of file expando.c.

76{
77 const struct AttachPtr *aptr = data;
78
80 node_expando_set_has_tree(node, true);
81 const char *s = aptr->tree;
82 buf_strcpy(buf, s);
83}
@ MT_COLOR_TREE
Index: tree-drawing characters.
Definition: color.h:79
void node_expando_set_color(const struct ExpandoNode *node, int cid)
Set the colour for an Expando.
Definition: node_expando.c:100
void node_expando_set_has_tree(const struct ExpandoNode *node, bool has_tree)
Set the has_tree flag for an Expando.
Definition: node_expando.c:115
char * tree
Tree characters to display.
Definition: attach.h:39
+ Here is the call graph for this function:

◆ body_attach_qualifies()

static void body_attach_qualifies ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Body: Attachment counting - Implements get_string_t -.

Definition at line 99 of file expando.c.

101{
102 const struct AttachPtr *aptr = data;
103
104 // NOTE(g0mb4): use $to_chars?
105 const char *s = aptr->body->attach_qualifies ? "Q" : " ";
106 buf_strcpy(buf, s);
107}
bool attach_qualifies
This attachment should be counted.
Definition: body.h:87
+ Here is the call graph for this function:

◆ body_charset_convert()

static void body_charset_convert ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Body: Requires conversion flag - Implements get_string_t -.

Definition at line 122 of file expando.c.

124{
125 const struct AttachPtr *aptr = data;
126
127 // NOTE(g0mb4): use $to_chars?
128 const char *s = ((aptr->body->type != TYPE_TEXT) || aptr->body->noconv) ? "n" : "c";
129 buf_strcpy(buf, s);
130}
@ TYPE_TEXT
Type: 'text/*'.
Definition: mime.h:38
bool noconv
Don't do character set conversion.
Definition: body.h:46
unsigned int type
content-type primary type, ContentType
Definition: body.h:40
+ Here is the call graph for this function:

◆ body_deleted()

static void body_deleted ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Body: Deleted - Implements get_string_t -.

Definition at line 135 of file expando.c.

137{
138 const struct AttachPtr *aptr = data;
139
140 // NOTE(g0mb4): use $to_chars?
141 const char *s = aptr->body->deleted ? "D" : " ";
142 buf_strcpy(buf, s);
143}
bool deleted
Attachment marked for deletion.
Definition: body.h:88
+ Here is the call graph for this function:

◆ body_description()

static void body_description ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Body: Description - Implements get_string_t -.

Definition at line 157 of file expando.c.

159{
160 const struct AttachPtr *aptr = data;
161
162 const struct Expando *c_message_format = cs_subset_expando(NeoMutt->sub, "message_format");
163 if (aptr->body->description)
164 {
165 const char *s = aptr->body->description;
166 buf_strcpy(buf, s);
167 return;
168 }
169
170 if (mutt_is_message_type(aptr->body->type, aptr->body->subtype) &&
171 c_message_format && aptr->body->email)
172 {
173 mutt_make_string(buf, -1, c_message_format, NULL, -1, aptr->body->email,
175
176 return;
177 }
178
179 if (!aptr->body->d_filename && !aptr->body->filename)
180 {
181 const char *s = "<no description>";
182 buf_strcpy(buf, s);
183 return;
184 }
185
186 body_file_disposition(node, data, flags, buf);
187}
const struct Expando * cs_subset_expando(const struct ConfigSubset *sub, const char *name)
Get an Expando config item by name.
Definition: config_type.c:357
int mutt_make_string(struct Buffer *buf, size_t max_cols, const struct Expando *exp, struct Mailbox *m, int inpgr, struct Email *e, MuttFormatFlags flags, const char *progress)
Create formatted strings using mailbox expandos.
Definition: dlg_index.c:803
bool mutt_is_message_type(int type, const char *subtype)
Determine if a mime type matches a message or not.
Definition: parse.c:1498
static void body_file_disposition(const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
Body: Filename in header - Implements get_string_t -.
Definition: expando.c:241
#define MUTT_FORMAT_FORCESUBJ
Print the subject even if unchanged.
Definition: render.h:34
#define MUTT_FORMAT_ARROWCURSOR
Reserve space for arrow_cursor.
Definition: render.h:37
char * d_filename
filename to be used for the content-disposition header If NULL, filename is used instead.
Definition: body.h:56
struct Email * email
header information for message/rfc822
Definition: body.h:74
char * description
content-description
Definition: body.h:55
char * subtype
content-type subtype
Definition: body.h:61
char * filename
When sending a message, this is the file to which this structure refers.
Definition: body.h:59
Parsed Expando trees.
Definition: expando.h:41
struct ExpandoNode * node
Parsed tree.
Definition: expando.h:43
Container for Accounts, Notifications.
Definition: neomutt.h:42
struct ConfigSubset * sub
Inherited config items.
Definition: neomutt.h:46
+ Here is the call graph for this function:

◆ body_disposition()

static void body_disposition ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Body: Disposition flag - Implements get_string_t -.

Definition at line 192 of file expando.c.

194{
195 const struct AttachPtr *aptr = data;
196
197 // NOTE(g0mb4): use $to_chars?
198 static const char dispchar[] = { 'I', 'A', 'F', '-' };
199 char ch;
200
201 if (aptr->body->disposition < sizeof(dispchar))
202 {
203 ch = dispchar[aptr->body->disposition];
204 }
205 else
206 {
207 mutt_debug(LL_DEBUG1, "ERROR: invalid content-disposition %d\n", aptr->body->disposition);
208 ch = '!';
209 }
210
211 buf_printf(buf, "%c", ch);
212}
int buf_printf(struct Buffer *buf, const char *fmt,...)
Format a string overwriting a Buffer.
Definition: buffer.c:161
#define mutt_debug(LEVEL,...)
Definition: logging2.h:89
@ LL_DEBUG1
Log at debug level 1.
Definition: logging2.h:43
unsigned int disposition
content-disposition, ContentDisposition
Definition: body.h:42
+ Here is the call graph for this function:

◆ body_file()

static void body_file ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Body: Filename - Implements get_string_t -.

Definition at line 217 of file expando.c.

219{
220 const struct AttachPtr *aptr = data;
221
222 if (aptr->body->filename && (*aptr->body->filename == '/'))
223 {
224 struct Buffer *path = buf_pool_get();
225
226 buf_strcpy(path, aptr->body->filename);
227 buf_pretty_mailbox(path);
228 buf_copy(buf, path);
229 buf_pool_release(&path);
230 }
231 else
232 {
233 const char *s = aptr->body->filename;
234 buf_strcpy(buf, s);
235 }
236}
size_t buf_copy(struct Buffer *dst, const struct Buffer *src)
Copy a Buffer's contents to another Buffer.
Definition: buffer.c:601
void buf_pretty_mailbox(struct Buffer *buf)
Shorten a mailbox path using '~' or '='.
Definition: muttlib.c:519
struct Buffer * buf_pool_get(void)
Get a Buffer from the pool.
Definition: pool.c:82
void buf_pool_release(struct Buffer **ptr)
Return a Buffer to the pool.
Definition: pool.c:96
String manipulation buffer.
Definition: buffer.h:36
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ body_file_disposition()

static void body_file_disposition ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Body: Filename in header - Implements get_string_t -.

Definition at line 241 of file expando.c.

243{
244 const struct AttachPtr *aptr = data;
245
246 if (aptr->body->d_filename)
247 {
248 const char *s = aptr->body->d_filename;
249 buf_strcpy(buf, s);
250 return;
251 }
252
253 body_file(node, data, flags, buf);
254}
static void body_file(const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
Body: Filename - Implements get_string_t -.
Definition: expando.c:217
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ body_file_size()

static void body_file_size ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Body: Size - Implements get_string_t -.

Definition at line 259 of file expando.c.

261{
262 const struct AttachPtr *aptr = data;
263
264 char tmp[128] = { 0 };
265
266 size_t l = 0;
267 if (aptr->body->filename && (flags & MUTT_FORMAT_STAT_FILE))
268 {
269 l = mutt_file_get_size(aptr->body->filename);
270 }
271 else
272 {
273 l = aptr->body->length;
274 }
275
276 mutt_str_pretty_size(tmp, sizeof(tmp), l);
277 buf_strcpy(buf, tmp);
278}
long mutt_file_get_size(const char *path)
Get the size of a file.
Definition: file.c:1519
void mutt_str_pretty_size(char *buf, size_t buflen, size_t num)
Display an abbreviated size, like 3.4K.
Definition: muttlib.c:1004
#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
+ Here is the call graph for this function:

◆ body_mime_encoding()

static void body_mime_encoding ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Body: MIME type - Implements get_string_t -.

Definition at line 296 of file expando.c.

298{
299 const struct AttachPtr *aptr = data;
300
301 const char *s = ENCODING(aptr->body->encoding);
302 buf_strcpy(buf, s);
303}
#define ENCODING(x)
Definition: mime.h:92
unsigned int encoding
content-transfer-encoding, ContentEncoding
Definition: body.h:41
+ Here is the call graph for this function:

◆ body_mime_major()

static void body_mime_major ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Body: Major MIME type - Implements get_string_t -.

Definition at line 308 of file expando.c.

310{
311 const struct AttachPtr *aptr = data;
312
313 const char *s = TYPE(aptr->body);
314 buf_strcpy(buf, s);
315}
#define TYPE(body)
Definition: mime.h:89
+ Here is the call graph for this function:

◆ body_mime_minor()

static void body_mime_minor ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Body: MIME subtype - Implements get_string_t -.

Definition at line 320 of file expando.c.

322{
323 const struct AttachPtr *aptr = data;
324
325 const char *s = aptr->body->subtype;
326 buf_strcpy(buf, s);
327}
+ Here is the call graph for this function:

◆ body_tagged()

static void body_tagged ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Body: Is Tagged - Implements get_string_t -.

Definition at line 332 of file expando.c.

334{
335 const struct AttachPtr *aptr = data;
336
337 // NOTE(g0mb4): use $to_chars?
338 const char *s = aptr->body->tagged ? "*" : " ";
339 buf_strcpy(buf, s);
340}
bool tagged
This attachment is tagged.
Definition: body.h:90
+ Here is the call graph for this function:

◆ body_unlink()

static void body_unlink ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Body: Unlink flag - Implements get_string_t -.

Definition at line 354 of file expando.c.

356{
357 const struct AttachPtr *aptr = data;
358
359 // NOTE(g0mb4): use $to_chars?
360 const char *s = aptr->body->unlink ? "-" : " ";
361 buf_strcpy(buf, s);
362}
bool unlink
If true, filename should be unlink()ed before free()ing this structure.
Definition: body.h:68
+ Here is the call graph for this function:

◆ autocrypt_address()

static void autocrypt_address ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Autocrypt: Address - Implements get_string_t -.

Definition at line 41 of file expando.c.

43{
44 const struct AccountEntry *entry = data;
45
46 buf_copy(buf, entry->addr->mailbox);
47}
An entry in the Autocrypt account Menu.
Definition: private.h:46
struct Address * addr
Email address associated with the account.
Definition: private.h:49
+ Here is the call graph for this function:

◆ autocrypt_enabled()

static void autocrypt_enabled ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Autocrypt: Status flag - Implements get_string_t -.

Definition at line 52 of file expando.c.

54{
55 const struct AccountEntry *entry = data;
56
57 if (entry->account->enabled)
58 {
59 /* L10N: Autocrypt Account menu.
60 flag that an account is enabled/active */
61 buf_addstr(buf, _("active"));
62 }
63 else
64 {
65 /* L10N: Autocrypt Account menu.
66 flag that an account is disabled/inactive */
67 buf_addstr(buf, _("inactive"));
68 }
69}
#define _(a)
Definition: message.h:28
struct AutocryptAccount * account
Account details.
Definition: private.h:48
bool enabled
Is this account enabled.
Definition: lib.h:115
+ Here is the call graph for this function:

◆ autocrypt_keyid()

static void autocrypt_keyid ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Autocrypt: GPG Key - Implements get_string_t -.

Definition at line 74 of file expando.c.

76{
77 const struct AccountEntry *entry = data;
78
79 const char *s = entry->account->keyid;
80 buf_strcpy(buf, s);
81}
char * keyid
PGP Key id.
Definition: lib.h:112
+ Here is the call graph for this function:

◆ autocrypt_prefer_encrypt()

static void autocrypt_prefer_encrypt ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Autocrypt: Prefer-encrypt flag - Implements get_string_t -.

Definition at line 96 of file expando.c.

98{
99 const struct AccountEntry *entry = data;
100
101 if (entry->account->prefer_encrypt)
102 {
103 /* L10N: Autocrypt Account menu.
104 flag that an account has prefer-encrypt set */
105 buf_addstr(buf, _("prefer encrypt"));
106 }
107 else
108 {
109 /* L10N: Autocrypt Account menu.
110 flag that an account has prefer-encrypt unset;
111 thus encryption will need to be manually enabled. */
112 buf_addstr(buf, _("manual encrypt"));
113 }
114}
bool prefer_encrypt
false = nopref, true = mutual
Definition: lib.h:114
+ Here is the call graph for this function:

◆ folder_date()

static void folder_date ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Browser: Last modified - Implements get_string_t -.

Definition at line 47 of file expando.c.

49{
50 const struct Folder *folder = data;
51 if (!folder->ff->local)
52 return;
53
54 static const time_t one_year = 31536000;
55 const char *t_fmt = ((mutt_date_now() - folder->ff->mtime) < one_year) ?
56 "%b %d %H:%M" :
57 "%b %d %Y";
58
59 char tmp[128] = { 0 };
60
61 mutt_date_localtime_format(tmp, sizeof(tmp), t_fmt, folder->ff->mtime);
62
63 buf_strcpy(buf, tmp);
64}
size_t mutt_date_localtime_format(char *buf, size_t buflen, const char *format, time_t t)
Format localtime.
Definition: date.c:951
time_t mutt_date_now(void)
Return the number of seconds since the Unix epoch.
Definition: date.c:456
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
+ Here is the call graph for this function:

◆ folder_date_format()

static void folder_date_format ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Browser: Last modified ($date_format) - Implements get_string_t -.

Definition at line 81 of file expando.c.

83{
84 const struct Folder *folder = data;
85 if (!folder->ff->local)
86 return;
87
88 char tmp[128] = { 0 };
89 bool use_c_locale = false;
90 const char *const c_date_format = cs_subset_string(NeoMutt->sub, "date_format");
91 const char *t_fmt = NONULL(c_date_format);
92 if (*t_fmt == '!')
93 {
94 t_fmt++;
95 use_c_locale = true;
96 }
97
98 if (use_c_locale)
99 {
100 mutt_date_localtime_format_locale(tmp, sizeof(tmp), t_fmt,
101 folder->ff->mtime, NeoMutt->time_c_locale);
102 }
103 else
104 {
105 mutt_date_localtime_format(tmp, sizeof(tmp), t_fmt, folder->ff->mtime);
106 }
107
108 buf_strcpy(buf, tmp);
109}
const char * cs_subset_string(const struct ConfigSubset *sub, const char *name)
Get a string config item by name.
Definition: helpers.c:291
size_t mutt_date_localtime_format_locale(char *buf, size_t buflen, const char *format, time_t t, locale_t loc)
Format localtime using a given locale.
Definition: date.c:969
#define NONULL(x)
Definition: string2.h:37
locale_t time_c_locale
Current locale but LC_TIME=C.
Definition: neomutt.h:48
+ Here is the call graph for this function:

◆ folder_date_strf()

static void folder_date_strf ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Browser: Last modified (strftime) - Implements get_string_t -.

Definition at line 126 of file expando.c.

128{
129 const struct Folder *folder = data;
130
131 if (!folder->ff->local)
132 return;
133
134 bool use_c_locale = false;
135 const char *text = node->text;
136 if (*text == '!')
137 {
138 use_c_locale = true;
139 text++;
140 }
141
142 char tmp[128] = { 0 };
143 struct tm tm = mutt_date_localtime(folder->ff->mtime);
144
145 if (use_c_locale)
146 {
147 strftime_l(tmp, sizeof(tmp), text, &tm, NeoMutt->time_c_locale);
148 }
149 else
150 {
151 strftime(tmp, sizeof(tmp), text, &tm);
152 }
153
154 buf_strcpy(buf, tmp);
155}
struct tm mutt_date_localtime(time_t t)
Converts calendar time to a broken-down time structure expressed in user timezone.
Definition: date.c:906
const char * text
Node-specific text.
Definition: node.h:73
+ Here is the call graph for this function:

◆ folder_description()

static void folder_description ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Browser: Description - Implements get_string_t -.

Definition at line 173 of file expando.c.

175{
176 const struct Folder *folder = data;
177
178 const char *s = NULL;
179 if (folder->ff->desc)
180 s = folder->ff->desc;
181 else
182 s = folder->ff->name;
183
184 buf_printf(buf, "%s%s", s,
185 folder->ff->local ?
186 (S_ISLNK(folder->ff->mode) ?
187 "@" :
188 (S_ISDIR(folder->ff->mode) ?
189 "/" :
190 (((folder->ff->mode & S_IXUSR) != 0) ? "*" : ""))) :
191 "");
192}
char * name
Name of file/dir/mailbox.
Definition: lib.h:86
char * desc
Description of mailbox.
Definition: lib.h:87
mode_t mode
File permissions.
Definition: lib.h:79
+ Here is the call graph for this function:

◆ folder_filename()

static void folder_filename ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Browser: Filename - Implements get_string_t -.

Definition at line 197 of file expando.c.

199{
200 const struct Folder *folder = data;
201
202 const char *s = NONULL(folder->ff->name);
203
204 buf_printf(buf, "%s%s", s,
205 folder->ff->local ?
206 (S_ISLNK(folder->ff->mode) ?
207 "@" :
208 (S_ISDIR(folder->ff->mode) ?
209 "/" :
210 (((folder->ff->mode & S_IXUSR) != 0) ? "*" : ""))) :
211 "");
212}
+ Here is the call graph for this function:

◆ folder_file_group()

static void folder_file_group ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Browser: Group name - Implements get_string_t -.

Definition at line 217 of file expando.c.

219{
220 const struct Folder *folder = data;
221 if (!folder->ff->local)
222 return;
223
224 struct group *gr = getgrgid(folder->ff->gid);
225 if (gr)
226 {
227 buf_addstr(buf, gr->gr_name);
228 }
229 else
230 {
231 buf_printf(buf, "%u", folder->ff->gid);
232 }
233}
gid_t gid
File's Group ID.
Definition: lib.h:83
+ Here is the call graph for this function:

◆ folder_file_mode()

static void folder_file_mode ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Browser: File permissions - Implements get_string_t -.

Definition at line 238 of file expando.c.

240{
241 const struct Folder *folder = data;
242
243 if (folder->ff->local)
244 {
245 buf_printf(buf, "%c%c%c%c%c%c%c%c%c%c",
246 S_ISDIR(folder->ff->mode) ? 'd' : (S_ISLNK(folder->ff->mode) ? 'l' : '-'),
247 ((folder->ff->mode & S_IRUSR) != 0) ? 'r' : '-',
248 ((folder->ff->mode & S_IWUSR) != 0) ? 'w' : '-',
249 ((folder->ff->mode & S_ISUID) != 0) ? 's' :
250 ((folder->ff->mode & S_IXUSR) != 0) ? 'x' :
251 '-',
252 ((folder->ff->mode & S_IRGRP) != 0) ? 'r' : '-',
253 ((folder->ff->mode & S_IWGRP) != 0) ? 'w' : '-',
254 ((folder->ff->mode & S_ISGID) != 0) ? 's' :
255 ((folder->ff->mode & S_IXGRP) != 0) ? 'x' :
256 '-',
257 ((folder->ff->mode & S_IROTH) != 0) ? 'r' : '-',
258 ((folder->ff->mode & S_IWOTH) != 0) ? 'w' : '-',
259 ((folder->ff->mode & S_ISVTX) != 0) ? 't' :
260 ((folder->ff->mode & S_IXOTH) != 0) ? 'x' :
261 '-');
262 }
263 else if (folder->ff->imap)
264 {
265 /* mark folders with subfolders AND mail */
266 buf_printf(buf, "IMAP %c", (folder->ff->inferiors && folder->ff->selectable) ? '+' : ' ');
267 }
268}
bool selectable
Folder can be selected.
Definition: lib.h:96
bool imap
This is an IMAP folder.
Definition: lib.h:95
bool inferiors
Folder has children.
Definition: lib.h:97
+ Here is the call graph for this function:

◆ folder_file_owner()

static void folder_file_owner ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Browser: Owner name - Implements get_string_t -.

Definition at line 273 of file expando.c.

275{
276 const struct Folder *folder = data;
277 if (!folder->ff->local)
278 return;
279
280 struct passwd *pw = getpwuid(folder->ff->uid);
281 if (pw)
282 {
283 buf_addstr(buf, pw->pw_name);
284 }
285 else
286 {
287 buf_printf(buf, "%u", folder->ff->uid);
288 }
289}
uid_t uid
File's User ID.
Definition: lib.h:82
+ Here is the call graph for this function:

◆ folder_file_size()

static void folder_file_size ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Browser: Size in bytes - Implements get_string_t -.

Definition at line 294 of file expando.c.

296{
297 const struct Folder *folder = data;
298
299 char tmp[128] = { 0 };
300
301 mutt_str_pretty_size(tmp, sizeof(tmp), folder->ff->size);
302 buf_strcpy(buf, tmp);
303}
off_t size
File size.
Definition: lib.h:80
+ Here is the call graph for this function:

◆ folder_hard_links()

static void folder_hard_links ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Browser: Hard links - Implements get_string_t -.

Definition at line 317 of file expando.c.

319{
320 const struct Folder *folder = data;
321 if (!folder->ff->local)
322 return;
323
324 buf_add_printf(buf, "%d", (int) folder->ff->nlink);
325}
nlink_t nlink
Number of hard links.
Definition: lib.h:84
+ Here is the call graph for this function:

◆ folder_message_count()

static void folder_message_count ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Browser: Number of messages - Implements get_string_t -.

Definition at line 343 of file expando.c.

345{
346 const struct Folder *folder = data;
347 if (!folder->ff->has_mailbox)
348 return;
349
350 buf_add_printf(buf, "%d", folder->ff->msg_count);
351}
bool has_mailbox
This is a mailbox.
Definition: lib.h:98
int msg_count
total number of messages
Definition: lib.h:90
+ Here is the call graph for this function:

◆ folder_new_mail()

static void folder_new_mail ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Browser: New mail flag - Implements get_string_t -.

Definition at line 370 of file expando.c.

372{
373 const struct Folder *folder = data;
374
375 // NOTE(g0mb4): use $to_chars?
376 const char *s = folder->ff->has_new_mail ? "N" : " ";
377 buf_strcpy(buf, s);
378}
bool has_new_mail
true if mailbox has "new mail"
Definition: lib.h:89
+ Here is the call graph for this function:

◆ folder_tagged()

static void folder_tagged ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Browser: Is Tagged - Implements get_string_t -.

Definition at line 422 of file expando.c.

424{
425 const struct Folder *folder = data;
426
427 // NOTE(g0mb4): use $to_chars?
428 const char *s = folder->ff->tagged ? "*" : " ";
429 buf_strcpy(buf, s);
430}
bool tagged
Folder is tagged.
Definition: lib.h:102
+ Here is the call graph for this function:

◆ folder_unread_count()

static void folder_unread_count ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Browser: Number of unread messages - Implements get_string_t -.

Definition at line 444 of file expando.c.

446{
447 const struct Folder *folder = data;
448 if (!folder->ff->has_mailbox)
449 return;
450
451 buf_add_printf(buf, "%d", folder->ff->msg_unread);
452}
int msg_unread
number of unread messages
Definition: lib.h:91
+ Here is the call graph for this function:

◆ global_padding_space()

static void global_padding_space ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Fixed whitespace - Implements get_string_t -.

Definition at line 471 of file expando.c.

473{
474 buf_addstr(buf, " ");
475}
+ Here is the call graph for this function:

◆ compress_from()

static void compress_from ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Compress: From filename - Implements get_string_t -.

Definition at line 40 of file expando.c.

42{
43 const struct Mailbox *m = data;
44
45 struct Buffer *quoted = buf_pool_get();
46 buf_quote_filename(quoted, m->realpath, false);
47 buf_copy(buf, quoted);
48 buf_pool_release(&quoted);
49}
void buf_quote_filename(struct Buffer *buf, const char *filename, bool add_outer)
Quote a filename to survive the shell's quoting rules.
Definition: file.c:933
A mailbox.
Definition: mailbox.h:79
char * realpath
Used for duplicate detection, context comparison, and the sidebar.
Definition: mailbox.h:81
+ Here is the call graph for this function:

◆ compress_to()

static void compress_to ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Compress: To filename - Implements get_string_t -.

Definition at line 54 of file expando.c.

56{
57 const struct Mailbox *m = data;
58
59 struct Buffer *quoted = buf_pool_get();
60 buf_quote_filename(quoted, mailbox_path(m), false);
61 buf_copy(buf, quoted);
62 buf_pool_release(&quoted);
63}
static const char * mailbox_path(const struct Mailbox *m)
Get the Mailbox's path string.
Definition: mailbox.h:223
+ Here is the call graph for this function:

◆ compose_attach_size()

static void compose_attach_size ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Compose: Size in bytes - Implements get_string_t -.

Definition at line 59 of file expando.c.

61{
62 const struct ComposeSharedData *shared = data;
63
64 char tmp[128] = { 0 };
65
66 mutt_str_pretty_size(tmp, sizeof(tmp), cum_attachs_size(shared->sub, shared->adata));
67 buf_strcpy(buf, tmp);
68}
unsigned long cum_attachs_size(struct ConfigSubset *sub, struct ComposeAttachData *adata)
Cumulative Attachments Size.
Definition: attach.c:84
Shared Compose Data.
Definition: shared_data.h:35
struct ConfigSubset * sub
Config set to use.
Definition: shared_data.h:36
struct ComposeAttachData * adata
Attachments.
Definition: shared_data.h:39
+ Here is the call graph for this function:

◆ global_hostname()

static void global_hostname ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Compose: Hostname - Implements get_string_t -.

Definition at line 83 of file expando.c.

85{
86 const char *s = ShortHostname;
87 buf_strcpy(buf, s);
88}
char * ShortHostname
Short version of the hostname.
Definition: globals.c:38
+ Here is the call graph for this function:

◆ global_version()

static void global_version ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Compose: Version - Implements get_string_t -.

Definition at line 93 of file expando.c.

95{
96 const char *s = mutt_make_version();
97 buf_strcpy(buf, s);
98}
const char * mutt_make_version(void)
Generate the NeoMutt version string.
Definition: muttlib.c:858
+ Here is the call graph for this function:

◆ history_match()

static void history_match ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

History: History match - Implements get_string_t -.

Definition at line 49 of file expando.c.

51{
52 const struct HistoryEntry *entry = data;
53
54 const char *s = entry->history;
55 buf_strcpy(buf, s);
56}
A line in the History menu.
Definition: lib.h:67
const char * history
Description of history.
Definition: lib.h:69
+ Here is the call graph for this function:

◆ email_body_characters()

static void email_body_characters ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Number of raw bytes - Implements get_string_t -.

Definition at line 400 of file expando_index.c.

402{
403 const struct HdrFormatInfo *hfi = (const struct HdrFormatInfo *) data;
404 const struct Email *e = hfi->email;
405 if (!e)
406 return;
407
408 char tmp[128] = { 0 };
409
410 if (flags & MUTT_FORMAT_INDEX)
412
413 mutt_str_pretty_size(tmp, sizeof(tmp), email_get_size(e));
414 buf_strcpy(buf, tmp);
415}
@ MT_COLOR_INDEX_SIZE
Index: size field.
Definition: color.h:90
size_t email_get_size(const struct Email *e)
Compute the size of an email.
Definition: email.c:121
#define MUTT_FORMAT_INDEX
This is a main index entry.
Definition: render.h:38
The envelope/body of an email.
Definition: email.h:39
Data passed to index_format_str()
Definition: private.h:37
struct Email * email
Current Email.
Definition: private.h:40
+ Here is the call graph for this function:

◆ email_combined_flags()

static void email_combined_flags ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Status flags - Implements get_string_t -.

Definition at line 420 of file expando_index.c.

422{
423 const struct HdrFormatInfo *hfi = data;
424 struct Email *e = hfi->email;
425 if (!e)
426 return;
427
428 const int msg_in_pager = hfi->msg_in_pager;
429
430 const struct MbTable *c_crypt_chars = cs_subset_mbtable(NeoMutt->sub, "crypt_chars");
431 const struct MbTable *c_flag_chars = cs_subset_mbtable(NeoMutt->sub, "flag_chars");
432 const struct MbTable *c_to_chars = cs_subset_mbtable(NeoMutt->sub, "to_chars");
433 const bool threads = mutt_using_threads();
434
435 const char *first = NULL;
436 if (threads && thread_is_new(e))
437 {
438 first = mbtable_get_nth_wchar(c_flag_chars, FLAG_CHAR_NEW_THREAD);
439 }
440 else if (threads && thread_is_old(e))
441 {
442 first = mbtable_get_nth_wchar(c_flag_chars, FLAG_CHAR_OLD_THREAD);
443 }
444 else if (e->read && (msg_in_pager != e->msgno))
445 {
446 if (e->replied)
447 {
448 first = mbtable_get_nth_wchar(c_flag_chars, FLAG_CHAR_REPLIED);
449 }
450 else
451 {
452 first = mbtable_get_nth_wchar(c_flag_chars, FLAG_CHAR_ZEMPTY);
453 }
454 }
455 else
456 {
457 if (e->old)
458 {
459 first = mbtable_get_nth_wchar(c_flag_chars, FLAG_CHAR_OLD);
460 }
461 else
462 {
463 first = mbtable_get_nth_wchar(c_flag_chars, FLAG_CHAR_NEW);
464 }
465 }
466
467 /* Marked for deletion; deleted attachments; crypto */
468 const char *second = NULL;
469 if (e->deleted)
470 second = mbtable_get_nth_wchar(c_flag_chars, FLAG_CHAR_DELETED);
471 else if (e->attach_del)
472 second = mbtable_get_nth_wchar(c_flag_chars, FLAG_CHAR_DELETED_ATTACH);
473 else if ((WithCrypto != 0) && (e->security & SEC_GOODSIGN))
474 second = mbtable_get_nth_wchar(c_crypt_chars, FLAG_CHAR_CRYPT_GOOD_SIGN);
475 else if ((WithCrypto != 0) && (e->security & SEC_ENCRYPT))
476 second = mbtable_get_nth_wchar(c_crypt_chars, FLAG_CHAR_CRYPT_ENCRYPTED);
477 else if ((WithCrypto != 0) && (e->security & SEC_SIGN))
478 second = mbtable_get_nth_wchar(c_crypt_chars, FLAG_CHAR_CRYPT_SIGNED);
479 else if (((WithCrypto & APPLICATION_PGP) != 0) && (e->security & PGP_KEY))
481 else
482 second = mbtable_get_nth_wchar(c_crypt_chars, FLAG_CHAR_CRYPT_NO_CRYPTO);
483
484 /* Tagged, flagged and recipient flag */
485 const char *third = NULL;
486 if (e->tagged)
487 third = mbtable_get_nth_wchar(c_flag_chars, FLAG_CHAR_TAGGED);
488 else if (e->flagged)
489 third = mbtable_get_nth_wchar(c_flag_chars, FLAG_CHAR_IMPORTANT);
490 else
491 third = mbtable_get_nth_wchar(c_to_chars, user_is_recipient(e));
492
493 if (flags & MUTT_FORMAT_INDEX)
495
496 buf_printf(buf, "%s%s%s", first, second, third);
497}
@ MT_COLOR_INDEX_FLAGS
Index: flags field.
Definition: color.h:87
struct MbTable * cs_subset_mbtable(const struct ConfigSubset *sub, const char *name)
Get a Multibyte table config item by name.
Definition: helpers.c:119
static bool thread_is_old(struct Email *e)
Does the email thread contain any unread emails?
static enum ToChars user_is_recipient(struct Email *e)
Is the user a recipient of the message.
static bool thread_is_new(struct Email *e)
Does the email thread contain any new emails?
@ FLAG_CHAR_CRYPT_CONTAINS_KEY
Character denoting a message contains a PGP key.
Definition: expando_index.h:58
@ FLAG_CHAR_CRYPT_SIGNED
Character denoting a message is signed.
Definition: expando_index.h:57
@ FLAG_CHAR_CRYPT_NO_CRYPTO
Character denoting a message has no cryptography information.
Definition: expando_index.h:59
@ FLAG_CHAR_CRYPT_GOOD_SIGN
Character denoting a message signed with a verified key.
Definition: expando_index.h:55
@ FLAG_CHAR_CRYPT_ENCRYPTED
Character denoting a message is PGP-encrypted.
Definition: expando_index.h:56
@ FLAG_CHAR_OLD
Character denoting an email that has been read.
Definition: expando_index.h:42
@ FLAG_CHAR_REPLIED
Character denoting an email that has been replied to.
Definition: expando_index.h:41
@ FLAG_CHAR_OLD_THREAD
Character denoting a thread of emails that has been read.
Definition: expando_index.h:44
@ FLAG_CHAR_ZEMPTY
Character denoting a read email, $index_format Z expando.
Definition: expando_index.h:47
@ FLAG_CHAR_TAGGED
Character denoting a tagged email.
Definition: expando_index.h:37
@ FLAG_CHAR_NEW
Character denoting an unread email.
Definition: expando_index.h:43
@ FLAG_CHAR_DELETED
Character denoting a deleted email.
Definition: expando_index.h:39
@ FLAG_CHAR_NEW_THREAD
Character denoting a thread containing at least one new email.
Definition: expando_index.h:45
@ FLAG_CHAR_DELETED_ATTACH
Character denoting a deleted attachment.
Definition: expando_index.h:40
@ FLAG_CHAR_IMPORTANT
Character denoting a important (flagged) email.
Definition: expando_index.h:38
const char * mbtable_get_nth_wchar(const struct MbTable *table, int index)
Extract one char from a multi-byte table.
Definition: mbtable.c:331
#define mutt_using_threads()
Definition: mutt_thread.h:114
#define SEC_GOODSIGN
Email has a valid signature.
Definition: lib.h:86
#define APPLICATION_PGP
Use PGP to encrypt/sign.
Definition: lib.h:96
#define SEC_ENCRYPT
Email is encrypted.
Definition: lib.h:84
#define PGP_KEY
Definition: lib.h:105
#define WithCrypto
Definition: lib.h:122
#define SEC_SIGN
Email is signed.
Definition: lib.h:85
bool read
Email is read.
Definition: email.h:50
SecurityFlags security
bit 0-10: flags, bit 11,12: application, bit 13: traditional pgp See: ncrypt/lib.h pgplib....
Definition: email.h:43
bool old
Email is seen, but unread.
Definition: email.h:49
bool attach_del
Has an attachment marked for deletion.
Definition: email.h:99
bool flagged
Marked important?
Definition: email.h:47
bool replied
Email has been replied to.
Definition: email.h:51
int msgno
Number displayed to the user.
Definition: email.h:111
bool deleted
Email is deleted.
Definition: email.h:78
bool tagged
Email is tagged.
Definition: email.h:107
int msg_in_pager
Index of Email displayed in the Pager.
Definition: private.h:39
Multibyte character table.
Definition: mbtable.h:36
+ Here is the call graph for this function:

◆ email_crypto_flags()

static void email_crypto_flags ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Message crypto flags - Implements get_string_t -.

Definition at line 502 of file expando_index.c.

504{
505 const struct HdrFormatInfo *hfi = data;
506 const struct Email *e = hfi->email;
507 if (!e)
508 return;
509
510 const struct MbTable *c_crypt_chars = cs_subset_mbtable(NeoMutt->sub, "crypt_chars");
511
512 const char *ch = NULL;
513 if ((WithCrypto != 0) && (e->security & SEC_GOODSIGN))
514 {
516 }
517 else if ((WithCrypto != 0) && (e->security & SEC_ENCRYPT))
518 {
520 }
521 else if ((WithCrypto != 0) && (e->security & SEC_SIGN))
522 {
524 }
525 else if (((WithCrypto & APPLICATION_PGP) != 0) && ((e->security & PGP_KEY) == PGP_KEY))
526 {
528 }
529 else
530 {
532 }
533
534 if (flags & MUTT_FORMAT_INDEX)
536 buf_strcpy(buf, ch);
537}
+ Here is the call graph for this function:

◆ email_date_format()

static void email_date_format ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Sent date and time - Implements get_string_t -.

Definition at line 542 of file expando_index.c.

544{
545 const struct HdrFormatInfo *hfi = data;
546 const struct Email *e = hfi->email;
547 if (!e)
548 return;
549
550 const char *c_date_format = cs_subset_string(NeoMutt->sub, "date_format");
551 const char *cp = NONULL(c_date_format);
552
553 index_email_date(node, e, SENT_SENDER, flags, buf, cp);
554}
static void index_email_date(const struct ExpandoNode *node, const struct Email *e, enum IndexDateChoice which, MuttFormatFlags flags, struct Buffer *buf, const char *format)
Index: Sent/Received Local/Sender date and time.
@ SENT_SENDER
Date sent in the sender's timezone.
Definition: expando_index.c:88
+ Here is the call graph for this function:

◆ email_date_format_local()

static void email_date_format_local ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Sent local date and time - Implements get_string_t -.

Definition at line 559 of file expando_index.c.

561{
562 const struct HdrFormatInfo *hfi = data;
563 const struct Email *e = hfi->email;
564 if (!e)
565 return;
566
567 const char *c_date_format = cs_subset_string(NeoMutt->sub, "date_format");
568 const char *cp = NONULL(c_date_format);
569
570 index_email_date(node, e, SENT_LOCAL, flags, buf, cp);
571}
@ SENT_LOCAL
Date sent in the local timezone.
Definition: expando_index.c:89
+ Here is the call graph for this function:

◆ email_date_strf()

static void email_date_strf ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Sent date and time - Implements get_string_t -.

Definition at line 603 of file expando_index.c.

605{
606 const struct HdrFormatInfo *hfi = data;
607 const struct Email *e = hfi->email;
608 if (!e)
609 return;
610
611 index_email_date(node, e, SENT_SENDER, flags, buf, node->text);
612}
+ Here is the call graph for this function:

◆ email_date_strf_local()

static void email_date_strf_local ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Sent local date and time - Implements get_string_t -.

Definition at line 630 of file expando_index.c.

632{
633 const struct HdrFormatInfo *hfi = data;
634 const struct Email *e = hfi->email;
635 if (!e)
636 return;
637
638 index_email_date(node, e, SENT_LOCAL, flags, buf, node->text);
639}
+ Here is the call graph for this function:

◆ email_flag_chars()

static void email_flag_chars ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Status flag - Implements get_string_t -.

Definition at line 658 of file expando_index.c.

660{
661 const struct HdrFormatInfo *hfi = data;
662 const struct Email *e = hfi->email;
663 if (!e)
664 return;
665
666 const struct MbTable *c_flag_chars = cs_subset_mbtable(NeoMutt->sub, "flag_chars");
667 const int msg_in_pager = hfi->msg_in_pager;
668
669 const char *wch = NULL;
670 if (e->deleted)
671 wch = mbtable_get_nth_wchar(c_flag_chars, FLAG_CHAR_DELETED);
672 else if (e->attach_del)
674 else if (e->tagged)
675 wch = mbtable_get_nth_wchar(c_flag_chars, FLAG_CHAR_TAGGED);
676 else if (e->flagged)
677 wch = mbtable_get_nth_wchar(c_flag_chars, FLAG_CHAR_IMPORTANT);
678 else if (e->replied)
679 wch = mbtable_get_nth_wchar(c_flag_chars, FLAG_CHAR_REPLIED);
680 else if (e->read && (msg_in_pager != e->msgno))
681 wch = mbtable_get_nth_wchar(c_flag_chars, FLAG_CHAR_SEMPTY);
682 else if (e->old)
683 wch = mbtable_get_nth_wchar(c_flag_chars, FLAG_CHAR_OLD);
684 else
685 wch = mbtable_get_nth_wchar(c_flag_chars, FLAG_CHAR_NEW);
686
687 if (flags & MUTT_FORMAT_INDEX)
689
690 buf_strcpy(buf, wch);
691}
@ FLAG_CHAR_SEMPTY
Character denoting a read email, $index_format S expando.
Definition: expando_index.h:46
+ Here is the call graph for this function:

◆ email_from_list()

static void email_from_list ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: List address - Implements get_string_t -.

Definition at line 696 of file expando_index.c.

698{
699 const struct HdrFormatInfo *hfi = data;
700 const struct Email *e = hfi->email;
701 if (!e)
702 return;
703
704 char tmp[128] = { 0 };
705
706 make_from(e->env, tmp, sizeof(tmp), true, flags);
707
708 if (flags & MUTT_FORMAT_INDEX)
710 buf_strcpy(buf, tmp);
711}
@ MT_COLOR_INDEX_AUTHOR
Index: author field.
Definition: color.h:84
static void make_from(struct Envelope *env, char *buf, size_t buflen, bool do_lists, MuttFormatFlags flags)
Generate a From: field (with optional prefix)
struct Envelope * env
Envelope information.
Definition: email.h:68
+ Here is the call graph for this function:

◆ email_index_hook()

static void email_index_hook ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: index-format-hook - Implements get_string_t -.

Definition at line 716 of file expando_index.c.

718{
719 const struct HdrFormatInfo *hfi = data;
720 struct Email *e = hfi->email;
721 if (!e)
722 return;
723
724 struct Mailbox *m = hfi->mailbox;
725
726 const struct Expando *exp = mutt_idxfmt_hook(node->text, m, e);
727 if (!exp)
728 return;
729
731}
int expando_filter(const struct Expando *exp, const struct ExpandoRenderCallback *erc, void *data, MuttFormatFlags flags, int max_cols, struct Buffer *buf)
Render an Expando and run the result through a filter.
Definition: filter.c:138
const struct ExpandoRenderCallback IndexRenderCallbacks[]
Callbacks for Index Expandos.
const struct Expando * mutt_idxfmt_hook(const char *name, struct Mailbox *m, struct Email *e)
Get index-format-hook format string.
Definition: hook.c:990
#define MUTT_FORMAT_NO_FLAGS
No flags are set.
Definition: render.h:33
size_t dsize
Length of data.
Definition: buffer.h:39
struct Mailbox * mailbox
Current Mailbox.
Definition: private.h:38
+ Here is the call graph for this function:

◆ email_list_or_save_folder()

static void email_list_or_save_folder ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: List Name or Save folder - Implements get_string_t -.

Definition at line 752 of file expando_index.c.

754{
755 const struct HdrFormatInfo *hfi = data;
756 const struct Email *e = hfi->email;
757 if (!e || !e->env)
758 return;
759
760 char tmp[128] = { 0 };
761 char *p = NULL;
762
763 make_from_addr(e->env, tmp, sizeof(tmp), true);
764 const bool c_save_address = cs_subset_bool(NeoMutt->sub, "save_address");
765 if (!c_save_address && (p = strpbrk(tmp, "%@")))
766 {
767 *p = '\0';
768 }
769
770 buf_strcpy(buf, tmp);
771}
bool cs_subset_bool(const struct ConfigSubset *sub, const char *name)
Get a boolean config item by name.
Definition: helpers.c:47
static void make_from_addr(struct Envelope *env, char *buf, size_t buflen, bool do_lists)
Create a 'from' address for a reply email.
+ Here is the call graph for this function:

◆ email_message_flags()

static void email_message_flags ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Message tag flags - Implements get_string_t -.

Definition at line 776 of file expando_index.c.

778{
779 const struct HdrFormatInfo *hfi = data;
780 struct Email *e = hfi->email;
781 if (!e)
782 return;
783
784 const struct MbTable *c_flag_chars = cs_subset_mbtable(NeoMutt->sub, "flag_chars");
785 const struct MbTable *c_to_chars = cs_subset_mbtable(NeoMutt->sub, "to_chars");
786
787 const char *ch = NULL;
788 if (e->tagged)
789 {
790 ch = mbtable_get_nth_wchar(c_flag_chars, FLAG_CHAR_TAGGED);
791 }
792 else if (e->flagged)
793 {
794 ch = mbtable_get_nth_wchar(c_flag_chars, FLAG_CHAR_IMPORTANT);
795 }
796 else
797 {
798 ch = mbtable_get_nth_wchar(c_to_chars, user_is_recipient(e));
799 }
800
801 if (flags & MUTT_FORMAT_INDEX)
803 buf_strcpy(buf, ch);
804}
+ Here is the call graph for this function:

◆ email_size()

static void email_size ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Number of bytes - Implements get_string_t -.

Definition at line 838 of file expando_index.c.

840{
841 const struct HdrFormatInfo *hfi = data;
842 const struct Email *e = hfi->email;
843 if (!e)
844 return;
845
846 char tmp[128] = { 0 };
847
848 if (flags & MUTT_FORMAT_INDEX)
850
851 mutt_str_pretty_size(tmp, sizeof(tmp), e->body->length);
852 buf_strcpy(buf, tmp);
853}
struct Body * body
List of MIME parts.
Definition: email.h:69
+ Here is the call graph for this function:

◆ email_status_flags()

static void email_status_flags ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Message status flags - Implements get_string_t -.

Definition at line 871 of file expando_index.c.

873{
874 const struct HdrFormatInfo *hfi = data;
875 struct Email *e = hfi->email;
876 if (!e)
877 return;
878
879 const bool threads = mutt_using_threads();
880 const struct MbTable *c_flag_chars = cs_subset_mbtable(NeoMutt->sub, "flag_chars");
881 const int msg_in_pager = hfi->msg_in_pager;
882
883 const char *ch = NULL;
884 if (e->deleted)
885 {
886 ch = mbtable_get_nth_wchar(c_flag_chars, FLAG_CHAR_DELETED);
887 }
888 else if (e->attach_del)
889 {
891 }
892 else if (threads && thread_is_new(e))
893 {
895 }
896 else if (threads && thread_is_old(e))
897 {
899 }
900 else if (e->read && (msg_in_pager != e->msgno))
901 {
902 if (e->replied)
903 {
904 ch = mbtable_get_nth_wchar(c_flag_chars, FLAG_CHAR_REPLIED);
905 }
906 else
907 {
908 ch = mbtable_get_nth_wchar(c_flag_chars, FLAG_CHAR_ZEMPTY);
909 }
910 }
911 else
912 {
913 if (e->old)
914 {
915 ch = mbtable_get_nth_wchar(c_flag_chars, FLAG_CHAR_OLD);
916 }
917 else
918 {
919 ch = mbtable_get_nth_wchar(c_flag_chars, FLAG_CHAR_NEW);
920 }
921 }
922
923 if (flags & MUTT_FORMAT_INDEX)
925 buf_strcpy(buf, ch);
926}
+ Here is the call graph for this function:

◆ email_strf_recv_local()

static void email_strf_recv_local ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Received local date and time - Implements get_string_t -.

Definition at line 931 of file expando_index.c.

933{
934 const struct HdrFormatInfo *hfi = data;
935 const struct Email *e = hfi->email;
936 if (!e)
937 return;
938
939 index_email_date(node, e, RECV_LOCAL, flags, buf, node->text);
940}
@ RECV_LOCAL
Date received in the local timezone.
Definition: expando_index.c:90
+ Here is the call graph for this function:

◆ email_tags()

static void email_tags ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Message tags - Implements get_string_t -.

Definition at line 959 of file expando_index.c.

961{
962 const struct HdrFormatInfo *hfi = data;
963 struct Email *e = hfi->email;
964 if (!e)
965 return;
966
967 if (flags & MUTT_FORMAT_INDEX)
970}
@ MT_COLOR_INDEX_TAGS
Index: tags field (g, J)
Definition: color.h:93
struct TagList tags
For drivers that support server tagging.
Definition: email.h:72
void driver_tags_get_transformed(struct TagList *tl, struct Buffer *tags)
Get transformed tags separated by space.
Definition: tags.c:152
+ Here is the call graph for this function:

◆ email_tags_transformed()

static void email_tags_transformed ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Individual tag - Implements get_string_t -.

Definition at line 975 of file expando_index.c.

977{
978 const struct HdrFormatInfo *hfi = data;
979 struct Email *e = hfi->email;
980 if (!e)
981 return;
982
983 char *tag = mutt_hash_find(TagFormats, node->text);
984 if (!tag)
985 return;
986
987 if (flags & MUTT_FORMAT_INDEX)
990}
@ MT_COLOR_INDEX_TAG
Index: tag field (G)
Definition: color.h:92
void * mutt_hash_find(const struct HashTable *table, const char *strkey)
Find the HashElem data in a Hash Table element using a key.
Definition: hash.c:362
struct HashTable * TagFormats
Hash Table: "inbox" -> "GI" - Tag format strings.
Definition: tags.c:42
void driver_tags_get_transformed_for(struct TagList *tl, const char *name, struct Buffer *tags)
Get transformed tags for a tag name separated by space.
Definition: tags.c:187
+ Here is the call graph for this function:

◆ email_thread_hidden_count()

static void email_thread_hidden_count ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Number of hidden messages - Implements get_string_t -.

Definition at line 1007 of file expando_index.c.

1009{
1010 const struct HdrFormatInfo *hfi = data;
1011 const struct Email *e = hfi->email;
1012 if (!e)
1013 return;
1014
1015 const bool threads = mutt_using_threads();
1016 const bool is_index = (flags & MUTT_FORMAT_INDEX) != 0;
1017
1018 if (threads && is_index && e->collapsed && (e->num_hidden > 1))
1019 {
1020 if (flags & MUTT_FORMAT_INDEX)
1022 const int num = e->num_hidden;
1023 buf_printf(buf, "%d", num);
1024 }
1025 else if (is_index && threads)
1026 {
1027 if (flags & MUTT_FORMAT_INDEX)
1029 const char *s = " ";
1030 buf_strcpy(buf, s);
1031 }
1032}
@ MT_COLOR_INDEX_COLLAPSED
Index: number of messages in collapsed thread.
Definition: color.h:85
bool collapsed
Is this message part of a collapsed thread?
Definition: email.h:120
size_t num_hidden
Number of hidden messages in this view (only valid when collapsed is set)
Definition: email.h:123
+ Here is the call graph for this function:

◆ email_thread_tags()

static void email_thread_tags ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Tags - Implements get_string_t -.

Definition at line 1073 of file expando_index.c.

1075{
1076 const struct HdrFormatInfo *hfi = data;
1077 struct Email *e = hfi->email;
1078 if (!e)
1079 return;
1080
1081 bool have_tags = true;
1082 struct Buffer *tags = buf_pool_get();
1084 if (!buf_is_empty(tags))
1085 {
1086 if (flags & MUTT_FORMAT_TREE)
1087 {
1088 struct Buffer *parent_tags = buf_pool_get();
1089 if (e->thread->prev && e->thread->prev->message)
1090 {
1091 driver_tags_get_transformed(&e->thread->prev->message->tags, parent_tags);
1092 }
1093 if (!parent_tags && e->thread->parent && e->thread->parent->message)
1094 {
1096 }
1097 if (parent_tags && buf_istr_equal(tags, parent_tags))
1098 have_tags = false;
1099 buf_pool_release(&parent_tags);
1100 }
1101 }
1102 else
1103 {
1104 have_tags = false;
1105 }
1106
1107 if (flags & MUTT_FORMAT_INDEX)
1109
1110 const char *s = have_tags ? buf_string(tags) : "";
1111 buf_strcpy(buf, s);
1112
1113 buf_pool_release(&tags);
1114}
bool buf_istr_equal(const struct Buffer *a, const struct Buffer *b)
Return if two buffers are equal, case insensitive.
Definition: buffer.c:697
bool buf_is_empty(const struct Buffer *buf)
Is the Buffer empty?
Definition: buffer.c:291
#define MUTT_FORMAT_TREE
Draw the thread tree.
Definition: render.h:35
struct MuttThread * thread
Thread of Emails.
Definition: email.h:119
struct MuttThread * parent
Parent of this Thread.
Definition: thread.h:44
struct MuttThread * prev
Previous sibling Thread.
Definition: thread.h:47
struct Email * message
Email this Thread refers to.
Definition: thread.h:49
+ Here is the call graph for this function:

◆ email_to_chars()

static void email_to_chars ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: $to_chars flag - Implements get_string_t -.

Definition at line 1119 of file expando_index.c.

1121{
1122 const struct HdrFormatInfo *hfi = data;
1123 struct Email *e = hfi->email;
1124 if (!e)
1125 return;
1126
1127 const struct MbTable *c_to_chars = cs_subset_mbtable(NeoMutt->sub, "to_chars");
1128
1129 int i;
1130 const char *s = (c_to_chars && ((i = user_is_recipient(e))) < c_to_chars->len) ?
1131 c_to_chars->chars[i] :
1132 " ";
1133
1134 buf_strcpy(buf, s);
1135}
int len
Number of characters.
Definition: mbtable.h:38
+ Here is the call graph for this function:

◆ envelope_cc_all()

static void envelope_cc_all ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Cc recipients - Implements get_string_t -.

Definition at line 1140 of file expando_index.c.

1142{
1143 const struct HdrFormatInfo *hfi = data;
1144 const struct Email *e = hfi->email;
1145 if (!e || !e->env)
1146 return;
1147
1148 mutt_addrlist_write(&e->env->cc, buf, true);
1149}
struct AddressList cc
Email's 'Cc' list.
Definition: envelope.h:61
+ Here is the call graph for this function:

◆ envelope_first_name()

static void envelope_first_name ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: First name - Implements get_string_t -.

Definition at line 1154 of file expando_index.c.

1156{
1157 const struct HdrFormatInfo *hfi = data;
1158 const struct Email *e = hfi->email;
1159 if (!e || !e->env)
1160 return;
1161
1162 const struct Address *from = TAILQ_FIRST(&e->env->from);
1163 const struct Address *to = TAILQ_FIRST(&e->env->to);
1164 const struct Address *cc = TAILQ_FIRST(&e->env->cc);
1165
1166 char tmp[128] = { 0 };
1167 char *p = NULL;
1168
1169 if (mutt_addr_is_user(from))
1170 {
1171 if (to)
1172 {
1173 const char *s = mutt_get_name(to);
1174 mutt_str_copy(tmp, NONULL(s), sizeof(tmp));
1175 }
1176 else if (cc)
1177 {
1178 const char *s = mutt_get_name(cc);
1179 mutt_str_copy(tmp, NONULL(s), sizeof(tmp));
1180 }
1181 }
1182 else
1183 {
1184 const char *s = mutt_get_name(from);
1185 mutt_str_copy(tmp, NONULL(s), sizeof(tmp));
1186 }
1187 p = strpbrk(tmp, " %@");
1188 if (p)
1189 {
1190 *p = '\0';
1191 }
1192
1193 buf_strcpy(buf, tmp);
1194}
bool mutt_addr_is_user(const struct Address *addr)
Does the address belong to the user.
Definition: alias.c:600
const char * mutt_get_name(const struct Address *a)
Pick the best name to display from an address.
Definition: sort.c:139
size_t mutt_str_copy(char *dest, const char *src, size_t dsize)
Copy a string into a buffer (guaranteeing NUL-termination)
Definition: string.c:581
#define TAILQ_FIRST(head)
Definition: queue.h:741
struct AddressList to
Email's 'To' list.
Definition: envelope.h:60
struct AddressList from
Email's 'From' list.
Definition: envelope.h:59
+ Here is the call graph for this function:

◆ envelope_from()

static void envelope_from ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Author Address - Implements get_string_t -.

Definition at line 1199 of file expando_index.c.

1201{
1202 const struct HdrFormatInfo *hfi = data;
1203 const struct Email *e = hfi->email;
1204 if (!e || !e->env)
1205 return;
1206
1207 const struct Address *from = TAILQ_FIRST(&e->env->from);
1208
1209 const char *s = NULL;
1210 if (from && from->mailbox)
1211 {
1212 s = mutt_addr_for_display(from);
1213 }
1214
1215 if (flags & MUTT_FORMAT_INDEX)
1217 buf_strcpy(buf, s);
1218}
const char * mutt_addr_for_display(const struct Address *a)
Convert an Address for display purposes.
Definition: address.c:1012
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ envelope_from_full()

static void envelope_from_full ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Sender - Implements get_string_t -.

Definition at line 1223 of file expando_index.c.

1225{
1226 const struct HdrFormatInfo *hfi = data;
1227 struct Email *e = hfi->email;
1228 if (!e || !e->env)
1229 return;
1230
1231 mutt_addrlist_write(&e->env->from, buf, true);
1232}
+ Here is the call graph for this function:

◆ envelope_initials()

static void envelope_initials ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Initials of author - Implements get_string_t -.

Definition at line 1237 of file expando_index.c.

1239{
1240 const struct HdrFormatInfo *hfi = data;
1241 const struct Email *e = hfi->email;
1242 if (!e || !e->env)
1243 return;
1244
1245 const struct Address *from = TAILQ_FIRST(&e->env->from);
1246
1247 char tmp[128] = { 0 };
1248
1249 if (mutt_mb_get_initials(mutt_get_name(from), tmp, sizeof(tmp)))
1250 {
1251 if (flags & MUTT_FORMAT_INDEX)
1253
1254 buf_strcpy(buf, tmp);
1255 return;
1256 }
1257
1258 envelope_from(node, data, flags, buf);
1259}
static void envelope_from(const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
Index: Author Address - Implements get_string_t -.
bool mutt_mb_get_initials(const char *name, char *buf, size_t buflen)
Turn a name into initials.
Definition: mbyte.c:82
+ Here is the call graph for this function:

◆ envelope_list_address()

static void envelope_list_address ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Email list - Implements get_string_t -.

Definition at line 1264 of file expando_index.c.

1266{
1267 const struct HdrFormatInfo *hfi = data;
1268 const struct Email *e = hfi->email;
1269 if (!e || !e->env)
1270 return;
1271
1272 char tmp[128] = { 0 };
1273
1274 if (first_mailing_list(tmp, sizeof(tmp), &e->env->to) ||
1275 first_mailing_list(tmp, sizeof(tmp), &e->env->cc))
1276 {
1277 buf_strcpy(buf, tmp);
1278 return;
1279 }
1280
1281 mailbox_mailbox_name(node, data, flags, buf);
1282}
static void mailbox_mailbox_name(const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
Index: Filename - Implements get_string_t -.
bool first_mailing_list(char *buf, size_t buflen, struct AddressList *al)
Get the first mailing list in the list of addresses.
Definition: maillist.c:124
+ Here is the call graph for this function:

◆ envelope_list_empty()

static void envelope_list_empty ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Mailing list - Implements get_string_t -.

Definition at line 1287 of file expando_index.c.

1289{
1290 const struct HdrFormatInfo *hfi = data;
1291 const struct Email *e = hfi->email;
1292 if (!e || !e->env)
1293 return;
1294
1295 char tmp[128] = { 0 };
1296
1297 if (first_mailing_list(tmp, sizeof(tmp), &e->env->to) ||
1298 first_mailing_list(tmp, sizeof(tmp), &e->env->cc))
1299 {
1300 buf_strcpy(buf, tmp);
1301 }
1302}
+ Here is the call graph for this function:

◆ envelope_message_id()

static void envelope_message_id ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Message-id - Implements get_string_t -.

Definition at line 1307 of file expando_index.c.

1309{
1310 const struct HdrFormatInfo *hfi = data;
1311 struct Email *e = hfi->email;
1312 if (!e || !e->env)
1313 return;
1314
1315 const char *s = e->env->message_id ? e->env->message_id : "<no.id>";
1316 buf_strcpy(buf, s);
1317}
char * message_id
Message ID.
Definition: envelope.h:73
+ Here is the call graph for this function:

◆ envelope_name()

static void envelope_name ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Author's real name - Implements get_string_t -.

Definition at line 1322 of file expando_index.c.

1324{
1325 const struct HdrFormatInfo *hfi = data;
1326 const struct Email *e = hfi->email;
1327 if (!e || !e->env)
1328 return;
1329
1330 const struct Address *from = TAILQ_FIRST(&e->env->from);
1331
1332 if (flags & MUTT_FORMAT_INDEX)
1334
1335 const char *s = mutt_get_name(from);
1336 buf_strcpy(buf, s);
1337}
+ Here is the call graph for this function:

◆ envelope_newsgroup()

static void envelope_newsgroup ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Newsgroup name - Implements get_string_t -.

Definition at line 1342 of file expando_index.c.

1344{
1345 const struct HdrFormatInfo *hfi = data;
1346 const struct Email *e = hfi->email;
1347 if (!e || !e->env)
1348 return;
1349
1350 const char *s = e->env->newsgroups;
1351 buf_strcpy(buf, s);
1352}
char * newsgroups
List of newsgroups.
Definition: envelope.h:78
+ Here is the call graph for this function:

◆ envelope_organization()

static void envelope_organization ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Organization - Implements get_string_t -.

Definition at line 1357 of file expando_index.c.

1359{
1360 const struct HdrFormatInfo *hfi = data;
1361 const struct Email *e = hfi->email;
1362 if (!e || !e->env)
1363 return;
1364
1365 const char *s = e->env->organization;
1366 buf_strcpy(buf, s);
1367}
char * organization
Organisation header.
Definition: envelope.h:77
+ Here is the call graph for this function:

◆ envelope_reply_to()

static void envelope_reply_to ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Reply-to address - Implements get_string_t -.

Definition at line 1372 of file expando_index.c.

1374{
1375 const struct HdrFormatInfo *hfi = data;
1376 const struct Email *e = hfi->email;
1377 if (!e || !e->env)
1378 return;
1379
1380 const struct Address *reply_to = TAILQ_FIRST(&e->env->reply_to);
1381
1382 if (reply_to && reply_to->mailbox)
1383 {
1384 if (flags & MUTT_FORMAT_INDEX)
1386 const char *s = mutt_addr_for_display(reply_to);
1387 buf_strcpy(buf, s);
1388 return;
1389 }
1390
1391 envelope_from(node, data, flags, buf);
1392}
struct AddressList reply_to
Email's 'reply-to'.
Definition: envelope.h:64
+ Here is the call graph for this function:

◆ envelope_sender()

static void envelope_sender ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Author name - Implements get_string_t -.

Definition at line 1397 of file expando_index.c.

1399{
1400 const struct HdrFormatInfo *hfi = data;
1401 struct Email *e = hfi->email;
1402 if (!e || !e->env)
1403 return;
1404
1405 char tmp[128] = { 0 };
1406
1407 make_from(e->env, tmp, sizeof(tmp), false, MUTT_FORMAT_NO_FLAGS);
1408
1409 if (flags & MUTT_FORMAT_INDEX)
1411
1412 buf_strcpy(buf, tmp);
1413}
+ Here is the call graph for this function:

◆ envelope_sender_plain()

static void envelope_sender_plain ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Plain author name - Implements get_string_t -.

Definition at line 1418 of file expando_index.c.

1420{
1421 const struct HdrFormatInfo *hfi = (const struct HdrFormatInfo *) data;
1422 struct Email *e = hfi->email;
1423 if (!e || !e->env)
1424 return;
1425
1426 char tmp[128] = { 0 };
1427
1428 if (flags & MUTT_FORMAT_INDEX)
1430
1431 make_from(e->env, tmp, sizeof(tmp), false, MUTT_FORMAT_PLAIN);
1432
1433 buf_strcpy(buf, tmp);
1434}
#define MUTT_FORMAT_PLAIN
Do not prepend DISP_TO, DISP_CC ...
Definition: render.h:39
+ Here is the call graph for this function:

◆ envelope_spam()

static void envelope_spam ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Spam attributes - Implements get_string_t -.

Definition at line 1439 of file expando_index.c.

1441{
1442 const struct HdrFormatInfo *hfi = data;
1443 struct Email *e = hfi->email;
1444 if (!e || !e->env)
1445 return;
1446
1447 buf_copy(buf, &e->env->spam);
1448}
struct Buffer spam
Spam header.
Definition: envelope.h:82
+ Here is the call graph for this function:

◆ envelope_subject()

static void envelope_subject ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Subject - Implements get_string_t -.

Definition at line 1453 of file expando_index.c.

1455{
1456 const struct HdrFormatInfo *hfi = data;
1457 const struct Email *e = hfi->email;
1458 if (!e || !e->env)
1459 return;
1460
1461 if ((flags & MUTT_FORMAT_TREE) && !e->collapsed && !(flags & MUTT_FORMAT_FORCESUBJ))
1462 return;
1463
1464 if (flags & MUTT_FORMAT_INDEX)
1466
1468
1469 if (e->env->disp_subj)
1470 buf_strcpy(buf, e->env->disp_subj);
1471 else
1472 buf_strcpy(buf, e->env->subject);
1473}
@ MT_COLOR_INDEX_SUBJECT
Index: subject field.
Definition: color.h:91
char *const subject
Email's subject.
Definition: envelope.h:70
char * disp_subj
Display subject (modified copy of subject)
Definition: envelope.h:72
bool subjrx_apply_mods(struct Envelope *env)
Apply regex modifications to the subject.
Definition: subjectrx.c:133
+ Here is the call graph for this function:

◆ envelope_thread_tree()

static void envelope_thread_tree ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Thread tree - Implements get_string_t -.

Definition at line 1478 of file expando_index.c.

1480{
1481 const struct HdrFormatInfo *hfi = data;
1482 const struct Email *e = hfi->email;
1483 if (!e || !e->env)
1484 return;
1485
1486 if (!(flags & MUTT_FORMAT_TREE) || e->collapsed)
1487 return;
1488
1490 node_expando_set_has_tree(node, true);
1491 buf_strcpy(buf, e->tree);
1492}
char * tree
Character string to print thread tree.
Definition: email.h:125
+ Here is the call graph for this function:

◆ envelope_thread_x_label()

static void envelope_thread_x_label ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: X-Label (if different) - Implements get_string_t -.

Definition at line 1497 of file expando_index.c.

1499{
1500 const struct HdrFormatInfo *hfi = data;
1501 const struct Email *e = hfi->email;
1502 if (!e || !e->env)
1503 return;
1504
1505 bool label = true;
1506 if (e->env->x_label)
1507 {
1508 struct Email *e_tmp = NULL;
1509 if (flags & MUTT_FORMAT_TREE && (e->thread->prev && e->thread->prev->message &&
1510 e->thread->prev->message->env->x_label))
1511 {
1512 e_tmp = e->thread->prev->message;
1513 }
1514 else if (flags & MUTT_FORMAT_TREE && (e->thread->parent && e->thread->parent->message &&
1516 {
1517 e_tmp = e->thread->parent->message;
1518 }
1519
1520 if (e_tmp && mutt_istr_equal(e->env->x_label, e_tmp->env->x_label))
1521 {
1522 label = false;
1523 }
1524 }
1525 else
1526 {
1527 label = false;
1528 }
1529
1530 if (flags & MUTT_FORMAT_INDEX)
1532
1533 if (label)
1534 {
1535 const char *s = e->env->x_label;
1536 buf_strcpy(buf, s);
1537 }
1538}
@ MT_COLOR_INDEX_LABEL
Index: label field.
Definition: color.h:88
bool mutt_istr_equal(const char *a, const char *b)
Compare two strings, ignoring case.
Definition: string.c:672
char * x_label
X-Label.
Definition: envelope.h:76
+ Here is the call graph for this function:

◆ envelope_to()

static void envelope_to ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: To field - Implements get_string_t -.

Definition at line 1543 of file expando_index.c.

1545{
1546 const struct HdrFormatInfo *hfi = data;
1547 const struct Email *e = hfi->email;
1548 if (!e || !e->env)
1549 return;
1550
1551 const struct Address *to = TAILQ_FIRST(&e->env->to);
1552 const struct Address *cc = TAILQ_FIRST(&e->env->cc);
1553
1554 char tmp[128] = { 0 };
1555
1556 if (!check_for_mailing_list(&e->env->to, "To ", tmp, sizeof(tmp)) &&
1557 !check_for_mailing_list(&e->env->cc, "Cc ", tmp, sizeof(tmp)))
1558 {
1559 if (to)
1560 snprintf(tmp, sizeof(tmp), "To %s", mutt_get_name(to));
1561 else if (cc)
1562 snprintf(tmp, sizeof(tmp), "Cc %s", mutt_get_name(cc));
1563 else
1564 {
1565 tmp[0] = '\0';
1566 }
1567 }
1568
1569 buf_strcpy(buf, tmp);
1570}
bool check_for_mailing_list(struct AddressList *al, const char *pfx, char *buf, int buflen)
Search list of addresses for a mailing list.
Definition: maillist.c:78
+ Here is the call graph for this function:

◆ envelope_to_all()

static void envelope_to_all ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: To recipients - Implements get_string_t -.

Definition at line 1575 of file expando_index.c.

1577{
1578 const struct HdrFormatInfo *hfi = data;
1579 const struct Email *e = hfi->email;
1580 if (!e || !e->env)
1581 return;
1582
1583 mutt_addrlist_write(&e->env->to, buf, true);
1584}
+ Here is the call graph for this function:

◆ envelope_username()

static void envelope_username ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: User name - Implements get_string_t -.

Definition at line 1589 of file expando_index.c.

1591{
1592 const struct HdrFormatInfo *hfi = data;
1593 const struct Email *e = hfi->email;
1594 if (!e || !e->env)
1595 return;
1596
1597 const struct Address *from = TAILQ_FIRST(&e->env->from);
1598 if (!from || !from->mailbox)
1599 return;
1600
1601 char tmp[128] = { 0 };
1602 char *p = NULL;
1603
1604 mutt_str_copy(tmp, mutt_addr_for_display(from), sizeof(tmp));
1605 p = strpbrk(tmp, "%@");
1606 if (p)
1607 {
1608 *p = '\0';
1609 }
1610
1611 buf_strcpy(buf, tmp);
1612}
+ Here is the call graph for this function:

◆ envelope_x_comment_to()

static void envelope_x_comment_to ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: X-Comment-To - Implements get_string_t -.

Definition at line 1617 of file expando_index.c.

1619{
1620 const struct HdrFormatInfo *hfi = data;
1621 const struct Email *e = hfi->email;
1622 if (!e || !e->env)
1623 return;
1624
1625 const char *s = e->env->x_comment_to;
1626 buf_strcpy(buf, s);
1627}
char * x_comment_to
List of 'X-comment-to' fields.
Definition: envelope.h:81
+ Here is the call graph for this function:

◆ envelope_x_label()

static void envelope_x_label ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: X-Label - Implements get_string_t -.

Definition at line 1632 of file expando_index.c.

1634{
1635 const struct HdrFormatInfo *hfi = data;
1636 const struct Email *e = hfi->email;
1637 if (!e || !e->env)
1638 return;
1639
1640 if (flags & MUTT_FORMAT_INDEX)
1642
1643 const char *s = e->env->x_label;
1644 buf_strcpy(buf, s);
1645}
+ Here is the call graph for this function:

◆ mailbox_mailbox_name()

static void mailbox_mailbox_name ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Filename - Implements get_string_t -.

Definition at line 1650 of file expando_index.c.

1652{
1653 const struct HdrFormatInfo *hfi = data;
1654 struct Mailbox *m = hfi->mailbox;
1655 if (!m)
1656 {
1657 buf_addstr(buf, "(null)");
1658 return;
1659 }
1660
1661 char *p = NULL;
1662
1663#ifdef USE_NOTMUCH
1664 struct Email *e = hfi->email;
1665 if (m->type == MUTT_NOTMUCH)
1666 {
1668 }
1669#endif
1670 if (!p)
1671 {
1672 p = strrchr(mailbox_path(m), '/');
1673 if (p)
1674 {
1675 p++;
1676 }
1677 }
1678 buf_addstr(buf, p ? p : mailbox_path(m));
1679}
@ MUTT_NOTMUCH
'Notmuch' (virtual) Mailbox type
Definition: mailbox.h:51
char * nm_email_get_folder_rel_db(struct Mailbox *m, struct Email *e)
Get the folder for a Email from the same level as the notmuch database.
Definition: notmuch.c:1488
enum MailboxType type
Mailbox type.
Definition: mailbox.h:102
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ mailbox_percentage()

static void mailbox_percentage ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Index: Progress indicator - Implements get_string_t -.

Definition at line 1698 of file expando_index.c.

1700{
1701 const struct HdrFormatInfo *hfi = data;
1702
1703 const char *s = hfi->pager_progress;
1704 buf_strcpy(buf, s);
1705}
const char * pager_progress
String representing Pager position through Email.
Definition: private.h:41
+ Here is the call graph for this function:

◆ global_config_sort()

static void global_config_sort ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Status: Sorting mode - Implements get_string_t -.

Definition at line 76 of file expando_status.c.

78{
79 char tmp[128] = { 0 };
80
81 const enum EmailSortType c_sort = cs_subset_sort(NeoMutt->sub, "sort");
82 const char *s = get_sort_str(tmp, sizeof(tmp), c_sort);
83 buf_strcpy(buf, s);
84}
short cs_subset_sort(const struct ConfigSubset *sub, const char *name)
Get a sort config item by name.
Definition: helpers.c:266
EmailSortType
Methods for sorting Emails.
Definition: sort.h:53
static char * get_sort_str(char *buf, size_t buflen, enum EmailSortType method)
Get the sort method as a string.
+ Here is the call graph for this function:

◆ global_config_sort_aux()

static void global_config_sort_aux ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Status: Aux sorting method - Implements get_string_t -.

Definition at line 89 of file expando_status.c.

91{
92 char tmp[128] = { 0 };
93
94 const enum EmailSortType c_sort_aux = cs_subset_sort(NeoMutt->sub, "sort_aux");
95 const char *s = get_sort_str(tmp, sizeof(tmp), c_sort_aux);
96 buf_strcpy(buf, s);
97}
+ Here is the call graph for this function:

◆ global_config_use_threads()

static void global_config_use_threads ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Status: Current threading mode - Implements get_string_t -.

Definition at line 102 of file expando_status.c.

104{
105 const enum UseThreads c_use_threads = mutt_thread_style();
106 const char *s = get_use_threads_str(c_use_threads);
107 buf_strcpy(buf, s);
108}
const char * get_use_threads_str(enum UseThreads value)
Convert UseThreads enum to string.
Definition: mutt_thread.c:99
enum UseThreads mutt_thread_style(void)
Which threading style is active?
Definition: mutt_thread.c:81
UseThreads
Which threading style is active, $use_threads.
Definition: mutt_thread.h:97
+ Here is the call graph for this function:

◆ index_description()

static void index_description ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Status: Description of the mailbox - Implements get_string_t -.

Definition at line 146 of file expando_status.c.

148{
149 const struct MenuStatusLineData *msld = data;
150 const struct IndexSharedData *shared = msld->shared;
151 const struct Mailbox *m = shared->mailbox;
152
153 // If there's a descriptive name, use it. Otherwise, use %f
154 if (m && m->name)
155 {
156 const char *s = m->name;
157 buf_strcpy(buf, s);
158 return;
159 }
160
161 index_mailbox_path(node, data, flags, buf);
162}
static void index_mailbox_path(const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
Status: pathname of the mailbox - Implements get_string_t -.
Data shared between Index, Pager and Sidebar.
Definition: shared_data.h:37
struct Mailbox * mailbox
Current Mailbox.
Definition: shared_data.h:41
char * name
A short name for the Mailbox.
Definition: mailbox.h:82
Data for creating a Menu line.
struct IndexSharedData * shared
Data shared between Index, Pager and Sidebar.
+ Here is the call graph for this function:

◆ index_limit_pattern()

static void index_limit_pattern ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Status: Active limit pattern - Implements get_string_t -.

Definition at line 192 of file expando_status.c.

194{
195 const struct MenuStatusLineData *msld = data;
196 const struct IndexSharedData *shared = msld->shared;
197 const struct MailboxView *mailbox_view = shared->mailbox_view;
198
199 const char *s = mview_has_limit(mailbox_view) ? mailbox_view->pattern : "";
200 buf_strcpy(buf, s);
201}
bool mview_has_limit(const struct MailboxView *mv)
Is a limit active?
Definition: mview.c:438
struct MailboxView * mailbox_view
Current Mailbox view.
Definition: shared_data.h:40
View of a Mailbox.
Definition: mview.h:40
char * pattern
Limit pattern string.
Definition: mview.h:42
+ Here is the call graph for this function:

◆ index_limit_size()

static void index_limit_size ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Status: Size of the messages - Implements get_string_t -.

Definition at line 206 of file expando_status.c.

208{
209 const struct MenuStatusLineData *msld = data;
210 const struct IndexSharedData *shared = msld->shared;
211 const struct MailboxView *mailbox_view = shared->mailbox_view;
212
213 char tmp[128] = { 0 };
214
215 const off_t num = mailbox_view ? mailbox_view->vsize : 0;
216 mutt_str_pretty_size(tmp, sizeof(tmp), num);
217 buf_strcpy(buf, tmp);
218}
off_t vsize
Size (in bytes) of the messages shown.
Definition: mview.h:41
+ Here is the call graph for this function:

◆ index_mailbox_path()

static void index_mailbox_path ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Status: pathname of the mailbox - Implements get_string_t -.

Definition at line 237 of file expando_status.c.

239{
240 const struct MenuStatusLineData *msld = data;
241 const struct IndexSharedData *shared = msld->shared;
242 const struct Mailbox *m = shared->mailbox;
243
244 char tmp[128] = { 0 };
245
246 if (m && m->compress_info && (m->realpath[0] != '\0'))
247 {
248 mutt_str_copy(tmp, m->realpath, sizeof(tmp));
249 mutt_pretty_mailbox(tmp, sizeof(tmp));
250 }
251 else if (m && (m->type == MUTT_NOTMUCH) && m->name)
252 {
253 mutt_str_copy(tmp, m->name, sizeof(tmp));
254 }
255 else if (m && !buf_is_empty(&m->pathbuf))
256 {
257 mutt_str_copy(tmp, mailbox_path(m), sizeof(tmp));
258 mutt_pretty_mailbox(tmp, sizeof(tmp));
259 }
260 else
261 {
262 mutt_str_copy(tmp, _("(no mailbox)"), sizeof(tmp));
263 }
264
265 buf_strcpy(buf, tmp);
266}
void mutt_pretty_mailbox(char *buf, size_t buflen)
Shorten a mailbox path using '~' or '='.
Definition: muttlib.c:440
struct Buffer pathbuf
Path of the Mailbox.
Definition: mailbox.h:80
void * compress_info
Compressed mbox module private data.
Definition: mailbox.h:121
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ index_mailbox_size()

static void index_mailbox_size ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Status: Size of the current mailbox - Implements get_string_t -.

Definition at line 271 of file expando_status.c.

273{
274 const struct MenuStatusLineData *msld = data;
275 const struct IndexSharedData *shared = msld->shared;
276 const struct Mailbox *m = shared->mailbox;
277
278 char tmp[128] = { 0 };
279
280 const off_t num = m ? m->size : 0;
281 mutt_str_pretty_size(tmp, sizeof(tmp), num);
282 buf_strcpy(buf, tmp);
283}
off_t size
Size of the Mailbox.
Definition: mailbox.h:84
+ Here is the call graph for this function:

◆ index_readonly()

static void index_readonly ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Status: Modified/read-only flag - Implements get_string_t -.

Definition at line 352 of file expando_status.c.

354{
355 const struct MbTable *c_status_chars = cs_subset_mbtable(NeoMutt->sub, "status_chars");
356 if (!c_status_chars || !c_status_chars->len)
357 return;
358
359 const struct MenuStatusLineData *msld = data;
360 const struct IndexSharedData *shared = msld->shared;
361 const struct Mailbox *m = shared->mailbox;
362
363 size_t i = 0;
364
365 if (m)
366 {
367 i = shared->attach_msg ? 3 :
368 ((m->readonly || m->dontwrite) ? 2 :
369 (m->changed ||
370 /* deleted doesn't necessarily mean changed in IMAP */
371 (m->type != MUTT_IMAP && m->msg_deleted)) ?
372 1 :
373 0);
374 }
375
376 if (i >= c_status_chars->len)
377 buf_addstr(buf, c_status_chars->chars[0]);
378 else
379 buf_addstr(buf, c_status_chars->chars[i]);
380}
@ MUTT_IMAP
'IMAP' Mailbox type
Definition: mailbox.h:50
bool attach_msg
Are we in "attach message" mode?
Definition: shared_data.h:46
bool changed
Mailbox has been modified.
Definition: mailbox.h:110
int msg_deleted
Number of deleted messages.
Definition: mailbox.h:93
bool dontwrite
Don't write the mailbox on close.
Definition: mailbox.h:111
bool readonly
Don't allow changes to the mailbox.
Definition: mailbox.h:116
char ** chars
The array of multibyte character strings.
Definition: mbtable.h:39
+ Here is the call graph for this function:

◆ menu_percentage()

static void menu_percentage ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Status: Percentage through index - Implements get_string_t -.

Definition at line 434 of file expando_status.c.

436{
437 const struct MenuStatusLineData *msld = data;
438 const struct Menu *menu = msld->menu;
439 if (!menu)
440 return;
441
442 char tmp[128] = { 0 };
443
444 char *cp = NULL;
445 if (menu->top + menu->page_len >= menu->max)
446 {
447 cp = menu->top ?
448 /* L10N: Status bar message: the end of the list emails is visible in the index */
449 _("end") :
450 /* L10N: Status bar message: all the emails are visible in the index */
451 _("all");
452 }
453 else
454 {
455 int count = (100 * (menu->top + menu->page_len)) / menu->max;
456 /* L10N: Status bar, percentage of way through index.
457 `%d` is the number, `%%` is the percent symbol.
458 They may be reordered, or space inserted, if you wish. */
459 snprintf(tmp, sizeof(tmp), _("%d%%"), count);
460 cp = tmp;
461 }
462
463 buf_strcpy(buf, cp);
464}
struct Menu * menu
Current Menu.
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
+ Here is the call graph for this function:

◆ pgp_command_file_message()

static void pgp_command_file_message ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

PGP Command: Filename of message - Implements get_string_t -.

Definition at line 39 of file expando_command.c.

41{
42 const struct PgpCommandContext *cctx = data;
43
44 const char *s = cctx->fname;
45 buf_strcpy(buf, s);
46}
Data for a PGP command.
Definition: pgp.h:43
const char * fname
f
Definition: pgp.h:45
+ Here is the call graph for this function:

◆ pgp_command_file_signature()

static void pgp_command_file_signature ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

PGP Command: Filename of signature - Implements get_string_t -.

Definition at line 51 of file expando_command.c.

53{
54 const struct PgpCommandContext *cctx = data;
55
56 const char *s = cctx->sig_fname;
57 buf_strcpy(buf, s);
58}
const char * sig_fname
s
Definition: pgp.h:46
+ Here is the call graph for this function:

◆ pgp_command_key_ids()

static void pgp_command_key_ids ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

PGP Command: key IDs - Implements get_string_t -.

Definition at line 63 of file expando_command.c.

65{
66 const struct PgpCommandContext *cctx = data;
67
68 const char *s = cctx->ids;
69 buf_strcpy(buf, s);
70}
const char * ids
r
Definition: pgp.h:48
+ Here is the call graph for this function:

◆ pgp_command_need_pass()

static void pgp_command_need_pass ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

PGP Command: PGPPASSFD=0 if passphrase is needed - Implements get_string_t -.

Definition at line 75 of file expando_command.c.

77{
78 const struct PgpCommandContext *cctx = data;
79
80 const char *s = cctx->need_passphrase ? "PGPPASSFD=0" : "";
81 buf_strcpy(buf, s);
82}
bool need_passphrase
p
Definition: pgp.h:44
+ Here is the call graph for this function:

◆ pgp_command_sign_as()

static void pgp_command_sign_as ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

PGP Command: $pgp_sign_as or $pgp_default_key - Implements get_string_t -.

Definition at line 87 of file expando_command.c.

89{
90 const struct PgpCommandContext *cctx = data;
91
92 const char *s = cctx->signas;
93 buf_strcpy(buf, s);
94}
const char * signas
a
Definition: pgp.h:47
+ Here is the call graph for this function:

◆ gpgme_entry_trust()

static void gpgme_entry_trust ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

GPGME: Trust/validity - Implements get_string_t -.

Definition at line 105 of file expando_gpgme.c.

107{
108 const struct CryptEntry *entry = data;
109 const struct CryptKeyInfo *key = entry->key;
110
111 const char *s = "";
112 if ((key->flags & KEYFLAG_ISX509))
113 {
114 s = "x";
115 }
116 else
117 {
118 switch (key->validity)
119 {
120 case GPGME_VALIDITY_FULL:
121 s = "f";
122 break;
123 case GPGME_VALIDITY_MARGINAL:
124 s = "m";
125 break;
126 case GPGME_VALIDITY_NEVER:
127 s = "n";
128 break;
129 case GPGME_VALIDITY_ULTIMATE:
130 s = "u";
131 break;
132 case GPGME_VALIDITY_UNDEFINED:
133 s = "q";
134 break;
135 case GPGME_VALIDITY_UNKNOWN:
136 default:
137 s = "?";
138 break;
139 }
140 }
141
142 buf_strcpy(buf, s);
143}
#define KEYFLAG_ISX509
Key is an X.509 key.
Definition: lib.h:135
An entry in the Select-Key menu.
Definition: crypt_gpgme.h:86
struct CryptKeyInfo * key
Key.
Definition: crypt_gpgme.h:88
A stored PGP key.
Definition: crypt_gpgme.h:44
gpgme_validity_t validity
uid validity (cached for convenience)
Definition: crypt_gpgme.h:50
KeyFlags flags
global and per uid flags (for convenience)
Definition: crypt_gpgme.h:49
+ Here is the call graph for this function:

◆ gpgme_entry_user_id()

static void gpgme_entry_user_id ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

GPGME: User id - Implements get_string_t -.

Definition at line 148 of file expando_gpgme.c.

150{
151 const struct CryptEntry *entry = data;
152 const struct CryptKeyInfo *key = entry->key;
153
154 const char *s = key->uid;
155 buf_strcpy(buf, s);
156}
const char * uid
and for convenience point to this user ID
Definition: crypt_gpgme.h:48
+ Here is the call graph for this function:

◆ gpgme_key_algorithm()

static void gpgme_key_algorithm ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

GPGME: Key Algorithm - Implements get_string_t -.

Definition at line 161 of file expando_gpgme.c.

163{
164 const struct CryptEntry *entry = data;
165 const struct CryptKeyInfo *key = entry->key;
166
167 const char *s = NULL;
168 if (key->kobj->subkeys)
169 s = gpgme_pubkey_algo_name(key->kobj->subkeys->pubkey_algo);
170 else
171 s = "?";
172
173 buf_strcpy(buf, s);
174}
gpgme_key_t kobj
Definition: crypt_gpgme.h:46
+ Here is the call graph for this function:

◆ gpgme_key_capabilities()

static void gpgme_key_capabilities ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

GPGME: Key Capabilities - Implements get_string_t -.

Definition at line 179 of file expando_gpgme.c.

181{
182 const struct CryptEntry *entry = data;
183 const struct CryptKeyInfo *key = entry->key;
184
185 const char *s = crypt_key_abilities(key->flags);
186 buf_strcpy(buf, s);
187}
static char * crypt_key_abilities(KeyFlags flags)
Parse key flags into a string.
Definition: expando_gpgme.c:49
+ Here is the call graph for this function:

◆ gpgme_key_date()

static void gpgme_key_date ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

GPGME: Date of the key - Implements get_string_t -.

Definition at line 192 of file expando_gpgme.c.

194{
195 const struct CryptEntry *entry = data;
196 const struct CryptKeyInfo *key = entry->key;
197
198 const char *text = node->text;
199 bool use_c_locale = false;
200 if (*text == '!')
201 {
202 use_c_locale = true;
203 text++;
204 }
205
206 struct tm tm = { 0 };
207 if (key->kobj->subkeys && (key->kobj->subkeys->timestamp > 0))
208 {
209 tm = mutt_date_localtime(key->kobj->subkeys->timestamp);
210 }
211 else
212 {
213 tm = mutt_date_localtime(0); // Default to 1970-01-01
214 }
215
216 char tmp[128] = { 0 };
217 if (use_c_locale)
218 {
219 strftime_l(tmp, sizeof(tmp), text, &tm, NeoMutt->time_c_locale);
220 }
221 else
222 {
223 strftime(tmp, sizeof(tmp), text, &tm);
224 }
225
226 buf_strcpy(buf, tmp);
227}
+ Here is the call graph for this function:

◆ gpgme_key_fingerprint()

static void gpgme_key_fingerprint ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

GPGME: Key fingerprint - Implements get_string_t -.

Definition at line 242 of file expando_gpgme.c.

244{
245 const struct CryptEntry *entry = data;
246 struct CryptKeyInfo *key = entry->key;
247
248 /* fixme: we need a way to distinguish between main and subkeys.
249 * Store the idx in entry? */
250 const char *s = crypt_fpr_or_lkeyid(key);
251 buf_strcpy(buf, s);
252}
const char * crypt_fpr_or_lkeyid(struct CryptKeyInfo *k)
Find the fingerprint of a key.
Definition: crypt_gpgme.c:214
+ Here is the call graph for this function:

◆ gpgme_key_flags()

static void gpgme_key_flags ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

GPGME: Key Flags - Implements get_string_t -.

Definition at line 257 of file expando_gpgme.c.

259{
260 const struct CryptEntry *entry = data;
261 const struct CryptKeyInfo *key = entry->key;
262
263 const char *s = crypt_flags(key->flags);
264 buf_strcpy(buf, s);
265}
static char * crypt_flags(KeyFlags flags)
Parse the key flags into a single character.
Definition: expando_gpgme.c:79
+ Here is the call graph for this function:

◆ gpgme_key_id()

static void gpgme_key_id ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

GPGME: Key id - Implements get_string_t -.

Definition at line 270 of file expando_gpgme.c.

272{
273 const struct CryptEntry *entry = data;
274 struct CryptKeyInfo *key = entry->key;
275
276 /* fixme: we need a way to distinguish between main and subkeys.
277 * Store the idx in entry? */
278 const char *s = crypt_keyid(key);
279 buf_strcpy(buf, s);
280}
const char * crypt_keyid(struct CryptKeyInfo *k)
Find the ID for the key.
Definition: crypt_gpgme.c:138
+ Here is the call graph for this function:

◆ gpgme_key_protocol()

static void gpgme_key_protocol ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

GPGME: Protocol - Implements get_string_t -.

Definition at line 296 of file expando_gpgme.c.

298{
299 const struct CryptEntry *entry = data;
300 const struct CryptKeyInfo *key = entry->key;
301
302 const char *s = gpgme_get_protocol_name(key->kobj->protocol);
303 buf_strcpy(buf, s);
304}
+ Here is the call graph for this function:

◆ pgp_entry_ignore()

static void pgp_entry_ignore ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

PGP: Field not supported - Implements get_string_t -.

Definition at line 66 of file expando_pgp.c.

68{
69}

◆ pgp_entry_trust()

static void pgp_entry_trust ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

PGP: Trust/validity - Implements get_string_t -.

Definition at line 83 of file expando_pgp.c.

85{
86 const struct PgpEntry *entry = data;
87 const struct PgpUid *uid = entry->uid;
88
89 buf_printf(buf, "%c", TrustFlags[uid->trust & 0x03]);
90}
static const char TrustFlags[]
Characters used to show the trust level for PGP keys.
Definition: expando_pgp.c:42
An entry in a PGP key menu.
Definition: private.h:39
struct PgpUid * uid
PGP Key info.
Definition: private.h:41
PGP User ID.
Definition: pgplib.h:36
short trust
Definition: pgplib.h:38
+ Here is the call graph for this function:

◆ pgp_entry_user_id()

static void pgp_entry_user_id ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

PGP: User id - Implements get_string_t -.

Definition at line 95 of file expando_pgp.c.

97{
98 const struct PgpEntry *entry = data;
99 const struct PgpUid *uid = entry->uid;
100
101 const char *s = uid->addr;
102 buf_strcpy(buf, s);
103}
char * addr
Definition: pgplib.h:37
+ Here is the call graph for this function:

◆ pgp_key_algorithm()

static void pgp_key_algorithm ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

PGP: Key Algorithm - Implements get_string_t -.

Definition at line 138 of file expando_pgp.c.

140{
141 const struct PgpEntry *entry = data;
142 const struct PgpUid *uid = entry->uid;
143 const struct PgpKeyInfo *key = uid->parent;
144
145 const char *s = key->algorithm;
146 buf_strcpy(buf, s);
147}
Information about a PGP key.
Definition: pgplib.h:49
const char * algorithm
Definition: pgplib.h:57
struct PgpKeyInfo * parent
Parent key.
Definition: pgplib.h:40
+ Here is the call graph for this function:

◆ pgp_key_capabilities()

static void pgp_key_capabilities ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

PGP: Key Capabilities - Implements get_string_t -.

Definition at line 152 of file expando_pgp.c.

154{
155 const struct PgpEntry *entry = data;
156 const struct PgpUid *uid = entry->uid;
157 const struct PgpKeyInfo *key = uid->parent;
158
159 const KeyFlags kflags = key->flags | uid->flags;
160
161 const char *s = pgp_key_abilities(kflags);
162 buf_strcpy(buf, s);
163}
static char * pgp_key_abilities(KeyFlags flags)
Turn PGP key abilities into a string.
Definition: expando_pgp.c:112
uint16_t KeyFlags
Flags describing PGP/SMIME keys, e.g. KEYFLAG_CANSIGN.
Definition: lib.h:131
KeyFlags flags
Definition: pgplib.h:53
int flags
Definition: pgplib.h:39
+ Here is the call graph for this function:

◆ pgp_key_date()

static void pgp_key_date ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

PGP: Date of the key - Implements get_string_t -.

Definition at line 168 of file expando_pgp.c.

170{
171 const struct PgpEntry *entry = data;
172 const struct PgpUid *uid = entry->uid;
173 const struct PgpKeyInfo *key = uid->parent;
174
175 bool use_c_locale = false;
176 const char *text = node->text;
177 if (*text == '!')
178 {
179 use_c_locale = true;
180 text++;
181 }
182
183 char tmp[128] = { 0 };
184 if (use_c_locale)
185 {
186 mutt_date_localtime_format_locale(tmp, sizeof(tmp), text, key->gen_time,
188 }
189 else
190 {
191 mutt_date_localtime_format(tmp, sizeof(tmp), text, key->gen_time);
192 }
193
194 buf_strcpy(buf, tmp);
195}
time_t gen_time
Definition: pgplib.h:55
+ Here is the call graph for this function:

◆ pgp_key_flags()

static void pgp_key_flags ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

PGP: Key Flags - Implements get_string_t -.

Definition at line 212 of file expando_pgp.c.

214{
215 const struct PgpEntry *entry = data;
216 const struct PgpUid *uid = entry->uid;
217 const struct PgpKeyInfo *key = uid->parent;
218
219 const KeyFlags kflags = key->flags | uid->flags;
220
221 buf_printf(buf, "%c", pgp_flags(kflags));
222}
static char pgp_flags(KeyFlags flags)
Turn PGP key flags into a string.
Definition: expando_pgp.c:49
+ Here is the call graph for this function:

◆ pgp_key_id()

static void pgp_key_id ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

PGP: Key id - Implements get_string_t -.

Definition at line 227 of file expando_pgp.c.

229{
230 const struct PgpEntry *entry = data;
231 const struct PgpUid *uid = entry->uid;
232 struct PgpKeyInfo *key = uid->parent;
233
234 const char *s = pgp_this_keyid(key);
235 buf_strcpy(buf, s);
236}
char * pgp_this_keyid(struct PgpKeyInfo *k)
Get the ID of this key.
Definition: pgp.c:191
+ Here is the call graph for this function:

◆ pgp_pkey_algorithm()

static void pgp_pkey_algorithm ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

PGP: Principal Key Algorithm - Implements get_string_t -.

Definition at line 253 of file expando_pgp.c.

255{
256 const struct PgpEntry *entry = data;
257 const struct PgpUid *uid = entry->uid;
258 struct PgpKeyInfo *key = uid->parent;
259 struct PgpKeyInfo *pkey = pgp_principal_key(key);
260
261 const char *s = pkey->algorithm;
262 buf_strcpy(buf, s);
263}
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:

◆ pgp_pkey_capabilities()

static void pgp_pkey_capabilities ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

PGP: Principal Key Capabilities - Implements get_string_t -.

Definition at line 268 of file expando_pgp.c.

270{
271 const struct PgpEntry *entry = data;
272 const struct PgpUid *uid = entry->uid;
273 struct PgpKeyInfo *key = uid->parent;
274 struct PgpKeyInfo *pkey = pgp_principal_key(key);
275
276 const KeyFlags kflags = (pkey->flags & KEYFLAG_RESTRICTIONS) | uid->flags;
277
278 const char *s = pgp_key_abilities(kflags);
279 buf_strcpy(buf, s);
280}
#define KEYFLAG_RESTRICTIONS
Definition: lib.h:146
+ Here is the call graph for this function:

◆ pgp_pkey_flags()

static void pgp_pkey_flags ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

PGP: Principal Key Flags - Implements get_string_t -.

Definition at line 285 of file expando_pgp.c.

287{
288 const struct PgpEntry *entry = data;
289 const struct PgpUid *uid = entry->uid;
290 struct PgpKeyInfo *key = uid->parent;
291 struct PgpKeyInfo *pkey = pgp_principal_key(key);
292
293 const KeyFlags kflags = (pkey->flags & KEYFLAG_RESTRICTIONS) | uid->flags;
294
295 buf_printf(buf, "%c", pgp_flags(kflags));
296}
+ Here is the call graph for this function:

◆ pgp_pkey_id()

static void pgp_pkey_id ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

PGP: Principal Key id - Implements get_string_t -.

Definition at line 301 of file expando_pgp.c.

303{
304 const struct PgpEntry *entry = data;
305 const struct PgpUid *uid = entry->uid;
306 struct PgpKeyInfo *key = uid->parent;
307 struct PgpKeyInfo *pkey = pgp_principal_key(key);
308
309 const char *s = pgp_this_keyid(pkey);
310 buf_strcpy(buf, s);
311}
+ Here is the call graph for this function:

◆ smime_command_algorithm()

static void smime_command_algorithm ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Smime Command: algorithm - Implements get_string_t -.

Definition at line 43 of file expando_smime.c.

45{
46 const struct SmimeCommandContext *cctx = data;
47
48 const char *s = cctx->cryptalg;
49 buf_strcpy(buf, s);
50}
Data for a SIME command.
Definition: smime.h:58
const char * cryptalg
a
Definition: smime.h:60
+ Here is the call graph for this function:

◆ smime_command_certificate_ids()

static void smime_command_certificate_ids ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Smime Command: certificate IDs - Implements get_string_t -.

Definition at line 55 of file expando_smime.c.

57{
58 const struct SmimeCommandContext *cctx = data;
59
60 const char *s = cctx->certificates;
61 buf_strcpy(buf, s);
62}
const char * certificates
c
Definition: smime.h:64
+ Here is the call graph for this function:

◆ smime_command_certificate_path()

static void smime_command_certificate_path ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Smime Command: CA location - Implements get_string_t -.

Definition at line 67 of file expando_smime.c.

69{
70 const char *const c_smime_ca_location = cs_subset_path(NeoMutt->sub, "smime_ca_location");
71
72 struct Buffer *path = buf_pool_get();
73 struct Buffer *buf1 = buf_pool_get();
74 struct Buffer *buf2 = buf_pool_get();
75 struct stat st = { 0 };
76
77 buf_strcpy(path, c_smime_ca_location);
78 buf_expand_path(path);
79 buf_quote_filename(buf1, buf_string(path), true);
80
81 if ((stat(buf_string(path), &st) != 0) || !S_ISDIR(st.st_mode))
82 {
83 buf_printf(buf2, "-CAfile %s", buf_string(buf1));
84 }
85 else
86 {
87 buf_printf(buf2, "-CApath %s", buf_string(buf1));
88 }
89
90 buf_copy(buf, buf2);
91
92 buf_pool_release(&path);
93 buf_pool_release(&buf1);
94 buf_pool_release(&buf2);
95}
const char * cs_subset_path(const struct ConfigSubset *sub, const char *name)
Get a path config item by name.
Definition: helpers.c:168
void buf_expand_path(struct Buffer *buf)
Create the canonical path.
Definition: muttlib.c:315
+ Here is the call graph for this function:

◆ smime_command_digest_algorithm()

static void smime_command_digest_algorithm ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Smime Command: Message digest algorithm - Implements get_string_t -.

Definition at line 100 of file expando_smime.c.

102{
103 const struct SmimeCommandContext *cctx = data;
104
105 const char *s = cctx->digestalg;
106 buf_strcpy(buf, s);
107}
const char * digestalg
d
Definition: smime.h:61
+ Here is the call graph for this function:

◆ smime_command_intermediate_ids()

static void smime_command_intermediate_ids ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Smime Command: Intermediate certificates - Implements get_string_t -.

Definition at line 112 of file expando_smime.c.

114{
115 const struct SmimeCommandContext *cctx = data;
116
117 const char *s = cctx->intermediates;
118 buf_strcpy(buf, s);
119}
const char * intermediates
i
Definition: smime.h:65
+ Here is the call graph for this function:

◆ smime_command_key()

static void smime_command_key ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Smime Command: Key-pair - Implements get_string_t -.

Definition at line 124 of file expando_smime.c.

126{
127 const struct SmimeCommandContext *cctx = data;
128
129 const char *s = cctx->key;
130 buf_strcpy(buf, s);
131}
const char * key
k
Definition: smime.h:59
+ Here is the call graph for this function:

◆ smime_command_message_file()

static void smime_command_message_file ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Smime Command: Filename of message - Implements get_string_t -.

Definition at line 136 of file expando_smime.c.

138{
139 const struct SmimeCommandContext *cctx = data;
140
141 const char *s = cctx->fname;
142 buf_strcpy(buf, s);
143}
const char * fname
f
Definition: smime.h:62
+ Here is the call graph for this function:

◆ smime_command_signature_file()

static void smime_command_signature_file ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Smime Command: Filename of signature - Implements get_string_t -.

Definition at line 148 of file expando_smime.c.

150{
151 const struct SmimeCommandContext *cctx = data;
152
153 const char *s = cctx->sig_fname;
154 buf_strcpy(buf, s);
155}
const char * sig_fname
s
Definition: smime.h:63
+ Here is the call graph for this function:

◆ group_index_description()

static void group_index_description ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

NNTP: Description - Implements get_string_t -.

Definition at line 45 of file expando_browser.c.

47{
48 const struct Folder *folder = data;
49
50 char tmp[128] = { 0 };
51
52 if (!folder->ff->nd->desc)
53 return;
54
55 char *desc = mutt_str_dup(folder->ff->nd->desc);
56 const char *const c_newsgroups_charset = cs_subset_string(NeoMutt->sub, "newsgroups_charset");
57 if (c_newsgroups_charset)
58 {
59 mutt_ch_convert_string(&desc, c_newsgroups_charset, cc_charset(), MUTT_ICONV_HOOK_FROM);
60 }
62 mutt_str_copy(tmp, desc, sizeof(tmp));
63 FREE(&desc);
64
65 buf_strcpy(buf, tmp);
66}
const char * cc_charset(void)
Get the cached value of $charset.
Definition: config_cache.c:116
int mutt_mb_filter_unprintable(char **s)
Replace unprintable characters.
Definition: mbyte.c:423
#define FREE(x)
Definition: memory.h:55
int mutt_ch_convert_string(char **ps, const char *from, const char *to, uint8_t flags)
Convert a string between encodings.
Definition: charset.c:831
#define MUTT_ICONV_HOOK_FROM
apply charset-hooks to fromcode
Definition: charset.h:65
char * mutt_str_dup(const char *str)
Copy a string, safely.
Definition: string.c:253
struct NntpMboxData * nd
Extra NNTP data.
Definition: lib.h:103
char * desc
Description of newsgroup.
Definition: mdata.h:36
+ Here is the call graph for this function:

◆ group_index_flags()

static void group_index_flags ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

NNTP: Moderated flag - Implements get_string_t -.

Definition at line 71 of file expando_browser.c.

73{
74 const struct Folder *folder = data;
75
76 const char *s = NULL;
77 // NOTE(g0mb4): use $flag_chars?
78 if (folder->ff->nd->deleted)
79 {
80 s = "D";
81 }
82 else
83 {
84 s = folder->ff->nd->allowed ? " " : "-";
85 }
86
87 buf_strcpy(buf, s);
88}
bool deleted
Definition: mdata.h:45
bool allowed
Definition: mdata.h:44
+ Here is the call graph for this function:

◆ group_index_flags2()

static void group_index_flags2 ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

NNTP: New flag - Implements get_string_t -.

Definition at line 93 of file expando_browser.c.

95{
96 const struct Folder *folder = data;
97
98 const char *s = NULL;
99 // NOTE(g0mb4): use $flag_chars?
100 if (folder->ff->nd->subscribed)
101 {
102 s = " ";
103 }
104 else
105 {
106 s = folder->ff->has_new_mail ? "N" : "u";
107 }
108
109 buf_strcpy(buf, s);
110}
bool subscribed
Definition: mdata.h:42
+ Here is the call graph for this function:

◆ group_index_newsgroup()

static void group_index_newsgroup ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

NNTP: Newsgroup name - Implements get_string_t -.

Definition at line 115 of file expando_browser.c.

117{
118 const struct Folder *folder = data;
119
120 const char *s = folder->ff->name;
121 buf_strcpy(buf, s);
122}
+ Here is the call graph for this function:

◆ nntp_account()

static void nntp_account ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Newsrc: Account url - Implements get_string_t -.

Definition at line 44 of file expando_newsrc.c.

46{
47 struct NntpAccountData *adata = data;
48 struct ConnAccount *cac = &adata->conn->account;
49
50 char tmp[128] = { 0 };
51
52 struct Url url = { 0 };
53 account_to_url(cac, &url);
54 url_tostring(&url, tmp, sizeof(tmp), U_PATH);
55 char *p = strchr(tmp, '/');
56 if (p)
57 {
58 *p = '\0';
59 }
60
61 buf_strcpy(buf, tmp);
62}
void account_to_url(struct ConnAccount *cac, struct Url *url)
Fill URL with info from account.
Definition: mutt_account.c:80
void * adata
Private data (for Mailbox backends)
Definition: account.h:42
Login details for a remote server.
Definition: connaccount.h:53
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
A parsed URL proto://user:password@host:port/path?a=1&b=2
Definition: url.h:69
int url_tostring(const struct Url *url, char *dest, size_t len, uint8_t flags)
Output the URL string for a given Url object.
Definition: url.c:423
#define U_PATH
Definition: url.h:50
+ Here is the call graph for this function:

◆ nntp_port_if()

static void nntp_port_if ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Newsrc: Port if specified - Implements get_string_t -.

Definition at line 92 of file expando_newsrc.c.

94{
95 const struct NntpAccountData *adata = data;
96 const struct ConnAccount *cac = &adata->conn->account;
97
98 if (cac->flags & MUTT_ACCT_PORT)
99 {
100 buf_add_printf(buf, "%hd", cac->port);
101 }
102}
#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
unsigned short port
Port to connect to.
Definition: connaccount.h:58
+ Here is the call graph for this function:

◆ nntp_schema()

static void nntp_schema ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Newsrc: Url schema - Implements get_string_t -.

Definition at line 107 of file expando_newsrc.c.

109{
110 struct NntpAccountData *adata = data;
111 struct ConnAccount *cac = &adata->conn->account;
112
113 char tmp[128] = { 0 };
114
115 struct Url url = { 0 };
116 account_to_url(cac, &url);
117 url_tostring(&url, tmp, sizeof(tmp), U_PATH);
118 char *p = strchr(tmp, ':');
119 if (p)
120 {
121 *p = '\0';
122 }
123
124 buf_strcpy(buf, tmp);
125}
+ Here is the call graph for this function:

◆ nntp_server()

static void nntp_server ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Newsrc: News server name - Implements get_string_t -.

Definition at line 130 of file expando_newsrc.c.

132{
133 const struct NntpAccountData *adata = data;
134 const struct ConnAccount *cac = &adata->conn->account;
135
136 char tmp[128] = { 0 };
137
138 mutt_str_copy(tmp, cac->host, sizeof(tmp));
139 mutt_str_lower(tmp);
140
141 buf_strcpy(buf, tmp);
142}
char * mutt_str_lower(char *str)
Convert all characters in the string to lowercase.
Definition: string.c:313
char host[128]
Server to login to.
Definition: connaccount.h:54
+ Here is the call graph for this function:

◆ nntp_username()

static void nntp_username ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Newsrc: Username - Implements get_string_t -.

Definition at line 147 of file expando_newsrc.c.

149{
150 const struct NntpAccountData *adata = data;
151 const struct ConnAccount *cac = &adata->conn->account;
152
153 const char *s = cac->user;
154 buf_strcpy(buf, s);
155}
char user[128]
Username.
Definition: connaccount.h:56
+ Here is the call graph for this function:

◆ pattern_description()

static void pattern_description ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Pattern: pattern description - Implements get_string_t -.

Definition at line 39 of file expando.c.

41{
42 const struct PatternEntry *entry = data;
43
44 const char *s = entry->desc;
45 buf_strcpy(buf, s);
46}
A line in the Pattern Completion menu.
Definition: pattern_data.h:35
const char * desc
Description of pattern.
Definition: pattern_data.h:39
+ Here is the call graph for this function:

◆ pattern_expression()

static void pattern_expression ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Pattern: pattern expression - Implements get_string_t -.

Definition at line 51 of file expando.c.

53{
54 const struct PatternEntry *entry = data;
55
56 const char *s = entry->expr;
57 buf_strcpy(buf, s);
58}
const char * expr
Displayed in the menu.
Definition: pattern_data.h:38
+ Here is the call graph for this function:

◆ greeting_real_name()

static void greeting_real_name ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Greeting: Real name - Implements get_string_t -.

Definition at line 41 of file expando.c.

43{
44 const struct Email *e = data;
45 const struct Address *to = TAILQ_FIRST(&e->env->to);
46
47 const char *s = mutt_get_name(to);
48 buf_strcpy(buf, s);
49}
+ Here is the call graph for this function:

◆ greeting_login_name()

static void greeting_login_name ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Greeting: Login name - Implements get_string_t -.

Definition at line 54 of file expando.c.

56{
57 const struct Email *e = data;
58 const struct Address *to = TAILQ_FIRST(&e->env->to);
59
60 char tmp[128] = { 0 };
61 char *p = NULL;
62
63 if (to)
64 {
65 mutt_str_copy(tmp, mutt_addr_for_display(to), sizeof(tmp));
66 if ((p = strpbrk(tmp, "%@")))
67 {
68 *p = '\0';
69 }
70 }
71
72 buf_strcpy(buf, tmp);
73}
+ Here is the call graph for this function:

◆ greeting_first_name()

static void greeting_first_name ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Greeting: First name - Implements get_string_t -.

Definition at line 78 of file expando.c.

80{
81 const struct Email *e = data;
82 const struct Address *to = TAILQ_FIRST(&e->env->to);
83 const struct Address *cc = TAILQ_FIRST(&e->env->cc);
84
85 char tmp[128] = { 0 };
86 char *p = NULL;
87
88 if (to)
89 {
90 const char *s = mutt_get_name(to);
91 mutt_str_copy(tmp, s, sizeof(tmp));
92 }
93 else if (cc)
94 {
95 const char *s = mutt_get_name(cc);
96 mutt_str_copy(tmp, s, sizeof(tmp));
97 }
98
99 if ((p = strpbrk(tmp, " %@")))
100 *p = '\0';
101
102 buf_strcpy(buf, tmp);
103}
+ Here is the call graph for this function:

◆ sidebar_description()

static void sidebar_description ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Sidebar: Descriptive name - Implements get_string_t -.

Definition at line 77 of file expando.c.

79{
80 const struct SidebarData *sdata = data;
81 const struct SbEntry *sbe = sdata->entry;
82
83 char tmp[256] = { 0 };
84
85 const size_t ilen = sizeof(tmp);
86 const size_t off = add_indent(tmp, ilen, sbe);
87
88 if (sbe->mailbox->name)
89 {
90 snprintf(tmp + off, ilen - off, "%s", sbe->mailbox->name);
91 }
92 else
93 {
94 snprintf(tmp + off, ilen - off, "%s", sbe->box);
95 }
96
97 buf_strcpy(buf, tmp);
98}
static size_t add_indent(char *buf, size_t buflen, const struct SbEntry *sbe)
Generate the needed indentation.
Definition: expando.c:46
Info about folders in the sidebar.
Definition: private.h:41
struct Mailbox * mailbox
Mailbox this represents.
Definition: private.h:45
char box[256]
Mailbox path (possibly abbreviated)
Definition: private.h:42
Data passed to sidebar_format_str()
Definition: expando.h:34
struct SbEntry * entry
Info about a folder.
Definition: expando.h:35
+ Here is the call graph for this function:

◆ sidebar_flagged()

static void sidebar_flagged ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Sidebar: Flagged flags - Implements get_string_t -.

Definition at line 103 of file expando.c.

105{
106 const struct SidebarData *sdata = data;
107 const struct SbEntry *sbe = sdata->entry;
108 const struct Mailbox *m = sbe->mailbox;
109
110 if (m->msg_flagged == 0)
111 {
112 buf_strcpy(buf, "");
113 }
114 else if (m->msg_flagged == 1)
115 {
116 buf_strcpy(buf, "!");
117 }
118 else if (m->msg_flagged == 2)
119 {
120 buf_strcpy(buf, "!!");
121 }
122 else
123 {
124 buf_printf(buf, "%d!", m->msg_flagged);
125 }
126}
int msg_flagged
Number of flagged messages.
Definition: mailbox.h:90
+ Here is the call graph for this function:

◆ sidebar_name()

static void sidebar_name ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Sidebar: Name of the mailbox - Implements get_string_t -.

Definition at line 174 of file expando.c.

176{
177 const struct SidebarData *sdata = data;
178 const struct SbEntry *sbe = sdata->entry;
179
180 char tmp[256] = { 0 };
181
182 const size_t ilen = sizeof(tmp);
183 const size_t off = add_indent(tmp, ilen, sbe);
184 snprintf(tmp + off, ilen - off, "%s", sbe->box);
185
186 buf_strcpy(buf, tmp);
187}
+ Here is the call graph for this function:

◆ sidebar_new_mail()

static void sidebar_new_mail ( const struct ExpandoNode node,
void *  data,
MuttFormatFlags  flags,
struct Buffer buf 
)
static

Sidebar: New mail flag - Implements get_string_t -.

Definition at line 192 of file expando.c.

194{
195 const struct SidebarData *sdata = data;
196 const struct SbEntry *sbe = sdata->entry;
197 const struct Mailbox *m = sbe->mailbox;
198
199 // NOTE(g0mb4): use $flag_chars?
200 const char *s = m->has_new ? "N" : " ";
201 buf_strcpy(buf, s);
202}
bool has_new
Mailbox has new mail.
Definition: mailbox.h:85
+ Here is the call graph for this function: