CL_GUIManager Class Reference
[clanGUI System]

GUI manager. More...

#include <gui_manager.h>

List of all members.

Public Member Functions

Construction

 CL_GUIManager ()
 Constructs a gui manager with a system window manager.
 CL_GUIManager (const CL_DisplayWindow &display_window)
 Constructs a gui manager with a texture window manager.
 CL_GUIManager (const CL_String &path_to_theme)
 Fully constructs a gui manager with a system window manager, a css theme and resources.
 CL_GUIManager (const CL_DisplayWindow &display_window, const CL_String &path_to_theme)
 Fully constructs a gui manager with a texture window manager, a css theme and resources.
 CL_GUIManager (CL_GUIWindowManager &window_manager, const CL_String &path_to_theme)
 Fully constructs a gui manager with a custom window manager, a css theme and resources.
 CL_GUIManager (CL_SharedPtr< CL_GUIManager_Impl > impl)
 Constructs a GUIManager.
virtual ~CL_GUIManager ()
Attributes

bool is_gui_manager () const
 Returns true if the parent is the GUI manager.
CL_GUITheme get_theme () const
 Returns the GUI theme being used.
CL_CSSDocument get_css_document () const
 Returns the CSS document being used.
CL_GUIWindowManager get_window_manager () const
 Returns the windows manager being used.
CL_GUIComponentget_capture_component () const
 Returns the mouse capture component.
CL_GUIComponentget_focused_component ()
 Returns the currently focused component.
bool get_exit_flag () const
 Returns if a dialog message pump loop should exit.
int get_exit_code () const
 Returns the dialog exit code.
CL_Font get_registered_font (const CL_FontDescription &desc)
 Get a registered user defined GUI font (set with register_font()). Returns NULL if not found.
CL_String get_clipboard_text () const
 Get Clipboard text.
Events

CL_Signal_v1< CL_GUIMessage & > & sig_filter_message ()
 bool func_filter_message(const CL_GUIMessage &message)
CL_Callback_0< int > & func_exec_handler ()
 int func_exec_handler()
Operations

void add_theme (const CL_String &path_to_theme)
 Adds a GUI theme directory.
void set_theme (CL_GUITheme &theme)
 Sets the GUI theme.
void set_css_document (CL_CSSDocument css)
 Sets the CSS document.
void set_css_document (const CL_String &fullname)
 Sets the CSS document, by creating a CSSDocument from file automatically.
void set_css_document (const CL_String &filename, const CL_VirtualDirectory &directory)
 Set css document.
void add_resources (const CL_ResourceManager &resources)
 Adds additional resources to the GUI resource manager.
void add_resources (const CL_String &filename)
 Adds additional resources to the GUI resource manager, by creating a ResourceManager from file automatically.
void add_resources (const CL_String &filename, const CL_VirtualDirectory &directory)
 Adds additional resources to the GUI resource manager.
void initialize_layout_manager (const CL_String &xml_fullname, const CL_String &css_fullname)
 Load layout.
void set_window_manager (CL_GUIWindowManager &window_manager)
 Sets the windows manager.
int exec ()
 Processes messages until exit_with_code is called.
void process_messages (int timeout)
 Processes all messages available.
void dispatch_message (CL_GUIMessage message)
 Sends a GUI message to the message handler target for the message.
void exit_with_code (int exit_code)
 Breaks the message loop.
void clear_exit_flag ()
 Clears the flag indicating exec() should exit its message pump loop.
void set_capture_component (CL_GUIComponent *component, bool state)
 Set the mouse capture component.
void request_repaint (const CL_Rect &rect, CL_GUIComponent *root_component)
 Mark the specified area to be redrawn.
void register_font (const CL_Font &font, const CL_FontDescription &desc)
 Registers a user defined GUI font - referenced using the specified font description.
void render_windows ()
 Render windows.
void set_clipboard_text (const CL_StringRef &str)
 Set clipboard text.
void set_tablet_proximity_component (CL_GUIComponent *, bool state)
 Redirect proximity events from tablet to the specified component.
void set_accelerator_table (const CL_AcceleratorTable &table)
 Set the accelerator table.
CL_CSSLayout create_layout (CL_GUIComponent *component)
 Creates a css layout for a given component.
bool has_layout (CL_GUIComponent *component)
 Checks if a component type has layout information available.

Implementation



class CL_GUIComponent_Impl
class CL_GUIThemePart
class CL_GUIThemePart_Impl

Detailed Description

GUI manager.


Constructor & Destructor Documentation

CL_GUIManager::CL_GUIManager (  ) 

Constructs a gui manager with a system window manager.

Remember to add a theme using set_theme() or add_theme().

CL_GUIManager::CL_GUIManager ( const CL_DisplayWindow display_window  ) 

Constructs a gui manager with a texture window manager.

Remember to add a theme using set_theme() or add_theme().

Parameters:
display_window = display window to attach gui to.
CL_GUIManager::CL_GUIManager ( const CL_String path_to_theme  ) 

Fully constructs a gui manager with a system window manager, a css theme and resources.

Parameters:
path_to_theme = Path to theme directory. It has to contain resources.xml and theme.css.
CL_GUIManager::CL_GUIManager ( const CL_DisplayWindow display_window,
const CL_String path_to_theme 
)

Fully constructs a gui manager with a texture window manager, a css theme and resources.

