1 enum ItemOption {IMG, BG, FG, BRD, TAG, CMD, SEC, UNKNOWN};
2 enum {DownWards, UpWards};
3 enum {LeftAlignment, CenterAlignment, RightAlignment};
4 enum {
5 	NetWMName,
6 	NetWMWindowType,
7 	NetWMWindowTypeNotification,
8 	NetWMState,
9 	NetWMStateAbove,
10 	NetLast
11 };
12 
13 /* configuration structure */
14 struct Config {
15 	const char *titlefont;
16 	const char *bodyfont;
17 
18 	const char *background_color;
19 	const char *foreground_color;
20 	const char *border_color;
21 
22 	const char *geometryspec;
23 	const char *gravityspec;
24 
25 	int border_pixels;
26 	int gap_pixels;
27 	int image_pixels;
28 	int leading_pixels;
29 	int padding_pixels;
30 
31 	int alignment;
32 	int shrink;
33 
34 	int sec;
35 
36 	unsigned int actionbutton;
37 };
38 
39 /* monitor geometry structure */
40 struct Monitor {
41 	int num;
42 	int x, y, w, h;
43 };
44 
45 /* draw context structure */
46 struct DC {
47 	XftColor background;
48 	XftColor foreground;
49 	XftColor border;
50 
51 	GC gc;
52 };
53 
54 /* font context structure */
55 struct Fonts {
56 	FcPattern *pattern;
57 	XftFont **fonts;
58 	size_t nfonts;
59 	int texth;          /* text height, also used for padding */
60 };
61 
62 /* notification item specification structure */
63 struct Itemspec {
64 	char *title;
65 	char *body;
66 	char *file;
67 	char *background;
68 	char *foreground;
69 	char *border;
70 	char *tag;
71 	char *cmd;
72 	int sec;
73 };
74 
75 /* notification item structure */
76 struct Item {
77 	struct Item *prev, *next;
78 
79 	char *title;
80 	char *body;
81 	char *tag;
82 	char *cmd;
83 
84 	time_t time;
85 	int sec;
86 
87 	int w, h;
88 	int imgw, imgh;
89 
90 	XftColor background;
91 	XftColor foreground;
92 	XftColor border;
93 
94 	Imlib_Image image;
95 	Drawable pixmap;
96 	Window win;
97 };
98 
99 /* notification queue structure */
100 struct Queue {
101 	/* queue pointers */
102 	struct Item *head, *tail;
103 
104 	/* general geometry for the notification queue */
105 	int gravity;    /* NorthEastGravity, NorthGravity, etc */
106 	int direction;  /* DownWards or UpWards */
107 	int x, y;       /* position of the first notification */
108 	int w, h;       /* width and height of individual notifications */
109 
110 	/* whether the queue changed */
111 	int change;
112 };
113