aboutsummaryrefslogtreecommitdiff
path: root/runtime/lua/vim/lsp
diff options
context:
space:
mode:
authorTristan Knight <admin@snappeh.com>2024-09-19 16:00:08 +0100
committerGitHub <noreply@github.com>2024-09-19 08:00:08 -0700
commitadbaaa522550a098e3b8e4efe0909cb3aa6e1d83 (patch)
tree31a10d9a95bafac56fed1185927b58ce272b2957 /runtime/lua/vim/lsp
parent84e85aeb10ae51b03392fdee12e14c9699c99e66 (diff)
downloadrneovim-adbaaa522550a098e3b8e4efe0909cb3aa6e1d83.tar.gz
rneovim-adbaaa522550a098e3b8e4efe0909cb3aa6e1d83.tar.bz2
rneovim-adbaaa522550a098e3b8e4efe0909cb3aa6e1d83.zip
docs(lsp): hover window controls #30347
Diffstat (limited to 'runtime/lua/vim/lsp')
-rw-r--r--runtime/lua/vim/lsp/buf.lua7
1 files changed, 6 insertions, 1 deletions
diff --git a/runtime/lua/vim/lsp/buf.lua b/runtime/lua/vim/lsp/buf.lua
index a43ad8a690..301c1f0cb6 100644
--- a/runtime/lua/vim/lsp/buf.lua
+++ b/runtime/lua/vim/lsp/buf.lua
@@ -29,7 +29,12 @@ local function request(method, params, handler)
end
--- Displays hover information about the symbol under the cursor in a floating
---- window. Calling the function twice will jump into the floating window.
+--- window. The window will be dismissed on cursor move.
+--- Calling the function twice will jump into the floating window
+--- (thus by default, "KK" will open the hover window and focus it).
+--- In the floating window, all commands and mappings are available as usual,
+--- except that "q" dismisses the window.
+--- You can scroll the contents the same as you would any other buffer.
function M.hover()
local params = util.make_position_params()
request(ms.textDocument_hover, params)