aboutsummaryrefslogtreecommitdiff
path: root/runtime/doc/builtin.txt
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/doc/builtin.txt')
-rw-r--r--runtime/doc/builtin.txt8
1 files changed, 3 insertions, 5 deletions
diff --git a/runtime/doc/builtin.txt b/runtime/doc/builtin.txt
index cf12ec7568..226ae80599 100644
--- a/runtime/doc/builtin.txt
+++ b/runtime/doc/builtin.txt
@@ -1198,11 +1198,9 @@ col({expr}) The result is a Number, which is the byte index of the column
buffer.
For the cursor position, when 'virtualedit' is active, the
column is one higher if the cursor is after the end of the
- line. This can be used to obtain the column in Insert mode: >
- :imap <F2> <C-O>:let save_ve = &ve<CR>
- \<C-O>:set ve=all<CR>
- \<C-O>:echo col(".") .. "\n" <Bar>
- \let &ve = save_ve<CR>
+ line. Also, when using a <Cmd> mapping the cursor isn't
+ moved, this can be used to obtain the column in Insert mode: >
+ :imap <F2> <Cmd>echo col(".")<CR>
< Can also be used as a |method|: >
GetPos()->col()