LSP icon indicating copy to clipboard operation
LSP copied to clipboard

Add ability to disable popup on hover

Open felixcatto opened this issue 4 years ago • 3 comments

Is your feature request related to a problem? Please describe.

When you work with code, the popup often appears, even if you don't want it. I.e. in 90% cases you think how to write your program, cursor stops at random area, then LSP popup appears with some info about this area. But you don't need it. And this redundant flickering happens very often. For me is more convenient, when i have no random hover popups at all. If i need to know LSP info about variable, i manually invoke "lsp_hover" command via keybinding.

Describe the solution you'd like

Currently i just overwrited source file, commented those lines https://github.com/sublimelsp/LSP/blob/main/plugin/documents.py#L430-L433 And added keybinding with "lsp_hover" command. But it would be cool if such thing available through settings. Something like

// Show hover popup. If disabled, it can be manually invoked via "lsp_hover" command in keybindings.
"show_popup_on_hover": true,

felixcatto avatar Sep 04 '21 06:09 felixcatto

Thanks for the suggestion. If the LSP hover popup is disabled, then the popup from the Default package will be shown instead. The net result is that you'll still see a popup?

rwols avatar Sep 04 '21 19:09 rwols

I don't see it because i disable it in sublime settings :) "show_definitions": false,

But it may be good to put this in comment line like this

// Show hover popup. If disabled, it can be manually invoked via "lsp_hover" command in keybindings.
// You might also need to disable native ST popup via settings "show_definitions": false,
"show_popup_on_hover": true,

felixcatto avatar Sep 05 '21 02:09 felixcatto

Then it might be more consistent to just follow the global show_popup_on_hover setting for LSP.

rchl avatar Sep 06 '21 09:09 rchl