Variable: tab-bar-select-restore-windows
tab-bar-select-restore-windows is a customizable variable defined in
tab-bar.el.gz.
Value
tab-bar-select-restore-windows
Documentation
Function called when selecting a tab to handle windows whose buffer was killed.
When a tab-bar tab displays a window whose buffer was killed since this tab was last selected, this variable determines what to do with that window.
If this variable is nil, there is no special handling;
set-window-configuration will decide what to do with the window,
then either a random buffer is displayed instead of the killed buffer,
or the window gets deleted.
If this variable is a function, display another buffer in that window,
and pass that buffer to the function. See the variable
window-restore-killed-buffer-windows for the calling convention.
By default, tab-bar-select-restore-windows(var)/tab-bar-select-restore-windows(fun) displays a placeholder buffer
in the same window to give information about the killed buffer.
This variable was added, or its default value changed, in Emacs 30.1.
Probably introduced at or before Emacs version 30.1.
Source Code
;; Defined in /usr/src/emacs/lisp/tab-bar.el.gz
(defcustom tab-bar-select-restore-windows #'tab-bar-select-restore-windows
"Function called when selecting a tab to handle windows whose buffer was killed.
When a tab-bar tab displays a window whose buffer was killed since
this tab was last selected, this variable determines what to do with
that window.
If this variable is nil, there is no special handling;
`set-window-configuration' will decide what to do with the window,
then either a random buffer is displayed instead of the killed buffer,
or the window gets deleted.
If this variable is a function, display another buffer in that window,
and pass that buffer to the function. See the variable
`window-restore-killed-buffer-windows' for the calling convention.
By default, `tab-bar-select-restore-windows' displays a placeholder buffer
in the same window to give information about the killed buffer."
:type '(choice (const :tag "No special handling" nil)
(const :tag "Show placeholder buffers"
tab-bar-select-restore-windows)
(function :tag "Function"))
:group 'tab-bar
:version "30.1")