removed unnecessary border color
[dmenu.git] / dmenu.h
1 /*
2  * (C)opyright MMVI Anselm R. Garbe <garbeam at gmail dot com>
3  * See LICENSE file for license details.
4  */
5
6 #include "config.h"
7 #include <X11/Xlib.h>
8 #include <X11/Xlocale.h>
9
10 #define SPACE           30 /* px */
11
12 typedef struct DC DC;
13 typedef struct Fnt Fnt;
14
15 struct Fnt {
16         XFontStruct *xfont;
17         XFontSet set;
18         int ascent;
19         int descent;
20         int height;
21 };
22
23 struct DC { /* draw context */
24         int x, y, w, h;
25         unsigned long bg;
26         unsigned long fg;
27         Drawable drawable;
28         Fnt font;
29         GC gc;
30 };
31
32 extern int screen;
33 extern Display *dpy;
34 extern DC dc;
35
36 /* draw.c */
37 extern void drawtext(const char *text, Bool invert);
38 extern unsigned long getcolor(const char *colstr);
39 extern void setfont(const char *fontstr);
40 extern unsigned int textw(const char *text);
41
42 /* util.c */
43 extern void *emalloc(unsigned int size);
44 extern void eprint(const char *errstr, ...);
45 extern char *estrdup(const char *str);