Commit c7d6eb2
authored
Fix XFCE wallpaper scripts for missing backdrop properties (varietywalls#815)
On fresh XFCE installs or systems where wallpaper was never set via XFCE,
the backdrop properties (e.g., /backdrop/screen0/monitor0/workspace0/last-image)
don't exist. This causes both scripts to fail silently or with errors.
Changes to set_wallpaper:
- Check if existing backdrop properties exist first
- If none exist, detect connected monitors via xrandr and create properties
- Use xfconf-query --create (-n) flag to initialize missing properties
- Set a sensible default image-style (zoomed)
Changes to get_wallpaper:
- Dynamically find the first existing backdrop property instead of
hardcoding monitor0
- Handle missing properties gracefully by returning nothing
Fixes varietywalls#1641 parent be5ae11 commit c7d6eb2
2 files changed
+34
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
15 | | - | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
16 | 21 | | |
17 | 22 | | |
18 | 23 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
198 | 198 | | |
199 | 199 | | |
200 | 200 | | |
201 | | - | |
202 | | - | |
203 | | - | |
204 | | - | |
205 | | - | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
206 | 229 | | |
207 | 230 | | |
208 | 231 | | |
| |||
0 commit comments