2 * Copyright notice from original mutt:
3 * Copyright (C) 1996-2000,2 Michael R. Elkins <me@mutt.org>
5 * This file is part of mutt-ng, see http://www.muttng.org/.
6 * It's licensed under the GNU General Public License,
7 * please see the file GPL in the top level source directory.
15 /* maximal length of a key binding sequence used for buffer in km_bindkey */
18 /* flags for km_dokey() */
19 #define M_KM_UNBUFFERED 1 /* don't read from the key buffer */
21 /* type for key storage, the rest of mutt works fine with int type */
22 typedef short keycode_t;
24 void km_bind (const char *, int, int, char *, char *);
25 void km_bindkey (const char *, int, int);
28 /* entry in the keymap tree */
30 char *macro; /* macro expansion (op == OP_MACRO) */
31 char *descr; /* description of a macro for the help menu */
32 struct keymap_t *next; /* next key in map */
33 short op; /* operation to perform */
34 short eq; /* number of leading keys equal to next entry */
35 short len; /* length of key sequence (unit: sizeof (keycode_t)) */
36 keycode_t *keys; /* key sequence */
39 const char *km_keyname (int);
40 int km_expand_key (char *, size_t, struct keymap_t *);
41 struct keymap_t *km_find_func (int, int);
43 void km_error_key (int);
44 void mutt_what_key (void);
62 #ifdef CRYPT_BACKEND_GPGME
64 MENU_KEY_SELECT_SMIME,
76 /* the keymap trees (one for each menu) */
77 extern struct keymap_t *Keymaps[];
79 /* dokey() records the last real key pressed */
82 extern struct mapping_t Menus[];
85 const char *name; /* name of the function */
86 int op; /* function id number */
87 const char *seq; /* default key binding */
90 struct binding_t *km_get_table (int menu);
92 extern struct binding_t OpGeneric[];
93 extern struct binding_t OpPost[];
94 extern struct binding_t OpMain[];
95 extern struct binding_t OpAttach[];
96 extern struct binding_t OpPager[];
97 extern struct binding_t OpCompose[];
98 extern struct binding_t OpBrowser[];
99 extern struct binding_t OpEditor[];
100 extern struct binding_t OpQuery[];
101 extern struct binding_t OpAlias[];
103 extern struct binding_t OpPgp[];
105 extern struct binding_t OpSmime[];
108 extern struct binding_t OpMix[];
111 #include "keymap_defs.h"
113 #endif /* KEYMAP_H */