You are not logged in.

#1 2023-12-07 00:11:11

Xeauron
Member
From: Manchester, UK
Registered: 2023-07-10
Posts: 32

KDE: XCURSOR_THEME resetting to breeze_cursors on reboot

Hi,
Does anyone have any idea why my cursor would be resetting itself on every reboot, it's driving me insane at this point.

If I pick my preferred cursor (McMojave_cursors) from the system settings, something switches it back to breeze_cursors on reboot.

OS: Arch Linux x86_64 
Kernel: 6.6.4-arch1-1 
Shell: zsh 5.9
DE: Plasma 5.27.10 
WM: KWin 

I update the environment variable:

export XCURSOR_THEME=McMojave-cursors
set XCURSOR_THEME=McMojave-cursors

It works for the session, then something switches it right back on reboot.

I've added the file:

/usr/share/icons/default/index.theme
[Icon Theme]
Inherits=McMojave-cursors

it gets switched back on reboot.

I've added (same file contents as above):

/home/user/.icons/default/index.theme

it's switched back on reboot.

The result of printenv after a reboot shows:

$ printenv | grep CURSOR
XCURSOR_SIZE=24
XCURSOR_THEME=breeze_cursors

I also added the environment variable XCURSOR_THEME=McMojave-cursors to /etc/environment, that's done nothing.

I just can't work out what's altering this environment variable and I'm going mad.
This only started happening in the last couple of weeks.

The frustrating thing is I can see the correct cursor is set when the OS first boots.
Before the little animated boot screen on KDE the first thing to appear is the cursor and it's the correct one, then after the boot animation it switches to breeze.

Anyone have any clues as to where I should look?

Web searches always only seem to bring up "My cursor changes when I hover over X application", seemingly no mention anywhere of anyone else having the cursor being switched by something.

Thanks in advance for any ideas!

Last edited by Xeauron (2023-12-10 10:58:42)

Offline

#2 2023-12-09 11:49:25

Xeauron
Member
From: Manchester, UK
Registered: 2023-07-10
Posts: 32

Re: KDE: XCURSOR_THEME resetting to breeze_cursors on reboot

I thought the problem had gone away, but it hasn't.

WORKAROUND:
I took the step of deleting /usr/share/icons/breeze_cursors folder.

$ sudo rm -r "/usr/share/icons/breeze_cursors"

the environment variable is still set:

$ printenv | grep CURSOR        
XCURSOR_SIZE=24
XCURSOR_THEME=breeze_cursors

however, SDDM seems to step in now and change it to the default cursor.

$ journalctl -b | grep cursor   
Dec 09 11:05:02 main sddm[3050]: Setting default cursor

and my cursor seems to be sticking after multiple reboots.

If anyone has any idea how to fix this properly then let me know, thanks.

Last edited by Xeauron (2023-12-09 11:49:53)

Offline

#3 2023-12-09 17:48:31

seth
Member
From: Won't reply 2 private help req
Registered: 2012-09-03
Posts: 76,631

Re: KDE: XCURSOR_THEME resetting to breeze_cursors on reboot

"kcmshell5 mouse"?

Edit: you could chattr config files immutable, but that's rather not a "proper" fix.

Last edited by seth (2023-12-09 17:49:22)

Online

#4 2023-12-09 20:58:23

Xeauron
Member
From: Manchester, UK
Registered: 2023-07-10
Posts: 32

Re: KDE: XCURSOR_THEME resetting to breeze_cursors on reboot

HI Seth, cheers for the suggestion smile

I can only access the mouse speed settings ect from that command it looks like.

It's weird, I've been in and out of the Arch Wiki and the KDE help pages and web searches and there doesn't seem to be any way to trace where an environment variable has been set from.

I've got a laptop with practically the exactly the same setup (Arch / KDE), though one was installed using the KDE meta package and the other the KDE package group, can't remember which. Anyway the laptop is fine.

All I can think is I must have installed a package that's altering this, I just can't think what it would be. Nothing I've installed (intentionally) is mouse or cursor related because KDE just works in that respect so I haven't had to.

Offline

#5 2023-12-09 21:02:36

seth
Member
From: Won't reply 2 private help req
Registered: 2012-09-03
Posts: 76,631

Re: KDE: XCURSOR_THEME resetting to breeze_cursors on reboot

Sorry, there's actually "kcmshell5 cursortheme" (i just check for a "mouse" kcm and figured that reasonably that would be it…)

Online

#6 2023-12-09 23:04:09

Xeauron
Member
From: Manchester, UK
Registered: 2023-07-10
Posts: 32

Re: KDE: XCURSOR_THEME resetting to breeze_cursors on reboot

Ah OK that makes sense.

Yeah, that accesses the system settings panel, albeit directly rather than having to click through the menus.

Thanks for having a stab at it. The problem seems to have gone away - fingers crossed - since I deleted the breeze_cursors folder now. Hopefully that's it.

It's just irritating having to use a workaround and not actually solving the problem. If I do find the proper solution I'll  document it here for others though.

Offline

#7 2023-12-10 09:40:56

seth
Member
From: Won't reply 2 private help req
Registered: 2012-09-03
Posts: 76,631

Re: KDE: XCURSOR_THEME resetting to breeze_cursors on reboot

I've added (same file contents as above):
/home/user/.icons/index.theme
it's switched back on reboot.

Does that file still change on reboots?

Online

#8 2023-12-10 10:57:45

Xeauron
Member
From: Manchester, UK
Registered: 2023-07-10
Posts: 32

Re: KDE: XCURSOR_THEME resetting to breeze_cursors on reboot

Apologies, that was mistyped, the file is:
/home/user/.icons/default/index.theme

And no, the file contents would stay the same.

The only thing that seemed to change was the environment variable:

$ printenv | grep CURSOR        
XCURSOR_SIZE=24
XCURSOR_THEME=breeze_cursors

Which is why I fixated on that since I could see it being manipulated by something.

I wasn't able to find anything referenced in either the Arch Wiki or KDE docs that referenced cursors which was set to breeze.

I even tried a full root search:

$ grep -r XCURSOR_THEME

That was probably a stupid idea since it went on for hours scraping all my HDDs and didn't find anything, I was a bit frustrated at the time, I ended up cancelling it in the end.
I may try again but with a narrower search path at some point.

Last edited by Xeauron (2023-12-10 11:10:45)

Offline

#9 2023-12-10 13:14:36

seth
Member
From: Won't reply 2 private help req
Registered: 2012-09-03
Posts: 76,631

Re: KDE: XCURSOR_THEME resetting to breeze_cursors on reboot

I'd

strace -fo /tmp/cursortheme.strace kcmshell5 cursortheme

to see what files are being opened and whether there's maybe a permission error - the environment is most likely set out of that kde config file (but the variable name encoded in the binary, not the config itself)

Online

#10 2023-12-11 10:08:15

Xeauron
Member
From: Manchester, UK
Registered: 2023-07-10
Posts: 32

Re: KDE: XCURSOR_THEME resetting to breeze_cursors on reboot

Thanks Seth, I'll give that a go as soon as I get chance.

Offline

Board footer

Powered by FluxBB