Parameters:
display_window = display window to attach gui to.
path_to_theme = Path to theme directory. It has to contain resources.xml and theme.css.
CL_GUIManager::CL_GUIManager ( CL_GUIWindowManager window_manager,
const CL_String path_to_theme 
)

Fully constructs a gui manager with a custom window manager, a css theme and resources.

Parameters:
window_manager = Window manager
path_to_theme = Path to theme directory. It has to contain resources.xml and theme.css.
CL_GUIManager::CL_GUIManager ( CL_SharedPtr< CL_GUIManager_Impl >  impl  ) 

Constructs a GUIManager.

Parameters:
impl = Shared Ptr
virtual CL_GUIManager::~CL_GUIManager (  )  [virtual]

Member Function Documentation

void CL_GUIManager::add_resources ( const CL_ResourceManager resources  ) 

Adds additional resources to the GUI resource manager.

void CL_GUIManager::add_resources ( const CL_String filename  ) 

Adds additional resources to the GUI resource manager, by creating a ResourceManager from file automatically.

void CL_GUIManager::add_resources ( const CL_String filename,
const CL_VirtualDirectory directory 
)

Adds additional resources to the GUI resource manager.

void CL_GUIManager::add_theme ( const CL_String path_to_theme  ) 

Adds a GUI theme directory.

Parameters:
path_to_theme = Path to theme directory. It has to contain resources.xml and theme.css.
void CL_GUIManager::clear_exit_flag (  ) 

Clears the flag indicating exec() should exit its message pump loop.

CL_CSSLayout CL_GUIManager::create_layout ( CL_GUIComponent component  ) 

Creates a css layout for a given component.

void CL_GUIManager::dispatch_message ( CL_GUIMessage  message  ) 

Sends a GUI message to the message handler target for the message.

int CL_GUIManager::exec (  ) 

Processes messages until exit_with_code is called.

void CL_GUIManager::exit_with_code ( int  exit_code  ) 

Breaks the message loop.

CL_Callback_0<int>& CL_GUIManager::func_exec_handler (  ) 
CL_GUIComponent* CL_GUIManager::get_capture_component (  )  const

Returns the mouse capture component.

CL_String CL_GUIManager::get_clipboard_text (  )  const

Get Clipboard text.

Returns:
clipboard_text
CL_CSSDocument CL_GUIManager::get_css_document (  )  const

Returns the CSS document being used.

int CL_GUIManager::get_exit_code (  )  const

Returns the dialog exit code.

bool CL_GUIManager::get_exit_flag (  )  const

Returns if a dialog message pump loop should exit.

CL_GUIComponent* CL_GUIManager::get_focused_component (  ) 

Returns the currently focused component.

CL_Font CL_GUIManager::get_registered_font ( const CL_FontDescription desc  ) 

Get a registered user defined GUI font (set with register_font()). Returns NULL if not found.

CL_GUITheme CL_GUIManager::get_theme (  )  const

Returns the GUI theme being used.

CL_GUIWindowManager CL_GUIManager::get_window_manager (  )  const

Returns the windows manager being used.

bool CL_GUIManager::has_layout ( CL_GUIComponent component  ) 

Checks if a component type has layout information available.

void CL_GUIManager::initialize_layout_manager ( const CL_String xml_fullname,
const CL_String css_fullname 
)

Load layout.

bool CL_GUIManager::is_gui_manager (  )  const [inline]

Returns true if the parent is the GUI manager.

void CL_GUIManager::process_messages ( int  timeout  ) 

Processes all messages available.

Parameters:
timeout = Timeout (ms). -1 = Wait forever
void CL_GUIManager::register_font ( const CL_Font font,
const CL_FontDescription desc 
)

Registers a user defined GUI font - referenced using the specified font description.

void CL_GUIManager::render_windows (  ) 

Render windows.

void CL_GUIManager::request_repaint ( const CL_Rect rect,
CL_GUIComponent root_component 
)

Mark the specified area to be redrawn.

void CL_GUIManager::set_accelerator_table ( const CL_AcceleratorTable table  ) 

Set the accelerator table.

void CL_GUIManager::set_capture_component ( CL_GUIComponent component,
bool  state 
)

Set the mouse capture component.

void CL_GUIManager::set_clipboard_text ( const CL_StringRef str  ) 

Set clipboard text.

void CL_GUIManager::set_css_document ( const CL_String filename,
const CL_VirtualDirectory directory 
)

Set css document.

Parameters:
filename = String
directory = Virtual Directory
void CL_GUIManager::set_css_document ( CL_CSSDocument  css  ) 

Sets the CSS document.

void CL_GUIManager::set_css_document ( const CL_String fullname  ) 

Sets the CSS document, by creating a CSSDocument from file automatically.

void CL_GUIManager::set_tablet_proximity_component ( CL_GUIComponent ,
bool  state 
)

Redirect proximity events from tablet to the specified component.

void CL_GUIManager::set_theme ( CL_GUITheme theme  ) 

Sets the GUI theme.

void CL_GUIManager::set_window_manager ( CL_GUIWindowManager window_manager  ) 

Sets the windows manager.

CL_Signal_v1<CL_GUIMessage &>& CL_GUIManager::sig_filter_message (  ) 

bool func_filter_message(const CL_GUIMessage &message)


Friends And Related Function Documentation

friend class CL_GUIComponent_Impl [friend]
friend class CL_GUIThemePart [friend]
friend class CL_GUIThemePart_Impl [friend]

The documentation for this class was generated from the following file: