Gtk::Table is one of the primary ways of grouping widgets together. It consists of a set of lattice points to to which widgets can be attached. There are rows + 1 lattice points vertically and columns + 1 lattice points horizontally. Lattice points start counting from 0. Lattice points can either be specified to be homogeneous, meaning equally spaced, or not homogeneous, meaning each cell should be calculated based on the widgets contained in the row and column. The homogeneous property defaults to false.
Widgets can be attached to the table by specifying the top, bottom, left and right points corresponding to upper, lefthand lattice point and the lower, righthand lattice point which the widget should span. Widgets can either be contained in a cell or may span cells. A number of options control the resizing behavior of widgets contained in the table.
|
Public Types |
typedef Table_Helpers::TableList | TableList |
Public Member Functions |
virtual | ~Table () |
GtkTable* | gobj () |
| Provides access to the underlying C GtkObject.
|
const GtkTable* | gobj () const |
| Provides access to the underlying C GtkObject.
|
| Table (guint n_rows=1, guint n_columns=1, bool homogeneous=false) |
void | attach (Widget& child, guint left_attach, guint right_attach, guint top_attach, guint bottom_attach, AttachOptions xoptions=FILL|EXPAND, AttachOptions yoptions=FILL|EXPAND, guint xpadding=0, guint ypadding=0) |
void | resize (guint rows, guint columns) |
void | set_row_spacing (guint row, guint spacing) |
guint | get_row_spacing (guint row) const |
| Gets the amount of space between row row , and row row + 1.
|
void | set_col_spacing (guint column, guint spacing) |
guint | get_col_spacing (guint column) const |
| Gets the amount of space between column col , and column col + 1.
|
void | set_row_spacings (guint spacing) |
void | set_col_spacings (guint spacing) |
void | set_spacings (guint spacing) |
guint | get_default_row_spacing () |
| Gets the default row spacing for the table.
|
guint | get_default_col_spacing () |
| Gets the default column spacing for the table.
|
void | set_homogeneous (bool homogeneous=true) |
bool | get_homogeneous () const |
| Returns whether the table cells are all constrained to the same width and height.
|
TableList& | children () |
const TableList& | children () const |
Glib::PropertyProxy<guint> | property_n_rows () |
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
|
Glib::PropertyProxy<guint> | property_n_columns () |
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
|
Glib::PropertyProxy<guint> | property_column_spacing () |
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
|
Glib::PropertyProxy<guint> | property_row_spacing () |
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
|
Related Functions |
(Note that these are not member functions.)
|
Gtk::Table* | wrap (GtkTable* object, bool take_copy=false) |