-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgui.py
295 lines (288 loc) · 17.8 KB
/
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
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
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
# -*- coding: utf-8 -*-
# Form implementation generated from reading ui file 'gui2.ui'
#
# Created: Tue Jun 24 15:48:16 2014
# by: PyQt4 UI code generator 4.10.4
#
# WARNING! All changes made in this file will be lost!
from PyQt4 import QtCore, QtGui
QtCore.QTextCodec.setCodecForCStrings(QtCore.QTextCodec.codecForName("UTF-8"))
try:
_fromUtf8 = QtCore.QString.fromUtf8
except AttributeError:
def _fromUtf8(s):
return s
try:
_encoding = QtGui.QApplication.UnicodeUTF8
def _translate(context, text, disambig):
return QtGui.QApplication.translate(context, text, disambig, _encoding)
except AttributeError:
def _translate(context, text, disambig):
return QtGui.QApplication.translate(context, text, disambig)
class Ui_MainWindow(object):
def setupUi(self, MainWindow):
MainWindow.setObjectName(_fromUtf8("MainWindow"))
MainWindow.setEnabled(True)
MainWindow.resize(800, 650)
MainWindow.setMinimumSize(QtCore.QSize(800, 650))
MainWindow.setMaximumSize(QtCore.QSize(800, 650))
palette = QtGui.QPalette()
brush = QtGui.QBrush(QtGui.QColor(255, 255, 255))
brush.setStyle(QtCore.Qt.SolidPattern)
palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Base, brush)
brush = QtGui.QBrush(QtGui.QColor(180, 205, 230))
brush.setStyle(QtCore.Qt.SolidPattern)
palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Window, brush)
brush = QtGui.QBrush(QtGui.QColor(255, 255, 255))
brush.setStyle(QtCore.Qt.SolidPattern)
palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Base, brush)
brush = QtGui.QBrush(QtGui.QColor(180, 205, 230))
brush.setStyle(QtCore.Qt.SolidPattern)
palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Window, brush)
brush = QtGui.QBrush(QtGui.QColor(180, 205, 230))
brush.setStyle(QtCore.Qt.SolidPattern)
palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Base, brush)
brush = QtGui.QBrush(QtGui.QColor(180, 205, 230))
brush.setStyle(QtCore.Qt.SolidPattern)
palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Window, brush)
MainWindow.setPalette(palette)
MainWindow.setWindowOpacity(1.0)
MainWindow.setAutoFillBackground(True)
MainWindow.setDocumentMode(False)
self.centralwidget = QtGui.QWidget(MainWindow)
self.centralwidget.setObjectName(_fromUtf8("centralwidget"))
self.progressBar_GenerateOutFile = QtGui.QProgressBar(self.centralwidget)
self.progressBar_GenerateOutFile.setGeometry(QtCore.QRect(10, 590, 781, 16))
self.progressBar_GenerateOutFile.setAutoFillBackground(False)
self.progressBar_GenerateOutFile.setProperty("value", 0)
self.progressBar_GenerateOutFile.setTextVisible(False)
self.progressBar_GenerateOutFile.setObjectName(_fromUtf8("progressBar_GenerateOutFile"))
self.Button_LoadOutFile = QtGui.QPushButton(self.centralwidget)
self.Button_LoadOutFile.setGeometry(QtCore.QRect(400, 10, 111, 31))
icon = QtGui.QIcon()
icon.addPixmap(QtGui.QPixmap(_fromUtf8("C:/Users/rafal/.designer/backup/Image/Rysunek.svg-path3297-4294966409.png")), QtGui.QIcon.Normal, QtGui.QIcon.Off)
self.Button_LoadOutFile.setIcon(icon)
self.Button_LoadOutFile.setIconSize(QtCore.QSize(25, 25))
self.Button_LoadOutFile.setObjectName(_fromUtf8("Button_LoadOutFile"))
self.listWidget_MainFile = QtGui.QListWidget(self.centralwidget)
self.listWidget_MainFile.setGeometry(QtCore.QRect(10, 156, 381, 391))
font = QtGui.QFont()
font.setFamily(_fromUtf8("Tahoma"))
font.setPointSize(9)
self.listWidget_MainFile.setFont(font)
self.listWidget_MainFile.setProperty("isWrapping", False)
self.listWidget_MainFile.setWordWrap(True)
self.listWidget_MainFile.setObjectName(_fromUtf8("listWidget_MainFile"))
self.Button_LoadMainFilePath = QtGui.QPushButton(self.centralwidget)
self.Button_LoadMainFilePath.setGeometry(QtCore.QRect(60, 10, 111, 31))
self.Button_LoadMainFilePath.setObjectName(_fromUtf8("Button_LoadMainFilePath"))
self.listWidget_OutFilesList = QtGui.QListWidget(self.centralwidget)
self.listWidget_OutFilesList.setGeometry(QtCore.QRect(400, 46, 391, 61))
self.listWidget_OutFilesList.setObjectName(_fromUtf8("listWidget_OutFilesList"))
self.horizontalSlider_Threshold = QtGui.QSlider(self.centralwidget)
self.horizontalSlider_Threshold.setEnabled(False)
self.horizontalSlider_Threshold.setGeometry(QtCore.QRect(500, 126, 160, 19))
self.horizontalSlider_Threshold.setMinimum(1)
self.horizontalSlider_Threshold.setMaximum(100)
self.horizontalSlider_Threshold.setOrientation(QtCore.Qt.Horizontal)
self.horizontalSlider_Threshold.setObjectName(_fromUtf8("horizontalSlider_Threshold"))
self.label_numberOfThreshold = QtGui.QLabel(self.centralwidget)
self.label_numberOfThreshold.setGeometry(QtCore.QRect(670, 116, 131, 31))
self.label_numberOfThreshold.setObjectName(_fromUtf8("label_numberOfThreshold"))
self.listWidget_ChoosenOutFile = QtGui.QListWidget(self.centralwidget)
self.listWidget_ChoosenOutFile.setGeometry(QtCore.QRect(400, 156, 391, 391))
font = QtGui.QFont()
font.setFamily(_fromUtf8("Tahoma"))
font.setPointSize(9)
self.listWidget_ChoosenOutFile.setFont(font)
self.listWidget_ChoosenOutFile.setWordWrap(True)
self.listWidget_ChoosenOutFile.setObjectName(_fromUtf8("listWidget_ChoosenOutFile"))
self.label_20 = QtGui.QLabel(self.centralwidget)
self.label_20.setEnabled(True)
self.label_20.setGeometry(QtCore.QRect(510, 96, 151, 41))
font = QtGui.QFont()
font.setFamily(_fromUtf8("Tahoma"))
font.setPointSize(10)
font.setBold(False)
font.setWeight(50)
self.label_20.setFont(font)
self.label_20.setObjectName(_fromUtf8("label_20"))
self.Button_LoadOutFileCandidateFromWWW = QtGui.QPushButton(self.centralwidget)
self.Button_LoadOutFileCandidateFromWWW.setGeometry(QtCore.QRect(540, 10, 121, 31))
icon1 = QtGui.QIcon()
icon1.addPixmap(QtGui.QPixmap(_fromUtf8("C:/Users/rafal/.designer/backup/Image/Rysunek.svg-path3008-154.png")), QtGui.QIcon.Normal, QtGui.QIcon.Off)
self.Button_LoadOutFileCandidateFromWWW.setIcon(icon1)
self.Button_LoadOutFileCandidateFromWWW.setIconSize(QtCore.QSize(25, 25))
self.Button_LoadOutFileCandidateFromWWW.setObjectName(_fromUtf8("Button_LoadOutFileCandidateFromWWW"))
self.comboBox_MethodList = QtGui.QComboBox(self.centralwidget)
self.comboBox_MethodList.setGeometry(QtCore.QRect(410, 126, 69, 22))
self.comboBox_MethodList.setObjectName(_fromUtf8("comboBox_MethodList"))
self.comboBox_MethodList.addItem(_fromUtf8(""))
self.comboBox_MethodList.addItem(_fromUtf8(""))
self.listWidget_errorList = QtGui.QListWidget(self.centralwidget)
self.listWidget_errorList.setEnabled(False)
self.listWidget_errorList.setGeometry(QtCore.QRect(10, 550, 781, 41))
self.listWidget_errorList.setObjectName(_fromUtf8("listWidget_errorList"))
self.Button_RemoveOutFile = QtGui.QPushButton(self.centralwidget)
self.Button_RemoveOutFile.setGeometry(QtCore.QRect(680, 10, 111, 31))
icon2 = QtGui.QIcon()
icon2.addPixmap(QtGui.QPixmap(_fromUtf8("C:/Users/rafal/.designer/backup/Image/Rysunek.svg-path3297-4294966531.png")), QtGui.QIcon.Normal, QtGui.QIcon.Off)
self.Button_RemoveOutFile.setIcon(icon2)
self.Button_RemoveOutFile.setIconSize(QtCore.QSize(25, 25))
self.Button_RemoveOutFile.setObjectName(_fromUtf8("Button_RemoveOutFile"))
self.Button_LoadConfigPath = QtGui.QPushButton(self.centralwidget)
self.Button_LoadConfigPath.setGeometry(QtCore.QRect(220, 10, 111, 31))
self.Button_LoadConfigPath.setObjectName(_fromUtf8("Button_LoadConfigPath"))
self.groupBox = QtGui.QGroupBox(self.centralwidget)
self.groupBox.setGeometry(QtCore.QRect(10, 40, 381, 111))
palette = QtGui.QPalette()
brush = QtGui.QBrush(QtGui.QColor(240, 255, 254))
brush.setStyle(QtCore.Qt.SolidPattern)
palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Base, brush)
brush = QtGui.QBrush(QtGui.QColor(222, 227, 230))
brush.setStyle(QtCore.Qt.SolidPattern)
palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Window, brush)
brush = QtGui.QBrush(QtGui.QColor(240, 255, 254))
brush.setStyle(QtCore.Qt.SolidPattern)
palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Base, brush)
brush = QtGui.QBrush(QtGui.QColor(222, 227, 230))
brush.setStyle(QtCore.Qt.SolidPattern)
palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Window, brush)
brush = QtGui.QBrush(QtGui.QColor(222, 227, 230))
brush.setStyle(QtCore.Qt.SolidPattern)
palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Base, brush)
brush = QtGui.QBrush(QtGui.QColor(222, 227, 230))
brush.setStyle(QtCore.Qt.SolidPattern)
palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Window, brush)
self.groupBox.setPalette(palette)
self.groupBox.setObjectName(_fromUtf8("groupBox"))
self.label_15 = QtGui.QLabel(self.groupBox)
self.label_15.setGeometry(QtCore.QRect(50, 10, 211, 41))
font = QtGui.QFont()
font.setFamily(_fromUtf8("Tahoma"))
font.setPointSize(10)
font.setBold(False)
font.setWeight(50)
self.label_15.setFont(font)
self.label_15.setObjectName(_fromUtf8("label_15"))
self.label_numberOfSentences = QtGui.QLabel(self.groupBox)
self.label_numberOfSentences.setGeometry(QtCore.QRect(240, 10, 111, 41))
self.label_numberOfSentences.setText(_fromUtf8(""))
self.label_numberOfSentences.setObjectName(_fromUtf8("label_numberOfSentences"))
self.label_repeatSentencesProcent = QtGui.QLabel(self.groupBox)
self.label_repeatSentencesProcent.setGeometry(QtCore.QRect(240, 80, 111, 21))
self.label_repeatSentencesProcent.setText(_fromUtf8(""))
self.label_repeatSentencesProcent.setObjectName(_fromUtf8("label_repeatSentencesProcent"))
self.label_numberOfRepeatSentences = QtGui.QLabel(self.groupBox)
self.label_numberOfRepeatSentences.setGeometry(QtCore.QRect(240, 50, 111, 21))
self.label_numberOfRepeatSentences.setText(_fromUtf8(""))
self.label_numberOfRepeatSentences.setObjectName(_fromUtf8("label_numberOfRepeatSentences"))
self.label_17 = QtGui.QLabel(self.groupBox)
self.label_17.setGeometry(QtCore.QRect(50, 40, 181, 41))
font = QtGui.QFont()
font.setFamily(_fromUtf8("Tahoma"))
font.setPointSize(10)
font.setBold(False)
font.setWeight(50)
self.label_17.setFont(font)
self.label_17.setObjectName(_fromUtf8("label_17"))
self.label_16 = QtGui.QLabel(self.groupBox)
self.label_16.setGeometry(QtCore.QRect(50, 70, 201, 41))
font = QtGui.QFont()
font.setFamily(_fromUtf8("Tahoma"))
font.setPointSize(10)
font.setBold(False)
font.setWeight(50)
self.label_16.setFont(font)
self.label_16.setObjectName(_fromUtf8("label_16"))
self.Button_Przelicz = QtGui.QPushButton(self.centralwidget)
self.Button_Przelicz.setGeometry(QtCore.QRect(690, 120, 91, 31))
self.Button_Przelicz.setIcon(icon2)
self.Button_Przelicz.setIconSize(QtCore.QSize(25, 25))
self.Button_Przelicz.setObjectName(_fromUtf8("Button_Przelicz"))
self.lineEdit_wwwPath = QtGui.QLineEdit(self.centralwidget)
self.lineEdit_wwwPath.setGeometry(QtCore.QRect(410, 380, 211, 31))
self.lineEdit_wwwPath.setObjectName(_fromUtf8("lineEdit_wwwPath"))
self.Button_AddWWW = QtGui.QPushButton(self.centralwidget)
self.Button_AddWWW.setGeometry(QtCore.QRect(630, 380, 91, 31))
self.Button_AddWWW.setIcon(icon2)
self.Button_AddWWW.setIconSize(QtCore.QSize(25, 25))
self.Button_AddWWW.setObjectName(_fromUtf8("Button_AddWWW"))
self.listWidget_wwwFromMainFile = QtGui.QListWidget(self.centralwidget)
self.listWidget_wwwFromMainFile.setGeometry(QtCore.QRect(410, 90, 311, 291))
self.listWidget_wwwFromMainFile.setObjectName(_fromUtf8("listWidget_wwwFromMainFile"))
self.Button_CloseAddWWW = QtGui.QPushButton(self.centralwidget)
self.Button_CloseAddWWW.setGeometry(QtCore.QRect(630, 410, 91, 31))
self.Button_CloseAddWWW.setIcon(icon2)
self.Button_CloseAddWWW.setIconSize(QtCore.QSize(25, 25))
self.Button_CloseAddWWW.setObjectName(_fromUtf8("Button_CloseAddWWW"))
MainWindow.setCentralWidget(self.centralwidget)
self.menubar = QtGui.QMenuBar(MainWindow)
self.menubar.setGeometry(QtCore.QRect(0, 0, 800, 21))
self.menubar.setObjectName(_fromUtf8("menubar"))
self.menuFile = QtGui.QMenu(self.menubar)
self.menuFile.setObjectName(_fromUtf8("menuFile"))
self.menuResources = QtGui.QMenu(self.menubar)
self.menuResources.setObjectName(_fromUtf8("menuResources"))
self.menuO_programie = QtGui.QMenu(self.menubar)
self.menuO_programie.setObjectName(_fromUtf8("menuO_programie"))
MainWindow.setMenuBar(self.menubar)
self.statusBar = QtGui.QStatusBar(MainWindow)
self.statusBar.setObjectName(_fromUtf8("statusBar"))
MainWindow.setStatusBar(self.statusBar)
self.actionQuit = QtGui.QAction(MainWindow)
self.actionQuit.setObjectName(_fromUtf8("actionQuit"))
self.actionDodaj_plik = QtGui.QAction(MainWindow)
self.actionDodaj_plik.setObjectName(_fromUtf8("actionDodaj_plik"))
self.actionDodaj_WWW = QtGui.QAction(MainWindow)
self.actionDodaj_WWW.setObjectName(_fromUtf8("actionDodaj_WWW"))
self.actionUsu_plik = QtGui.QAction(MainWindow)
self.actionUsu_plik.setObjectName(_fromUtf8("actionUsu_plik"))
self.actionNowy_projekt = QtGui.QAction(MainWindow)
self.actionNowy_projekt.setObjectName(_fromUtf8("actionNowy_projekt"))
self.actionOtw_rz_projekt = QtGui.QAction(MainWindow)
self.actionOtw_rz_projekt.setObjectName(_fromUtf8("actionOtw_rz_projekt"))
self.actionDokumentacja = QtGui.QAction(MainWindow)
self.actionDokumentacja.setObjectName(_fromUtf8("actionDokumentacja"))
self.menuFile.addAction(self.actionNowy_projekt)
self.menuFile.addAction(self.actionOtw_rz_projekt)
self.menuFile.addSeparator()
self.menuFile.addAction(self.actionQuit)
self.menuResources.addAction(self.actionDodaj_plik)
self.menuResources.addAction(self.actionDodaj_WWW)
self.menuResources.addAction(self.actionUsu_plik)
self.menuO_programie.addAction(self.actionDokumentacja)
self.menubar.addAction(self.menuFile.menuAction())
self.menubar.addAction(self.menuResources.menuAction())
self.menubar.addAction(self.menuO_programie.menuAction())
self.retranslateUi(MainWindow)
QtCore.QObject.connect(self.actionQuit, QtCore.SIGNAL(_fromUtf8("triggered()")), MainWindow.close)
QtCore.QMetaObject.connectSlotsByName(MainWindow)
def retranslateUi(self, MainWindow):
MainWindow.setWindowTitle(_translate("MainWindow", "MainWindow", None))
self.Button_LoadOutFile.setText(_translate("MainWindow", "Dodaj plik", None))
self.Button_LoadMainFilePath.setText(_translate("MainWindow", "Nowy projekt", None))
self.label_numberOfThreshold.setText(_translate("MainWindow", "0", None))
self.label_20.setText(_translate("MainWindow", "Współczynnik odrzucenia", None))
self.Button_LoadOutFileCandidateFromWWW.setText(_translate("MainWindow", "Dodaj WWW", None))
self.comboBox_MethodList.setItemText(0, _translate("MainWindow", "I metoda", None))
self.comboBox_MethodList.setItemText(1, _translate("MainWindow", "II metoda", None))
self.Button_RemoveOutFile.setText(_translate("MainWindow", "Usuń plik", None))
self.Button_LoadConfigPath.setText(_translate("MainWindow", "Otwórz projekt", None))
self.groupBox.setTitle(_translate("MainWindow", "Statystyka", None))
self.label_15.setText(_translate("MainWindow", "Ilość zdań w pliku głównym:", None))
self.label_17.setText(_translate("MainWindow", "Współczynnik plagiatu:", None))
self.label_16.setText(_translate("MainWindow", "Ilość zdań powtórzonych:", None))
self.Button_Przelicz.setText(_translate("MainWindow", "Przelicz", None))
self.Button_AddWWW.setText(_translate("MainWindow", "Dodaj", None))
self.Button_CloseAddWWW.setText(_translate("MainWindow", "Zamknij", None))
self.menuFile.setTitle(_translate("MainWindow", "Projekt", None))
self.menuResources.setTitle(_translate("MainWindow", "Zasoby", None))
self.menuO_programie.setTitle(_translate("MainWindow", "O programie", None))
self.actionQuit.setText(_translate("MainWindow", "Quit", None))
self.actionDodaj_plik.setText(_translate("MainWindow", "Dodaj plik", None))
self.actionDodaj_WWW.setText(_translate("MainWindow", "Dodaj WWW", None))
self.actionUsu_plik.setText(_translate("MainWindow", "Usuń plik", None))
self.actionNowy_projekt.setText(_translate("MainWindow", "Nowy projekt", None))
self.actionOtw_rz_projekt.setText(_translate("MainWindow", "Otwórz projekt", None))
self.actionDokumentacja.setText(_translate("MainWindow", "Pomoc", None))