Top-level window class. More...
#include <display_window.h>
Public Member Functions | |
Construction | |
| DisplayWindow () | |
| Constructs a null instance. More... | |
| DisplayWindow (const std::string &title, int width, int height, bool start_fullscreen=false, bool allow_resize=false, int flipping_buffers=2) | |
| Constructs a window. More... | |
| DisplayWindow (const DisplayWindowDescription &description) | |
| Constructs a window. More... | |
| DisplayWindow (DisplayWindowProvider *provider) | |
| Constructs a window. More... | |
| ~DisplayWindow () | |
Attributes | |
| Rect | get_geometry () const |
| Returns the position and size of the window frame. More... | |
| Rect | get_viewport () const |
| Returns the drawable area of the window (excluding window frame). More... | |
| bool | is_fullscreen () const |
| Returns true if window is currently running fullscreen. More... | |
| bool | has_focus () const |
| Returns true if window has focus. More... | |
| GraphicContext & | get_gc () const |
| Return the graphic context for the window. More... | |
| InputContext | get_ic () const |
| Return the input context for the window. More... | |
| Signal_v0 & | sig_lost_focus () |
| Signal emitted when window lost focus. More... | |
| Signal_v0 & | sig_got_focus () |
| Signal emitted when window gain focus. More... | |
| Signal_v2< int, int > & | sig_resize () |
| Signal emitted when window is resized. More... | |
| Signal_v1< const Rect & > & | sig_paint () |
| Signal emitted when an area of the window is invalidated. More... | |
| Signal_v0 & | sig_window_close () |
| Signal emitted when window is closed. More... | |
| Signal_v0 & | sig_window_destroy () |
| Signal emitted when window is destroyed. More... | |
| Signal_v0 & | sig_window_minimized () |
| Signal emitted when window is minimized. More... | |
| Signal_v0 & | sig_window_maximized () |
| Signal emitted when window is maximized. More... | |
| Signal_v0 & | sig_window_restored () |
| Signal emitted when window is restored. More... | |
| Signal_v0 & | sig_window_moved () |
| Signal emitted after a window has been moved. More... | |
| Signal_v0 & | sig_window_flip () |
| Signal emitted when window flip() was called. More... | |
| Callback_v1< Rect & > & | func_window_resize () |
| Callback called when a window is being resized. More... | |
| Callback_0< bool > & | func_minimize_clicked () |
| Callback called when a window is asked to minimize itself. More... | |
| bool | is_null () const |
| Returns true if this object is invalid. More... | |
| void | throw_if_null () const |
| Throw an exception if this object is invalid. More... | |
| bool | is_visible () const |
| returns true if this display window is visible More... | |
| bool | is_minimized () const |
| Returns true if the window is minimized. More... | |
| bool | is_maximized () const |
| Returns true if the window is maximized. More... | |
| DisplayWindowProvider * | get_provider () const |
| Returns the display window provider. More... | |
| bool | is_clipboard_text_available () const |
| Returns true if text is available in the clipboard. More... | |
| bool | is_clipboard_image_available () const |
| Returns true if an image is available in the clipboard. More... | |
| std::string | get_clipboard_text () const |
| Returns the text stored in the clipboard. More... | |
| PixelBuffer | get_clipboard_image () const |
| Returns an image stored in the clipboard. More... | |
| Size | get_minimum_size (bool client_area=false) |
| Returns the minimum size the window can be resized to by the application user. More... | |
| Size | get_maximum_size (bool client_area=false) |
| Returns the maximum size the window can be resized to by the application user. More... | |
| std::string | get_title () const |
| Returns the window title. More... | |
| ::Display * | get_display () const |
| Returns the X11 display handle. More... | |
| ::Window | get_window () const |
| Handle to X11 window handle. More... | |
Operations | |
| Point | client_to_screen (const Point &client) |
| Convert from window client coordinates to screen coordinates. More... | |
| Point | screen_to_client (const Point &screen) |
| Convert from screen coordinates to client coordinates. More... | |
| void | capture_mouse (bool capture) |
| Capture/Release the mouse. More... | |
| void | request_repaint (const Rect &rect) |
| Invalidates a region of a screen, causing a repaint. More... | |
| void | set_title (const std::string &title) |
| Change window title. More... | |
| void | set_position (const Rect &pos, bool client_area) |
| Set window position and size. More... | |
| void | set_position (int x, int y) |
| Set window position and size. More... | |
| void | set_enabled (bool enable) |
| Set enabled. More... | |
| void | set_visible (bool visible, bool activate) |
| Set visible. More... | |
| void | set_size (int width, int height, bool client_area) |
| Resize window. More... | |
| void | set_minimum_size (int width, int height, bool client_area) |
| Minimum size a window can be resized to by the application user. More... | |
| void | set_maximum_size (int width, int height, bool client_area) |
| Maximum size a window can be resized to by the application user. More... | |
| void | minimize () |
| Minimizes the window. More... | |
| void | restore () |
| Restores the window. More... | |
| void | maximize () |
| Maximizes the window. More... | |
| void | show (bool activate=true) |
| Displays the window in its current size and position. More... | |
| void | hide () |
| Hides the window. More... | |
| void | bring_to_front () |
| Raises the window on top of other windows. More... | |
| void | update (const Rect &rect) |
| Copy the specified rectangle area from back buffer to front buffer. More... | |
| void | flip (int interval=-1) |
| Flip back buffer to front, making changes visible on screen. More... | |
| void | show_cursor () |
| Shows the mouse cursor. More... | |
| void | set_cursor (const Cursor &cursor) |
| Sets the current cursor icon. More... | |
| void | set_cursor (StandardCursor type) |
| Set cursor. More... | |
| void | hide_cursor () |
| Hides the mouse cursor. More... | |
| void | set_clipboard_text (const std::string &text) |
| Stores text in the clipboard. More... | |
| void | set_clipboard_image (const PixelBuffer &buf) |
| Stores an image in the clipboard. More... | |
| void | set_large_icon (const PixelBuffer &image) |
| Sets the large icon used for this window. More... | |
| void | set_small_icon (const PixelBuffer &image) |
| Sets the small icon used for this window. More... | |
| void | enable_alpha_channel (const Rect &blur_rect) |
| Enable alpha channel for this window. More... | |
| void | extend_frame_into_client_area (int height) |
| Exend the window frame into the client area. More... | |
Top-level window class.