From: Jonas Bernoulli Date: Sun, 26 Mar 2023 21:53:03 +0000 (+0200) Subject: Update to Transient v0.3.7-218-g3dbb22a X-Git-Tag: emacs-29.0.90~80 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=0337131bfa1;p=emacs.git Update to Transient v0.3.7-218-g3dbb22a --- diff --git a/doc/misc/transient.texi b/doc/misc/transient.texi index 850930a290f..33d689cc01b 100644 --- a/doc/misc/transient.texi +++ b/doc/misc/transient.texi @@ -2566,6 +2566,20 @@ currently exist. Yes, see @code{transient-display-buffer-action} in @ref{Configuration}. +@anchor{How can I copy text from the popup buffer?} +@appendixsec How can I copy text from the popup buffer? + +To be able to mark text in any transient popup buffer using the mouse, +you have to add the following binding. Note that the region won't be +visualized, while doing so. After you have quit the transient popup, +you will be able to yank it another buffer. + +@lisp +(keymap-set transient-predicate-map + "" + #'transient--do-stay) +@end lisp + @anchor{Why did some of the key bindings change?} @appendixsec Why did some of the key bindings change? diff --git a/lisp/transient.el b/lisp/transient.el index 96e711e950c..4affc414fa6 100644 --- a/lisp/transient.el +++ b/lisp/transient.el @@ -2516,17 +2516,22 @@ prefix argument and pivot to `transient-update'." (defun transient--invalid (msg) (ding) - (message "%s: `%s' (Use `%s' to abort, `%s' for help) [%s]" + (message "%s: `%s' (Use `%s' to abort, `%s' for help)%s" msg (propertize (key-description (this-single-command-keys)) 'face 'font-lock-warning-face) (propertize "C-g" 'face 'transient-key) (propertize "?" 'face 'transient-key) - ;; `this-command' is `transient--undefined' or similar at this - ;; point. Show the command the user actually tried to invoke. - (propertize (symbol-name (transient--suffix-symbol - this-original-command)) - 'face 'font-lock-warning-face)) + ;; `this-command' is `transient-undefined' or `transient-inapt'. + ;; Show the command (`this-original-command') the user actually + ;; tried to invoke. For an anonymous inapt command that is a + ;; lambda expression, which cannot be mapped to a symbol, so + ;; forgo displaying the command. + (if-let ((cmd (ignore-errors + (symbol-name (transient--suffix-symbol + this-original-command))))) + (format " [%s]" (propertize cmd 'face 'font-lock-warning-face)) + "")) (unless (and transient--transient-map (memq transient--transient-map overriding-terminal-local-map)) (let ((transient--prefix (or transient--prefix 'sic)))