diff options
| -rw-r--r-- | lisp/image/wallpaper.el | 43 |
1 files changed, 41 insertions, 2 deletions
diff --git a/lisp/image/wallpaper.el b/lisp/image/wallpaper.el index ff47d37e3a6..effa25b1804 100644 --- a/lisp/image/wallpaper.el +++ b/lisp/image/wallpaper.el | |||
| @@ -62,6 +62,16 @@ | |||
| 62 | ;; XFCE | 62 | ;; XFCE |
| 63 | ("xfconf-query" "-c" "xfce4-desktop" "-p" | 63 | ("xfconf-query" "-c" "xfce4-desktop" "-p" |
| 64 | "/backdrop/screen0/monitoreDP/workspace0/last-image" "-s" "%f") | 64 | "/backdrop/screen0/monitoreDP/workspace0/last-image" "-s" "%f") |
| 65 | ;; LXDE | ||
| 66 | ("pcmanfm" "--set-wallpaper=%f") | ||
| 67 | ;; LXQt | ||
| 68 | ("pcmanfm-qt" "--set-wallpaper=%f") ; "--wallpaper-mode=MODE" | ||
| 69 | ;; ;; Mate | ||
| 70 | ;; ("gsettings" "set" "org.mate.background" "picture-filename" "%f") | ||
| 71 | ;; ;; Cinnamon | ||
| 72 | ;; ("gsettings" "set" "org.cinnamon.desktop.background" "picture-uri" "file://%f") | ||
| 73 | ;; ;; Deepin | ||
| 74 | ;; ("gsettings" "set" "com.deepin.wrap.gnome.desktop.background" "picture-uri" "file://%f") | ||
| 65 | ;; Sway (Wayland) | 75 | ;; Sway (Wayland) |
| 66 | ("swaybg" "-o" "*" "-i" "%f" "-m" "fill") | 76 | ("swaybg" "-o" "*" "-i" "%f" "-m" "fill") |
| 67 | ;; Wayland General | 77 | ;; Wayland General |
| @@ -95,13 +105,40 @@ In each of the command line arguments, \"%f\", \"%h\" and \"%w\" | |||
| 95 | will be replaced as described in `wallpaper-command-args'.") | 105 | will be replaced as described in `wallpaper-command-args'.") |
| 96 | 106 | ||
| 97 | (cl-defmethod wallpaper--check-command ((_type (eql 'gsettings))) | 107 | (cl-defmethod wallpaper--check-command ((_type (eql 'gsettings))) |
| 98 | (member "GNOME" (xdg-current-desktop))) | 108 | (or (member (downcase (env "DESKTOP_SESSION")) |
| 109 | '("gnome" "gnome" "gnome-wayland" "gnome-xorg" | ||
| 110 | "unity" "ubuntu" "pantheon" "budgie-desktop" | ||
| 111 | "pop")) | ||
| 112 | (member "GNOME" (xdg-current-desktop)) | ||
| 113 | (member "Budgie" (xdg-current-desktop)) | ||
| 114 | (member "GNOME-Classic" (xdg-current-desktop)))) | ||
| 99 | 115 | ||
| 100 | (cl-defmethod wallpaper--check-command ((_type (eql 'plasma-apply-wallpaperimage))) | 116 | (cl-defmethod wallpaper--check-command ((_type (eql 'plasma-apply-wallpaperimage))) |
| 101 | (member "KDE" (xdg-current-desktop))) | 117 | (member "KDE" (xdg-current-desktop))) |
| 102 | 118 | ||
| 103 | (cl-defmethod wallpaper--check-command ((_type (eql 'xfconf-query))) | 119 | (cl-defmethod wallpaper--check-command ((_type (eql 'xfconf-query))) |
| 104 | (member "XFCE" (xdg-current-desktop))) | 120 | (or (member (lowercase (env "DESKTOP_SESSION")) |
| 121 | '("xubuntu" "ubuntustudio")) | ||
| 122 | (member "XFCE" (xdg-current-desktop)))) | ||
| 123 | |||
| 124 | (cl-defmethod wallpaper--check-command ((_type (eql 'pcmanf))) | ||
| 125 | (member "LXDE" (xdg-current-desktop))) | ||
| 126 | |||
| 127 | (cl-defmethod wallpaper--check-command ((_type (eql 'pcmanf-qt))) | ||
| 128 | (or (member (lowercase (env "DESKTOP_SESSION")) | ||
| 129 | '("lubuntu" "lxqt")) | ||
| 130 | (member "LXQt" (xdg-current-desktop)))) | ||
| 131 | |||
| 132 | ;; (cl-defmethod wallpaper--check-command ((_type (eql 'gsettings))) | ||
| 133 | ;; (or (equal "mate" (lowercase (env "DESKTOP_SESSION"))) | ||
| 134 | ;; (member "MATE" (xdg-current-desktop)))) | ||
| 135 | |||
| 136 | ;; (cl-defmethod wallpaper--check-command ((_type (eql 'gsettings))) | ||
| 137 | ;; (or (equal "cinnamon" (lowercase (env "DESKTOP_SESSION"))) | ||
| 138 | ;; (member "X-Cinnamon" (xdg-current-desktop)))) | ||
| 139 | |||
| 140 | ;; (cl-defmethod wallpaper--check-command ((_type (eql 'gsettings))) | ||
| 141 | ;; (member "Deepin" (xdg-current-desktop))) | ||
| 105 | 142 | ||
| 106 | (cl-defmethod wallpaper--check-command ((_type (eql 'swaybg))) | 143 | (cl-defmethod wallpaper--check-command ((_type (eql 'swaybg))) |
| 107 | (and (getenv "WAYLAND_DISPLAY") | 144 | (and (getenv "WAYLAND_DISPLAY") |
| @@ -163,6 +200,8 @@ systems, where a native API is used instead." | |||
| 163 | (const :tag "gsettings (GNOME)" "gsettings") | 200 | (const :tag "gsettings (GNOME)" "gsettings") |
| 164 | (const :tag "plasma-apply-wallpaperimage (KDE Plasma)" "plasma-apply-wallpaperimage") | 201 | (const :tag "plasma-apply-wallpaperimage (KDE Plasma)" "plasma-apply-wallpaperimage") |
| 165 | (const :tag "xfconf-query (XFCE)" "xfconf-query") | 202 | (const :tag "xfconf-query (XFCE)" "xfconf-query") |
| 203 | (const :tag "pcmanf (LXDE)" "pcmanf") | ||
| 204 | (const :tag "pcmanf-qt (LXQt)" "pcmanf-qt") | ||
| 166 | (const :tag "swaybg (Wayland/Sway)" "swaybg") | 205 | (const :tag "swaybg (Wayland/Sway)" "swaybg") |
| 167 | (const :tag "wbg (Wayland)" "wbg") | 206 | (const :tag "wbg (Wayland)" "wbg") |
| 168 | (const :tag "gm (X Window System)" "gm") | 207 | (const :tag "gm (X Window System)" "gm") |