summaryrefslogtreecommitdiffstats
path: root/python/pyqt/examples3/tut3.py
blob: 9b739548d9af243f1b16c03b61529ce16cddb1e2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#!/usr/bin/env python

# Qt tutorial 3.

import sys
import qt


a = qt.QApplication(sys.argv)

box = qt.QVBox()
box.resize(200, 120)

quit = qt.QPushButton("Quit", box)
quit.setFont(qt.QFont("Times", 18, qt.QFont.Bold))

qt.QObject.connect(quit, qt.SIGNAL("clicked()"), a, qt.SLOT("quit()"))

a.setMainWidget(box)
box.show()
sys.exit(a.exec_loop())