]> Dogcows Code - chaz/openbox/blob - otk_c/display.h
a color cache to be proud of!
[chaz/openbox] / otk_c / display.h
1 // -*- mode: C; indent-tabs-mode: nil; -*-
2 #ifndef __display_h
3 #define __display_h
4
5 #include <X11/Xlib.h>
6 #include <Python.h>
7
8 struct OtkScreenInfo;
9 struct OtkDisplay;
10
11 extern struct OtkDisplay *OBDisplay; // the global display XXX: move this to app.h and ob.h?
12
13 typedef struct OtkDisplay {
14 PyObject_HEAD
15
16 //! The X display
17 Display *display;
18
19 //! Does the display have the Shape extention?
20 Bool shape;
21 //! Base for events for the Shape extention
22 int shape_event_basep;
23
24 //! Does the display have the Xinerama extention?
25 Bool xinerama;
26 //! Base for events for the Xinerama extention
27 int xinerama_event_basep;
28
29 //! A list of all possible combinations of keyboard lock masks
30 unsigned int mask_list[8];
31
32 //! The number of requested grabs on the display
33 int grab_count;
34
35 //! A list of information for all screens on the display
36 PyObject *screenInfoList; // PyListObject
37 } OtkDisplay;
38
39 //! Opens the X display, and sets the global OBDisplay variable
40 /*!
41 @see OBDisplay::display
42 @param name The name of the X display to open. If it is null, the DISPLAY
43 environment variable is used instead.
44 */
45 void OtkDisplay_Initialize(char *name);
46
47 //! Grabs the display
48 void OtkDisplay_Grab(OtkDisplay *self);
49
50 //! Ungrabs the display
51 void OtkDisplay_Ungrab(OtkDisplay *self);
52
53 //! Get the screen info for a specific screen
54 struct OtkScreenInfo *OtkDisplay_ScreenInfo(OtkDisplay *self, int num);
55
56 #endif // __display_h
This page took 0.03587 seconds and 5 git commands to generate.