-
Notifications
You must be signed in to change notification settings - Fork 2
/
types.h
58 lines (47 loc) · 861 Bytes
/
types.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
#ifndef XPAINT_TYPES_H__
#define XPAINT_TYPES_H__
#include <X11/X.h>
#include <limits.h>
#include <stddef.h>
#include <stdint.h>
#define ANY_MOD UINT_MAX
typedef int8_t i8;
typedef uint8_t u8;
typedef int16_t i16;
typedef int32_t i32;
typedef int64_t i64;
typedef uint16_t u16;
typedef uint32_t u32;
typedef uint64_t u64;
typedef size_t usize;
typedef u32 argb;
typedef struct {
i32 x;
i32 y;
} Pair;
typedef struct {
double x;
double y;
} DPt;
typedef struct {
KeySym sym;
u32 mask;
} Key;
typedef struct {
u32 button;
u32 mask;
} Button;
enum Schm {
SchmNorm,
SchmFocus,
SchmLast,
};
typedef struct {
enum {
MF_Int = 0x1, // interact
MF_Color = 0x2, // color
// MF_Term managed manually because can use any key
} mode;
Key key;
} Action;
#endif // XPAINT_TYPES_H__