-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathblank gui.py
57 lines (40 loc) · 1.62 KB
/
blank gui.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
#!/usr/bin/python
# -*- coding: utf-8 -*-
import sys
from PyQt4.QtGui import*
from PyQt4.QtCore import *
app = QApplication(sys.argv) # Creat a new QApplication object. This manages
# the GUI application's control flow and main
# settings.
#will get x and y axis sizemometer information from the wifi connection
#either plot x and y axis data against each other
#also display the x and y OBS data for levelling the device
class Gui(QWidget):
#base class of all user interface objects.
def __init__(self):
super(Gui, self).__init__()
self.initUI()
def initUI(self):
title1_font = QFont("Arial", 16, QFont.Bold) #Define title1 font
# Title
application_title = QLabel() #Create label for the window title
application_title.setText("ROV Control Interface") #Set Text
application_title.setFont(title1_font) #Set font
application_title.setAlignment(Qt.AlignCenter) #Set Allignment
#self.quit_button = QPushButton('Quit')
#self.quit_button.clicked.connect(self.close_app)
grid = QGridLayout() #Create layout container
#grid.addWidget(self.quit_button, 10, 1)
grid.addWidget(application_title, 0, 0)
self.setLayout(grid) #Set the layout
self.setGeometry(10, 100, 600, 300)
self.setWindowTitle('Test')
self.show()
#def close_app(self):
#print("Closing")
#sys.exit()
def main():
ex = Gui()
sys.exit(app.exec_())
if __name__ == '__main__':
main()