annotate __main__.py @ 37:09af29ca763f default tip

more fixes to run with PyQt5
author Dirk Olmes <dirk@xanthippe.ping.de>
date Sat, 23 Dec 2017 02:56:24 +0100
parents 5b6e65b90784
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
f889ad584f0a initial import
Dirk Olmes <dirk@xanthippe.ping.de>
parents:
diff changeset
1 #!/usr/bin/env python3
f889ad584f0a initial import
Dirk Olmes <dirk@xanthippe.ping.de>
parents:
diff changeset
2
f889ad584f0a initial import
Dirk Olmes <dirk@xanthippe.ping.de>
parents:
diff changeset
3 # see http://stackoverflow.com/questions/6238193/pyqt-new-api-with-python-2
f889ad584f0a initial import
Dirk Olmes <dirk@xanthippe.ping.de>
parents:
diff changeset
4 import sip
f889ad584f0a initial import
Dirk Olmes <dirk@xanthippe.ping.de>
parents:
diff changeset
5 sip.setapi('QString', 2)
f889ad584f0a initial import
Dirk Olmes <dirk@xanthippe.ping.de>
parents:
diff changeset
6 sip.setapi('QVariant', 2)
f889ad584f0a initial import
Dirk Olmes <dirk@xanthippe.ping.de>
parents:
diff changeset
7
f889ad584f0a initial import
Dirk Olmes <dirk@xanthippe.ping.de>
parents:
diff changeset
8 import sys
36
5b6e65b90784 Port to PyQt5
Dirk Olmes <dirk@xanthippe.ping.de>
parents: 0
diff changeset
9 from PyQt5.QtWidgets import QApplication
0
f889ad584f0a initial import
Dirk Olmes <dirk@xanthippe.ping.de>
parents:
diff changeset
10 from RemoteViewer.RemoteViewer import RemoteViewer
f889ad584f0a initial import
Dirk Olmes <dirk@xanthippe.ping.de>
parents:
diff changeset
11
f889ad584f0a initial import
Dirk Olmes <dirk@xanthippe.ping.de>
parents:
diff changeset
12 if __name__ == '__main__':
f889ad584f0a initial import
Dirk Olmes <dirk@xanthippe.ping.de>
parents:
diff changeset
13 app = QApplication(sys.argv)
f889ad584f0a initial import
Dirk Olmes <dirk@xanthippe.ping.de>
parents:
diff changeset
14 window = RemoteViewer()
f889ad584f0a initial import
Dirk Olmes <dirk@xanthippe.ping.de>
parents:
diff changeset
15 window.show()
f889ad584f0a initial import
Dirk Olmes <dirk@xanthippe.ping.de>
parents:
diff changeset
16 sys.exit(app.exec_())