Angband
ui-keymap.h
Go to the documentation of this file.
1 
19 #ifndef UI_KEYMAP_H
20 #define UI_KEYMAP_H
21 
22 #include "z-file.h"
23 
27 #define KEYMAP_ACTION_MAX 20
28 
32 enum {
35 
37 };
38 
42 const struct keypress *keymap_find(int keymap, struct keypress kc);
43 
47 void keymap_add(int keymap, struct keypress trigger, struct keypress *actions, bool user);
48 
52 bool keymap_remove(int keymap, struct keypress trigger);
53 
57 void keymap_free(void);
58 
62 void keymap_dump(ang_file *fff);
63 
64 #endif /* UI_KEYMAP_H */
Low-level file (and directory) handling.
Definition: z-file.c:261
bool keymap_remove(int keymap, struct keypress trigger)
Given a keypress, remove any keymap that would trigger on that key.
Definition: ui-keymap.c:120
Definition: ui-keymap.h:34
Struct holding all relevant info for keypresses.
Definition: ui-event.h:162
void keymap_dump(ang_file *fff)
Save keymaps to the specified file.
Definition: ui-keymap.c:166
Definition: ui-keymap.h:36
Definition: ui-keymap.h:33
const struct keypress * keymap_find(int keymap, struct keypress kc)
Given a keymap mode and a keypress, return any attached action.
Definition: ui-keymap.c:60
Keymap implementation.
Definition: ui-keymap.c:41
void keymap_free(void)
Free all keymaps.
Definition: ui-keymap.c:147
void keymap_add(int keymap, struct keypress trigger, struct keypress *actions, bool user)
Given a keymap mode, a trigger, and an action, store it in the keymap list.
Definition: ui-keymap.c:99