Home | All Classes | Main Classes | Annotated | Grouped Classes | Functions

QGrid Class Reference

The QGrid widget provides simple geometry management of its children. More...

#include <QGrid>

Inherits QFrame.

List of all members.

Writable Properties

Read-Only Properties

Public Functions

Public Slots

Signals

Static Public Members

Protected Functions


Detailed Description

The QGrid widget provides simple geometry management of its children.

The grid places its widgets either in columns or in rows depending on its orientation.

The number of rows or columns is defined in the constructor. All the grid's children will be placed and sized in accordance with their sizeHint() and sizePolicy().

Use setMargin() to add space around the grid itself, and setSpacing() to add space between the widgets.

If you just need a layout (not a widget) use QGridLayout instead.

QGrid

See also QVBox and QHBox.


Member Function Documentation

QGrid::QGrid ( int n, QWidget * parent = 0, Qt::WFlags f = 0 )

Constructs a grid widget with parent parent. n specifies the number of columns. The widget flags f are passed to the QFrame constructor.

QGrid::QGrid ( int n, Qt::Orientation orient, QWidget * parent = 0, Qt::WFlags f = 0 )

Constructs a grid widget with parent parent. If orient is Qt::Horizontal, n specifies the number of columns. If orient is Qt::Vertical, n specifies the number of rows. The widget flags f are passed to the QFrame constructor.

void QGrid::setSpacing ( int space )

Sets the spacing between the child widgets to space.


Copyright © 2004 Trolltech. Trademarks
Qt 4.0.0-tp1