DialogButtonBox
Base classes
| Name | Children | Inherits |
|---|---|---|
| WidgetMixin prettyqt.widgets.widget |
||
| QDialogButtonBox PySide6.QtWidgets QDialogButtonBox(self, orientation: PySide6.QtCore.Qt.Orientation, /, parent: PySide6.QtWidgets.QWidget | None \= None, *, standardButtons: PySide6.QtWidgets.QDialogButtonBox.StandardButton | None \= None, centerButtons: bool | None \= None) -> None |
â‹” Inheritance diagram
graph TD
477347109["widgets.DialogButtonBox"]
829357528["widgets.WidgetMixin"]
3227531497["core.ObjectMixin"]
2751680898["builtins.object"]
625385617["gui.PaintDeviceMixin"]
4020850882["QtWidgets.QDialogButtonBox"]
3620195106["QtWidgets.QWidget"]
3984060476["QtCore.QObject"]
37984305["Shiboken.Object"]
673956333["QtGui.QPaintDevice"]
829357528 --> 477347109
3227531497 --> 829357528
2751680898 --> 3227531497
625385617 --> 829357528
2751680898 --> 625385617
2751680898 --> 829357528
4020850882 --> 477347109
3620195106 --> 4020850882
3984060476 --> 3620195106
37984305 --> 3984060476
2751680898 --> 37984305
673956333 --> 3620195106
37984305 --> 673956333
🛈 DocStrings
Bases: WidgetMixin, QDialogButtonBox
Widget presenting buttons in a layout that is appropriate to the widget style.
Source code in prettyqt/widgets/dialogbuttonbox.py
85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 | |
add_button(button: widgets.QPushButton | str, role: RoleStr | widgets.QDialogButtonBox.ButtonRole = 'accept', callback: Callable | None = None) -> widgets.QPushButton
Add a button.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
button
|
QPushButton | str
|
button to add |
required |
role
|
RoleStr | ButtonRole
|
role of the button |
'accept'
|
callback
|
Callable | None
|
function to call when button gets clicked |
None
|
add_default_button(button: StandardButtonStr | widgets.QDialogButtonBox.StandardButton, callback: Callable | None = None) -> widgets.QPushButton
Add a default button.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
button
|
StandardButtonStr | StandardButton
|
button to add |
required |
callback
|
Callable | None
|
function to call when button gets clicked |
None
|