Make always-visible '+' new tab button opt-in via tab_bar_show_new_tab_button

Default is 'no' to avoid forcing the button on all kitty users. When disabled,
the '+' indicator still appears during window drags as a drop target (existing
behaviour). Set to 'yes' to keep it permanently visible as a clickable button.
This commit is contained in:
mcrmck
2026-03-22 17:13:08 -04:00
parent 412cd30cd2
commit 3e85db684d
2 changed files with 13 additions and 1 deletions

View File

@@ -1635,6 +1635,16 @@ The horizontal alignment of the tab bar, can be one of: :code:`left`,
'''
)
opt('tab_bar_show_new_tab_button', 'no', option_type='to_bool', ctype='bool',
long_text='''
When set to :code:`yes`, a :code:`+` button is always shown at the end of the
tab bar as a clickable shortcut to open a new tab. When set to :code:`no`
(the default), the button is hidden at rest but still appears temporarily
while a window is being dragged, so it can be used as a drop target to open
the window in a new tab.
'''
)
opt('tab_bar_min_tabs', '2', option_type='tab_bar_min_tabs',
long_text='The minimum number of tabs that must exist before the tab bar is shown.'
)