Changing the backdrop

Iain Scurrah iscurrah at fmail.co.uk
Tue Nov 8 21:53:55 CET 2005


Hi,

Many thanks for the hardwork of all involved in the Xfce project. I'm a new 
convert, (having found out that no desktop icons does not necessarily mean 
"very scary - let me out please...").

One hangover from my KDE days though, is a desire to change my backdrop 
regularly...

Currently I've got a list of all the photos I want to see sometime as a 
backdrop and a little script in ~/Desktop/Autostart/change_backdrop.sh

#!/bin/bash
while  [ 0 ]
do
   sleep 300
   nice xfdesktop -reload
done

Dead simple - and it works well, every 5 mins, I get a new backdrop. 

The only problem is that it never ends. After Exiting Xfce and re-logging in, 
either as myself, or as my wife, the script keeps running. I would have two 
copies of this script running, my wife has one (and she uses KDE (although 
she wouldn't be able to tell you that)).

Is there anyway I can get Xfce to kill this script on exiting Xfce? Maybe I 
could use the session manager to start the (or similar) script when I login, 
but it would need to kill it on logout...

A test that Xfce is running in the while loop would (probably) not be good 
enough because if I log back into Xfce a second time, the script will 
contine, and if my wife logs into KDE, then the xfdesktop is likely to be 
reloaded (and the worst thing about this is that it changes her screen 
resolution).

Thanks again for everything you've all put into this project, and thanks in 
advance for any advice you can give me.

Iain Scurrah.



More information about the Xfce mailing list