Description
Did you check the docs?
- I have read all the docs.
Is your feature request related to a problem? Please describe.
Neotree currently provides the ability to show the source selector tabs in the status line or winbar, but it would be nice if it were possible to show them in the tabline. I use bufferline.nvim and I would prefer that the source selector tabs from Neotree were at the same level as my other buffer tabs (i.e. where the red box is in the screenshot, below).
This idea was previous proposed here in the discussion under #425, but it was never implemented.
Describe the solution you'd like.
I'm new to Lua so I'm not sure how this would best be implemented, or if it would even be possible to implement here versus in another plugin like bufferline. The three scenarios that I am able to envision are:
- This feature is implemented here.
- This feature is implemented in other plugins (e.g. bufferline).
- This feature is implemented as an extension that can be used from other plugins like bufferline.
For example, in bufferline's configuration, you can reserve space for a sidebar (e.g. file explorer) so that the buffer tabs do not display over the sidebar. Additionally, you can configure the text that will be displayed above this sidebar.
return {
'akinsho/bufferline.nvim',
version = '*',
dependencies = { 'nvim-tree/nvim-web-devicons' },
event = { 'VimEnter' },
init = function()
vim.opt.termguicolors = true
end,
opts = {
options = {
offsets = {
{
filetype = 'neo-tree',
text = '<The source selector tabs could go here>',
text_align = 'center',
highlight = 'Directory',
},
},
},
},
}
It seems that the above text
key can be a function, and any string that gets returned will be displayed in the tabline above the sidebar. This may provide an easy way to implement this feature, or it may already be possible using some of Neotree's internal functions.
Describe alternatives you've considered.
The alternative that I have considered is to just use the status line or winbar, but my preference, of course, would be to use the tabline. I understand that this feature may not be the preference of most, but I just thought I would create this issue to express my own interest in it, and to see if others would be interested as well.
Additional Context
No response