Skip to content

Commit 680ed58

Browse files
18202781743deepin-bot[bot]
authored andcommitted
fix: adjust ui of title for notification
Add DropShadow for text. pms: BUG-313195
1 parent 3a55b95 commit 680ed58

File tree

4 files changed

+30
-10
lines changed

4 files changed

+30
-10
lines changed

panels/notification/center/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ qt_add_qml_module(notificationcenterpanel
2020
AnimationSettingButton.qml
2121
BoundingRectangle.qml
2222
DataPanel.qml
23+
NotifyHeaderTitleText.qml
2324
SOURCES
2425
notificationcenterpanel.h
2526
notificationcenterpanel.cpp

panels/notification/center/GroupNotify.qml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,11 @@ NotifyItem {
1515
signal collapse()
1616

1717
contentItem: RowLayout {
18-
Text {
18+
NotifyHeaderTitleText {
1919
text: root.appName
2020
Layout.alignment: Qt.AlignLeft
2121
Layout.leftMargin: 18
22-
font: DTK.fontManager.t5
23-
color: palette.windowText
22+
tFont: DTK.fontManager.t5
2423
}
2524

2625
Item {

panels/notification/center/NotifyHeader.qml

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -38,16 +38,11 @@ FocusScope {
3838

3939
RowLayout {
4040
anchors.fill: parent
41-
Text {
41+
NotifyHeaderTitleText {
4242
text: qsTr("Notification Center")
4343
Layout.alignment: Qt.AlignLeft
4444
Layout.leftMargin: 18
45-
font {
46-
pixelSize: DTK.fontManager.t4.pixelSize
47-
family: DTK.fontManager.t4.family
48-
bold: true
49-
}
50-
color: palette.windowText
45+
tFont: DTK.fontManager.t4
5146
MouseArea {
5247
anchors.fill: parent
5348
onDoubleClicked: {
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
// SPDX-FileCopyrightText: 2025 UnionTech Software Technology Co., Ltd.
2+
//
3+
// SPDX-License-Identifier: GPL-3.0-or-later
4+
5+
import QtQuick
6+
import Qt5Compat.GraphicalEffects
7+
import org.deepin.dtk 1.0
8+
import org.deepin.ds.notificationcenter
9+
10+
Text {
11+
property font tFont: DTK.fontManager.t4
12+
font {
13+
pixelSize: tFont.pixelSize
14+
family: tFont.family
15+
bold: true
16+
}
17+
color: Qt.rgba(1, 1, 1, 1)
18+
layer.enabled: true
19+
layer.effect: DropShadow {
20+
color: Qt.rgba(0, 0, 0, 0.6)
21+
radius: 4
22+
samples: 9
23+
verticalOffset: 1
24+
}
25+
}

0 commit comments

Comments
 (0)