It can be used to enable/disable the tab bar individually on each frame
independently from the value of 'tab-bar-mode' and 'tab-bar-show'.
----
-*** New command 'tab-duplicate'.
-
---
*** 'Mod-9' bound to 'tab-last' now switches to the last tab.
It also supports a negative argument.
+---
+*** New command 'tab-duplicate' bound to 'C-x t n'.
+
---
*** 'C-x t N' creates a new tab at the specified absolute position.
It also supports a negative argument.
(defvar tab-bar-separator nil
"String that delimits tabs.")
+(defun tab-bar-separator ()
+ (or tab-bar-separator (if window-system " " "|")))
+
\f
(defcustom tab-bar-tab-name-function #'tab-bar-tab-name-current
"Function to get a tab name.
(defun tab-bar-make-keymap-1 ()
"Generate an actual keymap from `tab-bar-map', without caching."
- (let* ((separator (or tab-bar-separator (if window-system " " "|")))
- (i 0)
- (tabs (funcall tab-bar-tabs-function)))
+ (let ((separator (tab-bar-separator))
+ (tabs (funcall tab-bar-tabs-function))
+ (i 0))
(append
'(keymap (mouse-1 . tab-bar-handle-mouse))
(when (and tab-bar-history-mode tab-bar-history-buttons-show)
nil "[other-tab]")
(message "Display next command buffer in a new tab..."))
+(define-key tab-prefix-map "n" 'tab-duplicate)
(define-key tab-prefix-map "N" 'tab-new-to)
(define-key tab-prefix-map "2" 'tab-new)
(define-key tab-prefix-map "1" 'tab-close-other)