4 Commits
Author SHA1 Message Date
KeyitdevandGitHub abb3163c72 Merge pull request #95 from NonameBlank007/cleanup
Improve system init detection and runit compatibility in setup.sh
2026-09-18 19:26:03 +02:00
NonameBlank007andGitHub b5fac9358f Update setup.sh
- Download additional pkg only if os-release ID=artix
2026-07-14 00:01:47 +05:30
Noname Blank 8fb1c72df5 Feat: add check for runit with pacman
It requires additional sddm-runit to add to service file directory (e.g., Artix-runit)

Signed-off-by: Noname Blank <nonameblank007@gmail.com>
2026-07-13 16:16:09 +05:30
Noname Blank d3b6cbbddd Fix: check for correct sv path and runsvdir improvements
1. The previous commit didn't account for correct "sv" path.
2. The previous setup gave priority to artix runit setup, but sv path was incorrect
 - Its "/etc/runit/sv", but accidentaly gave "/etc/sv" which dosen't exist.
 - So, improve it by adding various other check and make it a branch "if-elif" check.
 - Called '_runit_sv'.
3. Improve on/default to first check for current running system dir's insted.
 - Prioritise current running insted of Not/Enabled symlinked "/etc/runit/runsvdir/default".
 - Above should only gave priority if it is not enabled/running.
 - So, not recommended.

link of ref:
[1]: https://docs.voidlinux.org/config/services/index.html | Enabling Services
[2]: https://wiki.gentoo.org/wiki/Runit#Runit_and_service_management | 3.4.2
[3]: https://wiki.artixlinux.org/Main/Runit | Basic usage

Signed-off-by: Noname Blank <nonameblank007@gmail.com>
2026-07-13 16:16:01 +05:30
11 changed files with 264 additions and 413 deletions
+7 -7
View File
@@ -1,10 +1,10 @@
// Config created by Keyitdev https://github.com/Keyitdev/sddm-astronaut-theme
// Copyright (C) 2022-2026 Keyitdev
// Copyright (C) 2022-2025 Keyitdev
// Based on https://github.com/MarianArlt/sddm-sugar-dark
// Distributed under the GPLv3+ License https://www.gnu.org/licenses/gpl-3.0.html
import QtQuick
import QtQuick.Controls
import QtQuick 2.15
import QtQuick.Controls 2.15
Column {
id: clock
@@ -13,11 +13,11 @@ Column {
spacing: 0
Label {
id: headerTextLabel
id:headerTextLabel
anchors.horizontalCenter: parent.horizontalCenter
font.pixelSize: rootFontSize * 4
font.pointSize: root.font.pointSize * 3
color: config.HeaderTextColor
renderType: Text.QtRendering
text: config.HeaderText
@@ -28,7 +28,7 @@ Column {
anchors.horizontalCenter: parent.horizontalCenter
font.pixelSize: rootFontSize * 12
font.pointSize: root.font.pointSize * 9
font.bold: true
color: config.TimeTextColor
renderType: Text.QtRendering
@@ -44,7 +44,7 @@ Column {
anchors.horizontalCenter: parent.horizontalCenter
color: config.DateTextColor
font.pixelSize: rootFontSize * 2.66
font.pointSize: root.font.pointSize * 2
font.bold: true
renderType: Text.QtRendering
+96 -124
View File
@@ -1,105 +1,98 @@
// Config created by Keyitdev https://github.com/Keyitdev/sddm-astronaut-theme
// Copyright (C) 2022-2026 Keyitdev
// Copyright (C) 2022-2025 Keyitdev
// Based on https://github.com/MarianArlt/sddm-sugar-dark
// Distributed under the GPLv3+ License https://www.gnu.org/licenses/gpl-3.0.html
import QtQuick
import QtQuick.Layouts
import QtQuick.Controls
import QtQuick 2.15
import QtQuick.Layouts 1.15
import QtQuick.Controls 2.15
Column {
id: inputContainer
Layout.fillWidth: true
spacing: 0
property ComboBox exposeSession: sessionSelect.exposeSession
property bool failed
readonly property real passwordFieldTopMargin: (Number(config.PasswordFieldTopMargin) || 0) * rootHeightUnit
readonly property real loginButtonTopMargin: (Number(config.LoginButtonTopMargin) || 0) * rootHeightUnit
function findRegisteredUser(typedUser, matchRealName) {
for (var i = 0; i < userRegistry.list.length; i++) {
var candidate = userRegistry.list[i]
if (typedUser === candidate.name || (matchRealName && typedUser === candidate.realName)) {
return candidate
}
}
return null
}
property url currentUserIcon: {
var typedUser = username.text
if (typedUser === "") {
var highlighted = userRegistry.list[selectUser.currentIndex]
return highlighted ? (highlighted.icon || "") : ""
}
var match = findRegisteredUser(typedUser, true)
return match ? (match.icon || "") : ""
}
function triggerLogin() {
var typedUser = username.text
var match = findRegisteredUser(typedUser, config.UseRealName == "true")
var targetUser = match ? match.name : typedUser
var targetUser = typedUser
if (config.UseRealName == "true") {
for (var i = 0; i < userRegistry.list.length; i++) {
var u = userRegistry.list[i]
if (typedUser === u.realName || typedUser === u.name) {
targetUser = u.name
break
}
}
} else {
for (var j = 0; j < userRegistry.list.length; j++) {
var u2 = userRegistry.list[j]
if (typedUser === u2.name) {
targetUser = u2.name
break
}
}
}
sddm.login(targetUser, password.text, sessionSelect.selectedSession)
}
Item {
id: errorMessageField
id: errorMessageField
height: rootHeightUnit * 1.5
width: parent.width / 2
anchors.horizontalCenter: parent.horizontalCenter
// change also in selectSession
height: root.font.pointSize * 2
width: parent.width / 2
anchors.horizontalCenter: parent.horizontalCenter
Label {
id: errorMessage
Label {
id: errorMessage
width: parent.width
horizontalAlignment: Text.AlignHCenter
width: parent.width
horizontalAlignment: Text.AlignHCenter
text: failed ? config.TranslateLoginFailedWarning || textConstants.loginFailed + "!" : keyboard.capsLock ? config.TranslateCapslockWarning || textConstants.capslockWarning : ""
text: failed ? config.TranslateLoginFailedWarning || textConstants.loginFailed + "!" : keyboard.capsLock ? config.TranslateCapslockWarning || textConstants.capslockWarning : null
font.pointSize: root.font.pointSize * 0.8
font.italic: true
color: config.WarningColor
opacity: 0
font.pixelSize: rootFontSize * 1.33
font.italic: true
color: config.WarningColor
opacity: 0
states: [
State {
name: "fail"
when: failed
PropertyChanges {
target: errorMessage
opacity: 1
}
},
State {
name: "capslock"
when: keyboard.capsLock
PropertyChanges {
target: errorMessage
opacity: 1
}
states: [
State {
name: "fail"
when: failed
PropertyChanges {
target: errorMessage
opacity: 1
}
]
transitions: [
Transition {
PropertyAnimation {
properties: "opacity"
duration: 100
}
},
State {
name: "capslock"
when: keyboard.capsLock
PropertyChanges {
target: errorMessage
opacity: 1
}
]
}
}
]
transitions: [
Transition {
PropertyAnimation {
properties: "opacity"
duration: 100
}
}
]
}
}
Item {
id: usernameField
height: username.height
height: root.font.pointSize * 4.5
width: parent.width / 2
anchors.horizontalCenter: parent.horizontalCenter
@@ -109,7 +102,6 @@ Column {
width: parent.height
height: parent.height
anchors.left: parent.left
anchors.leftMargin: selectUser.height * 0.2
z: 2
model: userModel
@@ -135,20 +127,15 @@ Column {
delegate: ItemDelegate {
// minus padding
width: popupHandler.width - (rootWidthUnit * 1.5)
width: popupHandler.width - 20
anchors.horizontalCenter: popupHandler.horizontalCenter
topPadding: rootScaleUnit * 6
bottomPadding: rootScaleUnit * 6
leftPadding: rootScaleUnit * 12
rightPadding: rootScaleUnit * 12
contentItem: Text {
verticalAlignment: Text.AlignVCenter
horizontalAlignment: Text.AlignHCenter
text: config.UseRealName == "true" ? (model.realName || model.name) : model.name
font.pixelSize: rootFontSize * 1.06
font.pointSize: root.font.pointSize * 0.8
font.capitalization: Font.MixedCase
font.family: root.font.family
color: config.DropdownTextColor
@@ -166,10 +153,10 @@ Column {
height: parent.height
anchors.left: parent.left
anchors.verticalCenter: parent.verticalCenter
anchors.leftMargin: selectUser.height * 0
icon.height: parent.height * 0.4
icon.width: parent.height * 0.4
icon.height: parent.height * 0.25
icon.width: parent.height * 0.25
enabled: false
icon.color: config.UserIconColor
icon.source: Qt.resolvedUrl("../Assets/User.svg")
@@ -191,12 +178,12 @@ Column {
implicitHeight: contentItem.implicitHeight
width: usernameField.width
y: parent.height - username.height / 3
x: config.RightToLeftLayout == "true" ? (-loginButton.width + selectUser.width + selectUser.anchors.leftMargin) : 0 - selectUser.anchors.leftMargin
x: config.RightToLeftLayout == "true" ? -loginButton.width + selectUser.width : 0
rightMargin: config.RightToLeftLayout == "true" ? root.padding + usernameField.width / 2 : undefined
padding: rootHeightUnit * 0.75
padding: 10
contentItem: ListView {
implicitHeight: contentHeight + (rootHeightUnit * 1.5)
implicitHeight: contentHeight + 20
clip: true
model: selectUser.popup.visible ? selectUser.delegateModel : null
@@ -205,7 +192,7 @@ Column {
}
background: Rectangle {
radius: (rootScaleUnit * config.RoundCorners) / 2
radius: config.RoundCorners / 2
color: config.DropdownBackgroundColor
layer.enabled: true
}
@@ -256,12 +243,9 @@ Column {
id: username
anchors.centerIn: parent
height: rootHeightUnit * 3
height: root.font.pointSize * 3
width: parent.width
font.pixelSize: rootFontSize * 1.33
horizontalAlignment: TextInput.AlignHCenter
leftPadding: selectUser.width
rightPadding: selectUser.width
z: 1
text: config.ForceLastUser == "true" ? selectUser.displayText : null
@@ -282,8 +266,8 @@ Column {
color: config.LoginFieldBackgroundColor
opacity: 0.2
border.color: "transparent"
border.width: parent.activeFocus ? (rootScaleUnit * 2) : (rootScaleUnit * 1)
radius: rootScaleUnit * config.RoundCorners || 0
border.width: parent.activeFocus ? 2 : 1
radius: config.RoundCorners || 0
}
onAccepted: triggerLogin()
@@ -306,30 +290,25 @@ Column {
}
}
Item {
id: passwordFieldSpacer
width: 1
height: passwordFieldTopMargin
}
Item {
id: passwordField
height: password.height
height: root.font.pointSize * 4.5
width: parent.width / 2
anchors.horizontalCenter: parent.horizontalCenter
Button {
id: passwordIcon
width: parent.height
height: parent.height
width: selectUser.height * 1
anchors.left: parent.left
anchors.leftMargin: selectUser.height * 0.2
anchors.leftMargin: selectUser.height * 0
anchors.verticalCenter: parent.verticalCenter
z: 2
icon.height: parent.height * 0.4
icon.width: parent.height * 0.4
icon.height: parent.height * 0.25
icon.width: parent.height * 0.25
icon.color: config.PasswordIconColor
icon.source: Qt.resolvedUrl("../Assets/Password2.svg")
@@ -395,22 +374,19 @@ Column {
TextField {
id: password
height: rootHeightUnit * 3
height: root.font.pointSize * 3
width: parent.width
font.pixelSize: rootFontSize * 1.33
anchors.centerIn: parent
horizontalAlignment: TextInput.AlignHCenter
leftPadding: passwordIcon.width
rightPadding: passwordIcon.width
font.bold: true
color: config.PasswordFieldTextColor
focus: config.PasswordFocus == "true"
focus: config.PasswordFocus == "true" ? true : false
echoMode: passwordIcon.checked ? TextInput.Normal : TextInput.Password
placeholderText: config.TranslatePlaceholderPassword || textConstants.password
placeholderTextColor: config.PlaceholderTextColor
passwordCharacter: "•"
passwordMaskDelay: config.ShowLastPasswordCharacter == "true" ? 1000 : undefined
passwordMaskDelay: config.HideCompletePassword == "true" ? undefined : 1000
renderType: Text.QtRendering
selectByMouse: true
@@ -418,8 +394,8 @@ Column {
color: config.PasswordFieldBackgroundColor
opacity: 0.2
border.color: "transparent"
border.width: parent.activeFocus ? (rootScaleUnit * 2) : (rootScaleUnit * 1)
radius: rootScaleUnit * config.RoundCorners || 0
border.width: parent.activeFocus ? 2 : 1
radius: config.RoundCorners || 0
}
onAccepted: triggerLogin()
KeyNavigation.down: loginButton
@@ -449,31 +425,27 @@ Column {
]
}
Item {
id: loginButtonSpacer
width: 1
height: loginButtonTopMargin
}
Item {
id: login
height: loginButton.height
// important
// try 4 or 9 ...
height: root.font.pointSize * 9
width: parent.width / 2
anchors.horizontalCenter: parent.horizontalCenter
visible: config.ShowLoginButton == "true"
visible: config.HideLoginButton == "true" ? false : true
Button {
id: loginButton
height: rootHeightUnit * 3
height: root.font.pointSize * 3
implicitWidth: parent.width
anchors.horizontalCenter: parent.horizontalCenter
anchors.verticalCenter: parent.verticalCenter
text: config.TranslateLogin || textConstants.login
enabled: config.AllowEmptyPassword == "true" || (username.text != "" && password.text != "")
enabled: config.AllowEmptyPassword == "true" || username.text != "" && password.text != "" ? true : false
hoverEnabled: true
contentItem: Text {
@@ -481,7 +453,7 @@ Column {
verticalAlignment: Text.AlignVCenter
font.bold: true
font.pixelSize: rootFontSize * 1.33
font.pointSize: root.font.pointSize
font.family: root.font.family
color: config.LoginButtonTextColor
text: parent.text
@@ -493,7 +465,7 @@ Column {
color: config.LoginButtonBackgroundColor
opacity: 0.2
radius: rootScaleUnit * config.RoundCorners || 0
radius: config.RoundCorners || 0
}
states: [
@@ -562,7 +534,7 @@ Column {
Keys.onReturnPressed: clicked()
Keys.onEnterPressed: clicked()
KeyNavigation.down: config.ShowSystemButtons == "true" ? systemButtons.children[0] : virtualKeyboard
KeyNavigation.down: config.HideSystemButtons == "true" ? virtualKeyboard : systemButtons.children[0]
}
}
@@ -576,7 +548,7 @@ Column {
Item {
Component.onCompleted: {
var currentList = userRegistry.list
currentList.push({ "name": model.name, "realName": model.realName || "", "icon": model.icon || "" })
currentList.push({ "name": model.name, "realName": model.realName || "" })
userRegistry.list = currentList
}
}
+47 -106
View File
@@ -1,122 +1,63 @@
// Config created by Keyitdev https://github.com/Keyitdev/sddm-astronaut-theme
// Copyright (C) 2022-2026 Keyitdev
// Copyright (C) 2022-2025 Keyitdev
// Based on https://github.com/MarianArlt/sddm-sugar-dark
// Distributed under the GPLv3+ License https://www.gnu.org/licenses/gpl-3.0.html
import QtQuick
import QtQuick.Layouts
import QtQuick 2.15
import QtQuick.Layouts 1.15
import SddmComponents 2.0 as SDDM
Item {
ColumnLayout {
id: formContainer
SDDM.TextConstants { id: textConstants }
readonly property real clockTopMargin: (Number(config.ClockTopMargin) || 0) * rootHeightUnit
readonly property real profilePictureTopMargin: (Number(config.ProfilePictureTopMargin) || 0) * rootHeightUnit
readonly property real loginInputTopMargin: (Number(config.LoginInputTopMargin) || 0) * rootHeightUnit
readonly property real systemButtonsBottomMargin: (Number(config.SystemButtonsBottomMargin) || 0) * rootHeightUnit
readonly property real sessionSelectBottomMargin: (Number(config.SessionSelectBottomMargin) || 0) * rootHeightUnit
readonly property real virtualKeyboardButtonBottomMargin: (Number(config.VirtualKeyboardButtonBottomMargin) || 0) * rootHeightUnit
property int p: config.ScreenPadding == "" ? 0 : config.ScreenPadding
property string a: config.FormPosition
ColumnLayout {
id: topGroup
spacing: 0
anchors.top: parent.top
anchors.horizontalCenter: parent.horizontalCenter
Clock {
id: clock
Rectangle {
id: clockBox
color: "transparent"
Layout.alignment: Qt.AlignHCenter
Layout.topMargin: clockTopMargin
Layout.preferredHeight: clock.implicitHeight + (rootHeightUnit * 1.5)
implicitWidth: clock.implicitWidth + (rootWidthUnit * 3)
radius: 20
Layout.preferredWidth: implicitWidth
Clock {
anchors.fill: parent
id: clock
Layout.alignment: Qt.AlignHCenter
}
}
Rectangle {
id: profilePictureBox
color: "transparent"
Layout.alignment: Qt.AlignHCenter
Layout.topMargin: profilePictureTopMargin
Layout.preferredHeight: profilePicture.height
implicitWidth: profilePicture.width + (rootWidthUnit * 3)
Layout.preferredWidth: implicitWidth
ProfilePicture {
id: profilePicture
visible: config.ShowProfilePicture == "true"
anchors.centerIn: parent
width: rootHeightUnit * 11
height: rootHeightUnit * 11
}
}
Rectangle {
id: inputBox
color: "transparent"
Layout.alignment: Qt.AlignHCenter
Layout.topMargin: loginInputTopMargin
Layout.preferredHeight: input.implicitHeight
implicitWidth: input.implicitWidth
Layout.preferredWidth: implicitWidth
Input {
id: input
anchors.centerIn: parent
width: rootWidthUnit * 65
}
}
Layout.alignment: Qt.AlignHCenter | Qt.AlignBottom
// important
Layout.preferredHeight: root.height / 3
Layout.leftMargin: p != "0" ? a == "left" ? -p : a == "right" ? p : 0 : 0
}
ColumnLayout {
id: bottomGroup
spacing: 0
anchors.bottom: parent.bottom
anchors.horizontalCenter: parent.horizontalCenter
Input {
id: input
Rectangle {
id: systemButtonsBox
color: "transparent"
Layout.alignment: Qt.AlignHCenter
Layout.bottomMargin: systemButtonsBottomMargin
Layout.preferredHeight: systemButtons.implicitHeight
implicitWidth: systemButtons.implicitWidth
Layout.preferredWidth: implicitWidth
SystemButtons {
id: systemButtons
anchors.centerIn: parent
}
}
Rectangle {
id: sessionSelectBox
color: "transparent"
Layout.alignment: Qt.AlignHCenter
Layout.bottomMargin: sessionSelectBottomMargin
Layout.preferredHeight: sessionSelect.height
implicitWidth: sessionSelect.width
Layout.preferredWidth: implicitWidth
SessionButton {
id: sessionSelect
anchors.centerIn: parent
width: rootWidthUnit * 32.5
}
}
Rectangle {
id: virtualKeyboardButtonBox
color: "transparent"
Layout.alignment: Qt.AlignHCenter
Layout.bottomMargin: virtualKeyboardButtonBottomMargin
Layout.preferredHeight: virtualKeyboardButton.height
implicitWidth: virtualKeyboardButton.width
Layout.preferredWidth: implicitWidth
VirtualKeyboardButton {
id: virtualKeyboardButton
anchors.centerIn: parent
width: rootWidthUnit * 32.5
}
}
Layout.alignment: Qt.AlignVCenter
Layout.preferredHeight: root.height / 10
Layout.leftMargin: p != "0" ? a == "left" ? -p : a == "right" ? p : 0 : 0
Layout.topMargin: 0
}
SystemButtons {
id: systemButtons
Layout.alignment: Qt.AlignHCenter | Qt.AlignBottom
Layout.preferredHeight: root.height / 5
Layout.maximumHeight: root.height / 5
Layout.leftMargin: p != "0" ? a == "left" ? -p : a == "right" ? p : 0 : 0
exposedSession: input.exposeSession
}
SessionButton {
id: sessionSelect
Layout.alignment: Qt.AlignHCenter | Qt.AlignBottom
Layout.preferredHeight: root.height / 54
Layout.maximumHeight: root.height / 54
Layout.leftMargin: p != "0" ? a == "left" ? -p : a == "right" ? p : 0 : 0
}
VirtualKeyboardButton {
id: virtualKeyboardButton
Layout.alignment: Qt.AlignHCenter | Qt.AlignTop
Layout.preferredHeight: root.height / 27
Layout.maximumHeight: root.height / 27
Layout.leftMargin: p != "0" ? a == "left" ? -p : a == "right" ? p : 0 : 0
}
}
-61
View File
@@ -1,61 +0,0 @@
// Config created by Keyitdev https://github.com/Keyitdev/sddm-astronaut-theme
// Copyright (C) 2022-2026 Keyitdev
// Distributed under the GPLv3+ License https://www.gnu.org/licenses/gpl-3.0.html
import QtQuick
import QtQuick.Effects
Item {
id: profilePicture
property url userIcon: input.currentUserIcon
property bool hasCustomIcon: userIcon != ""
Rectangle {
anchors.fill: avatarImage
radius: width / 2
color: config.ProfilePictureBorderColor
opacity: 0.2
z: -1
}
Image {
id: avatarImage
anchors.fill: parent
anchors.margins: ringBorder.border.width
source: hasCustomIcon ? profilePicture.userIcon : Qt.resolvedUrl("../Assets/User.svg")
fillMode: hasCustomIcon ? Image.PreserveAspectCrop : Image.PreserveAspectFit
smooth: true
mipmap: true
asynchronous: true
visible: false
}
Rectangle {
id: circleMask
anchors.fill: avatarImage
radius: rootScaleUnit * config.ProfilePictureRoundedCorners || 0
visible: false
layer.enabled: true
}
MultiEffect {
anchors.fill: avatarImage
source: avatarImage
maskEnabled: true
maskSource: circleMask
}
Rectangle {
id: ringBorder
anchors.fill: parent
radius: rootScaleUnit * config.ProfilePictureRoundedCorners || 0
color: "transparent"
border.width: rootScaleUnit * config.ProfilePictureBorderWidth || 2
border.color: config.ProfilePictureBorderColor
}
}
+19 -22
View File
@@ -1,25 +1,28 @@
// Config created by Keyitdev https://github.com/Keyitdev/sddm-astronaut-theme
// Copyright (C) 2022-2026 Keyitdev
// Copyright (C) 2022-2025 Keyitdev
// Based on https://github.com/MarianArlt/sddm-sugar-dark
// Distributed under the GPLv3+ License https://www.gnu.org/licenses/gpl-3.0.html
import QtQuick
import QtQuick.Controls
import QtQuick 2.15
import QtQuick.Controls 2.15
Item {
id: sessionButton
height: selectSession.height
height: root.font.pointSize
width: parent.width / 2
property var selectedSession: selectSession.currentIndex
property string textConstantSession
property int loginButtonWidth
property ComboBox exposeSession: selectSession
ComboBox {
id: selectSession
height: rootHeightUnit
width: parent.width
// important
// change also in errorMessage
height: root.font.pointSize * 2
anchors.horizontalCenter: parent.horizontalCenter
hoverEnabled: true
@@ -35,20 +38,15 @@ Item {
delegate: ItemDelegate {
// minus padding
width: popupHandler.width - (rootScaleUnit * 20)
width: popupHandler.width - 20
anchors.horizontalCenter: popupHandler.horizontalCenter
topPadding: rootScaleUnit * 6
bottomPadding: rootScaleUnit * 6
leftPadding: rootScaleUnit * 12
rightPadding: rootScaleUnit * 12
contentItem: Text {
verticalAlignment: Text.AlignVCenter
horizontalAlignment: Text.AlignHCenter
text: model.name
font.pixelSize: rootFontSize * 1.06
font.pointSize: root.font.pointSize * 0.8
font.family: root.font.family
color: config.DropdownTextColor
}
@@ -66,19 +64,18 @@ Item {
id: displayedItem
verticalAlignment: Text.AlignVCenter
horizontalAlignment: Text.AlignHCenter
text: (config.TranslateSessionSelection || "Session") + " (" + selectSession.currentText + ")"
color: config.SessionButtonTextColor
font.pixelSize: rootFontSize * 1.06
font.pointSize: root.font.pointSize * 0.8
font.family: root.font.family
Keys.onReleased: parent.popup.open()
}
background: Rectangle {
height: parent.visualFocus ? (rootScaleUnit * 2) : 0
width: parent.width
height: parent.visualFocus ? 2 : 0
width: displayedItem.implicitWidth
color: "transparent"
}
@@ -88,12 +85,12 @@ Item {
implicitHeight: contentItem.implicitHeight
width: sessionButton.width
y: parent.height + rootHeightUnit
x: 0
padding: rootScaleUnit * 10
y: parent.height - 1
x: -popupHandler.width/2 + displayedItem.width/2
padding: 10
contentItem: ListView {
implicitHeight: contentHeight + (rootScaleUnit * 20)
implicitHeight: contentHeight + 20
clip: true
model: selectSession.popup.visible ? selectSession.delegateModel : null
@@ -102,7 +99,7 @@ Item {
}
background: Rectangle {
radius: (rootScaleUnit * config.RoundCorners) / 2
radius: config.RoundCorners / 2
color: config.DropdownBackgroundColor
layer.enabled: true
}
+33 -26
View File
@@ -1,77 +1,81 @@
// Config created by Keyitdev https://github.com/Keyitdev/sddm-astronaut-theme
// Copyright (C) 2022-2026 Keyitdev
// Copyright (C) 2022-2025 Keyitdev
// Based on https://github.com/MarianArlt/sddm-sugar-dark
// Distributed under the GPLv3+ License https://www.gnu.org/licenses/gpl-3.0.html
import QtQuick
import QtQuick.Layouts
import QtQuick.Controls
import QtQuick 2.15
import QtQuick.Layouts 1.15
import QtQuick.Controls 2.15
RowLayout {
spacing: rootFontSize
spacing: root.font.pointSize
property var shutdown: ["Shutdown", config.TranslateShutdown || textConstants.shutdown, sddm.canPowerOff]
property var reboot: ["Reboot", config.TranslateReboot || textConstants.reboot, sddm.canReboot]
property var suspend: ["Suspend", config.TranslateSuspend || textConstants.suspend, sddm.canSuspend]
property var hibernate: ["Hibernate", config.TranslateHibernate || textConstants.hibernate, sddm.canHibernate]
property ComboBox exposedSession
Repeater {
id: systemButtons
model: [shutdown, reboot, suspend, hibernate]
RoundButton {
id: sysButton
Layout.alignment: Qt.AlignHCenter | Qt.AlignVCenter
Layout.topMargin: root.font.pointSize * 6.5
text: modelData[1]
font.pixelSize: rootFontSize * 1.06
icon.source: Qt.resolvedUrl("../Assets/" + modelData[0] + ".svg")
icon.height: 2 * Math.round((rootFontSize * 3) / 2)
icon.width: 2 * Math.round((rootFontSize * 3) / 2)
font.pointSize: root.font.pointSize * 0.8
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.SystemButtonsIconsColor
palette.buttonText: config.SystemButtonsIconsColor
display: AbstractButton.TextUnderIcon
spacing: rootScaleUnit * 6
padding: rootScaleUnit * 8
visible: config.ShowSystemButtons == "true" && (config.BypassSystemButtonsChecks == "true" || modelData[2])
visible: config.HideSystemButtons != "true" && (config.BypassSystemButtonsChecks == "true" ? 1 : modelData[2])
hoverEnabled: true
background: Rectangle {
height: rootScaleUnit * 2
height: 2
width: parent.width
color: "transparent"
}
Keys.onReturnPressed: clicked()
onClicked: {
parent.forceActiveFocus()
switch (index) {
case 0: sddm.powerOff(); break
case 1: sddm.reboot(); break
case 2: sddm.suspend(); break
default: sddm.hibernate()
}
index == 0 ? sddm.powerOff() : index == 1 ? sddm.reboot() : index == 2 ? sddm.suspend() : sddm.hibernate()
}
KeyNavigation.left: index > 0 ? parent.children[index-1] : null
states: [
State {
name: "pressed"
when: sysButton.down
when: parent.children[index].down
PropertyChanges {
target: sysButton
target: parent.children[index]
icon.color: root.palette.buttonText
palette.buttonText: Qt.darker(root.palette.buttonText, 1.1)
}
},
State {
name: "hovered"
when: sysButton.hovered
when: parent.children[index].hovered
PropertyChanges {
target: sysButton
target: parent.children[index]
icon.color: root.palette.buttonText
palette.buttonText: Qt.lighter(root.palette.buttonText, 1.1)
}
},
State {
name: "focused"
when: sysButton.activeFocus
when: parent.children[index].activeFocus
PropertyChanges {
target: sysButton
target: parent.children[index]
icon.color: root.palette.buttonText
palette.buttonText: root.palette.buttonText
}
@@ -85,6 +89,9 @@ RowLayout {
}
}
]
}
}
}
+3 -3
View File
@@ -1,10 +1,10 @@
// Config created by Keyitdev https://github.com/Keyitdev/sddm-astronaut-theme
// Copyright (C) 2022-2026 Keyitdev
// Copyright (C) 2022-2025 Keyitdev
// Based on https://github.com/MarianArlt/sddm-sugar-dark
// Distributed under the GPLv3+ License https://www.gnu.org/licenses/gpl-3.0.html
import QtQuick
import QtQuick.VirtualKeyboard
import QtQuick 2.15
import QtQuick.VirtualKeyboard 2.3
InputPanel {
id: virtualKeyboard
+6 -15
View File
@@ -1,24 +1,18 @@
// Config created by Keyitdev https://github.com/Keyitdev/sddm-astronaut-theme
// Copyright (C) 2022-2026 Keyitdev
// Copyright (C) 2022-2025 Keyitdev
// Distributed under the GPLv3+ License https://www.gnu.org/licenses/gpl-3.0.html
import QtQuick
import QtQuick.Controls
import QtQuick 2.15
import QtQuick.Controls 2.15
Item {
id: virtualKeyboardButtonRoot
height: virtualKeyboardButton.height
width: parent.width / 2
Button {
id: virtualKeyboardButton
height: rootHeightUnit
width: parent.width
anchors.horizontalCenter: parent.horizontalCenter
z: 1
visible: virtualKeyboard.status == Loader.Ready && config.ShowVirtualKeyboard == "true"
visible: virtualKeyboard.status == Loader.Ready && config.HideVirtualKeyboard == "false"
checkable: true
onClicked: virtualKeyboard.switchState()
@@ -34,11 +28,8 @@ Item {
contentItem: Text {
id: virtualKeyboardButtonText
verticalAlignment: Text.AlignVCenter
horizontalAlignment: Text.AlignHCenter
text: config.TranslateVirtualKeyboardButtonOff || "Virtual Keyboard (off)"
font.pixelSize: rootFontSize * 1.06
font.pointSize: root.font.pointSize * 0.8
font.family: root.font.family
color: parent.visualFocus ? config.HoverVirtualKeyboardButtonTextColor : config.VirtualKeyboardButtonTextColor
}
+29 -43
View File
@@ -1,10 +1,11 @@
// Config created by Keyitdev https://github.com/Keyitdev/sddm-astronaut-theme
// Copyright (C) 2022-2026 Keyitdev
// Copyright (C) 2022-2025 Keyitdev
// Based on https://github.com/MarianArlt/sddm-sugar-dark
// Distributed under the GPLv3+ License https://www.gnu.org/licenses/gpl-3.0.html
import QtQuick
import QtQuick.Controls
import QtQuick 2.15
import QtQuick.Layouts 1.15
import QtQuick.Controls 2.15
import QtQuick.Effects
import QtMultimedia
@@ -13,8 +14,8 @@ import "Components"
Pane {
id: root
height: Screen.height
width: Screen.width
height: config.ScreenHeight || Screen.height
width: config.ScreenWidth || Screen.ScreenWidth
padding: config.ScreenPadding
LayoutMirroring.enabled: config.RightToLeftLayout == "true" ? true : Qt.application.layoutDirection === Qt.RightToLeft
@@ -26,36 +27,27 @@ Pane {
palette.buttonText: config.HoverSystemButtonsIconsColor
font.family: config.Font
function safeOffset(val) {
var n = Number(val)
return (val === "" || val === undefined || val === null || isNaN(n)) ? 0 : n
}
property real rootFontSize: (config.FontSize !== "" && config.FontSize !== undefined ? Number(config.FontSize) : (height / 90)) + safeOffset(config.FontSizeOffset)
property real rootHeightUnit: (config.HeightUnit !== "" && config.HeightUnit !== undefined ? Number(config.HeightUnit) : (height / 90)) + safeOffset(config.HeightUnitOffset)
property real rootWidthUnit: (config.WidthUnit !== "" && config.WidthUnit !== undefined ? Number(config.WidthUnit) : (width / 160)) + safeOffset(config.WidthUnitOffset)
property real rootScaleUnit: (config.ScaleUnit !== "" && config.ScaleUnit !== undefined ? Number(config.ScaleUnit) : (height / 1080)) + safeOffset(config.ScaleUnitOffset)
font.pointSize: config.FontSize !== "" ? config.FontSize : parseInt(height / 80) || 13
focus: true
property bool leftleft: config.HaveFormBackground == "true" &&
config.PartialBlur != "true" &&
config.PartialBlur == "false" &&
config.FormPosition == "left" &&
config.BackgroundHorizontalAlignment == "left"
property bool leftcenter: config.HaveFormBackground == "true" &&
config.PartialBlur != "true" &&
config.PartialBlur == "false" &&
config.FormPosition == "left" &&
config.BackgroundHorizontalAlignment == "center"
property bool rightright: config.HaveFormBackground == "true" &&
config.PartialBlur != "true" &&
config.PartialBlur == "false" &&
config.FormPosition == "right" &&
config.BackgroundHorizontalAlignment == "right"
property bool rightcenter: config.HaveFormBackground == "true" &&
config.PartialBlur != "true" &&
config.PartialBlur == "false" &&
config.FormPosition == "right" &&
config.BackgroundHorizontalAlignment == "center"
@@ -85,7 +77,7 @@ Pane {
z: 1
color: config.FormBackgroundColor
visible: config.HaveFormBackground == "true"
visible: config.HaveFormBackground == "true" ? true : false
opacity: config.PartialBlur == "true" ? 0.3 : 1
}
@@ -235,7 +227,7 @@ Pane {
Image.AlignBottom : Image.AlignVCenter
speed: config.BackgroundSpeed == "" ? 1.0 : config.BackgroundSpeed
paused: config.PauseBackground == "true"
paused: config.PauseBackground == "true" ? 1 : 0
fillMode: config.CropBackground == "true" ? Image.PreserveAspectCrop : Image.PreserveAspectFit
asynchronous: true
cache: true
@@ -251,7 +243,7 @@ Pane {
player.play();
}
else{
backgroundImage.source = config.Background
backgroundImage.source = config.background || config.Background
}
}
}
@@ -270,33 +262,27 @@ Pane {
sourceItem: backgroundImage
sourceRect: Qt.rect(x,y,width,height)
visible: config.FullBlur == "true" || config.PartialBlur == "true"
visible: config.FullBlur == "true" || config.PartialBlur == "true" ? true : false
}
MultiEffect {
id: blur
id: blur
height: parent.height
height: parent.height
// width: config.FullBlur == "true" ? parent.width : form.width
// anchors.centerIn: config.FullBlur == "true" ? parent : form
// width: config.FullBlur == "true" ? parent.width : form.width
// anchors.centerIn: config.FullBlur == "true" ? parent : form
// This solves problem when FullBlur and HaveFormBackground is set to true but PartialBlur is false and FormPosition isn't center.
width: config.FullBlur == "true" ? (config.HaveFormBackground == "true" && config.PartialBlur != "true" && config.FormPosition != "center" ? parent.width - formBackground.width : parent.width) : form.width
anchors.centerIn: config.FullBlur == "true" ? backgroundImage : form
// This solves problem when FullBlur and HaveFormBackground is set to true but PartialBlur is false and FormPosition isn't center.
width: (config.FullBlur == "true" && config.PartialBlur == "false" && config.FormPosition != "center" ) ? parent.width - formBackground.width : config.FullBlur == "true" ? parent.width : form.width
anchors.centerIn: config.FullBlur == "true" ? backgroundImage : form
source: config.FullBlur == "true" ? backgroundImage : blurMask
blurEnabled: true
autoPaddingEnabled: false
property real parsedBlur: config.Blur === "" ? 2.0 : parseFloat(config.Blur)
property real scaledBlur: parsedBlur * root.rootScaleUnit
blur: Math.min(1.0, scaledBlur)
blurMax: config.BlurMax !== "" ? parseInt(config.BlurMax, 10) : 48
blurMultiplier: Math.max(0.0, scaledBlur - 1.0)
visible: config.FullBlur == "true" || config.PartialBlur == "true"
}
source: config.FullBlur == "true" ? backgroundImage : blurMask
blurEnabled: true
autoPaddingEnabled: false
blur: config.Blur == "" ? 2.0 : config.Blur
blurMax: config.BlurMax == "" ? 48 : config.BlurMax
visible: config.FullBlur == "true" || config.PartialBlur == "true" ? true : false
}
}
}
+1 -1
View File
@@ -5,7 +5,7 @@ Author=keyitdev
Website=https://github.com/Keyitdev/sddm-astronaut-theme
License=GPL-3.0-or-later
Type=sddm-theme
Version=1.5
Version=1.4
ConfigFile=Themes/astronaut.conf
Screenshot=Previews/astronaut.png
MainScript=Main.qml
+23 -5
View File
@@ -181,8 +181,19 @@ _disable_dm_dinit() {
done
}
_runit_sv() {
if [ -d /etc/sv ]; then echo "/etc/sv"
elif [ -d /etc/runit/sv ]; then echo "/etc/runit/sv"
else
error "Cannot find runit service configuration files directory"
return 1
fi
}
_runit_runsvdir() {
if [ -d /run/runit/service ]; then echo "/run/runit/service"
if [ -d /service ]; then echo "/service" # legacy/upstream symlink
elif [ -d /var/service ]; then echo "/var/service"
elif [ -d /run/runit/service ]; then echo "/run/runit/service"
elif [ -d /etc/runit/runsvdir/default ]; then echo "/etc/runit/runsvdir/default"
else
error "Cannot find runit service directory"
@@ -230,16 +241,23 @@ enable_sddm() {
;;
runit)
local sv
local runsvdir
sv=$(_runit_sv)
runsvdir=$(_runit_runsvdir)
if [ ! -d /etc/sv/sddm ]; then
error "/etc/sv/sddm not found - is sddm-runit (or equivalent) installed?"
if [ -f /etc/os-release ] && grep -q 'ID=artix' /etc/os-release; then
sudo pacman --needed -S sddm-runit
info "sddm-runit installed for Artix Linux"
fi
if [ ! -d "$sv/sddm" ]; then
error "$sv/sddm not found - is sddm-runit (or equivalent) installed?"
return 1
fi
_disable_dm_runit
sudo ln -sf /etc/sv/sddm "$runsvdir/sddm"
sudo ln -sf "$sv/sddm" "$runsvdir/"
info "sddm symlinked into $runsvdir"
;;
@@ -268,7 +286,7 @@ enable_sddm() {
echo ""
echo " systemd - sudo systemctl enable --now sddm"
echo " openrc - sudo rc-update add sddm default"
echo " runit - sudo ln -s /etc/sv/sddm /run/runit/service/"
echo " runit - sudo ln -s /etc/sv/sddm /var/service/ || sudo ln -s /etc/runit/sv/sddm /run/runit/service/"
echo " dinit - sudo ln -s /etc/dinit.d/sddm /etc/dinit.d/boot.d/sddm"
return 1
;;