From d807c2c2b005badbef80c45cc79d0f5ed5730ba9 Mon Sep 17 00:00:00 2001 From: mitchell <70453897+orbitalquark@users.noreply.github.com> Date: Tue, 9 Feb 2021 12:58:21 -0500 Subject: Added `ui.SHOW_ALL_TABS` option for `ui.tabs`. Textadept hides the first tab by default since its information is duplicated in the titlebar and screen space is wasted. However, some users choose to hide titlebars (e.g. on window maximize/fullscreen), so this option now exists. --- core/ui.lua | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'core') diff --git a/core/ui.lua b/core/ui.lua index 497cadc4..19bf5881 100644 --- a/core/ui.lua +++ b/core/ui.lua @@ -26,6 +26,8 @@ local ui = ui -- @field tabs (bool) -- Whether or not to display the tab bar when multiple buffers are open. -- The default value is `true`. +-- A third option, `ui.SHOW_ALL_TABS` may be used to always show the tab bar, +-- even if only one buffer is open. -- @field silent_print (bool) -- Whether or not to print messages to buffers silently. -- This is not guaranteed to be a constant value, as Textadept may change it @@ -33,8 +35,12 @@ local ui = ui -- with a group of [`ui.print()`]() and [`ui._print()`]() function calls. -- The default value is `false`, and focuses buffers when messages are printed -- to them. +-- @field SHOW_ALL_TABS (number) +-- module('ui')]] +ui.SHOW_ALL_TABS = 2 -- ui.tabs options must be greater than 1 + ui.silent_print = false -- Helper function for jumping to another view to print to, or creating a new -- cgit v1.2.3