clanDisplay Window

Classes

class  clan::Cursor
 Mouse cursor class. More...
 
class  clan::DisplayWindow
 Top-level window class. More...
 
class  clan::DisplayWindowDescription
 Display window description class. More...
 
struct  clan::DisplayWindowHandle
 

Enumerations

enum  clan::StandardCursor {
  clan::StandardCursor::arrow, clan::StandardCursor::appstarting, clan::StandardCursor::cross, clan::StandardCursor::hand,
  clan::StandardCursor::ibeam, clan::StandardCursor::no, clan::StandardCursor::size_all, clan::StandardCursor::size_nesw,
  clan::StandardCursor::size_ns, clan::StandardCursor::size_nwse, clan::StandardCursor::size_we, clan::StandardCursor::uparrow,
  clan::StandardCursor::wait
}
 Standard Cursor. More...
 
enum  clan::WindowType { clan::WindowType::normal, clan::WindowType::popup, clan::WindowType::tool, clan::WindowType::custom }
 

Variables

::Displayclan::DisplayWindowHandle::display = 0
 
::Window clan::DisplayWindowHandle::window = 0
 

Construction

 clan::Cursor::Cursor ()
 Constructs a null instance. More...
 
 clan::Cursor::Cursor (const DisplayWindow &window, const CursorDescription &cursor_description)
 Constructs a Cursor. More...
 

Attributes

bool clan::Cursor::is_null () const
 Returns true if this object is invalid. More...
 
void clan::Cursor::throw_if_null () const
 Throw an exception if this object is invalid. More...
 
CursorProviderclan::Cursor::get_provider () const
 Returns the cursor provider. More...
 

Construction

 clan::DisplayWindow::DisplayWindow ()
 Constructs a null instance. More...
 
 clan::DisplayWindow::DisplayWindow (const std::string &title, float width, float height, bool start_fullscreen=false, bool allow_resize=false, int flipping_buffers=2)
 Constructs a window. More...
 
 clan::DisplayWindow::DisplayWindow (const DisplayWindowDescription &description)
 Constructs a window. More...
 
 clan::DisplayWindow::DisplayWindow (DisplayWindowProvider *provider)
 Constructs a window. More...
 
 clan::DisplayWindow::~DisplayWindow ()
 

Attributes

Rectf clan::DisplayWindow::get_geometry () const
 Returns the position and size of the window frame. More...
 
Rectf clan::DisplayWindow::get_viewport () const
 Returns the drawable area of the window (excluding window frame). More...
 
bool clan::DisplayWindow::is_fullscreen () const
 Returns true if window is currently running fullscreen. More...
 
bool clan::DisplayWindow::has_focus () const
 Returns true if window has focus. More...
 
GraphicContextclan::DisplayWindow::get_gc () const
 Return the graphic context for the window. More...
 
InputContext clan::DisplayWindow::get_ic () const
 Return the input context for the window. More...
 
Signal< void()> & clan::DisplayWindow::sig_lost_focus ()
 Signal emitted when window lost focus. More...
 
Signal< void()> & clan::DisplayWindow::sig_got_focus ()
 Signal emitted when window gain focus. More...
 
Signal< void(float, float)> & clan::DisplayWindow::sig_resize ()
 Signal emitted when window is resized. More...
 
Signal< void(const Rectf &)> & clan::DisplayWindow::sig_paint ()
 Signal emitted when an area of the window is invalidated. More...
 
Signal< void()> & clan::DisplayWindow::sig_window_close ()
 Signal emitted when window is closed. More...
 
Signal< void()> & clan::DisplayWindow::sig_window_destroy ()
 Signal emitted when window is destroyed. More...
 
Signal< void()> & clan::DisplayWindow::sig_window_minimized ()
 Signal emitted when window is minimized. More...
 
Signal< void()> & clan::DisplayWindow::sig_window_maximized ()
 Signal emitted when window is maximized. More...
 
Signal< void()> & clan::DisplayWindow::sig_window_restored ()
 Signal emitted when window is restored. More...
 
Signal< void()> & clan::DisplayWindow::sig_window_moved ()
 Signal emitted after a window has been moved. More...
 
Signal< void()> & clan::DisplayWindow::sig_window_flip ()
 Signal emitted when window flip() was called. More...
 
std::function< void(Rectf &)> & clan::DisplayWindow::func_window_resize ()
 Callback called when a window is being resized. More...
 
std::function< bool()> & clan::DisplayWindow::func_minimize_clicked ()
 Callback called when a window is asked to minimize itself. More...
 
bool clan::DisplayWindow::is_null () const
 Returns true if this object is invalid. More...
 
void clan::DisplayWindow::throw_if_null () const
 Throw an exception if this object is invalid. More...
 
bool clan::DisplayWindow::is_visible () const
 returns true if this display window is visible More...
 
bool clan::DisplayWindow::is_minimized () const
 Returns true if the window is minimized. More...
 
bool clan::DisplayWindow::is_maximized () const
 Returns true if the window is maximized. More...
 
DisplayWindowProviderclan::DisplayWindow::get_provider () const
 Returns the display window provider. More...
 
bool clan::DisplayWindow::is_clipboard_text_available () const
 Returns true if text is available in the clipboard. More...
 
