You are not logged in.
Hello there folks!
I've got a quick question for everyone. In my OS running OB, I use nitrogen to pull a random image file from a folder of 2,000+ desktop bg images and use a cron job to rotate images every X minutes. When I select my bg folder in right-click/Desktop Settings, it selects and loads the images in the window(albeit, taking a while). I wait for it to stop loading thumbnails and for the CPU to go idle then choose close but images continue to get pulled from the stock backdrop folder. When I open Desktop Settings, the folder has reverted to the stock location.
Is there a way to get the stock XFCE bg manager to save a folder location with many images?
Thanks for your time!
Offline
Hello and welcome.
If you are using a newer version of xfdesktop (the bg manager), then select the folder in the "Folder" field in its Settings dialog. This will display the image files in that folder. Manually select one of those images and it will save the folder location for you.
Edit: alternatively, you can use xfconf-query (if the xfconfd process is running) to change the background as well. You'll need to determine the X location of the wallpaper first. You can do this by running "xfconf-query -c xfce4-desktop -mv" in a terminal window and manually changing the wallpaper to see its location displayed in the terminal.
Last edited by ToZ (2022-05-26 01:15:54)
Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki | Community | Contribute ---
Offline
Hello and welcome.
If you are using a newer version of xfdesktop (the bg manager), then select the folder in the "Folder" field in its Settings dialog. This will display the image files in that folder. Manually select one of those images and it will save the folder location for you.
Edit: alternatively, you can use xfconf-query (if the xfconfd process is running) to change the background as well. You'll need to determine the X location of the wallpaper first. You can do this by running "xfconf-query -c xfce4-desktop -mv" in a terminal window and manually changing the wallpaper to see its location displayed in the terminal.
Selecting one of the images worked fantastically, thanks so much for your help!
Offline
Hello and welcome.
If you are using a newer version of xfdesktop (the bg manager), then select the folder in the "Folder" field in its Settings dialog. This will display the image files in that folder. Manually select one of those images and it will save the folder location for you.
Edit: alternatively, you can use xfconf-query (if the xfconfd process is running) to change the background as well. You'll need to determine the X location of the wallpaper first. You can do this by running "xfconf-query -c xfce4-desktop -mv" in a terminal window and manually changing the wallpaper to see its location displayed in the terminal.
I think fetching thumbnails takes a lot of time.
With yad version 12 (latest from github) is easy to make a script for this.
#!/usr/bin/env bash
monitor="$(xfconf-query -c displays -l | grep "/$(xfconf-query -c displays -p /ActiveProfile).*/Active$")"
monitor="${monitor%/${monitor##*/}*}"
monitor="monitor${monitor##*/}"
export monitor
yad --picture --on-top --size=fit --geometry="600x400-10-35" \
--image-on-top --no-markup --text="Ctrl+o or Right click -> Open\nto select images" \
--filename="$(xfconf-query -c xfce4-desktop -p /backdrop/screen0/${monitor}/workspace0/last-image)" \
--no-buttons --skip-taskbar --file-op \
--image-changed='bash -c "xfconf-query -c xfce4-desktop -p /backdrop/screen0/${monitor}/workspace0/last-image -s %s"'
Or even better maybe to find all the images and then use right click menu or lef/right keyboard keys to select background.
#!/usr/bin/env bash
monitor="$(xfconf-query -c displays -l | grep "/$(xfconf-query -c displays -p /ActiveProfile).*/Active$")"
monitor="${monitor%/${monitor##*/}*}"
monitor="monitor${monitor##*/}"
export monitor
yad --picture --on-top --size=fit --geometry="600x400-10-35" \
--image-on-top --no-markup --text="Left/Right key or Right click -> Next/prev\nto select background." \
--image-changed='bash -c "xfconf-query -c xfce4-desktop -p /backdrop/screen0/${monitor}/workspace0/last-image -s %s"' \
--no-buttons --file-op $(find "$HOME/Pictures" -type f -name '*.jpg' -o -name '*.png')
Do you want to exit the Circus?
https://www.youtube.com/watch?v=ZJwQicZHp_c
Offline
[ Generated in 0.010 seconds, 11 queries executed - Memory usage: 560.71 KiB (Peak: 561.55 KiB) ]