1 /* ghosd -- OSD with fake transparency, cairo, and pango.
2  * Copyright (C) 2006 Evan Martin <martine@danga.com>
3  *
4  * With further development by Giacomo Lozito <james@develia.org>
5  * for the ghosd-based Audacious OSD
6  * - added real transparency with X Composite Extension
7  * - added mouse event handling on OSD window
8  * - added/changed some other stuff
9  */
10 
11 #include <X11/Xlib.h>
12 
13 #include "ghosd.h"
14 
15 typedef struct {
16   GhosdRenderFunc func;
17   void *data;
18   void (*data_destroy)(void*);
19 } RenderCallback;
20 
21 typedef struct {
22   GhosdEventButtonCb func;
23   void *data;
24 } EventButtonCallback;
25 
26 typedef struct {
27   Pixmap pixmap;
28   int set;
29 } GhosdBackground;
30 
31 struct _Ghosd {
32   Display *dpy;
33   Window win;
34   Window root_win;
35   Visual *visual;
36   Colormap colormap;
37   int screen_num;
38   unsigned int depth;
39   int transparent;
40   int composite;
41   int x, y, width, height;
42 
43   GhosdBackground background;
44   RenderCallback render;
45   EventButtonCallback eventbutton;
46 };
47 
48 /* vim: set ts=2 sw=2 et cino=(0 : */
49