Skip to content
This repository has been archived by the owner on Oct 13, 2021. It is now read-only.

hover if _any_ of the connected server support it #279

Merged
merged 2 commits into from
Nov 20, 2020
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion lua/completion/hover.lua
Original file line number Diff line number Diff line change
Expand Up @@ -351,9 +351,11 @@ M.autoOpenHoverInPopup = function()
M.winnr = winnr
end
else
local has_hover = false
for _, value in pairs(vim.lsp.buf_get_clients(0)) do
if value.resolved_capabilities.hover == false then return end
has_hover = value.resolved_capabilities.hover or has_hover
lukas-reineke marked this conversation as resolved.
Show resolved Hide resolved
end
if not has_hover then return end
local row, col = unpack(api.nvim_win_get_cursor(0))
row = row - 1
local line = api.nvim_buf_get_lines(0, row, row+1, true)[1]
Expand Down