2023-05-14 00:21:16 +02:00
|
|
|
/* See LICENSE file for copyright and license details. */
|
|
|
|
|
2023-04-05 20:44:09 +02:00
|
|
|
typedef struct {
|
|
|
|
unsigned int mode;
|
2023-05-08 23:00:45 +02:00
|
|
|
unsigned int mod;
|
|
|
|
KeySym keysym;
|
|
|
|
void (*func)(Arg *);
|
|
|
|
Arg arg;
|
2023-04-05 20:44:09 +02:00
|
|
|
} Key;
|
|
|
|
|
2023-05-06 14:29:45 +02:00
|
|
|
// user friendly names for all the modifiers we're using, but there are many more
|
|
|
|
#define Ctrl ControlMask
|
|
|
|
#define Shift ShiftMask
|
|
|
|
#define Alt Mod1Mask
|
|
|
|
#define AltGr Mod3Mask
|
|
|
|
#define Super Mod4Mask
|
|
|
|
#define ShiftGr Mod5Mask
|
|
|
|
|
2023-03-08 17:20:32 +01:00
|
|
|
static void updatenumlockmask(void);
|
2023-06-02 18:37:51 +02:00
|
|
|
static void keypress_x11(XEvent *e);
|
|
|
|
static void grabkeyboard_x11(void);
|
2023-04-20 21:22:45 +02:00
|
|
|
static void getcapsstate(void);
|
|
|
|
|
2023-04-25 09:56:11 +02:00
|
|
|
static Key ckeys[256];
|
2023-05-06 23:07:16 +02:00
|
|
|
static char capstext[16];
|
2023-05-15 09:53:34 +02:00
|
|
|
static Key hkeys[1] = { { -1, Ctrl|Alt|Shift, XK_Delete, quit, {0} } };
|