Esempio n. 1
0
class MyWindow(QtGui.QMainWindow):
    def __init__(self):
        super(MyWindow, self).__init__()
        self.ui = Ui_MainWindow()
        self.ui.setupUi(self)
        self.ui.my_button.clicked.connect(self.on_my_button_push)
        self.show()

    def on_my_button_push(self):
        self.ui.my_label.setText("Button pushed!")
Esempio n. 2
0
 def __init__(self):
     super(MyWindow, self).__init__()
     self.ui = Ui_MainWindow()
     self.ui.setupUi(self)
     self.ui.my_button.clicked.connect(self.on_my_button_push)
     self.show()