Index functions. More...
#include "config.h"#include <limits.h>#include <stdbool.h>#include <stdio.h>#include "mutt/lib.h"#include "config/lib.h"#include "email/lib.h"#include "core/lib.h"#include "alias/lib.h"#include "gui/lib.h"#include "mutt.h"#include "functions.h"#include "lib.h"#include "attach/lib.h"#include "browser/lib.h"#include "editor/lib.h"#include "history/lib.h"#include "hooks/lib.h"#include "imap/lib.h"#include "key/lib.h"#include "menu/lib.h"#include "ncrypt/lib.h"#include "nntp/lib.h"#include "pager/lib.h"#include "pattern/lib.h"#include "pop/lib.h"#include "progress/lib.h"#include "question/lib.h"#include "send/lib.h"#include "sidebar/lib.h"#include "external.h"#include "globals.h"#include "module_data.h"#include "mutt_mailbox.h"#include "muttlib.h"#include "mx.h"#include "nntp/mdata.h"#include "nntp/module_data.h"#include "private_data.h"#include "shared_data.h"#include "autocrypt/lib.h"#include "notmuch/lib.h"#include <libintl.h>
Include dependency graph for functions.c:Go to the source code of this file.
Enumerations | |
| enum | ResolveMethod { RESOLVE_NEXT_EMAIL , RESOLVE_NEXT_UNDELETED , RESOLVE_NEXT_THREAD , RESOLVE_NEXT_SUBTHREAD } |
| How to advance the cursor. More... | |
Functions | |
| static int | op_jump (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Jump to an index number - Implements index_function_t -. | |
| void | index_init_keys (struct NeoMutt *n, struct SubMenu *sm_generic) |
| Initialise the Index Keybindings - Implements ::init_keys_api. | |
| static bool | resolve_email (struct IndexPrivateData *priv, struct IndexSharedData *shared, enum ResolveMethod rm, int count) |
| Pick the next Email to advance the cursor to. | |
| bool | index_next_undeleted (struct MuttWindow *win_index) |
| Select the next undeleted Email (if possible) | |
| static int | ea_add_selection (struct EmailArray *ea, struct MailboxView *mv, struct Email *e, bool use_tagged, int count) |
| Build a working set of Emails for an action. | |
| static struct MuttThread * | thread_target (struct Email *e, bool subthread) |
| Get the thread/subthread target for an email. | |
| static bool | ea_contains_thread_target (struct EmailArray *ea, struct Email *e, bool subthread) |
| Does the array already include this thread target? | |
| static int | ea_add_selection_threads (struct EmailArray *ea, struct MailboxView *mv, struct Email *e, bool use_tagged, bool subthread, int count) |
| Build a working set of threads/subthreads. | |
| static int | op_alias_dialog (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Open the aliases dialog - Implements index_function_t -. | |
| static int | op_attach_edit_type (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Edit attachment content type - Implements index_function_t -. | |
| static int | op_bounce_message (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Remail a message to another user - Implements index_function_t -. | |
| static int | op_check_traditional (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Check for classic PGP - Implements index_function_t -. | |
| static int | op_compose_to_sender (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Compose new message to the current message sender - Implements index_function_t -. | |
| static int | op_create_alias (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Create an alias from a message sender - Implements index_function_t -. | |
| static int | op_delete (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Delete the current entry - Implements index_function_t -. | |
| static void | update_thread_email (struct IndexPrivateData *priv, struct Email *email) |
| Focus a visible email in the current thread. | |
| static int | op_main_change_thread (struct IndexFunctionData *fdata, struct EmailArray *ea, enum CollapseMode mode) |
| Open/close/collapse a working set of threads. | |
| static int | op_delete_thread (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Delete all messages in thread - Implements index_function_t -. | |
| static int | op_display_address (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Display full address of sender - Implements index_function_t -. | |
| static int | op_display_message (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Display a message - Implements index_function_t -. | |
| static int | op_edit_label (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Add, change, or delete a message's label - Implements index_function_t -. | |
| static int | op_edit_raw_message (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Edit the raw message (edit and edit-raw-message are synonyms) - Implements index_function_t -. | |
| static int | op_end_cond (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| End of conditional execution (noop) - Implements index_function_t -. | |
| static int | op_exit (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Exit this menu - Implements index_function_t -. | |
| static int | op_extract_keys (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Extract supported public keys - Implements index_function_t -. | |
| static int | op_flag_message (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Toggle a message's 'important' flag - Implements index_function_t -. | |
| static int | op_forget_passphrase (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Wipe passphrases from memory - Implements index_function_t -. | |
| static int | op_forward_message (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Forward a message with comments - Implements index_function_t -. | |
| static int | op_group_reply (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Reply to all recipients - Implements index_function_t -. | |
| static int | op_list_action (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Show mailing-list actions - Implements index_function_t -. | |
| static int | op_list_reply (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Reply to specified mailing list - Implements index_function_t -. | |
| static int | op_list_subscribe (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Subscribe to a mailing list - Implements index_function_t -. | |
| static int | op_list_unsubscribe (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Unsubscribe from mailing list - Implements index_function_t -. | |
| static int | op_mail (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Compose a new mail message - Implements index_function_t -. | |
| static int | op_mailbox_list (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| List mailboxes with new mail - Implements index_function_t -. | |
| static int | op_mail_key (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Mail a PGP public key - Implements index_function_t -. | |
| static int | op_main_break_thread (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Break the thread in two - Implements index_function_t -. | |
| static int | op_main_change_folder (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Open a different folder - Implements index_function_t -. | |
| static int | op_main_collapse_all (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Collapse/uncollapse all threads - Implements index_function_t -. | |
| static int | op_main_close_all_threads (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Collapse all threads - Implements index_function_t -. | |
| static int | op_main_close_thread (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Collapse current thread - Implements index_function_t -. | |
| static int | op_main_collapse_thread (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Collapse/uncollapse current thread - Implements index_function_t -. | |
| static int | op_main_open_all_threads (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Open all threads - Implements index_function_t -. | |
| static int | op_main_open_thread (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Open current thread - Implements index_function_t -. | |
| static int | op_main_delete_pattern (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Delete messages matching a pattern - Implements index_function_t -. | |
| static int | op_main_limit (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Limit view to a pattern/thread - Implements index_function_t -. | |
| static int | op_main_link_threads (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Link tagged message to the current one - Implements index_function_t -. | |
| static int | op_main_modify_tags (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Modify (notmuch/imap) tags - Implements index_function_t -. | |
| static int | find_next_new_email (struct Mailbox *m, int start, bool forwards, int op) |
| Jump to next new message - Implements index_function_t -. | |
| static int | op_main_next_new (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| static int | op_main_next_thread (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Jump to the next thread - Implements index_function_t -. | |
| static int | op_main_next_undeleted (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Move to the next undeleted message - Implements index_function_t -. | |
| static int | op_main_next_unread_mailbox (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Open next mailbox with unread mail - Implements index_function_t -. | |
| static int | op_main_prev_unread_mailbox (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Open previous mailbox with unread mail - Implements index_function_t -. | |
| static int | op_main_prev_undeleted (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Move to the previous undeleted message - Implements index_function_t -. | |
| static int | op_main_quasi_delete (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Delete from NeoMutt, don't touch on disk - Implements index_function_t -. | |
| static int | op_main_read_thread (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Mark the current thread as read - Implements index_function_t -. | |
| static int | op_main_root_message (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Jump to root message in thread - Implements index_function_t -. | |
| static int | op_main_set_flag (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Set a status flag on a message - Implements index_function_t -. | |
| static int | op_main_show_limit (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Show currently active limit pattern - Implements index_function_t -. | |
| static int | op_main_sync_folder (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Save changes to mailbox - Implements index_function_t -. | |
| static int | op_main_tag_pattern (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Tag messages matching a pattern - Implements index_function_t -. | |
| static int | op_main_undelete_pattern (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Undelete messages matching a pattern - Implements index_function_t -. | |
| static int | op_main_untag_pattern (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Untag messages matching a pattern - Implements index_function_t -. | |
| static int | op_mark_msg (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Create a hotkey macro for the current message - Implements index_function_t -. | |
| static int | op_next_entry (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Move to the next entry - Implements index_function_t -. | |
| static int | op_pipe (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Pipe message/attachment to a shell command - Implements index_function_t -. | |
| static int | op_prev_entry (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Move to the previous entry - Implements index_function_t -. | |
| static int | op_print (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Print the current entry - Implements index_function_t -. | |
| static int | op_query (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Query external program for addresses - Implements index_function_t -. | |
| static int | op_quit (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Save changes to mailbox and quit - Implements index_function_t -. | |
| static int | op_recall_message (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Recall a postponed message - Implements index_function_t -. | |
| static int | op_reply (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Reply to a message - Implements index_function_t -. | |
| static int | op_resend (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Use the current message as a template for a new one - Implements index_function_t -. | |
| static int | op_save (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Make decrypted copy - Implements index_function_t -. | |
| static int | op_search (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Search for a regular expression - Implements index_function_t -. | |
| static int | op_sort (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Sort messages - Implements index_function_t -. | |
| static int | op_tag (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Tag the current entry - Implements index_function_t -. | |
| static int | op_tag_thread (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Tag the current thread - Implements index_function_t -. | |
| static int | op_toggle_new (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Toggle a message's 'new' flag - Implements index_function_t -. | |
| static int | op_toggle_write (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Toggle whether the mailbox will be rewritten - Implements index_function_t -. | |
| static int | op_undelete (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Undelete the current entry - Implements index_function_t -. | |
| static int | op_undelete_thread (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Undelete all messages in thread - Implements index_function_t -. | |
| static int | op_view_attachments (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Show MIME attachments - Implements index_function_t -. | |
| static int | op_autocrypt_acct_menu (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Manage autocrypt accounts - Implements index_function_t -. | |
| static int | op_main_imap_fetch (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Force retrieval of mail from IMAP server - Implements index_function_t -. | |
| static int | op_main_imap_logout_all (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Logout from all IMAP servers - Implements index_function_t -. | |
| static int | op_catchup (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Mark all articles in newsgroup as read - Implements index_function_t -. | |
| static int | op_get_children (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Get all children of the current message - Implements index_function_t -. | |
| static int | op_get_message (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Get parent of the current message - Implements index_function_t -. | |
| static int | op_main_change_group (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Open a different newsgroup - Implements index_function_t -. | |
| static int | op_post (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Followup to newsgroup - Implements index_function_t -. | |
| static int | op_main_entire_thread (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Read entire thread of the current message - Implements index_function_t -. | |
| static int | op_main_vfolder_from_query (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Generate virtual folder from query - Implements index_function_t -. | |
| static int | op_main_windowed_vfolder (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Shifts virtual folder time window - Implements index_function_t -. | |
| static int | op_main_fetch_mail (struct IndexFunctionData *fdata, const struct KeyEvent *event) |
| Retrieve mail from POP server - Implements index_function_t -. | |
| static bool | prereq (struct IndexSharedData *shared, struct Menu *menu, CheckFlags checks) |
| Check the pre-requisites for a function. | |
| int | index_function_dispatcher (struct MuttWindow *win, const struct KeyEvent *event) |
| Perform an Index function - Implements function_dispatcher_t -. | |
| struct MenuDefinition * | index_get_menu_definition (void) |
| Get the Index Menu Definition. | |
Variables | |
| static const struct MenuFuncOp | OpIndex [] |
| Functions for the Index Menu. | |
| static const struct MenuFuncOp | OpList [] |
| Functions for the List Dialog. | |
| static const struct MenuOpSeq | IndexDefaultBindings [] |
| Key bindings for the Index Menu. | |
| static const struct MenuOpSeq | ListDefaultBindings [] |
| Key bindings for the List Dialog. | |
| static const struct IndexFunction | IndexFunctions [] |
| All the NeoMutt functions that the Index supports. | |
Index functions.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.
Definition in file functions.c.
| enum ResolveMethod |
How to advance the cursor.
| Enumerator | |
|---|---|
| RESOLVE_NEXT_EMAIL | Next email, whatever its state. |
| RESOLVE_NEXT_UNDELETED | Next undeleted email. |
| RESOLVE_NEXT_THREAD | Next top-level thread. |
| RESOLVE_NEXT_SUBTHREAD | Next sibling sub-thread. |
Definition at line 347 of file functions.c.
Initialise the Index Keybindings - Implements ::init_keys_api.
Definition at line 358 of file functions.c.
Here is the call graph for this function:
Here is the caller graph for this function:
|
static |
Pick the next Email to advance the cursor to.
| priv | Private Index data |
| shared | Shared Index data |
| rm | How to advance the cursor, e.g. RESOLVE_NEXT_EMAIL |
| count | How many steps to advance (default 1) |
| true | Resolve succeeded |
Definition at line 393 of file functions.c.
Here is the call graph for this function:
Here is the caller graph for this function:| bool index_next_undeleted | ( | struct MuttWindow * | win_index | ) |
Select the next undeleted Email (if possible)
| win_index | Index Window |
| true | Selection succeeded |
Definition at line 466 of file functions.c.
Here is the call graph for this function:
Here is the caller graph for this function:
|
static |
Build a working set of Emails for an action.
| ea | Empty EmailArray to populate |
| mv | Current MailboxView |
| e | Current Email |
| use_tagged | Use tagged emails |
| count | Repeat-count (0 or 1 == just the current selection) |
| num | Number of selected emails |
| -1 | Error |
Definition at line 502 of file functions.c.
Here is the call graph for this function:
Here is the caller graph for this function:
|
static |
Get the thread/subthread target for an email.
| e | |
| subthread | If true, use the current subthread |
| ptr | Thread/subthread target |
Definition at line 538 of file functions.c.
Here is the caller graph for this function:
|
static |
Does the array already include this thread target?
| ea | Selected emails |
| e | Candidate email |
| subthread | If true, compare subthreads instead of top-level threads |
| true | The target is already represented in the array |
Definition at line 560 of file functions.c.
Here is the call graph for this function:
Here is the caller graph for this function:
|
static |
Build a working set of threads/subthreads.
| ea | Empty EmailArray to populate |
| mv | Current MailboxView |
| e | Current Email |
| use_tagged | Use tagged emails |
| subthread | If true, act on subthreads |
| count | Repeat-count (0 or 1 == just the current thread/subthread) |
| num | Number of selected threads/subthreads |
| -1 | Error |
Definition at line 590 of file functions.c.
Here is the call graph for this function:
Here is the caller graph for this function:
|
static |
Focus a visible email in the current thread.
| priv | Index private data |
| Current email |
Definition at line 784 of file functions.c.
Here is the call graph for this function:
Here is the caller graph for this function:
|
static |
Open/close/collapse a working set of threads.
| fdata | Index function data |
| ea | Working set of thread roots |
| mode | Collapse mode to apply |
| enum | FunctionRetval |
Definition at line 809 of file functions.c.
Here is the call graph for this function:
Here is the caller graph for this function:
|
static |
Definition at line 2064 of file functions.c.
Here is the call graph for this function:
|
static |
Check the pre-requisites for a function.
| shared | Index shared data |
| menu | Current Menu |
| checks | Checks to perform, see CheckFlags |
| true | The checks pass successfully |
Definition at line 3876 of file functions.c.
Here is the call graph for this function:
Here is the caller graph for this function:| struct MenuDefinition * index_get_menu_definition | ( | void | ) |
Get the Index Menu Definition.
| ptr | Index Menu Definition |
Definition at line 4120 of file functions.c.
Here is the call graph for this function:
|
static |
Functions for the Index Menu.
Definition at line 87 of file functions.c.
|
static |
Functions for the List Dialog.
Definition at line 227 of file functions.c.
|
static |
Key bindings for the Index Menu.
Definition at line 241 of file functions.c.
|
static |
Key bindings for the List Dialog.
Definition at line 332 of file functions.c.
|
static |
All the NeoMutt functions that the Index supports.
Definition at line 3925 of file functions.c.