Re: FVWM: Creating a wallpaper menu

From: Dominik Vogt <fvwm_at_fvwm.org>
Date: Tue, 7 Jan 2003 06:29:54 +0100

On Fri, Jan 03, 2003 at 01:05:11AM -0600, Mark A. Nicolosi wrote:
> I'm trying to create a wallpaper menu. First, in ~/images/wallpaper
> I have a bunch of directories to categorize my wallpaper. The
> menu should have those directories listed in the menu and popup
> submenus which contain the name of the images and then runs
> another function to display the image on the root window. I've
> got this half way figured out. I got menu of directories and...
> well, it'd be easier to explain if I just showed you what I have:
> (I think I may have figured out the most complicated of of getting
> this to _not_ work :)
>
> DestroyMenu WallpaperMenu
> AddToMenu WallpaperMenu
> + DynamicPopupAction Function CreateWallpaperMenu
> DestroyFunc CreateWallpaperMenu
> AddToFunc CreateWallpaperMenu
> + I DestroyMenu WallpaperMenu recreate WallpaperMenu
> + I PipeRead 'for i in `ls -d /home/mark/images/wallpaper/*/`; do echo AddToMenu WallpaperMenu \\"`basename $i | sed "s/_/ /g"`\\" Popup WallPaperMenu`basename $i` ; echo -e DestroyMenu WallpaperMenu`basename $i`\\nAddToMenu WallpaperMenu`basename $i`\\n+ DynamicPopupAction Function CreateWallpaperMenu2 $i WallpaperMenu`basename $i`; done'
> + I AddToMenu WallpaperMenu "" Nop
> + I AddToMenu WallpaperMenu "Recreate" Function CreateWallpaperMenu
>
> DestroyFunc CreateWallpaperMenu2
> AddToFunc CreateWallpaperMenu2
> + I Echo "In CreateWallpaperMenu2"
> + I DestroyMenu $2 recreate $2
> + I PipeRead 'for i in `ls $1`; do echo AddToMenu $2 \\"`basename $i | sed "s/_/ /g"`\\" Exec qiv -z $i
>
> CreateWallpaperMenu2 never gets called. If anyone can help (and be
> able to decipher that mess :) I'd appreciate the help. Thanks!

I have a setup in my config file that dynamically generates a menu
with backrounds, including thumbnails. The selected background is
remembered over a restart. It expects to find the images in
$HOME/.fvwm/backgrounds/ and stores the last selected background
in the file $HOME/.fvwm/background. The backgrounds must be named

  <somename>.bg.<extension>

e.g.

  marble.bg.jpg

and must be in a format understood by xv, which is used to set the
backgorund. The thumbnails that are used in the menu must be in
xpm format and be named

  <somename>.thumb.xpm

e.g.

  marble.thumb.xpm

(with the same name as the big image, of course)

Bye

Dominik ^_^ ^_^


--
Visit the official FVWM web page at <URL: http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to majordomo_at_fvwm.org.
To report problems, send mail to fvwm-owner_at_fvwm.org.
Received on Mon Jan 06 2003 - 23:30:01 GMT

This archive was generated by hypermail 2.3.0 : Mon Aug 29 2016 - 19:37:54 BST