class Menu
def to_s
File::open(“#{ENV[’HOME’]}/.fluxbox/imag
f.puts “[submenu] (Backgrounds) {#{ARGV[0]}}”
f.puts “\t[exec] (Update Backgrounds) {makeimagemenu.rb \”#{ARGV[0]}\“}”
Dir::entries(“#{ENV[’HOME’]}/.fluxbox/ba
f.puts “\t[exec] (#{image[0..-5].gsub(”-“,” “).gsub(”_“, ” “).capitalize}) {Esetroot -c #{ENV[’HOME’]}/.fluxbox/backgrounds/#{im
end
f.puts “[end]”
end
end
end
print Menu::new
I know, you’re thinking “What the hell does this do?” Here’s what it does. In fluxbox there is a file called menu. It’s read every time you right click the background. You can include other files. So if you include “imagemenu” then you can use this program to make an easy menu for setting your background.
Here’s how it works. When you get your new account you pull up your console and type ‘makeimagemenu.rb “Whatever Your Menu Is Called”’ and then it makes the menu. Drop all the image files you want into the .fluxbox/backgrounds directory and select “update menu” and it’ll add them to the menu. Then just select the name from the menu and it sets that image as your background. Nice and simple like. Oh, and if you want to change the name of the menu just re-run it from the console.