Search Members Help

» Welcome Guest
[ Log In :: Register ]

Mini-ITX Boards Sale, Fanless BareBones Mini-ITX, Bootable 1G DSL USBs, 533MHz Fanless PC <-- SALE $200 each!
Get The Official Damn Small Linux Book. DSL Market , Great VPS hosting provided by Tektonic
 

[ Track this topic :: Email this topic :: Print this topic ]

reply to topic new topic new poll
Topic: Fluxbox auto changing background< Next Oldest | Next Newest >
Shades Offline





Group: Members
Posts: 20
Joined: Oct. 2005
Posted: Dec. 12 2005,06:09 QUOTE

I'm wondering if anyone would happen to know the code I can put in my fluxbox init file to tell it to change the wallpaper after a certain amount of time? I've got several different backgrounds I want to display and thought it would be cool to rotate them after a time.

:cool:
Back to top
Profile PM 
mikshaw Offline





Group: Members
Posts: 4856
Joined: July 2004
Posted: Dec. 12 2005,16:40 QUOTE

There's a script here that will set a random background from a given directory:
http://damnsmalllinux.org/cgi-bin....;t=2456

I've never done anything related to rotation, so couldn't tell you how to accomplish that.  It could be as simple as putting the main block of code within a function and having it triggered by a loop and a sleep command.


--------------
http://www.tldp.org/LDP/intro-linux/html/index.html
Back to top
Profile PM WEB 
Shades Offline





Group: Members
Posts: 20
Joined: Oct. 2005
Posted: Dec. 15 2005,07:13 QUOTE

Thanks Mikshaw...I used the link and the code you had on it. The only thing is I've never created anything like that and I'm not so sure where to start.  ???

I pasted it in Beaver and saved it as a .sh file. I placed it in the backgrounds folder but wasn't sure how to reference it in the init file.

:cool:
Back to top
Profile PM 
mikshaw Offline





Group: Members
Posts: 4856
Joined: July 2004
Posted: Dec. 15 2005,16:00 QUOTE

That script was written mainly to pick a random background only once, when fluxbox is started.  It's meant to be run from .fluxbox/init
Code Sample
session.screen0.rootCommand: sh  /path/to/script

If you make the script executable (chmod +x /path/to/script) you can leave out the "sh".

Note libretto's comment: "Took out the star (*) in the bg_pics line adn [sic] the code works".  I think i was testing it with gnu find.

In its current state it will not do a slideshow...it runs once and quits. This is not a task that really interests me, so i haven't done any more work or research on it.
A simple solution may be to set up a hotkey combo in fluxbox linked to the script...any time you want a new background just hit the appropriate keys.


--------------
http://www.tldp.org/LDP/intro-linux/html/index.html
Back to top
Profile PM WEB 
SaidinUnleashed Offline





Group: Members
Posts: 1428
Joined: Mar. 2004
Posted: Dec. 15 2005,18:51 QUOTE

This is more of a programming/scripting topic.

Moved~

--------------
They say if you play a Microsoft CD backwards, you hear satanic messages. That's nothing, cause if you play it forwards, it installs Windows.

Unleash the power of the TILDE~~~
Back to top
Profile PM AOL MSN YIM 
4 replies since Dec. 12 2005,06:09 < Next Oldest | Next Newest >

[ Track this topic :: Email this topic :: Print this topic ]

 
reply to topic new topic new poll
Quick Reply: Fluxbox auto changing background

Do you wish to enable your signature for this post?
Do you wish to enable emoticons for this post?
Track this topic
View All Emoticons
View iB Code