2015-04-30 19:47:32 +00:00
|
|
|
#ifndef __KEYB_H__
|
|
|
|
#define __KEYB_H__
|
|
|
|
|
|
|
|
typedef enum _KeyBindingAction
|
|
|
|
{
|
|
|
|
PASTE_PRIMARY = 0,
|
|
|
|
PASTE_SECONDARY,
|
|
|
|
CLEAR_LINE,
|
|
|
|
MOVE_FRONT,
|
|
|
|
MOVE_END,
|
2015-04-30 20:46:51 +00:00
|
|
|
MOVE_WORD_BACK,
|
|
|
|
MOVE_WORD_FORWARD,
|
2015-04-30 19:47:32 +00:00
|
|
|
REMOVE_WORD_BACK,
|
|
|
|
REMOVE_WORD_FORWARD,
|
|
|
|
REMOVE_CHAR_FORWARD,
|
2015-04-30 20:42:04 +00:00
|
|
|
REMOVE_CHAR_BACK,
|
2015-05-01 06:16:52 +00:00
|
|
|
ACCEPT_ENTRY,
|
|
|
|
ACCEPT_CUSTOM,
|
|
|
|
ACCEPT_ENTRY_CONTINUE,
|
2015-04-30 19:47:32 +00:00
|
|
|
NUM_ABE
|
|
|
|
} KeyBindingAction;
|
|
|
|
|
|
|
|
|
|
|
|
typedef struct _KeyBinding
|
|
|
|
{
|
|
|
|
unsigned int modmask;
|
|
|
|
KeySym keysym;
|
|
|
|
} KeyBinding;
|
|
|
|
|
|
|
|
typedef struct _ActionBindingEntry
|
|
|
|
{
|
|
|
|
const char *name;
|
2015-04-30 20:42:04 +00:00
|
|
|
char *keystr;
|
2015-04-30 19:47:32 +00:00
|
|
|
int num_bindings;
|
|
|
|
KeyBinding *kb;
|
|
|
|
} ActionBindingEntry;
|
|
|
|
|
|
|
|
|
2015-04-30 20:42:04 +00:00
|
|
|
void parse_keys_abe ( void );
|
2015-04-30 19:47:32 +00:00
|
|
|
void setup_abe ( void );
|
|
|
|
|
2015-04-30 20:42:04 +00:00
|
|
|
void cleanup_abe ( void );
|
|
|
|
|
2015-04-30 19:47:32 +00:00
|
|
|
extern ActionBindingEntry abe[NUM_ABE];
|
|
|
|
int abe_test_action ( KeyBindingAction action, unsigned int mask, KeySym key );
|
|
|
|
#endif // __KEYB_H__
|