from
PySide2.QtCore
import
*
from
PySide2.QtGui
import
*
from
PySide2.QtWidgets
import
*
import
qtawesome
class
d2xUI(
object
):
def
setupUi(
self
, MainWindow):
MainWindow.setObjectName(
"MainWindow"
)
MainWindow.resize(
540
,
630
)
sizePolicy
=
QSizePolicy(QSizePolicy.Expanding, QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(
0
)
sizePolicy.setVerticalStretch(
0
)
sizePolicy.setHeightForWidth(MainWindow.sizePolicy().hasHeightForWidth())
MainWindow.setSizePolicy(sizePolicy)
icon
=
QIcon()
icon.addFile(u
"Trans.ico"
, QSize(), QIcon.Normal, QIcon.Off)
MainWindow.setWindowIcon(icon)
self
.centralwidget
=
QWidget(MainWindow)
self
.centralwidget.setObjectName(u
"centralwidget"
)
self
.pushButton
=
QPushButton(
self
.centralwidget)
self
.pushButton.setObjectName(u
"pushButton"
)
self
.pushButton.setGeometry(QRect(
400
,
320
,
100
,
40
))
self
.pushButton_2
=
QPushButton(
self
.centralwidget)
self
.pushButton_2.setObjectName(u
"pushButton_2"
)
self
.pushButton_2.setGeometry(QRect(
400
,
370
,
100
,
40
))
self
.pushButton_2.setEnabled(
False
)
self
.pushButton_5
=
QPushButton(
self
.centralwidget)
self
.pushButton_5.setObjectName(u
"pushButton_2"
)
self
.pushButton_5.setGeometry(QRect(
400
,
420
,
100
,
40
))
self
.pushButton_5.setEnabled(
False
)
self
.pushButton_6
=
QPushButton(
self
.centralwidget)
self
.pushButton_6.setObjectName(u
"pushButton_2"
)
self
.pushButton_6.setGeometry(QRect(
400
,
470
,
100
,
40
))
self
.pushButton_6.setEnabled(
False
)
self
.progressBar
=
QProgressBar(
self
.centralwidget)
self
.progressBar.setObjectName(u
"progressBar"
)
self
.progressBar.setGeometry(QRect(
40
,
550
,
470
,
30
))
self
.progressBar.setStyleSheet(u
"\n"
"QProgressBar::chunk\n"
"{\n"
"border-radius:15px;\n"
"background:qlineargradient(spread:pad,x1:0,y1:0,x2:1,y2:0,stop:0 #70649A,stop:1 #26B4FF);\n"
"border-radius:4px;/*\u6591\u9a6c\u7ebf \u5706\u89d2*/\n"
"border:1px solid black;\n"
"background-color:skyblue;\n"
"width:6px;margin:0.5px;/*\u5bbd\u5ea6\u548c\u5916\u8fb9\u8ddd*/\n"
" \n"
"}\n"
"QProgressBar#progressBar\n"
"{\n"
"height:20px;\n"
"text-align:center;\n"
"font-size:14px;\n"
"color:white;\n"
"border-radius:11px;\n"
"background: #0f1423 ;\n"
"}"
)
self
.progressBar.setValue(
0
)
self
.groupBox
=
QGroupBox(
self
.centralwidget)
self
.groupBox.setObjectName(u
"groupBox"
)
self
.groupBox.setGeometry(QRect(
40
,
20
,
470
,
100
))
self
.buttonGroup
=
QButtonGroup(MainWindow)
self
.buttonGroup.setObjectName(u
"buttonGroup"
)
self
.radioButton
=
QRadioButton(
self
.groupBox)
self
.radioButton.setChecked(
True
)
self
.radioButton.setObjectName(u
"radioButton"
)
self
.radioButton.setGeometry(QRect(
50
,
30
,
185
,
50
))
self
.radioButton_2
=
QRadioButton(
self
.groupBox)
self
.radioButton_2.setObjectName(u
"radioButton_2"
)
self
.radioButton_2.setGeometry(QRect(
235
,
30
,
185
,
50
))
self
.buttonGroup.addButton(
self
.radioButton)
self
.buttonGroup.addButton(
self
.radioButton_2)
self
.groupBox_2
=
QGroupBox(
self
.centralwidget)
self
.groupBox_2.setObjectName(u
"groupBox_2"
)
self
.groupBox_2.setGeometry(QRect(
40
,
140
,
470
,
150
))
self
.comboBox
=
QComboBox(
self
.groupBox_2)
self
.comboBox.setObjectName(u
"comboBox"
)
self
.comboBox.setGeometry(QRect(
20
,
30
,
350
,
40
))
self
.comboBox_2
=
QComboBox(
self
.groupBox_2)
self
.comboBox_2.setObjectName(u
"comboBox_2"
)
self
.comboBox_2.setGeometry(QRect(
20
,
90
,
350
,
40
))
self
.pushButton_3
=
QPushButton(
self
.groupBox_2)
self
.pushButton_3.setObjectName(u
"pushButton"
)
self
.pushButton_3.setGeometry(QRect(
380
,
30
,
70
,
40
))
self
.pushButton_4
=
QPushButton(
self
.groupBox_2)
self
.pushButton_4.setObjectName(u
"pushButton"
)
self
.pushButton_4.setGeometry(QRect(
380
,
90
,
70
,
40
))
self
.groupBox_3
=
QGroupBox(
self
.centralwidget)
self
.groupBox_3.setObjectName(u
"groupBox_3"
)
self
.groupBox_3.setGeometry(QRect(
40
,
310
,
300
,
210
))
self
.checkBox
=
QCheckBox(
self
.groupBox_3)
self
.checkBox.setObjectName(u
"checkBox"
)
self
.checkBox.setGeometry(QRect(
30
,
30
,
250
,
40
))
self
.checkBox_2
=
QCheckBox(
self
.groupBox_3)
self
.checkBox_2.setObjectName(u
"checkBox_2"
)
self
.checkBox_2.setGeometry(QRect(
30
,
60
,
250
,
40
))
self
.checkBox_3
=
QCheckBox(
self
.groupBox_3)
self
.checkBox_3.setChecked(
True
)
self
.checkBox_3.setObjectName(u
"checkBox_3"
)
self
.checkBox_3.setGeometry(QRect(
30
,
90
,
250
,
40
))
self
.checkBox_4
=
QCheckBox(
self
.groupBox_3)
self
.checkBox_4.setChecked(
True
)
self
.checkBox_4.setObjectName(u
"checkBox_3"
)
self
.checkBox_4.setGeometry(QRect(
30
,
120
,
250
,
40
))
self
.checkBox_5
=
QCheckBox(
self
.groupBox_3)
self
.checkBox_5.setObjectName(u
"checkBox_3"
)
self
.checkBox_5.setGeometry(QRect(
30
,
150
,
250
,
40
))
MainWindow.setCentralWidget(
self
.centralwidget)
self
.statusbar
=
QStatusBar(MainWindow)
self
.statusbar.setObjectName(u
"statusbar"
)
MainWindow.setStatusBar(
self
.statusbar)
self
.retranslateUi(MainWindow)
QMetaObject.connectSlotsByName(MainWindow)
def
retranslateUi(
self
, MainWindow):
MainWindow.setWindowTitle(QCoreApplication.translate(
"MainWindow"
, u
"Doc2Xlsx"
,
None
))
self
.pushButton_2.setText(QCoreApplication.translate(
"MainWindow"
, u
"开始运行"
,
None
))
self
.groupBox.setTitle(QCoreApplication.translate(
"MainWindow"
, u
"操作"
,
None
))
self
.radioButton.setText(QCoreApplication.translate(
"MainWindow"
, u
"汇总"
,
None
))
self
.radioButton_2.setText(QCoreApplication.translate(
"MainWindow"
, u
"分类"
,
None
))
self
.pushButton.setText(QCoreApplication.translate(
"MainWindow"
, u
"相关说明"
,
None
))
self
.groupBox_3.setTitle(QCoreApplication.translate(
"MainWindow"
, u
"其他"
,
None
))
self
.checkBox.setText(QCoreApplication.translate(
"MainWindow"
, u
"首列添加序号"
,
None
))
self
.checkBox_2.setText(QCoreApplication.translate(
"MainWindow"
, u
"数字前添加单引号"
,
None
))
self
.checkBox_3.setText(QCoreApplication.translate(
"MainWindow"
, u
"保存结果文件"
,
None
))
self
.checkBox_4.setText(QCoreApplication.translate(
"MainWindow"
, u
"Excel后台运行"
,
None
))
self
.checkBox_5.setText(QCoreApplication.translate(
"MainWindow"
, u
"对日期格式化"
,
None
))
self
.groupBox_2.setTitle(QCoreApplication.translate(
"MainWindow"
, u
"路径"
,
None
))
self
.pushButton_3.setText(QCoreApplication.translate(
"MainWindow"
, u
"文件"
,
None
))
self
.pushButton_4.setText(QCoreApplication.translate(
"MainWindow"
, u
"模板"
,
None
))
self
.pushButton_5.setText(QCoreApplication.translate(
"MainWindow"
, u
"打开结果"
,
None
))
self
.pushButton_6.setText(QCoreApplication.translate(
"MainWindow"
, u
"出错列表"
,
None
))