#include <omgui/win32/window.h>
Inherits omgui::win32::Widget, and omgui::common::Window.
Public Types | |
typedef omgui::initializer::WindowData | data_type |
Initialization data used for Windows. | |
typedef omgui::initializer::WidgetData | data_type |
Initialization data used for Widgets. | |
typedef omgui::Window | wrapper_type |
typedef omgui::Widget | wrapper_type |
Public Member Functions | |
void | add_ex_style (int style) |
Adds an extended style flag or flags to this HWND. | |
omgui::Size | client_size_to_absolute (const omgui::Size &size) |
virtual void | create (const data_type &init_params)=0 |
void | create (const omgui::initializer::WindowData ¶ms) |
virtual void | destroy () |
virtual void | enable (bool e) |
virtual Pointer< omgui::Panel > | get_content_panel () const |
virtual omgui::Size | get_content_size () |
virtual void * | get_handle () const |
HFONT | get_hfont () const |
virtual omgui::Size | get_max_content_size () const |
virtual omgui::Size | get_max_size () const |
Pointer< omgui::MenuBar > | get_menu_bar () const |
virtual omgui::Size | get_min_content_size () const |
virtual omgui::Size | get_min_size () const |
virtual omgui::Size | get_natural_size () const |
virtual Pointer< omgui::Panel > | get_parent () const |
virtual Pointer< omgui::Window > | get_parent_window () const |
virtual omgui::Point | get_position () const |
virtual omgui::Rect | get_rect () const |
virtual omgui::Size | get_size () const |
virtual string | get_title () |
string | get_window_placement () const |
int | get_window_styles () const |
string | get_window_text () const |
template<typename T> | |
T * | get_wrapper () |
template<typename T> | |
const T * | get_wrapper () const |
omgui::Widget * | get_wrapper () |
const omgui::Widget * | get_wrapper () const |
omgui::object_id | get_wrapper_id () const |
void | invalidate_parent () |
virtual bool | is_enabled () const |
virtual bool | is_hidden () const |
virtual bool | is_shown () const |
bool | process_menu_command (menu_id id) |
int | process_message (HWND hwnd, UINT msg, WPARAM w_param, LPARAM l_param) |
bool | process_notification (int notification, HWND hwnd) |
void | remove_ex_style (int style) |
Removes an extended style flag or flags from this HWND. | |
virtual Pointer< omgui::Panel > | set_content_panel (const Pointer< omgui::Panel > &p) |
virtual void | set_content_size (const omgui::Size &s) |
void | set_default_font () |
virtual void | set_max_content_size (const omgui::Size &) |
virtual void | set_max_size (const omgui::Size &s) |
void | set_menu_bar (const Pointer< omgui::MenuBar > &menubar) |
virtual void | set_min_content_size (const omgui::Size &) |
virtual void | set_min_size (const omgui::Size &s) |
virtual void | set_natural_size (const omgui::Size &s) |
virtual void | set_position (const omgui::Point &p) |
virtual void | set_rect (const omgui::Rect &r) |
virtual void | set_size (const omgui::Size &s) |
virtual void | set_title (const string &t) |
void | set_window_placement (const string &placement) |
void | set_window_text (const string &str) |
virtual void | show (bool show, bool focus) |
Window (omgui::Window *wrapper=0) | |
Static Public Member Functions | |
static void | set_default_font (HWND h) |
Protected Member Functions | |
void | create (const omgui::initializer::WidgetData ¶ms, bool parent_required, LPCTSTR class_name, LPCTSTR window_name, int styles, int styles_ex=0, int x=0, int y=0, int w=0, int h=0, HMENU menu=0) |
virtual void | post_create (const omgui::initializer::WidgetData ¶ms) |
void | set_old_proc (WNDPROC proc) |
void | set_window_pos (int x, int y, int w, int h, int flags=0) |
Protected Attributes | |
bool | m_hidden |
HWND | m_hwnd |
omgui::Size | m_max_size |
omgui::Size | m_min_size |
omgui::Size | m_natural_size |
WNDPROC | m_old_proc |
Private Attributes | |
Pointer< omgui::Panel > | m_content_panel |
Pointer< omgui::MenuBar > | m_menubar |
Friends | |
class | CreationHook |
LRESULT CALLBACK | widget_wndproc (HWND hwnd, UINT msg, WPARAM w_param, LPARAM l_param) |
LRESULT CALLBACK | window_wndproc (HWND hwnd, UINT msg, WPARAM w_param, LPARAM l_param) |
typedef omgui::initializer::WindowData omgui::api::Window::data_type [inherited] |
typedef omgui::initializer::WidgetData omgui::api::Widget::data_type [inherited] |
Initialization data used for Widgets.
Reimplemented in omgui::api::Button, omgui::api::ComboBox, omgui::api::EntryBox, omgui::api::Notebook, omgui::api::Panel, omgui::api::SecureEntryBox, omgui::api::TableLayout, omgui::api::TextBox, omgui::api::TextWidget, and omgui::api::Window.
typedef omgui::Window omgui::api::Window::wrapper_type [inherited] |
Reimplemented from omgui::api::TopLevel.
typedef omgui::Widget omgui::api::Widget::wrapper_type [inherited] |
omgui::win32::Window::Window | ( | omgui::Window * | wrapper = 0 |
) |
void omgui::win32::Widget::add_ex_style | ( | int | style | ) | [inherited] |
Adds an extended style flag or flags to this HWND.
Performs existing_ex_style |= style
omgui::Size omgui::win32::Window::client_size_to_absolute | ( | const omgui::Size & | size | ) |
virtual void omgui::api::Window::create | ( | const data_type & | init_params | ) | [pure virtual, inherited] |
void omgui::win32::Widget::create | ( | const omgui::initializer::WidgetData & | params, | |
bool | parent_required, | |||
LPCTSTR | class_name, | |||
LPCTSTR | window_name, | |||
int | styles, | |||
int | styles_ex = 0 , |
|||
int | x = 0 , |
|||
int | y = 0 , |
|||
int | w = 0 , |
|||
int | h = 0 , |
|||
HMENU | menu = 0 | |||
) | [protected, inherited] |
Creates the native widget using CreateWindowEx.
params | Initializer arguments for position, size, visibility and enabled states. | |
parent_required | If true and params.m_parent is NULL, an exception is thrown | |
class_name | Class name passed to CreateWindowEx | |
window_name | Window name passed to CreateWindowEx | |
styles | Window styles | |
styles_ex | Extended window styles | |
x | X position | |
y | Y position | |
w | Width | |
h | Height | |
menu | The menu handle for the widget |
void omgui::win32::Window::create | ( | const omgui::initializer::WindowData & | params | ) |
void omgui::win32::Widget::destroy | ( | ) | [virtual, inherited] |
Implements omgui::api::Widget.
void omgui::win32::Widget::enable | ( | bool | e | ) | [virtual, inherited] |
Implements omgui::api::Widget.
Pointer< omgui::Panel > omgui::win32::Window::get_content_panel | ( | ) | const [virtual] |
Implements omgui::api::Window.
virtual omgui::Size omgui::win32::Window::get_content_size | ( | ) | [inline, virtual] |
Implements omgui::api::TopLevel.
virtual void* omgui::win32::Widget::get_handle | ( | ) | const [inline, virtual, inherited] |
Implements omgui::api::Widget.
HFONT omgui::win32::Widget::get_hfont | ( | ) | const [inherited] |
Gets the HFONT associated with this HWND
omgui::Size omgui::win32::Window::get_max_content_size | ( | ) | const [virtual] |
omgui::Size omgui::win32::Widget::get_max_size | ( | ) | const [virtual, inherited] |
Implements omgui::api::Widget.
Pointer< omgui::MenuBar > omgui::win32::Window::get_menu_bar | ( | ) | const [virtual] |
Implements omgui::api::Window.
omgui::Size omgui::win32::Window::get_min_content_size | ( | ) | const [virtual] |
omgui::Size omgui::win32::Widget::get_min_size | ( | ) | const [virtual, inherited] |
Implements omgui::api::Widget.
Reimplemented in omgui::win32::Notebook, and omgui::win32::TableLayout.
omgui::Size omgui::win32::Widget::get_natural_size | ( | ) | const [virtual, inherited] |
Implements omgui::api::Widget.
Pointer< omgui::Panel > omgui::win32::Widget::get_parent | ( | ) | const [virtual, inherited] |
Implements omgui::api::Widget.
Pointer< omgui::Window > omgui::win32::Widget::get_parent_window | ( | ) | const [virtual, inherited] |
Implements omgui::api::Widget.
omgui::Point omgui::win32::Widget::get_position | ( | ) | const [virtual, inherited] |
Implements omgui::api::Widget.
omgui::Rect omgui::win32::Widget::get_rect | ( | ) | const [virtual, inherited] |
Implements omgui::api::Widget.
omgui::Size omgui::win32::Widget::get_size | ( | ) | const [virtual, inherited] |
Implements omgui::api::Widget.
string omgui::win32::Window::get_title | ( | ) | [virtual] |
Implements omgui::api::TopLevel.
string omgui::win32::Window::get_window_placement | ( | ) | const [virtual] |
Implements omgui::api::Window.
int omgui::win32::Widget::get_window_styles | ( | ) | const [inherited] |
Gets the window styles for this HWND
string omgui::win32::Widget::get_window_text | ( | ) | const [inherited] |
T* omgui::common::Widget::get_wrapper | ( | ) | [inline, inherited] |
const T* omgui::common::Widget::get_wrapper | ( | ) | const [inline, inherited] |
omgui::Widget* omgui::common::Widget::get_wrapper | ( | ) | [inline, inherited] |
const omgui::Widget* omgui::common::Widget::get_wrapper | ( | ) | const [inline, inherited] |
omgui::object_id omgui::common::Widget::get_wrapper_id | ( | ) | const [inherited] |
void omgui::win32::Widget::invalidate_parent | ( | ) | [inherited] |
Calls invalidate_cached_child_values on the parent if there is one
bool omgui::win32::Widget::is_enabled | ( | ) | const [virtual, inherited] |
Implements omgui::api::Widget.
bool omgui::win32::Widget::is_hidden | ( | ) | const [virtual, inherited] |
Implements omgui::api::Widget.
bool omgui::win32::Widget::is_shown | ( | ) | const [virtual, inherited] |
Implements omgui::api::Widget.
void omgui::win32::Widget::post_create | ( | const omgui::initializer::WidgetData & | params | ) | [protected, virtual, inherited] |
Performs post widget creation initialization
bool omgui::win32::Widget::process_menu_command | ( | menu_id | id | ) | [inherited] |
Processes a WM_COMMAND sent from a menu.
int omgui::win32::Window::process_message | ( | HWND | hwnd, | |
UINT | msg, | |||
WPARAM | w_param, | |||
LPARAM | l_param | |||
) | [virtual] |
Instead of subclassing window procedures to simulate inheritance, there is only one window procedure, which is widget_wndproc. This function calls process_message which does all message processing. process_message is responsible for knowing whether or not to call DefWindowProc, or some other window procedure.
Reimplemented from omgui::win32::Widget.
bool omgui::win32::Widget::process_notification | ( | int | notification, | |
HWND | hwnd | |||
) | [inherited] |
Processes a WM_COMMAND sent from a control
void omgui::win32::Widget::remove_ex_style | ( | int | style | ) | [inherited] |
Removes an extended style flag or flags from this HWND.
Performs existing_ex_style &= ~style
Pointer< omgui::Panel > omgui::win32::Window::set_content_panel | ( | const Pointer< omgui::Panel > & | p | ) | [virtual] |
void omgui::win32::Window::set_content_size | ( | const omgui::Size & | s | ) | [virtual] |
void omgui::win32::Widget::set_default_font | ( | ) | [inherited] |
Sets the font for this HWND to be the acceptible default GUI font
void omgui::win32::Widget::set_default_font | ( | HWND | h | ) | [static, inherited] |
Sets the font for the given HWND to be the acceptible default GUI font
void omgui::win32::Window::set_max_content_size | ( | const omgui::Size & | size | ) | [virtual] |
void omgui::win32::Widget::set_max_size | ( | const omgui::Size & | s | ) | [virtual, inherited] |
Implements omgui::api::Widget.
void omgui::win32::Window::set_menu_bar | ( | const Pointer< omgui::MenuBar > & | menubar | ) | [virtual] |
Implements omgui::api::Window.
void omgui::win32::Window::set_min_content_size | ( | const omgui::Size & | size | ) | [virtual] |
void omgui::win32::Widget::set_min_size | ( | const omgui::Size & | s | ) | [virtual, inherited] |
Implements omgui::api::Widget.
void omgui::win32::Widget::set_natural_size | ( | const omgui::Size & | s | ) | [virtual, inherited] |
Implements omgui::api::Widget.
void omgui::win32::Widget::set_old_proc | ( | WNDPROC | proc | ) | [inline, protected, inherited] |
void omgui::win32::Widget::set_position | ( | const omgui::Point & | p | ) | [virtual, inherited] |
Implements omgui::api::Widget.
void omgui::win32::Widget::set_rect | ( | const omgui::Rect & | r | ) | [virtual, inherited] |
Implements omgui::api::Widget.
void omgui::win32::Widget::set_size | ( | const omgui::Size & | s | ) | [virtual, inherited] |
Implements omgui::api::Widget.
void omgui::win32::Window::set_title | ( | const string & | t | ) | [virtual] |
Implements omgui::api::TopLevel.
void omgui::win32::Window::set_window_placement | ( | const string & | placement | ) | [virtual] |
Implements omgui::api::Window.
void omgui::win32::Widget::set_window_pos | ( | int | x, | |
int | y, | |||
int | w, | |||
int | h, | |||
int | flags = 0 | |||
) | [protected, inherited] |
Wraps SetWindowPos and supports DeferWindowPos functionality
void omgui::win32::Widget::set_window_text | ( | const string & | str | ) | [inherited] |
void omgui::win32::Widget::show | ( | bool | show, | |
bool | focus | |||
) | [virtual, inherited] |
friend class CreationHook [friend, inherited] |
LRESULT CALLBACK widget_wndproc | ( | HWND | hwnd, | |
UINT | msg, | |||
WPARAM | w_param, | |||
LPARAM | l_param | |||
) | [friend, inherited] |
This is the window procedure which is implemented outside of the win32::widget classes. It is called by the window procedures for all widgets and contains only common functionality.
LRESULT CALLBACK window_wndproc | ( | HWND | hwnd, | |
UINT | msg, | |||
WPARAM | w_param, | |||
LPARAM | l_param | |||
) | [friend] |
bool omgui::win32::Widget::m_hidden [protected, inherited] |
HWND omgui::win32::Widget::m_hwnd [protected, inherited] |
omgui::Size omgui::win32::Widget::m_max_size [protected, inherited] |
Pointer<omgui::MenuBar> omgui::win32::Window::m_menubar [private] |
omgui::Size omgui::win32::Widget::m_min_size [protected, inherited] |
omgui::Size omgui::win32::Widget::m_natural_size [protected, inherited] |
WNDPROC omgui::win32::Widget::m_old_proc [protected, inherited] |