Skip to content

Commit 298f97d

Browse files
committed
整理美化部分目录
1 parent 9f39570 commit 298f97d

File tree

110 files changed

+1459
-1514
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

110 files changed

+1459
-1514
lines changed

.settings/org.eclipse.core.resources.prefs

+1-25
Original file line numberDiff line numberDiff line change
@@ -65,37 +65,13 @@ encoding//\u591A\u9875\u9762/QScrollArea/\u4EFFQQ\u8BBE\u7F6E\u9762\u677F/\u4EFF
6565
encoding//\u591A\u9875\u9762/QStackedWidget/\u5DE6\u4FA7\u9009\u9879\u5361/\u5DE6\u4FA7\u9009\u9879\u5361.py=utf-8
6666
encoding//\u6811\u7ED3\u6784/QTreeWidget/Json\u751F\u6210QTreeWidget/Json\u751F\u6210\u6811\u5F62\u7ED3\u6784.py=utf-8
6767
encoding//\u6D4F\u89C8\u5668/QWebView/\u68A6\u5E7B\u6811/DreamTree.py=utf-8
68-
encoding//\u754C\u9762\u7F8E\u5316/QFileSystemModel\u56FE\u6807/FileSystemModel.py=utf-8
69-
encoding//\u754C\u9762\u7F8E\u5316/QLabel\u5706\u5F62\u5934\u50CF/CircleLabel.py=utf-8
70-
encoding//\u754C\u9762\u7F8E\u5316/QMessageBox\u6837\u5F0F/\u65B9\u6848\u4E00/critical.py=utf-8
71-
encoding//\u754C\u9762\u7F8E\u5316/QMessageBox\u6837\u5F0F/\u65B9\u6848\u4E00/information.py=utf-8
72-
encoding//\u754C\u9762\u7F8E\u5316/QMessageBox\u6837\u5F0F/\u65B9\u6848\u4E00/question.py=utf-8
73-
encoding//\u754C\u9762\u7F8E\u5316/QMessageBox\u6837\u5F0F/\u65B9\u6848\u4E00/warning.py=utf-8
74-
encoding//\u754C\u9762\u7F8E\u5316/QMessageBox\u6837\u5F0F/\u65B9\u6848\u4E8C/critical.py=utf-8
75-
encoding//\u754C\u9762\u7F8E\u5316/QMessageBox\u6837\u5F0F/\u65B9\u6848\u4E8C/information.py=utf-8
76-
encoding//\u754C\u9762\u7F8E\u5316/QMessageBox\u6837\u5F0F/\u65B9\u6848\u4E8C/question.py=utf-8
77-
encoding//\u754C\u9762\u7F8E\u5316/QMessageBox\u6837\u5F0F/\u65B9\u6848\u4E8C/warning.py=utf-8
78-
encoding//\u754C\u9762\u7F8E\u5316/QPushButton\u8FDB\u5EA6\u52A8\u753B/PushButtonFont.py=utf-8
79-
encoding//\u754C\u9762\u7F8E\u5316/QPushButton\u8FDB\u5EA6\u52A8\u753B/PushButtonLine.py=utf-8
80-
encoding//\u754C\u9762\u7F8E\u5316/QSS\u7F8E\u5316\u4F8B\u5B50/QProgressBar\u8FDB\u5EA6\u6761\u6837\u5F0F/ProgressBar.py=utf-8
81-
encoding//\u754C\u9762\u7F8E\u5316/QSS\u7F8E\u5316\u4F8B\u5B50/QPushButton\u6309\u94AE/ButtonHover.py=utf-8
82-
encoding//\u754C\u9762\u7F8E\u5316/QScrollBar\u6EDA\u52A8\u6761\u6837\u5F0F/ScrollBar.py=utf-8
83-
encoding//\u754C\u9762\u7F8E\u5316/QSlider\u7F8E\u5316/PaintQSlider.py=utf-8
84-
encoding//\u754C\u9762\u7F8E\u5316/QSlider\u7F8E\u5316/QssQSlider.py=utf-8
85-
encoding//\u754C\u9762\u7F8E\u5316/\u5404\u7C7B\u8FDB\u5EA6\u6761/CircleProgressBar.py=utf-8
86-
encoding//\u754C\u9762\u7F8E\u5316/\u5404\u7C7B\u8FDB\u5EA6\u6761/MetroCircleProgress.py=utf-8
87-
encoding//\u754C\u9762\u7F8E\u5316/\u5404\u7C7B\u8FDB\u5EA6\u6761/MetroLineProgress.py=utf-8
88-
encoding//\u754C\u9762\u7F8E\u5316/\u5404\u7C7B\u8FDB\u5EA6\u6761/PercentProgressBar.py=utf-8
89-
encoding//\u754C\u9762\u7F8E\u5316/\u6C34\u6CE2\u7EB9\u8FDB\u5EA6\u6761/ProgressBar.py=utf-8
90-
encoding//\u754C\u9762\u7F8E\u5316/\u6C34\u6CE2\u7EB9\u8FDB\u5EA6\u6761/TestWidget.py=utf-8
91-
encoding//\u754C\u9762\u7F8E\u5316/\u8FB9\u6846\u52A8\u753B\u9634\u5F71/AnimationShadowEffect.py=utf-8
92-
encoding//\u754C\u9762\u7F8E\u5316/\u8FB9\u6846\u52A8\u753B\u9634\u5F71/Test.py=utf-8
9368
encoding//\u7A97\u53E3/\u5206\u5272\u7A97\u53E3\u7684\u5206\u5272\u6761\u91CD\u5199.py=utf-8
9469
encoding//\u7A97\u53E3/\u65E0\u8FB9\u6846\u81EA\u5B9A\u4E49\u6807\u9898\u680F\u7A97\u53E3/FramelessWindow.py=utf-8
9570
encoding//\u7A97\u53E3/\u65E0\u8FB9\u6846\u81EA\u5B9A\u4E49\u6807\u9898\u680F\u7A97\u53E3/win\u65E0\u8FB9\u6846\u8C03\u6574\u5927\u5C0F.py=utf-8
9671
encoding//\u7A97\u53E3/\u65E0\u8FB9\u6846\u81EA\u5B9A\u4E49\u6807\u9898\u680F\u7A97\u53E3/\u65E0\u8FB9\u6846\u81EA\u5B9A\u4E49\u6807\u9898\u680F\u7A97\u53E3.py=utf-8
9772
encoding//\u7A97\u53E3/\u6D88\u606F\u5BF9\u8BDD\u6846\u5012\u8BA1\u65F6\u5173\u95ED.py=utf-8
9873
encoding//\u7A97\u53E3/\u7A97\u53E3\u91CD\u542F.py=utf-8
74+
encoding//\u7F8E\u5316/QLabel/\u5706\u5F62\u56FE\u7247.py=utf-8
9975
encoding//\u7F8E\u5316/\u81EA\u5B9A\u4E49QWidget\u7684QSS\u6837\u5F0F/CustomPaintWidget.py=utf-8
10076
encoding//\u7F8E\u5316/\u81EA\u5B9A\u4E49QWidget\u7684QSS\u6837\u5F0F/CustomWidget.py=utf-8
10177
encoding//\u7F8E\u5316/\u81EA\u5B9A\u4E49QWidget\u7684QSS\u6837\u5F0F/test.py=utf-8

