102 {
N_(
"Exit"), OP_EXIT },
103 {
N_(
"Del"), OP_DELETE },
104 {
N_(
"Undel"), OP_UNDELETE },
105 {
N_(
"Sort"), OP_SORT },
106 {
N_(
"Rev-Sort"), OP_SORT_REVERSE },
107 {
N_(
"Select"), OP_GENERIC_SELECT_ENTRY },
108 {
N_(
"Help"), OP_HELP },
122 const char *s = alias->
name;
135 const char *s = alias->
comment;
201 const char *s = av->
is_tagged ?
"*" :
" ";
224 const struct AliasViewArray *ava = &mdata->
ava;
245 const struct AliasViewArray *ava = &mdata->
ava;
285 if ((index > (vcount - 1)) && (index > 0))
316 if (ev_w->
win != win_menu)
386 mdata->
sbar = win_sbar;
393 avp->
num = ARRAY_FOREACH_IDX;
444 struct Alias *np = NULL;
445 char bestname[8192] = { 0 };
451 if (
buf_at(buf, 0) !=
'\0')
457 if (bestname[0] ==
'\0')
465 for (i = 0; np->
name[i] && (np->
name[i] == bestname[i]); i++)
473 if (bestname[0] ==
'\0')
488 mdata.limit = mtitle;
569 struct Alias *np = NULL;
634 { -1, -1, NULL, NULL },
void mutt_addrlist_copy(struct AddressList *dst, const struct AddressList *src, bool prune)
Copy a list of addresses into another list.
void mutt_addrlist_clear(struct AddressList *al)
Unlink and free all Address in an AddressList.
size_t mutt_addrlist_write(const struct AddressList *al, struct Buffer *buf, bool display)
Write an Address to a buffer.
void alias_tags_to_buffer(struct TagList *tl, struct Buffer *buf)
Write a comma-separated list of tags to a Buffer.
void alias_array_sort(struct AliasViewArray *ava, const struct ConfigSubset *sub)
Sort and reindex an AliasViewArray.
void alias_free(struct Alias **ptr)
Free an Alias.
struct AliasList Aliases
List of all the user's email aliases.
Representation of a single alias to an email address.
@ NT_ALIAS_ADD
Alias has been added.
@ NT_ALIAS_DELETE
Alias is about to be deleted.
int alias_array_count_visible(struct AliasViewArray *ava)
Count number of visible Aliases.
int alias_array_alias_delete(struct AliasViewArray *ava, const struct Alias *alias)
Delete an Alias from the AliasViewArray.
int alias_array_alias_add(struct AliasViewArray *ava, struct Alias *alias)
Add an Alias to the AliasViewArray.
#define ARRAY_FOREACH(elem, head)
Iterate over all elements of the array.
#define ARRAY_EMPTY(head)
Check if an array is empty.
#define ARRAY_SIZE(head)
The number of elements stored.
#define ARRAY_FREE(head)
Release all memory.
#define ARRAY_GET(head, idx)
Return the element at index.
#define ARRAY_HEAD_INITIALIZER
Static initializer for arrays.
size_t buf_len(const struct Buffer *buf)
Calculate the length of a Buffer.
void buf_reset(struct Buffer *buf)
Reset an existing Buffer.
char buf_at(const struct Buffer *buf, size_t offset)
Return the character at the given offset.
size_t buf_strcpy_n(struct Buffer *buf, const char *s, size_t len)
Copy a string into a Buffer.
size_t buf_addstr(struct Buffer *buf, const char *s)
Add a string to a Buffer.
size_t buf_strcpy(struct Buffer *buf, const char *s)
Copy a string into a Buffer.
size_t buf_copy(struct Buffer *dst, const struct Buffer *src)
Copy a Buffer's contents to another Buffer.
char * buf_strdup(const struct Buffer *buf)
Copy a Buffer's string.
static const char * buf_string(const struct Buffer *buf)
Convert a buffer to a const char * "string".
const char * cs_subset_string(const struct ConfigSubset *sub, const char *name)
Get a string config item by name.
bool cs_subset_bool(const struct ConfigSubset *sub, const char *name)
Get a boolean config item by name.
const struct Expando * cs_subset_expando(const struct ConfigSubset *sub, const char *name)
Get an Expando config item by name.
Convenience wrapper for the config headers.
Convenience wrapper for the core headers.
size_t mutt_strwidth(const char *s)
Measure a string's width in screen cells.
@ FR_DONE
Exit the Dialog.
@ FR_UNKNOWN
Unknown function.
@ FR_CONTINUE
Remain in the Dialog.
int alias_complete(struct Buffer *buf, struct ConfigSubset *sub)
Alias completion routine.
static const struct Mapping AliasHelp[]
Help Bar for the Alias dialog (address book)
void alias_dialog(struct Mailbox *m, struct ConfigSubset *sub)
Open the aliases dialog.
const struct ExpandoRenderData AliasRenderData[]
Callbacks for Alias Expandos.
static struct MuttWindow * alias_dialog_new(struct AliasMenuData *mdata)
Create an Alias Selection Dialog.
bool alias_to_addrlist(struct AddressList *al, struct Alias *alias)
Turn an Alias into an AddressList.
@ ED_ALIAS
Alias ED_ALI_ ExpandoDataAlias.
struct Email * email_new(void)
Create a new Email.
Structs that make up an email.
struct Envelope * mutt_env_new(void)
Create a new Envelope.
int expando_filter(const struct Expando *exp, const struct ExpandoRenderData *rdata, void *data, MuttFormatFlags flags, int max_cols, struct Buffer *buf)
Render an Expando and run the result through a filter.
int km_dokey(enum MenuType mtype, GetChFlags flags)
Determine what a keypress should do.
void km_error_key(enum MenuType mtype)
Handle an unbound key sequence.
int menu_tagging_dispatcher(struct MuttWindow *win, int op)
Perform tagging operations on the Menu - Implements function_dispatcher_t -.
int global_function_dispatcher(struct MuttWindow *win, int op)
Perform a Global function - Implements function_dispatcher_t -.
int menu_function_dispatcher(struct MuttWindow *win, int op)
Perform a Menu function - Implements function_dispatcher_t -.
int alias_function_dispatcher(struct MuttWindow *win, int op)
Perform a Alias function - Implements function_dispatcher_t -.
long alias_t_num(const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
Alias: Tagged char - Implements ExpandoRenderData::get_number() -.
long alias_f_num(const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
Alias: Flags - Implements ExpandoRenderData::get_number() -.
long alias_n_num(const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
Alias: Index number - Implements ExpandoRenderData::get_number() -.
void alias_t(const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
Alias: Tagged char - Implements ExpandoRenderData::get_string() -.
void alias_Y(const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
Alias: Tags - Implements ExpandoRenderData::get_string() -.
void alias_c(const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
Alias: Comment - Implements ExpandoRenderData::get_string() -.
void alias_a(const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
Alias: Alias name - Implements ExpandoRenderData::get_string() -.
void alias_f(const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
Alias: Flags - Implements ExpandoRenderData::get_string() -.
void alias_r(const struct ExpandoNode *node, void *data, MuttFormatFlags flags, struct Buffer *buf)
Alias: Address - Implements ExpandoRenderData::get_string() -.
static bool dlg_alias(struct Buffer *buf, struct AliasMenuData *mdata)
Display a menu of Aliases -.
#define mutt_warning(...)
#define mutt_debug(LEVEL,...)
static int alias_window_observer(struct NotifyCallback *nc)
Notification that a Window has changed - Implements observer_t -.
static int alias_alias_observer(struct NotifyCallback *nc)
Notification that an Alias has changed - Implements observer_t -.
int alias_config_observer(struct NotifyCallback *nc)
Notification that a Config Variable has changed - Implements observer_t -.
int alias_recalc(struct MuttWindow *win)
Recalculate the display of the Alias Window - Implements MuttWindow::recalc() -.
Convenience wrapper for the gui headers.
void simple_dialog_free(struct MuttWindow **ptr)
Destroy a simple index Dialog.
struct MuttWindow * simple_dialog_new(enum MenuType mtype, enum WindowType wtype, const struct Mapping *help_data)
Create a simple index Dialog.
void alias_set_title(struct MuttWindow *sbar, char *menu_name, char *limit)
Create a title string for the Menu.
Shared code for the Alias and Query Dialogs.
@ ED_ALI_FLAGS
Alias.flags.
@ ED_ALI_NUMBER
AliasView.num.
@ ED_ALI_ADDRESS
Alias.addr.
@ ED_ALI_COMMENT
Alias.comment.
@ ED_ALI_TAGGED
AliasView.tagged.
#define GETCH_NO_FLAGS
No flags are set.
@ LL_DEBUG5
Log at debug level 5.
@ LL_DEBUG1
Log at debug level 1.
Convenience wrapper for the library headers.
bool notify_observer_remove(struct Notify *notify, const observer_t callback, const void *global_data)
Remove an observer from an object.
bool notify_observer_add(struct Notify *notify, enum NotifyType type, observer_t callback, void *global_data)
Add an observer to an object.
char * mutt_str_dup(const char *str)
Copy a string, safely.
int mutt_str_asprintf(char **strp, const char *fmt,...)
bool mutt_str_equal(const char *a, const char *b)
Compare two strings.
bool mutt_strn_equal(const char *a, const char *b, size_t num)
Check for equality of two strings (to a maximum), safely.
size_t mutt_str_len(const char *a)
Calculate the length of a string, safely.
size_t mutt_str_copy(char *dest, const char *src, size_t dsize)
Copy a string into a buffer (guaranteeing NUL-termination)
void mutt_clear_error(void)
Clear the message line (bottom line of screen)
void window_redraw(struct MuttWindow *win)
Reflow, recalc and repaint a tree of Windows.
struct MuttWindow * window_set_focus(struct MuttWindow *win)
Set the Window focus.
struct MuttWindow * window_find_child(struct MuttWindow *win, enum WindowType type)
Recursively find a child Window of a given type.
@ WT_DLG_ALIAS
Alias Dialog, dlg_alias()
@ WT_STATUS_BAR
Status Bar containing extra info about the Index/Pager/etc.
@ NT_WINDOW_DELETE
Window is about to be deleted.
@ NT_WINDOW
MuttWindow has changed, NotifyWindow, EventWindow.
@ NT_CONFIG
Config has changed, NotifyConfig, EventConfig.
@ NT_ALIAS
Alias has changed, NotifyAlias, EventAlias.
const char * opcodes_get_name(int op)
Get the name of an opcode.
Match patterns to emails.
int mutt_pattern_alias_func(char *prompt, struct AliasMenuData *mdata, struct Menu *menu)
Perform some Pattern matching for Alias.
struct Buffer * buf_pool_get(void)
Get a Buffer from the pool.
void buf_pool_release(struct Buffer **ptr)
Return a Buffer to the pool.
#define TAILQ_FOREACH(var, head, field)
#define TAILQ_REMOVE(head, elm, field)
#define TAILQ_HEAD_INITIALIZER(head)
#define MUTT_FORMAT_ARROWCURSOR
Reserve space for arrow_cursor.
uint8_t MuttFormatFlags
Flags for expando_render(), e.g. MUTT_FORMAT_FORCESUBJ.
void search_state_free(struct SearchState **ptr)
Free a SearchState.
struct SearchState * search_state_new(void)
Create a new SearchState.
Convenience wrapper for the send headers.
int mutt_send_message(SendFlags flags, struct Email *e_templ, const char *tempfile, struct Mailbox *m, struct EmailArray *ea, struct ConfigSubset *sub)
Send an email.
#define SEND_REVIEW_TO
Allow the user to edit the To field.
GUI data wrapping an Alias.
bool is_visible
Is visible?
struct Alias * alias
Alias.
bool is_deleted
Is it deleted?
bool is_tagged
Is it tagged?
int num
Index number in list.
A shortcut for an email address or addresses.
char * comment
Free-form comment string.
struct AddressList addr
List of Addresses the Alias expands to.
String manipulation buffer.
A set of inherited config items.
struct Notify * notify
Notifications: NotifyConfig, EventConfig.
The envelope/body of an email.
struct Envelope * env
Envelope information.
struct AddressList to
Email's 'To' list.
struct Alias * alias
Alias that changed.
An Event that happened to a Window.
struct MuttWindow * win
Window that changed.
Mapping between user-readable string and a constant.
void * wdata
Private data.
struct Notify * notify
Notifications: NotifyWindow, EventWindow.
int(* recalc)(struct MuttWindow *win)
Container for Accounts, Notifications.
struct Notify * notify
Notifications handler.
struct ConfigSubset * sub
Inherited config items.
Data passed to a notification function.
void * event_data
Data from notify_send()
enum NotifyType event_type
Send: Event type, e.g. NT_ACCOUNT.
int event_subtype
Send: Event subtype, e.g. NT_ACCOUNT_ADD.
void * global_data
Data from notify_observer_add()
@ MENU_ALIAS
Select an email address by its alias.