15 std::vector<Window*> children;
19 bool managed; // whether the wm manages (+decorates) this win
25 const Rect &get_rect() const;
26 bool contains_point(int ptr_x, int ptr_y);
28 void move(int x, int y);
29 void resize(int x, int y);
31 void set_title(const char *s);
32 const char *get_title() const;
34 /* mark this window as dirty, and notify the window manager
35 * to repaint it, and anything it used to cover.
39 void draw(const Rect &dirty_region);
40 void draw_children(const Rect &dirty_region);
42 unsigned char *get_win_start_on_fb();
43 int get_scanline_width();
45 void set_managed(bool managed);
46 bool get_managed() const;
48 void set_display_callback(DisplayFuncType func);
49 void set_keyboard_callback(KeyboardFuncType func);
50 void set_mouse_button_callback(MouseButtonFuncType func);
51 void set_mouse_motion_callback(MouseMotionFuncType func);
53 const DisplayFuncType get_display_callback() const;
54 const KeyboardFuncType get_keyboard_callback() const;
55 const MouseButtonFuncType get_mouse_button_callback() const;
56 const MouseMotionFuncType get_mouse_motion_callback() const;
59 void add_child(Window *win);
60 void remove_child(Window *win);
62 const Window *get_parent() const;
65 // XXX remove if not needed
66 friend class WindowManager;