Skip to content

Commit 8e32dc3

Browse files
committed
Customization Integration
1 parent a657c27 commit 8e32dc3

26 files changed

+97
-35
lines changed

Background.qml

100755100644
File mode changed.

CHANGELOG.md

+5
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
# Changelog
22

3+
## [0.5.3] - 2018-10-12
4+
5+
### Changed
6+
- A lot of new options in theme.conf, see README for details
7+
38
## [0.5.2] - 2018-07-22
49

510
### Changed

Login.qml

100755100644
+19-9
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,11 @@ import org.kde.plasma.components 2.0 as PlasmaComponents
1010
SessionManagementScreen {
1111

1212
property bool showUsernamePrompt: !showUserList
13-
13+
property int usernameFontSize
14+
property string usernameFontColor
1415
property string lastUserName
16+
property bool passwordFieldOutlined: config.PasswordFieldOutlined == "true"
17+
property bool hidePasswordRevealIcon: config.HidePasswordRevealIcon == "false"
1518

1619
//the y position that should be ensured visible when the on screen keyboard is visible
1720
property int visibleBoundary: mapFromItem(loginButton, 0, 0).y
@@ -43,10 +46,10 @@ SessionManagementScreen {
4346
PlasmaComponents.TextField {
4447
id: userNameInput
4548
Layout.fillWidth: true
46-
Layout.minimumHeight: 24
49+
Layout.minimumHeight: 21
4750
implicitHeight: root.height / 28
4851
font.family: "Noto Sans"
49-
font.pointSize: root.height / 75
52+
font.pointSize: usernameFontSize
5053
opacity: 0.5
5154
text: lastUserName
5255
visible: showUsernamePrompt
@@ -63,21 +66,28 @@ SessionManagementScreen {
6366

6467
PlasmaComponents.TextField {
6568
id: passwordBox
69+
6670
Layout.fillWidth: true
67-
Layout.minimumHeight: 24
68-
implicitHeight: root.height / 28
71+
Layout.minimumHeight: 21
72+
implicitHeight: usernameFontSize * 2.85
73+
font.pointSize: usernameFontSize * 0.8
74+
opacity: passwordFieldOutlined ? 0.75 : 0.5
6975
font.family: "Noto Sans"
70-
font.pointSize: root.height / 85
71-
opacity: 0.5
72-
placeholderText: i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Password")
76+
placeholderText: config.PasswordFieldPlaceholderText == "Password" ? i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Password") : config.PasswordFieldPlaceholderText
7377
focus: !showUsernamePrompt || lastUserName
7478
echoMode: TextInput.Password
79+
revealPasswordButtonShown: hidePasswordRevealIcon
7580
onAccepted: startLogin()
7681

7782
style: TextFieldStyle {
78-
textColor: "black"
83+
textColor: passwordFieldOutlined ? "white" : "black"
84+
placeholderTextColor: passwordFieldOutlined ? "white" : "black"
85+
passwordCharacter: config.PasswordFieldCharacter == "" ? "" : config.PasswordFieldCharacter
7986
background: Rectangle {
8087
radius: 3
88+
border.color: "white"
89+
border.width: 1
90+
color: passwordFieldOutlined ? "transparent" : "white"
8191
}
8292
}
8393

Main.qml

100755100644
+16-5
Original file line numberDiff line numberDiff line change
@@ -32,10 +32,12 @@ PlasmaCore.ColorScope {
3232
id: root
3333
colorGroup: PlasmaCore.Theme.ComplementaryColorGroup
3434

35-
width: 1600
36-
height: 900
35+
width: config.ScreenWidth
36+
height: config.ScreenHeight
3737

3838
property string notificationMessage
39+
property string generalFontColor: "white"
40+
property int generalFontSize: config.FontPointSize ? config.FontPointSize : root.height / 75
3941

4042
LayoutMirroring.enabled: Qt.application.layoutDirection === Qt.RightToLeft
4143
LayoutMirroring.childrenInherit: true
@@ -66,6 +68,7 @@ PlasmaCore.ColorScope {
6668
}
6769
anchors.rightMargin: 14
6870
anchors.topMargin: 10
71+
clockSize: root.generalFontSize
6972
}
7073

7174

@@ -95,6 +98,10 @@ PlasmaCore.ColorScope {
9598
userListModel: userModel
9699
userListCurrentIndex: userModel.lastIndex >= 0 ? userModel.lastIndex : 0
97100
lastUserName: userModel.lastUser
101+
102+
usernameFontSize: root.generalFontSize
103+
usernameFontColor: root.generalFontColor
104+
98105
showUserList: {
99106
if ( !userListModel.hasOwnProperty("count")
100107
|| !userListModel.hasOwnProperty("disableAvatarsThreshold"))
@@ -120,24 +127,27 @@ PlasmaCore.ColorScope {
120127
actionItems: [
121128
ActionButton {
122129
iconSource: "system-suspend"
123-
text: i18nd("plasma_lookandfeel_org.kde.lookandfeel","Suspend")
130+
text: config.translationSuspend ? config.translationSuspend : i18nd("plasma_lookandfeel_org.kde.lookandfeel","Suspend")
124131
onClicked: sddm.suspend()
125132
enabled: sddm.canSuspend
126133
visible: !inputPanel.keyboardActive
134+
iconSize: root.generalFontSize * 4.25
127135
},
128136
ActionButton {
129137
iconSource: "system-reboot"
130-
text: i18nd("plasma_lookandfeel_org.kde.lookandfeel","Restart")
138+
text: config.translationReboot ? config.translationReboot : i18nd("plasma_lookandfeel_org.kde.lookandfeel","Restart")
131139
onClicked: sddm.reboot()
132140
enabled: sddm.canReboot
133141
visible: !inputPanel.keyboardActive
142+
iconSize: root.generalFontSize * 4.25
134143
},
135144
ActionButton {
136145
iconSource: "system-shutdown"
137-
text: i18nd("plasma_lookandfeel_org.kde.lookandfeel","Shutdown")
146+
text: config.translationPowerOff ? config.translationPowerOff : i18nd("plasma_lookandfeel_org.kde.lookandfeel","Shutdown")
138147
onClicked: sddm.powerOff()
139148
enabled: sddm.canPowerOff
140149
visible: !inputPanel.keyboardActive
150+
iconSize: root.generalFontSize * 4.25
141151
}
142152
]
143153

@@ -318,6 +328,7 @@ PlasmaCore.ColorScope {
318328

319329
SessionButton {
320330
id: sessionButton
331+
sessionFontSize: root.generalFontSize
321332
}
322333

323334
}

README.md

+26-8
Original file line numberDiff line numberDiff line change
@@ -30,18 +30,36 @@ In the `[Theme]` section set `Current=plasma-chili`. For a more detailed descrip
3030

3131
### Theming the theme
3232

33-
Chili is now customizable through its `theme.conf` file. You can now alter the intensity of the background blur or even not have any blur at all! Also there may be screens so big that the avatar just not looks correct. Change it in the config to something that better suits your screen!
33+
Chili is now **even more** customizable through its `theme.conf` file. You can alter the intensity of the background blur or even not have any blur at all! Have a custom password field to your likings! Also there may be screens so big that the avatar just not looks correct. Change it in the config to something that better suits your screen!
3434

3535
* Change the path of the background image relative to the themes directory:
3636
`background=components/artwork/background.jpg`
3737

38-
* Disable blur or play around with its intensity:
39-
`blur=true`
40-
`recursiveBlurLoops=40`
41-
`recursiveBlurRadius=4`
42-
43-
* Adjust the size of the user image:
44-
`changeAvatarPixelSize=`
38+
* Set the real screen size if anything looks odd:
39+
`ScreenWidth=1366`
40+
`ScreenHeight=768`
41+
42+
* Disable blur or play around with its intensity:
43+
`blur=true`
44+
`recursiveBlurLoops=40`
45+
`recursiveBlurRadius=4`
46+
47+
* Customize the password input field:
48+
`HidePasswordRevealIcon=true`
49+
`PasswordFieldOutlined=false`
50+
`PasswordFieldCharacter=`
51+
*Here are some funny ones you can copy: ⁙ ⁕ ○ █ ©*
52+
`PasswordFieldPlaceholderText=Password`
53+
54+
* Adjust the sizes of the theme (dangerous!):
55+
`PowerIconSize=`
56+
`FontPointSize=`
57+
`changeAvatarPixelSize=`
58+
59+
* Translate the power buttons if your language isn't available by default:
60+
`translationSuspend=`
61+
`translationReboot=`
62+
`translationPowerOff=`
4563

4664
You might see some grey pixels around your user image which is caused by the the anti-aliasing of the opacity mask. You may change the fill color of the mask that resides in `components/artwork/mask.svg` to a color that better matches with your user images colors. Do **not** change the *opacity* of the mask. Take note that this might affect other user images with different colors present on your system.
4765

SessionButton.qml

100755100644
+2-1
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,11 @@ import QtQuick.Controls 1.3 as QQC
2727
PlasmaComponents.ToolButton {
2828
id: root
2929
property int currentIndex: -1
30+
property int sessionFontSize
3031

3132
visible: menu.items.length > 1
3233
font.family: "Noto Sans"
33-
font.pointSize: footer.parent.height / 75
34+
font.pointSize: sessionFontSize
3435

3536
text: instantiator.objectAt(currentIndex).text || ""
3637

components/ActionButton.qml

100755100644
+4-4
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ Item {
3131

3232
activeFocusOnTab: true
3333
opacity: ( containsMouse || activeFocus ) ? 1 : 0.6
34-
property int iconSize: units.gridUnit * 2
34+
property int iconSize
3535

3636
implicitWidth: Math.max(icon.implicitWidth + units.largeSpacing * 3, label.contentWidth)
3737
implicitHeight: Math.max(icon.implicitHeight + units.largeSpacing * 2, label.contentHeight)
@@ -43,8 +43,8 @@ Item {
4343
horizontalCenter: parent.horizontalCenter
4444
}
4545

46-
width: iconSize
47-
height: iconSize
46+
width: config.PowerIconSize ? config.PowerIconSize : iconSize
47+
height: config.PowerIconSize ? config.PowerIconSize : iconSize
4848

4949
colorGroup: PlasmaCore.ColorScope.colorGroup
5050
active: mouseArea.containsMouse || root.activeFocus
@@ -81,4 +81,4 @@ Item {
8181
Accessible.onPressAction: clicked()
8282
Accessible.role: Accessible.Button
8383
Accessible.name: label.text
84-
}
84+
}

components/Battery.qml

100755100644
File mode changed.

components/Clock.qml

100755100644
+5-2
Original file line numberDiff line numberDiff line change
@@ -24,17 +24,20 @@ import org.kde.plasma.core 2.0
2424
import org.kde.plasma.components 2.0
2525

2626
RowLayout {
27+
28+
property int clockSize
29+
2730
KeyboardButton {}
2831
Battery {}
2932
Label {
3033
font.family: "Noto Sans"
31-
font.pointSize: root.height / 75
34+
font.pointSize: clockSize
3235
text: Qt.formatDateTime(timeSource.data["Local"]["DateTime"], " ddd dd MMMM,")
3336
renderType: Text.QtRendering
3437
}
3538
Label {
3639
font.family: "Noto Sans"
37-
font.pointSize: root.height / 75
40+
font.pointSize: clockSize
3841
text: Qt.formatTime(timeSource.data["Local"]["DateTime"])
3942
renderType: Text.QtRendering
4043
}

components/KeyboardButton.qml

100755100644
File mode changed.

components/KeyboardLayoutButton.qml

100755100644
File mode changed.

components/SessionManagementScreen.qml

100755100644
File mode changed.

components/UserDelegate.qml

100755100644
+2-2
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ Item {
3737
property bool constrainText: true
3838
signal clicked()
3939

40-
property real faceSize: config.changeAvatarPixelSize ? config.changeAvatarPixelSize : Math.min(width, height - usernameDelegate.height - units.smallSpacing)
40+
property real faceSize: config.AvatarPixelSize ? config.AvatarPixelSize : Math.min(width, height - usernameDelegate.height - units.smallSpacing)
4141

4242
opacity: isCurrent ? 1.0 : 0.3
4343

@@ -93,7 +93,7 @@ Item {
9393
PlasmaComponents.Label {
9494
id: usernameDelegate
9595
font.family: "Noto Sans"
96-
font.pointSize: root.height / 60
96+
font.pointSize: config.FontPointSize ? config.FontPointSize * 1.2 : root.height / 80 * 1.2
9797
renderType: Text.QtRendering
9898
font.capitalization: Font.Capitalize
9999
anchors {

components/UserList.qml

100755100644
File mode changed.

components/VirtualKeyboard.qml

100755100644
File mode changed.

components/artwork/.directory

100755100644
File mode changed.

components/artwork/background.jpg

100755100644
File mode changed.

components/artwork/logout_primary.svgz

100755100644
File mode changed.

components/artwork/restart_primary.svgz

100755100644
File mode changed.

components/artwork/shutdown_primary.svgz

100755100644
File mode changed.

metadata.desktop

100755100644
+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ Description=The hottest theme for KDE Plasma
44
Author=Marian Alexander Arlt
55
License=GPLv3
66
Type=sddm-theme
7-
Version=0.5.2
7+
Version=0.5.3
88
Website=https://github.com/MarianArlt/kde-plasma-chili
99
Screenshot=preview.png
1010
MainScript=Main.qml

preview.png

100755100644
File mode changed.

preview_customized.png

551 KB
Loading

preview_input.png

100755100644
File mode changed.

preview_multi_user.png

100755100644
File mode changed.

theme.conf

100755100644
+17-3
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,22 @@
11
[General]
22
background=components/artwork/background.jpg
33

4+
ScreenWidth=1366
5+
ScreenHeight=768
6+
47
blur=true
5-
recursiveBlurLoops=20
6-
recursiveBlurRadius=4
8+
recursiveBlurLoops=4
9+
recursiveBlurRadius=15
10+
11+
HidePasswordRevealIcon=true
12+
PasswordFieldOutlined=false
13+
PasswordFieldCharacter=
14+
PasswordFieldPlaceholderText=Password
15+
16+
PowerIconSize=
17+
FontPointSize=
18+
AvatarPixelSize=
719

8-
changeAvatarPixelSize=
20+
translationSuspend=
21+
translationReboot=
22+
translationPowerOff=

0 commit comments

Comments
 (0)