* doc/emacs/commands.texi (Keys): Add 'C-x t'.
* doc/emacs/frames.texi (Tab Bars): Replace 'C-x 6' with 'C-x t'.
* doc/lispref/keymaps.texi (Prefix Keys): Add 'C-x t' (tab-prefix-map).
* doc/lispref/maps.texi (Standard Keymaps): Add tab-prefix-map, tab-bar-map.
* lisp/dired.el: Rebind 'C-x 6 d' to 'C-x t d'. Use tab-prefix-map.
* lisp/subr.el (ctl-x-6-map, ctl-x-6-prefix, ctl-x-t-prefix): Remove.
(tab-prefix-map): New keymap bound to 'C-x t'.
* lisp/tab-bar.el: Use tab-prefix-map instead of ctl-x-6-map.
* lisp/textmodes/two-column.el: Restore autoload global setting of
"\C-x6" to 2C-command.
* lisp/ldefs-boot.el: Update to add setting "\C-x6" to 2C-command.
* doc/emacs/commands.texi (Keys):
* doc/emacs/text.texi (Two-Column):
* doc/lispref/keymaps.texi (Prefix Keys):
* doc/lispref/maps.texi (Standard Keymaps):
Restore 'C-x 6' bound to '2C-mode-map'.
By default, the prefix keys in Emacs are @kbd{C-c}, @kbd{C-h},
@kbd{C-x}, @kbd{C-x @key{RET}}, @kbd{C-x @@}, @kbd{C-x a}, @kbd{C-x
-n}, @kbd{C-x r}, @kbd{C-x v}, @kbd{C-x 4}, @kbd{C-x 5}, @kbd{C-x 6},
-@key{ESC}, @kbd{M-g}, @kbd{M-o} and @key{F2}. (@key{F1} is an alias
-for @kbd{C-h}.) This list is not cast in stone; if you customize
-Emacs, you can make new prefix keys. You could even eliminate some of
-the standard ones, though this is not recommended for most users; for
-example, if you remove the prefix definition of @kbd{C-x 4}, then
-@kbd{C-x 4 C-f} becomes an invalid key sequence. @xref{Key Bindings}.
+n}, @kbd{C-x r}, @kbd{C-x t}, @kbd{C-x v}, @kbd{C-x 4}, @kbd{C-x 5},
+@kbd{C-x 6}, @key{ESC}, @kbd{M-g}, and @kbd{M-o}. (@key{F1} and
+@key{F2} are aliases for @kbd{C-h} and @kbd{C-x 6}.) This list is not
+cast in stone; if you customize Emacs, you can make new prefix keys.
+You could even eliminate some of the standard ones, though this is not
+recommended for most users; for example, if you remove the prefix
+definition of @kbd{C-x 4}, then @kbd{C-x 4 C-f} becomes an invalid key
+sequence. @xref{Key Bindings}.
Typing the help character (@kbd{C-h} or @key{F1}) after a prefix key
displays a list of the commands starting with that prefix. The sole
by typing the related commands: @kbd{M-x tab-new}, @kbd{M-x tab-next},
@kbd{M-x tab-list}, @kbd{M-x tab-close}, etc.
-@kindex C-x 6
- The prefix key @kbd{C-x 6} is analogous to @kbd{C-x 5}.
+@kindex C-x t
+ The prefix key @kbd{C-x t} is analogous to @kbd{C-x 5}.
Whereas each @kbd{C-x 5} command pops up a buffer in a different frame
-(@pxref{Creating Frames}), the @kbd{C-x 6} commands use a different
+(@pxref{Creating Frames}), the @kbd{C-x t} commands use a different
tab with a different window configuration in the selected frame.
- The various @kbd{C-x 6} commands differ in how they find or create the
+ The various @kbd{C-x t} commands differ in how they find or create the
buffer to select:
@table @kbd
-@item C-x 6 2
-@kindex C-x 6 2
+@item C-x t 2
+@kindex C-x t 2
@findex tab-new
Add a new tab (@code{tab-new}). You can control the choice of the
buffer displayed in a new tab by customizing the variable
@code{tab-bar-new-tab-choice}.
-@item C-x 6 b @var{bufname} @key{RET}
+@item C-x t b @var{bufname} @key{RET}
Select buffer @var{bufname} in another tab. This runs
@code{switch-to-buffer-other-tab}.
-@item C-x 6 f @var{filename} @key{RET}
+@item C-x t f @var{filename} @key{RET}
Visit file @var{filename} and select its buffer in another tab. This
runs @code{find-file-other-tab}. @xref{Visiting}.
-@item C-x 6 d @var{directory} @key{RET}
+@item C-x t d @var{directory} @key{RET}
Select a Dired buffer for directory @var{directory} in another tab.
This runs @code{dired-other-tab}. @xref{Dired}.
-@item C-x 6 r @var{tabname} @key{RET}
+@item C-x t r @var{tabname} @key{RET}
Renames the current tab to @var{tabname}. You can control the
programmatic name given to a tab by default by customizing the
variable @code{tab-bar-tab-name-function}.
The following commands are used to delete and operate on tabs:
@table @kbd
-@item C-x 6 0
-@kindex C-x 6 0
+@item C-x t 0
+@kindex C-x t 0
@findex tab-close
Close the selected tab (@code{tab-close}). It has no effect if there
is only one tab.
-@item C-x 6 o
-@kindex C-x 6 o
+@item C-x t o
+@kindex C-x t o
@kindex C-TAB
@findex tab-next
Switch to another tab. If you repeat this command, it cycles through
N, it switches to the next Nth tab; with a negative argument −N, it
switches back to the previous Nth tab.
-@item C-x 6 1
-@kindex C-x 6 1
+@item C-x t 1
+@kindex C-x t 1
@findex tab-close-other
Close all tabs on the selected frame, except the selected one.
@end table
buffer. There are three ways to enter two-column mode:
@table @asis
-@item @kbd{@key{F2} 2}
+@item @kbd{@key{F2} 2} or @kbd{C-x 6 2}
@kindex F2 2
+@kindex C-x 6 2
@findex 2C-two-columns
Enter two-column mode with the current buffer on the left, and on the
right, a buffer whose name is based on the current buffer's name
This command is appropriate when the current buffer is empty or contains
just one column and you want to add another column.
-@item @kbd{@key{F2} s}
+@item @kbd{@key{F2} s} or @kbd{C-x 6 s}
@kindex F2 s
+@kindex C-x 6 s
@findex 2C-split
Split the current buffer, which contains two-column text, into two
buffers, and display them side by side (@code{2C-split}). The current
two-column text, and you wish to separate the columns temporarily.
@item @kbd{@key{F2} b @var{buffer} @key{RET}}
+@itemx @kbd{C-x 6 b @var{buffer} @key{RET}}
@kindex F2 b
+@kindex C-x 6 b
@findex 2C-associate-buffer
Enter two-column mode using the current buffer as the left-hand buffer,
and using buffer @var{buffer} as the right-hand buffer
(@code{2C-associate-buffer}).
@end table
- @kbd{@key{F2} s} looks for a column separator, which is a string
-that appears on each line between the two columns. You can specify
-the width of the separator with a numeric argument to @kbd{@key{F2}
-s}; that many characters, before point, constitute the separator
-string. By default, the width is 1, so the column separator is the
-character before point.
+ @kbd{@key{F2} s} or @kbd{C-x 6 s} looks for a column separator, which
+is a string that appears on each line between the two columns. You can
+specify the width of the separator with a numeric argument to
+@kbd{@key{F2} s}; that many characters, before point, constitute the
+separator string. By default, the width is 1, so the column separator
+is the character before point.
When a line has the separator at the proper place, @kbd{@key{F2} s}
puts the text after the separator into the right-hand buffer, and
right-hand buffer.)
@kindex F2 RET
+@kindex C-x 6 RET
@findex 2C-newline
- The command @kbd{@key{F2} @key{RET}} (@code{2C-newline}) inserts
-a newline in each of the two buffers at corresponding positions.
-This is the easiest way to add a new line to the two-column text while
-editing it in split buffers.
+ The command @kbd{@key{F2} @key{RET}} or @kbd{C-x 6 @key{RET}}
+(@code{2C-newline}) inserts a newline in each of the two buffers at
+corresponding positions. This is the easiest way to add a new line to
+the two-column text while editing it in split buffers.
@kindex F2 1
+@kindex C-x 6 1
@findex 2C-merge
When you have edited both buffers as you wish, merge them with
-@kbd{@key{F2} 1} (@code{2C-merge}). This copies the
+@kbd{@key{F2} 1} or @kbd{C-x 6 1} (@code{2C-merge}). This copies the
text from the right-hand buffer as a second column in the other buffer.
To go back to two-column editing, use @kbd{@key{F2} s}.
@kindex F2 d
+@kindex C-x 6 d
@findex 2C-dissociate
- Use @kbd{@key{F2} d} to dissociate the two buffers, leaving each as
-it stands (@code{2C-dissociate}). If the other buffer, the one not
-current when you type @kbd{@key{F2} d}, is empty, @kbd{@key{F2} d}
-kills it.
+ Use @kbd{@key{F2} d} or @kbd{C-x 6 d} to dissociate the two buffers,
+leaving each as it stands (@code{2C-dissociate}). If the other buffer,
+the one not current when you type @kbd{@key{F2} d}, is empty,
+@kbd{@key{F2} d} kills it.
@item
@cindex @kbd{C-x 6}
-@vindex ctl-x-6-map
-@code{ctl-x-6-map} is the global keymap used for the @kbd{C-x 6} prefix
+@vindex 2C-mode-map
+@code{2C-mode-map} is the global keymap used for the @kbd{C-x 6} prefix
+key.
+
+@item
+@cindex @kbd{C-x t}
+@vindex tab-prefix-map
+@code{tab-prefix-map} is the global keymap used for the @kbd{C-x t} prefix
key.
@item
@c Don't add xrefs to things covered in {Keymaps}.
@table @code
@item 2C-mode-map
-A sparse keymap for subcommands of the prefix @key{F2}.@*
+A sparse keymap for subcommands of the prefix @kbd{C-x 6}.@*
@xref{Two-Column,, Two-Column Editing, emacs, The GNU Emacs Manual}.
@item abbrev-map
@item ctl-x-5-map
A sparse keymap for subcommands of the prefix @kbd{C-x 5}.
-@item ctl-x-6-map
-A sparse keymap for subcommands of the prefix @kbd{C-x 6}.
-
@item ctl-x-map
A full keymap for @kbd{C-x} commands.
The keymap used by Special mode.@*
@xref{Basic Major Modes}.
+@item tab-prefix-map
+The global keymap used for the @kbd{C-x t} prefix key for tab-bar related commands.@*
+@xref{Tab Bars,,, emacs, The GNU Emacs Manual}.
+
+@item tab-bar-map
+The keymap defining the contents of the tab bar.@*
+@xref{Tab Bars,,, emacs, The GNU Emacs Manual}.
+
@item tool-bar-map
The keymap defining the contents of the tool bar.@*
@xref{Tool Bar}.
frame, where you can use tabs to switch between named persistent
window configurations.
-The 'C-x 6' sequence is the new prefix key for tab-related commands:
-'C-x 6 2' creates a new tab; 'C-x 6 0' deletes the current tab;
-'C-x 6 b' switches to buffer in another tab; 'C-x 6 f' and 'C-x 6 C-f'
+The 'C-x t' sequence is the new prefix key for tab-related commands:
+'C-x t 2' creates a new tab; 'C-x t 0' deletes the current tab;
+'C-x t b' switches to buffer in another tab; 'C-x t f' and 'C-x t C-f'
edit file in another tab; and 'C-TAB' and 'S-C-TAB' switch to the next
or previous tab. You can also switch between tabs and create/delete
tabs with a mouse.
\f
* Incompatible Lisp Changes in Emacs 27.1
----
-** Two-column mode provides its 'C-x 6' prefix map only after loading
-two-column.el. Its prefix key 'F2' is still available globally
-along with 'C-x 6' used by the tab commands globally.
-
---
** Incomplete destructive splicing support has been removed.
Support for Common Lisp style destructive splicing (",.") was
(interactive (dired-read-dir-and-switches "in other frame "))
(switch-to-buffer-other-frame (dired-noselect dirname switches)))
-;;;###autoload (define-key ctl-x-6-map "d" 'dired-other-tab)
+;;;###autoload (define-key tab-prefix-map "d" 'dired-other-tab)
;;;###autoload
(defun dired-other-tab (dirname &optional switches)
"\"Edit\" directory DIRNAME. Like `dired' but makes a new tab."
;;;;;; 0 0))
;;; Generated autoloads from textmodes/two-column.el
(autoload '2C-command "two-column" () t 'keymap)
+ (global-set-key "\C-x6" '2C-command)
(global-set-key [f2] '2C-command)
(autoload '2C-two-columns "two-column" "\
(defalias 'ctl-x-5-prefix ctl-x-5-map)
(define-key ctl-x-map "5" 'ctl-x-5-prefix)
-(defvar ctl-x-6-map (make-sparse-keymap)
- "Keymap for tab commands.")
-(defalias 'ctl-x-6-prefix ctl-x-6-map)
-(define-key ctl-x-map "6" 'ctl-x-6-prefix)
-(defalias 'ctl-x-t-prefix ctl-x-6-map)
-(define-key ctl-x-map "t" 'ctl-x-t-prefix)
+(defvar tab-prefix-map (make-sparse-keymap)
+ "Keymap for tab-bar related commands.")
+(define-key ctl-x-map "t" tab-prefix-map)
\f
;;;; Event manipulation functions.
value)
(switch-to-buffer-other-tab value))))
-(define-key ctl-x-6-map "2" 'tab-new)
-(define-key ctl-x-6-map "1" 'tab-close-other)
-(define-key ctl-x-6-map "0" 'tab-close)
-(define-key ctl-x-6-map "o" 'tab-next)
-(define-key ctl-x-6-map "b" 'switch-to-buffer-other-tab)
-(define-key ctl-x-6-map "f" 'find-file-other-tab)
-(define-key ctl-x-6-map "\C-f" 'find-file-other-tab)
-(define-key ctl-x-6-map "r" 'tab-rename)
+(define-key tab-prefix-map "2" 'tab-new)
+(define-key tab-prefix-map "1" 'tab-close-other)
+(define-key tab-prefix-map "0" 'tab-close)
+(define-key tab-prefix-map "o" 'tab-next)
+(define-key tab-prefix-map "b" 'switch-to-buffer-other-tab)
+(define-key tab-prefix-map "f" 'find-file-other-tab)
+(define-key tab-prefix-map "\C-f" 'find-file-other-tab)
+(define-key tab-prefix-map "r" 'tab-rename)
\f
(provide 'tab-bar)
;; This one is for historical reasons and simple keyboards, it is not
;; at all mnemonic. All usual sequences containing 2 were used, and
;; f2 could not be set up in a standard way under Emacs 18.
-;; This prefix is bound only after loading this package
-;; to not conflict with the C-x 6 prefix used by tab commands.
-(global-set-key "\C-x6" '2C-command)
+;;;###autoload (global-set-key "\C-x6" '2C-command)
;;;###autoload (global-set-key [f2] '2C-command)