#include <omgui/common/tablelayout.h>
Inherits omgui::common::Panel, and omgui::api::TableLayout.
Inherited by omgui::cocoa::TableLayout [virtual]
, omgui::gtk2::TableLayout [virtual]
, and omgui::win32::TableLayout [virtual]
.
Public Types | |
typedef omgui::initializer::TableLayoutData | data_type |
Initialization data used for TableLayout. | |
typedef omgui::initializer::PanelData | data_type |
Initialization data used for Panel. | |
typedef omgui::initializer::WidgetData | data_type |
Initialization data used for Widgets. | |
typedef omgui::TableLayout | wrapper_type |
typedef omgui::Panel | wrapper_type |
typedef omgui::Widget | wrapper_type |
Public Member Functions | |
void | add_child (const Pointer< omgui::Widget > &child) |
virtual void | create (const data_type &init_params)=0 |
void | create (const omgui::initializer::TableLayoutData ¶ms) |
virtual void | destroy ()=0 |
virtual void | enable (bool e)=0 |
const ChildList & | get_child_list () const |
virtual void * | get_handle () const =0 |
virtual omgui::Size | get_max_size () const =0 |
omgui::Size | get_min_size () const |
virtual omgui::Size | get_natural_size () const =0 |
virtual Pointer< omgui::Panel > | get_parent () const =0 |
virtual Pointer< omgui::Window > | get_parent_window () const =0 |
virtual omgui::Point | get_position () const =0 |
virtual omgui::Rect | get_rect () const =0 |
virtual omgui::Size | get_size () const =0 |
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_cached_child_values () |
virtual bool | is_enabled () const =0 |
virtual bool | is_hidden () const =0 |
bool | is_orphaned () const |
virtual bool | is_shown () const =0 |
void | remove_child (const Pointer< omgui::Widget > &) |
void | set_bottom_margin (int margin) |
void | set_column_gap (int gap) |
void | set_column_weight (int column, float weight) |
void | set_gap (int gap) |
void | set_left_margin (int margin) |
void | set_margins (int left, int top, int right, int bottom) |
void | set_margins (int margin) |
virtual void | set_max_size (const omgui::Size &)=0 |
virtual void | set_min_size (const omgui::Size &)=0 |
virtual void | set_natural_size (const omgui::Size &)=0 |
virtual void | set_position (const omgui::Point &)=0 |
virtual void | set_rect (const omgui::Rect &)=0 |
void | set_right_margin (int margin) |
void | set_row_gap (int gap) |
void | set_row_weight (int row, float weight) |
virtual void | set_size (const omgui::Size &)=0 |
void | set_top_margin (int margin) |
void | set_widget_layout_info (omgui::Widget *widget, const omgui::TableLayoutInfo &info) |
virtual void | show (bool show, bool focus)=0 |
TableLayout () | |
void | update_layout () |
Private Types | |
typedef std::map < omgui::Widget *, omgui::Rect > | WidgetRects |
Private Member Functions | |
template<tablelayoutdetails::GROUP > | |
void | calc_group_sizes () |
template<tablelayoutdetails::GROUP > | |
void | get_anchors (const tablelayoutdetails::LayoutData &data, int &anchor1, int &anchor2) const |
float & | get_column_weight (int index) |
template<tablelayoutdetails::GROUP > | |
int | get_gap () const |
template<> | |
bool | get_group_data (int index, tablelayoutdetails::GroupData &data) const |
template<> | |
bool | get_group_data (int index, tablelayoutdetails::GroupData &data) const |
template<tablelayoutdetails::GROUP > | |
bool | get_group_data (int index, tablelayoutdetails::GroupData &data) const |
template<tablelayoutdetails::GROUP > | |
tablelayoutdetails::GroupData & | get_group_data (int index) const |
template<tablelayoutdetails::GROUP > | |
void | get_margin_values (int &margin1, int &margin2) const |
template<tablelayoutdetails::GROUP > | |
int & | get_non_empty_groups () const |
template<tablelayoutdetails::GROUP > | |
void | get_pad_values (const tablelayoutdetails::LayoutData &data, int &pad1, int &pad2) const |
template<> | |
int | get_pos_value (const omgui::Point &pos) const |
template<> | |
int | get_pos_value (const omgui::Point &pos) const |
template<tablelayoutdetails::GROUP > | |
int | get_pos_value (const omgui::Point &pos) const |
template<tablelayoutdetails::GROUP > | |
int & | get_pos_value (omgui::Point &pos) const |
float & | get_row_weight (int index) |
template<> | |
int | get_size_value (const omgui::Size &size) const |
template<> | |
int | get_size_value (const omgui::Size &size) const |
template<tablelayoutdetails::GROUP > | |
int | get_size_value (const omgui::Size &size) const |
template<tablelayoutdetails::GROUP > | |
int & | get_size_value (omgui::Size &size) const |
template<tablelayoutdetails::GROUP > | |
tablelayoutdetails::Groups & | get_widgets () const |
template<tablelayoutdetails::GROUP > | |
void | update_group_sizes () const |
void | update_sizes () const |
Updates the cached child widget minimum, natural and maximum sizes if necessary. Also recalculates column and row minimum sizes. | |
Private Attributes | |
int | m_column_gap |
tablelayoutdetails::Groups | m_columns |
int | m_margin_bottom |
int | m_margin_left |
int | m_margin_right |
int | m_margin_top |
omgui::Size | m_min_size |
omgui::Size | m_natural_size |
int | m_non_empty_columns |
int | m_non_empty_rows |
int | m_row_gap |
tablelayoutdetails::Groups | m_rows |
bool | m_values_invalid |
tablelayoutdetails::Widgets | m_widgets |
typedef omgui::initializer::TableLayoutData omgui::api::TableLayout::data_type [inherited] |
typedef omgui::initializer::PanelData omgui::api::Panel::data_type [inherited] |
Initialization data used for Panel.
Reimplemented from omgui::api::Widget.
Reimplemented in omgui::api::Notebook, and omgui::api::TableLayout.
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 std::map<omgui::Widget*, omgui::Rect> omgui::common::TableLayout::WidgetRects [private] |
typedef omgui::TableLayout omgui::api::TableLayout::wrapper_type [inherited] |
Reimplemented from omgui::api::Panel.
typedef omgui::Panel omgui::api::Panel::wrapper_type [inherited] |
Reimplemented from omgui::api::Widget.
Reimplemented in omgui::api::Notebook, and omgui::api::TableLayout.
typedef omgui::Widget omgui::api::Widget::wrapper_type [inherited] |
omgui::common::TableLayout::TableLayout | ( | ) |
void omgui::common::Panel::add_child | ( | const Pointer< omgui::Widget > & | child | ) | [virtual, inherited] |
Implements omgui::api::Panel.
void omgui::common::TableLayout::calc_group_sizes | ( | ) | [inline, private] |
Calculates the sizes of the widgets contained in this objects columns or rows based on the template parameter
virtual void omgui::api::TableLayout::create | ( | const data_type & | init_params | ) | [pure virtual, inherited] |
void omgui::common::TableLayout::create | ( | const omgui::initializer::TableLayoutData & | params | ) |
Reimplemented in omgui::cocoa::TableLayout, omgui::gtk2::TableLayout, and omgui::win32::TableLayout.
virtual void omgui::api::Widget::destroy | ( | ) | [pure virtual, inherited] |
Implemented in omgui::cocoa::Panel, omgui::cocoa::Widget, omgui::gtk2::Widget, and omgui::win32::Widget.
virtual void omgui::api::Widget::enable | ( | bool | e | ) | [pure virtual, inherited] |
Implemented in omgui::cocoa::Widget, omgui::cocoa::Window, omgui::gtk2::Widget, and omgui::win32::Widget.
void omgui::common::TableLayout::get_anchors< ROW > | ( | const tablelayoutdetails::LayoutData & | data, | |
int & | anchor1, | |||
int & | anchor2 | |||
) | const [inline, private] |
const ChildList & omgui::common::Panel::get_child_list | ( | ) | const [virtual, inherited] |
Implements omgui::api::Panel.
float & omgui::common::TableLayout::get_column_weight | ( | int | index | ) | [private] |
int omgui::common::TableLayout::get_gap< ROW > | ( | ) | const [inline, private] |
bool omgui::common::TableLayout::get_group_data | ( | int | index, | |
tablelayoutdetails::GroupData & | data | |||
) | const [inline, private] |
bool omgui::common::TableLayout::get_group_data | ( | int | index, | |
tablelayoutdetails::GroupData & | data | |||
) | const [inline, private] |
bool omgui::common::TableLayout::get_group_data | ( | int | index, | |
tablelayoutdetails::GroupData & | data | |||
) | const [inline, private] |
tablelayoutdetails::GroupData & omgui::common::TableLayout::get_group_data< ROW > | ( | int | index | ) | const [inline, private] |
virtual void* omgui::api::Widget::get_handle | ( | ) | const [pure virtual, inherited] |
Implemented in omgui::cocoa::Widget, omgui::gtk2::Widget, and omgui::win32::Widget.
void omgui::common::TableLayout::get_margin_values< ROW > | ( | int & | margin1, | |
int & | margin2 | |||
) | const [inline, private] |
Returns either the left and right or top and bottom margin values based on the template parameter through the margin1 and margin2 arguments.
virtual omgui::Size omgui::api::Widget::get_max_size | ( | ) | const [pure virtual, inherited] |
Implemented in omgui::cocoa::Widget, omgui::gtk2::Widget, omgui::gtk2::Window, and omgui::win32::Widget.
omgui::Size omgui::common::TableLayout::get_min_size | ( | ) | const [virtual] |
Implements omgui::api::Widget.
Reimplemented in omgui::cocoa::TableLayout, omgui::gtk2::TableLayout, and omgui::win32::TableLayout.
virtual omgui::Size omgui::api::Widget::get_natural_size | ( | ) | const [pure virtual, inherited] |
Implemented in omgui::cocoa::Widget, omgui::gtk2::Widget, and omgui::win32::Widget.
int & omgui::common::TableLayout::get_non_empty_groups< ROW > | ( | ) | const [inline, private] |
void omgui::common::TableLayout::get_pad_values< ROW > | ( | const tablelayoutdetails::LayoutData & | data, | |
int & | pad1, | |||
int & | pad2 | |||
) | const [inline, private] |
Returns either the left and right or top and bottom padding values from the given data based on the template parameter through the pad1 and pad2 arguments.
virtual Pointer<omgui::Panel> omgui::api::Widget::get_parent | ( | ) | const [pure virtual, inherited] |
Implemented in omgui::cocoa::Widget, omgui::gtk2::Panel, omgui::gtk2::Widget, and omgui::win32::Widget.
virtual Pointer<omgui::Window> omgui::api::Widget::get_parent_window | ( | ) | const [pure virtual, inherited] |
Implemented in omgui::cocoa::Widget, omgui::gtk2::Widget, and omgui::win32::Widget.
int omgui::common::TableLayout::get_pos_value | ( | const omgui::Point & | pos | ) | const [inline, private] |
int omgui::common::TableLayout::get_pos_value | ( | const omgui::Point & | pos | ) | const [inline, private] |
int omgui::common::TableLayout::get_pos_value | ( | const omgui::Point & | pos | ) | const [inline, private] |
int & omgui::common::TableLayout::get_pos_value< ROW > | ( | omgui::Point & | pos | ) | const [inline, private] |
virtual omgui::Point omgui::api::Widget::get_position | ( | ) | const [pure virtual, inherited] |
Implemented in omgui::cocoa::Widget, omgui::cocoa::Window, omgui::gtk2::Widget, omgui::gtk2::Window, and omgui::win32::Widget.
virtual omgui::Rect omgui::api::Widget::get_rect | ( | ) | const [pure virtual, inherited] |
Implemented in omgui::cocoa::Widget, omgui::gtk2::Widget, and omgui::win32::Widget.
float & omgui::common::TableLayout::get_row_weight | ( | int | index | ) | [private] |
virtual omgui::Size omgui::api::Widget::get_size | ( | ) | const [pure virtual, inherited] |
Implemented in omgui::cocoa::Widget, omgui::cocoa::Window, omgui::gtk2::Widget, omgui::gtk2::Window, and omgui::win32::Widget.
int omgui::common::TableLayout::get_size_value | ( | const omgui::Size & | size | ) | const [inline, private] |
int omgui::common::TableLayout::get_size_value | ( | const omgui::Size & | size | ) | const [inline, private] |
int omgui::common::TableLayout::get_size_value | ( | const omgui::Size & | size | ) | const [inline, private] |
int & omgui::common::TableLayout::get_size_value< ROW > | ( | omgui::Size & | size | ) | const [inline, private] |
tablelayoutdetails::Groups & omgui::common::TableLayout::get_widgets< ROW > | ( | ) | const [inline, private] |
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::common::TableLayout::invalidate_cached_child_values | ( | ) | [virtual] |
Reimplemented from omgui::common::Panel.
virtual bool omgui::api::Widget::is_enabled | ( | ) | const [pure virtual, inherited] |
Implemented in omgui::cocoa::Widget, omgui::cocoa::Window, omgui::gtk2::Widget, and omgui::win32::Widget.
virtual bool omgui::api::Widget::is_hidden | ( | ) | const [pure virtual, inherited] |
Implemented in omgui::cocoa::Widget, and omgui::win32::Widget.
bool omgui::common::Panel::is_orphaned | ( | ) | const [virtual, inherited] |
Implements omgui::api::Panel.
virtual bool omgui::api::Widget::is_shown | ( | ) | const [pure virtual, inherited] |
Implemented in omgui::cocoa::Widget, omgui::cocoa::Window, omgui::gtk2::Widget, and omgui::win32::Widget.
void omgui::common::TableLayout::remove_child | ( | const Pointer< omgui::Widget > & | child | ) | [virtual] |
Reimplemented from omgui::common::Panel.
void omgui::common::TableLayout::set_bottom_margin | ( | int | margin | ) | [virtual] |
Implements omgui::api::TableLayout.
void omgui::common::TableLayout::set_column_gap | ( | int | gap | ) | [virtual] |
Implements omgui::api::TableLayout.
void omgui::common::TableLayout::set_column_weight | ( | int | column, | |
float | weight | |||
) | [virtual] |
Implements omgui::api::TableLayout.
void omgui::common::TableLayout::set_gap | ( | int | gap | ) | [virtual] |
Implements omgui::api::TableLayout.
void omgui::common::TableLayout::set_left_margin | ( | int | margin | ) | [virtual] |
Implements omgui::api::TableLayout.
void omgui::common::TableLayout::set_margins | ( | int | left, | |
int | top, | |||
int | right, | |||
int | bottom | |||
) | [virtual] |
Implements omgui::api::TableLayout.
void omgui::common::TableLayout::set_margins | ( | int | margin | ) | [virtual] |
Implements omgui::api::TableLayout.
virtual void omgui::api::Widget::set_max_size | ( | const omgui::Size & | ) | [pure virtual, inherited] |
Implemented in omgui::cocoa::Panel, omgui::cocoa::Widget, omgui::cocoa::Window, omgui::gtk2::Widget, omgui::gtk2::Window, and omgui::win32::Widget.
virtual void omgui::api::Widget::set_min_size | ( | const omgui::Size & | ) | [pure virtual, inherited] |
Implemented in omgui::cocoa::Panel, omgui::cocoa::Widget, omgui::cocoa::Window, omgui::gtk2::Widget, omgui::gtk2::Window, and omgui::win32::Widget.
virtual void omgui::api::Widget::set_natural_size | ( | const omgui::Size & | ) | [pure virtual, inherited] |
Implemented in omgui::cocoa::Widget, omgui::gtk2::Widget, and omgui::win32::Widget.
virtual void omgui::api::Widget::set_position | ( | const omgui::Point & | ) | [pure virtual, inherited] |
Implemented in omgui::cocoa::Widget, omgui::cocoa::Window, omgui::gtk2::Panel, omgui::gtk2::Widget, omgui::gtk2::Window, and omgui::win32::Widget.
virtual void omgui::api::Widget::set_rect | ( | const omgui::Rect & | ) | [pure virtual, inherited] |
Implemented in omgui::cocoa::Notebook, omgui::cocoa::TableLayout, omgui::cocoa::Widget, omgui::gtk2::Widget, and omgui::win32::Widget.
void omgui::common::TableLayout::set_right_margin | ( | int | margin | ) | [virtual] |
Implements omgui::api::TableLayout.
void omgui::common::TableLayout::set_row_gap | ( | int | gap | ) | [virtual] |
Implements omgui::api::TableLayout.
void omgui::common::TableLayout::set_row_weight | ( | int | row, | |
float | weight | |||
) | [virtual] |
Implements omgui::api::TableLayout.
virtual void omgui::api::Widget::set_size | ( | const omgui::Size & | ) | [pure virtual, inherited] |
void omgui::common::TableLayout::set_top_margin | ( | int | margin | ) | [virtual] |
Implements omgui::api::TableLayout.
void omgui::common::TableLayout::set_widget_layout_info | ( | omgui::Widget * | widget, | |
const omgui::TableLayoutInfo & | info | |||
) | [virtual] |
Implements omgui::api::TableLayout.
virtual void omgui::api::Widget::show | ( | bool | show, | |
bool | focus | |||
) | [pure virtual, inherited] |
void omgui::common::TableLayout::update_group_sizes | ( | ) | const [inline, private] |
Updates the cached min and max size values for each group
void omgui::common::TableLayout::update_layout | ( | ) | [virtual] |
Update the positions and sizes of all widgets
Reimplemented from omgui::common::Panel.
void omgui::common::TableLayout::update_sizes | ( | ) | const [private] |
Updates the cached child widget minimum, natural and maximum sizes if necessary. Also recalculates column and row minimum sizes.
int omgui::common::TableLayout::m_column_gap [private] |
tablelayoutdetails::Groups omgui::common::TableLayout::m_columns [mutable, private] |
int omgui::common::TableLayout::m_margin_bottom [private] |
int omgui::common::TableLayout::m_margin_left [private] |
int omgui::common::TableLayout::m_margin_right [private] |
int omgui::common::TableLayout::m_margin_top [private] |
omgui::Size omgui::common::TableLayout::m_min_size [mutable, private] |
omgui::Size omgui::common::TableLayout::m_natural_size [mutable, private] |
int omgui::common::TableLayout::m_non_empty_columns [mutable, private] |
int omgui::common::TableLayout::m_non_empty_rows [mutable, private] |
int omgui::common::TableLayout::m_row_gap [private] |
tablelayoutdetails::Groups omgui::common::TableLayout::m_rows [mutable, private] |
bool omgui::common::TableLayout::m_values_invalid [mutable, private] |
If this value is true, the values for m_min_size, m_max_size, and m_natural_size need to be recalculated, as well as the minimum column and row sizes.
tablelayoutdetails::Widgets omgui::common::TableLayout::m_widgets [mutable, private] |