-
Notifications
You must be signed in to change notification settings - Fork 0
/
qtui_ui.py
118 lines (109 loc) · 5.88 KB
/
qtui_ui.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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
# -*- coding: utf-8 -*-
# Form implementation generated from reading ui file 'qtui.ui'
#
# Created by: PyQt5 UI code generator 5.15.9
#
# WARNING: Any manual changes made to this file will be lost when pyuic5 is
# run again. Do not edit this file unless you know what you are doing.
from PyQt5 import QtCore, QtGui, QtWidgets
class Ui_MainWindow(object):
def setupUi(self, MainWindow):
MainWindow.setObjectName("MainWindow")
MainWindow.resize(932, 622)
self.centralwidget = QtWidgets.QWidget(MainWindow)
self.centralwidget.setObjectName("centralwidget")
self.verticalLayoutWidget = QtWidgets.QWidget(self.centralwidget)
self.verticalLayoutWidget.setGeometry(QtCore.QRect(10, 10, 791, 371))
self.verticalLayoutWidget.setObjectName("verticalLayoutWidget")
self.upperlo = QtWidgets.QVBoxLayout(self.verticalLayoutWidget)
self.upperlo.setContentsMargins(0, 0, 0, 0)
self.upperlo.setObjectName("upperlo")
self.tableView = QtWidgets.QTableView(self.verticalLayoutWidget)
self.tableView.setEditTriggers(QtWidgets.QAbstractItemView.NoEditTriggers)
self.tableView.setSelectionMode(QtWidgets.QAbstractItemView.SingleSelection)
self.tableView.setSelectionBehavior(QtWidgets.QAbstractItemView.SelectRows)
self.tableView.setWordWrap(True)
self.tableView.setObjectName("tableView")
self.tableView.verticalHeader().setVisible(True)
self.upperlo.addWidget(self.tableView)
self.verticalLayoutWidget_2 = QtWidgets.QWidget(self.centralwidget)
self.verticalLayoutWidget_2.setGeometry(QtCore.QRect(10, 400, 791, 211))
self.verticalLayoutWidget_2.setObjectName("verticalLayoutWidget_2")
self.lowerlo = QtWidgets.QVBoxLayout(self.verticalLayoutWidget_2)
self.lowerlo.setContentsMargins(0, 0, 0, 0)
self.lowerlo.setObjectName("lowerlo")
self.ipf_editText = QtWidgets.QPlainTextEdit(self.verticalLayoutWidget_2)
self.ipf_editText.setObjectName("ipf_editText")
self.lowerlo.addWidget(self.ipf_editText)
self.btn_openpo = QtWidgets.QPushButton(self.centralwidget)
self.btn_openpo.setGeometry(QtCore.QRect(820, 10, 101, 25))
self.btn_openpo.setObjectName("btn_openpo")
self.btn_gpt = QtWidgets.QPushButton(self.centralwidget)
self.btn_gpt.setGeometry(QtCore.QRect(820, 430, 101, 51))
self.btn_gpt.setObjectName("btn_gpt")
self.ipf_apikey = QtWidgets.QPlainTextEdit(self.centralwidget)
self.ipf_apikey.setGeometry(QtCore.QRect(820, 560, 51, 31))
self.ipf_apikey.setObjectName("ipf_apikey")
self.lab_key_hint = QtWidgets.QLabel(self.centralwidget)
self.lab_key_hint.setGeometry(QtCore.QRect(820, 540, 101, 17))
self.lab_key_hint.setObjectName("lab_key_hint")
self.btn_connect = QtWidgets.QPushButton(self.centralwidget)
self.btn_connect.setGeometry(QtCore.QRect(870, 560, 51, 31))
font = QtGui.QFont()
font.setPointSize(8)
self.btn_connect.setFont(font)
self.btn_connect.setObjectName("btn_connect")
self.btn_prev = QtWidgets.QPushButton(self.centralwidget)
self.btn_prev.setGeometry(QtCore.QRect(820, 160, 41, 25))
self.btn_prev.setObjectName("btn_prev")
self.btn_next = QtWidgets.QPushButton(self.centralwidget)
self.btn_next.setGeometry(QtCore.QRect(880, 160, 41, 25))
self.btn_next.setObjectName("btn_next")
self.btn_jump = QtWidgets.QPushButton(self.centralwidget)
self.btn_jump.setGeometry(QtCore.QRect(820, 80, 101, 25))
font = QtGui.QFont()
font.setPointSize(10)
self.btn_jump.setFont(font)
self.btn_jump.setObjectName("btn_jump")
self.ipf_linenum = QtWidgets.QPlainTextEdit(self.centralwidget)
self.ipf_linenum.setGeometry(QtCore.QRect(820, 110, 101, 31))
self.ipf_linenum.setObjectName("ipf_linenum")
self.lab_connection_stat = QtWidgets.QLabel(self.centralwidget)
self.lab_connection_stat.setGeometry(QtCore.QRect(820, 590, 101, 20))
self.lab_connection_stat.setObjectName("lab_connection_stat")
self.btn_dupe = QtWidgets.QPushButton(self.centralwidget)
self.btn_dupe.setGeometry(QtCore.QRect(820, 400, 101, 25))
font = QtGui.QFont()
font.setPointSize(9)
self.btn_dupe.setFont(font)
self.btn_dupe.setObjectName("btn_dupe")
self.btn_save = QtWidgets.QPushButton(self.centralwidget)
self.btn_save.setGeometry(QtCore.QRect(820, 480, 101, 51))
font = QtGui.QFont()
font.setPointSize(12)
self.btn_save.setFont(font)
self.btn_save.setObjectName("btn_save")
MainWindow.setCentralWidget(self.centralwidget)
self.retranslateUi(MainWindow)
QtCore.QMetaObject.connectSlotsByName(MainWindow)
def retranslateUi(self, MainWindow):
_translate = QtCore.QCoreApplication.translate
MainWindow.setWindowTitle(_translate("MainWindow", "pydoc ZH-TW Translate Helper"))
self.btn_openpo.setText(_translate("MainWindow", "Open .po"))
self.btn_gpt.setText(_translate("MainWindow", "GPT help"))
self.lab_key_hint.setText(_translate("MainWindow", "API key here"))
self.btn_connect.setText(_translate("MainWindow", "Connect"))
self.btn_prev.setText(_translate("MainWindow", "Prev"))
self.btn_next.setText(_translate("MainWindow", "Next"))
self.btn_jump.setText(_translate("MainWindow", "Jump to entry"))
self.lab_connection_stat.setText(_translate("MainWindow", "Not connected"))
self.btn_dupe.setText(_translate("MainWindow", "Duplicate original"))
self.btn_save.setText(_translate("MainWindow", "Save"))
if __name__ == "__main__":
import sys
app = QtWidgets.QApplication(sys.argv)
MainWindow = QtWidgets.QMainWindow()
ui = Ui_MainWindow()
ui.setupUi(MainWindow)
MainWindow.show()
sys.exit(app.exec_())