Hide the cursor from the XDM login screen

786 Views Asked by At

I want to hide the Adwaita cursor from the my XDM login screen. I looked at /etc/X11/xdm/ for a some cursor config, but found nothing.

There is my ~/.Xresources:

xlogin.Login.greeting:
xlogin.Login.unsecureGreeting:
xlogin.Login.fail:                Fail.
xlogin.Login.changePasswdMessage: Change.
xlogin.Login.namePrompt:          Username:
xlogin.Login.passwdPrompt:        Password:
xlogin.Login.echoPasswd:          true
xlogin.Login.background:          black
xlogin.Login.foreground:          white
xlogin.Login.failColor:           #cccccc
xlogin.Login.inpColor:            black
xlogin.Login.promptColor:         #aaaaaa
xlogin.Login.face:                courier:size=13:style=Bold
xlogin.Login.failFace:            courier:size=13:style=Bold
xlogin.Login.promptFace:          courier:size=13:style=Normal
xlogin.Login.greetFace:           courier:size=13
xlogin.Login.width:               400
xlogin.Login.y:                   400

For a reference, on the my login screen there are the 2 cursors: I-beam cursor (inside the field, which I enter now) and "unattached" cursor, which remains in the system after the login. I mean the second cursor (as I mentioned earlier, it has the Adwaita theme).

Is there a possibility to hide this cursor from the login screen?

1

There are 1 best solutions below

6
On BEST ANSWER

X cursors are defined by a theme. In .Xresources you can set the theme with:

Xcursor.theme: cursor-theme

I am not aware of the ability to set individual cursor shapes, but you could always craft your own theme for that. You can also set a size:

Xcursor.size: 16

Maybe setting an invalid size will make the cursor go away so you don't need to mangle with the theme.

Finally, the theme can also be overriden by the environmental variable XCURSOR_THEME. If it doesn't work and the settings in .Xresources don't as well, a call to xrdb might be needed, which can be done in /etc/X11/xdm/Xsetup_0. As you can pass the file to read, this might be the best way to make the cursor disappear only within the login prompt and not during the regular X session.