nvim-tree / nvim-tree.lua

A file explorer tree for neovim written in lua

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Separate active buffer highlight from vim.opt.cursorline

JoseConseco opened this issue · comments

Can this functionality be implemented utilising API?
I do not think so

Is your feature request related to a problem? Please describe.
If I have disabled vim.opt.cursorline then NvimTree wont highlight active buffer.

Describe the solution you'd like
Custom highlight - not dependent on nvim, but it would only depends on NvimTree config

Describe alternatives you've considered
We can make hack with autocmd that enables cursorline for NvimTree, but is not 'fun'.

Proposal: new highlight group NvimTreeFileCurrent or Focused. Will require refreshing tree on events such as BufEnter or BufWinEnter. @alex-courtis can you see any downsides?

It does seem like very reasonable request, cursor line highlighting should be used more for cursor movement(navigation) rather than displaying state.

This is a great idea, adds consistency. Currently there is no way to do this except for update_focused_file

This can be done without a refresh, a draw should be good enough as per opened files.

Of course, meant redraw, not a refresh, just to update highlight group.