"Merge the custom theme THEME's settings into the current buffer."
(interactive
(list
+ ;; TODO: Add `minibuffer-action'.
(intern (completing-read "Merge custom theme: "
(mapcar #'symbol-name
- (custom-available-themes))))))
+ (custom-available-themes)))))
+ custom-new-theme-mode)
(unless (eq theme 'user)
(unless (custom-theme-name-valid-p theme)
(error "Invalid theme name `%s'" theme))
(intern (completing-read "Describe custom theme: "
(mapcar #'symbol-name
(custom-available-themes))))))
+ (setq theme (if (stringp theme) (intern theme) theme))
(unless (custom-theme-name-valid-p theme)
(error "Invalid theme name `%s'" theme))
(help-setup-xref (list 'describe-theme theme)
(with-current-buffer standard-output
(describe-theme-1 theme))))
+(put 'describe-theme 'minibuffer-action "describe")
+
(defun describe-theme-from-file (theme &optional file short)
"Describe THEME from its FILE without loading it.
(mapcar #'symbol-name
(custom-available-themes))))
nil nil))
+ (setq theme (if (stringp theme) (intern theme) theme)
+ ;; If THEME is already enabled, re-enable it after loading, even
+ ;; if NO-ENABLE is non-nil.
+ no-enable (and no-enable (not (custom-theme-enabled-p theme))))
(unless (custom-theme-name-valid-p theme)
(error "Invalid theme name `%s'" theme))
- ;; If THEME is already enabled, re-enable it after loading, even if
- ;; NO-ENABLE is t.
- (if no-enable
- (setq no-enable (not (custom-theme-enabled-p theme))))
;; If reloading, clear out the old theme settings.
(when (custom-theme-p theme)
(disable-theme theme)
(enable-theme theme))
t)
+(put 'load-theme 'minibuffer-action "load")
+
(defun theme-list-variants (theme &rest list)
"Return a list of theme variants for THEME.
By default this will use all known custom themes (see
(completing-read
"Enable custom theme: "
obarray (lambda (sym) (get sym 'theme-settings)) t))))
+ (setq theme (if (stringp theme) (intern theme) theme))
(unless (custom-theme-p theme)
(error "Undefined Custom theme %s" theme))
(let ((settings (get theme 'theme-settings)) ; '(prop symbol theme value)
;; Allow callers to react to the enabling.
(run-hook-with-args 'enable-theme-functions theme))
+(put 'enable-theme 'minibuffer-action "enable")
+
(defcustom custom-enabled-themes nil
"List of enabled Custom Themes, highest precedence first.
This list does not include the `user' theme, which is set by
(interactive (list (intern
(completing-read
"Disable custom theme: "
- (mapcar #'symbol-name custom-enabled-themes)
+ (completion-table-dynamic
+ (lambda (_) (mapcar #'symbol-name
+ custom-enabled-themes)))
nil t))))
+ (setq theme (if (stringp theme) (intern theme) theme))
(when (custom-theme-enabled-p theme)
(let ((settings (get theme 'theme-settings)))
(dolist (s settings)
;; Allow callers to react to the disabling.
(run-hook-with-args 'disable-theme-functions theme)))
+(put 'disable-theme 'minibuffer-action "disable")
+
;; Only used if window-system not null.
(declare-function x-get-resource "frame.c"
(attribute class &optional component subclass))
"Pop to a buffer to describe ICON."
(interactive
(list (intern (completing-read "Describe icon: " obarray 'iconp t))))
- (let ((help-buffer-under-preparation t))
+ (let ((icon (if (stringp icon) (intern icon) icon))
+ (help-buffer-under-preparation t))
(help-setup-xref (list #'describe-icon icon)
(called-interactively-p 'interactive))
(with-help-window (help-buffer)
(insert "\nSpecification not including inheritance and theming:\n")
(icons--describe-spec plain)))))))
+(put 'describe-icon 'minibuffer-action "describe")
+
(defun icons--describe-spec (spec)
(dolist (elem spec)
(let ((type (car elem))
packages nil t nil nil (when guess
(symbol-name guess)))))
(list (and (> (length val) 0) (intern val)))))))
+ (setq package (if (stringp package) (intern package) package))
(if (not (or (package-desc-p package) (and package (symbolp package))))
(message "No package specified")
(help-setup-xref (list #'describe-package package)
(with-current-buffer standard-output
(describe-package-1 package)))))
+(put 'describe-package 'minibuffer-action "describe")
+
(defface package-help-section-name
'((t :inherit (bold font-lock-function-name-face)))
"Face used on section names in package description buffers."
(t
(error "No such minor mode: %s" minor-mode)))))
+(put 'describe-minor-mode 'minibuffer-action "describe")
+
;; symbol
(defun describe-minor-mode-completion-table-for-symbol ()
;; In order to list up all minor modes, minor-mode-list
"Input method: %s (`%s' in mode line) for %s\n %s\n"
input-method (nth 3 elt) (nth 1 elt) (nth 4 elt)))))))))))
+(put 'describe-input-method 'minibuffer-action "describe")
+
(defun describe-current-input-method ()
"Describe the input method currently in use.
This is a subroutine for `describe-input-method'."
(setq aliases (cdr aliases)))
(insert ")\n")))
(setq l (cdr l))))))))))
+
+(put 'describe-language-environment 'minibuffer-action "describe")
+
\f
;;; Locales.
(defun describe-character-set (charset)
"Display information about built-in character set CHARSET."
(interactive (list (read-charset "Charset: ")))
+ (setq charset (if (stringp charset) (intern charset) charset))
(let ((help-buffer-under-preparation t))
(or (charsetp charset)
(error "Invalid charset: %S" charset))
(let ((print-length 10) (print-level 2))
(princ (funcall (nth 2 elt) val) (current-buffer))))
(insert ?\n))))))))
+
+(put 'describe-character-set 'minibuffer-action "describe")
+
\f
;;; CODING-SYSTEM
(defun describe-coding-system (coding-system)
"Display information about CODING-SYSTEM."
(interactive "zDescribe coding system (default current choices): ")
- (let ((help-buffer-under-preparation t))
+ (let ((coding-system (if (stringp coding-system) (intern coding-system)
+ coding-system))
+ (help-buffer-under-preparation t))
(if (null coding-system)
(describe-current-coding-system)
(help-setup-xref (list #'describe-coding-system coding-system)
(goto-char (point-max))
(setq charsets (cdr charsets))))))))))))
+(put 'describe-coding-system 'minibuffer-action "describe")
+
;;;###autoload
(defun describe-current-coding-system-briefly ()
"Display coding systems currently used in a brief format in echo area.
(with-output-to-temp-buffer "*Help*"
(describe-font-internal font-info)))))
+(put 'describe-font 'minibuffer-action "describe")
+
(defvar mule--print-opened)
(defun mule--kbd-at (point)
(with-current-buffer standard-output
(print-fontset fontset t)))))
+(put 'describe-fontset 'minibuffer-action "describe")
+
(declare-function fontset-plain-name "fontset" (fontset))
;;;###autoload