bool clan::DisplayWindow::is_clipboard_image_available () const
 Returns true if an image is available in the clipboard. More...
 
std::string clan::DisplayWindow::get_clipboard_text () const
 Returns the text stored in the clipboard. More...
 
PixelBuffer clan::DisplayWindow::get_clipboard_image () const
 Returns an image stored in the clipboard. More...
 
Sizef clan::DisplayWindow::get_minimum_size (bool client_area=false)
 Returns the minimum size the window can be resized to by the application user. More...
 
Sizef clan::DisplayWindow::get_maximum_size (bool client_area=false)
 Returns the maximum size the window can be resized to by the application user. More...
 
std::string clan::DisplayWindow::get_title () const
 Returns the window title. More...
 
DisplayWindowHandle clan::DisplayWindow::get_handle () const
 

Operations

Pointf clan::DisplayWindow::client_to_screen (const Pointf &client)
 Convert from window client coordinates to screen coordinates. More...
 
Pointf clan::DisplayWindow::screen_to_client (const Pointf &screen)
 Convert from screen coordinates to client coordinates. More...
 
void clan::DisplayWindow::capture_mouse (bool capture)
 Capture/Release the mouse. More...
 
void clan::DisplayWindow::request_repaint (const Rectf &rect)
 Invalidates a region of a screen, causing a repaint. More...
 
void clan::DisplayWindow::set_title (const std::string &title)
 Change window title. More...
 
void clan::DisplayWindow::set_position (const Rectf &pos, bool client_area)
 Set window position and size. More...
 
void clan::DisplayWindow::set_position (float x, float y)
 Set window position. More...
 
void clan::DisplayWindow::set_enabled (bool enable)
 Set enabled. More...
 
void clan::DisplayWindow::set_visible (bool visible, bool activate)
 Set visible. More...
 
void clan::DisplayWindow::set_size (float width, float height, bool client_area)
 Resize window. More...
 
void clan::DisplayWindow::set_minimum_size (float width, float height, bool client_area)
 Minimum size a window can be resized to by the application user. More...
 
void clan::DisplayWindow::set_maximum_size (float width, float height, bool client_area)
 Maximum size a window can be resized to by the application user. More...
 
void clan::DisplayWindow::minimize ()
 Minimizes the window. More...
 
void clan::DisplayWindow::restore ()
 Restores the window. More...
 
void clan::DisplayWindow::maximize ()
 Maximizes the window. More...
 
void clan::DisplayWindow::show (bool activate=true)
 Displays the window in its current size and position. More...
 
void clan::DisplayWindow::hide ()
 Hides the window. More...
 
void clan::DisplayWindow::bring_to_front ()
 Raises the window on top of other windows. More...
 
void clan::DisplayWindow::update (const Rectf &rect)
 Copy the specified rectangle area from back buffer to front buffer. More...
 
void clan::DisplayWindow::flip (int interval=-1)
 Flip back buffer to front, making changes visible on screen. More...
 
void clan::DisplayWindow::show_cursor ()
 Shows the mouse cursor. More...
 
void clan::DisplayWindow::set_cursor (const Cursor &cursor)
 Sets the current cursor icon. More...
 
void clan::DisplayWindow::set_cursor (StandardCursor type)
 Set cursor. More...
 
void clan::DisplayWindow::hide_cursor ()
 Hides the mouse cursor. More...
 
void clan::DisplayWindow::set_clipboard_text (const std::string &text)
 Stores text in the clipboard. More...
 
void clan::DisplayWindow::set_clipboard_image (const PixelBuffer &buf)
 Stores an image in the clipboard. More...
 
void clan::DisplayWindow::set_large_icon (const PixelBuffer &image)
 Sets the large icon used for this window. More...
 
void clan::DisplayWindow::set_small_icon (const PixelBuffer &image)
 Sets the small icon used for this window. More...
 
void clan::DisplayWindow::enable_alpha_channel (const Rectf &blur_rect)
 Enable alpha channel for this window. More...
 
void clan::DisplayWindow::extend_frame_into_client_area (float left, float top, float right, float bottom)
 Exend the window frame into the client area. More...
 

Construction

 clan::DisplayWindowDescription::DisplayWindowDescription ()
 Constructs a window description with default values. More...
 
 clan::DisplayWindowDescription::DisplayWindowDescription (const std::string &title)
 Constructs a window description with default values and a title. More...
 
 clan::DisplayWindowDescription::DisplayWindowDescription (const std::string &title, const Rectf &position, bool client_area)
 Constructs a window description with default values, a title and a position. More...
 
 clan::DisplayWindowDescription::DisplayWindowDescription (const std::string &title, const Sizef &size, bool client_area)
 Constructs a window description with default values, a title and a size. More...
 
 clan::DisplayWindowDescription::DisplayWindowDescription (const Rectf &position, bool client_area)
 Constructs a window description with default values and a position. More...
 
 clan::DisplayWindowDescription::DisplayWindowDescription (const DisplayWindowDescription &copy)
 Constructs a DisplayWindowDescription. More...
 
DisplayWindowDescription clan::DisplayWindowDescription::clone () const
 
virtual clan::DisplayWindowDescription::~DisplayWindowDescription ()
 

