Change of theme gone wrong

I was curious and tried another xfce theme . I clicked on the first one and I got a window with huge letters filling the whole screen. Impossible to do anything since I had no access to any menu. I saw on a reply on another subject that Ctrl-Q might help. It did in a way for it reduced a little the size of the image on the screen and I could log out.
I have another user set-up for guessts with another name but same password as my ‘real’ user profile. This one works well but of course I have no access to my documents. So I need help ( step by step, please) on how to either recuperate the original theme on my admin account or turn my visitor account into admin so I can recuperate my documents. Thanks for your help

In the account having the mentioned problem with the theme, open a terminal window and run this command (copy/paste it in the terminal)

xfconf-query -c xsettings -p /Net/ThemeName -s Matcha-sea

in order to set Matcha-sea as the default GTK theme.

You can use in the above command any other installed theme you know that works well.

I did it but nothing happens

The xfce theme is defined in various places - in no specific order

  • ~/.gtkrc-2.0
  • ~/.config/gtk-3.0/settings.ini
  • ~/.config/gtk-4.0/settings.ini
  • ~/.config/xfce4/xfconf/xfce-perchannel/xsettings.ini

For qt and kvantum integration themes

  • ~/.config/Kvantum
  • ~/.config/qt5ct
  • ~/.config/qt6ct

Logout of the system and switch to a TTY
Login and manually modify those to use a well known theme e.g. Adwaita - switch back to your login manager - if lightdm then the display manager is on TTY7.

1 Like

Thanks but sorry. I really need a step by step way of doing it for I don’t want to lose everything. I think Awaita is the one that left a mess. Not sure. Happy with the original one,… Matcha-sea?

Adwaita is the de-facto gnome standard - I highly doubt it would cause any trouble.

I am sure you are right but I am pretty sure I had clicked on Adwaita and it now is a mess. Even the mouse behaves strangely so please, if someone can help me restore Matcha, I would be very grateful. I am at ease with it on my other account and would like to find it again.

With your guest account open the terminal - replace username with your dysfunctional user account

su -l username

Copy the contents from /etc/skel (including dot files) to your home - this will restore your settings.

cp --interactive --recursive /etc/skel/. ~/

or the shorthand version

cp -ir /etc/skel/. ~/

Finally the I don’t care just do it version

cp -r /etc/skel/. ~/
1 Like

The command @bill_t provided without the “-s …” (set) will display the theme’s name, so you’ll know for sure. Or,
grep ThemeName $HOME/.config/xfce4/xfconf/xfce-perchannel-xml/xsettings.xml

Could try:

  1. logging in/out
  2. remove cache, repeat step 1
    To remove xfce cache,

Best if you do it the manual way. While not logged in, delete ~/.cache/sessions. If you use a display manager like lightdm, then log out and Ctrl+Alt+F1, log into the text session and:

cd ~/.cache
rm -rf sessions
Broken Desktop / Desktop / Xfce Forums

Side note: if F1 doesn’t work, try F2-F6. F7 is your graphical desktop.

  1. Restore .config/xfce4 from backup (timeshift?? or other)
2 Likes

Thank you for your suggestions. I am terrified of loosing anything and have visitors at the moment so shall wait for a quiet time to try it all and let you know

OK, I tried what I thought might be the easiest way first, Stargazer’s.
When I enter : rm -rf sessions I get cannot remove rf no such file or directory

I am lost

You should have used what @linux-aarhus suggested.

That’s because: there is no such directory (to be removed).
Just as the message says.
It doesn’t exist.

The recommended approach will remove nothing, but get you the initial defaults back.

Thanks, I will, as soon as I have more time

I just did but nothing has changed. I cannot access my documents from my guest account. I can access then from my first account with the ‘twisted’ desktop so It is functional but awkward

Following a recipe is good and all
but it’s much better to actually understand what it is that is being done.

You essentially want to replace ~/.config/xfce4
(and perhaps some other subdirectories as well)
and everything in it

with the defaults, which are stored in /etc/skel/.config/xfce4

This cannot be done while you are logged into your graphical xfce session -
not as the same user that you are trying to fix anyway
(why? - because at least one file is in use - and thus cannot be replaced this way - you have to be logged out of that session for that)

Hence the use of the second account, which you already have - and doing it from there.

To do that from that other (guest) account - you have to login as your user that you are trying to fix:

su -l yourusername

before you do the removing and copying
else you will not have the rights to remove from or copy anything to that account.

You could just as well log out of xfce entirely and do it from a TTY - as your regular user.

  • remove the contents of ~/.config/xfce4

rm -rf ~/.config/xfce4

  • replace them with the defaults:

cp -r /etc/skel/.config/xfce4 ~/.config

It’s good to get a visual of what you are trying to do.

Have a look at both the source directory
/etc/skel
as well as the destination in your $HOME directory
~/.config/xfce4

You’ll see the identical names …

I often recommend mc as a file manager - it’s a terminal program that allows you to see both sides
(the source and the destination)
at the same time - it has two panes
and it makes comprehending what is being done
as well as doing it
fairly intuitive.

In my opinion it’s not as easy in a graphical file manager - because you do not get to see both sides simultaneously - and cannot this way as easily see what it is that is being attempted.

1 Like

I know that I should try to understand more of what I am doing but I am old…have been using Linux since Redhat…because I liked the idea and Window '98 kept crashing and seemed rubbish, but without trying to understand how it works. I have enjoyed and used many different distros since and am afraid have never tried to understand how it works. Just enjoyed it. So have patience, please, and I certainly appreciate your trying to dissect things for me.

Well, I have not solved my problem. Tried to make my main account acceptable. I can use it but fonts change and so does the size of windows. Very strange but I don;t want to lose access to my documents so hardly use it.If only I could access user privilege form my guest account…

The example you were given in the back, but there are missing quotation marks in the command (you can try to put “adwaita” between the quotation marks).

xfconf-query -c xsettings -p /Net/ThemeName -s "Matcha-dark-aliz"

Thanks. Tried with awaita, nothing happens

try dconf

click edit button: Value: adwaita if you have it, otherwise another one.
in case it does not change run in terminal

dconf update