summaryrefslogtreecommitdiff
path: root/lisp/face-remap.el
diff options
context:
space:
mode:
authorJuri Linkov <juri@linkov.net>2022-07-06 20:39:41 +0300
committerJuri Linkov <juri@linkov.net>2022-07-06 20:39:41 +0300
commit0e99046d62e71fb874cb9010e60ecfee289f84e9 (patch)
treef949517518d9ebef48923c6ecc409f43c2db9fa5 /lisp/face-remap.el
parent6a7bb1ddbc9837b2d2af60236be58723114855ac (diff)
downloademacs-0e99046d62e71fb874cb9010e60ecfee289f84e9.tar.gz
emacs-0e99046d62e71fb874cb9010e60ecfee289f84e9.tar.bz2
emacs-0e99046d62e71fb874cb9010e60ecfee289f84e9.zip
Add new args MESSAGE and TIMEOUT to set-transient-map (bug#21634)
* lisp/subr.el (set-transient-map): Add new args MESSAGE and TIMEOUT. (set-transient-map-timeout, set-transient-map-timer): New variables. * lisp/international/emoji.el (emoji-zoom-increase): * lisp/indent.el (indent-rigidly): * lisp/face-remap.el (text-scale-adjust, global-text-scale-adjust): Use the arg MESSAGE of set-transient-map. * doc/lispref/keymaps.texi (Controlling Active Maps): Mention new args MESSAGE and TIMEOUT of set-transient-map.
Diffstat (limited to 'lisp/face-remap.el')
-rw-r--r--lisp/face-remap.el17
1 files changed, 6 insertions, 11 deletions
diff --git a/lisp/face-remap.el b/lisp/face-remap.el
index 467ccbc2991..fd49c81ab3f 100644
--- a/lisp/face-remap.el
+++ b/lisp/face-remap.el
@@ -408,20 +408,15 @@ See also the related command `global-text-scale-adjust'."
(?0 0)
(_ inc))))
(text-scale-increase step)
- ;; (unless (zerop step)
- (message (substitute-command-keys
- "Use \\`+',\\`-',\\`0' for further adjustment"))
(set-transient-map
(let ((map (make-sparse-keymap)))
(dolist (mods '(() (control)))
- (dolist (key '(?- ?+ ?= ?0)) ;; = is often unshifted +.
+ (dolist (key '(?+ ?= ?- ?0)) ;; = is often unshifted +.
(define-key map (vector (append mods (list key)))
(lambda () (interactive) (text-scale-adjust (abs inc))))))
map)
- nil
- ;; Clear the prompt after exiting.
- (lambda ()
- (message ""))))))
+ nil nil
+ "Use %k for further adjustment"))))
(defvar-local text-scale--pinch-start-scale 0
"The text scale at the start of a pinch sequence.")
@@ -515,15 +510,15 @@ See also the related command `text-scale-adjust'."
(not global-text-scale-adjust-resizes-frames)))
(set-face-attribute 'default nil :height new)))
(when (characterp key)
- (message (substitute-command-keys
- "Use \\`+',\\`-',\\`0' for further adjustment"))
(set-transient-map
(let ((map (make-sparse-keymap)))
(dolist (mod '(() (control meta)))
(dolist (key '(?+ ?= ?- ?0))
(define-key map (vector (append mod (list key)))
'global-text-scale-adjust)))
- map))))))
+ map)
+ nil nil
+ "Use %k for further adjustment")))))
;; ----------------------------------------------------------------