![]() |
![]() |
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.
Gtk::EXPAND
, the lattice is allowed to grow to fill space. With Gtk::SHRINK
, the lattice is allowed to shrink when resized. It is also possible to specify the behaviour of the widgets allocation within the table. The flag Gtk::FILL
declares the widget should grow to fill lattice. If this is not set any extra space is used as padding. The default is (Gtk::FILL | Gtk::EXPAND)
.
Public Types | |
typedef Table_Helpers::TableList | TableList |
Public Member Functions | |
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) |
const TableList& | children () const |
TableList& | children () |
guint | get_col_spacing (guint column) const |
Gets the amount of space between column col , and column col + 1. | |
guint | get_default_col_spacing () |
Gets the default column spacing for the table. | |
guint | get_default_row_spacing () |
Gets the default row spacing for the table. | |
bool | get_homogeneous () const |
Returns whether the table cells are all constrained to the same width and height. | |
guint | get_row_spacing (guint row) const |
Gets the amount of space between row row , and row row + 1. | |
const GtkTable* | gobj () const |
Provides access to the underlying C GtkObject. | |
GtkTable* | gobj () |
Provides access to the underlying C GtkObject. | |
Glib::PropertyProxy_ReadOnly< guint > | property_column_spacing () const |
The amount of space between two consecutive columns. | |
Glib::PropertyProxy<guint> | property_column_spacing () |
The amount of space between two consecutive columns. | |
Glib::PropertyProxy_ReadOnly< guint > | property_n_columns () const |
The number of columns in the table. | |
Glib::PropertyProxy<guint> | property_n_columns () |
The number of columns in the table. | |
Glib::PropertyProxy_ReadOnly< guint > | property_n_rows () const |
The number of rows in the table. | |
Glib::PropertyProxy<guint> | property_n_rows () |
The number of rows in the table. | |
Glib::PropertyProxy_ReadOnly< guint > | property_row_spacing () const |
The amount of space between two consecutive rows. | |
Glib::PropertyProxy<guint> | property_row_spacing () |
The amount of space between two consecutive rows. | |
void | resize (guint rows, guint columns) |
void | set_col_spacing (guint column, guint spacing) |
void | set_col_spacings (guint spacing) |
void | set_homogeneous (bool homogeneous=true) |
void | set_row_spacing (guint row, guint spacing) |
void | set_row_spacings (guint spacing) |
void | set_spacings (guint spacing) |
Table (guint n_rows=1, guint n_columns=1, bool homogeneous=false) | |
virtual | ~Table () |
Related Functions | |
(Note that these are not member functions.) | |
Gtk::Table* | wrap (GtkTable* object, bool take_copy=false) |
|
|
|
|
|
|
|
|
|
|
|
|
|
Gets the amount of space between column col , and column col + 1. See set_col_spacing().
|
|
Gets the default column spacing for the table. This is the spacing that will be used for newly added columns. (See set_col_spacings())
|
|
Gets the default row spacing for the table. This is the spacing that will be used for newly added rows. (See set_row_spacings())
|
|
Returns whether the table cells are all constrained to the same width and height. (See set_homogenous())
|
|
Gets the amount of space between row row , and row row + 1. See set_row_spacing().
|
|
Provides access to the underlying C GtkObject.
Reimplemented from Gtk::Container. |
|
Provides access to the underlying C GtkObject.
Reimplemented from Gtk::Container. |
|
The amount of space between two consecutive columns. You rarely need to use properties because there are get_ and set_ methods for almost all of them.
|
|
The amount of space between two consecutive columns. You rarely need to use properties because there are get_ and set_ methods for almost all of them.
|
|
The number of columns in the table. You rarely need to use properties because there are get_ and set_ methods for almost all of them.
|
|
The number of columns in the table. You rarely need to use properties because there are get_ and set_ methods for almost all of them.
|
|
The number of rows in the table. You rarely need to use properties because there are get_ and set_ methods for almost all of them.
|
|
The number of rows in the table. You rarely need to use properties because there are get_ and set_ methods for almost all of them.
|
|
The amount of space between two consecutive rows. You rarely need to use properties because there are get_ and set_ methods for almost all of them.
|
|
The amount of space between two consecutive rows. You rarely need to use properties because there are get_ and set_ methods for almost all of them.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|