Q3Grid Class

The Q3Grid widget provides simple geometry management of its children. 更多...

頭: #include <Q3Grid>
繼承: Q3Frame

公共函數

Q3Grid (int n , QWidget * parent = 0, const char * name = 0, Qt::WindowFlags f = 0)
Q3Grid (int n , Qt::Orientation orient , QWidget * parent = 0, const char * name = 0, Qt::WindowFlags f = 0)
void setSpacing (int space )

重實現公共函數

virtual QSize sizeHint () const

重實現保護函數

virtual void frameChanged ()

額外繼承成員

詳細描述

The Q3Grid 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 () 和 sizePolicy ().

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

另請參閱 Q3VBox , Q3HBox ,和 QGridLayout .

成員函數文檔編製

Q3Grid:: Q3Grid ( int n , QWidget * parent = 0, const char * name = 0, Qt::WindowFlags f = 0)

Constructs a grid widget with parent parent , called name . n specifies the number of columns. The widget flags f 被傳遞給 Q3Frame 構造函數。

Q3Grid:: Q3Grid ( int n , Qt::Orientation orient , QWidget * parent = 0, const char * name = 0, Qt::WindowFlags f = 0)

Constructs a grid widget with parent parent , called name 。若 orient is Horizontal , n specifies the number of columns. If orient is Vertical , n specifies the number of rows. The widget flags f 被傳遞給 Q3Frame 構造函數。

[virtual protected] void Q3Grid:: frameChanged ()

重實現自 Q3Frame::frameChanged ().

void Q3Grid:: setSpacing ( int space )

Sets the spacing between the child widgets to space .

[虛擬] QSize Q3Grid:: sizeHint () const

重實現自 QWidget::sizeHint ().