aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard M. Stallman2003-01-13 07:59:04 +0000
committerRichard M. Stallman2003-01-13 07:59:04 +0000
commit48bf63e33d3d89655874718297cc724f71412f1f (patch)
tree30137a4ed101a91581ce48c20cb314c07b2e27c8
parent978a673fa45584fea87ca5d46655b3961f9137bd (diff)
downloademacs-48bf63e33d3d89655874718297cc724f71412f1f.tar.gz
emacs-48bf63e33d3d89655874718297cc724f71412f1f.zip
(Changing Key Bindings) <define-key>: Mention how to define a default binding.
-rw-r--r--lispref/keymaps.texi8
1 files changed, 6 insertions, 2 deletions
diff --git a/lispref/keymaps.texi b/lispref/keymaps.texi
index c087b968793..5102800d15e 100644
--- a/lispref/keymaps.texi
+++ b/lispref/keymaps.texi
@@ -1063,6 +1063,10 @@ in another keymap reached from @var{keymap}.) The argument
1063meaningful. (For a list of meaningful types, see @ref{Key Lookup}.) 1063meaningful. (For a list of meaningful types, see @ref{Key Lookup}.)
1064The value returned by @code{define-key} is @var{binding}. 1064The value returned by @code{define-key} is @var{binding}.
1065 1065
1066If @var{key} is @code{[t]}, this sets the default binding in
1067@var{keymap}. When an event has no binding of its own, the Emacs
1068command loop uses the keymap's default binding, if there is one.
1069
1066@cindex invalid prefix key error 1070@cindex invalid prefix key error
1067@cindex key sequence error 1071@cindex key sequence error
1068Every prefix of @var{key} must be a prefix key (i.e., bound to a keymap) 1072Every prefix of @var{key} must be a prefix key (i.e., bound to a keymap)
@@ -1072,8 +1076,8 @@ key so that the rest of @var{key} can be defined as specified.
1072 1076
1073If there was previously no binding for @var{key} in @var{keymap}, the 1077If there was previously no binding for @var{key} in @var{keymap}, the
1074new binding is added at the beginning of @var{keymap}. The order of 1078new binding is added at the beginning of @var{keymap}. The order of
1075bindings in a keymap makes no difference in most cases, but it does 1079bindings in a keymap makes no difference for keyboard input, but it
1076matter for menu keymaps (@pxref{Menu Keymaps}). 1080does matter for menu keymaps (@pxref{Menu Keymaps}).
1077@end defun 1081@end defun
1078 1082
1079 Here is an example that creates a sparse keymap and makes a number of 1083 Here is an example that creates a sparse keymap and makes a number of