diff --git a/Assets/Password.svg b/Assets/Password.svg new file mode 100644 index 0000000..e7b0e6a --- /dev/null +++ b/Assets/Password.svg @@ -0,0 +1,2 @@ + + diff --git a/Assets/Password2.svg b/Assets/Password2.svg new file mode 100644 index 0000000..c538c22 --- /dev/null +++ b/Assets/Password2.svg @@ -0,0 +1,22 @@ + + + + + + + + + + + + + + + + + + + + + + diff --git a/Components/Clock.qml b/Components/Clock.qml index 1aa7265..e6c83ab 100644 --- a/Components/Clock.qml +++ b/Components/Clock.qml @@ -23,7 +23,8 @@ Column { Label { id: timeLabel anchors.horizontalCenter: parent.horizontalCenter - font.pointSize: root.font.pointSize * 3 + font.pointSize: root.font.pointSize * 9 + font.bold: true color: root.palette.text renderType: Text.QtRendering function updateTime() { @@ -35,6 +36,8 @@ Column { id: dateLabel anchors.horizontalCenter: parent.horizontalCenter color: root.palette.text + font.pointSize: root.font.pointSize * 2 + font.bold: true renderType: Text.QtRendering function updateTime() { text = new Date().toLocaleDateString(Qt.locale(config.Locale), config.DateFormat == "short" ? Locale.ShortFormat : config.DateFormat !== "" ? config.DateFormat : Locale.LongFormat) diff --git a/Components/Input.qml b/Components/Input.qml index d8b763c..06aeabb 100644 --- a/Components/Input.qml +++ b/Components/Input.qml @@ -168,11 +168,13 @@ Column { TextField { id: username text: config.ForceLastUser == "true" ? selectUser.currentText : null + font.bold: true font.capitalization: config.AllowBadUsernames == "false" ? Font.Capitalize : Font.MixedCase anchors.centerIn: parent height: root.font.pointSize * 3 width: parent.width placeholderText: config.TranslatePlaceholderUsername || textConstants.userName + placeholderTextColor: config.placeholderColor selectByMouse: true horizontalAlignment: TextInput.AlignHCenter renderType: Text.QtRendering @@ -181,8 +183,9 @@ Column { selectAll() } background: Rectangle { - color: "transparent" - border.color: root.palette.text + color: "#222222" + opacity: 0.2 + border.color: "transparent" border.width: parent.activeFocus ? 2 : 1 radius: config.RoundCorners || 0 } @@ -205,31 +208,101 @@ Column { } ] } - } - + Item { id: passwordField + height: root.font.pointSize * 4.5 width: parent.width / 2 anchors.horizontalCenter: parent.horizontalCenter + + + Button { + + id: secretCheckBox + + width: parent.height + height: parent.height + anchors.left: parent.left + z: 2 + + background: Rectangle { + color: "transparent" + border.color: "transparent" + } + + CheckBox { + id: revealSecret + width: parent.width + height: parent.height + hoverEnabled: true + + indicator: Button { + id: passwordIcon + width: selectUser.height * 1 + height: parent.height + anchors.left: parent.left + anchors.verticalCenter: parent.verticalCenter + anchors.leftMargin: selectUser.height * 0 + icon.height: parent.height * 0.25 + icon.width: parent.height * 0.25 + enabled: false + icon.color: root.palette.text + icon.source: Qt.resolvedUrl("../Assets/Password.svg") + + background: Rectangle { + color: "transparent" + border.color: "transparent" + } + } + + states: [ + State { + name: "unchecked" + when: revealSecret.checked + PropertyChanges { + target: passwordIcon + icon.source: Qt.resolvedUrl("../Assets/Password.svg") + } + }, + State { + name: "checked" + when: revealSecret.enabled + PropertyChanges { + target: passwordIcon + icon.source: Qt.resolvedUrl("../Assets/Password2.svg") + } + } + ] + + Keys.onReturnPressed: toggle() + Keys.onEnterPressed: toggle() + KeyNavigation.down: loginButton + + } + + } TextField { id: password anchors.centerIn: parent height: root.font.pointSize * 3 width: parent.width + font.bold: true focus: config.ForcePasswordFocus == "true" ? true : false selectByMouse: true echoMode: revealSecret.checked ? TextInput.Normal : TextInput.Password placeholderText: config.TranslatePlaceholderPassword || textConstants.password + placeholderTextColor: config.placeholderColor horizontalAlignment: TextInput.AlignHCenter passwordCharacter: "•" passwordMaskDelay: config.ForceHideCompletePassword == "true" ? undefined : 1000 renderType: Text.QtRendering background: Rectangle { - color: "transparent" - border.color: root.palette.text + color: "#222222" + opacity: 0.2 + border.color: "transparent" border.width: parent.activeFocus ? 2 : 1 radius: config.RoundCorners || 0 } @@ -259,142 +332,7 @@ Column { duration: 150 } } - ] - } - - Item { - id: secretCheckBox - height: root.font.pointSize * 7 - width: parent.width / 2 - anchors.horizontalCenter: parent.horizontalCenter - - CheckBox { - id: revealSecret - width: parent.width - hoverEnabled: true - - indicator: Rectangle { - id: indicator - anchors.left: parent.left - anchors.top: parent.top - anchors.topMargin: 3 - anchors.leftMargin: 4 - implicitHeight: root.font.pointSize - implicitWidth: root.font.pointSize - color: "transparent" - border.color: root.palette.text - border.width: parent.activeFocus ? 2 : 1 - Rectangle { - id: dot - anchors.centerIn: parent - implicitHeight: parent.width - 6 - implicitWidth: parent.width - 6 - color: root.palette.text - opacity: revealSecret.checked ? 1 : 0 - } - } - - contentItem: Text { - id: indicatorLabel - text: config.TranslateShowPassword || "Show Password" - anchors.verticalCenter: indicator.verticalCenter - horizontalAlignment: Text.AlignLeft - anchors.left: indicator.right - anchors.leftMargin: indicator.width / 2 - font.pointSize: root.font.pointSize * 0.8 - font.family: root.font.family - color: root.palette.text - } - - Keys.onReturnPressed: toggle() - Keys.onEnterPressed: toggle() - KeyNavigation.down: loginButton - - background: Rectangle { - color: "transparent" - border.width: parent.activeFocus ? 1 : 0 - border.color: parent.activeFocus ? root.palette.text : "transparent" - height: parent.activeFocus ? 2 : 0 - width: (indicator.width + indicatorLabel.contentWidth + indicatorLabel.anchors.leftMargin + 2) - anchors.top: indicatorLabel.bottom - anchors.left: parent.left - anchors.leftMargin: 3 - anchors.topMargin: 8 - } - } - - states: [ - State { - name: "pressed" - when: revealSecret.down - PropertyChanges { - target: revealSecret.contentItem - color: Qt.darker(root.palette.highlight, 1.1) - } - PropertyChanges { - target: dot - color: Qt.darker(root.palette.highlight, 1.1) - } - PropertyChanges { - target: indicator - border.color: Qt.darker(root.palette.highlight, 1.1) - } - PropertyChanges { - target: revealSecret.background - border.color: Qt.darker(root.palette.highlight, 1.1) - } - }, - State { - name: "hovered" - when: revealSecret.hovered - PropertyChanges { - target: indicatorLabel - color: Qt.lighter(root.palette.highlight, 1.1) - } - PropertyChanges { - target: indicator - border.color: Qt.lighter(root.palette.highlight, 1.1) - } - PropertyChanges { - target: dot - color: Qt.lighter(root.palette.highlight, 1.1) - } - PropertyChanges { - target: revealSecret.background - border.color: Qt.lighter(root.palette.highlight, 1.1) - } - }, - State { - name: "focused" - when: revealSecret.activeFocus - PropertyChanges { - target: indicatorLabel - color: root.palette.highlight - } - PropertyChanges { - target: indicator - border.color: root.palette.highlight - } - PropertyChanges { - target: dot - color: root.palette.highlight - } - PropertyChanges { - target: revealSecret.background - border.color: root.palette.highlight - } - } - ] - - transitions: [ - Transition { - PropertyAnimation { - properties: "color, border.color, opacity" - duration: 150 - } - } - ] - + ] } Item { @@ -543,7 +481,6 @@ Column { SessionButton { id: sessionSelect - textConstantSession: textConstants.session loginButtonWidth: loginButton.background.width } diff --git a/Components/SessionButton.qml b/Components/SessionButton.qml index 1c9d0ee..02ca2c2 100644 --- a/Components/SessionButton.qml +++ b/Components/SessionButton.qml @@ -13,7 +13,6 @@ Item { height: root.font.pointSize width: parent.width / 2 anchors.horizontalCenter: parent.horizontalCenter - property var selectedSession: selectSession.currentIndex property string textConstantSession property int loginButtonWidth @@ -68,7 +67,7 @@ Item { contentItem: Text { id: displayedItem - text: (config.TranslateSession || (textConstantSession + ":")) + " " + selectSession.currentText + text: selectSession.currentText color: root.palette.text verticalAlignment: Text.AlignVCenter anchors.left: parent.left diff --git a/Components/SystemButtons.qml b/Components/SystemButtons.qml index 9f2dedc..d3d9c2b 100644 --- a/Components/SystemButtons.qml +++ b/Components/SystemButtons.qml @@ -31,6 +31,7 @@ RowLayout { icon.source: modelData ? Qt.resolvedUrl("../Assets/" + modelData[0] + ".svg") : "" icon.height: 2 * Math.round((root.font.pointSize * 3) / 2) icon.width: 2 * Math.round((root.font.pointSize * 3) / 2) + icon.color: config.IconColor display: AbstractButton.TextUnderIcon visible: config.ForceHideSystemButtons != "true" && modelData[2] hoverEnabled: true @@ -57,10 +58,12 @@ RowLayout { when: parent.children[index].down PropertyChanges { target: parent.children[index] + icon.color: root.palette.highlight palette.buttonText: Qt.darker(root.palette.highlight, 1.1) } PropertyChanges { target: parent.children[index].background + icon.color: root.palette.highlight border.color: Qt.darker(root.palette.highlight, 1.1) } }, @@ -69,10 +72,12 @@ RowLayout { when: parent.children[index].hovered PropertyChanges { target: parent.children[index] + icon.color: root.palette.highlight palette.buttonText: Qt.lighter(root.palette.highlight, 1.1) } PropertyChanges { target: parent.children[index].background + icon.color: root.palette.highlight border.color: Qt.lighter(root.palette.highlight, 1.1) } }, @@ -81,10 +86,12 @@ RowLayout { when: parent.children[index].activeFocus PropertyChanges { target: parent.children[index] + icon.color: root.palette.highlight palette.buttonText: root.palette.highlight } PropertyChanges { target: parent.children[index].background + icon.color: root.palette.highlight border.color: root.palette.highlight } } diff --git a/Fonts/OpenSans-Bold.ttf b/Fonts/OpenSans-Bold.ttf new file mode 100755 index 0000000..4d8f3e5 Binary files /dev/null and b/Fonts/OpenSans-Bold.ttf differ diff --git a/Fonts/OpenSans-BoldItalic.ttf b/Fonts/OpenSans-BoldItalic.ttf new file mode 100755 index 0000000..eba75d7 Binary files /dev/null and b/Fonts/OpenSans-BoldItalic.ttf differ diff --git a/Fonts/OpenSans-ExtraBold.ttf b/Fonts/OpenSans-ExtraBold.ttf new file mode 100755 index 0000000..db66f6a Binary files /dev/null and b/Fonts/OpenSans-ExtraBold.ttf differ diff --git a/Fonts/OpenSans-ExtraBoldItalic.ttf b/Fonts/OpenSans-ExtraBoldItalic.ttf new file mode 100755 index 0000000..b7611bb Binary files /dev/null and b/Fonts/OpenSans-ExtraBoldItalic.ttf differ diff --git a/Fonts/OpenSans-Italic.ttf b/Fonts/OpenSans-Italic.ttf new file mode 100755 index 0000000..b088474 Binary files /dev/null and b/Fonts/OpenSans-Italic.ttf differ diff --git a/Fonts/OpenSans-Light.ttf b/Fonts/OpenSans-Light.ttf new file mode 100755 index 0000000..d01b20c Binary files /dev/null and b/Fonts/OpenSans-Light.ttf differ diff --git a/Fonts/OpenSans-LightItalic.ttf b/Fonts/OpenSans-LightItalic.ttf new file mode 100755 index 0000000..0441a59 Binary files /dev/null and b/Fonts/OpenSans-LightItalic.ttf differ diff --git a/Fonts/OpenSans-Medium.ttf b/Fonts/OpenSans-Medium.ttf new file mode 100755 index 0000000..6b41918 Binary files /dev/null and b/Fonts/OpenSans-Medium.ttf differ diff --git a/Fonts/OpenSans-MediumItalic.ttf b/Fonts/OpenSans-MediumItalic.ttf new file mode 100755 index 0000000..c84fe4f Binary files /dev/null and b/Fonts/OpenSans-MediumItalic.ttf differ diff --git a/Fonts/OpenSans-Regular.ttf b/Fonts/OpenSans-Regular.ttf new file mode 100755 index 0000000..3a29f26 Binary files /dev/null and b/Fonts/OpenSans-Regular.ttf differ diff --git a/Fonts/OpenSans-SemiBold.ttf b/Fonts/OpenSans-SemiBold.ttf new file mode 100755 index 0000000..219f6e8 Binary files /dev/null and b/Fonts/OpenSans-SemiBold.ttf differ diff --git a/Fonts/OpenSans-SemiBoldItalic.ttf b/Fonts/OpenSans-SemiBoldItalic.ttf new file mode 100755 index 0000000..259ac50 Binary files /dev/null and b/Fonts/OpenSans-SemiBoldItalic.ttf differ diff --git a/Fonts/RobotoMono-Bold.ttf b/Fonts/RobotoMono-Bold.ttf deleted file mode 100644 index 900fce6..0000000 Binary files a/Fonts/RobotoMono-Bold.ttf and /dev/null differ diff --git a/Fonts/RobotoMono-BoldItalic.ttf b/Fonts/RobotoMono-BoldItalic.ttf deleted file mode 100644 index 4bfe29a..0000000 Binary files a/Fonts/RobotoMono-BoldItalic.ttf and /dev/null differ diff --git a/Fonts/RobotoMono-ExtraLight.ttf b/Fonts/RobotoMono-ExtraLight.ttf deleted file mode 100644 index d535884..0000000 Binary files a/Fonts/RobotoMono-ExtraLight.ttf and /dev/null differ diff --git a/Fonts/RobotoMono-ExtraLightItalic.ttf b/Fonts/RobotoMono-ExtraLightItalic.ttf deleted file mode 100644 index b28960a..0000000 Binary files a/Fonts/RobotoMono-ExtraLightItalic.ttf and /dev/null differ diff --git a/Fonts/RobotoMono-Italic.ttf b/Fonts/RobotoMono-Italic.ttf deleted file mode 100644 index 4ee4dc4..0000000 Binary files a/Fonts/RobotoMono-Italic.ttf and /dev/null differ diff --git a/Fonts/RobotoMono-Light.ttf b/Fonts/RobotoMono-Light.ttf deleted file mode 100644 index 276af4c..0000000 Binary files a/Fonts/RobotoMono-Light.ttf and /dev/null differ diff --git a/Fonts/RobotoMono-LightItalic.ttf b/Fonts/RobotoMono-LightItalic.ttf deleted file mode 100644 index a2801c2..0000000 Binary files a/Fonts/RobotoMono-LightItalic.ttf and /dev/null differ diff --git a/Fonts/RobotoMono-Medium.ttf b/Fonts/RobotoMono-Medium.ttf deleted file mode 100644 index 8461be7..0000000 Binary files a/Fonts/RobotoMono-Medium.ttf and /dev/null differ diff --git a/Fonts/RobotoMono-MediumItalic.ttf b/Fonts/RobotoMono-MediumItalic.ttf deleted file mode 100644 index a3bfaa1..0000000 Binary files a/Fonts/RobotoMono-MediumItalic.ttf and /dev/null differ diff --git a/Fonts/RobotoMono-Regular.ttf b/Fonts/RobotoMono-Regular.ttf deleted file mode 100644 index 7c4ce36..0000000 Binary files a/Fonts/RobotoMono-Regular.ttf and /dev/null differ diff --git a/Fonts/RobotoMono-SemiBold.ttf b/Fonts/RobotoMono-SemiBold.ttf deleted file mode 100644 index 15ee6c6..0000000 Binary files a/Fonts/RobotoMono-SemiBold.ttf and /dev/null differ diff --git a/Fonts/RobotoMono-SemiBoldItalic.ttf b/Fonts/RobotoMono-SemiBoldItalic.ttf deleted file mode 100644 index 8e21497..0000000 Binary files a/Fonts/RobotoMono-SemiBoldItalic.ttf and /dev/null differ diff --git a/Fonts/RobotoMono-Thin.ttf b/Fonts/RobotoMono-Thin.ttf deleted file mode 100644 index ee8a3fd..0000000 Binary files a/Fonts/RobotoMono-Thin.ttf and /dev/null differ diff --git a/Fonts/RobotoMono-ThinItalic.ttf b/Fonts/RobotoMono-ThinItalic.ttf deleted file mode 100644 index 40b01e4..0000000 Binary files a/Fonts/RobotoMono-ThinItalic.ttf and /dev/null differ diff --git a/Previews/preview.png b/Previews/preview.png deleted file mode 100644 index fde3064..0000000 Binary files a/Previews/preview.png and /dev/null differ diff --git a/Previews/preview1.png b/Previews/preview1.png new file mode 100644 index 0000000..d6e9b49 Binary files /dev/null and b/Previews/preview1.png differ diff --git a/Previews/preview2.png b/Previews/preview2.png new file mode 100644 index 0000000..3d6b9b2 Binary files /dev/null and b/Previews/preview2.png differ diff --git a/Previews/preview3.png b/Previews/preview3.png new file mode 100644 index 0000000..f27aaa4 Binary files /dev/null and b/Previews/preview3.png differ diff --git a/README.md b/README.md index 3bd2431..862b470 100644 --- a/README.md +++ b/README.md @@ -4,8 +4,9 @@ A theme for the [SDDM login manager](https://github.com/sddm/sddm) based on [`Su Screen resolution: 1080p. ### Preview -![Preview](./Previews/preview.png) - +![Preview](./Previews/preview1.png) +![Preview](./Previews/preview2.png) +![Preview](./Previews/preview3.png) ### Dependencies ```sh diff --git a/theme.conf b/theme.conf index 47bda59..9b03083 100755 --- a/theme.conf +++ b/theme.conf @@ -50,6 +50,12 @@ AccentColor="#343746" BackgroundColor="#21222C" ## Used for the user and session selection background as well as for ScreenPadding and FormBackground when either is true. If PartialBlur and FormBackground are both enabled this color will blend with the blur effect. +placeholderColor="#bbbbbb" +## Placholder text color. Example: username, password. + +IconColor="#ffffff" +## System icon colors + OverrideLoginButtonTextColor="" ## The text of the login button may become difficult to read depending on your color choices. Use this option to set it independently for legibility. @@ -65,7 +71,7 @@ RoundCorners="20" ScreenPadding="0" ## Integer in pixels. Increase or delete this to have a padding of color BackgroundColor all around your screen. This makes your login greeter appear as if it was a canvas. Cool! -Font="Roboto mono" +Font="Open Sans" ## If you want to choose a custom font it will have to be available to the X root user. See https://wiki.archlinux.org/index.php/fonts#Manual_installation FontSize="" @@ -109,25 +115,23 @@ Locale="" HourFormat="HH:mm" ## Defaults to Locale.ShortFormat - Accepts "long" or a custom string like "hh:mm A". See http://doc.qt.io/qt-5/qml-qtqml-date.html -DateFormat="dddd, d of MMMM" +DateFormat="dddd d MMMM" ## Defaults to Locale.LongFormat - Accepts "short" or a custom string like "dddd, d 'of' MMMM". See http://doc.qt.io/qt-5/qml-qtqml-date.html ## [Translations] -HeaderText="Welcome!" +HeaderText="" ## Header can be empty to not display any greeting at all. Keep it short. ## SDDM may lack proper translation for every element. Suger defaults to SDDM translations. Please help translate SDDM as much as possible for your language: https://github.com/sddm/sddm/wiki/Localization. These are in order as they appear on screen. TranslatePlaceholderUsername="" TranslatePlaceholderPassword="" -TranslateShowPassword="" TranslateLogin="" TranslateLoginFailedWarning="" TranslateCapslockWarning="" -TranslateSession="" TranslateSuspend="" TranslateHibernate="" TranslateReboot=""