1 #ifndef MSP_GRAPHICS_WINDOW_H_
2 #define MSP_GRAPHICS_WINDOW_H_
5 #include <sigc++/signal.h>
31 /** Provides input events. The event structure contents are platform-
32 specific. Applications will want to use the enclosed Keyboard and Mouse
34 sigc::signal<void, const Event &> signal_input_event;
36 sigc::signal<void> signal_got_focus;
37 sigc::signal<void> signal_lost_focus;
39 sigc::signal<void, int, int> signal_move;
40 sigc::signal<void, unsigned, unsigned> signal_resize;
41 sigc::signal<void, unsigned, unsigned, unsigned, unsigned, const Event &> signal_expose;
42 sigc::signal<void> signal_close;
46 WindowOptions options;
55 Window(Display &, unsigned w, unsigned h, bool fs = false);
56 Window(Display &, const WindowOptions &);
60 void platform_cleanup();
64 void set_title(const std::string &);
65 void reconfigure(const WindowOptions &);
67 void platform_reconfigure(bool);
69 void set_keyboard_autorepeat(bool);
70 bool get_keyboard_autorepeat() const { return kbd_autorepeat; }
71 void show_cursor(bool);
72 void warp_pointer(int, int);
73 void set_touch_input(bool);
75 void platform_set_touch_input();
77 bool get_touch_input() const { return touch_input; }
79 Display &get_display() const { return display; }
80 const WindowOptions &get_options() const { return options; }
81 virtual unsigned get_width() const { return options.width; }
82 virtual unsigned get_height() const { return options.height; }
83 const Private &get_private() const { return *priv; }
92 bool event(const Event &evnt);
95 } // namespace Graphics