diff options
Diffstat (limited to 'doc/lispref/commands.texi')
-rw-r--r-- | doc/lispref/commands.texi | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/doc/lispref/commands.texi b/doc/lispref/commands.texi index 6c68f70482a..3a2c7d019ef 100644 --- a/doc/lispref/commands.texi +++ b/doc/lispref/commands.texi @@ -2696,9 +2696,11 @@ from the terminal---not counting those generated by keyboard macros. @code{read-event}, @code{read-char}, and @code{read-char-exclusive} do not perform the translations described in @ref{Translation Keymaps}. If you wish to read a single key taking these translations into -account, use the function @code{read-key}: +account (for example, to read @ref{Function Keys} in a terminal or +@ref{Mouse Events} from @code{xterm-mouse-mode}), use the function +@code{read-key}: -@defun read-key &optional prompt +@defun read-key &optional prompt disable-fallbacks This function reads a single key. It is intermediate between @code{read-key-sequence} and @code{read-event}. Unlike the former, it reads a single key, not a key sequence. Unlike the latter, it does @@ -2708,6 +2710,14 @@ and @code{key-translation-map} (@pxref{Translation Keymaps}). The argument @var{prompt} is either a string to be displayed in the echo area as a prompt, or @code{nil}, meaning not to display a prompt. + +If argument @var{disable-fallbacks} is non-@code{nil} then the usual +fallback logic for unbound keys in @code{read-key-sequence} is not +applied. This means that mouse button-down and multi-click events +will not be discarded and @code{local-function-key-map} and +@code{key-translation-map} will not get applied. If @code{nil} or +unspecified, the only fallback disabled is downcasing of the last +event. @end defun @defun read-char-choice prompt chars &optional inhibit-quit |