When i try to run this code, it's showing an error: NameError: name 'QtGui' is not defined
. What's wrong with my app?
Code:
import sys
from tkinter import *
from PyQt4 import *
from PyQt4.QtGui import *
from PyQt4.QtCore import *
class WindowHello(QtGui, QWidget, QtCore):
def __init__(self, parent = None):
QtGui.QWidget.__init__(self, parent)
self.setGeometry(650, 450, 450, 380)
self.label = QtGui.QLabel("<center>Hello!<center>")
self.box = QtGui.QVBoxLayout()
self.box.addWidget(self.label)
self.setLayout(self.box)
app = QtGui.QApplication(sys.argv)
op = WindowHello()
op.setWindowTitle('LangTIME')
op.setWindowIcon(QtGui.QIcon('Minilogowin.png'))
op.show()
sys.exit(app.exec_())
I'm did it all like in the example, but still it is showing error.