Attributes

const std::string & clan::DisplayWindowDescription::get_title () const
 Returns the window title stored in the description. More...
 
Sizef clan::DisplayWindowDescription::get_size () const
 Returns the size of the window stored in description. More...
 
Rectf clan::DisplayWindowDescription::get_position () const
 Returns the initial position of the window. More...
 
bool clan::DisplayWindowDescription::get_position_client_area () const
 Returns if the client area is used for the initial position of the window. More...
 
bool clan::DisplayWindowDescription::is_fullscreen () const
 Returns if window should be initially fullscreen. More...
 
int clan::DisplayWindowDescription::get_flipping_buffers () const
 Returns the amount of flipping buffers to be created. More...
 
int clan::DisplayWindowDescription::get_swap_interval () const
 Returns the swap interval to be used for the window. More...
 
bool clan::DisplayWindowDescription::get_allow_resize () const
 Returns true if window should be resizeable. More...
 
int clan::DisplayWindowDescription::get_bpp () const
 Returns the numbers of bytes per pixel in the window. More...
 
int clan::DisplayWindowDescription::get_refresh_rate () const
 
bool clan::DisplayWindowDescription::is_layered () const
 Returns true if window is layered (black is transparent) More...
 
DisplayWindowHandle clan::DisplayWindowDescription::get_handle () const
 
bool clan::DisplayWindowDescription::has_caption () const
 Returns true if a title bar is shown. More...
 
bool clan::DisplayWindowDescription::has_sysmenu () const
 Returns true if the window has a window menu on its title bar. More...
 
bool clan::DisplayWindowDescription::has_minimize_button () const
 Returns true if the window has a minimize button. More...
 
bool clan::DisplayWindowDescription::has_maximize_button () const
 Returns true if the window has a maximize button. More...
 
bool clan::DisplayWindowDescription::is_visible () const
 Returns true if the window is initially visible. More...
 
bool clan::DisplayWindowDescription::is_topmost () const
 Returns true if the window should be placed above all non-topmost windows. More...
 
bool clan::DisplayWindowDescription::has_no_activate () const
 Indicates if window is automatically activated or not. More...
 
bool clan::DisplayWindowDescription::get_using_gui_window_cache () const
 Returns true if window from the window cache should be used. (GUI Only) More...
 
bool clan::DisplayWindowDescription::has_drop_shadow () const
 Returns true if the window is drawn with a drop shadow effect. More...
 
DisplayWindow clan::DisplayWindowDescription::get_owner () const
 Returns the window owning this one. More...
 
bool clan::DisplayWindowDescription::get_tablet_context () const
 Returns true if a tablet context is to be created for the window. More...
 
int clan::DisplayWindowDescription::get_depth_size () const
 Returns the minimum required depth buffer. More...
 
int clan::DisplayWindowDescription::get_stencil_size () const
 Returns the minimum required stencil buffer. More...
 
int clan::DisplayWindowDescription::get_fullscreen_monitor () const
 Returns the index of the monitor to go fullscreen on. See ScreenInfo. More...
 
bool clan::DisplayWindowDescription::get_allow_screensaver () const
 Returns true if the screensaver is allowed. More...
 
bool clan::DisplayWindowDescription::is_update_supported () const
 Returns true if DisplayWindow::update should be supported. More...
 
int clan::DisplayWindowDescription::get_multisampling () const
 Returns the number of samples per pixel. More...
 
float clan::DisplayWindowDescription::get_extend_frame_left () const
 
float clan::DisplayWindowDescription::get_extend_frame_top () const
 
float clan::DisplayWindowDescription::get_extend_frame_right () const
 
float clan::DisplayWindowDescription::get_extend_frame_bottom () const
 
WindowType clan::DisplayWindowDescription::get_type () const
 

Operations

DisplayWindowDescriptionclan::DisplayWindowDescription::operator= (const DisplayWindowDescription &copy)
 Copy assignment operator. More...
 
void clan::DisplayWindowDescription::show_caption (bool value=true)
 Controls if a title bar (including frame) is shown or not. More...
 
void clan::DisplayWindowDescription::show_sysmenu (bool value=true)
 Sets if the window has a window menu on its title bar. More...
 
void clan::DisplayWindowDescription::show_minimize_button (bool value=true)
 Sets if the window has a minimize button. More...
 
void clan::DisplayWindowDescription::show_maximize_button (bool value=true)
 Sets if the window has a maximize button. More...
 
void clan::DisplayWindowDescription::set_visible (bool value=true)
 Toggles whether the window is created as initially visible. More...
 
void clan::DisplayWindowDescription::set_topmost (bool value=true)
 Sets if the window should be placed above all non-topmost windows. More...
 
void clan::DisplayWindowDescription::set_no_activate (bool value=true)
 Prevents window from being automatically activated. More...
 
void clan::DisplayWindowDescription::set_drop_shadow (bool value=true)
 Enables a drop shadow effect on the window. More...
 
void clan::DisplayWindowDescription::set_owner_window (const DisplayWindow &owner)
 Specifies another window which owns this one. More...
 
void clan::DisplayWindowDescription::set_title (const std::string &title)
 Sets the title of the window. More...
 
