-
Notifications
You must be signed in to change notification settings - Fork 0
/
window.py
114 lines (105 loc) · 5.63 KB
/
window.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
# -*- coding: utf-8 -*-
# Form implementation generated from reading ui file 'window.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(1080, 766)
self.centralwidget = QtWidgets.QWidget(MainWindow)
self.centralwidget.setObjectName("centralwidget")
self.label = QtWidgets.QLabel(self.centralwidget)
self.label.setGeometry(QtCore.QRect(100, 100, 378, 565))
self.label.setStyleSheet("background-image: url(:/images/images/毕业晚会海报.jpg);\n"
"border-top-left-radius: 30px;\n"
"border-bottom-left-radius: 30px;")
self.label.setText("")
self.label.setObjectName("label")
self.label_2 = QtWidgets.QLabel(self.centralwidget)
self.label_2.setGeometry(QtCore.QRect(480, 100, 421, 565))
self.label_2.setStyleSheet("background-color: rgb(255, 255, 255);\n"
"border-top-right-radius: 30px;\n"
"border-bottom-right-radius: 30px;")
self.label_2.setText("")
self.label_2.setObjectName("label_2")
self.label_3 = QtWidgets.QLabel(self.centralwidget)
self.label_3.setGeometry(QtCore.QRect(540, 230, 300, 200))
font = QtGui.QFont()
font.setFamily("阿里妈妈数黑体")
font.setPointSize(24)
font.setBold(True)
font.setWeight(75)
font.setKerning(False)
self.label_3.setFont(font)
self.label_3.setMouseTracking(False)
self.label_3.setAlignment(QtCore.Qt.AlignCenter)
self.label_3.setObjectName("label_3")
self.widget = QtWidgets.QWidget(self.centralwidget)
self.widget.setEnabled(True)
self.widget.setGeometry(QtCore.QRect(480, 430, 421, 131))
font = QtGui.QFont()
font.setPointSize(15)
self.widget.setFont(font)
self.widget.setStyleSheet("border:none")
self.widget.setObjectName("widget")
self.StartButton = QtWidgets.QPushButton(self.widget)
self.StartButton.setEnabled(True)
self.StartButton.setGeometry(QtCore.QRect(50, 30, 141, 60))
self.StartButton.setStyleSheet("#StartButton {\n"
" background-color: rgb(0, 0, 0);\n"
" color: rgb(255, 255, 255);\n"
" border:2px solid rgb(0,0,0);\n"
" border-radius:8px;\n"
"}\n"
"#StartButton:hover {\n"
" color: rgb(0,0,0);\n"
" background-color: rgb(255, 255, 255);\n"
"}\n"
"#StartButton:pressed {\n"
" padding-top:5px;\n"
" padding-left:5px;\n"
"}")
self.StartButton.setIconSize(QtCore.QSize(20, 20))
self.StartButton.setObjectName("StartButton")
self.PauseButton = QtWidgets.QPushButton(self.widget)
self.PauseButton.setEnabled(True)
self.PauseButton.setGeometry(QtCore.QRect(230, 30, 141, 60))
self.PauseButton.setStyleSheet("#PauseButton {\n"
" background-color: rgb(0, 0, 0);\n"
" color: rgb(255, 255, 255);\n"
" border:2px solid rgb(0,0,0);\n"
" border-radius:8px;\n"
"}\n"
"#PauseButton:hover {\n"
" color: rgb(0,0,0);\n"
" background-color: rgb(255, 255, 255);\n"
"}\n"
"#PauseButton:pressed {\n"
" padding-top:5px;\n"
" padding-left:5px;\n"
"}")
self.PauseButton.setIconSize(QtCore.QSize(20, 20))
self.PauseButton.setObjectName("PauseButton")
self.CloseButton = QtWidgets.QPushButton(self.centralwidget)
self.CloseButton.setGeometry(QtCore.QRect(850, 110, 41, 41))
self.CloseButton.setStyleSheet("border:0px")
self.CloseButton.setText("")
icon = QtGui.QIcon()
icon.addPixmap(QtGui.QPixmap(":/images/images/Close.svg"), QtGui.QIcon.Normal, QtGui.QIcon.Off)
self.CloseButton.setIcon(icon)
self.CloseButton.setObjectName("CloseButton")
MainWindow.setCentralWidget(self.centralwidget)
self.retranslateUi(MainWindow)
self.CloseButton.clicked.connect(MainWindow.close) # type: ignore
QtCore.QMetaObject.connectSlotsByName(MainWindow)
def retranslateUi(self, MainWindow):
_translate = QtCore.QCoreApplication.translate
MainWindow.setWindowTitle(_translate("MainWindow", "MainWindow"))
self.label_3.setText(_translate("MainWindow", "TextLabel"))
self.StartButton.setText(_translate("MainWindow", "开始抽奖"))
self.PauseButton.setText(_translate("MainWindow", "停止抽奖"))
import src_rc