gtkmm: Gtk::Grid Class Reference

A container which arranges its child widgets in rows and columns. More...

Inheritance diagram for Gtk::Grid:
Collaboration diagram for Gtk::Grid:

List of all members.

Public Member Functions

virtual ~Grid ()
GtkGrid* gobj ()
 Provides access to the underlying C GtkObject.

const GtkGrid* gobj () const
 Provides access to the underlying C GtkObject.

 Grid ()
void attach (Widget& child, int left, int top, int width, int height)
void attach_next_to (Widget& child, Widget& sibling, PositionType side, int width, int height)
void set_row_homogeneous (bool homogeneous=true)
bool get_row_homogeneous () const
void set_row_spacing (guint spacing)
guint get_row_spacing () const
void set_column_homogeneous (bool homogeneous)
bool get_column_homogeneous () const
void set_column_spacing (guint spacing)
guint get_column_spacing () const
Glib::PropertyProxy< Orientationproperty_orientation ()
 The orientation of the orientable.

Glib::PropertyProxy_ReadOnly

< Orientation
property_orientation () const
 The orientation of the orientable.

Glib::PropertyProxy< guint > property_row_spacing ()
 The amount of space between two consecutive rows.

Glib::PropertyProxy_ReadOnly

< guint > 
property_row_spacing () const
 The amount of space between two consecutive rows.

Glib::PropertyProxy< guint > property_column_spacing ()
 The amount of space between two consecutive columns.

Glib::PropertyProxy_ReadOnly

< guint > 
property_column_spacing () const
 The amount of space between two consecutive columns.

Glib::PropertyProxy< bool > property_row_homogeneous ()
 If TRUE, the rows are all the same height.

Glib::PropertyProxy_ReadOnly

< bool > 
property_row_homogeneous () const
 If TRUE, the rows are all the same height.

Glib::PropertyProxy< bool > property_column_homogeneous ()
 If TRUE, the columns are all the same width.

Glib::PropertyProxy_ReadOnly

< bool > 
property_column_homogeneous () const
 If TRUE, the columns are all the same width.

Related Functions

(Note that these are not member functions.)

Gtk::Gridwrap (GtkGrid* object, bool take_copy=false)
 A Glib::wrap() method for this object.


Detailed Description

A container which arranges its child widgets in rows and columns.

It is a very similar to Table and Box, but it consistently uses Widget's margin and expand properties instead of custom child properties, and it fully supports height-for-width geometry management.

Children are added using attach(). They can span multiple rows or columns. It is also possible to add a child next to an existing child, using attach_next_to().

Grid can be used like a Box by just using Gtk::Container::add(), which will place children next to each other in the direction determined by the orientation property.

Since gtkmm 3.0:

Constructor & Destructor Documentation

virtual Gtk::Grid::~Grid ( ) [virtual]
Gtk::Grid::Grid ( )

Member Function Documentation

void Gtk::Grid::attach ( Widget child,
int  left,
int  top,
int  width,
int  height 
)
void Gtk::Grid::attach_next_to ( Widget child,
Widget sibling,
PositionType  side,
int  width,
int  height 
)
bool Gtk::Grid::get_column_homogeneous ( ) const
guint Gtk::Grid::get_column_spacing ( ) const
bool Gtk::Grid::get_row_homogeneous ( ) const
guint Gtk::Grid::get_row_spacing ( ) const
const GtkGrid* Gtk::Grid::gobj ( ) const [inline]

Provides access to the underlying C GtkObject.

Reimplemented from Gtk::Container.

GtkGrid* Gtk::Grid::gobj ( ) [inline]

Provides access to the underlying C GtkObject.

Reimplemented from Gtk::Container.

Glib::PropertyProxy<bool> Gtk::Grid::property_column_homogeneous ( )

If TRUE, the columns are all the same width.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.
Glib::PropertyProxy_ReadOnly<bool> Gtk::Grid::property_column_homogeneous ( ) const

If TRUE, the columns are all the same width.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.
Glib::PropertyProxy<guint> Gtk::Grid::property_column_spacing ( )

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.

Returns:
A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.
Glib::PropertyProxy_ReadOnly<guint> Gtk::Grid::property_column_spacing ( ) const

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.

Returns:
A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.
Glib::PropertyProxy<Orientation> Gtk::Grid::property_orientation ( )

The orientation of the orientable.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Reimplemented from Gtk::Orientable.

Glib::PropertyProxy_ReadOnly<Orientation> Gtk::Grid::property_orientation ( ) const

The orientation of the orientable.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Reimplemented from Gtk::Orientable.

Glib::PropertyProxy_ReadOnly<bool> Gtk::Grid::property_row_homogeneous ( ) const

If TRUE, the rows are all the same height.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.
Glib::PropertyProxy<bool> Gtk::Grid::property_row_homogeneous ( )

If TRUE, the rows are all the same height.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.
Glib::PropertyProxy_ReadOnly<guint> Gtk::Grid::property_row_spacing ( ) const

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.

Returns:
A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.
Glib::PropertyProxy<guint> Gtk::Grid::property_row_spacing ( )

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.

Returns:
A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.
void Gtk::Grid::set_column_homogeneous ( bool  homogeneous)
void Gtk::Grid::set_column_spacing ( guint  spacing)
void Gtk::Grid::set_row_homogeneous ( bool  homogeneous = true)
void Gtk::Grid::set_row_spacing ( guint  spacing)

Friends And Related Function Documentation

Gtk::Grid* wrap ( GtkGrid *  object,
bool  take_copy = false 
) [related]

A Glib::wrap() method for this object.

Parameters:
objectThe C instance.
take_copyFalse if the result should take ownership of the C instance. True if it should take a new copy or ref.
Returns:
A C++ instance that wraps this C instance.

The documentation for this class was generated from the following file:
  • gtkmm/grid.h