void clan::DisplayWindowDescription::set_size (const Sizef &size, bool client_area)
 Sets the size of the window (including window frame). More...
 
void clan::DisplayWindowDescription::set_position (const Rectf &position, bool client_area)
 Sets the position of the window (including window frame). More...
 
void clan::DisplayWindowDescription::set_fullscreen (bool fullscreen=true, int monitor=0)
 Makes the window initially fullscreen. More...
 
void clan::DisplayWindowDescription::set_flipping_buffers (int num_buffers=2)
 Sets the amount of flipping buffers to be used. More...
 
void clan::DisplayWindowDescription::set_swap_interval (int interval=-1)
 Sets the swap interval to be used for the window. More...
 
void clan::DisplayWindowDescription::set_allow_resize (bool allow_resize=true)
 Sets if windows should be resizable. More...
 
void clan::DisplayWindowDescription::set_bpp (int bpp)
 Sets the number of bytes per pixel. More...
 
void clan::DisplayWindowDescription::set_refresh_rate (int refresh_rate)
 
void clan::DisplayWindowDescription::set_tablet_context (bool create)
 Sets to true if a tablet input context should be created for this window. More...
 
void clan::DisplayWindowDescription::set_using_gui_window_cache (bool value)
 
void clan::DisplayWindowDescription::set_layered (bool layered)
 Creates a layered window (complex shaped window) More...
 
void clan::DisplayWindowDescription::set_allow_screensaver (bool allow_screensaver=true)
 Allow the screensaver to appear. More...
 
void clan::DisplayWindowDescription::set_handle (DisplayWindowHandle handle)
 
void clan::DisplayWindowDescription::set_depth_size (int value)
 Sets the minimum required depth buffer. More...
 
void clan::DisplayWindowDescription::set_stencil_size (int value)
 Sets the minimum required stencil buffer. More...
 
void clan::DisplayWindowDescription::set_update_supported (bool value) const
 Controls if DisplayWindow::update is supported. More...
 
void clan::DisplayWindowDescription::set_multisampling (int value)
 Sets the number of samples per pixel. More...
 
void clan::DisplayWindowDescription::set_extend_frame (float left, float top, float right, float bottom)
 
void clan::DisplayWindowDescription::set_type (WindowType type)
 

Detailed Description

Enumeration Type Documentation

◆ StandardCursor

enum clan::StandardCursor
strong

Standard Cursor.

Enumerator
arrow 
appstarting 
cross 
hand 
ibeam 
no 
size_all 
size_nesw 
size_ns 
size_nwse 
size_we 
uparrow 
wait 

◆ WindowType

enum clan::WindowType
strong
Enumerator
normal 
popup 
tool 
custom 

Function Documentation

◆ Cursor() [1/2]

clan::Cursor::Cursor ( )

Constructs a null instance.

◆ Cursor() [2/2]

clan::Cursor::Cursor ( const DisplayWindow window,
const CursorDescription cursor_description 
)

Constructs a Cursor.

Parameters
window= Display Window
cursor_description= Sprite Description
hotspot= Point

◆ DisplayWindow() [1/4]

clan::DisplayWindow::DisplayWindow ( )

Constructs a null instance.

◆ DisplayWindow() [2/4]

clan::DisplayWindow::DisplayWindow ( const DisplayWindowDescription description)

Constructs a window.

Parameters
description= Structure that describes how to create the display window.
target= Display target used to create the window.

◆ DisplayWindow() [3/4]

clan::DisplayWindow::DisplayWindow ( const std::string &  title,
float  width,
float  height,
bool  start_fullscreen = false,
bool  allow_resize = false,
int  flipping_buffers = 2 
)

Constructs a window.

Parameters
title= Titlebar text.
width= Width in pixels of window.
height= Height in pixels of window.
start_fullscreen= If true, window will go fullscreen.
allow_resize= If true, window will have resize grabbers and can be resized.
flipping_buffers= Number of flipping buffers in system. Default is that there is a front buffer and a back buffer.
target= Display target used to create the window.

◆ DisplayWindow() [4/4]

clan::DisplayWindow::DisplayWindow ( DisplayWindowProvider provider)

Constructs a window.

Parameters
provider= Display target implementation object.

◆ DisplayWindowDescription() [1/6]

clan::DisplayWindowDescription::DisplayWindowDescription ( )

Constructs a window description with default values.

◆ DisplayWindowDescription() [2/6]

clan::DisplayWindowDescription::DisplayWindowDescription ( const DisplayWindowDescription copy)

Constructs a DisplayWindowDescription.

Parameters
copy= Display Window Description

◆ DisplayWindowDescription() [3/6]

clan::DisplayWindowDescription::DisplayWindowDescription ( const Rectf position,
bool  client_area 
)

Constructs a window description with default values and a position.

◆ DisplayWindowDescription() [4/6]

clan::DisplayWindowDescription::DisplayWindowDescription ( const std::string &  title)

Constructs a window description with default values and a title.

◆ DisplayWindowDescription() [5/6]

clan::DisplayWindowDescription::DisplayWindowDescription ( const std::string &  title,
const Rectf position,
bool  client_area 
)

Constructs a window description with default values, a title and a position.

◆ DisplayWindowDescription() [6/6]

