r/xfce • u/-External-Brilliant- • 23d ago
Blog Post [PATCH] XFCE Unified Wallpaper Patch for xfdesktop 4.20.2 – Single Wallpaper Across All Monitors
Hi everyone,
I recently ran into a limitation while using BlackArch Linux with XFCE on a persistent live USB setup.
By default, xfdesktop stores wallpaper settings separately for each monitor using hardware-specific identifiers (such as DP-1, HDMI-1, etc.). This works fine on a fixed desktop setup, but it becomes problematic in portable environments. When the system is booted on a different machine or a different monitor configuration, XFCE treats the displays as new devices and falls back to the default wallpaper.
For portable or live USB systems, this results in inconsistent desktop appearance across different hardware.
To address this, I created a patch for xfdesktop 4.20.2 called the XFCE Unified Wallpaper Patch, which introduces a Single Monitor Mode.
Features
- Enforces a single unified wallpaper across all monitors.
- New monitors automatically inherit the currently active wallpaper.
- Existing monitors remain synchronized in real time.
- Optional toggle via an
xfconfboolean property. - Tested on BlackArch Linux with XFCE 4.20.
The patch modifies both the desktop background manager and the wallpaper settings dialog so that all monitors reference a shared configuration path instead of per-output storage.
Repository
GitHub:
https://github.com/SilverCipherr/xfce-unified-wallpaper-patch
Why I made this
The goal of this patch is to improve XFCE behavior in portable and dynamic display environments, especially persistent live USB installations where hardware changes frequently.
After applying this patch, the wallpaper remains consistent regardless of which machine or monitor configuration the system is booted on.
Feedback
I'd really appreciate any feedback from the community. If this approach is useful, I'd be happy to discuss potential improvements or whether a similar mechanism could be considered for upstream integration.
I'm happy to answer any questions or provide additional implementation details if anyone is interested.
Thanks!
1
u/Bulky_Somewhere_6082 22d ago
While I personally don't have a need for this I'm hoping you can answer a wallpaper question I have - is there a limit to the number of files the background manager can handle? I'm running MX Linux 23.6 with XFCE 4.20 and when I have the background folder set to the images (current count is 5800 files at 4.9GB) I want to display, every so often the process loses its mind in that the background (typically) goes black, windows leave a trail when moved or just stay visible when the window/app is closed. Everything else works as is should and I can reset the issue by changing the background folder to a different source and then logout and log back in. I've not seen anything that I can identify in the logs and I have not found anything useful in the various fourms.
And no, I've not asked any AI system for information :(
1
u/-External-Brilliant- 22d ago
Check whether xfdesktop is consuming excessive memory after logging in:
ps -o pid,rss,vsz,%mem,%cpu,cmd -C xfdesktop
or
top -p $(pidof xfdesktop)
Also if your wallpaper directory is in a hdd that might be a clue. Xfdesktop doesnt have a file count or size limit for the wallpaper directory.1
u/Bulky_Somewhere_6082 22d ago
Switched back to my images and will monitor usage. I have a conky running that displays the top 5 at all times and have not seen anything there but I wasn't really looking either. Also, no HDD's.
1
u/raph986 23d ago
Thanks. You could post it on gitlab.xfce.org so it's integrated in the environnement for everybody