Skip to content

Instantly share code, notes, and snippets.

@Indavelopers
Created June 2, 2017 10:50
Show Gist options
  • Save Indavelopers/2693ae58a0abbecd66803121851797e8 to your computer and use it in GitHub Desktop.
Save Indavelopers/2693ae58a0abbecd66803121851797e8 to your computer and use it in GitHub Desktop.
import sys
from PyQt4.QtGui import *
from PyQt4.QtCore import QT_VERSION_STR
from PyQt4.Qt import PYQT_VERSION_STR
from sip import SIP_VERSION_STR
a = QApplication(sys.argv)
w = QWidget()
w.resize(320, 240)
w.setWindowTitle("Hello World!")
label = QLabel()
info = "Qt version:" + QT_VERSION_STR + \
"\nSIP version:" + SIP_VERSION_STR + \
"\nPyQt version:" + PYQT_VERSION_STR
label.setText(info)
hbox = QHBoxLayout()
hbox.addWidget(label)
w.setLayout(hbox)
w.show()
sys.exit(a.exec_())
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment