sddm-theme-clairvoyance
sddm-theme-clairvoyance copied to clipboard
[Request] Select user automatically
I would like to ask for a feature. I had only one user to log in, and when my system boots up, I would like to start typing the password. (Without pressing the enter before it)
I know it is a very minor task for me to press the enter, but sometimes I just forgot this. And combined with the already in ,,autoFocusPassword" it would be perfect.
In the config it could be a ,,selectDefaultUser=username" and it could select that user, or if this value doesn't exists, or the user, it would be the same as now.
This is definitely something that I have been meaning to add for a while. I was going to have it automatically go to the password screen if there is only one user on the system. I'll try and do this over the weekend.
Have you made any progress on this? I would really like to use this theme but I can't get over having to press enter before typing my password
I just found this theme and had the same issue. I wrote a little hack to select the user right away, in the ChooseUser.qml
file add
Timer {id: singleUser
interval: 16
running: true
repeat: false
onTriggered: {
page.state = "login";
loginFrame.name = currentItem.name
loginFrame.realName = currentItem.realName
loginFrame.icon = currentItem.icon
focus = false
if (config.autoFocusPassword == "true")
focusDelay.start();
else
loginFrame.focus = true;
}
}
And it selects the user after running a 16ms timer automatically.
Disclaimer: I have no idea of QML or anything, I simply looked at the code and figured I could combine the onReturnPressed
and Timer
functionalities I encountered. I tested the theme with sddm-greeter --test-mode --theme /usr/share/sddm/themes/clairvoyance
and it worked fine, but any bugs this may introduce are yours to keep ;)
And if you at a later point add another user this will probably not work anymore.