more links to originals in inspirations
This commit is contained in:
@ -18,14 +18,15 @@ def run_simple_button_app(title, actions):
|
||||
# create single widget
|
||||
widget = QtWidgets.QWidget()
|
||||
widget.setWindowTitle(title)
|
||||
widget.setMinimumSize(200, 400)
|
||||
widget.setMinimumSize(200, 200)
|
||||
|
||||
# add actions
|
||||
layout = QtWidgets.QVBoxLayout(widget)
|
||||
for name, action in actions:
|
||||
for name, action in actions.items():
|
||||
button = QtWidgets.QPushButton(name)
|
||||
button.clicked.connect(action)
|
||||
layout.addWidget(button)
|
||||
layout.addStretch()
|
||||
|
||||
# execute app
|
||||
widget.show()
|
||||
|
Reference in New Issue
Block a user