dstein64 / nvim-scrollview

A Neovim plugin that displays interactive vertical scrollbars and signs.
MIT License
517 stars 9 forks source link

To show scrollbar in float windows #91

Closed vollowx closed 11 months ago

vollowx commented 1 year ago

image

Scrollbars don't show in float windows such as Lazy, Mason or LspInfo.

I didn't find any option to control it. Is this configurable? If not, could you please add it as a feature?

dstein64 commented 1 year ago

"I didn't find any option to control it. Is this configurable?"

Hi @huge-pancake, it's not currently possible for scrollbars and/or signs to appear in floating windows. There's no configuration option for that functionality.

"If not, could you please add it as a feature?"

I'll consider adding this to a future version of the plugin. If it were a simple update, I'd add it quickly, but I believe there are various assumptions throughout the code that scrollbars don't appear in floating windows.

vollowx commented 1 year ago

I see, hope things work out soon :smile_cat:

dstein64 commented 11 months ago

I've added an experimental option, scrollview_floating_windows, that can be set to v:true to enable scrollview for floating windows.

For floating windows that use nvim_win_set_hl_ns, the background color of scrollview signs will be incorrect (#105).

VimScript

:let g:scrollview_floating_windows = v:true

Lua

-- with vim.g
vim.g.scrollview_floating_windows = true,

-- with a setup() function
require('scrollview').setup({
  ...
  floating_windows = true,
  ...
})