KDialogButtonBox Class Reference
from PyKDE4.kdeui import *
Inherits: QDialogButtonBox → QWidget → QObject
Detailed Description
Container widget for buttons.
An extension of QDialogButtonBox which allow the use of KGuiItem and conveniance slot connection.
"Various KDE Dialog Button Boxes with different buttons"
Methods | |
__init__ (self, QWidget parent, Qt::Orientation _orientation=Qt.Horizontal) | |
QPushButton | addButton (self, QString text, QDialogButtonBox::ButtonRole role, SIP_RXOBJ_CON a2, SIP_SLOT_CON () a3) |
KPushButton | addButton (self, KGuiItem guiitem, QDialogButtonBox::ButtonRole role, SIP_RXOBJ_CON a2, SIP_SLOT_CON () a3) |
Method Documentation
__init__ | ( | self, | ||
QWidget | parent, | |||
Qt::Orientation | _orientation=Qt.Horizontal | |||
) |
Create an empty container for buttons.
If _orientation is Vertical, the buttons inserted with addButton() are laid out from top to bottom, otherwise they are laid out from left to right.
QPushButton addButton | ( | self, | ||
QString | text, | |||
QDialogButtonBox::ButtonRole | role, | |||
SIP_RXOBJ_CON | a2, | |||
SIP_SLOT_CON () | a3 | |||
) |
Creates a push button with the given KUiItem, adds it to the button box for the specified role, and returns the corresponding push button. If role is invalid, the button is created, but not added.
The clicked signal of the button is automatically connected to the slot
- Parameters:
-
guiitem text and icon on the button role the button role receiver An object to connect to. slot A Qt slot to connect the 'clicked()' signal to.
- Returns:
- A pointer to the new button.
KPushButton addButton | ( | self, | ||
KGuiItem | guiitem, | |||
QDialogButtonBox::ButtonRole | role, | |||
SIP_RXOBJ_CON | a2, | |||
SIP_SLOT_CON () | a3 | |||
) |
Creates a push button with the given KUiItem, adds it to the button box for the specified role, and returns the corresponding push button. If role is invalid, the button is created, but not added.
The clicked signal of the button is automatically connected to the slot
- Parameters:
-
guiitem text and icon on the button role the button role receiver An object to connect to. slot A Qt slot to connect the 'clicked()' signal to.
- Returns:
- A pointer to the new button.