"Default keymap for ESC (meta) commands.
The normal global definition of the character ESC indirects to this keymap.")
-(defvar ctl-x-map nil
- "Default keymap for C-x commands.
-The normal global definition of the character C-x indirects to this keymap.")
-
(defvar ctl-x-4-map (make-sparse-keymap)
"Keymap for subcommands of C-x 4.")
(defalias 'ctl-x-4-prefix ctl-x-4-map)
-(define-key ctl-x-map "4" 'ctl-x-4-prefix)
(defvar ctl-x-5-map (make-sparse-keymap)
"Keymap for frame commands.")
(defalias 'ctl-x-5-prefix ctl-x-5-map)
-(define-key ctl-x-map "5" 'ctl-x-5-prefix)
(defvar tab-prefix-map (make-sparse-keymap)
"Keymap for tab-bar related commands.")
-(define-key ctl-x-map "t" tab-prefix-map)
+
+(defvar ctl-x-map
+ (let ((map (make-keymap)))
+ (define-key map "4" 'ctl-x-4-prefix)
+ (define-key map "5" 'ctl-x-5-prefix)
+ (define-key map "t" tab-prefix-map)
+
+ (define-key map "b" #'switch-to-buffer)
+ (define-key map "l" #'kill-buffer)
+ (define-key map "\C-u" #'upcase-region) (put 'upcase-region 'disabled t)
+ (define-key map "\C-l" #'downcase-region) (put 'downcase-region 'disabled t)
+ (define-key map "<" #'scroll-left)
+ (define-key map ">" #'scroll-right)
+ map)
+ "Default keymap for C-x commands.
+The normal global definition of the character C-x indirects to this keymap.")
+(fset 'Control-X-prefix ctl-x-map)
+(make-obsolete 'Control-X-prefix 'ctl-x-map "28.1")
(defvar global-map
(let ((map (make-keymap)))
(define-key map "\C-b" #'backward-char)
(define-key map "\C-e" #'end-of-line)
(define-key map "\C-f" #'forward-char)
- (define-key map "\C-z" #'suspend-emacs) ;FIXME: Re-bound later!
-
+ (define-key map "\C-z" #'suspend-emacs) ;FIXME: Re-bound later!
+ (define-key map "\C-x\C-z" #'suspend-emacs) ;FIXME: Re-bound later!
(define-key map "\C-v" #'scroll-up-command)
(define-key map "\C-]" #'abort-recursive-edit)
map)
Fput (intern_c_string ("erase-buffer"), Qdisabled, Qt);
}
-
-void
-keys_of_buffer (void)
-{
- initial_define_key (control_x_map, 'b', "switch-to-buffer");
- initial_define_key (control_x_map, 'k', "kill-buffer");
-}
void
keys_of_casefiddle (void)
{
- initial_define_key (control_x_map, Ctl ('U'), "upcase-region");
- Fput (intern ("upcase-region"), Qdisabled, Qt);
- initial_define_key (control_x_map, Ctl ('L'), "downcase-region");
- Fput (intern ("downcase-region"), Qdisabled, Qt);
-
initial_define_key (meta_map, 'u', "upcase-word");
initial_define_key (meta_map, 'l', "downcase-word");
initial_define_key (meta_map, 'c', "capitalize-word");
initialization; use-global-map doesn't affect these; it sets
current_global_map instead. */
extern Lisp_Object meta_map;
-extern Lisp_Object control_x_map;
/* If not Qnil, this is a switch-frame event which we decided to put
off until the end of a key sequence. This should be read as the
#endif
keys_of_casefiddle ();
- keys_of_buffer ();
keys_of_keyboard ();
keys_of_window ();
}
void
keys_of_keyboard (void)
{
- initial_define_key (control_x_map, Ctl ('Z'), "suspend-emacs");
initial_define_key (meta_map, Ctl ('C'), "exit-recursive-edit");
initial_define_key (meta_map, 'x', "execute-extended-command");
Lisp_Object meta_map; /* The keymap used for globally bound
ESC-prefixed default commands. */
-Lisp_Object control_x_map; /* The keymap used for globally bound
- C-x-prefixed default commands. */
-
/* The keymap used by the minibuf for local
bindings when spaces are allowed in the
minibuf. */
Fset (intern_c_string ("esc-map"), meta_map);
Ffset (intern_c_string ("ESC-prefix"), meta_map);
- control_x_map = Fmake_keymap (Qnil);
- Fset (intern_c_string ("ctl-x-map"), control_x_map);
- Ffset (intern_c_string ("Control-X-prefix"), control_x_map);
-
exclude_keys = pure_list
(pure_cons (build_pure_c_string ("DEL"), build_pure_c_string ("\\d")),
pure_cons (build_pure_c_string ("TAB"), build_pure_c_string ("\\t")),
extern void init_buffer_once (void);
extern void init_buffer (void);
extern void syms_of_buffer (void);
-extern void keys_of_buffer (void);
/* Defined in marker.c. */
void
keys_of_window (void)
{
- initial_define_key (control_x_map, '<', "scroll-left");
- initial_define_key (control_x_map, '>', "scroll-right");
-
initial_define_key (meta_map, Ctl ('V'), "scroll-other-window");
initial_define_key (meta_map, 'v', "scroll-down-command");
}