[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master 4e207423eb 1/3: Add :type to wallpaper-command
From: |
Stefan Kangas |
Subject: |
master 4e207423eb 1/3: Add :type to wallpaper-command |
Date: |
Wed, 14 Sep 2022 09:02:30 -0400 (EDT) |
branch: master
commit 4e207423eb74fae014e40a3027919bb11beb29aa
Author: Stefan Kangas <stefankangas@gmail.com>
Commit: Stefan Kangas <stefankangas@gmail.com>
Add :type to wallpaper-command
* lisp/image/wallpaper.el (wallpaper-command): Make it easier to
customize by adding a :type declaration covering all supported values.
---
lisp/image/wallpaper.el | 25 +++++++++++++++++++++----
1 file changed, 21 insertions(+), 4 deletions(-)
diff --git a/lisp/image/wallpaper.el b/lisp/image/wallpaper.el
index e25ce448c1..a3bf44a5c3 100644
--- a/lisp/image/wallpaper.el
+++ b/lisp/image/wallpaper.el
@@ -47,6 +47,7 @@
;;; Finding the wallpaper command
(defvar wallpaper--default-commands
+ ;; When updating this, also update the custom :type for `wallpaper-command'.
'(
;; Sway (Wayland)
("swaybg" "-o" "*" "-i" "%f" "-m" "fill")
@@ -124,16 +125,32 @@ will be replaced as described in
`wallpaper-command-args'.")
"Executable used for setting the wallpaper.
A suitable command for your environment should be detected
automatically, so there is usually no need to customize this.
-However, if you do need to change this, you might also want to
-customize `wallpaper-command-args' to match.
+
+If you set this to any supported command using customize or
+`setopt', the user option `wallpaper-command-args' is
+automatically updated to match. If you need to change this to an
+unsupported command, you will want to manually customize
+`wallpaper-command-args' to match.
Note: If you find that you need to use a command in your
environment that is not automatically detected, we would love to
hear about it! Please send an email to bug-gnu-emacs@gnu.org and
tell us the command (and all options) that worked for you. You
can also use \\[report-emacs-bug]."
- :type '(choice string
- (const :tag "Not set" nil))
+ :type
+ '(choice
+ (radio
+ (const :tag "gsettings (GNOME)" "gsettings")
+ (const :tag "plasma-apply-wallpaperimage (KDE Plasma)"
"plasma-apply-wallpaperimage")
+ (const :tag "swaybg (Wayland/Sway)" "swaybg")
+ (const :tag "wbg (Wayland)" "wbg")
+ (const :tag "gm (X Window System)" "gm")
+ (const :tag "display (X Window System)" "display")
+ (const :tag "feh (X Window System)" "feh")
+ (const :tag "xwallpaper (X Window System)" "xwallpaper")
+ (const :tag "xloadimage (X Window System)" "xloadimage")
+ (const :tag "xsetbg (X Window System)" "xsetbg"))
+ (const :tag "Other (specify)" string))
:set #'wallpaper--set-wallpaper-command
:group 'image
:version "29.1")