aboutsummaryrefslogtreecommitdiff
path: root/runtime/doc
diff options
context:
space:
mode:
authorChristian Clason <c.clason@uni-graz.at>2022-12-10 13:17:07 +0100
committerFolke Lemaitre <folke.lemaitre@gmail.com>2022-12-13 18:59:27 +0100
commit04da0432446fac57e391c31bd4de0a9c06b1626d (patch)
tree62e1bd5623d81e86d4fdf92e9613ed3e68a5a3f9 /runtime/doc
parenta442c9f5564ff9690803faa92012e35541588294 (diff)
downloadrneovim-04da0432446fac57e391c31bd4de0a9c06b1626d.tar.gz
rneovim-04da0432446fac57e391c31bd4de0a9c06b1626d.tar.bz2
rneovim-04da0432446fac57e391c31bd4de0a9c06b1626d.zip
feat(lsp): add function to get semantic tokens at cursor
Diffstat (limited to 'runtime/doc')
-rw-r--r--runtime/doc/lsp.txt13
1 files changed, 13 insertions, 0 deletions
diff --git a/runtime/doc/lsp.txt b/runtime/doc/lsp.txt
index 75d5c067b1..32cfbd37eb 100644
--- a/runtime/doc/lsp.txt
+++ b/runtime/doc/lsp.txt
@@ -1332,6 +1332,19 @@ force_refresh({bufnr}) *vim.lsp.semantic_tokens.force_refresh()*
Parameters: ~
• {bufnr} (nil|number) default: current buffer
+ *vim.lsp.semantic_tokens.get_at_pos()*
+get_at_pos({bufnr}, {row}, {col})
+ Return the semantic token(s) at the given position. If called without
+ argument, returns the token under the cursor.
+
+ Parameters: ~
+ • {bufnr} (number|nil) Buffer number (0 for current buffer, default)
+ • {row} (number|nil) Position row (default cursor position)
+ • {col} (number|nil) Position column (default cursor position)
+
+ Return: ~
+ table[]|nil tokens Table of tokens at position
+
start({bufnr}, {client_id}, {opts}) *vim.lsp.semantic_tokens.start()*
Start the semantic token highlighting engine for the given buffer with the
given client. The client must already be attached to the buffer.