Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/python
- # -*- coding: utf-8 -*-
- import sys
- from PySide import QtGui
- def new_window():
- global wid
- wid = QtGui.QWidget()
- wid.resize(250, 150)
- wid.setWindowTitle(u'Drugie okno')
- wid.show()
- app = QtGui.QApplication(sys.argv)
- wid = QtGui.QWidget()
- wid.resize(250, 150)
- wid.setWindowTitle('Simple')
- wid.show()
- button = QtGui.QPushButton(u'Nowe okno')
- button.clicked.connect(new_window)
- layout = QtGui.QVBoxLayout(wid)
- layout.addWidget(button)
- sys.exit(app.exec_())
Advertisement
Add Comment
Please, Sign In to add comment