clan::DisplayWindowDescription::DisplayWindowDescription ( const std::string &  title,
const Sizef size,
bool  client_area 
)

Constructs a window description with default values, a title and a size.

◆ ~DisplayWindow()

clan::DisplayWindow::~DisplayWindow ( )

◆ ~DisplayWindowDescription()

virtual clan::DisplayWindowDescription::~DisplayWindowDescription ( )
virtual

◆ bring_to_front()

void clan::DisplayWindow::bring_to_front ( )

Raises the window on top of other windows.

◆ capture_mouse()

void clan::DisplayWindow::capture_mouse ( bool  capture)

Capture/Release the mouse.

◆ client_to_screen()

Pointf clan::DisplayWindow::client_to_screen ( const Pointf client)

Convert from window client coordinates to screen coordinates.

◆ clone()

DisplayWindowDescription clan::DisplayWindowDescription::clone ( ) const

◆ enable_alpha_channel()

void clan::DisplayWindow::enable_alpha_channel ( const Rectf blur_rect)

Enable alpha channel for this window.

This is only supported on Windows Vista and above (Else use Layered windows instead)

Parameters
blur_rect= Blur rectangle. If size = 0, then the entire window is used

◆ extend_frame_into_client_area()

void clan::DisplayWindow::extend_frame_into_client_area ( float  left,
float  top,
float  right,
float  bottom 
)

Exend the window frame into the client area.

Only implemented on win32

◆ flip()

void clan::DisplayWindow::flip ( int  interval = -1)

Flip back buffer to front, making changes visible on screen.

The parameter interval specifies the minimum number of video frames that are displayed before a buffer swap will occur.

If interval is set to a value of 0, buffer swaps are not synchronized to a video frame.

If interval is set to a value of -1 (the default), then it will use the buffer swap used for previous flip. If its the first flip, it will use the system default.

Parameters
interval= See note

◆ func_minimize_clicked()

std::function<bool()>& clan::DisplayWindow::func_minimize_clicked ( )

Callback called when a window is asked to minimize itself.

◆ func_window_resize()

std::function<void(Rectf &)>& clan::DisplayWindow::func_window_resize ( )

Callback called when a window is being resized.

◆ get_allow_resize()

bool clan::DisplayWindowDescription::get_allow_resize ( ) const

Returns true if window should be resizeable.

◆ get_allow_screensaver()

bool clan::DisplayWindowDescription::get_allow_screensaver ( ) const

Returns true if the screensaver is allowed.

◆ get_bpp()

int clan::DisplayWindowDescription::get_bpp ( ) const

Returns the numbers of bytes per pixel in the window.

◆ get_clipboard_image()

PixelBuffer clan::DisplayWindow::get_clipboard_image ( ) const

Returns an image stored in the clipboard.

Returns a null pixelbuffer if no image is available.

◆ get_clipboard_text()

std::string clan::DisplayWindow::get_clipboard_text ( ) const

Returns the text stored in the clipboard.

◆ get_depth_size()

int clan::DisplayWindowDescription::get_depth_size ( ) const

Returns the minimum required depth buffer.

◆ get_extend_frame_bottom()

float clan::DisplayWindowDescription::get_extend_frame_bottom ( ) const

◆ get_extend_frame_left()

float clan::DisplayWindowDescription::get_extend_frame_left ( ) const

◆ get_extend_frame_right()

float clan::DisplayWindowDescription::get_extend_frame_right ( ) const

◆ get_extend_frame_top()

float clan::DisplayWindowDescription::get_extend_frame_top ( ) const

◆ get_flipping_buffers()

int clan::DisplayWindowDescription::get_flipping_buffers ( ) const

Returns the amount of flipping buffers to be created.

◆ get_fullscreen_monitor()

int clan::DisplayWindowDescription::get_fullscreen_monitor ( ) const

Returns the index of the monitor to go fullscreen on. See ScreenInfo.

◆ get_gc()

GraphicContext& clan::DisplayWindow::get_gc ( ) const

Return the graphic context for the window.

◆ get_geometry()

Rectf clan::DisplayWindow::get_geometry ( ) const

Returns the position and size of the window frame.

◆ get_handle() [1/2]

DisplayWindowHandle clan::DisplayWindowDescription::get_handle ( ) const

Returns an platform-specific internal display window handle object.

◆ get_handle() [2/2]

DisplayWindowHandle clan::DisplayWindow::get_handle ( ) const

Returns an platform-specific internal display window handle object.

◆ get_ic()

InputContext clan::DisplayWindow::get_ic ( ) const

Return the input context for the window.

◆ get_maximum_size()

Sizef clan::DisplayWindow::get_maximum_size ( bool  client_area = false)

Returns the maximum size the window can be resized to by the application user.

◆ get_minimum_size()

Sizef clan::DisplayWindow::get_minimum_size ( bool  client_area = false)

Returns the minimum size the window can be resized to by the application user.

◆ get_multisampling()

int clan::DisplayWindowDescription::get_multisampling ( ) const

Returns the number of samples per pixel.

◆ get_owner()

DisplayWindow clan::DisplayWindowDescription::get_owner ( ) const

Returns the window owning this one.

◆ get_position()

Rectf clan::DisplayWindowDescription::get_position ( ) const