界面美化/QLabel圆形头像/README.md

-10
This file was deleted.

界面美化/QPushButton进度动画/README.md

-10
This file was deleted.

界面美化/QSS美化例子/QPushButton按钮/README.md

-8
This file was deleted.

界面美化/QSS美化例子/README.md

-10
This file was deleted.

界面美化/README.md

-24
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -1,117 +1,117 @@
1-
'''
2-
Created on 2018年1月30日
3-
@author: Irony."[讽刺]
4-
@site: http://alyl.vip, http://orzorz.vip, https://coding.net/u/892768447, https://github.com/892768447
5-
@email: 892768447@qq.com
6-
@file: CalendarWidget
7-
@description: 日历
8-
'''
9-
import sys
10-
11-
from PyQt5.QtWidgets import QApplication, QCalendarWidget
12-
13-
14-
StyleSheet = '''
15-
/*顶部导航区域*/
16-
#qt_calendar_navigationbar {
17-
background-color: rgb(0, 188, 212);
18-
min-height: 100px;
19-
}
20-
21-
22-
/*上一个月按钮和下一个月按钮(从源码里找到的objectName)*/
23-
#qt_calendar_prevmonth, #qt_calendar_nextmonth {
24-
border: none; /*去掉边框*/
25-
margin-top: 64px;
26-
color: white;
27-
min-width: 36px;
28-
max-width: 36px;
29-
min-height: 36px;
30-
max-height: 36px;
31-
border-radius: 18px; /*看来近似椭圆*/
32-
font-weight: bold; /*字体加粗*/
33-
qproperty-icon: none; /*去掉默认的方向键图片,当然也可以自定义*/
34-
background-color: transparent;/*背景颜色透明*/
35-
}
36-
#qt_calendar_prevmonth {
37-
qproperty-text: "<"; /*修改按钮的文字*/
38-
}
39-
#qt_calendar_nextmonth {
40-
qproperty-text: ">";
41-
}
42-
#qt_calendar_prevmonth:hover, #qt_calendar_nextmonth:hover {
43-
background-color: rgba(225, 225, 225, 100);
44-
}
45-
#qt_calendar_prevmonth:pressed, #qt_calendar_nextmonth:pressed {
46-
background-color: rgba(235, 235, 235, 100);
47-
}
48-
49-
50-
/*年,月控件*/
51-
#qt_calendar_yearbutton, #qt_calendar_monthbutton {
52-
color: white;
53-
margin: 18px;
54-
min-width: 60px;
55-
border-radius: 30px;
56-
}
57-
#qt_calendar_yearbutton:hover, #qt_calendar_monthbutton:hover {
58-
background-color: rgba(225, 225, 225, 100);
59-
}
60-
#qt_calendar_yearbutton:pressed, #qt_calendar_monthbutton:pressed {
61-
background-color: rgba(235, 235, 235, 100);
62-
}
63-
64-
65-
/*年份输入框*/
66-
#qt_calendar_yearedit {
67-
min-width: 50px;
68-
color: white;
69-
background: transparent;/*让输入框背景透明*/
70-
}
71-
#qt_calendar_yearedit::up-button { /*往上的按钮*/
72-
width: 20px;
73-
subcontrol-position: right;/*移动到右边*/
74-
}
75-
#qt_calendar_yearedit::down-button { /*往下的按钮*/
76-
width: 20px;
77-
subcontrol-position: left; /*移动到左边去*/
78-
}
79-
80-
81-
/*月份选择菜单*/
82-
CalendarWidget QToolButton QMenu {
83-
background-color: white;
84-
}
85-
CalendarWidget QToolButton QMenu::item {
86-
padding: 10px;
87-
}
88-
CalendarWidget QToolButton QMenu::item:selected:enabled {
89-
background-color: rgb(230, 230, 230);
90-
}
91-
CalendarWidget QToolButton::menu-indicator {
92-
/*image: none;去掉月份选择下面的小箭头*/
93-
subcontrol-position: right center;/*右边居中*/
94-
}
95-
96-
97-
/*下方的日历表格*/
98-
#qt_calendar_calendarview {
99-
outline: 0px;/*去掉选中后的虚线框*/
100-
selection-background-color: rgb(0, 188, 212); /*选中背景颜色*/
101-
}
102-
'''
103-
104-
105-
class CalendarWidget(QCalendarWidget):
106-
107-
def __init__(self, *args, **kwargs):
108-
super(CalendarWidget, self).__init__(*args, **kwargs)
109-
# 隐藏左边的序号
110-
self.setVerticalHeaderFormat(self.NoVerticalHeader)
111-
112-
if __name__ == "__main__":
113-
app = QApplication(sys.argv)
114-
app.setStyleSheet(StyleSheet)
115-
w = CalendarWidget()
116-
w.show()
117-
sys.exit(app.exec_())
1+
'''
2+
Created on 2018年1月30日
3+
@author: Irony."[讽刺]
4+
@site: http://alyl.vip, http://orzorz.vip, https://coding.net/u/892768447, https://github.com/892768447
5+
@email: 892768447@qq.com
6+
@file: CalendarWidget
7+
@description: 日历
8+
'''
9+
import sys
10+
11+
from PyQt5.QtWidgets import QApplication, QCalendarWidget
12+
13+
14+
StyleSheet = '''
15+
/*顶部导航区域*/
16+
#qt_calendar_navigationbar {
17+
background-color: rgb(0, 188, 212);
18+
min-height: 100px;
19+
}
20+
21+
22+
/*上一个月按钮和下一个月按钮(从源码里找到的objectName)*/
23+
#qt_calendar_prevmonth, #qt_calendar_nextmonth {
24+
border: none; /*去掉边框*/
25+
margin-top: 64px;
26+
color: white;
27+
min-width: 36px;
28+
max-width: 36px;
29+
min-height: 36px;
30+
max-height: 36px;
31+
border-radius: 18px; /*看来近似椭圆*/
32+
font-weight: bold; /*字体加粗*/
33+
qproperty-icon: none; /*去掉默认的方向键图片,当然也可以自定义*/
34+
background-color: transparent;/*背景颜色透明*/
35+
}
36+
#qt_calendar_prevmonth {
37+
qproperty-text: "<"; /*修改按钮的文字*/
38+
}
39+
#qt_calendar_nextmonth {
40+
qproperty-text: ">";
41+
}
42+
#qt_calendar_prevmonth:hover, #qt_calendar_nextmonth:hover {
43+
background-color: rgba(225, 225, 225, 100);
44+
}
45+
#qt_calendar_prevmonth:pressed, #qt_calendar_nextmonth:pressed {
46+
background-color: rgba(235, 235, 235, 100);
47+
}
48+
49+
50+
/*年,月控件*/
51+
#qt_calendar_yearbutton, #qt_calendar_monthbutton {
52+
color: white;
53+
margin: 18px;
54+
min-width: 60px;
55+
border-radius: 30px;
56+
}
57+
#qt_calendar_yearbutton:hover, #qt_calendar_monthbutton:hover {
58+
background-color: rgba(225, 225, 225, 100);
59+
}
60+
#qt_calendar_yearbutton:pressed, #qt_calendar_monthbutton:pressed {
61+
background-color: rgba(235, 235, 235, 100);
62+
}
63+
64+
65+
/*年份输入框*/
66+
#qt_calendar_yearedit {
67+
min-width: 50px;
68+
color: white;
69+
background: transparent;/*让输入框背景透明*/
70+
}
71+
#qt_calendar_yearedit::up-button { /*往上的按钮*/
72+
width: 20px;
73+
subcontrol-position: right;/*移动到右边*/
74+
}
75+
#qt_calendar_yearedit::down-button { /*往下的按钮*/
76+
width: 20px;
77+
subcontrol-position: left; /*移动到左边去*/
78+
}
79+
80+
81+
/*月份选择菜单*/
82+
CalendarWidget QToolButton QMenu {
83+
background-color: white;
84+
}
85+
CalendarWidget QToolButton QMenu::item {
86+
padding: 10px;
87+
}
88+
CalendarWidget QToolButton QMenu::item:selected:enabled {
89+
background-color: rgb(230, 230, 230);
90+
}
91+
CalendarWidget QToolButton::menu-indicator {
92+
/*image: none;去掉月份选择下面的小箭头*/
93+
subcontrol-position: right center;/*右边居中*/
94+
}
95+
96+
97+
/*下方的日历表格*/
98+
#qt_calendar_calendarview {
99+
outline: 0px;/*去掉选中后的虚线框*/
100+
selection-background-color: rgb(0, 188, 212); /*选中背景颜色*/
101+
}
102+
'''
103+
104+
105+
class CalendarWidget(QCalendarWidget):
106+
107+
def __init__(self, *args, **kwargs):
108+
super(CalendarWidget, self).__init__(*args, **kwargs)
109+
# 隐藏左边的序号
110+
self.setVerticalHeaderFormat(self.NoVerticalHeader)
111+
112+
if __name__ == "__main__":
113+
app = QApplication(sys.argv)
114+
app.setStyleSheet(StyleSheet)
115+
w = CalendarWidget()
116+
w.show()
117+
sys.exit(app.exec_())
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
# QCalendarWidget 日历控件 QSS 美化样式
2-
3-
主要改变顶部背景颜色和高度,上下月按钮、月份选择、年选择、菜单
4-
5-
详细美化都在代码里的QSS中注释了
6-
7-
效果图:
8-
9-
### [CalendarWidget.py](CalendarWidget.py)
1+
# QCalendarWidget 日历控件 QSS 美化样式
2+
3+
主要改变顶部背景颜色和高度,上下月按钮、月份选择、年选择、菜单
4+
5+
详细美化都在代码里的QSS中注释了
6+
7+
效果图:
8+
9+
### [CalendarWidget.py](CalendarWidget.py)
1010
![CalendarWidget](ScreenShot/CalendarWidget.gif)

0 commit comments

Comments
 (0)