NeoMutt
Teaching an old dog new tricks
DOXYGEN
Loading...
Searching...
No Matches
lib.h
Go to the documentation of this file.
1
43#ifndef MUTT_ALIAS_LIB_H
44#define MUTT_ALIAS_LIB_H
45
46#include <stddef.h>
47#include <stdbool.h>
48#include <stdint.h>
49#include "core/lib.h"
50#include "complete/lib.h"
51
52struct Address;
53struct AddressList;
54struct Buffer;
55struct ConfigSubset;
56struct EnterWindowData;
57struct Envelope;
58
59extern const struct CompleteOps CompleteAliasOps;
60
61void alias_init (void);
62void alias_cleanup(void);
63
64void alias_create (struct AddressList *al, const struct ConfigSubset *sub);
65struct AddressList *alias_lookup (const char *name);
66
67bool mutt_addr_is_user (const struct Address *addr);
68void mutt_expand_aliases_env(struct Envelope *env);
69void mutt_expand_aliases (struct AddressList *al);
70struct AddressList *mutt_get_address (struct Envelope *env, const char **prefix);
71
72enum CommandResult parse_alias (struct Buffer *buf, struct Buffer *s, intptr_t data, struct Buffer *err);
73enum CommandResult parse_unalias(struct Buffer *buf, struct Buffer *s, intptr_t data, struct Buffer *err);
74
75int alias_complete(struct Buffer *buf, struct ConfigSubset *sub);
76void alias_dialog (struct Mailbox *m, struct ConfigSubset *sub);
77
78int query_complete(struct Buffer *buf, struct ConfigSubset *sub);
79void query_index (struct Mailbox *m, struct ConfigSubset *sub);
80
81int complete_alias(struct EnterWindowData *wdata, int op);
82
83struct Address *alias_reverse_lookup(const struct Address *addr);
84
85#endif /* MUTT_ALIAS_LIB_H */
void alias_cleanup(void)
Clean up the Alias globals.
Definition: alias.c:687
int alias_complete(struct Buffer *buf, struct ConfigSubset *sub)
Alias completion routine.
Definition: dlg_alias.c:385
struct AddressList * alias_lookup(const char *name)
Find an Alias.
Definition: alias.c:280
void mutt_expand_aliases(struct AddressList *al)
Expand aliases in a List of Addresses.
Definition: alias.c:298
const struct CompleteOps CompleteAliasOps
Auto-Completion of Aliases.
Definition: complete.c:108
int query_complete(struct Buffer *buf, struct ConfigSubset *sub)
Perform auto-complete using an Address Query.
Definition: dlg_query.c:456
void alias_dialog(struct Mailbox *m, struct ConfigSubset *sub)
Open the aliases dialog.
Definition: dlg_alias.c:509
void alias_create(struct AddressList *al, const struct ConfigSubset *sub)
Create a new Alias from an Address.
Definition: alias.c:370
bool mutt_addr_is_user(const struct Address *addr)
Does the address belong to the user.
Definition: alias.c:570
void alias_init(void)
Set up the Alias globals.
Definition: alias.c:679
void mutt_expand_aliases_env(struct Envelope *env)
Expand aliases in all the fields of an Envelope.
Definition: alias.c:312
struct AddressList * mutt_get_address(struct Envelope *env, const char **prefix)
Get an Address from an Envelope.
Definition: alias.c:330
void query_index(struct Mailbox *m, struct ConfigSubset *sub)
Perform an Alias Query and display the results.
Definition: dlg_query.c:538
struct Address * alias_reverse_lookup(const struct Address *addr)
Does the user have an alias for the given address.
Definition: reverse.c:105
CommandResult
Error codes for command_t parse functions.
Definition: command.h:36
Auto-completion.
Convenience wrapper for the core headers.
enum CommandResult parse_alias(struct Buffer *buf, struct Buffer *s, intptr_t data, struct Buffer *err)
Parse the 'alias' command - Implements Command::parse() -.
Definition: commands.c:47
enum CommandResult parse_unalias(struct Buffer *buf, struct Buffer *s, intptr_t data, struct Buffer *err)
Parse the 'unalias' command - Implements Command::parse() -.
Definition: commands.c:160
int complete_alias(struct EnterWindowData *wdata, int op)
Alias completion wrapper - Implements complete_function_t -.
Definition: complete.c:95
An email address.
Definition: address.h:36
String manipulation buffer.
Definition: buffer.h:34
A set of inherited config items.
Definition: subset.h:47
Data to fill the Enter Window.
Definition: wdata.h:46
The header of an Email.
Definition: envelope.h:57
A mailbox.
Definition: mailbox.h:79