Returns the initial position of the window.

◆ get_position_client_area()

bool clan::DisplayWindowDescription::get_position_client_area ( ) const

Returns if the client area is used for the initial position of the window.

◆ get_provider() [1/2]

CursorProvider* clan::Cursor::get_provider ( ) const

Returns the cursor provider.

◆ get_provider() [2/2]

DisplayWindowProvider* clan::DisplayWindow::get_provider ( ) const

Returns the display window provider.

◆ get_refresh_rate()

int clan::DisplayWindowDescription::get_refresh_rate ( ) const

Returns the refresh rate of the DisplayMode in Hertz (cycles per second). This value is also known as the vertical refresh rate.

◆ get_size()

Sizef clan::DisplayWindowDescription::get_size ( ) const

Returns the size of the window stored in description.

◆ get_stencil_size()

int clan::DisplayWindowDescription::get_stencil_size ( ) const

Returns the minimum required stencil buffer.

◆ get_swap_interval()

int clan::DisplayWindowDescription::get_swap_interval ( ) const

Returns the swap interval to be used for the window.

◆ get_tablet_context()

bool clan::DisplayWindowDescription::get_tablet_context ( ) const

Returns true if a tablet context is to be created for the window.

◆ get_title() [1/2]

const std::string& clan::DisplayWindowDescription::get_title ( ) const

Returns the window title stored in the description.

◆ get_title() [2/2]

std::string clan::DisplayWindow::get_title ( ) const

Returns the window title.

◆ get_type()

WindowType clan::DisplayWindowDescription::get_type ( ) const

◆ get_using_gui_window_cache()

bool clan::DisplayWindowDescription::get_using_gui_window_cache ( ) const

Returns true if window from the window cache should be used. (GUI Only)

This setting is ignored unless the GUI and GUIWindowManagerSystem are used.

◆ get_viewport()

Rectf clan::DisplayWindow::get_viewport ( ) const

Returns the drawable area of the window (excluding window frame).

◆ has_caption()

bool clan::DisplayWindowDescription::has_caption ( ) const

Returns true if a title bar is shown.

◆ has_drop_shadow()

bool clan::DisplayWindowDescription::has_drop_shadow ( ) const

Returns true if the window is drawn with a drop shadow effect.

◆ has_focus()

bool clan::DisplayWindow::has_focus ( ) const

Returns true if window has focus.

◆ has_maximize_button()

bool clan::DisplayWindowDescription::has_maximize_button ( ) const

Returns true if the window has a maximize button.

◆ has_minimize_button()

bool clan::DisplayWindowDescription::has_minimize_button ( ) const

Returns true if the window has a minimize button.

◆ has_no_activate()

bool clan::DisplayWindowDescription::has_no_activate ( ) const

Indicates if window is automatically activated or not.

◆ has_sysmenu()

bool clan::DisplayWindowDescription::has_sysmenu ( ) const

Returns true if the window has a window menu on its title bar.

◆ hide()

void clan::DisplayWindow::hide ( )

Hides the window.

◆ hide_cursor()

void clan::DisplayWindow::hide_cursor ( )

Hides the mouse cursor.

◆ is_clipboard_image_available()

bool clan::DisplayWindow::is_clipboard_image_available ( ) const

Returns true if an image is available in the clipboard.

◆ is_clipboard_text_available()

bool clan::DisplayWindow::is_clipboard_text_available ( ) const

Returns true if text is available in the clipboard.

◆ is_fullscreen() [1/2]

bool clan::DisplayWindowDescription::is_fullscreen ( ) const

Returns if window should be initially fullscreen.

◆ is_fullscreen() [2/2]

bool clan::DisplayWindow::is_fullscreen ( ) const

Returns true if window is currently running fullscreen.

◆ is_layered()

bool clan::DisplayWindowDescription::is_layered ( ) const

Returns true if window is layered (black is transparent)

◆ is_maximized()

bool clan::DisplayWindow::is_maximized ( ) const

Returns true if the window is maximized.

◆ is_minimized()

bool clan::DisplayWindow::is_minimized ( ) const

Returns true if the window is minimized.

◆ is_null() [1/2]

bool clan::Cursor::is_null ( ) const
inline

Returns true if this object is invalid.

◆ is_null() [2/2]

bool clan::DisplayWindow::is_null ( ) const
inline

Returns true if this object is invalid.

◆ is_topmost()

bool clan::DisplayWindowDescription::is_topmost ( ) const

Returns true if the window should be placed above all non-topmost windows.

◆ is_update_supported()

bool clan::DisplayWindowDescription::is_update_supported ( ) const

Returns true if DisplayWindow::update should be supported.

◆ is_visible() [1/2]

bool clan::DisplayWindowDescription::is_visible ( ) const

Returns true if the window is initially visible.

◆ is_visible() [2/2]

bool clan::DisplayWindow::is_visible ( ) const

returns true if this display window is visible

◆ maximize()

void clan::DisplayWindow::maximize ( )

Maximizes the window.

◆ minimize()

void clan::DisplayWindow::minimize ( )

Minimizes the window.

◆ operator=()

DisplayWindowDescription& clan::DisplayWindowDescription::operator= ( const DisplayWindowDescription copy)

