X-Git-Url: http://git.mutantstargoat.com?a=blobdiff_plain;ds=inline;f=src%2Fwm.h;h=e2e24875e1372e944ad67e2f8386d76de4a11e7c;hb=e2626c41c841dbbfb64ddf6341b4e23089036299;hp=406ef9dbf7a45cd07f0026ed8086eb5e31a7add8;hpb=287b4d5d1b7eadfe9d5d0aa3b33700f3e1bed55e;p=winnie
diff --git a/src/wm.h b/src/wm.h
index 406ef9d..e2e2487 100644
--- a/src/wm.h
+++ b/src/wm.h
@@ -1,3 +1,24 @@
+/*
+winnie - an experimental window system
+
+Copyright (C) 2013 Eleni Maria Stea
+
+This program is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program. If not, see .
+
+Author: Eleni Maria Stea
+*/
+
#ifndef WM_H_
#define WM_H_
@@ -8,6 +29,9 @@
class Window;
+bool init_window_manager();
+void destroy_window_manager();
+
class WindowManager {
private:
std::list windows;
@@ -25,6 +49,7 @@ private:
Window *grab_win;
Pixmap mouse_cursor;
+ Pixmap *background;
void create_frame(Window *win);
void destroy_frame(Window *win);
@@ -44,11 +69,27 @@ public:
Window *get_focused_window();
Window *get_window_at_pos(int pointer_x, int pointer_y);
+ Window *get_root_window() const;
+
+ void set_focused_frame_color(int r, int g, int b);
+ void get_focused_frame_color(int *r, int *g, int *b) const;
+
+ void set_unfocused_frame_color(int r, int g, int b);
+ void get_unfocused_frame_color(int *r, int *g, int *b) const;
+
+ void set_background(const Pixmap *pixmap);
+ const Pixmap *get_background() const;
Window *get_grab_window() const;
void grab_mouse(Window *win);
void release_mouse();
+
+ void raise_window(Window *win);
+ void sink_window(Window *win);
+
+ void maximize_window(Window *win);
+ void unmaximize_window(Window *win);
};
extern WindowManager *wm;