diff options
Diffstat (limited to 'x11-themes/redcore-theme-sddm/files')
29 files changed, 509 insertions, 1330 deletions
diff --git a/x11-themes/redcore-theme-sddm/files/redcore/Background.qml b/x11-themes/redcore-theme-sddm/files/redcore/Background.qml index 5a384151..6721e57f 100644 --- a/x11-themes/redcore-theme-sddm/files/redcore/Background.qml +++ b/x11-themes/redcore-theme-sddm/files/redcore/Background.qml @@ -1,23 +1,10 @@ /* - * Copyright 2016 Boudhayan Gupta <bgupta@kde.org> - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU Library General Public License as - * published by the Free Software Foundation; either version 2 or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details - * - * You should have received a copy of the GNU Library General Public - * License along with this program; if not, write to the - * Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - */ + SPDX-FileCopyrightText: 2016 Boudhayan Gupta <bgupta@kde.org> -import QtQuick 2.2 + SPDX-License-Identifier: LGPL-2.0-or-later +*/ + +import QtQuick 2.15 FocusScope { id: sceneBackground diff --git a/x11-themes/redcore-theme-sddm/files/redcore/BreezeMenuStyle.qml b/x11-themes/redcore-theme-sddm/files/redcore/BreezeMenuStyle.qml deleted file mode 100644 index 7d56c149..00000000 --- a/x11-themes/redcore-theme-sddm/files/redcore/BreezeMenuStyle.qml +++ /dev/null @@ -1,25 +0,0 @@ -import QtQuick 2.2 - -import org.kde.plasma.core 2.0 as PlasmaCore - -import QtQuick.Controls.Styles 1.4 as QQCS -import QtQuick.Controls 1.3 as QQC - -QQCS.MenuStyle { - frame: Rectangle { - color: PlasmaCore.ColorScope.backgroundColor - border.color: Qt.tint(PlasmaCore.ColorScope.textColor, Qt.rgba(color.r, color.g, color.b, 0.7)) - border.width: 1 - } - itemDelegate.label: QQC.Label { - height: contentHeight * 1.2 - verticalAlignment: Text.AlignVCenter - color: styleData.selected ? PlasmaCore.ColorScope.highlightedTextColor : PlasmaCore.ColorScope.textColor - font.pointSize: config.fontSize - text: styleData.text - } - itemDelegate.background: Rectangle { - visible: styleData.selected - color: PlasmaCore.ColorScope.highlightColor - } -} diff --git a/x11-themes/redcore-theme-sddm/files/redcore/KeyboardButton.qml b/x11-themes/redcore-theme-sddm/files/redcore/KeyboardButton.qml index 9989d93e..cd9f97bd 100644 --- a/x11-themes/redcore-theme-sddm/files/redcore/KeyboardButton.qml +++ b/x11-themes/redcore-theme-sddm/files/redcore/KeyboardButton.qml @@ -1,36 +1,59 @@ -import QtQuick 2.2 +/* + SPDX-FileCopyrightText: 2016 David Edmundson <davidedmundson@kde.org> + SPDX-FileCopyrightText: 2022 Aleix Pol Gonzalez <aleixpol@kde.org> -import org.kde.plasma.core 2.0 as PlasmaCore -import org.kde.plasma.components 2.0 as PlasmaComponents + SPDX-License-Identifier: LGPL-2.0-or-later +*/ -import QtQuick.Controls 1.3 as QQC +import QtQuick 2.15 + +import org.kde.plasma.components 3.0 as PlasmaComponents +import org.kde.kirigami 2.20 as Kirigami PlasmaComponents.ToolButton { - id: keyboardButton + id: root + + property int currentIndex: keyboard.currentLayout + onCurrentIndexChanged: keyboard.currentLayout = currentIndex - property int currentIndex: -1 + text: i18nd("plasma-desktop-sddm-theme", "Keyboard Layout: %1", keyboard.layouts[currentIndex].longName) + visible: keyboard.layouts.length > 1 - text: i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Keyboard Layout: %1", instantiator.objectAt(currentIndex).shortName) - implicitWidth: minimumWidth - font.pointSize: config.fontSize + checkable: true + checked: menu.opened + onToggled: { + if (checked) { + menu.popup(root, 0, 0) + } else { + menu.dismiss() + } + } - visible: menu.items.length > 1 + signal keyboardLayoutChanged() - Component.onCompleted: currentIndex = Qt.binding(function() {return keyboard.currentLayout}); + PlasmaComponents.Menu { + id: menu + Kirigami.Theme.colorSet: Kirigami.Theme.Window + Kirigami.Theme.inherit: false + + onAboutToShow: { + if (instantiator.model === null) { + let layouts = keyboard.layouts; + layouts.sort((a, b) => a.longName.localeCompare(b.longName)); + instantiator.model = layouts; + } + } - menu: QQC.Menu { - id: keyboardMenu - style: BreezeMenuStyle {} Instantiator { id: instantiator - model: keyboard.layouts - onObjectAdded: keyboardMenu.insertItem(index, object) - onObjectRemoved: keyboardMenu.removeItem( object ) - delegate: QQC.MenuItem { + model: null + onObjectAdded: (index, object) => menu.insertItem(index, object) + onObjectRemoved: (index, object) => menu.removeItem(object) + delegate: PlasmaComponents.MenuItem { text: modelData.longName - property string shortName: modelData.shortName onTriggered: { - keyboard.currentLayout = model.index + keyboard.currentLayout = keyboard.layouts.indexOf(modelData) + root.keyboardLayoutChanged() } } } diff --git a/x11-themes/redcore-theme-sddm/files/redcore/Login.qml b/x11-themes/redcore-theme-sddm/files/redcore/Login.qml index 7234917f..22751b01 100644 --- a/x11-themes/redcore-theme-sddm/files/redcore/Login.qml +++ b/x11-themes/redcore-theme-sddm/files/redcore/Login.qml @@ -1,22 +1,27 @@ -import "components" +import org.kde.breeze.components -import QtQuick 2.0 -import QtQuick.Layouts 1.2 -import QtQuick.Controls.Styles 1.4 +import QtQuick 2.15 +import QtQuick.Layouts 1.15 +import QtQuick.Controls 2.15 as QQC2 -import org.kde.plasma.core 2.0 as PlasmaCore -import org.kde.plasma.components 2.0 as PlasmaComponents +import org.kde.plasma.components 3.0 as PlasmaComponents3 +import org.kde.plasma.extras 2.0 as PlasmaExtras +import org.kde.kirigami 2.20 as Kirigami SessionManagementScreen { + id: root + property Item mainPasswordBox: passwordBox property bool showUsernamePrompt: !showUserList - property int usernameFontSize - property string usernameFontColor + property string lastUserName - property bool passwordFieldOutlined: config.PasswordFieldOutlined == "true" - property bool hidePasswordRevealIcon: config.HidePasswordRevealIcon == "false" + property bool loginScreenUiVisible: false + + //the y position that should be ensured visible when the on screen keyboard is visible property int visibleBoundary: mapFromItem(loginButton, 0, 0).y - onHeightChanged: visibleBoundary = mapFromItem(loginButton, 0, 0).y + loginButton.height + units.smallSpacing + onHeightChanged: visibleBoundary = mapFromItem(loginButton, 0, 0).y + loginButton.height + Kirigami.Units.smallSpacing + + property real fontSize: Kirigami.Theme.defaultFont.pointSize signal loginRequest(string username, string password) @@ -26,131 +31,126 @@ SessionManagementScreen { } } + onUserSelected: { + // Don't startLogin() here, because the signal is connected to the + // Escape key as well, for which it wouldn't make sense to trigger + // login. + focusFirstVisibleFormControl(); + } + + QQC2.StackView.onActivating: { + // Controls are not visible yet. + Qt.callLater(focusFirstVisibleFormControl); + } + + function focusFirstVisibleFormControl() { + const nextControl = (userNameInput.visible + ? userNameInput + : (passwordBox.visible + ? passwordBox + : loginButton)); + // Using TabFocusReason, so that the loginButton gets the visual highlight. + nextControl.forceActiveFocus(Qt.TabFocusReason); + } + /* - * Login has been requested with the following username and password - * If username field is visible, it will be taken from that, otherwise from the "name" property of the currentIndex - */ + * Login has been requested with the following username and password + * If username field is visible, it will be taken from that, otherwise from the "name" property of the currentIndex + */ function startLogin() { - var username = showUsernamePrompt ? userNameInput.text : userList.selectedUser - var password = passwordBox.text - + const username = showUsernamePrompt ? userNameInput.text : userList.selectedUser + const password = passwordBox.text + + footer.enabled = false + mainStack.enabled = false + userListComponent.userList.opacity = 0.5 + + // This is partly because it looks nicer, but more importantly it + // works round a Qt bug that can trigger if the app is closed with a + // TextField focused. + // + // See https://bugreports.qt.io/browse/QTBUG-55460 loginButton.forceActiveFocus(); loginRequest(username, password); } - PlasmaComponents.TextField { + PlasmaComponents3.TextField { id: userNameInput + font.pointSize: fontSize + 1 Layout.fillWidth: true - Layout.minimumHeight: 32 - implicitHeight: usernameFontSize * 2.85 - font.pointSize: usernameFontSize * 0.8 - font.family: config.Font || "Noto Sans" - opacity: 1.0 + text: lastUserName visible: showUsernamePrompt focus: showUsernamePrompt && !lastUserName //if there's a username prompt it gets focus first, otherwise password does - placeholderText: i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Username") - - style: TextFieldStyle { - textColor: "white" - placeholderTextColor: "white" - background: Rectangle { - radius: 6 - border.color: "#1A73E8" - border.width: 2 - color: "#48316f" + placeholderText: i18nd("plasma-desktop-sddm-theme", "Username") + + onAccepted: { + if (root.loginScreenUiVisible) { + passwordBox.forceActiveFocus() } } } - PlasmaComponents.TextField { - id: passwordBox + RowLayout { Layout.fillWidth: true - Layout.minimumHeight: 32 - implicitHeight: usernameFontSize * 2.85 - font.pointSize: usernameFontSize * 0.8 - opacity: passwordFieldOutlined ? 1.0 : 1.0 - font.family: config.Font || "Noto Sans" - placeholderText: config.PasswordFieldPlaceholderText == "Password" ? i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Password") : config.PasswordFieldPlaceholderText - focus: !showUsernamePrompt || lastUserName - echoMode: TextInput.Password - revealPasswordButtonShown: hidePasswordRevealIcon - onAccepted: startLogin() - - style: TextFieldStyle { - textColor: passwordFieldOutlined ? "white" : "white" - placeholderTextColor: passwordFieldOutlined ? "white" : "white" - passwordCharacter: config.PasswordFieldCharacter == "" ? "●" : config.PasswordFieldCharacter - background: Rectangle { - radius: 6 - border.color: "#1A73E8" - border.width: 2 - color: "#48316f" - } - } - Keys.onEscapePressed: { - mainStack.currentItem.forceActiveFocus(); - } + PlasmaExtras.PasswordField { + id: passwordBox + font.pointSize: fontSize + 1 + Layout.fillWidth: true - Keys.onPressed: { - if (event.key == Qt.Key_Left && !text) { - userList.decrementCurrentIndex(); - event.accepted = true - } - if (event.key == Qt.Key_Right && !text) { - userList.incrementCurrentIndex(); - event.accepted = true + placeholderText: i18nd("plasma-desktop-sddm-theme", "Password") + focus: !showUsernamePrompt || lastUserName + + // Disable reveal password action because SDDM does not have the breeze icon set loaded + rightActions: [] + + onAccepted: { + if (root.loginScreenUiVisible) { + startLogin(); + } } - } - Keys.onReleased: { - if (loginButton.opacity == 0 && length > 0) { - showLoginButton.start() + visible: root.showUsernamePrompt || userList.currentItem.needsPassword + + Keys.onEscapePressed: { + mainStack.currentItem.forceActiveFocus(); } - if (loginButton.opacity > 0 && length == 0) { - hideLoginButton.start() + + //if empty and left or right is pressed change selection in user switch + //this cannot be in keys.onLeftPressed as then it doesn't reach the password box + Keys.onPressed: event => { + if (event.key === Qt.Key_Left && !text) { + userList.decrementCurrentIndex(); + event.accepted = true + } + if (event.key === Qt.Key_Right && !text) { + userList.incrementCurrentIndex(); + event.accepted = true + } } - } - Connections { - target: sddm - onLoginFailed: { - passwordBox.selectAll() - passwordBox.forceActiveFocus() + Connections { + target: sddm + function onLoginFailed() { + passwordBox.selectAll() + passwordBox.forceActiveFocus() + } } } - } - Image { - id: loginButton - source: "assets/login.svgz" - smooth: true - sourceSize: Qt.size(passwordBox.height, passwordBox.height) - anchors { - left: passwordBox.right - verticalCenter: passwordBox.verticalCenter - } - anchors.leftMargin: 8 - visible: opacity > 0 - opacity: 0 - MouseArea { - anchors.fill: parent - onClicked: startLogin(); - } - PropertyAnimation { - id: showLoginButton - target: loginButton - properties: "opacity" - to: 0.75 - duration: 100 - } - PropertyAnimation { - id: hideLoginButton - target: loginButton - properties: "opacity" - to: 0 - duration: 80 + PlasmaComponents3.Button { + id: loginButton + Accessible.name: i18nd("plasma-desktop-sddm-theme", "Log In") + Layout.preferredHeight: passwordBox.implicitHeight + Layout.preferredWidth: text.length === 0 ? loginButton.Layout.preferredHeight : -1 + + icon.name: text.length === 0 ? (root.LayoutMirroring.enabled ? "go-previous" : "go-next") : "" + + text: root.showUsernamePrompt || userList.currentItem.needsPassword ? "" : i18n("Log In") + onClicked: startLogin() + Keys.onEnterPressed: clicked() + Keys.onReturnPressed: clicked() } } } diff --git a/x11-themes/redcore-theme-sddm/files/redcore/Main.qml b/x11-themes/redcore-theme-sddm/files/redcore/Main.qml index ab5c5dd7..60b8f61d 100644 --- a/x11-themes/redcore-theme-sddm/files/redcore/Main.qml +++ b/x11-themes/redcore-theme-sddm/files/redcore/Main.qml @@ -1,42 +1,29 @@ /* - * Copyright 2016 David Edmundson <davidedmundson@kde.org> - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU Library General Public License as - * published by the Free Software Foundation; either version 2 or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details - * - * You should have received a copy of the GNU Library General Public - * License along with this program; if not, write to the - * Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - */ - -import QtQuick 2.8 - -import QtQuick.Layouts 1.1 -import QtQuick.Controls 1.1 -import QtGraphicalEffects 1.0 - -import org.kde.plasma.core 2.0 as PlasmaCore -import org.kde.plasma.components 2.0 as PlasmaComponents -import org.kde.plasma.extras 2.0 as PlasmaExtras - -import "components" - -PlasmaCore.ColorScope { + SPDX-FileCopyrightText: 2016 David Edmundson <davidedmundson@kde.org> + + SPDX-License-Identifier: LGPL-2.0-or-later +*/ + +import QtQuick 2.15 +import QtQuick.Layouts 1.15 +import QtQuick.Controls 2.15 as QQC2 +import Qt5Compat.GraphicalEffects + +import org.kde.plasma.components 3.0 as PlasmaComponents3 +import org.kde.plasma.private.keyboardindicator as KeyboardIndicator +import org.kde.kirigami 2.20 as Kirigami + +import org.kde.breeze.components + +Item { id: root // If we're using software rendering, draw outlines instead of shadows // See https://bugs.kde.org/show_bug.cgi?id=398317 readonly property bool softwareRendering: GraphicsInfo.api === GraphicsInfo.Software - colorGroup: PlasmaCore.Theme.ComplementaryColorGroup + Kirigami.Theme.colorSet: Kirigami.Theme.Complementary + Kirigami.Theme.inherit: false width: 1600 height: 900 @@ -46,10 +33,9 @@ PlasmaCore.ColorScope { LayoutMirroring.enabled: Qt.application.layoutDirection === Qt.RightToLeft LayoutMirroring.childrenInherit: true - PlasmaCore.DataSource { - id: keystateSource - engine: "keystate" - connectedSources: "Caps Lock" + KeyboardIndicator.KeyState { + id: capsLockState + key: Qt.Key_CapsLock } Item { @@ -67,6 +53,11 @@ PlasmaCore.ColorScope { } } + RejectPasswordAnimation { + id: rejectPasswordAnimation + target: mainStack + } + MouseArea { id: loginScreenRoot anchors.fill: parent @@ -94,7 +85,7 @@ PlasmaCore.ColorScope { } } - Keys.onPressed: { + Keys.onPressed: event => { uiVisible = true; event.accepted = false; } @@ -106,6 +97,7 @@ PlasmaCore.ColorScope { interval: 60000 onTriggered: { if (!loginScreenRoot.blockUI) { + userListComponent.mainPasswordBox.showPassword = false; loginScreenRoot.uiVisible = false; } } @@ -125,15 +117,13 @@ PlasmaCore.ColorScope { anchors.fill: clock source: clock visible: !softwareRendering - horizontalOffset: 1 - verticalOffset: 1 radius: 6 samples: 14 spread: 0.3 - color: "black" // matches Breeze window decoration and desktopcontainment + color : "black" // shadows should always be black Behavior on opacity { OpacityAnimator { - duration: 1000 + duration: Kirigami.Units.veryLongDuration * 2 easing.type: Easing.InOutQuad } } @@ -141,20 +131,27 @@ PlasmaCore.ColorScope { Clock { id: clock - visible: y > 0 property Item shadow: clockShadow - y: (userListComponent.userList.y + mainStack.y)/2 - height/2 + visible: y > 0 anchors.horizontalCenter: parent.horizontalCenter + y: (userListComponent.userList.y + mainStack.y)/2 - height/2 + Layout.alignment: Qt.AlignBaseline } - - StackView { + QQC2.StackView { id: mainStack anchors { left: parent.left right: parent.right } - height: root.height + units.gridUnit * 3 + height: root.height + Kirigami.Units.gridUnit * 3 + + // If true (depends on the style and environment variables), hover events are always accepted + // and propagation stopped. This means the parent MouseArea won't get them and the UI won't be shown. + // Disable capturing those events while the UI is hidden to avoid that, while still passing events otherwise. + // One issue is that while the UI is visible, mouse activity won't keep resetting the timer, but when it + // finally expires, the next event should immediately set uiVisible = true again. + hoverEnabled: loginScreenRoot.uiVisible ? undefined : false focus: true //StackView is an implicit focus scope, so we need to give this focus so the item inside will have it @@ -170,64 +167,69 @@ PlasmaCore.ColorScope { } initialItem: Login { - id: userListComponent - userListModel: userModel - userListCurrentIndex: userModel.lastIndex >= 0 ? userModel.lastIndex : 0 - lastUserName: userModel.lastUser - - usernameFontSize: root.generalFontSize - usernameFontColor: root.generalFontColor - - showUserList: { - if ( !userListModel.hasOwnProperty("count") - || !userListModel.hasOwnProperty("disableAvatarsThreshold")) - return (userList.y + mainStack.y) > 0 - - if ( userListModel.count == 0 ) return false - - return userListModel.count <= userListModel.disableAvatarsThreshold && (userList.y + mainStack.y) > 0 - } + id: userListComponent + userListModel: userModel + loginScreenUiVisible: loginScreenRoot.uiVisible + userListCurrentIndex: userModel.lastIndex >= 0 ? userModel.lastIndex : 0 + lastUserName: userModel.lastUser + showUserList: { + if (!userListModel.hasOwnProperty("count") + || !userListModel.hasOwnProperty("disableAvatarsThreshold")) { + return false + } + + if (userListModel.count === 0 ) { + return false + } + + if (userListModel.hasOwnProperty("containsAllUsers") && !userListModel.containsAllUsers) { + return false + } - notificationMessage: { - var text = "" - if (keystateSource.data["Caps Lock"]["Locked"]) { - text += i18nd("plasma_lookandfeel_org.kde.lookandfeel","Caps Lock is on") + return userListModel.count <= userListModel.disableAvatarsThreshold + } + + notificationMessage: { + const parts = []; + if (capsLockState.locked) { + parts.push(i18nd("plasma-desktop-sddm-theme", "Caps Lock is on")); + } if (root.notificationMessage) { - text += " • " + parts.push(root.notificationMessage); } + return parts.join(" • "); } - text += root.notificationMessage - return text - } + actionItemsVisible: !inputPanel.keyboardActive actionItems: [ ActionButton { - iconSource: "/usr/share/sddm/themes/redcore/assets/suspend_primary.svgz" - text: i18ndc("plasma_lookandfeel_org.kde.lookandfeel","Suspend to RAM","Sleep") + iconSource: "system-suspend" + text: i18ndc("plasma-desktop-sddm-theme", "Suspend to RAM", "Sleep") + fontSize: Kirigami.Theme.defaultFont.pointSize + 1 onClicked: sddm.suspend() enabled: sddm.canSuspend - visible: !inputPanel.keyboardActive }, ActionButton { - iconSource: "/usr/share/sddm/themes/redcore/assets/restart_primary.svgz" - text: i18nd("plasma_lookandfeel_org.kde.lookandfeel","Restart") + iconSource: "system-reboot" + text: i18nd("plasma-desktop-sddm-theme", "Restart") + fontSize: Kirigami.Theme.defaultFont.pointSize + 1 onClicked: sddm.reboot() enabled: sddm.canReboot - visible: !inputPanel.keyboardActive }, ActionButton { - iconSource: "/usr/share/sddm/themes/redcore/assets/shutdown_primary.svgz" - text: i18nd("plasma_lookandfeel_org.kde.lookandfeel","Shut Down") + iconSource: "system-shutdown" + text: i18nd("plasma-desktop-sddm-theme", "Shut Down") + fontSize: Kirigami.Theme.defaultFont.pointSize + 1 onClicked: sddm.powerOff() enabled: sddm.canPowerOff - visible: !inputPanel.keyboardActive }, ActionButton { - iconSource: "/usr/share/sddm/themes/redcore/assets/switch_primary.svgz" - text: i18ndc("plasma_lookandfeel_org.kde.lookandfeel", "For switching to a username and password prompt", "Other...") + iconSource: "system-user-prompt" + text: i18ndc("plasma-desktop-sddm-theme", "For switching to a username and password prompt", "Other…") + fontSize: Kirigami.Theme.defaultFont.pointSize + 1 onClicked: mainStack.push(userPromptComponent) enabled: true - visible: !userListComponent.showUsernamePrompt && !inputPanel.keyboardActive + visible: !userListComponent.showUsernamePrompt }] onLoginRequest: { @@ -238,139 +240,102 @@ PlasmaCore.ColorScope { Behavior on opacity { OpacityAnimator { - duration: units.longDuration + duration: Kirigami.Units.longDuration } } - } - Loader { - id: inputPanel - state: "hidden" - property bool keyboardActive: item ? item.active : false - onKeyboardActiveChanged: { - if (keyboardActive) { - state = "visible" - } else { - state = "hidden"; + readonly property real zoomFactor: 1.5 + + popEnter: Transition { + ScaleAnimator { + from: mainStack.zoomFactor + to: 1 + duration: Kirigami.Units.veryLongDuration + easing.type: Easing.OutCubic + } + OpacityAnimator { + from: 0 + to: 1 + duration: Kirigami.Units.veryLongDuration + easing.type: Easing.OutCubic } } - source: "components/VirtualKeyboard.qml" - anchors { - left: parent.left - right: parent.right + + popExit: Transition { + ScaleAnimator { + from: 1 + to: 1 / mainStack.zoomFactor + duration: Kirigami.Units.veryLongDuration + easing.type: Easing.OutCubic + } + OpacityAnimator { + from: 1 + to: 0 + duration: Kirigami.Units.veryLongDuration + easing.type: Easing.OutCubic + } } - function showHide() { - state = state == "hidden" ? "visible" : "hidden"; + pushEnter: Transition { + ScaleAnimator { + from: 1 / mainStack.zoomFactor + to: 1 + duration: Kirigami.Units.veryLongDuration + easing.type: Easing.OutCubic + } + OpacityAnimator { + from: 0 + to: 1 + duration: Kirigami.Units.veryLongDuration + easing.type: Easing.OutCubic + } } - states: [ - State { - name: "visible" - PropertyChanges { - target: mainStack - y: Math.min(0, root.height - inputPanel.height - userListComponent.visibleBoundary) - } - PropertyChanges { - target: inputPanel - y: root.height - inputPanel.height - opacity: 1 - } - }, - State { - name: "hidden" - PropertyChanges { - target: mainStack - y: 0 - } - PropertyChanges { - target: inputPanel - y: root.height - root.height/4 - opacity: 0 - } + pushExit: Transition { + ScaleAnimator { + from: 1 + to: mainStack.zoomFactor + duration: Kirigami.Units.veryLongDuration + easing.type: Easing.OutCubic } - ] - transitions: [ - Transition { - from: "hidden" - to: "visible" - SequentialAnimation { - ScriptAction { - script: { - inputPanel.item.activated = true; - Qt.inputMethod.show(); - } - } - ParallelAnimation { - NumberAnimation { - target: mainStack - property: "y" - duration: units.longDuration - easing.type: Easing.InOutQuad - } - NumberAnimation { - target: inputPanel - property: "y" - duration: units.longDuration - easing.type: Easing.OutQuad - } - OpacityAnimator { - target: inputPanel - duration: units.longDuration - easing.type: Easing.OutQuad - } - } - } - }, - Transition { - from: "visible" - to: "hidden" - SequentialAnimation { - ParallelAnimation { - NumberAnimation { - target: mainStack - property: "y" - duration: units.longDuration - easing.type: Easing.InOutQuad - } - NumberAnimation { - target: inputPanel - property: "y" - duration: units.longDuration - easing.type: Easing.InQuad - } - OpacityAnimator { - target: inputPanel - duration: units.longDuration - easing.type: Easing.InQuad - } - } - ScriptAction { - script: { - Qt.inputMethod.hide(); - } - } - } + OpacityAnimator { + from: 1 + to: 0 + duration: Kirigami.Units.veryLongDuration + easing.type: Easing.OutCubic } - ] + } } + VirtualKeyboardLoader { + id: inputPanel + + z: 1 + + screenRoot: root + mainStack: mainStack + mainBlock: userListComponent + passwordField: userListComponent.mainPasswordBox + } Component { id: userPromptComponent Login { showUsernamePrompt: true notificationMessage: root.notificationMessage + loginScreenUiVisible: loginScreenRoot.uiVisible + fontSize: Kirigami.Theme.defaultFont.pointSize + 2 // using a model rather than a QObject list to avoid QTBUG-75900 userListModel: ListModel { ListElement { name: "" - iconSource: "" + icon: "" } Component.onCompleted: { // as we can't bind inside ListElement - setProperty(0, "name", i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Type in Username and Password")); + setProperty(0, "name", i18nd("plasma-desktop-sddm-theme", "Type in Username and Password")); + setProperty(0, "icon", Qt.resolvedUrl("faces/.face.icon")) } } @@ -379,86 +344,180 @@ PlasmaCore.ColorScope { sddm.login(username, password, sessionButton.currentIndex) } + actionItemsVisible: !inputPanel.keyboardActive actionItems: [ ActionButton { - iconSource: "/usr/share/sddm/themes/redcore/assets/suspend_primary.svgz" - text: i18ndc("plasma_lookandfeel_org.kde.lookandfeel","Suspend to RAM","Sleep") + iconSource: "system-suspend" + text: i18ndc("plasma-desktop-sddm-theme", "Suspend to RAM", "Sleep") + fontSize: Kirigami.Theme.defaultFont.pointSize + 1 onClicked: sddm.suspend() enabled: sddm.canSuspend - visible: !inputPanel.keyboardActive }, ActionButton { - iconSource: "/usr/share/sddm/themes/redcore/assets/restart_primary.svgz" - text: i18nd("plasma_lookandfeel_org.kde.lookandfeel","Restart") + iconSource: "system-reboot" + text: i18nd("plasma-desktop-sddm-theme", "Restart") + fontSize: Kirigami.Theme.defaultFont.pointSize + 1 onClicked: sddm.reboot() enabled: sddm.canReboot - visible: !inputPanel.keyboardActive }, ActionButton { - iconSource: "/usr/share/sddm/themes/redcore/assets/shutdown_primary.svgz" - text: i18nd("plasma_lookandfeel_org.kde.lookandfeel","Shut Down") + iconSource: "system-shutdown" + text: i18nd("plasma-desktop-sddm-theme", "Shut Down") + fontSize: Kirigami.Theme.defaultFont.pointSize + 1 onClicked: sddm.powerOff() enabled: sddm.canPowerOff - visible: !inputPanel.keyboardActive }, ActionButton { - iconSource: "/usr/share/sddm/themes/redcore/assets/switch_primary.svgz" - text: i18nd("plasma_lookandfeel_org.kde.lookandfeel","List Users") + iconSource: "system-user-list" + text: i18nd("plasma-desktop-sddm-theme", "List Users") + fontSize: Kirigami.Theme.defaultFont.pointSize + 1 onClicked: mainStack.pop() - visible: !inputPanel.keyboardActive } ] } } - //Footer + DropShadow { + id: logoShadow + anchors.fill: logo + source: logo + visible: !softwareRendering && config.showlogo === "shown" + horizontalOffset: 1 + verticalOffset: 1 + radius: 6 + samples: 14 + spread: 0.3 + color : "black" // shadows should always be black + opacity: loginScreenRoot.uiVisible ? 0 : 1 + Behavior on opacity { + //OpacityAnimator when starting from 0 is buggy (it shows one frame with opacity 1)" + NumberAnimation { + duration: Kirigami.Units.longDuration + easing.type: Easing.InOutQuad + } + } + } + + Image { + id: logo + visible: config.showlogo === "shown" + source: config.logo + anchors.horizontalCenter: parent.horizontalCenter + anchors.bottom: footer.top + anchors.bottomMargin: Kirigami.Units.largeSpacing + asynchronous: true + sourceSize.height: height + opacity: loginScreenRoot.uiVisible ? 0 : 1 + fillMode: Image.PreserveAspectFit + height: Math.round(Kirigami.Units.gridUnit * 3.5) + Behavior on opacity { + // OpacityAnimator when starting from 0 is buggy (it shows one frame with opacity 1)" + NumberAnimation { + duration: Kirigami.Units.longDuration + easing.type: Easing.InOutQuad + } + } + } + + // Note: Containment masks stretch clickable area of their buttons to + // the screen edges, essentially making them adhere to Fitts's law. + // Due to virtual keyboard button having an icon, buttons may have + // different heights, so fillHeight is required. + // + // Note for contributors: Keep this in sync with LockScreenUi.qml footer. RowLayout { id: footer anchors { bottom: parent.bottom left: parent.left right: parent.right - margins: units.smallSpacing + margins: Kirigami.Units.smallSpacing } + spacing: Kirigami.Units.smallSpacing Behavior on opacity { OpacityAnimator { - duration: units.longDuration + duration: Kirigami.Units.longDuration } } - PlasmaComponents.ToolButton { - text: i18ndc("plasma_lookandfeel_org.kde.lookandfeel", "Button to show/hide virtual keyboard", "Virtual Keyboard") - font.pointSize: config.fontSize - iconName: inputPanel.keyboardActive ? "input-keyboard-virtual-on" : "input-keyboard-virtual-off" - onClicked: inputPanel.showHide() - visible: inputPanel.status == Loader.Ready + PlasmaComponents3.ToolButton { + id: virtualKeyboardButton + + text: i18ndc("plasma-desktop-sddm-theme", "Button to show/hide virtual keyboard", "Virtual Keyboard") + icon.name: inputPanel.keyboardActive ? "input-keyboard-virtual-on" : "input-keyboard-virtual-off" + onClicked: { + // Otherwise the password field loses focus and virtual keyboard + // keystrokes get eaten + userListComponent.mainPasswordBox.forceActiveFocus(); + inputPanel.showHide() + } + visible: inputPanel.status === Loader.Ready + + Layout.fillHeight: true + containmentMask: Item { + parent: virtualKeyboardButton + anchors.fill: parent + anchors.leftMargin: -footer.anchors.margins + anchors.bottomMargin: -footer.anchors.margins + } } KeyboardButton { + id: keyboardButton + + onKeyboardLayoutChanged: { + // Otherwise the password field loses focus and virtual keyboard + // keystrokes get eaten + userListComponent.mainPasswordBox.forceActiveFocus(); + } + + Layout.fillHeight: true + containmentMask: Item { + parent: keyboardButton + anchors.fill: parent + anchors.leftMargin: virtualKeyboardButton.visible ? 0 : -footer.anchors.margins + anchors.bottomMargin: -footer.anchors.margins + } } SessionButton { id: sessionButton + + onSessionChanged: { + // Otherwise the password field loses focus and virtual keyboard + // keystrokes get eaten + userListComponent.mainPasswordBox.forceActiveFocus(); + } + + Layout.fillHeight: true + containmentMask: Item { + parent: sessionButton + anchors.fill: parent + anchors.leftMargin: virtualKeyboardButton.visible || keyboardButton.visible + ? 0 : -footer.anchors.margins + anchors.bottomMargin: -footer.anchors.margins + } } Item { Layout.fillWidth: true } - Battery { } + Battery {} } } Connections { target: sddm - onLoginFailed: { - notificationMessage = i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Login Failed") + function onLoginFailed() { + notificationMessage = i18nd("plasma-desktop-sddm-theme", "Login Failed") footer.enabled = true mainStack.enabled = true userListComponent.userList.opacity = 1 + rejectPasswordAnimation.start() } - onLoginSucceeded: { + function onLoginSucceeded() { //note SDDM will kill the greeter at some random point after this //there is no certainty any transition will finish, it depends on the time it //takes to complete the init diff --git a/x11-themes/redcore-theme-sddm/files/redcore/Messages.sh b/x11-themes/redcore-theme-sddm/files/redcore/Messages.sh new file mode 100644 index 00000000..1ded812a --- /dev/null +++ b/x11-themes/redcore-theme-sddm/files/redcore/Messages.sh @@ -0,0 +1,2 @@ +#! /usr/bin/env bash +$XGETTEXT `find . -name \*.qml` -L Java -o $podir/plasma-desktop-sddm-theme.pot diff --git a/x11-themes/redcore-theme-sddm/files/redcore/SessionButton.qml b/x11-themes/redcore-theme-sddm/files/redcore/SessionButton.qml index 58590c83..ad387b51 100644 --- a/x11-themes/redcore-theme-sddm/files/redcore/SessionButton.qml +++ b/x11-themes/redcore-theme-sddm/files/redcore/SessionButton.qml @@ -1,57 +1,53 @@ /* - * Copyright 2016 David Edmundson <davidedmundson@kde.org> - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU Library General Public License as - * published by the Free Software Foundation; either version 2 or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details - * - * You should have received a copy of the GNU Library General Public - * License along with this program; if not, write to the - * Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - */ - -import QtQuick 2.2 - -import org.kde.plasma.core 2.0 as PlasmaCore -import org.kde.plasma.components 2.0 as PlasmaComponents - -import QtQuick.Controls 1.3 as QQC + SPDX-FileCopyrightText: 2016 David Edmundson <davidedmundson@kde.org> + SPDX-FileCopyrightText: 2022 Aleix Pol Gonzalez <aleixpol@kde.org> -PlasmaComponents.ToolButton { - id: root - property int currentIndex: -1 + SPDX-License-Identifier: LGPL-2.0-or-later +*/ - implicitWidth: minimumWidth +import QtQuick 2.15 - visible: menu.items.length > 1 +import org.kde.plasma.components 3.0 as PlasmaComponents +import org.kde.kirigami 2.20 as Kirigami - text: i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Desktop Session: %1", instantiator.objectAt(currentIndex).text || "") +PlasmaComponents.ToolButton { + id: root - font.pointSize: config.fontSize + property int currentIndex: -1 + + text: i18nd("plasma-desktop-sddm-theme", "Desktop Session: %1", instantiator.objectAt(currentIndex).text || "") + visible: menu.count > 1 Component.onCompleted: { currentIndex = sessionModel.lastIndex } + checkable: true + checked: menu.opened + onToggled: { + if (checked) { + menu.popup(root, 0, 0) + } else { + menu.dismiss() + } + } + + signal sessionChanged() + + PlasmaComponents.Menu { + Kirigami.Theme.colorSet: Kirigami.Theme.Window + Kirigami.Theme.inherit: false - menu: QQC.Menu { id: menu - style: BreezeMenuStyle {} Instantiator { id: instantiator model: sessionModel - onObjectAdded: menu.insertItem(index, object) - onObjectRemoved: menu.removeItem( object ) - delegate: QQC.MenuItem { + onObjectAdded: (index, object) => menu.insertItem(index, object) + onObjectRemoved: (index, object) => menu.removeItem(object) + delegate: PlasmaComponents.MenuItem { text: model.name onTriggered: { root.currentIndex = model.index + sessionChanged() } } } diff --git a/x11-themes/redcore-theme-sddm/files/redcore/assets/login.svgz b/x11-themes/redcore-theme-sddm/files/redcore/assets/login.svgz Binary files differdeleted file mode 100644 index a1b005b6..00000000 --- a/x11-themes/redcore-theme-sddm/files/redcore/assets/login.svgz +++ /dev/null diff --git a/x11-themes/redcore-theme-sddm/files/redcore/assets/logout_primary.svgz b/x11-themes/redcore-theme-sddm/files/redcore/assets/logout_primary.svgz Binary files differdeleted file mode 100644 index fd83ef02..00000000 --- a/x11-themes/redcore-theme-sddm/files/redcore/assets/logout_primary.svgz +++ /dev/null diff --git a/x11-themes/redcore-theme-sddm/files/redcore/assets/restart_primary.svgz b/x11-themes/redcore-theme-sddm/files/redcore/assets/restart_primary.svgz Binary files differdeleted file mode 100644 index e749f9b3..00000000 --- a/x11-themes/redcore-theme-sddm/files/redcore/assets/restart_primary.svgz +++ /dev/null diff --git a/x11-themes/redcore-theme-sddm/files/redcore/assets/shutdown_primary.svgz b/x11-themes/redcore-theme-sddm/files/redcore/assets/shutdown_primary.svgz Binary files differdeleted file mode 100644 index 03592da9..00000000 --- a/x11-themes/redcore-theme-sddm/files/redcore/assets/shutdown_primary.svgz +++ /dev/null diff --git a/x11-themes/redcore-theme-sddm/files/redcore/assets/suspend_primary.svgz b/x11-themes/redcore-theme-sddm/files/redcore/assets/suspend_primary.svgz Binary files differdeleted file mode 100644 index 6bbf63c9..00000000 --- a/x11-themes/redcore-theme-sddm/files/redcore/assets/suspend_primary.svgz +++ /dev/null diff --git a/x11-themes/redcore-theme-sddm/files/redcore/assets/switch_primary.svgz b/x11-themes/redcore-theme-sddm/files/redcore/assets/switch_primary.svgz Binary files differdeleted file mode 100644 index 5f344258..00000000 --- a/x11-themes/redcore-theme-sddm/files/redcore/assets/switch_primary.svgz +++ /dev/null diff --git a/x11-themes/redcore-theme-sddm/files/redcore/background.jpg b/x11-themes/redcore-theme-sddm/files/redcore/background.jpg Binary files differdeleted file mode 100644 index 2b07c0d8..00000000 --- a/x11-themes/redcore-theme-sddm/files/redcore/background.jpg +++ /dev/null diff --git a/x11-themes/redcore-theme-sddm/files/redcore/background.png b/x11-themes/redcore-theme-sddm/files/redcore/background.png Binary files differnew file mode 100644 index 00000000..196752c8 --- /dev/null +++ b/x11-themes/redcore-theme-sddm/files/redcore/background.png diff --git a/x11-themes/redcore-theme-sddm/files/redcore/components/ActionButton.qml b/x11-themes/redcore-theme-sddm/files/redcore/components/ActionButton.qml deleted file mode 100644 index 9fbd2a8a..00000000 --- a/x11-themes/redcore-theme-sddm/files/redcore/components/ActionButton.qml +++ /dev/null @@ -1,128 +0,0 @@ -/* - * Copyright 2016 David Edmundson <davidedmundson@kde.org> - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU Library General Public License as - * published by the Free Software Foundation; either version 2 or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details - * - * You should have received a copy of the GNU Library General Public - * License along with this program; if not, write to the - * Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - */ - -import QtQuick 2.8 -import org.kde.plasma.core 2.0 as PlasmaCore -import org.kde.plasma.components 2.0 as PlasmaComponents - -Item { - id: root - property alias text: label.text - property alias iconSource: icon.source - property alias containsMouse: mouseArea.containsMouse - property alias font: label.font - property alias labelRendering: label.renderType - property alias circleOpacity: iconCircle.opacity - property alias circleVisiblity: iconCircle.visible - property int fontSize: config.fontSize - readonly property bool softwareRendering: GraphicsInfo.api === GraphicsInfo.Software - signal clicked - - activeFocusOnTab: true - - property int iconSize: units.gridUnit * 3 - - implicitWidth: Math.max(iconSize + units.largeSpacing * 2, label.contentWidth) - implicitHeight: iconSize + units.smallSpacing + label.implicitHeight - - opacity: activeFocus || containsMouse ? 1 : 0.85 - Behavior on opacity { - PropertyAnimation { // OpacityAnimator makes it turn black at random intervals - duration: units.longDuration * 2 - easing.type: Easing.InOutQuad - } - } - - Rectangle { - id: iconCircle - anchors.centerIn: icon - width: iconSize + units.smallSpacing - height: width - radius: width / 2 - color: softwareRendering ? PlasmaCore.ColorScope.backgroundColor : PlasmaCore.ColorScope.textColor - opacity: activeFocus || containsMouse ? (softwareRendering ? 0.8 : 0.15) : (softwareRendering ? 0.6 : 0) - Behavior on opacity { - PropertyAnimation { // OpacityAnimator makes it turn black at random intervals - duration: units.longDuration * 3 - easing.type: Easing.InOutQuad - } - } - } - - Rectangle { - anchors.centerIn: iconCircle - width: iconCircle.width - height: width - radius: width / 2 - scale: mouseArea.containsPress ? 1 : 0 - color: PlasmaCore.ColorScope.textColor - opacity: 0.15 - Behavior on scale { - PropertyAnimation { - duration: units.shortDuration - easing.type: Easing.InOutQuart - } - } - } - - PlasmaCore.IconItem { - id: icon - anchors { - top: parent.top - horizontalCenter: parent.horizontalCenter - } - width: iconSize - height: iconSize - - colorGroup: PlasmaCore.ColorScope.colorGroup - active: mouseArea.containsMouse || root.activeFocus - } - - PlasmaComponents.Label { - id: label - font.pointSize: Math.max(fontSize + 1,theme.defaultFont.pointSize + 1) - anchors { - top: icon.bottom - topMargin: (softwareRendering ? 1.5 : 1) * units.smallSpacing - left: parent.left - right: parent.right - } - style: softwareRendering ? Text.Outline : Text.Normal - styleColor: softwareRendering ? PlasmaCore.ColorScope.backgroundColor : "transparent" //no outline, doesn't matter - horizontalAlignment: Text.AlignHCenter - verticalAlignment: Text.AlignTop - wrapMode: Text.WordWrap - font.underline: root.activeFocus - } - - MouseArea { - id: mouseArea - hoverEnabled: true - onClicked: root.clicked() - anchors.fill: parent - } - - Keys.onEnterPressed: clicked() - Keys.onReturnPressed: clicked() - Keys.onSpacePressed: clicked() - - Accessible.onPressAction: clicked() - Accessible.role: Accessible.Button - Accessible.name: label.text -} diff --git a/x11-themes/redcore-theme-sddm/files/redcore/components/Battery.qml b/x11-themes/redcore-theme-sddm/files/redcore/components/Battery.qml deleted file mode 100644 index 2351c4de..00000000 --- a/x11-themes/redcore-theme-sddm/files/redcore/components/Battery.qml +++ /dev/null @@ -1,53 +0,0 @@ -/* - * Copyright 2016 Kai Uwe Broulik <kde@privat.broulik.de> - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU Library General Public License as - * published by the Free Software Foundation; either version 2 or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details - * - * You should have received a copy of the GNU Library General Public - * License along with this program; if not, write to the - * Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - */ - -import QtQuick 2.2 - -import org.kde.plasma.core 2.0 as PlasmaCore -import org.kde.plasma.components 2.0 as PlasmaComponents -import org.kde.plasma.workspace.components 2.0 as PW - -Row { - spacing: units.smallSpacing - visible: pmSource.data["Battery"]["Has Cumulative"] - - PlasmaCore.DataSource { - id: pmSource - engine: "powermanagement" - connectedSources: ["Battery", "AC Adapter"] - } - - PW.BatteryIcon { - id: battery - hasBattery: pmSource.data["Battery"]["Has Battery"] || false - percent: pmSource.data["Battery"]["Percent"] || 0 - pluggedIn: pmSource.data["AC Adapter"] ? pmSource.data["AC Adapter"]["Plugged in"] : false - - height: batteryLabel.height - width: height - } - - PlasmaComponents.Label { - id: batteryLabel - font.pointSize: config.fontSize - height: undefined - text: i18nd("plasma_lookandfeel_org.kde.lookandfeel","%1%", battery.percent) - Accessible.name: i18nd("plasma_lookandfeel_org.kde.lookandfeel","Battery at %1%", battery.percent) - } -} diff --git a/x11-themes/redcore-theme-sddm/files/redcore/components/Clock.qml b/x11-themes/redcore-theme-sddm/files/redcore/components/Clock.qml deleted file mode 100644 index 6e26055c..00000000 --- a/x11-themes/redcore-theme-sddm/files/redcore/components/Clock.qml +++ /dev/null @@ -1,50 +0,0 @@ -/* - * Copyright 2016 David Edmundson <davidedmundson@kde.org> - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU Library General Public License as - * published by the Free Software Foundation; either version 2 or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details - * - * You should have received a copy of the GNU Library General Public - * License along with this program; if not, write to the - * Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - */ - -import QtQuick 2.8 -import QtQuick.Layouts 1.1 -import QtQuick.Controls 1.1 -import org.kde.plasma.core 2.0 - -ColumnLayout { - readonly property bool softwareRendering: GraphicsInfo.api === GraphicsInfo.Software - - Label { - text: Qt.formatTime(timeSource.data["Local"]["DateTime"]) - color: ColorScope.textColor - style: softwareRendering ? Text.Outline : Text.Normal - styleColor: softwareRendering ? ColorScope.backgroundColor : "transparent" //no outline, doesn't matter - font.pointSize: 48 - Layout.alignment: Qt.AlignHCenter - } - Label { - text: Qt.formatDate(timeSource.data["Local"]["DateTime"], Qt.DefaultLocaleLongDate) - color: ColorScope.textColor - style: softwareRendering ? Text.Outline : Text.Normal - styleColor: softwareRendering ? ColorScope.backgroundColor : "transparent" //no outline, doesn't matter - font.pointSize: 24 - Layout.alignment: Qt.AlignHCenter - } - DataSource { - id: timeSource - engine: "time" - connectedSources: ["Local"] - interval: 1000 - } -} diff --git a/x11-themes/redcore-theme-sddm/files/redcore/components/KeyboardLayoutButton.qml b/x11-themes/redcore-theme-sddm/files/redcore/components/KeyboardLayoutButton.qml deleted file mode 100644 index 32edb528..00000000 --- a/x11-themes/redcore-theme-sddm/files/redcore/components/KeyboardLayoutButton.qml +++ /dev/null @@ -1,52 +0,0 @@ -/*************************************************************************** - * Copyright (C) 2014 by Daniel Vrátil <dvratil@redhat.com> * - * * - * This program is free software; you can redistribute it and/or modify * - * it under the terms of the GNU General Public License as published by * - * the Free Software Foundation; either version 2 of the License, or * - * (at your option) any later version. * - * * - * This program is distributed in the hope that it will be useful, * - * but WITHOUT ANY WARRANTY; without even the implied warranty of * - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * - * GNU General Public License for more details. * - * * - * You should have received a copy of the GNU General Public License * - * along with this program; if not, write to the * - * Free Software Foundation, Inc., * - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA . * - ***************************************************************************/ - -import QtQuick 2.1 -import QtQuick.Controls 1.1 as QQC - -import org.kde.plasma.components 2.0 as PlasmaComponents - -import org.kde.plasma.workspace.keyboardlayout 1.0 - -PlasmaComponents.ToolButton { - - property int fontSize: config.fontSize - - id: kbLayoutButton - - iconName: "input-keyboard" - implicitWidth: minimumWidth - text: layout.currentLayoutDisplayName - font.pointSize: Math.max(fontSize,theme.defaultFont.pointSize) - - Accessible.name: i18ndc("plasma_lookandfeel_org.kde.lookandfeel", "Button to change keyboard layout", "Switch layout") - - visible: layout.layouts.length > 1 - - onClicked: layout.nextLayout() - - KeyboardLayout { - id: layout - function nextLayout() { - var layouts = layout.layouts; - var index = (layouts.indexOf(layout.currentLayout)+1) % layouts.length; - layout.currentLayout = layouts[index]; - } - } -} diff --git a/x11-themes/redcore-theme-sddm/files/redcore/components/SessionManagementScreen.qml b/x11-themes/redcore-theme-sddm/files/redcore/components/SessionManagementScreen.qml deleted file mode 100644 index 5f882604..00000000 --- a/x11-themes/redcore-theme-sddm/files/redcore/components/SessionManagementScreen.qml +++ /dev/null @@ -1,121 +0,0 @@ -/* - * Copyright 2016 David Edmundson <davidedmundson@kde.org> - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU Library General Public License as - * published by the Free Software Foundation; either version 2 or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details - * - * You should have received a copy of the GNU Library General Public - * License along with this program; if not, write to the - * Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - */ - -import QtQuick 2.2 - -import QtQuick.Layouts 1.1 -import QtQuick.Controls 1.1 - -import org.kde.plasma.core 2.0 as PlasmaCore -import org.kde.plasma.components 2.0 as PlasmaComponents - -Item { - id: root - - /* - * Any message to be displayed to the user, visible above the text fields - */ - property alias notificationMessage: notificationsLabel.text - - /* - * A list of Items (typically ActionButtons) to be shown in a Row beneath the prompts - */ - property alias actionItems: actionItemsLayout.children - - /* - * A model with a list of users to show in the view - * The following roles should exist: - * - name - * - iconSource - * - * The following are also handled: - * - vtNumber - * - displayNumber - * - session - * - isTty - */ - property alias userListModel: userListView.model - - /* - * Self explanatory - */ - property alias userListCurrentIndex: userListView.currentIndex - property var userListCurrentModelData: userListView.currentItem === null ? [] : userListView.currentItem.m - property bool showUserList: true - - property alias userList: userListView - - property int fontSize: config.fontSize - - default property alias _children: innerLayout.children - - UserList { - id: userListView - visible: showUserList && y > 0 - anchors { - bottom: parent.verticalCenter - left: parent.left - right: parent.right - } - } - - //goal is to show the prompts, in ~16 grid units high, then the action buttons - //but collapse the space between the prompts and actions if there's no room - //ui is constrained to 16 grid units wide, or the screen - ColumnLayout { - id: prompts - anchors.top: parent.verticalCenter - anchors.topMargin: units.gridUnit * 0.5 - anchors.left: parent.left - anchors.right: parent.right - anchors.bottom: parent.bottom - PlasmaComponents.Label { - id: notificationsLabel - font.pointSize: Math.max(fontSize + 1,theme.defaultFont.pointSize + 1) - Layout.maximumWidth: units.gridUnit * 16 - Layout.alignment: Qt.AlignHCenter - Layout.fillWidth: true - horizontalAlignment: Text.AlignHCenter - wrapMode: Text.WordWrap - font.italic: true - } - ColumnLayout { - Layout.minimumHeight: implicitHeight - Layout.maximumHeight: units.gridUnit * 10 - Layout.maximumWidth: units.gridUnit * 16 - Layout.alignment: Qt.AlignHCenter - ColumnLayout { - id: innerLayout - Layout.alignment: Qt.AlignHCenter - Layout.fillWidth: true - } - Item { - Layout.fillHeight: true - } - } - Row { //deliberately not rowlayout as I'm not trying to resize child items - id: actionItemsLayout - spacing: units.largeSpacing / 2 - Layout.alignment: Qt.AlignHCenter - } - Item { - Layout.fillHeight: true - } - } -} diff --git a/x11-themes/redcore-theme-sddm/files/redcore/components/UserDelegate.qml b/x11-themes/redcore-theme-sddm/files/redcore/components/UserDelegate.qml deleted file mode 100644 index 960315df..00000000 --- a/x11-themes/redcore-theme-sddm/files/redcore/components/UserDelegate.qml +++ /dev/null @@ -1,190 +0,0 @@ -/* - * Copyright 2014 David Edmundson <davidedmundson@kde.org> - * Copyright 2014 Aleix Pol Gonzalez <aleixpol@blue-systems.com> - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU Library General Public License as - * published by the Free Software Foundation; either version 2 or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details - * - * You should have received a copy of the GNU Library General Public - * License along with this program; if not, write to the - * Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - */ - -import QtQuick 2.8 -import org.kde.plasma.core 2.0 as PlasmaCore -import org.kde.plasma.components 2.0 as PlasmaComponents - -Item { - id: wrapper - - // If we're using software rendering, draw outlines instead of shadows - // See https://bugs.kde.org/show_bug.cgi?id=398317 - readonly property bool softwareRendering: GraphicsInfo.api === GraphicsInfo.Software - - property bool isCurrent: true - - readonly property var m: model - property string name - property string userName - property string avatarPath - property string iconSource - property bool constrainText: true - property alias nameFontSize: usernameDelegate.font.pointSize - property int fontSize: config.fontSize - signal clicked() - - property real faceSize: Math.min(width, height - usernameDelegate.height - units.smallSpacing) - - opacity: isCurrent ? 1.0 : 0.5 - - Behavior on opacity { - OpacityAnimator { - duration: units.longDuration - } - } - - // Draw a translucent background circle under the user picture - Rectangle { - anchors.centerIn: imageSource - width: imageSource.width - 2 // Subtract to prevent fringing - height: width - radius: width / 2 - - color: PlasmaCore.ColorScope.backgroundColor - opacity: 0.6 - } - - Item { - id: imageSource - anchors { - bottom: usernameDelegate.top - bottomMargin: units.largeSpacing - horizontalCenter: parent.horizontalCenter - } - Behavior on width { - PropertyAnimation { - from: faceSize - duration: units.longDuration * 2; - } - } - width: isCurrent ? faceSize : faceSize - units.largeSpacing - height: width - - //Image takes priority, taking a full path to a file, if that doesn't exist we show an icon - Image { - id: face - source: wrapper.avatarPath - sourceSize: Qt.size(faceSize, faceSize) - fillMode: Image.PreserveAspectCrop - anchors.fill: parent - } - - PlasmaCore.IconItem { - id: faceIcon - source: iconSource - visible: (face.status == Image.Error || face.status == Image.Null) - anchors.fill: parent - anchors.margins: units.gridUnit * 0.5 // because mockup says so... - colorGroup: PlasmaCore.ColorScope.colorGroup - } - } - - ShaderEffect { - anchors { - bottom: usernameDelegate.top - bottomMargin: units.largeSpacing - horizontalCenter: parent.horizontalCenter - } - - width: imageSource.width - height: imageSource.height - - supportsAtlasTextures: true - - property var source: ShaderEffectSource { - sourceItem: imageSource - // software rendering is just a fallback so we can accept not having a rounded avatar here - hideSource: wrapper.GraphicsInfo.api !== GraphicsInfo.Software - live: true // otherwise the user in focus will show a blurred avatar - } - - property var colorBorder: PlasmaCore.ColorScope.textColor - - //draw a circle with an antialised border - //innerRadius = size of the inner circle with contents - //outerRadius = size of the border - //blend = area to blend between two colours - //all sizes are normalised so 0.5 == half the width of the texture - - //if copying into another project don't forget to connect themeChanged to update() - //but in SDDM that's a bit pointless - fragmentShader: " - varying highp vec2 qt_TexCoord0; - uniform highp float qt_Opacity; - uniform lowp sampler2D source; - - uniform lowp vec4 colorBorder; - highp float blend = 0.01; - highp float innerRadius = 0.47; - highp float outerRadius = 0.49; - lowp vec4 colorEmpty = vec4(0.0, 0.0, 0.0, 0.0); - - void main() { - lowp vec4 colorSource = texture2D(source, qt_TexCoord0.st); - - highp vec2 m = qt_TexCoord0 - vec2(0.5, 0.5); - highp float dist = sqrt(m.x * m.x + m.y * m.y); - - if (dist < innerRadius) - gl_FragColor = colorSource; - else if (dist < innerRadius + blend) - gl_FragColor = mix(colorSource, colorBorder, ((dist - innerRadius) / blend)); - else if (dist < outerRadius) - gl_FragColor = colorBorder; - else if (dist < outerRadius + blend) - gl_FragColor = mix(colorBorder, colorEmpty, ((dist - outerRadius) / blend)); - else - gl_FragColor = colorEmpty ; - - gl_FragColor = gl_FragColor * qt_Opacity; - } - " - } - - PlasmaComponents.Label { - id: usernameDelegate - font.pointSize: Math.max(fontSize + 2,theme.defaultFont.pointSize + 2) - anchors { - bottom: parent.bottom - horizontalCenter: parent.horizontalCenter - } - height: implicitHeight // work around stupid bug in Plasma Components that sets the height - width: constrainText ? parent.width : implicitWidth - text: wrapper.name - style: softwareRendering ? Text.Outline : Text.Normal - styleColor: softwareRendering ? PlasmaCore.ColorScope.backgroundColor : "transparent" //no outline, doesn't matter - elide: Text.ElideRight - horizontalAlignment: Text.AlignHCenter - //make an indication that this has active focus, this only happens when reached with keyboard navigation - font.underline: wrapper.activeFocus - } - - MouseArea { - anchors.fill: parent - hoverEnabled: true - - onClicked: wrapper.clicked(); - } - - Accessible.name: name - Accessible.role: Accessible.Button - function accessiblePressAction() { wrapper.clicked() } -} diff --git a/x11-themes/redcore-theme-sddm/files/redcore/components/UserList.qml b/x11-themes/redcore-theme-sddm/files/redcore/components/UserList.qml deleted file mode 100644 index a2d85088..00000000 --- a/x11-themes/redcore-theme-sddm/files/redcore/components/UserList.qml +++ /dev/null @@ -1,93 +0,0 @@ -/* - * Copyright 2014 David Edmundson <davidedmundson@kde.org> - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU Library General Public License as - * published by the Free Software Foundation; either version 2 or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details - * - * You should have received a copy of the GNU Library General Public - * License along with this program; if not, write to the - * Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - */ - -import QtQuick 2.2 - -ListView { - id: view - readonly property string selectedUser: currentItem ? currentItem.userName : "" - readonly property int userItemWidth: units.gridUnit * 8 - readonly property int userItemHeight: units.gridUnit * 8 - - implicitHeight: userItemHeight - - activeFocusOnTab : true - - /* - * Signals that a user was explicitly selected - */ - signal userSelected; - - orientation: ListView.Horizontal - highlightRangeMode: ListView.StrictlyEnforceRange - - //centre align selected item (which implicitly centre aligns the rest - preferredHighlightBegin: width/2 - userItemWidth/2 - preferredHighlightEnd: preferredHighlightBegin - - delegate: UserDelegate { - avatarPath: model.icon || "" - iconSource: model.iconName || "user-identity" - - name: { - var displayName = model.realName || model.name - - if (model.vtNumber === undefined || model.vtNumber < 0) { - return displayName - } - - if (!model.session) { - return i18ndc("plasma_lookandfeel_org.kde.lookandfeel", "Nobody logged in on that session", "Unused") - } - - - var location = "" - if (model.isTty) { - location = i18ndc("plasma_lookandfeel_org.kde.lookandfeel", "User logged in on console number", "TTY %1", model.vtNumber) - } else if (model.displayNumber) { - location = i18ndc("plasma_lookandfeel_org.kde.lookandfeel", "User logged in on console (X display number)", "on TTY %1 (Display %2)", model.vtNumber, model.displayNumber) - } - - if (location) { - return i18ndc("plasma_lookandfeel_org.kde.lookandfeel", "Username (location)", "%1 (%2)", displayName, location) - } - - return displayName - } - - userName: model.name - - width: userItemWidth - height: userItemHeight - - //if we only have one delegate, we don't need to clip the text as it won't be overlapping with anything - constrainText: ListView.view.count > 1 - - isCurrent: ListView.isCurrentItem - - onClicked: { - ListView.view.currentIndex = index; - ListView.view.userSelected(); - } - } - - Keys.onEscapePressed: view.userSelected() - Keys.onEnterPressed: view.userSelected() - Keys.onReturnPressed: view.userSelected() -} diff --git a/x11-themes/redcore-theme-sddm/files/redcore/components/VirtualKeyboard.qml b/x11-themes/redcore-theme-sddm/files/redcore/components/VirtualKeyboard.qml deleted file mode 100644 index 7848b753..00000000 --- a/x11-themes/redcore-theme-sddm/files/redcore/components/VirtualKeyboard.qml +++ /dev/null @@ -1,28 +0,0 @@ -/******************************************************************** - This file is part of the KDE project. - -Copyright (C) 2017 Martin Gräßlin <mgraesslin@kde.org> - -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program. If not, see <http://www.gnu.org/licenses/>. -*********************************************************************/ -import QtQuick 2.5 -import QtQuick.VirtualKeyboard 2.1 - -InputPanel { - id: inputPanel - property bool activated: false - active: activated && Qt.inputMethod.visible - visible: active - width: parent.width -} diff --git a/x11-themes/redcore-theme-sddm/files/redcore/components/WallpaperFader.qml b/x11-themes/redcore-theme-sddm/files/redcore/components/WallpaperFader.qml deleted file mode 100644 index 31dfe007..00000000 --- a/x11-themes/redcore-theme-sddm/files/redcore/components/WallpaperFader.qml +++ /dev/null @@ -1,182 +0,0 @@ -/******************************************************************** - This file is part of the KDE project. - -Copyright (C) 2014 Aleix Pol Gonzalez <aleixpol@blue-systems.com> - -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program. If not, see <http://www.gnu.org/licenses/>. -*********************************************************************/ - -import QtQuick 2.6 -import QtQuick.Controls 1.1 -import QtQuick.Layouts 1.1 -import QtGraphicalEffects 1.0 - -import org.kde.plasma.core 2.0 as PlasmaCore -import org.kde.plasma.components 2.0 as PlasmaComponents - -import org.kde.plasma.private.sessions 2.0 -import "../components" - -Item { - id: wallpaperFader - property Item clock - property Item mainStack - property Item footer - property alias source: wallpaperBlur.source - state: lockScreenRoot.uiVisible ? "on" : "off" - property real factor: 0 - readonly property bool lightBackground: Math.max(PlasmaCore.ColorScope.backgroundColor.r, PlasmaCore.ColorScope.backgroundColor.g, PlasmaCore.ColorScope.backgroundColor.b) > 0.5 - - Behavior on factor { - NumberAnimation { - target: wallpaperFader - property: "factor" - duration: 1000 - easing.type: Easing.InOutQuad - } - } - FastBlur { - id: wallpaperBlur - anchors.fill: parent - radius: 50 * wallpaperFader.factor - } - ShaderEffect { - id: wallpaperShader - anchors.fill: parent - supportsAtlasTextures: true - property var source: ShaderEffectSource { - sourceItem: wallpaperBlur - live: true - hideSource: true - textureMirroring: ShaderEffectSource.NoMirroring - } - - readonly property real contrast: 0.65 * wallpaperFader.factor + (1 - wallpaperFader.factor) - readonly property real saturation: 1.6 * wallpaperFader.factor + (1 - wallpaperFader.factor) - readonly property real intensity: (wallpaperFader.lightBackground ? 1.7 : 0.6) * wallpaperFader.factor + (1 - wallpaperFader.factor) - - readonly property real transl: (1.0 - contrast) / 2.0; - readonly property real rval: (1.0 - saturation) * 0.2126; - readonly property real gval: (1.0 - saturation) * 0.7152; - readonly property real bval: (1.0 - saturation) * 0.0722; - - property var colorMatrix: Qt.matrix4x4( - contrast, 0, 0, 0.0, - 0, contrast, 0, 0.0, - 0, 0, contrast, 0.0, - transl, transl, transl, 1.0).times(Qt.matrix4x4( - rval + saturation, rval, rval, 0.0, - gval, gval + saturation, gval, 0.0, - bval, bval, bval + saturation, 0.0, - 0, 0, 0, 1.0)).times(Qt.matrix4x4( - intensity, 0, 0, 0, - 0, intensity, 0, 0, - 0, 0, intensity, 0, - 0, 0, 0, 1 - )); - - - fragmentShader: " - uniform mediump mat4 colorMatrix; - uniform mediump sampler2D source; - varying mediump vec2 qt_TexCoord0; - uniform lowp float qt_Opacity; - - void main(void) - { - mediump vec4 tex = texture2D(source, qt_TexCoord0); - gl_FragColor = tex * colorMatrix * qt_Opacity; - }" - } - - states: [ - State { - name: "on" - PropertyChanges { - target: mainStack - opacity: 1 - } - PropertyChanges { - target: footer - opacity: 1 - } - PropertyChanges { - target: wallpaperFader - factor: 1 - } - PropertyChanges { - target: clock.shadow - opacity: 0 - } - }, - State { - name: "off" - PropertyChanges { - target: mainStack - opacity: 0 - } - PropertyChanges { - target: footer - opacity: 0 - } - PropertyChanges { - target: wallpaperFader - factor: 0 - } - PropertyChanges { - target: clock.shadow - opacity: 1 - } - } - ] - transitions: [ - Transition { - from: "off" - to: "on" - //Note: can't use animators as they don't play well with parallelanimations - ParallelAnimation { - NumberAnimation { - target: mainStack - property: "opacity" - duration: units.longDuration - easing.type: Easing.InOutQuad - } - NumberAnimation { - target: footer - property: "opacity" - duration: units.longDuration - easing.type: Easing.InOutQuad - } - } - }, - Transition { - from: "on" - to: "off" - ParallelAnimation { - NumberAnimation { - target: mainStack - property: "opacity" - duration: 500 - easing.type: Easing.InOutQuad - } - NumberAnimation { - target: footer - property: "opacity" - duration: 500 - easing.type: Easing.InOutQuad - } - } - } - ] -} diff --git a/x11-themes/redcore-theme-sddm/files/redcore/faces/.face.icon b/x11-themes/redcore-theme-sddm/files/redcore/faces/.face.icon new file mode 100644 index 00000000..ecee9917 --- /dev/null +++ b/x11-themes/redcore-theme-sddm/files/redcore/faces/.face.icon @@ -0,0 +1,14 @@ +<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 22 22"> + <defs id="defs3051"> + <style type="text/css" id="current-color-scheme"> + .ColorScheme-Text { + color:#f2f2f2; + } + </style> + </defs> + <path + style="fill:currentColor;fill-opacity:1;stroke:none" + d="M 11 3 A 3.9999902 4.0000296 0 0 0 7 7 A 3.9999902 4.0000296 0 0 0 11 11 A 3.9999902 4.0000296 0 0 0 15 7 A 3.9999902 4.0000296 0 0 0 11 3 z M 11 4 A 3 3.0000296 0 0 1 14 7 A 3 3.0000296 0 0 1 11 10 A 3 3.0000296 0 0 1 8 7 A 3 3.0000296 0 0 1 11 4 z M 11 12 A 7.9999504 8.0000296 0 0 0 3.0722656 19 L 4.0800781 19 A 6.9999604 7.0000296 0 0 1 11 13 A 6.9999604 7.0000296 0 0 1 17.921875 19 L 18.929688 19 A 7.9999504 8.0000296 0 0 0 11 12 z " + class="ColorScheme-Text" + /> +</svg> diff --git a/x11-themes/redcore-theme-sddm/files/redcore/metadata.desktop b/x11-themes/redcore-theme-sddm/files/redcore/metadata.desktop index 26e37838..11188a8f 100644 --- a/x11-themes/redcore-theme-sddm/files/redcore/metadata.desktop +++ b/x11-themes/redcore-theme-sddm/files/redcore/metadata.desktop @@ -1,16 +1,17 @@ [SddmGreeterTheme] -Name=Redcore -Description=ChromeOS Theme -Author=Vince Liuice -Copyright=(c) 2020, Vince Liuice +Name=Redcore-Breeze +Description=Redcore-Breeze +Author=KDE Visual Design Group +Copyright=(c) 2014, David Edmundson License=CC-BY-SA Type=sddm-theme -Version=0.1.0 -Website=https://github.com/vinceliuice/Orchis-kde -Screenshot=preview.png +Version=0.1 +Website=https://github.com/sddm/sddm +Screenshot=background.png MainScript=Main.qml ConfigFile=theme.conf TranslationsDirectory=translations -Email=vinceliuice@hotmail.com -Theme-Id=Orchis +Email=plasma-devel@kde.org +Theme-Id=redcore-breeze Theme-API=2.0 +QtVersion=6 diff --git a/x11-themes/redcore-theme-sddm/files/redcore/redcore-weblink.svg b/x11-themes/redcore-theme-sddm/files/redcore/redcore-weblink.svg new file mode 100644 index 00000000..7fa6a290 --- /dev/null +++ b/x11-themes/redcore-theme-sddm/files/redcore/redcore-weblink.svg @@ -0,0 +1,15 @@ +<svg xmlns="http://www.w3.org/2000/svg" version="1.1" viewBox="0 0 48 48"> + <defs> + <linearGradient id="linearGradient3764" x2="47" gradientUnits="userSpaceOnUse" x1="1" gradientTransform="matrix(0 -1 1 0 -.0000015 48)"> + <stop style="stop-color:#752521" offset="0"/> + <stop style="stop-color:#852a25" offset="1"/> + </linearGradient> + </defs> + <path style="opacity:.05" d="m36.31 5c5.859 4.062 9.688 10.831 9.688 18.5 0 12.426-10.07 22.5-22.5 22.5-7.669 0-14.438-3.828-18.5-9.688 1.037 1.822 2.306 3.499 3.781 4.969 4.085 3.712 9.514 5.969 15.469 5.969 12.703 0 23-10.298 23-23 0-5.954-2.256-11.384-5.969-15.469-1.469-1.475-3.147-2.744-4.969-3.781zm4.969 3.781c3.854 4.113 6.219 9.637 6.219 15.719 0 12.703-10.297 23-23 23-6.081 0-11.606-2.364-15.719-6.219 4.16 4.144 9.883 6.719 16.219 6.719 12.703 0 23-10.298 23-23 0-6.335-2.575-12.06-6.719-16.219z"/> + <path style="opacity:.1" d="m41.28 8.781c3.712 4.085 5.969 9.514 5.969 15.469 0 12.703-10.297 23-23 23-5.954 0-11.384-2.256-15.469-5.969 4.113 3.854 9.637 6.219 15.719 6.219 12.703 0 23-10.298 23-23 0-6.081-2.364-11.606-6.219-15.719z"/> + <path style="opacity:.2" d="m31.25 2.375c8.615 3.154 14.75 11.417 14.75 21.13 0 12.426-10.07 22.5-22.5 22.5-9.708 0-17.971-6.135-21.12-14.75a23 23 0 0 0 44.875 -7 23 23 0 0 0 -16 -21.875z"/> + <path style="fill:url(#linearGradient3764)" d="m24 1c12.703 0 23 10.297 23 23s-10.297 23-23 23-23-10.297-23-23 10.297-23 23-23z"/> + <path style="opacity:.1" d="m40.03 7.531c3.712 4.084 5.969 9.514 5.969 15.469 0 12.703-10.297 23-23 23-5.954 0-11.384-2.256-15.469-5.969 4.178 4.291 10.01 6.969 16.469 6.969 12.703 0 23-10.298 23-23 0-6.462-2.677-12.291-6.969-16.469z"/> + <path d="m25 12c-3.87 0-6.0922 2.3479-7.3652 5.4434-4.604 1.283-6.635 5.092-6.635 7.557 0 7 7 12 12 13-4-2-9-6-9-13 0-1.6997 0.96495-3.397 2.709-4.5508-0.57 2.594-0.709 5.343-0.709 7.551 0-1.658 0.921-5.451 2.754-8.516 0.958-0.306 2.042-0.483 3.246-0.484 0.09012-0.000068 0.21145 0.0019 0.30664 0.002-0.483 0.302-0.936 0.627-1.307 0.998 0.97928-0.58053 2.4997-0.89772 4-1 1.5003 0.10228 3.0207 0.41947 4 1-0.37064-0.37064-0.82409-0.6961-1.3066-0.99805 0.09519-0.000036 0.21652-0.002 0.30664-0.002 1.2036 0.000877 2.2882 0.17838 3.2461 0.48438 1.833 3.065 2.754 6.858 2.754 8.516 0-2.208-0.139-4.957-0.709-7.551 1.744 1.154 2.709 2.851 2.709 4.551 0 7-5 11-9 13 5-1 12-6 12-13 0-2.4646-2.031-6.2736-6.6348-7.5566-1.273-3.095-3.495-5.443-7.365-5.443zm0 3c1.6902 0 3.1336 0.80851 4.3477 2.0156-0.11782-0.0029-0.22748-0.01563-0.34766-0.01563-1 0-2.5 0.25-4 0.75-1.5-0.5-3-0.75-4-0.75-0.12018 0-0.22983 0.01271-0.34766 0.01563 1.2141-1.2071 2.6574-2.0156 4.3477-2.0156zm0 5a8 8 0 0 0 -8 8 8 8 0 0 0 8 8 8 8 0 0 0 8 -8 8 8 0 0 0 -8 -8z" style="opacity:.1"/> + <path style="fill:#ea5259" d="m24 11c-3.87 0-6.0922 2.3479-7.3652 5.4434-4.604 1.283-6.635 5.092-6.635 7.557 0 7 7 12 12 13-4-2-9-6-9-13 0-1.6997 0.96495-3.397 2.709-4.5508-0.57 2.594-0.709 5.343-0.709 7.551 0-1.658 0.921-5.451 2.754-8.516 0.958-0.306 2.042-0.483 3.246-0.484 0.09012-0.000068 0.21145 0.0019 0.30664 0.002-0.483 0.302-0.936 0.627-1.307 0.998 0.97928-0.58053 2.4997-0.89772 4-1 1.5003 0.10228 3.0207 0.41947 4 1-0.37064-0.37064-0.82409-0.6961-1.3066-0.99805 0.09519-0.000036 0.21652-0.002 0.30664-0.002 1.2036 0.000877 2.2882 0.17838 3.2461 0.48438 1.833 3.065 2.754 6.858 2.754 8.516 0-2.208-0.139-4.957-0.709-7.551 1.744 1.154 2.709 2.851 2.709 4.551 0 7-5 11-9 13 5-1 12-6 12-13 0-2.4646-2.031-6.2736-6.6348-7.5566-1.273-3.095-3.495-5.443-7.365-5.443zm0 3c1.6902 0 3.1336 0.80851 4.3477 2.0156-0.11782-0.0029-0.22748-0.01563-0.34766-0.01563-1 0-2.5 0.25-4 0.75-1.5-0.5-3-0.75-4-0.75-0.12018 0-0.22983 0.01271-0.34766 0.01563 1.2141-1.2071 2.6574-2.0156 4.3477-2.0156zm0 5a8 8 0 0 0 -8 8 8 8 0 0 0 8 8 8 8 0 0 0 8 -8 8 8 0 0 0 -8 -8z"/> +</svg> diff --git a/x11-themes/redcore-theme-sddm/files/redcore/theme.conf b/x11-themes/redcore-theme-sddm/files/redcore/theme.conf index 53dfe0ad..1dc1948a 100644 --- a/x11-themes/redcore-theme-sddm/files/redcore/theme.conf +++ b/x11-themes/redcore-theme-sddm/files/redcore/theme.conf @@ -1,5 +1,8 @@ [General] +showlogo=hidden +logo=redcore-weblink.svg type=image color=#520A0A fontSize=10 -background=background.jpg +background=background.png +needsFullUserModel=false diff --git a/x11-themes/redcore-theme-sddm/files/redcore/theme.conf.user b/x11-themes/redcore-theme-sddm/files/redcore/theme.conf.user index 68c66429..64db91c8 100644 --- a/x11-themes/redcore-theme-sddm/files/redcore/theme.conf.user +++ b/x11-themes/redcore-theme-sddm/files/redcore/theme.conf.user @@ -1,2 +1,3 @@ [General] +background=background.png type=image |