Copy assignment operator.

◆ request_repaint()

void clan::DisplayWindow::request_repaint ( const Rectf rect)

Invalidates a region of a screen, causing a repaint.

◆ restore()

void clan::DisplayWindow::restore ( )

Restores the window.

◆ screen_to_client()

Pointf clan::DisplayWindow::screen_to_client ( const Pointf screen)

Convert from screen coordinates to client coordinates.

◆ set_allow_resize()

void clan::DisplayWindowDescription::set_allow_resize ( bool  allow_resize = true)

Sets if windows should be resizable.

◆ set_allow_screensaver()

void clan::DisplayWindowDescription::set_allow_screensaver ( bool  allow_screensaver = true)

Allow the screensaver to appear.

Parameters
allow_screensaver= Allow the allow_screensaver (default is true)

◆ set_bpp()

void clan::DisplayWindowDescription::set_bpp ( int  bpp)

Sets the number of bytes per pixel.

◆ set_clipboard_image()

void clan::DisplayWindow::set_clipboard_image ( const PixelBuffer buf)

Stores an image in the clipboard.

◆ set_clipboard_text()

void clan::DisplayWindow::set_clipboard_text ( const std::string &  text)

Stores text in the clipboard.

◆ set_cursor() [1/2]

void clan::DisplayWindow::set_cursor ( const Cursor cursor)

Sets the current cursor icon.

◆ set_cursor() [2/2]

void clan::DisplayWindow::set_cursor ( StandardCursor  type)

Set cursor.

Parameters
type= Standard Cursor

◆ set_depth_size()

void clan::DisplayWindowDescription::set_depth_size ( int  value)

Sets the minimum required depth buffer.

If this value is zero, the smallest available depth buffer is preferred. Otherwise, the largest available depth buffer of at least the minimum size is preferred.

◆ set_drop_shadow()

void clan::DisplayWindowDescription::set_drop_shadow ( bool  value = true)

Enables a drop shadow effect on the window.

◆ set_enabled()

void clan::DisplayWindow::set_enabled ( bool  enable)

Set enabled.

Parameters
enable= bool

◆ set_extend_frame()

void clan::DisplayWindowDescription::set_extend_frame ( float  left,
float  top,
float  right,
float  bottom 
)

◆ set_flipping_buffers()

void clan::DisplayWindowDescription::set_flipping_buffers ( int  num_buffers = 2)

Sets the amount of flipping buffers to be used.

◆ set_fullscreen()

void clan::DisplayWindowDescription::set_fullscreen ( bool  fullscreen = true,
int  monitor = 0 
)

Makes the window initially fullscreen.

◆ set_handle()

void clan::DisplayWindowDescription::set_handle ( DisplayWindowHandle  handle)

Sets the platform-specific internal display window handle object.

◆ set_large_icon()

void clan::DisplayWindow::set_large_icon ( const PixelBuffer image)

Sets the large icon used for this window.

◆ set_layered()

void clan::DisplayWindowDescription::set_layered ( bool  layered)

Creates a layered window (complex shaped window)

◆ set_maximum_size()

void clan::DisplayWindow::set_maximum_size ( float  width,
float  height,
bool  client_area 
)

Maximum size a window can be resized to by the application user.

◆ set_minimum_size()

void clan::DisplayWindow::set_minimum_size ( float  width,
float  height,
bool  client_area 
)

Minimum size a window can be resized to by the application user.

◆ set_multisampling()

void clan::DisplayWindowDescription::set_multisampling ( int  value)

Sets the number of samples per pixel.

◆ set_no_activate()

void clan::DisplayWindowDescription::set_no_activate ( bool  value = true)

Prevents window from being automatically activated.

◆ set_owner_window()

void clan::DisplayWindowDescription::set_owner_window ( const DisplayWindow owner)

Specifies another window which owns this one.

◆ set_position() [1/3]

void clan::DisplayWindow::set_position ( const Rectf pos,
bool  client_area 
)

Set window position and size.

Parameters
pos= Window position and size.
client_area= true - Position relative to window client area

◆ set_position() [2/3]

void clan::DisplayWindowDescription::set_position ( const Rectf position,
bool  client_area 
)

Sets the position of the window (including window frame).

The default position, is centred on the screen. If this is wanted, use set_size() instead

Parameters
position= Window position
client_area= false = include the window frame. true = exclude the window frame

◆ set_position() [3/3]

void clan::DisplayWindow::set_position ( float  x,
float  y 
)

Set window position.

Parameters
xWindow x position on desktop.
yWindow y position on desktop.

◆ set_refresh_rate()

void clan::DisplayWindowDescription::set_refresh_rate ( int  refresh_rate)

Sets the refresh rate of the DisplayMode in Hertz (cycles per second). This value is also known as the vertical refresh rate.

◆ set_size() [1/2]

void clan::DisplayWindowDescription::set_size ( const Sizef size,
bool  client_area 
)

Sets the size of the window (including window frame).

Parameters
size= Window size
client_area= false = include the window frame. true = exclude the window frame

◆ set_size() [2/2]

void clan::DisplayWindow::set_size ( float  width,
float  height,
bool  client_area 
)

Resize window.

