diff options
Diffstat (limited to 'core')
-rw-r--r-- | core/.buffer.luadoc | 2 | ||||
-rw-r--r-- | core/ui.lua | 4 |
2 files changed, 6 insertions, 0 deletions
diff --git a/core/.buffer.luadoc b/core/.buffer.luadoc index b1265c2e..087fd8a3 100644 --- a/core/.buffer.luadoc +++ b/core/.buffer.luadoc @@ -773,6 +773,8 @@ -- @field tab_indents (bool) -- Tabbing indents within indentation. -- The default value is `false`. +-- @field tab_label (string) +-- The buffer's tab label in the tab bar. -- @field tab_width (number) -- The number of space characters represented by a tab character. -- The default value is `8`. diff --git a/core/ui.lua b/core/ui.lua index 9a1bd5a4..03a0adcf 100644 --- a/core/ui.lua +++ b/core/ui.lua @@ -19,6 +19,9 @@ local ui = ui -- The text displayed in the buffer statusbar. -- @field maximized (bool) -- Whether or not Textadept's window is maximized. +-- @field tabs (bool) +-- Whether or not to display the tab bar when multiple buffers are open. +-- The default value is `true`. module('ui')]] local theme = package.searchpath(not CURSES and 'light' or 'term', @@ -262,6 +265,7 @@ local function set_title() local basename = buffer.filename and filename:match('[^/\\]+$') or filename ui.title = string.format('%s %s Textadept (%s)', basename, buffer.modify and '*' or '-', filename) + buffer.tab_label = basename..(buffer.modify and '*' or '') end -- Changes Textadept title to show the buffer as being "clean" or "dirty". |