]> icculus.org git repositories - mikachu/openbox.git/blob - openbox/screen.h
dont skip ungrab corssing events
[mikachu/openbox.git] / openbox / screen.h
1 #ifndef __screen_h
2 #define __screen_h
3
4 #include "geom.h"
5
6 struct Client;
7
8 #define DESKTOP_ALL (0xffffffff)
9
10 /*! The number of available desktops */
11 extern guint screen_num_desktops;
12 /*! The current desktop */
13 extern guint screen_desktop;
14 /*! The size of the screen */
15 extern Size  screen_physical_size;
16 /*! Are we in showing-desktop mode? */
17 extern gboolean screen_showing_desktop;
18
19 /*! Orientation of the desktops */
20 typedef enum {
21     Orientation_Horz,
22     Orientation_Vert
23 } Orientation;
24
25 typedef struct DesktopLayout {
26     guint orientation;
27     guint start_corner;
28     guint rows;
29     guint columns;
30 } DesktopLayout;
31 extern DesktopLayout screen_desktop_layout;
32
33 /*! An array of gchar*'s which are desktop names in UTF-8 format */
34 extern GPtrArray *screen_desktop_names;
35
36 /*! Take over the screen, set the basic hints on it claming it as ours */
37 gboolean screen_annex();
38
39 /*! Once the screen is ours, set up its initial state */
40 void screen_startup();
41 /*! Free resources */
42 void screen_shutdown();
43
44 /*! Figure out the new size of the screen and adjust stuff for it */
45 void screen_resize();
46
47 /*! Change the number of available desktops */
48 void screen_set_num_desktops(guint num);
49 /*! Change the current desktop */
50 void screen_set_desktop(guint num);
51
52 /*! Shows and focuses the desktop and hides all the client windows, or
53   returns to the normal state, showing client windows. */
54 void screen_show_desktop(gboolean show);
55
56 /*! Updates the desktop layout from the root property if available */
57 void screen_update_layout();
58
59 /*! Get desktop names from the root window property */
60 void screen_update_desktop_names();
61
62 /*! Installs or uninstalls a colormap for a client. If client is NULL, then
63   it handles the root colormap. */
64 void screen_install_colormap(struct Client *client, gboolean install);
65
66 void screen_update_struts();
67
68 Rect *screen_area(guint desktop);
69
70 Strut *screen_strut(guint desktop);
71
72 #endif