Replies: 2 comments
-
I think clearing tab name is a missing feature, I want to add it in the next version. |
Beta Was this translation helpful? Give feedback.
0 replies
-
Yes, it's possible:
Follow the example in Readme, you can set tabline as this: require('tabby.tabline').set(function(line)
return {
{
{ ' ', hl = theme.head },
line.sep('', theme.head, theme.fill),
},
line.tabs().foreach(function(tab)
local hl = tab.is_current() and theme.current_tab or theme.tab
return {
line.sep('', hl, theme.fill),
tab.is_current() and '' or '',
tab.name(),
tab.current_win().buf_name(),
tab.current_win().name()
tab.close_btn(''),
line.sep('', hl, theme.fill),
hl = hl,
margin = ' ',
}
end),
line.spacer(),
line.wins_in_tab(line.api.get_current_tab()).foreach(function(win)
return {
line.sep('', theme.win, theme.fill),
win.is_current() and '' or '',
win.buf_name(),
line.sep('', theme.win, theme.fill),
hl = theme.win,
margin = ' ',
}
end),
{
line.sep('', theme.tail, theme.fill),
{ ' ', hl = theme.tail },
},
hl = theme.fill,
}
end, {
tab_name = {
name_fallback = function()
return ''
end,
},
}) |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
There is
:TabRename
command which allows setting tab name.What if I want to revert back to the default behaviour for the tab, showing current file? Is there a way to do this? I tried calling
TabRename
without arguments, but it is not allowed.And what if I want to display both, tab name and current file name? Is that possible?
I am new to tabby, using preset tab_only
Beta Was this translation helpful? Give feedback.
All reactions