Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I have a convertible notebook, and am writing a bash script to change from standard desktop to tablet mode. I am running XFCE.

Currently, the script is switching reading the orientation from a built-in accelerator on and off, but I want it to also switch the XFCE theme programmatically.

Apparently, xfce4-settings-manager does not have any command line options to switch the theme, and gtk-theme-switcher2 does not apply options for the scrollbar - which is one of the things that are larger with the theme that I want to switch to.

Is there any way to do that from command line?

share|improve this question
add comment

1 Answer

up vote 1 down vote accepted

Try xfconf-query like this

xfconf-query -c xsettings -p /Net/ThemeName -s Greybird

Where you can replace Greybird with the name of your theme. With quotes if it's not a single word.

Now if what you want is to change only some parts of your current theme, not switching to a different theme altogether, then this won't help. In that case I would suggest making multiple copies of your theme, naming them "My Neat Theme 1" "My neat Theme 2" and so on; make the modifications on each one, for each particular need and finally just switch between those themes using xfconf-query.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.