Parameters
width= New width of window in pixels.
height= New height of window in pixels.
client_area= true - relative to the window client area

◆ set_small_icon()

void clan::DisplayWindow::set_small_icon ( const PixelBuffer image)

Sets the small icon used for this window.

◆ set_stencil_size()

void clan::DisplayWindowDescription::set_stencil_size ( int  value)

Sets the minimum required stencil buffer.

If this value is zero, the smallest available stencil buffer is preferred. Otherwise, the largest available stencil buffer of at least the minimum size is preferred.

◆ set_swap_interval()

void clan::DisplayWindowDescription::set_swap_interval ( int  interval = -1)

Sets the swap interval to be used for the window.

◆ set_tablet_context()

void clan::DisplayWindowDescription::set_tablet_context ( bool  create)

Sets to true if a tablet input context should be created for this window.

◆ set_title() [1/2]

void clan::DisplayWindowDescription::set_title ( const std::string &  title)

Sets the title of the window.

◆ set_title() [2/2]

void clan::DisplayWindow::set_title ( const std::string &  title)

Change window title.

◆ set_topmost()

void clan::DisplayWindowDescription::set_topmost ( bool  value = true)

Sets if the window should be placed above all non-topmost windows.

◆ set_type()

void clan::DisplayWindowDescription::set_type ( WindowType  type)

◆ set_update_supported()

void clan::DisplayWindowDescription::set_update_supported ( bool  value) const

Controls if DisplayWindow::update is supported.

The Direct3D target needs to know at window creation time if the application intends to update the screen by calling DisplayWindow::update.

◆ set_using_gui_window_cache()

void clan::DisplayWindowDescription::set_using_gui_window_cache ( bool  value)

Set to use a window from the window cache (GUI Only). Creating a window in Windows XP is slow (~100 ms). Using cached windows for menus and dialogs may make things run faster on Windows XP. This setting is ignored unless the GUI and GUIWindowManagerSystem are used.

◆ set_visible() [1/2]

void clan::DisplayWindowDescription::set_visible ( bool  value = true)

Toggles whether the window is created as initially visible.

◆ set_visible() [2/2]

void clan::DisplayWindow::set_visible ( bool  visible,
bool  activate 
)

Set visible.

Parameters
visible= bool
activate= bool

◆ show()

void clan::DisplayWindow::show ( bool  activate = true)

Displays the window in its current size and position.

◆ show_caption()

void clan::DisplayWindowDescription::show_caption ( bool  value = true)

Controls if a title bar (including frame) is shown or not.

◆ show_cursor()

void clan::DisplayWindow::show_cursor ( )

Shows the mouse cursor.

◆ show_maximize_button()

void clan::DisplayWindowDescription::show_maximize_button ( bool  value = true)

Sets if the window has a maximize button.

◆ show_minimize_button()

void clan::DisplayWindowDescription::show_minimize_button ( bool  value = true)

Sets if the window has a minimize button.

◆ show_sysmenu()

void clan::DisplayWindowDescription::show_sysmenu ( bool  value = true)

Sets if the window has a window menu on its title bar.

◆ sig_got_focus()

Signal<void()>& clan::DisplayWindow::sig_got_focus ( )

Signal emitted when window gain focus.

◆ sig_lost_focus()

Signal<void()>& clan::DisplayWindow::sig_lost_focus ( )

Signal emitted when window lost focus.

◆ sig_paint()

Signal<void(const Rectf &)>& clan::DisplayWindow::sig_paint ( )

Signal emitted when an area of the window is invalidated.

◆ sig_resize()

Signal<void(float, float)>& clan::DisplayWindow::sig_resize ( )

Signal emitted when window is resized.

◆ sig_window_close()

Signal<void()>& clan::DisplayWindow::sig_window_close ( )

Signal emitted when window is closed.

◆ sig_window_destroy()

Signal<void()>& clan::DisplayWindow::sig_window_destroy ( )

Signal emitted when window is destroyed.

◆ sig_window_flip()

Signal<void()>& clan::DisplayWindow::sig_window_flip ( )

Signal emitted when window flip() was called.

◆ sig_window_maximized()

Signal<void()>& clan::DisplayWindow::sig_window_maximized ( )

Signal emitted when window is maximized.

◆ sig_window_minimized()

Signal<void()>& clan::DisplayWindow::sig_window_minimized ( )

Signal emitted when window is minimized.

◆ sig_window_moved()

Signal<void()>& clan::DisplayWindow::sig_window_moved ( )

Signal emitted after a window has been moved.

◆ sig_window_restored()

Signal<void()>& clan::DisplayWindow::sig_window_restored ( )

Signal emitted when window is restored.

◆ throw_if_null() [1/2]

void clan::Cursor::throw_if_null ( ) const

Throw an exception if this object is invalid.

◆ throw_if_null() [2/2]

void clan::DisplayWindow::throw_if_null ( ) const

Throw an exception if this object is invalid.

◆ update()

void clan::DisplayWindow::update ( const Rectf rect)

Copy the specified rectangle area from back buffer to front buffer.

Parameters
rectArea that should be copied.

Variable Documentation

◆ display

::Display* clan::DisplayWindowHandle::display = 0

◆ window

::Window clan::DisplayWindowHandle::window = 0