Home · All Classes · Modules

QGroupBox Class Reference
[QtGui module]

The QGroupBox widget provides a group box frame with a title. More...

Inherits QWidget.

Methods

Qt Signals


Detailed Description

The QGroupBox widget provides a group box frame with a title.

A group box provides a frame, a title and a keyboard shortcut, and displays various other widgets inside itself. The title is on top, the keyboard shortcut moves keyboard focus to one of the group box's child widgets.

QGroupBox also lets you set the title (normally set in the constructor) and the title's alignment(). If setCheckable(true) is called then the group box is isCheckable(), and it can be setChecked(). Checkable group boxes child widgets are enabled or disabled depending on whether or not the group box is isChecked().

To minimize space consumption, you can remove the right, left and bottom edges of the frame with setFlat().

Screenshot in Plastique style Screenshot in Windows style

See also QButtonGroup.


Method Documentation

QGroupBox.__init__ (self, QWidget parent = None)

The parent argument, if not None, causes self to be owned by Qt instead of PyQt.

Constructs a group box widget with no title and parent parent.

QGroupBox.__init__ (self, QString title, QWidget parent = None)

The parent argument, if not None, causes self to be owned by Qt instead of PyQt.

Constructs a group box with the title title and parent parent.

Qt.Alignment QGroupBox.alignment (self)

QGroupBox.changeEvent (self, QEvent)

QGroupBox.childEvent (self, QChildEvent)

bool QGroupBox.event (self, QEvent)

QGroupBox.focusInEvent (self, QFocusEvent)

bool QGroupBox.isCheckable (self)

bool QGroupBox.isChecked (self)

bool QGroupBox.isFlat (self)

QSize QGroupBox.minimumSizeHint (self)

QGroupBox.mouseMoveEvent (self, QMouseEvent event)

QGroupBox.mousePressEvent (self, QMouseEvent event)

QGroupBox.mouseReleaseEvent (self, QMouseEvent event)

QGroupBox.paintEvent (self, QPaintEvent)

QGroupBox.resizeEvent (self, QResizeEvent)

QGroupBox.setAlignment (self, int)

QGroupBox.setCheckable (self, bool b)

QGroupBox.setChecked (self, bool b)

This method is also a Qt slot with the C++ signature void setChecked(bool).

QGroupBox.setFlat (self, bool b)

QGroupBox.setTitle (self, QString)

QString QGroupBox.title (self)


Qt Signal Documentation

void toggled (bool)

If the group box has a check box (see isCheckable()) this signal is emitted when the check box is toggled. on is true if the check box is checked; otherwise it is false.


PyQt 4.0.1 for X11Copyright © Riverbank Computing Ltd and Trolltech AS 2006Qt 4.1.4