aboutsummaryrefslogtreecommitdiff
path: root/runtime/doc/api.txt
diff options
context:
space:
mode:
authorSergey Slipchenko <faergeek@gmail.com>2023-09-11 08:16:03 +0400
committerSergey Slipchenko <faergeek@gmail.com>2023-09-11 08:16:03 +0400
commitd22172f36bbe147f3aa6b76a1c43ae445f481c2e (patch)
tree882356fe01d9dde4447ecd2bfe43bcfc44e6c3d1 /runtime/doc/api.txt
parent2b475cb5cc2196a32085fbbdfd7357cbb02a1cb0 (diff)
downloadrneovim-d22172f36bbe147f3aa6b76a1c43ae445f481c2e.tar.gz
rneovim-d22172f36bbe147f3aa6b76a1c43ae445f481c2e.tar.bz2
rneovim-d22172f36bbe147f3aa6b76a1c43ae445f481c2e.zip
fix(api): more intuitive cursor updates in nvim_buf_set_text
Fixes #22526
Diffstat (limited to 'runtime/doc/api.txt')
-rw-r--r--runtime/doc/api.txt3
1 files changed, 3 insertions, 0 deletions
diff --git a/runtime/doc/api.txt b/runtime/doc/api.txt
index 7dd760b6a5..c0bea52513 100644
--- a/runtime/doc/api.txt
+++ b/runtime/doc/api.txt
@@ -2438,6 +2438,8 @@ nvim_buf_set_text({buffer}, {start_row}, {start_col}, {end_row}, {end_col},
Prefer |nvim_buf_set_lines()| if you are only adding or deleting entire
lines.
+ Prefer |nvim_put()| if you want to insert text at the cursor position.
+
Attributes: ~
not allowed when |textlock| is active
@@ -2451,6 +2453,7 @@ nvim_buf_set_text({buffer}, {start_row}, {start_col}, {end_row}, {end_col},
See also: ~
• |nvim_buf_set_lines()|
+ • |nvim_put()|
nvim_buf_set_var({buffer}, {name}, {value}) *nvim_buf_set_var()*
Sets a buffer-scoped (b:) variable