X-Git-Url: https://git.draconx.ca/gitweb/fvwmconf.git/blobdiff_plain/55b6d9c6d3425ae9bb03a6864ea8f78735dba642..d3d785e17abc600d804e075d95f1e8d0afbc1bee:/common/wallpaper diff --git a/common/wallpaper b/common/wallpaper index 5855f74..a80e320 100644 --- a/common/wallpaper +++ b/common/wallpaper @@ -1,6 +1,6 @@ # Stuff to handle pretty pictures on the background. SetEnv SETROOT "fvwm-root -r" -SetEnv BGFILE "$[FVWM_USERDIR]/wallpaper$[screen].png" +SetEnv BGFILE "$[FVWM_USERDIR]/.state/wallpaper$[screen].png" SetEnv BGROOT "$[HOME]/wallpaper" CopyMenuStyle * MenuWallpaper @@ -15,7 +15,7 @@ DestroyFunc MakeMenuWallpaper AddToFunc MakeMenuWallpaper + I DestroyMenu recreate MenuWallpaper + I AddToMenu MenuWallpaper Wallpaper Title - + I PipeRead '. $[FVWM_USERDIR]/bgmenu.sh $[BGROOT] MenuWallpaper' + + I PipeRead 'exec $[FVWM_USERDIR]/scripts/bgmenu.zsh $[BGROOT] MenuWallpaper' DestroyFunc SetWallpaper AddToFunc SetWallpaper @@ -23,4 +23,8 @@ AddToFunc SetWallpaper + I Exec exec $[SETROOT] "$[BGFILE]" AddToFunc InitFunction - + I Exec exec $[SETROOT] "$[BGFILE]" + + I Exec if [ -f "$[BGFILE]" ]; then \ + $[SETROOT] "$[BGFILE]"; \ + else \ + $[SETROOT] "$($[FVWM_USERDIR]/scripts/randombg.pl $[BGROOT])"; \ + fi