My dmenu build
Non puoi selezionare più di 25 argomenti Gli argomenti devono iniziare con una lettera o un numero, possono includere trattini ('-') e possono essere lunghi fino a 35 caratteri.

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