aboutsummaryrefslogtreecommitdiff
path: root/runtime/doc
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/doc')
-rw-r--r--runtime/doc/Makefile2
-rw-r--r--runtime/doc/api.txt125
-rw-r--r--runtime/doc/arabic.txt2
-rw-r--r--runtime/doc/autocmd.txt63
-rw-r--r--runtime/doc/change.txt72
-rw-r--r--runtime/doc/channel.txt18
-rw-r--r--runtime/doc/cmdline.txt69
-rw-r--r--runtime/doc/debug.txt10
-rw-r--r--runtime/doc/deprecated.txt5
-rw-r--r--runtime/doc/develop.txt65
-rw-r--r--runtime/doc/diff.txt8
-rw-r--r--runtime/doc/digraph.txt2
-rw-r--r--runtime/doc/editing.txt21
-rw-r--r--runtime/doc/eval.txt301
-rw-r--r--runtime/doc/farsi.txt2
-rw-r--r--runtime/doc/filetype.txt62
-rw-r--r--runtime/doc/fold.txt2
-rw-r--r--runtime/doc/ft_ada.txt2
-rw-r--r--runtime/doc/ft_rust.txt6
-rw-r--r--runtime/doc/ft_sql.txt2
-rw-r--r--runtime/doc/gui.txt240
-rw-r--r--runtime/doc/hebrew.txt2
-rw-r--r--runtime/doc/help.txt5
-rw-r--r--runtime/doc/helphelp.txt2
-rw-r--r--runtime/doc/if_cscop.txt2
-rw-r--r--runtime/doc/if_lua.txt5
-rw-r--r--runtime/doc/if_pyth.txt43
-rw-r--r--runtime/doc/if_ruby.txt4
-rw-r--r--runtime/doc/indent.txt42
-rw-r--r--runtime/doc/index.txt5
-rw-r--r--runtime/doc/insert.txt68
-rw-r--r--runtime/doc/intro.txt167
-rw-r--r--runtime/doc/job_control.txt10
-rw-r--r--runtime/doc/makehtml.awk4
-rw-r--r--runtime/doc/map.txt19
-rw-r--r--runtime/doc/mbyte.txt2
-rw-r--r--runtime/doc/message.txt5
-rw-r--r--runtime/doc/mlang.txt2
-rw-r--r--runtime/doc/motion.txt29
-rw-r--r--runtime/doc/msgpack_rpc.txt13
-rw-r--r--runtime/doc/nvim.txt27
-rw-r--r--runtime/doc/options.txt462
-rw-r--r--runtime/doc/pattern.txt15
-rw-r--r--runtime/doc/pi_gzip.txt2
-rw-r--r--runtime/doc/pi_msgpack.txt4
-rw-r--r--runtime/doc/pi_netrw.txt4
-rw-r--r--runtime/doc/pi_paren.txt2
-rw-r--r--runtime/doc/pi_spec.txt2
-rw-r--r--runtime/doc/pi_tar.txt2
-rw-r--r--runtime/doc/pi_zip.txt2
-rw-r--r--runtime/doc/print.txt4
-rw-r--r--runtime/doc/provider.txt83
-rw-r--r--runtime/doc/quickfix.txt217
-rw-r--r--runtime/doc/quickref.txt8
-rw-r--r--runtime/doc/recover.txt5
-rw-r--r--runtime/doc/remote.txt6
-rw-r--r--runtime/doc/repeat.txt6
-rw-r--r--runtime/doc/rileft.txt2
-rw-r--r--runtime/doc/russian.txt2
-rw-r--r--runtime/doc/scroll.txt4
-rw-r--r--runtime/doc/sign.txt7
-rw-r--r--runtime/doc/spell.txt2
-rw-r--r--runtime/doc/sponsor.txt216
-rw-r--r--runtime/doc/starting.txt78
-rw-r--r--runtime/doc/syntax.txt95
-rw-r--r--runtime/doc/tabpage.txt11
-rw-r--r--runtime/doc/tagsrch.txt44
-rw-r--r--runtime/doc/term.txt94
-rw-r--r--runtime/doc/tips.txt2
-rw-r--r--runtime/doc/uganda.txt2
-rw-r--r--runtime/doc/ui.txt299
-rw-r--r--runtime/doc/undo.txt2
-rw-r--r--runtime/doc/usr_01.txt8
-rw-r--r--runtime/doc/usr_02.txt2
-rw-r--r--runtime/doc/usr_03.txt2
-rw-r--r--runtime/doc/usr_04.txt2
-rw-r--r--runtime/doc/usr_05.txt9
-rw-r--r--runtime/doc/usr_06.txt2
-rw-r--r--runtime/doc/usr_07.txt2
-rw-r--r--runtime/doc/usr_08.txt2
-rw-r--r--runtime/doc/usr_09.txt9
-rw-r--r--runtime/doc/usr_10.txt2
-rw-r--r--runtime/doc/usr_11.txt6
-rw-r--r--runtime/doc/usr_12.txt2
-rw-r--r--runtime/doc/usr_20.txt2
-rw-r--r--runtime/doc/usr_21.txt2
-rw-r--r--runtime/doc/usr_22.txt2
-rw-r--r--runtime/doc/usr_23.txt2
-rw-r--r--runtime/doc/usr_24.txt18
-rw-r--r--runtime/doc/usr_25.txt2
-rw-r--r--runtime/doc/usr_26.txt2
-rw-r--r--runtime/doc/usr_27.txt8
-rw-r--r--runtime/doc/usr_28.txt2
-rw-r--r--runtime/doc/usr_29.txt2
-rw-r--r--runtime/doc/usr_30.txt2
-rw-r--r--runtime/doc/usr_31.txt2
-rw-r--r--runtime/doc/usr_32.txt2
-rw-r--r--runtime/doc/usr_40.txt2
-rw-r--r--runtime/doc/usr_41.txt15
-rw-r--r--runtime/doc/usr_42.txt2
-rw-r--r--runtime/doc/usr_43.txt2
-rw-r--r--runtime/doc/usr_44.txt2
-rw-r--r--runtime/doc/usr_45.txt5
-rw-r--r--runtime/doc/usr_toc.txt2
-rw-r--r--runtime/doc/various.txt27
-rw-r--r--runtime/doc/vi_diff.txt4
-rw-r--r--runtime/doc/vim_diff.txt47
-rw-r--r--runtime/doc/visual.txt12
-rw-r--r--runtime/doc/windows.txt30
109 files changed, 1875 insertions, 1590 deletions
diff --git a/runtime/doc/Makefile b/runtime/doc/Makefile
index dabbcd08d9..18d32c0820 100644
--- a/runtime/doc/Makefile
+++ b/runtime/doc/Makefile
@@ -13,7 +13,7 @@ HTMLS = $(DOCS:.txt=.html)
.SUFFIXES: .c .o .txt .html
# Awk version of .txt to .html conversion.
-html: noerrors $(HTMLS)
+html: noerrors vimindex.html $(HTMLS)
@if test -f errors.log; then cat errors.log; fi
noerrors:
diff --git a/runtime/doc/api.txt b/runtime/doc/api.txt
index 21f818cb8d..e16b6b7e75 100644
--- a/runtime/doc/api.txt
+++ b/runtime/doc/api.txt
@@ -85,7 +85,7 @@ Buffer update events *api-buffer-updates*
API clients can "attach" to Nvim buffers to subscribe to buffer update events.
This is similar to |TextChanged| but more powerful and granular.
-Call |nvim_buf_attach| to receive these events on the channel:
+Call |nvim_buf_attach()| to receive these events on the channel:
*nvim_buf_lines_event*
nvim_buf_lines_event[{buf}, {changedtick}, {firstline}, {lastline}, {linedata}, {more}]
@@ -97,7 +97,7 @@ nvim_buf_lines_event[{buf}, {changedtick}, {firstline}, {lastline}, {linedata},
When {changedtick} is |v:null| this means the screen lines (display) changed
but not the buffer contents. {linedata} contains the changed screen lines.
- This happens when |inccommand| shows a buffer preview.
+ This happens when 'inccommand' shows a buffer preview.
Properties:~
{buf} API buffer handle (buffer number)
@@ -138,7 +138,7 @@ nvim_buf_changedtick_event[{buf}, {changedtick}] *nvim_buf_changedtick_event*
nvim_buf_detach_event[{buf}] *nvim_buf_detach_event*
When buffer is detached (i.e. updates are disabled). Triggered explicitly by
- |nvim_buf_detach| or implicitly in these cases:
+ |nvim_buf_detach()| or implicitly in these cases:
- Buffer was |abandon|ed and 'hidden' is not set.
- Buffer was reloaded, e.g. with |:edit| or an external change triggered
|:checktime| or 'autoread'.
@@ -150,7 +150,7 @@ nvim_buf_detach_event[{buf}] *nvim_buf_detach_event*
EXAMPLE ~
-Calling |nvim_buf_attach| with send_buffer=true on an empty buffer, emits: >
+Calling |nvim_buf_attach()| with send_buffer=true on an empty buffer, emits: >
nvim_buf_lines_event[{buf}, {changedtick}, 0, 0, [""], v:false]
User adds two lines to the buffer, emits: >
@@ -189,12 +189,11 @@ Another use case are plugins that show output in an append-only buffer, and
want to add highlights to the outputs. Highlight data cannot be preserved
on writing and loading a buffer to file, nor in undo/redo cycles.
-Highlights are registered using the |nvim_buf_add_highlight| function, see the
-generated API documentation for details. If an external highlighter plugin is
-adding a large number of highlights in a batch, performance can be improved by
-calling |nvim_buf_add_highlight| as an asynchronous notification, after first
-(synchronously) reqesting a source id. Here is an example using wrapper
-functions in the python client:
+Highlights are registered using the |nvim_buf_add_highlight()| function. If an
+external highlighter plugin wants to add many highlights in a batch,
+performance can be improved by calling |nvim_buf_add_highlight()| as an
+asynchronous notification, after first (synchronously) reqesting a source id.
+Example using the Nvim python-client:
>
src = vim.new_highlight_source()
@@ -207,10 +206,10 @@ functions in the python client:
buf.clear_highlight(src)
<
If the highlights don't need to be deleted or updated, just pass -1 as
-src_id (this is the default in python). |nvim_buf_clear_highlight| can be used
-to clear highlights from a specific source, in a specific line range or the
-entire buffer by passing in the line range 0, -1 (the latter is the default
-in python as used above).
+src_id (this is the default in python). Use |nvim_buf_clear_highlight()| to
+clear highlights from a specific source, in a specific line range or the
+entire buffer by passing in the line range 0, -1 (the latter is the default in
+python as used above).
An example of calling the api from vimscript: >
@@ -639,7 +638,7 @@ nvim_set_client_info({name}, {version}, {type}, {methods},
Clients might define their own keys, but the
following are suggested: "website" Website
of client (for instance github repository)
- "license" Informal descripton of the
+ "license" Informal description of the
license, such as "Apache 2", "GPLv3" or
"MIT" "logo" URI or path to image,
preferably small logo or icon. .png or .svg
@@ -655,14 +654,14 @@ nvim_get_chan_info({chan}) *nvim_get_chan_info()*
stderr of this Nvim instance "socket" TCP/IP socket or
named pipe "job" job with communication over its stdio
- "mode" how data received on the channel is interpreted "bytes" send and recieve raw bytes "terminal" a |terminal| instance interprets ASCII sequences "rpc" |RPC| communication on the channel is active "pty" Name of pseudoterminal, if one is used (optional). On a POSIX system, this will be a device path like /dev/pts/1. Even if the name is unknown, the key will still be present to indicate a pty is used. This is currently the case when using winpty on windows. "buffer" buffer with connected |terminal| instance (optional) "client" information about the client on the other end of the RPC channel, if it has added it using |nvim_set_client_info|. (optional)
+ "mode" how data received on the channel is interpreted "bytes" send and recieve raw bytes "terminal" a |terminal| instance interprets ASCII sequences "rpc" |RPC| communication on the channel is active "pty" Name of pseudoterminal, if one is used (optional). On a POSIX system, this will be a device path like /dev/pts/1. Even if the name is unknown, the key will still be present to indicate a pty is used. This is currently the case when using winpty on windows. "buffer" buffer with connected |terminal| instance (optional) "client" information about the client on the other end of the RPC channel, if it has added it using |nvim_set_client_info()|. (optional)
nvim_list_chans() *nvim_list_chans()*
Get information about all open channels.
Return: ~
Array of Dictionaries, each describing a channel with the
- format specified at |nvim_get_chan_info|.
+ format specified at |nvim_get_chan_info()|.
nvim_call_atomic({calls}) *nvim_call_atomic()*
Calls many API methods atomically.
@@ -836,10 +835,26 @@ nvim_get_proc({pid}) *nvim_get_proc()*
Return: ~
Map of process properties, or NIL if process not found.
+nvim__inspect_cell({row}, {col}) *nvim__inspect_cell()*
+ TODO: Documentation
+
==============================================================================
Buffer Functions *api-buffer*
+Unloaded Buffers:~
+
+Buffers may be unloaded by the |:bunload| command or the
+buffer's |'bufhidden'| option. When a buffer is unloaded its
+file contents are freed from memory and vim cannot operate on
+the buffer lines until it is reloaded (usually by opening the
+buffer again in a new window). API methods such as
+|nvim_buf_get_lines()| and |nvim_buf_line_count()| will be
+affected.
+
+You can use |nvim_buf_is_loaded()| or |nvim_buf_line_count()|
+to check whether a buffer is loaded.
+
nvim_buf_line_count({buffer}) *nvim_buf_line_count()*
Gets the buffer line count
@@ -847,7 +862,7 @@ nvim_buf_line_count({buffer}) *nvim_buf_line_count()*
{buffer} Buffer handle
Return: ~
- Line count
+ Line count, or 0 for unloaded buffer. |api-buffer|
nvim_buf_attach({buffer}, {send_buffer}, {opts}) *nvim_buf_attach()*
Activate updates from this buffer to the current channel.
@@ -896,7 +911,7 @@ nvim_buf_get_lines({buffer}, {start}, {end}, {strict_indexing})
error.
Return: ~
- Array of lines
+ Array of lines, or empty array for unloaded buffer.
*nvim_buf_set_lines()*
nvim_buf_set_lines({buffer}, {start}, {end}, {strict_indexing},
@@ -923,6 +938,25 @@ nvim_buf_set_lines({buffer}, {start}, {end}, {strict_indexing},
error.
{replacement} Array of lines to use as replacement
+nvim_buf_get_offset({buffer}, {index}) *nvim_buf_get_offset()*
+ Returns the byte offset for a line.
+
+ Line 1 (index=0) has offset 0. UTF-8 bytes are counted. EOL is
+ one byte. 'fileformat' and 'fileencoding' are ignored. The
+ line index just after the last line gives the total byte-count
+ of the buffer. A final EOL byte is counted if it would be
+ written, see 'eol'.
+
+ Unlike |line2byte()|, throws error for out-of-bounds indexing.
+ Returns -1 for unloaded buffer.
+
+ Parameters: ~
+ {buffer} Buffer handle
+ {index} Line index
+
+ Return: ~
+ Integer byte offset, or -1 for unloaded buffer.
+
nvim_buf_get_var({buffer}, {name}) *nvim_buf_get_var()*
Gets a buffer-scoped (b:) variable.
@@ -1013,14 +1047,28 @@ nvim_buf_set_name({buffer}, {name}) *nvim_buf_set_name()*
{buffer} Buffer handle
{name} Buffer name
+nvim_buf_is_loaded({buffer}) *nvim_buf_is_loaded()*
+ Checks if a buffer is valid and loaded. See |api-buffer| for
+ more info about unloaded buffers.
+
+ Parameters: ~
+ {buffer} Buffer handle
+
+ Return: ~
+ true if the buffer is valid and loaded, false otherwise.
+
nvim_buf_is_valid({buffer}) *nvim_buf_is_valid()*
- Checks if a buffer is valid
+ Checks if a buffer is valid.
+
+ Note:
+ Even if a buffer is valid it may have been unloaded. See
+ |api-buffer| for more info about unloaded buffers.
Parameters: ~
{buffer} Buffer handle
Return: ~
- true if the buffer is valid, false otherwise
+ true if the buffer is valid, false otherwise.
nvim_buf_get_mark({buffer}, {name}) *nvim_buf_get_mark()*
Return a tuple (row,col) representing the position of the
@@ -1075,8 +1123,8 @@ nvim_buf_add_highlight({buffer}, {src_id}, {hl_group}, {line},
*nvim_buf_clear_highlight()*
nvim_buf_clear_highlight({buffer}, {src_id}, {line_start}, {line_end})
- Clears highlights from a given source group and a range of
- lines
+ Clears highlights and virtual text from a given source id and
+ range of lines
To clear a source group in the entire buffer, pass in 0 and -1
to line_start and line_end respectively.
@@ -1089,6 +1137,37 @@ nvim_buf_clear_highlight({buffer}, {src_id}, {line_start}, {line_end})
{line_end} End of range of lines to clear (exclusive)
or -1 to clear to end of file.
+ *nvim_buf_set_virtual_text()*
+nvim_buf_set_virtual_text({buffer}, {src_id}, {line}, {chunks},
+ {opts})
+ Set the virtual text (annotation) for a buffer line.
+
+ By default (and currently the only option) the text will be
+ placed after the buffer text. Virtual text will never cause
+ reflow, rather virtual text will be truncated at the end of
+ the screen line. The virtual text will begin after one cell to
+ the right of the ordinary text, this will contain the |lcs-
+ eol| char if set, otherwise just be a space.
+
+ The same src_id can be used for both virtual text and
+ highlights added by nvim_buf_add_highlight. Virtual text is
+ cleared using nvim_buf_clear_highlight.
+
+ Parameters: ~
+ {buffer} Buffer handle
+ {src_id} Source group to use or 0 to use a new group, or
+ -1 for a ungrouped annotation
+ {line} Line to annotate with virtual text (zero-
+ indexed)
+ {chunks} A list of [text, hl_group] arrays, each
+ representing a text chunk with specified
+ highlight. `hl_group` element can be omitted for
+ no highlight.
+ {opts} Optional parameters. Currently not used.
+
+ Return: ~
+ The src_id that was used
+
==============================================================================
Window Functions *api-window*
diff --git a/runtime/doc/arabic.txt b/runtime/doc/arabic.txt
index 07350083c6..a3d979e519 100644
--- a/runtime/doc/arabic.txt
+++ b/runtime/doc/arabic.txt
@@ -313,4 +313,4 @@ There is one known minor bug,
No other bugs are known to exist.
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/autocmd.txt b/runtime/doc/autocmd.txt
index 5b2e226fbb..a2772e2485 100644
--- a/runtime/doc/autocmd.txt
+++ b/runtime/doc/autocmd.txt
@@ -4,7 +4,7 @@
VIM REFERENCE MANUAL by Bram Moolenaar
-Automatic commands *autocommand*
+Automatic commands *autocmd* *autocommand*
For a basic explanation, see section |40.3| in the user manual.
@@ -20,7 +20,7 @@ files matching *.c. You can also use autocommands to implement advanced
features, such as editing compressed files (see |gzip-example|). The usual
place to put autocommands is in your vimrc file.
- *E203* *E204* *E143* *E855* *E937*
+ *E203* *E204* *E143* *E855* *E937* *E952*
WARNING: Using autocommands is very powerful, and may lead to unexpected side
effects. Be careful not to destroy your text.
- It's a good idea to do some testing on an expendable copy of a file first.
@@ -44,6 +44,8 @@ effects. Be careful not to destroy your text.
Add {cmd} to the list of commands that Vim will
execute automatically on {event} for a file matching
{pat} |autocmd-patterns|.
+ Note: A quote character is seen as argument to the
+ :autocmd and won't start a comment.
Vim always adds the {cmd} after existing autocommands,
so that the autocommands execute in the order in which
they were given. See |autocmd-nested| for [nested].
@@ -79,7 +81,8 @@ will appear twice. To avoid this, define your autocommands in a group, so
that you can easily clear them: >
augroup vimrc
- autocmd! " Remove all vimrc autocommands
+ " Remove all vimrc autocommands
+ autocmd!
au BufNewFile,BufRead *.html so <sfile>:h/html.vim
augroup END
@@ -133,6 +136,8 @@ prompt. When one command outputs two messages this can happen anyway.
plugins, syntax highlighting, etc.
:au[tocmd]! [group] Remove ALL autocommands.
+ Note: a quote will be seen as argument to the :autocmd
+ and won't start a comment.
Warning: You should normally not do this without a
group, it breaks plugins, syntax highlighting, etc.
@@ -273,14 +278,16 @@ Name triggered by ~
|VimEnter| after doing all the startup stuff
|GUIEnter| after starting the GUI successfully
|GUIFailed| after starting the GUI failed
-|TermResponse| after the terminal response to |t_RV| is received
-|QuitPre| when using `:quit`, before deciding whether to quit
+|TermResponse| after the terminal response to t_RV is received
+|QuitPre| when using `:quit`, before deciding whether to exit
+|ExitPre| when using a command that may make Vim exit
|VimLeavePre| before exiting Nvim, before writing the shada file
|VimLeave| before exiting Nvim, after writing the shada file
|VimResume| after Nvim is resumed
|VimSuspend| before Nvim is suspended
Various
+|DiffUpdated| after diffs have been updated
|DirChanged| after the |current-directory| was changed
|FileChangedShell| Vim notices that a file changed since editing started
@@ -312,6 +319,7 @@ Name triggered by ~
|TabNew| when creating a new tab page
|TabNewEntered| after entering a new tab page
|TabClosed| after closing a tab page
+|CmdlineChanged| after a change was made to the command-line text
|CmdlineEnter| after entering cmdline mode
|CmdlineLeave| before leaving cmdline mode
|CmdwinEnter| after entering the command-line window
@@ -331,6 +339,7 @@ Name triggered by ~
|TextChangedP| after a change was made to the text in Insert mode
when popup menu visible
+|ColorSchemePre| before loading a color scheme
|ColorScheme| after loading a color scheme
|RemoteReply| a reply from a server Vim was received
@@ -494,14 +503,14 @@ ChanInfo State of channel changed, for instance the
client of a RPC channel described itself.
Sets these |v:event| keys:
info
- See |nvim_get_chan_info| for the format of the
- info Dictionary.
+ See |nvim_get_chan_info()| for the format of
+ the info Dictionary.
*ChanOpen*
ChanOpen Just after a channel was opened.
Sets these |v:event| keys:
info
- See |nvim_get_chan_info| for the format of the
- info Dictionary.
+ See |nvim_get_chan_info()| for the format of
+ the info Dictionary.
*CmdUndefined*
CmdUndefined When a user command is used but it isn't
defined. Useful for defining a command only
@@ -512,6 +521,10 @@ CmdUndefined When a user command is used but it isn't
command is defined. An alternative is to
always define the user command and have it
invoke an autoloaded function. See |autoload|.
+ *CmdlineChanged*
+CmdlineChanged After a change was made to the text in the
+ command line. Be careful not to mess up
+ the command line, it may cause Vim to lock up.
*CmdlineEnter*
CmdlineEnter After moving the cursor to the command line,
where the user can type a command or search
@@ -558,6 +571,10 @@ ColorScheme After loading a color scheme. |:colorscheme|
set, and <amatch> for the new colorscheme
name.
+ *ColorSchemePre*
+ColorSchemePre Before loading a color scheme. |:colorscheme|
+ Useful to setup removing things added by a
+ color scheme, before another one is loaded.
*CompleteDone*
CompleteDone After Insert mode completion is done. Either
@@ -646,6 +663,14 @@ FileChangedRO Before making the first change to a read-only
*E881*
If the number of lines changes saving for undo
may fail and the change will be aborted.
+ *ExitPre*
+ExitPre When using `:quit`, `:wq` in a way it makes
+ Vim exit, or using `:qall`, just after
+ |QuitPre|. Can be used to close any
+ non-essential window. Exiting may still be
+ cancelled if there is a modified buffer that
+ isn't automatically saved, use |VimLeavePre|
+ for really exiting.
*FileChangedShell*
FileChangedShell When Vim notices that the modification time of
a file has changed since editing started.
@@ -832,6 +857,9 @@ OptionSet After setting an option. The pattern is
plugin. You can always use `:noa` to prevent
triggering this autocommand.
+ When using |:set| in the autocommand the event
+ is not triggered again.
+
*QuickFixCmdPre*
QuickFixCmdPre Before a quickfix command is run (|:make|,
|:lmake|, |:grep|, |:lgrep|, |:grepadd|,
@@ -862,6 +890,7 @@ QuitPre When using `:quit`, `:wq` or `:qall`, before
or quits Vim. Can be used to close any
non-essential window if the current window is
the last ordinary window.
+ Also see |ExitPre|.
*RemoteReply*
RemoteReply When a reply from a Vim that functions as
server was received |server2client()|. The
@@ -929,6 +958,7 @@ SwapExists Detected an existing swap file when starting
It is not allowed to change to another buffer,
change a buffer name or change directory
here.
+ {only available with the +eval feature}
*Syntax*
Syntax When the 'syntax' option has been set. The
pattern is matched against the syntax name.
@@ -959,7 +989,7 @@ TermClose When a |terminal| job ends.
TermOpen When a |terminal| job is starting. Can be
used to configure the terminal buffer.
*TermResponse*
-TermResponse After the response to |t_RV| is received from
+TermResponse After the response to t_RV is received from
the terminal. The value of |v:termresponse|
can be used to do things depending on the
terminal version. Note that this event may be
@@ -989,6 +1019,10 @@ TextChangedP After a change was made to the text in the
User Never executed automatically. To be used for
autocommands that are only executed with
":doautocmd".
+ Note that when `:doautocmd User MyEvent` is
+ used while there are no matching autocommands,
+ you will get an error. If you don't want
+ that, define a dummy autocommand yourself.
*UserGettingBored*
UserGettingBored When the user presses the same key 42 times.
Just kidding! :-)
@@ -1037,9 +1071,10 @@ WinEnter After entering another window. Not done for
If the window is for another buffer, Vim
executes the BufEnter autocommands after the
WinEnter autocommands.
- Note: When using ":split fname" the WinEnter
- event is triggered after the split but before
- the file "fname" is loaded.
+ Note: For split and tabpage commands the
+ WinEnter event is triggered after the split
+ or tab command but before the file is loaded.
+
*WinLeave*
WinLeave Before leaving a window. If the window to be
entered next is for a different buffer, Vim
@@ -1349,7 +1384,7 @@ Careful: '[ and '] change when using commands that change the buffer.
In commands which expect a file name, you can use "<afile>" for the file name
that is being read |:<afile>| (you can also use "%" for the current file
name). "<abuf>" can be used for the buffer number of the currently effective
-buffer. This also works for buffers that doesn't have a name. But it doesn't
+buffer. This also works for buffers that don't have a name. But it doesn't
work for files without a buffer (e.g., with ":r file").
*gzip-example*
diff --git a/runtime/doc/change.txt b/runtime/doc/change.txt
index 9610d7359f..c73b460767 100644
--- a/runtime/doc/change.txt
+++ b/runtime/doc/change.txt
@@ -99,7 +99,7 @@ is an error when 'cpoptions' includes the 'E' flag.
J Join [count] lines, with a minimum of two lines.
Remove the indent and insert up to two spaces (see
below). Fails when on the last line of the buffer.
- If [count] is too big it is reduce to the number of
+ If [count] is too big it is reduced to the number of
lines available.
*v_J*
@@ -416,7 +416,7 @@ This depends on the 'nrformats' option:
For decimals a leading negative sign is considered for incrementing or
decrementing, for binary, octal and hex values, it won't be considered. To
-ignore the sign Visually select the number before using CTRL-A or CTRL-X.
+ignore the sign Visually select the number before using CTRL-A or CTRL-X.
For numbers with leading zeros (including all octal and hexadecimal numbers),
Vim preserves the number of characters in the number when possible. CTRL-A on
@@ -501,6 +501,7 @@ If the 'shiftround' option is on, the indent is rounded to a multiple of
If the 'smartindent' option is on, or 'cindent' is on and 'cinkeys' contains
'#' with a zero value, shift right does not affect lines starting with '#'
(these are supposed to be C preprocessor lines that must stay in column 1).
+This can be changed with the 'cino' option, see |cino-#|.
When the 'expandtab' option is off (this is the default) Vim uses <Tab>s as
much as possible to make the indent. You can use ">><<" to replace an indent
@@ -666,6 +667,7 @@ The flags that you can use for the substitute commands:
CTRL-E to scroll the screen up
CTRL-Y to scroll the screen down
+ *:s_e*
[e] When the search pattern fails, do not issue an error message and, in
particular, continue in maps as if no error occurred. This is most
useful to prevent the "No match" error from breaking a mapping. Vim
@@ -676,29 +678,34 @@ The flags that you can use for the substitute commands:
Trailing characters
Interrupted
+ *:s_g*
[g] Replace all occurrences in the line. Without this argument,
replacement occurs only for the first occurrence in each line. If the
'gdefault' option is on, this flag is on by default and the [g]
argument switches it off.
+ *:s_i*
[i] Ignore case for the pattern. The 'ignorecase' and 'smartcase' options
are not used.
+ *:s_I*
[I] Don't ignore case for the pattern. The 'ignorecase' and 'smartcase'
options are not used.
+ *:s_n*
[n] Report the number of matches, do not actually substitute. The [c]
flag is ignored. The matches are reported as if 'report' is zero.
Useful to |count-items|.
If \= |sub-replace-expression| is used, the expression will be
evaluated in the |sandbox| at every match.
-[p] Print the line containing the last substitute.
+[p] Print the line containing the last substitute. *:s_p*
-[#] Like [p] and prepend the line number.
+[#] Like [p] and prepend the line number. *:s_#*
-[l] Like [p] but print the text like |:list|.
+[l] Like [p] but print the text like |:list|. *:s_l*
+ *:s_r*
[r] Only useful in combination with `:&` or `:s` without arguments. `:&r`
works the same way as `:~`: When the search pattern is empty, use the
previously used search pattern instead of the search pattern from the
@@ -1135,7 +1142,7 @@ There are ten types of registers: *registers* *E354*
5. three read-only registers ":, "., "%
6. alternate buffer register "#
7. the expression register "=
-8. The selection and drop registers "*, "+ and "~
+8. The selection registers "* and "+
9. The black hole register "_
10. Last search pattern register "/
@@ -1236,7 +1243,7 @@ If the "= register is used for the "p" command, the String is split up at <NL>
characters. If the String ends in a <NL>, it is regarded as a linewise
register.
-8. Selection and drop registers "*, "+ and "~
+8. Selection registers "* and "+
Use these registers for storing and retrieving the selected text for the GUI.
See |quotestar| and |quoteplus|. When the clipboard is not available or not
working, the unnamed register is used instead. For Unix systems and Mac OS X,
@@ -1371,6 +1378,55 @@ to the name of an external program for Vim to use for text formatting. The
'textwidth' and other options have no effect on formatting by an external
program.
+ *format-formatexpr*
+The 'formatexpr' option can be set to a Vim script function that performs
+reformatting of the buffer. This should usually happen in an |ftplugin|,
+since formatting is highly dependent on the type of file. It makes
+sense to use an |autoload| script, so the corresponding script is only loaded
+when actually needed and the script should be called <filetype>format.vim.
+
+For example, the XML filetype plugin distributed with Vim in the $VIMRUNTIME
+directory, sets the 'formatexpr' option to: >
+
+ setlocal formatexpr=xmlformat#Format()
+
+That means, you will find the corresponding script, defining the
+xmlformat#Format() function, in the directory:
+`$VIMRUNTIME/autoload/xmlformat.vim`
+
+Here is an example script that removes trailing whitespace from the selected
+text. Put it in your autoload directory, e.g. ~/.vim/autoload/format.vim: >
+
+ func! format#Format()
+ " only reformat on explicit gq command
+ if mode() != 'n'
+ " fall back to Vims internal reformatting
+ return 1
+ endif
+ let lines = getline(v:lnum, v:lnum + v:count - 1)
+ call map(lines, {key, val -> substitute(val, '\s\+$', '', 'g')})
+ call setline('.', lines)
+
+ " do not run internal formatter!
+ return 0
+ endfunc
+
+You can then enable the formatting by executing: >
+ setlocal formatexpr=format#Format()
+
+Note: this function explicitly returns non-zero when called from insert mode
+(which basically means, text is inserted beyond the 'textwidth' limit). This
+causes Vim to fall back to reformat the text by using the internal formatter.
+
+However, if the |gq| command is used to reformat the text, the function
+will receive the selected lines, trim trailing whitespace from those lines and
+put them back in place. If you are going to split single lines into multiple
+lines, be careful not to overwrite anything.
+
+If you want to allow reformatting of text from insert or replace mode, one has
+to be very careful, because the function might be called recursively. For
+debugging it helps to set the 'debug' option.
+
*right-justify*
There is no command in Vim to right justify text. You can do it with
an external command, like "par" (e.g.: "!}par" to format until the end of the
@@ -1753,4 +1809,4 @@ The sorting can be interrupted, but if you interrupt it too late in the
process you may end up with duplicated lines. This also depends on the system
library function used.
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/channel.txt b/runtime/doc/channel.txt
index 1e4d643e95..be3efb371f 100644
--- a/runtime/doc/channel.txt
+++ b/runtime/doc/channel.txt
@@ -32,8 +32,13 @@ Channels support multiple modes or protocols. In the most basic
mode of operation, raw bytes are read and written to the channel.
The |rpc| protocol, based on the msgpack-rpc standard, enables nvim and the
process at the other end to send remote calls and events to each other.
-Additionally, the builtin |terminal-emulator|, is implemented on top of PTY
-channels.
+The builtin |terminal-emulator| is also implemented on top of PTY channels.
+
+Channel Id *channel-id*
+
+Each channel is identified by an integer id, unique for the life of the
+current Nvim session. Functions like |stdioopen()| return channel ids;
+functions like |chansend()| consume channel ids.
==============================================================================
2. Reading and writing raw bytes *channel-bytes*
@@ -64,8 +69,8 @@ be raised.
- The arguments passed to the callback function are:
- 0: The channel id
- 1: the raw data read from the channel, formatted as a |readfile()|-style
+ 0: |channel-id|
+ 1: Raw data read from the channel, formatted as a |readfile()|-style
list. If EOF occured, a single empty string `['']` will be passed in.
Note that the items in this list do not directly correspond to actual
lines in the output. See |channel-lines|
@@ -150,9 +155,8 @@ Nvim uses stdin/stdout to interact with the user over the terminal interface
(TUI). If Nvim is |--headless| the TUI is not started and stdin/stdout can be
used as a channel. See also |--embed|.
-Call |stdioopen()| during |startup| to open the stdio channel as channel-id 1.
-Nvim's stderr is always available as channel-id 2 (|v:stderr| to be explicit),
-a write-only bytes channel.
+Call |stdioopen()| during |startup| to open the stdio channel as |channel-id| 1.
+Nvim's stderr is always available as |v:stderr|, a write-only bytes channel.
Example: >
func! OnEvent(id, data, event)
diff --git a/runtime/doc/cmdline.txt b/runtime/doc/cmdline.txt
index c46a9fc2d8..3f22fcb504 100644
--- a/runtime/doc/cmdline.txt
+++ b/runtime/doc/cmdline.txt
@@ -4,8 +4,8 @@
VIM REFERENCE MANUAL by Bram Moolenaar
- *Cmdline-mode* *Command-line-mode*
-Command-line mode *Cmdline* *Command-line* *mode-cmdline* *:*
+ *Cmdline-mode* *Command-line-mode* *Cmdline*
+Command-line mode *cmdline* *Command-line* *mode-cmdline* *:*
Command-line mode is used to enter Ex commands (":"), search patterns
("/" and "?"), and filter commands ("!").
@@ -163,12 +163,14 @@ CTRL-R CTRL-F *c_CTRL-R_CTRL-F* *c_<C-R>_<C-F>*
CTRL-R CTRL-P *c_CTRL-R_CTRL-P* *c_<C-R>_<C-P>*
CTRL-R CTRL-W *c_CTRL-R_CTRL-W* *c_<C-R>_<C-W>*
CTRL-R CTRL-A *c_CTRL-R_CTRL-A* *c_<C-R>_<C-A>*
+CTRL-R CTRL-L *c_CTRL-R_CTRL-L* *c_<C-R>_<C-L>*
Insert the object under the cursor:
CTRL-F the Filename under the cursor
CTRL-P the Filename under the cursor, expanded with
'path' as in |gf|
CTRL-W the Word under the cursor
CTRL-A the WORD under the cursor; see |WORD|
+ CTRL-L the line under the cursor
When 'incsearch' is set the cursor position at the end of the
currently displayed match is used. With CTRL-W the part of
@@ -176,8 +178,8 @@ CTRL-R CTRL-A *c_CTRL-R_CTRL-A* *c_<C-R>_<C-A>*
*c_CTRL-R_CTRL-R* *c_<C-R>_<C-R>*
*c_CTRL-R_CTRL-O* *c_<C-R>_<C-O>*
-CTRL-R CTRL-R {0-9a-z"%#:-=. CTRL-F CTRL-P CTRL-W CTRL-A}
-CTRL-R CTRL-O {0-9a-z"%#:-=. CTRL-F CTRL-P CTRL-W CTRL-A}
+CTRL-R CTRL-R {0-9a-z"%#:-=. CTRL-F CTRL-P CTRL-W CTRL-A CTRL-L}
+CTRL-R CTRL-O {0-9a-z"%#:-=. CTRL-F CTRL-P CTRL-W CTRL-A CTRL-L}
Insert register or object under the cursor. Works like
|c_CTRL-R| but inserts the text literally. For example, if
register a contains "xy^Hz" (where ^H is a backspace),
@@ -210,7 +212,7 @@ CTRL-\ e {expr} *c_CTRL-\_e*
*c_CTRL-Y*
CTRL-Y When there is a modeless selection, copy the selection into
- the clipboard. |modeless-selection|
+ the clipboard.
If there is no selection CTRL-Y is inserted as a character.
CTRL-M or CTRL-J *c_CTRL-M* *c_CTRL-J* *c_<NL>* *c_<CR>* *c_CR*
@@ -376,10 +378,13 @@ CTRL-D List names that match the pattern in front of the cursor.
match is inserted. After the last match, the first is used
again (wrap around).
The behavior can be changed with the 'wildmode' option.
+ *c_<S-Tab>*
+<S-Tab> Like 'wildchar' or <Tab>, but begin with the last match and
+ then go to the previous match.
*c_CTRL-N*
CTRL-N After using 'wildchar' which got multiple matches, go to next
match. Otherwise recall more recent command-line from history.
-<S-Tab> *c_CTRL-P* *c_<S-Tab>*
+ *c_CTRL-P*
CTRL-P After using 'wildchar' which got multiple matches, go to
previous match. Otherwise recall older command-line from
history.
@@ -490,8 +495,46 @@ after a command causes the rest of the line to be ignored. This can be used
to add comments. Example: >
:set ai "set 'autoindent' option
It is not possible to add a comment to a shell command ":!cmd" or to the
-":map" command and a few others, because they see the '"' as part of their
-argument. This is mentioned where the command is explained.
+":map" command and a few others (mainly commands that expect expressions)
+that see the '"' as part of their argument:
+
+ :argdo
+ :autocmd
+ :bufdo
+ :cexpr (and the like)
+ :call
+ :cdo (and the like)
+ :command
+ :cscope (and the like)
+ :debug
+ :display
+ :echo (and the like)
+ :elseif
+ :execute
+ :folddoopen
+ :folddoclosed
+ :for
+ :grep (and the like)
+ :help (and the like)
+ :if
+ :let
+ :make
+ :map (and the like including :abbrev commands)
+ :menu (and the like)
+ :mkspell
+ :normal
+ :ownsyntax
+ :popup
+ :promptfind (and the like)
+ :registers
+ :return
+ :sort
+ :syntax
+ :tabdo
+ :tearoff
+ :vimgrep (and the like)
+ :while
+ :windo
*:bar* *:\bar*
'|' can be used to separate commands, so you can give multiple commands in one
@@ -786,6 +829,11 @@ Also see |`=|.
Note: these are typed literally, they are not special keys!
<cword> is replaced with the word under the cursor (like |star|)
<cWORD> is replaced with the WORD under the cursor (see |WORD|)
+ <cexpr> is replaced with the word under the cursor, including more
+ to form a C expression. E.g., when the cursor is on "arg"
+ of "ptr->arg" then the result is "ptr->arg"; when the
+ cursor is on "]" of "list[idx]" then the result is
+ "list[idx]". This is used for |v:beval_text|.
<cfile> is replaced with the path name under the cursor (like what
|gf| uses)
<afile> When executing autocommands, is replaced with the file name
@@ -834,7 +882,8 @@ These modifiers can be given, in this order:
directory.
:. Reduce file name to be relative to current directory, if
possible. File name is unmodified if it is not below the
- current directory.
+ current directory, but on MS-Windows the drive is removed if
+ it is the current drive.
For maximum shortness, use ":~:.".
:h Head of the file name (the last component and any separators
removed). Cannot be used with :e, :r or :t.
@@ -1098,4 +1147,4 @@ The character used for the pattern indicates the type of command-line:
@ string for |input()|
- text for |:insert| or |:append|
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/debug.txt b/runtime/doc/debug.txt
index 422255fa02..835b35b388 100644
--- a/runtime/doc/debug.txt
+++ b/runtime/doc/debug.txt
@@ -162,12 +162,8 @@ In WinDbg: choose Open Crash Dump on the File menu. Follow the instructions in
*get-ms-debuggers*
3.5 Obtaining Microsoft Debugging Tools ~
-The Debugging Tools for Windows (including WinDbg) can be downloaded from
- http://www.microsoft.com/whdc/devtools/debugging/default.mspx
-This includes the WinDbg debugger.
-
-Visual C++ 2005 Express Edition can be downloaded for free from:
- http://msdn.microsoft.com/vstudio/express/visualC/default.aspx
+Visual Studio 2017 Community Edition can be downloaded for free from:
+ https://visualstudio.microsoft.com/downloads/
=========================================================================
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/deprecated.txt b/runtime/doc/deprecated.txt
index 7c98b81867..92a6bd6b4f 100644
--- a/runtime/doc/deprecated.txt
+++ b/runtime/doc/deprecated.txt
@@ -42,10 +42,11 @@ Functions ~
*last_buffer_nr()* Obsolete name for bufnr("$").
Modifiers ~
+*cpo-<*
*:menu-<special>*
-*:menu-special* <> notation is always enabled. |cpo-<|
+*:menu-special* <> notation is always enabled.
*:map-<special>*
-*:map-special* <> notation is always enabled. |cpo-<|
+*:map-special* <> notation is always enabled.
Normal commands ~
*]f*
diff --git a/runtime/doc/develop.txt b/runtime/doc/develop.txt
index b3b60cbab8..cd81236f32 100644
--- a/runtime/doc/develop.txt
+++ b/runtime/doc/develop.txt
@@ -4,7 +4,7 @@
NVIM REFERENCE MANUAL
-Development of Nvim. *development*
+Development of Nvim *development*
Nvim is open source software. Everybody is encouraged to contribute.
https://github.com/neovim/neovim/blob/master/CONTRIBUTING.md
@@ -23,37 +23,17 @@ Note that some items conflict; this is intentional. A balance must be found.
NVIM IS... IMPROVED *design-improved*
-The IMproved bits of Vim should make it a better Vi, without becoming a
-completely different editor. Extensions are done with a "Vi spirit".
-- Use the keyboard as much as feasible. The mouse requires a third hand,
- which we don't have. Many terminals don't have a mouse.
-- When the mouse is used anyway, avoid the need to switch back to the
- keyboard. Avoid mixing mouse and keyboard handling.
-- Add commands and options in a consistent way. Otherwise people will have a
- hard time finding and remembering them. Keep in mind that more commands and
- options will be added later.
+The Neo bits of Nvim should make it a better Vim, without becoming a
+completely different editor.
+- In matters of taste, prefer Vim/Unix tradition. If there is no relevant
+ Vim/Unix tradition, consider the "common case".
- A feature that people do not know about is a useless feature. Don't add
obscure features, or at least add hints in documentation that they exist.
-- Minimize using CTRL and other modifiers, they are more difficult to type.
-- There are many first-time and inexperienced Vim users. Make it easy for
- them to start using Vim and learn more over time.
- There is no limit to the features that can be added. Selecting new features
is based on (1) what users ask for, (2) how much effort it takes to
implement and (3) someone actually implementing it.
-
-
-NVIM IS... MULTI PLATFORM *design-multi-platform*
-
-Vim tries to help as many users on as many platforms as possible.
-- Support many kinds of terminals. The minimal demands are cursor positioning
- and clear-screen. Commands should only use key strokes that most keyboards
- have. Support all the keys on the keyboard for mapping.
-- Support many platforms. A condition is that there is someone willing to do
- Vim development on that platform, and it doesn't mean messing up the code.
-- Support many compilers and libraries. Not everybody is able or allowed to
- install another compiler or GUI library.
-- People switch from one platform to another, and from GUI to terminal
- version. Features should be present in all versions.
+- Backwards compatibility is a feature. The RPC API in particular should
+ never break.
NVIM IS... WELL DOCUMENTED *design-documented*
@@ -90,15 +70,6 @@ NVIM IS... MAINTAINABLE *design-maintain*
knowledge spread to other parts of the code.
-NVIM IS... FLEXIBLE *design-flexible*
-
-Vim should make it easy for users to work in their preferred styles rather
-than coercing its users into particular patterns of work. This can be for
-items with a large impact or for details. The defaults are carefully chosen
-such that most users will enjoy using Vim as it is. Commands and options can
-be used to adjust Vim to the desire of the user and its environment.
-
-
NVIM IS... NOT *design-not*
Nvim is not an operating system; instead it should be composed with other
@@ -239,7 +210,14 @@ Example: `nvim_buf_changedtick_event`.
API-CLIENT *dev-api-client*
+Standard Features ~
+
+- Clients should call |nvim_set_client_info()| after connecting, so users and
+ plugins can detect the client by handling the |ChanInfo| event. This
+ avoids the need for special variables or other client hints.
+
Package Naming ~
+
API client packages should NOT be named something ambiguous like "neovim" or
"python-client". Use "nvim" as a prefix/suffix to some other identifier
following ecosystem conventions.
@@ -255,10 +233,11 @@ Examples of API-client package names:
BAD: neovim
Implementation ~
-Consider using libmpack instead of the msgpack.org C/C++ library. libmpack is
-small, efficient, and C89-compatible. It can be easily inlined in your
-C project source, too. https://github.com/libmpack/libmpack/
+Consider using libmpack instead of the msgpack.org C/C++ library. libmpack is
+small (can be inlined into your C/C++ project) and efficient (no allocations).
+It also implements msgpack-RPC.
+https://github.com/libmpack/libmpack/
EXTERNAL UI *dev-ui*
@@ -267,7 +246,13 @@ versions of Nvim may add new items to existing events. The API is strongly
backwards-compatible, but clients must not break if new (optional) fields are
added to existing events.
+Standard Features ~
+
External UIs are expected to implement these common features:
+
+- Call |nvim_set_client_info()| after connecting, so users and plugins can
+ detect the UI by handling the |ChanInfo| event. This avoids the need for
+ special variables and UI-specific config files (gvimrc, macvimrc, …).
- Cursor style (shape, color) should conform to the 'guicursor' properties
delivered with the mode_info_set UI event.
- Send the ALT/META ("Option" on macOS) key as a |<M-| chord.
@@ -280,4 +265,4 @@ External UIs are expected to implement these common features:
this event.
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/diff.txt b/runtime/doc/diff.txt
index c6c827a748..766240dfb0 100644
--- a/runtime/doc/diff.txt
+++ b/runtime/doc/diff.txt
@@ -5,7 +5,7 @@
*diff* *diff-mode*
-This file describes the |+diff| feature: Showing differences between two to
+This file describes the diff feature: Showing differences between two to
eight versions of the same file.
The basics are explained in section |08.7| of the user manual.
@@ -372,12 +372,16 @@ Example (this does almost the same as 'diffexpr' being empty): >
endif
silent execute "!diff -a --binary " . opt . v:fname_in . " " . v:fname_new .
\ " > " . v:fname_out
+ redraw!
endfunction
The "-a" argument is used to force comparing the files as text, comparing as
binaries isn't useful. The "--binary" argument makes the files read in binary
mode, so that a CTRL-Z doesn't end the text on DOS.
+The `redraw!` command may not be needed, depending on whether executing a
+shell command shows something on the display or not.
+
*E810* *E97*
Vim will do a test if the diff output looks alright. If it doesn't, you will
get an error message. Possible causes:
@@ -429,4 +433,4 @@ evaluating 'patchexpr'. This hopefully avoids that files in the current
directory are accidentally patched. Vim will also delete files starting with
v:fname_in and ending in ".rej" and ".orig".
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/digraph.txt b/runtime/doc/digraph.txt
index d3b03c6ef6..f05c73d737 100644
--- a/runtime/doc/digraph.txt
+++ b/runtime/doc/digraph.txt
@@ -1484,4 +1484,4 @@ char digraph hex dec official name ~
ſt ft FB05 64261 LATIN SMALL LIGATURE LONG S T
st st FB06 64262 LATIN SMALL LIGATURE ST
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/editing.txt b/runtime/doc/editing.txt
index 5939cb8a8b..34fb779fe7 100644
--- a/runtime/doc/editing.txt
+++ b/runtime/doc/editing.txt
@@ -376,6 +376,15 @@ On Unix and a few other systems you can also use backticks for the file name
argument, for example: >
:next `find . -name ver\\*.c -print`
:view `ls -t *.patch \| head -n1`
+Vim will run the command in backticks using the 'shell' and use the standard
+output as argument for the given Vim command (error messages from the shell
+command will be discarded).
+To see what shell command Vim is running, set the 'verbose' option to 4. When
+the shell command returns a non-zero exit code, an error message will be
+displayed and the Vim command will be aborted. To avoid this make the shell
+always return zero like so: >
+ :next `find . -name ver\\*.c -print \|\| true`
+
The backslashes before the star are required to prevent the shell from
expanding "ver*.c" prior to execution of the find program. The backslash
before the shell pipe symbol "|" prevents Vim from parsing it as command
@@ -824,8 +833,8 @@ flag is used for the ":substitute" command to avoid an error for files where
Note: When the 'write' option is off, you are not able to write any file.
*:w* *:write*
- *E502* *E503* *E504* *E505*
- *E512* *E514* *E667* *E796*
+ *E502* *E503* *E504* *E505*
+ *E512* *E514* *E667* *E796* *E949*
:w[rite] [++opt] Write the whole buffer to the current file. This is
the normal way to save changes to a file. It fails
when the 'readonly' option is set or when there is
@@ -881,6 +890,9 @@ used, for example, when the write fails and you want to try again later with
":w #". This can be switched off by removing the 'A' flag from the
'cpoptions' option.
+Note that the 'fsync' option matters here. If it's set it may make writes
+slower (but safer).
+
*:sav* *:saveas*
:sav[eas][!] [++opt] {file}
Save the current buffer under the name {file} and set
@@ -1225,9 +1237,6 @@ working directory, which in turn takes precedence over the global
working directory. If a local working directory (tab or window) does not
exist, the next-higher scope in the hierarchy applies.
-Commands for changing the working directory can be suffixed with a bang "!"
-(e.g. |:cd!|) which is ignored, for compatibility with Vim.
-
*:cd* *E747* *E472*
:cd[!] On non-Unix systems: Print the current directory
name. On Unix systems: Change the current directory
@@ -1545,4 +1554,4 @@ There are three different types of searching:
currently work with 'path' items that contain a URL or use the double star
with depth limiter (/usr/**2) or upward search (;) notations.
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/eval.txt b/runtime/doc/eval.txt
index c460e65c64..91986a9442 100644
--- a/runtime/doc/eval.txt
+++ b/runtime/doc/eval.txt
@@ -921,6 +921,13 @@ These three can be repeated and mixed. Examples:
expr8 *expr8*
-----
+This expression is either |expr9| or a sequence of the alternatives below,
+in any order. E.g., these are all possible:
+ expr9[expr1].name
+ expr9.name[expr1]
+ expr9(expr1, ...)[expr1].name
+
+
expr8[expr1] item of String or |List| *expr-[]* *E111*
*subscript*
@@ -1508,8 +1515,7 @@ v:errmsg Last given error message. It's allowed to set this variable.
:silent! next
:if v:errmsg != ""
: ... handle error
-< "errmsg" also works, for backwards compatibility.
-
+<
*v:errors* *errors-variable*
v:errors Errors found by assert functions, such as |assert_true()|.
This is a list of strings.
@@ -1529,7 +1535,7 @@ v:event Dictionary of event data for the current |autocommand|. Valid
KEY DESCRIPTION ~
abort Whether the event triggered during
an aborting condition (e.g. |c_Esc| or
- |c_CTRL-c| for |CmdlineLeave|).
+ |c_CTRL-C| for |CmdlineLeave|).
cmdlevel Level of cmdline.
cmdtype Type of cmdline, |cmdline-char|.
cwd Current working directory.
@@ -1813,17 +1819,16 @@ v:shell_error Result of the last shell command. When non-zero, the last
:if v:shell_error
: echo 'could not rename "foo" to "bar"!'
:endif
-< "shell_error" also works, for backwards compatibility.
-
+<
*v:statusmsg* *statusmsg-variable*
v:statusmsg Last given status message. It's allowed to set this variable.
*v:stderr* *stderr-variable*
-v:stderr Channel id for stderr. Unlike stdin and stdout (see
- |stdioopen()|), stderr is always open for writing. This channel
- ID is always 2, but this variable can be used to be explicit.
- Example: >
- :call chansend(v:stderr, "something bad happened\n")
+v:stderr |channel-id| corresponding to stderr. The value is always 2;
+ use this variable to make your code more descriptive.
+ Unlike stdin and stdout (see |stdioopen()|), stderr is always
+ open for writing. Example: >
+ :call chansend(v:stderr, "error: toaster empty\n")
<
*v:swapname* *swapname-variable*
v:swapname Only valid when executing |SwapExists| autocommands: Name of
@@ -1888,7 +1893,6 @@ v:testing Must be set before using `test_garbagecollect_now()`.
v:this_session Full filename of the last loaded or saved session file. See
|:mksession|. It is allowed to set this variable. When no
session file has been saved, this variable is empty.
- "this_session" also works, for backwards compatibility.
*v:throwpoint* *throwpoint-variable*
v:throwpoint The point where the exception most recently caught and not
@@ -2104,6 +2108,7 @@ gettabvar({nr}, {varname} [, {def}])
gettabwinvar({tabnr}, {winnr}, {name} [, {def}])
any {name} in {winnr} in tab page {tabnr}
getwininfo([{winid}]) List list of windows
+getwinpos([{timeout}]) List X and Y coord in pixels of the Vim window
getwinposx() Number X coord in pixels of GUI Vim window
getwinposy() Number Y coord in pixels of GUI Vim window
getwinvar({nr}, {varname} [, {def}])
@@ -2197,6 +2202,8 @@ msgpackdump({list}) List dump a list of objects to msgpack
msgpackparse({list}) List parse msgpack to a list of objects
nextnonblank({lnum}) Number line nr of non-blank line >= {lnum}
nr2char({expr}[, {utf8}]) String single char with ASCII/UTF8 value {expr}
+option_restore({list}) none restore options saved by option_save()
+option_save({list}) List save options values
nvim_...({args}...) any call nvim |api| functions
or({expr}, {expr}) Number bitwise OR
pathshorten({expr}) String shorten directory names in a path
@@ -2223,7 +2230,6 @@ remote_read({serverid} [, {timeout}])
remote_send({server}, {string} [, {idvar}])
String send key sequence
remote_startserver({name}) none become server {name}
- String send key sequence
remove({list}, {idx} [, {end}]) any remove items {idx}-{end} from {list}
remove({dict}, {key}) any remove entry {key} from {dict}
rename({from}, {to}) Number rename (move) file from {from} to {to}
@@ -2339,6 +2345,7 @@ tolower({expr}) String the String {expr} switched to lowercase
toupper({expr}) String the String {expr} switched to uppercase
tr({src}, {fromstr}, {tostr}) String translate chars of {src} in {fromstr}
to chars in {tostr}
+trim({text} [, {mask}]) String trim characters in {mask} from {text}
trunc({expr}) Float truncate Float {expr}
type({name}) Number type of variable {name}
undofile({name}) String undo file name for {name}
@@ -2354,6 +2361,7 @@ win_getid([{win} [, {tab}]]) Number get |window-ID| for {win} in {tab}
win_gotoid({expr}) Number go to |window-ID| {expr}
win_id2tabwin({expr}) List get tab and window nr from |window-ID|
win_id2win({expr}) Number get window nr from |window-ID|
+win_screenpos({nr}) List get screen position of window {nr}
winbufnr({nr}) Number buffer number of window {nr}
wincol() Number window column of the cursor
winheight({nr}) Number height of window {nr}
@@ -2414,10 +2422,10 @@ and({expr}, {expr}) *and()*
api_info() *api_info()*
Returns Dictionary of |api-metadata|.
-append({lnum}, {expr}) *append()*
- When {expr} is a |List|: Append each item of the |List| as a
+append({lnum}, {text}) *append()*
+ When {text} is a |List|: Append each item of the |List| as a
text line below line {lnum} in the current buffer.
- Otherwise append {expr} as one text line below line {lnum} in
+ Otherwise append {text} as one text line below line {lnum} in
the current buffer.
{lnum} can be zero to insert a line before the first one.
Returns 1 for failure ({lnum} out of range or out of memory),
@@ -2487,7 +2495,7 @@ assert_exception({error} [, {msg}]) *assert_exception()*
call assert_exception('E492:')
endtry
-assert_fails({cmd} [, {error}]) *assert_fails()*
+assert_fails({cmd} [, {error} [, {msg}]]) *assert_fails()*
Run {cmd} and add an error message to |v:errors| if it does
NOT produce an error.
When {error} is given it must match in |v:errmsg|.
@@ -2612,6 +2620,8 @@ bufexists({expr}) *bufexists()*
The result is a Number, which is |TRUE| if a buffer called
{expr} exists.
If the {expr} argument is a number, buffer numbers are used.
+ Number zero is the alternate buffer for the current window.
+
If the {expr} argument is a string it must match a buffer name
exactly. The name can be:
- Relative to the current directory.
@@ -2915,7 +2925,7 @@ confirm({msg} [, {choices} [, {default} [, {type}]]])
made. It returns the number of the choice. For the first
choice this is 1.
- {msg} is displayed in a |dialog| with {choices} as the
+ {msg} is displayed in a dialog with {choices} as the
alternatives. When {choices} is missing or empty, "&OK" is
used (and translated).
{msg} is a String, use '\n' to include a newline. Only on
@@ -2993,11 +3003,16 @@ cosh({expr}) *cosh()*
count({comp}, {expr} [, {ic} [, {start}]]) *count()*
Return the number of times an item with value {expr} appears
- in |List| or |Dictionary| {comp}.
+ in |String|, |List| or |Dictionary| {comp}.
+
If {start} is given then start with the item with this index.
{start} can only be used with a |List|.
+
When {ic} is given and it's |TRUE| then case is ignored.
+ When {comp} is a string then the number of not overlapping
+ occurrences of {expr} is returned. Zero is returned when
+ {expr} is an empty string.
*cscope_connection()*
cscope_connection([{num} , {dbpath} [, {prepend}]])
@@ -3226,12 +3241,12 @@ executable({expr}) *executable()*
On Windows it only checks if the file exists and
is not a directory, not if it's really executable.
On Windows an executable in the same directory as Vim is
- always found. Since this directory is added to $PATH it
- should also work to execute it |win32-PATH|.
+ always found (it is added to $PATH at |startup|).
The result is a Number:
1 exists
0 does not exist
-1 not implemented on this system
+ |exepath()| can be used to get the full path of an executable.
execute({command} [, {silent}]) *execute()*
Execute {command} and capture its output.
@@ -3881,7 +3896,7 @@ getbufinfo([{dict}])
endfor
<
To get buffer-local options use: >
- getbufvar({bufnr}, '&')
+ getbufvar({bufnr}, '&option_name')
<
*getbufline()*
@@ -4042,6 +4057,8 @@ getcmdline() *getcmdline()*
Example: >
:cmap <F7> <C-\>eescape(getcmdline(), ' \')<CR>
< Also see |getcmdtype()|, |getcmdpos()| and |setcmdpos()|.
+ Returns an empty string when entering a password or using
+ |inputsecret()|.
getcmdpos() *getcmdpos()*
Return the position of the cursor in the command line as a
@@ -4076,6 +4093,7 @@ getcompletion({pat}, {type} [, {filtered}]) *getcompletion()*
specifies what for. The following completion types are
supported:
+ arglist file names in argument list
augroup autocmd groups
buffer buffer names
behave :behave suboptions
@@ -4096,6 +4114,7 @@ getcompletion({pat}, {type} [, {filtered}]) *getcompletion()*
highlight highlight groups
history :history suboptions
locale locale names (as output of locale -a)
+ mapclear buffer argument
mapping mapping name
menu menus
messages |:messages| suboptions
@@ -4305,6 +4324,7 @@ getqflist([{what}]) *getqflist()*
list item is a dictionary with these entries:
bufnr number of buffer that has the file name, use
bufname() to get the name
+ module module name
lnum line number in the buffer (first line is 1)
col column number (first column is 1)
vcol |TRUE|: "col" is visual column
@@ -4329,34 +4349,63 @@ getqflist([{what}]) *getqflist()*
If the optional {what} dictionary argument is supplied, then
returns only the items listed in {what} as a dictionary. The
following string items are supported in {what}:
- context get the context stored with |setqflist()|
+ changedtick get the total number of changes made
+ to the list |quickfix-changedtick|
+ context get the |quickfix-context|
+ efm errorformat to use when parsing "lines". If
+ not present, then the 'errorformat' option
+ value is used.
+ id get information for the quickfix list with
+ |quickfix-ID|; zero means the id for the
+ current list or the list specified by "nr"
+ idx index of the current entry in the list
items quickfix list entries
+ lines parse a list of lines using 'efm' and return
+ the resulting entries. Only a |List| type is
+ accepted. The current quickfix list is not
+ modified. See |quickfix-parse|.
nr get information for this quickfix list; zero
- means the current quickfix list and '$' means
+ means the current quickfix list and "$" means
the last quickfix list
- title get the list title
- winid get the |window-ID| (if opened)
+ size number of entries in the quickfix list
+ title get the list title |quickfix-title|
+ winid get the quickfix |window-ID|
all all of the above quickfix properties
- Non-string items in {what} are ignored.
+ Non-string items in {what} are ignored. To get the value of a
+ particular item, set it to zero.
If "nr" is not present then the current quickfix list is used.
- To get the number of lists in the quickfix stack, set 'nr' to
- '$' in {what}. The 'nr' value in the returned dictionary
+ If both "nr" and a non-zero "id" are specified, then the list
+ specified by "id" is used.
+ To get the number of lists in the quickfix stack, set "nr" to
+ "$" in {what}. The "nr" value in the returned dictionary
contains the quickfix stack size.
- In case of error processing {what}, an empty dictionary is
- returned.
+ When "lines" is specified, all the other items except "efm"
+ are ignored. The returned dictionary contains the entry
+ "items" with the list of entries.
The returned dictionary contains the following entries:
- context context information stored with |setqflist()|
- items quickfix list entries
- nr quickfix list number
- title quickfix list title text
- winid quickfix |window-ID| (if opened)
-
- Examples: >
+ changedtick total number of changes made to the
+ list |quickfix-changedtick|
+ context quickfix list context. See |quickfix-context|
+ If not present, set to "".
+ id quickfix list ID |quickfix-ID|. If not
+ present, set to 0.
+ idx index of the current entry in the list. If not
+ present, set to 0.
+ items quickfix list entries. If not present, set to
+ an empty list.
+ nr quickfix list number. If not present, set to 0
+ size number of entries in the quickfix list. If not
+ present, set to 0.
+ title quickfix list title text. If not present, set
+ to "".
+ winid quickfix |window-ID|. If not present, set to 0
+
+ Examples (See also |getqflist-examples|): >
:echo getqflist({'all': 1})
:echo getqflist({'nr': 2, 'title': 1})
+ :echo getqflist({'lines' : ["F1:10:L10"]})
<
-
getreg([{regname} [, 1 [, {list}]]]) *getreg()*
The result is a String, which is the contents of register
{regname}. Example: >
@@ -4435,6 +4484,9 @@ gettabwinvar({tabnr}, {winnr}, {varname} [, {def}]) *gettabwinvar()*
:let list_is_on = gettabwinvar(1, 2, '&list')
:echo "myvar = " . gettabwinvar(3, 1, 'myvar')
<
+ To obtain all window-local variables use: >
+ gettabwinvar({tabnr}, {winnr}, '&')
+
*getwinposx()*
getwinposx() The result is a Number, which is the X coordinate in pixels of
the left hand side of the GUI Vim window. The result will be
@@ -4460,19 +4512,18 @@ getwininfo([{winid}]) *getwininfo()*
Each List item is a Dictionary with the following entries:
bufnr number of buffer in the window
height window height (excluding winbar)
- winbar 1 if the window has a toolbar, 0
- otherwise
loclist 1 if showing a location list
quickfix 1 if quickfix or location list window
tabnr tab page number
variables a reference to the dictionary with
window-local variables
width window width
+ winbar 1 if the window has a toolbar, 0
+ otherwise
+ wincol leftmost screen column of the window
winid |window-ID|
winnr window number
-
- To obtain all window-local variables use: >
- gettabwinvar({tabnr}, {winnr}, '&')
+ winrow topmost screen column of the window
getwinvar({winnr}, {varname} [, {def}]) *getwinvar()*
Like |gettabwinvar()| for the current tabpage.
@@ -4801,7 +4852,7 @@ input({opts})
where
hl_start_col is the first highlighted column,
hl_end_col is the last highlighted column (+ 1!),
- hl_group is |:hl| group used for highlighting.
+ hl_group is |:hi| group used for highlighting.
*E5403* *E5404* *E5405* *E5406*
Both hl_start_col and hl_end_col + 1 must point to the start
of the multibyte character (highlighting must not break
@@ -5000,13 +5051,12 @@ jobstart({cmd}[, {opts}]) *jobstart()*
<
Returns |job-id| on success, 0 on invalid arguments (or job
table is full), -1 if {cmd}[0] or 'shell' is not executable.
- For communication over the job's stdio, it is represented as a
- |channel|, and a channel ID is returned on success. Use
- |chansend()| (or |rpcnotify()| and |rpcrequest()| if "rpc" option
- was used) to send data to stdin and |chanclose()| to close stdio
- streams without stopping the job explicitly.
+ The returned job-id is a valid |channel-id| representing the
+ job's stdio streams. Use |chansend()| (or |rpcnotify()| and
+ |rpcrequest()| if "rpc" was enabled) to send data to stdin and
+ |chanclose()| to close the streams without stopping the job.
- See |job-control| and |rpc|.
+ See |job-control| and |RPC|.
NOTE: on Windows if {cmd} is a List:
- cmd[0] must be an executable (not a "built-in"). If it is
@@ -5048,7 +5098,7 @@ jobstart({cmd}[, {opts}]) *jobstart()*
- The channel ID on success
- 0 on invalid arguments
- -1 if {cmd}[0] is not executable.
- See |job-control|, |channels|, and |msgpack-rpc| for more information.
+ See also |job-control|, |channel|, |msgpack-rpc|.
jobstop({id}) *jobstop()*
Stop |job-id| {id} by sending SIGTERM to the job process. If
@@ -5058,18 +5108,24 @@ jobstop({id}) *jobstop()*
See |job-control|.
jobwait({ids}[, {timeout}]) *jobwait()*
- Wait for a set of jobs to finish. The {ids} argument is a list
- of |job-id|s to wait for. {timeout} is the maximum number of
- milliseconds to wait. During jobwait(), callbacks for jobs not
- in the {ids} list may be invoked. The screen will not redraw
- unless |:redraw| is invoked by a callback.
+ Wait for a set of jobs to complete.
+
+ {ids} is a list of |job-id|s to wait for.
+ {timeout} is the maximum number of milliseconds to wait.
+ {timeout} of zero can be used to check if a job-id is valid,
+ without waiting.
+
+ During jobwait() callbacks for jobs not in the {ids} list may
+ be invoked. The screen will not redraw unless |:redraw| is
+ invoked by a callback.
Returns a list of len({ids}) integers, where each integer is
- the wait-result of the corresponding job. Each wait-result is:
- Job exit-code, if the job exited
- -1 if the wait timed out for the job
- -2 if the job was interrupted
- -3 if the |job-id| is invalid.
+ the wait-result of the corresponding job. Each wait-result is
+ one of the following:
+ * Exit-code, if the job exited
+ * -1 if the timeout was exceeded
+ * -2 if the job was interrupted
+ * -3 if the |job-id| is invalid
join({list} [, {sep}]) *join()*
Join the items in {list} together into one String.
@@ -5311,7 +5367,8 @@ maparg({name} [, {mode} [, {abbr} [, {dict}]]]) *maparg()*
listing.
When there is no mapping for {name}, an empty String is
- returned.
+ returned. When the mapping for {name} is empty, then "<Nop>"
+ is returned.
The {name} can have special key names, like in the ":map"
command.
@@ -5378,9 +5435,10 @@ mapcheck({name} [, {mode} [, {abbr}]]) *mapcheck()*
mapping that matches with {name}, while maparg() only finds a
mapping for {name} exactly.
When there is no mapping that starts with {name}, an empty
- String is returned. If there is one, the rhs of that mapping
+ String is returned. If there is one, the RHS of that mapping
is returned. If there are several mappings that start with
- {name}, the rhs of one of them is returned.
+ {name}, the RHS of one of them is returned. This will be
+ "<Nop>" if the RHS is empty.
The mappings local to the current buffer are checked first,
then the global mappings.
This function can be used to check if a mapping can be added
@@ -5395,11 +5453,14 @@ match({expr}, {pat} [, {start} [, {count}]]) *match()*
When {expr} is a |List| then this returns the index of the
first item where {pat} matches. Each item is used as a
String, |Lists| and |Dictionaries| are used as echoed.
+
Otherwise, {expr} is used as a String. The result is a
Number, which gives the index (byte offset) in {expr} where
{pat} matches.
+
A match at the first character or |List| item returns zero.
If there is no match -1 is returned.
+
For getting submatches see |matchlist()|.
Example: >
:echo match("testing", "ing") " results in 4
@@ -5536,8 +5597,6 @@ matchaddpos({group}, {pos} [, {priority} [, {id} [, {dict}]]])
< Matches added by |matchaddpos()| are returned by
|getmatches()| with an entry "pos1", "pos2", etc., with the
value a list like the {pos} item.
- These matches cannot be set via |setmatches()|, however they
- can still be deleted by |clearmatches()|.
matcharg({nr}) *matcharg()*
Selects the {nr} match item, as set with a |:match|,
@@ -6382,11 +6441,9 @@ rpcstart({prog}[, {argv}]) {Nvim} *rpcstart()*
:let id = jobstart(['prog', 'arg1', 'arg2'], {'rpc': v:true})
rpcstop({channel}) {Nvim} *rpcstop()*
- Deprecated. This function was used to stop a job with |rpc|
- channel, and additionally closed rpc sockets. Instead use
- |jobstop()| to stop any job, and |chanclose|(id, "rpc") to close
- rpc communication without stopping the job. Use |chanclose|(id)
- to close any socket.
+ Deprecated. Instead use |jobstop()| to stop any job, and
+ chanclose(id, "rpc") to close RPC communication without
+ stopping the job. Use chanclose(id) to close any socket.
screenattr({row}, {col}) *screenattr()*
Like |screenchar()|, but return the attribute. This is a rather
@@ -6567,6 +6624,8 @@ searchpair({start}, {middle}, {end} [, {flags} [, {skip}
When {skip} is omitted or empty, every match is accepted.
When evaluating {skip} causes an error the search is aborted
and -1 returned.
+ {skip} can be a string, a lambda, a funcref or a partial.
+ Anything else makes the function fail.
For {stopline} and {timeout} see |search()|.
@@ -6846,10 +6905,12 @@ setpos({expr}, {list})
setqflist({list} [, {action}[, {what}]]) *setqflist()*
- Create or replace or add to the quickfix list using the items
- in {list}. Each item in {list} is a dictionary.
- Non-dictionary items in {list} are ignored. Each dictionary
- item can contain the following entries:
+ Create or replace or add to the quickfix list.
+
+ When {what} is not present, use the items in {list}. Each
+ item must be a dictionary. Non-dictionary items in {list} are
+ ignored. Each dictionary item can contain the following
+ entries:
bufnr buffer number; must be the number of a valid
buffer
@@ -6894,7 +6955,10 @@ setqflist({list} [, {action}[, {what}]]) *setqflist()*
freed.
If {action} is not present or is set to ' ', then a new list
- is created.
+ is created. The new quickfix list is added after the current
+ quickfix list in the stack and all the following lists are
+ freed. To add a new quickfix list at the end of the stack,
+ set "nr" in {what} to "$".
If {title} is given, it will be used to set |w:quickfix_title|
after opening the quickfix window.
@@ -6903,20 +6967,32 @@ setqflist({list} [, {action}[, {what}]]) *setqflist()*
only the items listed in {what} are set. The first {list}
argument is ignored. The following items can be specified in
{what}:
- context any Vim type can be stored as a context
+ context quickfix list context. See |quickfix-context|
+ efm errorformat to use when parsing text from
+ "lines". If this is not present, then the
+ 'errorformat' option value is used.
+ id quickfix list identifier |quickfix-ID|
items list of quickfix entries. Same as the {list}
argument.
+ lines use 'errorformat' to parse a list of lines and
+ add the resulting entries to the quickfix list
+ {nr} or {id}. Only a |List| value is supported.
nr list number in the quickfix stack; zero
- means the current quickfix list and '$' means
+ means the current quickfix list and "$" means
the last quickfix list
title quickfix list title text
Unsupported keys in {what} are ignored.
If the "nr" item is not present, then the current quickfix list
- is modified.
-
- Examples: >
- :call setqflist([], 'r', {'title': 'My search'})
- :call setqflist([], 'r', {'nr': 2, 'title': 'Errors'})
+ is modified. When creating a new quickfix list, "nr" can be
+ set to a value one greater than the quickfix stack size.
+ When modifying a quickfix list, to guarantee that the correct
+ list is modified, "id" should be used instead of "nr" to
+ specify the list.
+
+ Examples (See also |setqflist-examples|): >
+ :call setqflist([], 'r', {'title': 'My search'})
+ :call setqflist([], 'r', {'nr': 2, 'title': 'Errors'})
+ :call setqflist([], 'a', {'id':qfid, 'lines':["F1:10:L10"]})
<
Returns zero for success, -1 for failure.
@@ -7286,8 +7362,8 @@ stdpath({what}) *stdpath()* *E6100*
directories.
{what} Type Description ~
- cache String Cache directory. Useful for plugins
- that need temporary files to work.
+ cache String Cache directory. Arbitrary temporary
+ storage for plugins, etc.
config String User configuration directory. The
|init.vim| is stored here.
config_dirs List Additional configuration directories.
@@ -7295,6 +7371,9 @@ stdpath({what}) *stdpath()* *E6100*
is stored here.
data_dirs List Additional data directories.
+ Example: >
+ :echo stdpath("config")
+
str2float({expr}) *str2float()*
Convert String {expr} to a Float. This mostly works the same
@@ -7516,8 +7595,9 @@ submatch({nr} [, {list}]) *submatch()* *E935*
When substitute() is used recursively only the submatches in
the current (deepest) call can be obtained.
- Example: >
+ Examples: >
:s/\d\+/\=submatch(0) + 1/
+ :echo substitute(text, '\d\+', '\=submatch(0) + 1', '')
< This finds the first number in the line and adds one to it.
A line break is included as a newline character.
@@ -7642,7 +7722,7 @@ synconcealed({lnum}, {col}) *synconcealed()*
concealable region if there are two consecutive regions
with the same replacement character. For an example, if
the text is "123456" and both "23" and "45" are concealed
- and replace by the character "X", then:
+ and replaced by the character "X", then:
call returns ~
synconcealed(lnum, 1) [0, '', 0]
synconcealed(lnum, 2) [1, 'X', 1]
@@ -7959,6 +8039,22 @@ tr({src}, {fromstr}, {tostr}) *tr()*
echo tr("<blob>", "<>", "{}")
< returns "{blob}"
+trim({text} [, {mask}]) *trim()*
+ Return {text} as a String where any character in {mask} is
+ removed from the beginning and end of {text}.
+ If {mask} is not given, {mask} is all characters up to 0x20,
+ which includes Tab, space, NL and CR, plus the non-breaking
+ space character 0xa0.
+ This code deals with multibyte characters properly.
+
+ Examples: >
+ echo trim(" some text ")
+< returns "some text" >
+ echo trim(" \r\t\t\r RESERVE \t\n\x0B\xA0") . "_TAIL"
+< returns "RESERVE_TAIL" >
+ echo trim("rm<Xrm<>X>rrm", "rm<>")
+< returns "Xrm<>X" (characters in the middle are not removed)
+
trunc({expr}) *trunc()*
Return the largest integral value with magnitude less than or
equal to {expr} as a |Float| (truncate towards zero).
@@ -8161,6 +8257,14 @@ win_id2win({expr}) *win_id2win()*
Return the window number of window with ID {expr}.
Return 0 if the window cannot be found in the current tabpage.
+win_screenpos({nr}) *win_screenpos()*
+ Return the screen position of window {nr} as a list with two
+ numbers: [row, col]. The first window always has position
+ [1, 1].
+ {nr} can be the window number or the |window-ID|.
+ Return [0, 0] if the window cannot be found in the current
+ tabpage.
+
*winbufnr()*
winbufnr({nr}) The result is a Number, which is the number of the buffer
associated with window {nr}. {nr} can be the window number or
@@ -8456,7 +8560,7 @@ tag_old_static Compiled with support for old static tags
|tag-old-static|.
tag_any_white Compiled with support for any white characters in tags
files |tag-any-white|.
-termresponse Compiled with support for |t_RV| and |v:termresponse|.
+termresponse Compiled with support for t_RV and |v:termresponse|.
textobjects Compiled with support for |text-objects|.
timers Compiled with |timer_start()| support.
title Compiled with window title support |'title'|.
@@ -8473,6 +8577,8 @@ visual Compiled with Visual mode.
visualextra Compiled with extra Visual mode commands.
|blockwise-operators|.
vreplace Compiled with |gR| and |gr| commands.
+vtp Compiled for vcon support |+vtp| (check vcon to find
+ out if it works in the current console)).
wildignore Compiled with 'wildignore' option.
wildmenu Compiled with 'wildmenu' option.
win32 Windows version of Vim (32 or 64 bit).
@@ -8697,8 +8803,7 @@ may be larger.
It is also possible to define a function without any arguments. You must
still supply the () then.
-It is allowed to define another function inside a function
-body.
+It is allowed to define another function inside a function body.
*local-variables*
Inside a function local variables can be used. These will disappear when the
@@ -8855,9 +8960,6 @@ Also note that if you have two script files, and one calls a function in the
other and vice versa, before the used function is defined, it won't work.
Avoid using the autoload functionality at the toplevel.
-Hint: If you distribute a bunch of scripts you can pack them together with the
-|vimball| utility. Also read the user manual |distribute-script|.
-
==============================================================================
6. Curly braces names *curly-braces-names*
@@ -9076,6 +9178,14 @@ This does NOT work: >
variables are automatically deleted when the function
ends.
+:unl[et] ${env-name} ... *:unlet-environment* *:unlet-$*
+ Remove environment variable {env-name}.
+ Can mix {name} and ${env-name} in one :unlet command.
+ No error message is given for a non-existing
+ variable, also without !.
+ If the system does not support deleting an environment
+ variable, it is made emtpy.
+
:lockv[ar][!] [depth] {name} ... *:lockvar* *:lockv*
Lock the internal variable {name}. Locking means that
it can no longer be changed (until it is unlocked).
@@ -10614,7 +10724,7 @@ The sandbox is also used for the |:sandbox| command.
These items are not allowed in the sandbox:
- changing the buffer text
- - defining or changing mapping, autocommands, functions, user commands
+ - defining or changing mapping, autocommands, user commands
- setting certain options (see |option-summary|)
- setting certain v: variables (see |v:var|) *E794*
- executing a shell command
@@ -10636,6 +10746,7 @@ location. Insecure in this context are:
- sourcing a .nvimrc or .exrc in the current directory
- while executing in the sandbox
- value coming from a modeline
+- executing a function that was defined in the sandbox
Note that when in the sandbox and saving an option value and restoring it, the
option will still be marked as it was set in the sandbox.
@@ -10729,7 +10840,7 @@ Group Default link Colored expression ~
|expr-entry|
*hl-NvimColon* Delimiter `:` in |dict| literal
-*hl-NvimComma* Delimiter `,` in |dict|/|list|
+*hl-NvimComma* Delimiter `,` in |dict| or |list|
literal or
|expr-function|
*hl-NvimArrow* Delimiter `->` in |lambda|
diff --git a/runtime/doc/farsi.txt b/runtime/doc/farsi.txt
index a824c469b0..c5421137f8 100644
--- a/runtime/doc/farsi.txt
+++ b/runtime/doc/farsi.txt
@@ -205,4 +205,4 @@ changes made in the current line.
For more information about the bugs refer to rileft.txt.
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/filetype.txt b/runtime/doc/filetype.txt
index 74c453f79a..92404440da 100644
--- a/runtime/doc/filetype.txt
+++ b/runtime/doc/filetype.txt
@@ -152,8 +152,8 @@ file. It will be overwritten when installing a new version of Vim.
A. If you want to overrule all default file type checks.
This works by writing one file for each filetype. The disadvantage is that
- means there can be many files. The advantage is that you can simply drop
- this file in the right directory to make it work.
+ there can be many files. The advantage is that you can simply drop this
+ file in the right directory to make it work.
*ftdetect*
1. Create your user runtime directory. You would normally use the first
item of the 'runtimepath' option. Then create the directory "ftdetect"
@@ -273,6 +273,10 @@ then Vim will load all plugins in these directories and below:
Note that the last one is the value of $VIMRUNTIME which has been expanded.
+Note that when using a plugin manager or |packages| many directories will be
+added to 'runtimepath'. These plugins each require their own directory, don't
+put them directly in ~/.vim/plugin.
+
What if it looks like your plugin is not being loaded? You can find out what
happens when Vim starts up by using the |-V| argument: >
@@ -512,7 +516,7 @@ View manpages in Nvim. Supports highlighting, completion, locales, and
navigation. Also see |find-manpage|.
To use Nvim as a manpager: >
- export MANPAGER="nvim -c 'set ft=man' -"
+ export MANPAGER='nvim +Man!'
man.vim will always attempt to reuse the closest man window (above/left) but
otherwise create a split.
@@ -522,13 +526,14 @@ The case sensitivity of completion is controlled by 'fileignorecase'.
Commands:
Man {name} Display the manpage for {name}.
Man {sect} {name} Display the manpage for {name} and section {sect}.
-Man {name}({sect}) Alternate syntax which completes the section.
+Man {name}({sect}) Same as above.
Man {sect} {name}({sect}) Used during completion to show the real section of
when the provided section is a prefix, e.g. 1m vs 1.
-Man {path} Open the manpage specified by path. Prepend "./" if
- page is in the current directory.
+Man {path} Open the manpage at {path}. Prepend "./" if {path}
+ is relative to the current directory.
Man Open the manpage for the <cWORD> (man buffers)
or <cword> (non-man buffers) under the cursor.
+Man! Display the current buffer contents as a manpage.
|:Man| accepts command modifiers. For example, to use a vertical split: >
:vertical Man printf
@@ -568,11 +573,31 @@ By default the following options are set, in accordance with PEP8: >
setlocal expandtab shiftwidth=4 softtabstop=4 tabstop=8
-To disable this behaviour, set the following variable in your vimrc: >
-
+To disable this behavior, set the following variable in your vimrc: >
+
let g:python_recommended_style = 0
+R MARKDOWN *ft-rmd-plugin*
+
+By default ftplugin/html.vim is not sourced. If you want it sourced, add to
+your |vimrc|: >
+ let rmd_include_html = 1
+
+The 'formatexpr' option is set dynamically with different values for R code
+and for Markdown code. If you prefer that 'formatexpr' is not set, add to your
+|vimrc|: >
+ let rmd_dynamic_comments = 0
+
+
+R RESTRUCTURED TEXT *ft-rrst-plugin*
+
+The 'formatexpr' option is set dynamically with different values for R code
+and for ReStructured text. If you prefer that 'formatexpr' is not set, add to
+your |vimrc|: >
+ let rrst_dynamic_comments = 0
+
+
RPM SPEC *ft-spec-plugin*
Since the text for this plugin is rather long it has been put in a separate
@@ -749,4 +774,23 @@ You can change the default by defining the variable g:tex_flavor to the format
Currently no other formats are recognized.
- vim:tw=78:ts=8:ft=help:norl:
+VIM *ft-vim-plugin*
+
+The Vim filetype plugin defines mappings to move to the start and end of
+functions with [[ and ]]. Move around comments with ]" and [".
+
+The mappings can be disabled with: >
+ let g:no_vim_maps = 1
+
+
+ZIMBU *ft-zimbu-plugin*
+
+The Zimbu filetype plugin defines mappings to move to the start and end of
+functions with [[ and ]].
+
+The mappings can be disabled with: >
+ let g:no_zimbu_maps = 1
+<
+
+
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/fold.txt b/runtime/doc/fold.txt
index c644d63280..b7d92fb229 100644
--- a/runtime/doc/fold.txt
+++ b/runtime/doc/fold.txt
@@ -595,4 +595,4 @@ used. Otherwise the values from the window where the buffer was edited last
are used.
==============================================================================
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/ft_ada.txt b/runtime/doc/ft_ada.txt
index c1aa0904c4..771ccc3302 100644
--- a/runtime/doc/ft_ada.txt
+++ b/runtime/doc/ft_ada.txt
@@ -249,7 +249,7 @@ g:decada.Make_Command string
External command used for |g:decada.Make()| (|'makeprg'|).
*g:decada.Error_Format*
-g:decada.Error_Format| string
+g:decada.Error_Format string
Error format (|'errorformat'|).
==============================================================================
diff --git a/runtime/doc/ft_rust.txt b/runtime/doc/ft_rust.txt
index 750ba76afc..ff2e0ca56f 100644
--- a/runtime/doc/ft_rust.txt
+++ b/runtime/doc/ft_rust.txt
@@ -1,4 +1,6 @@
-*ft_rust.txt* Filetype plugin for Rust
+*ft_rust.txt* For Vim version 8.1. Last change: 2017 Nov 02
+
+This is documentation for the Rust filetype plugin.
==============================================================================
CONTENTS *rust*
@@ -234,4 +236,4 @@ It also has a few other mappings:
Note: This binding is only available in MacVim.
==============================================================================
- vim:tw=78:sw=4:noet:ts=8:ft=help:norl:
+ vim:tw=78:sw=4:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/ft_sql.txt b/runtime/doc/ft_sql.txt
index 29268f5753..324e2e44af 100644
--- a/runtime/doc/ft_sql.txt
+++ b/runtime/doc/ft_sql.txt
@@ -773,4 +773,4 @@ Setting the filetype back to Perl sets all the usual "perl" related items back
as they were.
-vim:tw=78:ts=8:ft=help:norl:
+vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/gui.txt b/runtime/doc/gui.txt
index 904c4be19c..06609a77e1 100644
--- a/runtime/doc/gui.txt
+++ b/runtime/doc/gui.txt
@@ -9,7 +9,7 @@ Vim's Graphical User Interface *gui* *GUI*
Type |gO| to see the table of contents.
==============================================================================
-1. Starting the GUI *gui-start* *E229* *E233*
+Starting the GUI *gui-start* *E229* *E233*
*ginit.vim* *gui-init* *gvimrc* *$MYGVIMRC*
The gvimrc file is where GUI-specific startup commands should be placed. It
@@ -71,7 +71,7 @@ and only the first one that is found is read.
:winp[os]
Display current position of the top left corner of the GUI vim
window in pixels. Does not work in all versions.
- Also see |getwinposx()| and |getwinposy()|.
+ Also see |getwinpos()|, |getwinposx()| and |getwinposy()|.
:winp[os] {X} {Y} *E466*
Put the GUI vim window at the given {X} and {Y} coordinates.
@@ -87,7 +87,7 @@ and only the first one that is found is read.
Obsolete, use ":set lines=11 columns=22".
==============================================================================
-2. Scrollbars *gui-scrollbars*
+Scrollbars *gui-scrollbars*
There are vertical scrollbars and a horizontal scrollbar. You may
configure which ones appear with the 'guioptions' option.
@@ -155,167 +155,7 @@ include the 'h' flag in 'guioptions'. Then the scrolling is limited by the
text of the current cursor line.
==============================================================================
-3. Mouse Control *gui-mouse*
-
-The mouse only works if the appropriate flag in the 'mouse' option is set.
-When the GUI is switched on, and 'mouse' wasn't set yet, the 'mouse' option is
-automatically set to "a", enabling it for all modes except for the
-|hit-enter| prompt. If you don't want this, a good place to change the
-'mouse' option is the "gvimrc" file.
-
-Other options that are relevant:
-'mousefocus' window focus follows mouse pointer |gui-mouse-focus|
-'mousemodel' what mouse button does which action
-'mousehide' hide mouse pointer while typing text
-'selectmode' whether to start Select mode or Visual mode
-
-A quick way to set these is with the ":behave" command.
- *:behave* *:be*
-:be[have] {model} Set behavior for mouse and selection. Valid
- arguments are:
- mswin MS-Windows behavior
- xterm Xterm behavior
-
- Using ":behave" changes these options:
- option mswin xterm ~
- 'selectmode' "mouse,key" ""
- 'mousemodel' "popup" "extend"
- 'keymodel' "startsel,stopsel" ""
- 'selection' "exclusive" "inclusive"
-
-In the $VIMRUNTIME directory, there is a script called |mswin.vim|, which will
-also map a few keys to the MS-Windows cut/copy/paste commands. This is NOT
-compatible, since it uses the CTRL-V, CTRL-X and CTRL-C keys. If you don't
-mind, use this command: >
- :so $VIMRUNTIME/mswin.vim
-
-For scrolling with a wheel on a mouse, see |scroll-mouse-wheel|.
-
-
-3.1 Moving Cursor with Mouse *gui-mouse-move*
-
-Click the left mouse button somewhere in a text buffer where you want the
-cursor to go, and it does!
-This works in when 'mouse' contains ~
-Normal mode 'n' or 'a'
-Visual mode 'v' or 'a'
-Insert mode 'i' or 'a'
-
-Select mode is handled like Visual mode.
-
-You may use this with an operator such as 'd' to delete text from the current
-cursor position to the position you point to with the mouse. That is, you hit
-'d' and then click the mouse somewhere.
-
- *gui-mouse-focus*
-The 'mousefocus' option can be set to make the keyboard focus follow the
-mouse pointer. This means that the window where the mouse pointer is, is the
-active window. Warning: this doesn't work very well when using a menu,
-because the menu command will always be applied to the top window.
-
-If you are on the ':' line (or '/' or '?'), then clicking the left or right
-mouse button will position the cursor on the ':' line (if 'mouse' contains
-'c', 'a' or 'A').
-
-In any situation the middle mouse button may be clicked to paste the current
-selection.
-
-
-3.2 Selection with Mouse *gui-mouse-select*
-
-The mouse can be used to start a selection. How depends on the 'mousemodel'
-option:
-'mousemodel' is "extend": use the right mouse button
-'mousemodel' is "popup": use the left mouse button, while keeping the Shift
-key pressed.
-
-If there was no selection yet, this starts a selection from the old cursor
-position to the position pointed to with the mouse. If there already is a
-selection then the closest end will be extended.
-
-If 'selectmode' contains "mouse", then the selection will be in Select mode.
-This means that typing normal text will replace the selection. See
-|Select-mode|. Otherwise, the selection will be in Visual mode.
-
-Double clicking may be done to make the selection word-wise, triple clicking
-makes it line-wise, and quadruple clicking makes it rectangular block-wise.
-
-See |gui-selections| on how the selection is used.
-
-
-3.3 Other Text Selection with Mouse *gui-mouse-modeless*
- *modeless-selection*
-A different kind of selection is used when:
-- in Command-line mode
-- in the Command-line window and pointing in another window
-- at the |hit-enter| prompt
-- whenever the current mode is not in the 'mouse' option
-- when holding the CTRL and SHIFT keys in the GUI
-
-Since Vim continues like the selection isn't there, and there is no mode
-associated with the selection, this is called modeless selection. Any text in
-the Vim window can be selected. Select the text by pressing the left mouse
-button at the start, drag to the end and release. To extend the selection,
-use the right mouse button when 'mousemodel' is "extend", or the left mouse
-button with the shift key pressed when 'mousemodel' is "popup".
-The selection is removed when the selected text is scrolled or changed.
-
-On the command line CTRL-Y can be used to copy the selection into the
-clipboard. To do this from Insert mode, use CTRL-O : CTRL-Y <CR>. When
-'guioptions' contains a or A (default on X11), the selection is automatically
-copied to the "* register.
-
-The middle mouse button can then paste the text. On non-X11 systems, you can
-use CTRL-R +.
-
-
-3.4 Using Mouse on Status Lines *gui-mouse-status*
-
-Clicking the left or right mouse button on the status line below a Vim
-window makes that window the current window. This actually happens on button
-release (to be able to distinguish a click from a drag action).
-
-With the left mouse button a status line can be dragged up and down, thus
-resizing the windows above and below it. This does not change window focus.
-
-The same can be used on the vertical separator: click to give the window left
-of it focus, drag left and right to make windows wider and narrower.
-
-
-3.5 Various Mouse Clicks *gui-mouse-various*
-
- <S-LeftMouse> Search forward for the word under the mouse click.
- When 'mousemodel' is "popup" this starts or extends a
- selection.
- <S-RightMouse> Search backward for the word under the mouse click.
- <C-LeftMouse> Jump to the tag name under the mouse click.
- <C-RightMouse> Jump back to position before the previous tag jump
- (same as "CTRL-T")
-
-
-3.6 Mouse Mappings *gui-mouse-mapping*
-
-The mouse events, complete with modifiers, may be mapped. Eg: >
- :map <S-LeftMouse> <RightMouse>
- :map <S-LeftDrag> <RightDrag>
- :map <S-LeftRelease> <RightRelease>
- :map <2-S-LeftMouse> <2-RightMouse>
- :map <2-S-LeftDrag> <2-RightDrag>
- :map <2-S-LeftRelease> <2-RightRelease>
- :map <3-S-LeftMouse> <3-RightMouse>
- :map <3-S-LeftDrag> <3-RightDrag>
- :map <3-S-LeftRelease> <3-RightRelease>
- :map <4-S-LeftMouse> <4-RightMouse>
- :map <4-S-LeftDrag> <4-RightDrag>
- :map <4-S-LeftRelease> <4-RightRelease>
-These mappings make selection work the way it probably should in a Motif
-application, with shift-left mouse allowing for extending the visual area
-rather than the right mouse button.
-
-Mouse mapping with modifiers does not work for modeless selection.
-
-
-3.7 Drag and drop *drag-n-drop*
+Drag and drop *drag-n-drop*
You can drag and drop one or more files into the Vim window, where they will
be opened as if a |:drop| command was used.
@@ -334,47 +174,12 @@ names with any Ex command. Special characters (space, tab, double quote and
'|'; backslash on non-MS-Windows systems) will be escaped.
==============================================================================
-4. Making GUI Selections *gui-selections*
-
- *quotestar*
-You may make selections with the mouse (see |gui-mouse-select|), or by using
-Vim's Visual mode (see |v|). If 'a' is present in 'guioptions', then
-whenever a selection is started (Visual or Select mode), or when the selection
-is changed, Vim becomes the owner of the windowing system's primary selection
-(on MS-Windows the |clipboard| is used).
-
- *primary-selection*
-There is a special register for storing this selection, it is the "*
-register. Nothing is put in here unless the information about what text is
-selected is about to change (e.g. with a left mouse click somewhere), or when
-another application wants to paste the selected text. Then the text is put
-in the "* register. For example, to cut a line and make it the current
-selection/put it on the clipboard: >
-
- "*dd
-
-Similarly, when you want to paste a selection from another application, e.g.,
-by clicking the middle mouse button, the selection is put in the "* register
-first, and then 'put' like any other register. For example, to put the
-selection (contents of the clipboard): >
-
- "*p
-
-Note that when pasting text from one Vim into another separate Vim, the type
-of selection (character, line, or block) will also be copied. For other
-applications the type is always character.
-
-When the "unnamed" string is included in the 'clipboard' option, the unnamed
-register is the same as the "* register. Thus you can yank to and paste the
-selection without prepending "* to commands.
-
-==============================================================================
-5. Menus *menus*
+Menus *menus*
For an introduction see |usr_42.txt| in the user manual.
-5.1 Using Menus *using-menus*
+Using Menus *using-menus*
Basically, menus can be used just like mappings. You can define your own
menus, as many as you like.
@@ -420,7 +225,7 @@ Pressing <F4> will start the menu. You can now use the cursor keys to select
a menu entry. Hit <Enter> to execute it. Hit <Esc> if you want to cancel.
This does require the |+menu| feature enabled at compile time.
-5.2 Creating New Menus *creating-menus*
+Creating New Menus *creating-menus*
*:me* *:menu* *:noreme* *:noremenu*
*:am* *:amenu* *:an* *:anoremenu*
@@ -662,7 +467,7 @@ when the right mouse button is pressed, if 'mousemodel' is set to popup or
popup_setpos.
-5.3 Showing What Menus Are Mapped To *showing-menus*
+Showing What Menus Are Mapped To *showing-menus*
To see what an existing menu is mapped to, use just one argument after the
menu commands (just like you would with the ":map" commands). If the menu
@@ -680,7 +485,7 @@ Note that hitting <Tab> while entering a menu name after a menu command may
be used to complete the name of the menu item.
-5.4 Executing Menus *execute-menus*
+Executing Menus *execute-menus*
*:em* *:emenu* *E334* *E335*
:[range]em[enu] {menu} Execute {menu} from the command line.
@@ -700,7 +505,7 @@ When using a range, if the lines match with '<,'>, then the menu is executed
using the last visual selection.
-5.5 Deleting Menus *delete-menus*
+Deleting Menus *delete-menus*
*:unme* *:unmenu*
*:aun* *:aunmenu*
@@ -730,7 +535,7 @@ If you want to get rid of the menu bar: >
:set guioptions-=m
-5.6 Disabling Menus *disable-menus*
+Disabling Menus *disable-menus*
*:menu-disable* *:menu-enable*
If you do not want to remove a menu, but disable it for a moment, this can be
@@ -746,7 +551,7 @@ When the argument is "*", all menus are affected. Otherwise the given menu
name and all existing submenus below it are affected.
-5.7 Examples for Menus *menu-examples*
+Examples for Menus *menu-examples*
Here is an example on how to add menu items with menu's! You can add a menu
item for the keyword under the cursor. The register "z" is used. >
@@ -763,7 +568,7 @@ mappings, or put these lines in your gvimrc; "<C-R>" is CTRL-R, "<CR>" is
the <CR> key. |<>|)
-5.8 Tooltips & Menu tips
+Tooltips & Menu tips
See section |42.4| in the user manual.
@@ -833,22 +638,5 @@ This creates a popup menu that doesn't exist on the main menu-bar.
Note that a menu that starts with ']' will not be displayed.
-==============================================================================
-6. Extras *gui-extras*
-
-This section describes other features which are related to the GUI.
-
-- With the GUI, there is no wait for one second after hitting escape, because
- the key codes don't start with <Esc>.
-
-- Typing ^V followed by a special key in the GUI will insert "<Key>", since
- the internal string used is meaningless. Modifiers may also be held down to
- get "<Modifiers-Key>".
-
-- In the GUI, the modifiers SHIFT, CTRL, and ALT (or META) may be used within
- mappings of special keys and mouse events. E.g.: :map <M-LeftDrag> <LeftDrag>
-
-- In the GUI, several normal keys may have modifiers in mappings etc, these
- are <Space>, <Tab>, <NL>, <CR>, <Esc>.
- vim:tw=78:sw=4:ts=8:ft=help:norl:
+ vim:tw=78:sw=4:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/hebrew.txt b/runtime/doc/hebrew.txt
index 642d80adc7..2f4b137bd3 100644
--- a/runtime/doc/hebrew.txt
+++ b/runtime/doc/hebrew.txt
@@ -134,4 +134,4 @@ The result is that all Hebrew characters are displayed as ~x. To solve this
problem, set isprint=@,128-255.
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/help.txt b/runtime/doc/help.txt
index 8a83cbc79c..c2ad25aeda 100644
--- a/runtime/doc/help.txt
+++ b/runtime/doc/help.txt
@@ -160,6 +160,9 @@ Versions ~
*standard-plugin-list*
Standard plugins ~
|pi_gzip.txt| Reading and writing compressed files
+|pi_health.txt| Healthcheck framework
+|pi_matchit.txt| Extended "%" matching
+|pi_msgpack.txt| msgpack utilities
|pi_netrw.txt| Reading and writing files over a network
|pi_paren.txt| Highlight matching parens
|pi_spec.txt| Filetype plugin to work with rpm spec files
@@ -182,4 +185,4 @@ will try to find help for it. Especially for options in single quotes, e.g.
'hlsearch'.
------------------------------------------------------------------------------
- vim:tw=78:fo=tcq2:isk=!-~,^*,^\|,^\":ts=8:ft=help:norl:
+ vim:tw=78:isk=!-~,^*,^\|,^\":ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/helphelp.txt b/runtime/doc/helphelp.txt
index adc72d1835..ba6dd02a29 100644
--- a/runtime/doc/helphelp.txt
+++ b/runtime/doc/helphelp.txt
@@ -364,4 +364,4 @@ highlighting. So do these:
You can find the details in $VIMRUNTIME/syntax/help.vim
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/if_cscop.txt b/runtime/doc/if_cscop.txt
index 451d525ea8..f05b3bb8ed 100644
--- a/runtime/doc/if_cscop.txt
+++ b/runtime/doc/if_cscop.txt
@@ -371,4 +371,4 @@ Cscope Home Page (http://cscope.sourceforge.net/): >
\:vert scs find a <C-R>=expand("<cword>")<CR><CR>
<
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/if_lua.txt b/runtime/doc/if_lua.txt
index 17c1a8a329..9dbbf87995 100644
--- a/runtime/doc/if_lua.txt
+++ b/runtime/doc/if_lua.txt
@@ -229,8 +229,7 @@ shared between command calls. All Lua default libraries are available. In
addition, Lua "print" function has its output redirected to the Nvim message
area, with arguments separated by a white space instead of a tab.
-Lua uses the "vim" module (see |lua-vim|) to issue commands to Nvim
-and manage buffers (|lua-buffer|) and windows (|lua-window|). However,
+Lua uses the "vim" module (see |lua-vim|) to issue commands to Nvim. However,
procedures that alter buffer content, open new buffers, and change cursor
position are restricted when the command is executed in the |sandbox|.
@@ -261,7 +260,7 @@ vim.stricmp(a, b) *lua-vim.stricmp*
greater then b or a is lesser then b respectively.
vim.type_idx *lua-vim.type_idx*
- Type index for use in |lua-special-tables|. Specifying one of the
+ Type index for use in |lua-special-tbl|. Specifying one of the
values from |lua-vim.types| allows typing the empty table (it is
unclear whether empty lua table represents empty list or empty array)
and forcing integral numbers to be |Float|. See |lua-special-tbl| for
diff --git a/runtime/doc/if_pyth.txt b/runtime/doc/if_pyth.txt
index 8940e69092..81a7816c93 100644
--- a/runtime/doc/if_pyth.txt
+++ b/runtime/doc/if_pyth.txt
@@ -4,7 +4,7 @@
VIM REFERENCE MANUAL by Paul Moore
-The Python Interface to Vim *python* *Python*
+The Python Interface to Vim *if_pyth* *python* *Python*
See |provider-python| for more information. {Nvim}
@@ -42,9 +42,10 @@ Example: >
endfunction
To see what version of Python you have: >
- :python import sys
:python print(sys.version)
+There is no need to import sys, it's done by default.
+
Note: Python is very sensitive to the indenting. Make sure the "class" line
and "EOF" do not have any indent.
@@ -63,6 +64,18 @@ Examples:
:pydo return "%s\t%d" % (line[::-1], len(line))
:pydo if line: return "%4d: %s" % (linenr, line)
<
+One can use `:pydo` in possible conjunction with `:py` to filter a range using
+python. For example: >
+
+ :py3 << EOF
+ needle = vim.eval('@a')
+ replacement = vim.eval('@b')
+
+ def py_vim_string_replace(str):
+ return str.replace(needle, replacement)
+ EOF
+ :'<,'>py3do return py_vim_string_replace(line)
+<
*:pyfile* *:pyf*
:[range]pyf[ile] {file}
Execute the Python script in {file}. The whole
@@ -79,7 +92,6 @@ Python commands cannot be used in the |sandbox|.
To pass arguments you need to set sys.argv[] explicitly. Example: >
- :python import sys
:python sys.argv = ["foo", "bar"]
:pyfile myscript.py
@@ -118,7 +130,7 @@ Instead, put the Python command in a function and call that function:
Note that "EOF" must be at the start of the line.
==============================================================================
-2. The vim module *python-vim*
+2. The vim module *python-vim* *python2*
Python code gets all of its access to vim (with one exception - see
|python-output| below) via the "vim" module. The vim module implements two
@@ -705,12 +717,31 @@ Raising SystemExit exception in python isn't endorsed way to quit vim, use: >
You can test what Python version is available with: >
if has('python')
echo 'there is Python 2.x'
- elseif has('python3')
+ endif
+ if has('python3')
echo 'there is Python 3.x'
endif
Note however, that if Python 2 and 3 are both available, but not loaded,
these has() calls will try to load them.
+To avoid loading the dynamic library, only check if Vim was compiled with
+python support: >
+ if has('python_compiled')
+ echo 'compiled with Python 2.x support'
+ if has('python_dynamic')
+ echo 'Python 2.x dynamically loaded'
+ endif
+ endif
+ if has('python3_compiled')
+ echo 'compiled with Python 3.x support'
+ if has('python3_dynamic')
+ echo 'Python 3.x dynamically loaded'
+ endif
+ endif
+
+This also tells you whether Python is dynamically loaded, which will fail if
+the runtime library cannot be found.
+
==============================================================================
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/if_ruby.txt b/runtime/doc/if_ruby.txt
index ace304c083..3c7c800fbf 100644
--- a/runtime/doc/if_ruby.txt
+++ b/runtime/doc/if_ruby.txt
@@ -3,7 +3,7 @@
VIM REFERENCE MANUAL by Shugo Maeda
-The Ruby Interface to Vim *ruby* *Ruby*
+The Ruby Interface to Vim *if_ruby* *ruby* *Ruby*
*E266* *E267* *E268* *E269* *E270* *E271* *E272* *E273*
@@ -180,4 +180,4 @@ $curwin The current window object.
$curbuf The current buffer object.
==============================================================================
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/indent.txt b/runtime/doc/indent.txt
index 7ba5a373dc..aae091aa99 100644
--- a/runtime/doc/indent.txt
+++ b/runtime/doc/indent.txt
@@ -410,10 +410,10 @@ The examples below assume a 'shiftwidth' of 4.
*cino-(*
(N When in unclosed parentheses, indent N characters from the line
with the unclosed parentheses. Add a 'shiftwidth' for every
- unclosed parentheses. When N is 0 or the unclosed parentheses
- is the first non-white character in its line, line up with the
- next non-white character after the unclosed parentheses.
- (default 'shiftwidth' * 2).
+ extra unclosed parentheses. When N is 0 or the unclosed
+ parentheses is the first non-white character in its line, line
+ up with the next non-white character after the unclosed
+ parentheses. (default 'shiftwidth' * 2).
cino= cino=(0 >
if (c1 && (c2 || if (c1 && (c2 ||
@@ -424,7 +424,8 @@ The examples below assume a 'shiftwidth' of 4.
{ {
<
*cino-u*
- uN Same as (N, but for one level deeper. (default 'shiftwidth').
+ uN Same as (N, but for one nesting level deeper.
+ (default 'shiftwidth').
cino= cino=u2 >
if (c123456789 if (c123456789
@@ -902,6 +903,25 @@ In PHP braces are not required inside 'case/default' blocks therefore 'case:'
and 'default:' are indented at the same level than the 'switch()' to avoid
meaningless indentation. You can use the above option to return to the
traditional way.
+-------------
+
+ *PHP_noArrowMatching*
+By default the indent script will indent multi-line chained calls by matching
+the position of the '->': >
+
+ $user_name_very_long->name()
+ ->age()
+ ->info();
+
+You can revert to the classic way of indenting by setting this option to 1: >
+ :let g:PHP_noArrowMatching = 1
+
+You will obtain the following result: >
+
+ $user_name_very_long->name()
+ ->age()
+ ->info();
+
PYTHON *ft-python-indent*
@@ -917,6 +937,11 @@ Indent after a nested paren: >
Indent for a continuation line: >
let g:pyindent_continue = '&sw * 2'
+The method uses searchpair() to look back for unclosed parenthesis. This can
+sometimes be slow, thus it timeouts after 150 msec. If you notice the
+indenting isn't correct, you can set a larger timeout in msec: >
+ let g:pyindent_searchpair_timeout = 500
+
R *ft-r-indent*
@@ -954,6 +979,11 @@ Below is an example of indentation with and without this option enabled:
paste(x) paste(x)
} }
<
+The code will be indented after lines that match the pattern
+`'\(&\||\|+\|-\|\*\|/\|=\|\~\|%\|->\)\s*$'`. If you want indentation after
+lines that match a different pattern, you should set the appropriate value of
+`r_indent_op_pattern` in your |vimrc|.
+
SHELL *ft-sh-indent*
@@ -1132,4 +1162,4 @@ indent for a continuation line, a line that starts with a backslash: >
Three times shiftwidth is the default value.
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/index.txt b/runtime/doc/index.txt
index f4f43aeac2..7024a57333 100644
--- a/runtime/doc/index.txt
+++ b/runtime/doc/index.txt
@@ -944,7 +944,7 @@ tag command note action in Visual mode ~
|v_i{| i{ same as iB
|v_i}| i} same as iB
|v_o| o move cursor to other corner of area
-|v_r| r 2 delete highlighted area and start insert
+|v_r| r 2 replace highlighted area with a character
|v_s| s 2 delete highlighted area and start insert
|v_u| u 2 make highlighted area lowercase
|v_v| v make Visual mode characterwise or stop
@@ -1472,7 +1472,6 @@ tag command action ~
|:sfind| :sf[ind] split current window and edit file in 'path'
|:sfirst| :sfir[st] split window and go to first file in the
argument list
-|:simalt| :sim[alt] Win32 GUI: simulate Windows ALT key
|:sign| :sig[n] manipulate signs
|:silent| :sil[ent] run a command silently
|:sleep| :sl[eep] do nothing for a few seconds
@@ -1615,4 +1614,4 @@ tag command action ~
|:~| :~ repeat last ":substitute"
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/insert.txt b/runtime/doc/insert.txt
index d612f038a6..81eeae80ed 100644
--- a/runtime/doc/insert.txt
+++ b/runtime/doc/insert.txt
@@ -410,12 +410,12 @@ An example for using CTRL-G U: >
inoremap ( ()<C-G>U<Left>
This makes it possible to use the cursor keys in Insert mode, without breaking
-the undo sequence and therefore using |.| (redo) will work as expected.
-Also entering a text like (with the "(" mapping from above): >
+the undo sequence and therefore using |.| (redo) will work as expected.
+Also entering a text like (with the "(" mapping from above):
Lorem ipsum (dolor
-will be repeatable by the |.|to the expected
+will be repeatable by using |.| to the expected
Lorem ipsum (dolor)
@@ -1026,13 +1026,13 @@ The function must return the column where the completion starts. It must be a
number between zero and the cursor column "col('.')". This involves looking
at the characters just before the cursor and including those characters that
could be part of the completed item. The text between this column and the
-cursor column will be replaced with the matches.
+cursor column will be replaced with the matches. If the returned value is
+larger than the cursor column, the cursor column is used.
-Special return values:
- -1 If no completion can be done, the completion will be cancelled with an
- error message.
- -2 To cancel silently and stay in completion mode.
- -3 To cancel silently and leave completion mode.
+Negative return values:
+ -2 To cancel silently and stay in completion mode.
+ -3 To cancel silently and leave completion mode.
+ Another negative value: completion starts at the cursor column
On the second invocation the arguments are:
a:findstart 0
@@ -1275,7 +1275,8 @@ it here: http://ctags.sourceforge.net/ Version 5.6 or later is recommended.
For version 5.5.4 you should add a patch that adds the "typename:" field:
ftp://ftp.vim.org/pub/vim/unstable/patches/ctags-5.5.4.patch
A compiled .exe for MS-Windows can be found at:
- http://georgevreilly.com/vim/ctags.html
+ http://ctags.sourceforge.net/
+ https://github.com/universal-ctags/ctags-win32
If you want to complete system functions you can do something like this. Use
ctags to generate a tags file for all the system header files: >
@@ -1507,15 +1508,15 @@ that begin with the filetype, "php", in this case. For example these syntax
groups are included by default with the PHP: phpEnvVar, phpIntVar,
phpFunctions.
-If you wish non-filetype syntax items to also be included, you can use a
-regular expression syntax (added in version 13.0 of autoload\syntaxcomplete.vim)
-to add items. Looking at the output from ":syntax list" while editing a PHP file
-I can see some of these entries: >
+If you wish non-filetype syntax items to also be included, you can use a
+regular expression syntax (added in version 13.0 of
+autoload/syntaxcomplete.vim) to add items. Looking at the output from
+":syntax list" while editing a PHP file I can see some of these entries: >
htmlArg,htmlTag,htmlTagName,javaScriptStatement,javaScriptGlobalObjects
To pick up any JavaScript and HTML keyword syntax groups while editing a PHP
-file, you can use 3 different regexs, one for each language. Or you can
-simply restrict the include groups to a particular value, without using
+file, you can use 3 different regexs, one for each language. Or you can
+simply restrict the include groups to a particular value, without using
a regex string: >
let g:omni_syntax_group_include_php = 'php\w\+,javaScript\w\+,html\w\+'
let g:omni_syntax_group_include_php = 'phpFunctions,phpMethods'
@@ -1528,9 +1529,9 @@ highlight. These items will be available within the omni completion list.
Some people may find this list unwieldy or are only interested in certain
items. There are two ways to prune this list (if necessary). If you find
-certain syntax groups you do not wish displayed you can use two different
-methods to identify these groups. The first specifically lists the syntax
-groups by name. The second uses a regular expression to identify both
+certain syntax groups you do not wish displayed you can use two different
+methods to identify these groups. The first specifically lists the syntax
+groups by name. The second uses a regular expression to identify both
syntax groups. Simply add one the following to your vimrc: >
let g:omni_syntax_group_exclude_php = 'phpCoreConstant,phpConstant'
let g:omni_syntax_group_exclude_php = 'php\w*Constant'
@@ -1553,22 +1554,22 @@ vimrc: >
For plugin developers, the plugin exposes a public function OmniSyntaxList.
This function can be used to request a List of syntax items. When editing a
-SQL file (:e syntax.sql) you can use the ":syntax list" command to see the
+SQL file (:e syntax.sql) you can use the ":syntax list" command to see the
various groups and syntax items. For example: >
- syntax list
-
-Yields data similar to this: >
- sqlOperator xxx some prior all like and any escape exists in is not
- or intersect minus between distinct
- links to Operator
- sqlType xxx varbit varchar nvarchar bigint int uniqueidentifier
- date money long tinyint unsigned xml text smalldate
- double datetime nchar smallint numeric time bit char
- varbinary binary smallmoney
- image float integer timestamp real decimal
+ syntax list
+
+Yields data similar to this:
+ sqlOperator xxx some prior all like and any escape exists in is not ~
+ or intersect minus between distinct ~
+ links to Operator ~
+ sqlType xxx varbit varchar nvarchar bigint int uniqueidentifier ~
+ date money long tinyint unsigned xml text smalldate ~
+ double datetime nchar smallint numeric time bit char ~
+ varbinary binary smallmoney ~
+ image float integer timestamp real decimal ~
There are two syntax groups listed here: sqlOperator and sqlType. To retrieve
-a List of syntax items you can call OmniSyntaxList a number of different
+a List of syntax items you can call OmniSyntaxList a number of different
ways. To retrieve all syntax items regardless of syntax group: >
echo OmniSyntaxList( [] )
@@ -1585,7 +1586,6 @@ From within a plugin, you would typically assign the output to a List: >
let myKeywords = []
let myKeywords = OmniSyntaxList( ['sqlKeyword'] )
-
SQL *ft-sql-omni*
@@ -1972,4 +1972,4 @@ self explanatory. Using the long or the short version depends on the
[READ ERRORS] not all of the file could be read
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/intro.txt b/runtime/doc/intro.txt
index 5c63d9e5e2..b74079e74e 100644
--- a/runtime/doc/intro.txt
+++ b/runtime/doc/intro.txt
@@ -1,7 +1,7 @@
*intro.txt* Nvim
- VIM REFERENCE MANUAL by Bram Moolenaar
+ NVIM REFERENCE MANUAL
Introduction to Vim *ref* *reference*
@@ -9,7 +9,7 @@ Introduction to Vim *ref* *reference*
Type |gO| to see the table of contents.
==============================================================================
-1. Introduction *intro*
+Introduction *intro*
Vim stands for Vi IMproved. It used to be Vi IMitation, but there are so many
improvements that a name change was appropriate. Vim is a text editor which
@@ -28,8 +28,8 @@ is not located in the default place. You can jump to subjects like with tags:
Use CTRL-] to jump to a subject under the cursor, use CTRL-T to jump back.
*pronounce*
-Vim is pronounced as one word, like Jim, not vi-ai-em. It's written with a
-capital, since it's a name, again like Jim.
+Vim is pronounced as one word, like Jim. Nvim is pronounced as N-vim, or,
+continuing with the Jim simile, N-Jim, which sounds like Ninja.
This manual is a reference for all the Vim commands and options. This is not
an introduction to the use of Vi or Vim, it gets a bit complicated here and
@@ -37,134 +37,67 @@ there. For beginners, there is a hands-on |tutor|. To learn using Vim, read
the user manual |usr_toc.txt|.
*book*
-There are many books on Vi that contain a section for beginners. There are
-two books I can recommend:
+There are many books on Vi and Vim. We recommend these books:
- "Vim - Vi Improved" by Steve Oualline
+ "Practical Vim" by Drew Neil
+ "Modern Vim" by Drew Neil
+ https://vimcasts.org/publications/
-This is the very first book completely dedicated to Vim. It is very good for
-beginners. The most often used commands are explained with pictures and
-examples. The less often used commands are also explained, the more advanced
-features are summarized. There is a comprehensive index and a quick
-reference. Parts of this book have been included in the user manual
-|frombook|.
-Published by New Riders Publishing. ISBN: 0735710015
-For more information try one of these:
- http://iccf-holland.org/click5.html
- http://www.vim.org/iccf/click5.html
+"Practical Vim" is a popular because of its focus on quickly learning common
+editing tasks with Vim. "Modern Vim" explores new features introduced by Nvim
+and Vim 8.
- "Learning the Vi editor" by Linda Lamb and Arnold Robbins
+ "Vim - Vi Improved" by Steve Oualline
-This is a book about Vi that includes a chapter on Vim (in the sixth edition).
-The first steps in Vi are explained very well. The commands that Vim adds are
-only briefly mentioned. There is also a German translation.
-Published by O'Reilly. ISBN: 1-56592-426-6.
+This is the first book dedicated to Vim. Parts of it were included in the
+user manual. |frombook| ISBN: 0735710015
+For more information try one of these:
+ https://iccf-holland.org/click5.html
+ https://www.vim.org/iccf/click5.html
==============================================================================
-2. Vim on the internet *internet*
+Nvim on the interwebs *internet*
*www* *WWW* *faq* *FAQ* *distribution* *download*
-The Vim pages contain the most recent information about Vim. They also
-contain links to the most recent version of Vim. The FAQ is a list of
-Frequently Asked Questions. Read this if you have problems.
-
- Vim home page: http://www.vim.org/
- Vim FAQ: http://vimdoc.sf.net/
- Downloading: ftp://ftp.vim.org/pub/vim/MIRRORS
-
-
-Usenet News group where Vim is discussed: *news* *usenet*
- comp.editors
-This group is also for other editors. If you write about Vim, don't forget to
-mention that.
-
- *mail-list* *maillist*
-There are several mailing lists for Vim:
-<vim@vim.org> *vim-use* *vim_use*
- For discussions about using existing versions of Vim: Useful mappings,
- questions, answers, where to get a specific version, etc. There are
- quite a few people watching this list and answering questions, also
- for beginners. Don't hesitate to ask your question here.
-<vim-dev@vim.org> *vim-dev* *vim_dev* *vimdev*
- For discussions about changing Vim: New features, porting, patches,
- beta-test versions, etc.
-<vim-announce@vim.org> *vim-announce* *vim_announce*
- Announcements about new versions of Vim; also for beta-test versions
- and ports to different systems. This is a read-only list.
-<vim-mac@vim.org> *vim-mac* *vim_mac*
- For discussions about using and improving the Macintosh version of
- Vim.
-
-See http://www.vim.org/maillist.php for the latest information.
-
-NOTE:
-- You can only send messages to these lists if you have subscribed!
-- You need to send the messages from the same location as where you subscribed
- from (to avoid spam mail).
-- Maximum message size is 40000 characters.
-
- *subscribe-maillist*
-If you want to join, send a message to
- <vim-subscribe@vim.org>
-Make sure that your "From:" address is correct. Then the list server will
-give you help on how to subscribe.
-
- *maillist-archive*
-For more information and archives look on the Vim maillist page:
-http://www.vim.org/maillist.php
+
+ Nvim home page: https://neovim.io/
+ Nvim FAQ: https://github.com/neovim/neovim/wiki/FAQ
+ Downloads: https://github.com/neovim/neovim/releases
+ Vim FAQ: https://vimhelp.appspot.com/vim_faq.txt.html
+ Vim home page: https://www.vim.org/
Bug reports: *bugs* *bug-reports* *bugreport.vim*
Report bugs on GitHub: https://github.com/neovim/neovim/issues
-Please be brief; all the time that is spent on answering mail is subtracted
-from the time that is spent on improving Vim! Always give a reproducible
-example and try to find out which settings or other things trigger the bug.
+Be brief, yet complete. Always give a reproducible example and try to find
+out which settings or other things trigger the bug.
-Preferably start Vim with: >
- vim --clean -u reproduce.vim
-Where reproduce.vim is a script that reproduces the problem. Try different
-machines, if relevant (is this an MS-Windows specific bug perhaps?).
+If Nvim crashes, try to get a backtrace. See |debug.txt|.
-Send me patches if you can!
+==============================================================================
+Sponsor Vim/Nvim development *sponsor* *register*
-It will help to include information about the version of Vim you are using and
-your setup. You can get the information with this command: >
- :so $VIMRUNTIME/bugreport.vim
-This will create a file "bugreport.txt" in the current directory, with a lot
-of information of your environment. Before sending this out, check if it
-doesn't contain any confidential information!
+Fixing bugs and adding new features takes a lot of time and effort. To show
+your appreciation for the work and motivate Bram and others to continue
+working on Vim please send a donation.
-If Vim crashes, please try to find out where. You can find help on this here:
-|debug.txt|.
+Since Bram is back to a paid job the money will now be used to help children
+in Uganda. See |uganda|. But at the same time donations increase Bram's
+motivation to keep working on Vim!
-In case of doubt or when you wonder if the problem has already been fixed but
-you can't find a fix for it, become a member of the vim-dev maillist and ask
-your question there. |maillist|
+For the most recent information about sponsoring look on the Vim web site:
- *year-2000* *Y2K*
-Since Vim internally doesn't use dates for editing, there is no year 2000
-problem to worry about. Vim does use the time in the form of seconds since
-January 1st 1970. It is used for a time-stamp check of the edited file and
-the swap file, which is not critical and should only cause warning messages.
+ https://www.vim.org/sponsor/
-There might be a year 2038 problem, when the seconds don't fit in a 32 bit int
-anymore. This depends on the compiler, libraries and operating system.
-Specifically, time_t and the ctime() function are used. And the time_t is
-stored in four bytes in the swap file. But that's only used for printing a
-file date/time for recovery, it will never affect normal editing.
-The Vim strftime() function directly uses the strftime() system function.
-localtime() uses the time() system function. getftime() uses the time
-returned by the stat() system function. If your system libraries are year
-2000 compliant, Vim is too.
+Neovim development is funded separately from Vim:
-The user may create scripts for Vim that use external commands. These might
-introduce Y2K problems, but those are not really part of Vim itself.
+ https://neovim.io/sponsors/
==============================================================================
-3. Credits *credits* *author* *Bram* *Moolenaar*
+Credits *credits* *author* *Bram* *Moolenaar*
Most of Vim was written by Bram Moolenaar <Bram@vim.org>.
@@ -273,7 +206,7 @@ Elvis Another Vi clone, made by Steve Kirkendall. Very compact but isn't
freely available.
==============================================================================
-4. Notation *notation*
+Notation *notation*
When syntax highlighting is used to read this, text that is not typed
literally is often highlighted with the Special group. These are items in [],
@@ -439,7 +372,7 @@ notation meaning equivalent decimal value(s) ~
<k0> - <k9> keypad 0 to 9 *keypad-0* *keypad-9*
<S-...> shift-key *shift* *<S-*
<C-...> control-key *control* *ctrl* *<C-*
-<M-...> alt-key or meta-key *META* *meta* *alt* *<M-*
+<M-...> alt-key or meta-key *META* *ALT* *<M-*
<A-...> same as <M-...> *<A-*
<D-...> command-key or "super" key *<D-*
-----------------------------------------------------------------------
@@ -494,7 +427,7 @@ examples and use them directly. Or type them literally, including the '<' and
":autocmd"!
==============================================================================
-5. Modes, introduction *vim-modes-intro* *vim-modes*
+Modes, introduction *vim-modes-intro* *vim-modes*
Vim has seven BASIC modes:
@@ -559,9 +492,9 @@ Virtual Replace mode Virtual Replace mode is similar to Replace mode, but
If the 'showmode' option is on "-- VREPLACE --" is
shown at the bottom of the window.
-Insert Normal mode Entered when CTRL-O given in Insert mode. This is
- like Normal mode, but after executing one command Vim
- returns to Insert mode.
+Insert Normal mode Entered when CTRL-O is typed in Insert mode (see
+ |i_CTRL-O|). This is like Normal mode, but after
+ executing one command Vim returns to Insert mode.
If the 'showmode' option is on "-- (insert) --" is
shown at the bottom of the window.
@@ -579,7 +512,7 @@ Insert Select mode Entered when starting Select mode from Insert mode.
is shown at the bottom of the window.
==============================================================================
-6. Switching from mode to mode *mode-switching*
+Switching from mode to mode *mode-switching*
If for any reason you do not know which mode you are in, you can always get
back to Normal mode by typing <Esc> twice. This doesn't work for Ex mode
@@ -650,7 +583,7 @@ Q or gQ Switch to Ex mode. This is like typing ":" commands
Use the ":vi" command |:visual| to exit this mode.
==============================================================================
-7. The window contents *window-contents*
+The window contents *window-contents*
In Normal mode and Insert/Replace mode the screen window will show the current
contents of the buffer: What You See Is What You Get. There are two
@@ -773,7 +706,7 @@ On most Unix systems, resizing the window is recognized and handled correctly
by Vim.
==============================================================================
-8. Definitions *definitions*
+Definitions *definitions*
buffer Contains lines of text, usually read from a file.
screen The whole area that Vim uses to work in. This can be
@@ -838,4 +771,4 @@ buffer lines logical lines window lines screen lines ~
6. ~
==============================================================================
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/job_control.txt b/runtime/doc/job_control.txt
index ed5f16902a..e5cd765e83 100644
--- a/runtime/doc/job_control.txt
+++ b/runtime/doc/job_control.txt
@@ -16,12 +16,14 @@ Concepts
Job Id *job-id*
-When a job starts it is assigned a number, unique for the life of the current
-Nvim session. Functions like |jobstart()| return job ids. Functions like
+Each job is identified by an integer id, unique for the life of the current
+Nvim session. Each job-id is a valid |channel-id|: they share the same "key
+space". Functions like |jobstart()| return job ids; functions like
|jobsend()|, |jobstop()|, |rpcnotify()|, and |rpcrequest()| take job ids.
-The job's stdio streams are represented as a |channel|. It is possible to send
-and recieve raw bytes, or use |msgpack-rpc|.
+Job stdio streams form a |channel| which can send and receive raw bytes or
+|msgpack-rpc| messages.
+
==============================================================================
Usage *job-control-usage*
diff --git a/runtime/doc/makehtml.awk b/runtime/doc/makehtml.awk
index 216bb5fac1..6e93c01c54 100644
--- a/runtime/doc/makehtml.awk
+++ b/runtime/doc/makehtml.awk
@@ -135,11 +135,11 @@ NR == 1 { nf=split(FILENAME,f,".")
# common case - Latin1
print "<META HTTP-EQUIV=\"Content-type\" content=\"text/html; charset=ISO-8859-1\">";
}
- print "<TITLE>Vim documentation: " f[1] "</TITLE>";
+ print "<TITLE>Nvim documentation: " f[1] "</TITLE>";
print "</HEAD>";
print "<BODY BGCOLOR=\"#ffffff\">";
- print "<H1>Vim documentation: " f[1] "</H1>";
+ print "<H1>Nvim documentation: " f[1] "</H1>";
print "<A NAME=\"top\"></A>";
if ( FILENAME != "help.txt" ) {
print "<A HREF=\"index.html\">main help file</A>\n";
diff --git a/runtime/doc/map.txt b/runtime/doc/map.txt
index 804b7410f6..30e7f644b3 100644
--- a/runtime/doc/map.txt
+++ b/runtime/doc/map.txt
@@ -371,8 +371,9 @@ several modes. In Vim you can use the ":nmap", ":vmap", ":omap", ":cmap" and
*omap-info*
Operator-pending mappings can be used to define a movement command that can be
-used with any operator. Simple example: ":omap { w" makes "y{" work like "yw"
-and "d{" like "dw".
+used with any operator. Simple example: >
+ :omap { w
+makes "y{" work like "yw" and "d{" like "dw".
To ignore the starting cursor position and select different text, you can have
the omap start Visual mode to select the text to be operated upon. Example
@@ -383,9 +384,11 @@ Normal mode commands find the first '(' character and select the first word
before it. That usually is the function name.
To enter a mapping for Normal and Visual mode, but not Operator-pending mode,
-first define it for all three modes, then unmap it for Operator-pending mode:
+first define it for all three modes, then unmap it for
+Operator-pending mode: >
:map xx something-difficult
:ounmap xx
+
Likewise for a mapping for Visual and Operator-pending mode or Normal and
Operator-pending mode.
@@ -866,7 +869,9 @@ an additional rule:
full-id In front of the match is a non-keyword character, or this is where
the line or insertion starts. Exception: When the abbreviation is
only one character, it is not recognized if there is a non-keyword
- character in front of it, other than a space or a tab.
+ character in front of it, other than a space or a tab. However, for
+ the command line "'<,'>" (or any other marks) is ignored, as if the
+ command line starts after it.
end-id In front of the match is a keyword character, or a space or a tab,
or this is where the line or insertion starts.
@@ -1208,6 +1213,7 @@ By default, the arguments of user defined commands do not undergo completion.
However, by specifying one or the other of the following attributes, argument
completion can be enabled:
+ -complete=arglist file names in argument list
-complete=augroup autocmd groups
-complete=buffer buffer names
-complete=behave :behave suboptions
@@ -1227,6 +1233,7 @@ completion can be enabled:
-complete=highlight highlight groups
-complete=history :history suboptions
-complete=locale locale names (as output of locale -a)
+ -complete=mapclear buffer argument
-complete=mapping mapping name
-complete=menu menus
-complete=messages |:messages| suboptions
@@ -1363,6 +1370,8 @@ The valid escape sequences are
<line1> The starting line of the command range.
*<line2>*
<line2> The final line of the command range.
+ *<range>*
+ <range> The number of items in the command range: 0, 1 or 2
*<count>*
<count> Any count supplied (as described for the '-range'
and '-count' attributes).
@@ -1483,4 +1492,4 @@ local to the script and use mappings local to the script. When the user
invokes the user command, it will run in the context of the script it was
defined in. This matters if |<SID>| is used in a command.
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/mbyte.txt b/runtime/doc/mbyte.txt
index d38c4fd019..24d9d01af0 100644
--- a/runtime/doc/mbyte.txt
+++ b/runtime/doc/mbyte.txt
@@ -1185,4 +1185,4 @@ Contributions specifically for the multi-byte features by:
Taro Muraoka <koron@tka.att.ne.jp>
Yasuhiro Matsumoto <mattn@mail.goo.ne.jp>
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/message.txt b/runtime/doc/message.txt
index 96c28009c4..d52905fc36 100644
--- a/runtime/doc/message.txt
+++ b/runtime/doc/message.txt
@@ -69,7 +69,7 @@ See `:messages` above.
LIST OF MESSAGES
*E222* *E228* *E232* *E256* *E293* *E298* *E304* *E317*
*E318* *E356* *E438* *E439* *E440* *E316* *E320* *E322*
- *E323* *E341* *E473* *E570* *E685* >
+ *E323* *E341* *E473* *E570* *E685* *E950* >
Add to read buffer
makemap: Illegal mode
Cannot create BalloonEval with both message and callback
@@ -90,6 +90,7 @@ LIST OF MESSAGES
Internal error
Internal error: {function}
fatal error in cs_manage_matches
+ Invalid count for del_bytes(): {N}
This is an internal error. If you can reproduce it, please send in a bug
report. |bugs|
@@ -843,4 +844,4 @@ The |g<| command can be used to see the last page of previous command output.
This is especially useful if you accidentally typed <Space> at the hit-enter
prompt.
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/mlang.txt b/runtime/doc/mlang.txt
index 8284d38fa4..a19d9fd2f4 100644
--- a/runtime/doc/mlang.txt
+++ b/runtime/doc/mlang.txt
@@ -203,4 +203,4 @@ a message adapt to language preferences of the user, >
:endif
<
- vim:tw=78:sw=4:ts=8:ft=help:norl:
+ vim:tw=78:sw=4:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/motion.txt b/runtime/doc/motion.txt
index 6f3a585ff3..84867318a4 100644
--- a/runtime/doc/motion.txt
+++ b/runtime/doc/motion.txt
@@ -986,12 +986,13 @@ These commands are not marks themselves, but jump to a mark:
==============================================================================
8. Jumps *jump-motions*
-A "jump" is one of the following commands: "'", "`", "G", "/", "?", "n",
-"N", "%", "(", ")", "[[", "]]", "{", "}", ":s", ":tag", "L", "M", "H" and
-the commands that start editing a new file. If you make the cursor "jump"
-with one of these commands, the position of the cursor before the jump is
+A "jump" is a command that normally moves the cursor several lines away. If
+you make the cursor "jump" the position of the cursor before the jump is
remembered. You can return to that position with the "''" and "``" command,
-unless the line containing that position was changed or deleted.
+unless the line containing that position was changed or deleted. The
+following commands are "jump" commands: "'", "`", "G", "/", "?", "n", "N",
+"%", "(", ")", "[[", "]]", "{", "}", ":s", ":tag", "L", "M", "H" and the
+commands that start editing a new file.
*CTRL-O*
CTRL-O Go to [count] Older cursor position in jump list
@@ -1117,7 +1118,7 @@ remembered.
*:changes*
:changes Print the change list. A ">" character indicates the
current position. Just after a change it is below the
- newest entry, indicating that "g;" takes you to the
+ newest entry, indicating that `g;` takes you to the
newest entry position. The first column indicates the
count needed to take you to this position. Example:
@@ -1127,8 +1128,8 @@ remembered.
1 14 54 the latest changed line
>
- The "3g;" command takes you to line 9. Then the
- output of ":changes is:
+ The `3g;` command takes you to line 9. Then the
+ output of `:changes` is:
change line col text ~
> 0 9 8 bla bla bla
@@ -1271,7 +1272,10 @@ the current line is included. You can then use "%" to go to the matching line.
H To line [count] from top (Home) of window (default:
first line on the window) on the first non-blank
character |linewise|. See also 'startofline' option.
- Cursor is adjusted for 'scrolloff' option.
+ Cursor is adjusted for 'scrolloff' option, unless an
+ operator is pending, in which case the text may
+ scroll. E.g. "yH" yanks from the first visible line
+ until the cursor line (inclusive).
*M*
M To Middle line of window, on the first non-blank
@@ -1281,11 +1285,14 @@ M To Middle line of window, on the first non-blank
L To line [count] from bottom of window (default: Last
line on the window) on the first non-blank character
|linewise|. See also 'startofline' option.
- Cursor is adjusted for 'scrolloff' option.
+ Cursor is adjusted for 'scrolloff' option, unless an
+ operator is pending, in which case the text may
+ scroll. E.g. "yL" yanks from the cursor to the last
+ visible line.
<LeftMouse> Moves to the position on the screen where the mouse
click is |exclusive|. See also |<LeftMouse>|. If the
position is in a status line, that window is made the
active window and the cursor is not moved.
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/msgpack_rpc.txt b/runtime/doc/msgpack_rpc.txt
index a29569f049..862aa7b750 100644
--- a/runtime/doc/msgpack_rpc.txt
+++ b/runtime/doc/msgpack_rpc.txt
@@ -61,18 +61,15 @@ To get a formatted dump of the API using python (requires the `pyyaml` and
3. Connecting *rpc-connecting*
See |channel-intro|, for various ways to open a channel. Most of the channel
-opening functions take an `rpc` key in the options dictionary, to enable rpc.
+opening functions take an `rpc` key in the options dictionary, to enable RPC.
-Additionally, rpc channels can be opened by other processes connecting to
+Additionally, RPC channels can be opened by other processes connecting to
TCP/IP sockets or named pipes listened to by nvim.
-An rpc socket is automatically created with each instance. The socket
- location is stored in |v:servername|. By default this is a named pipe
-with an automatically generated address. See |XXX|.
-
-To make Nvim listen on a TCP/IP socket instead, specify |--listen|: >
+Nvim creates a default RPC socket at |startup|, given by |v:servername|. To
+start with a TCP/IP socket instead, use |--listen| with a TCP-style address: >
nvim --listen 127.0.0.1:6666
-<Also, more sockets and named pipes can be listened on using |serverstart()|.
+Additional sockets and named pipes can be started with |serverstart()|.
Note that localhost TCP sockets are generally less secure than named pipes,
and can lead to vunerabilities like remote code execution.
diff --git a/runtime/doc/nvim.txt b/runtime/doc/nvim.txt
index b8a481a016..07eb48aea3 100644
--- a/runtime/doc/nvim.txt
+++ b/runtime/doc/nvim.txt
@@ -8,7 +8,9 @@ Nvim *nvim* *nvim-intro*
Nvim is based on Vim by Bram Moolenaar.
-If you are new to Vim see |help.txt|, or type ":Tutor".
+If you are new to Vim, try the 30-minute tutorial: >
+ :Tutor<Enter>
+
If you already use Vim see |nvim-from-vim| for a quickstart.
Nvim is emphatically a fork of Vim, not a clone: compatibility with Vim is
@@ -20,29 +22,24 @@ differences from Vim.
==============================================================================
Transitioning from Vim *nvim-from-vim*
-To start the transition, create init.vim in the correct directory for your
-platform.
-
-For Linux, macOS and other Unixes, create the file at ~/.config/nvim/init.vim.
+1. To start the transition, create your |init.vim| (user config) file: >
-For Windows, create the file at %LOCALAPPDATA%\nvim\init.vim. `%LOCALAPPDATA%`
-usually expands to `C:\Users\<username>\AppData\Local`.
+ :call mkdir(stdpath('config'), 'p')
+ :exe 'edit '.stdpath('config').'/init.vim'
-Note: If your system sets `$XDG_CONFIG_HOME`, use that instead of `~/.config`
-or `%LOCALAPPDATA%` in the paths above. Nvim follows the XDG |base-directories|
-convention.
+2. Add these contents to the file: >
-Next, add these contents to the file:
->
set runtimepath^=~/.vim runtimepath+=~/.vim/after
let &packpath = &runtimepath
source ~/.vimrc
-<
+
+3. Restart Nvim, your existing Vim config will be loaded.
+
See |provider-python| and |provider-clipboard| for additional software you
might need to use some features.
-Your Vim configuration might not be entirely compatible with Nvim. For a
-full list of differences between Vim and Nvim see |vim-differences|.
+Your Vim configuration might not be entirely Nvim-compatible.
+See |vim-differences| for the full list of changes.
The |'ttymouse'| option, for example, was removed from Nvim (mouse support
should work without it). If you use the same |vimrc| for Vim and Nvim,
diff --git a/runtime/doc/options.txt b/runtime/doc/options.txt
index 81726ca46b..d1e84c5aec 100644
--- a/runtime/doc/options.txt
+++ b/runtime/doc/options.txt
@@ -100,17 +100,17 @@ and the following arguments will be ignored.
When 'verbose' is non-zero, displaying an option value will also tell where it
was last set. Example: >
:verbose set shiftwidth cindent?
-< shiftwidth=4 ~
- Last set from modeline ~
- cindent ~
- Last set from /usr/local/share/vim/vim60/ftplugin/c.vim ~
+< shiftwidth=4 ~
+ Last set from modeline line 1 ~
+ cindent ~
+ Last set from /usr/local/share/vim/vim60/ftplugin/c.vim line 30 ~
This is only done when specific option values are requested, not for ":verbose
set all" or ":verbose set" without an argument.
When the option was set by hand there is no "Last set" message.
When the option was set while executing a function, user command or
autocommand, the script in which it was defined is reported.
A few special texts:
- Last set from modeline ~
+ Last set from modeline line 1 ~
Option was set in a |modeline|.
Last set from --cmd argument ~
Option was set with command line argument |--cmd| or +.
@@ -575,8 +575,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'ambiwidth'* *'ambw'*
'ambiwidth' 'ambw' string (default: "single")
global
- {only available when compiled with the |+multi_byte|
- feature}
Tells Vim what to do with characters with East Asian Width Class
Ambiguous (such as Euro, Registered Sign, Copyright Sign, Greek
letters, Cyrillic letters).
@@ -611,8 +609,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'autochdir'* *'acd'* *'noautochdir'* *'noacd'*
'autochdir' 'acd' boolean (default off)
global
- {only available when compiled with it, use
- exists("+autochdir") to check}
When on, Vim will change the current working directory whenever you
open a file, switch buffers, delete a buffer or open/close a window.
It will change to the directory containing the file which was opened
@@ -679,7 +675,9 @@ A jump table for the options with a short description can be found at |Q_op|.
global or local to buffer |global-local|
When a file has been detected to have been changed outside of Vim and
it has not been changed inside of Vim, automatically read it again.
- When the file has been deleted this is not done. |timestamp|
+ When the file has been deleted this is not done, so you have the text
+ from before it was deleted. When it appears again then it is read.
+ |timestamp|
If this option has a local value, use this command to switch back to
using the global value: >
:set autoread<
@@ -693,6 +691,8 @@ A jump table for the options with a short description can be found at |Q_op|.
'{A-Z0-9}, or `{A-Z0-9} command takes one to another file.
Note that for some commands the 'autowrite' option is not used, see
'autowriteall' for that.
+ Some buffers will not be written, specifically when 'buftype' is
+ "nowrite", "nofile", "terminal" or "prompt".
*'autowriteall'* *'awa'* *'noautowriteall'* *'noawa'*
'autowriteall' 'awa' boolean (default off)
@@ -728,13 +728,6 @@ A jump table for the options with a short description can be found at |Q_op|.
< Vim will guess the value. In the GUI this should work correctly,
in other cases Vim might not be able to guess the right value.
- When the |t_RB| option is set, Vim will use it to request the background
- color from the terminal. If the returned RGB value is dark/light and
- 'background' is not dark/light, 'background' will be set and the
- screen is redrawn. This may have side effects, make t_BG empty in
- your .vimrc if you suspect this problem. The response to |t_RB| can
- be found in |v:termrbgresp|.
-
When starting the GUI, the default value for 'background' will be
"light". When the value is not set in the gvimrc, and Vim detects
that the background is actually quite dark, 'background' is set to
@@ -916,8 +909,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'backupskip'* *'bsk'*
'backupskip' 'bsk' string (default: "/tmp/*,$TMPDIR/*,$TMP/*,$TEMP/*")
global
- {not available when compiled without the |+wildignore|
- feature}
A list of file patterns. When one of the patterns matches with the
name of the file which is written, no backup file is created. Both
the specified file name and the full path name of the file are used.
@@ -1021,8 +1012,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'bomb'* *'nobomb'*
'bomb' boolean (default off)
local to buffer
- {only available when compiled with the |+multi_byte|
- feature}
When writing a file and the following conditions are met, a BOM (Byte
Order Mark) is prepended to the file:
- this option is on
@@ -1042,16 +1031,12 @@ A jump table for the options with a short description can be found at |Q_op|.
*'breakat'* *'brk'*
'breakat' 'brk' string (default " ^I!@*-+;:,./?")
global
- {not available when compiled without the |+linebreak|
- feature}
This option lets you choose which characters might cause a line
break if 'linebreak' is on. Only works for ASCII characters.
*'breakindent'* *'bri'*
'breakindent' 'bri' boolean (default off)
local to window
- {not available when compiled without the |+linebreak|
- feature}
Every wrapped line will continue visually indented (same amount of
space as the beginning of that line), thus preserving horizontal blocks
of text.
@@ -1059,8 +1044,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'breakindentopt'* *'briopt'*
'breakindentopt' 'briopt' string (default empty)
local to window
- {not available when compiled without the |+linebreak|
- feature}
Settings for 'breakindent'. It can consist of the following optional
items and must be separated by a comma:
min:{n} Minimum text width that will be kept after
@@ -1073,14 +1056,13 @@ A jump table for the options with a short description can be found at |Q_op|.
characters. It permits dynamic French paragraph
indentation (negative) or emphasizing the line
continuation (positive).
- sbr Display the 'showbreak' value before applying the
+ sbr Display the 'showbreak' value before applying the
additional indent.
The default value for min is 20 and shift is 0.
*'browsedir'* *'bsdir'*
'browsedir' 'bsdir' string (default: "last")
global
- {only for Mac and Win32 GUI}
Which directory to use for the file browser:
last Use same directory as with last file browser, where a
file was opened or saved.
@@ -1091,8 +1073,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'bufhidden'* *'bh'*
'bufhidden' 'bh' string (default: "")
local to buffer
- {not available when compiled without the |+quickfix|
- feature}
This option specifies what happens when a buffer is no longer
displayed in a window:
<empty> follow the global 'hidden' option
@@ -1168,8 +1148,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'casemap'* *'cmp'*
'casemap' 'cmp' string (default: "internal,keepascii")
global
- {only available when compiled with the |+multi_byte|
- feature}
Specifies details about changing the case of letters. It may contain
these words, separated by a comma:
internal Use internal case mapping functions, the current
@@ -1183,8 +1161,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'cdpath'* *'cd'* *E344* *E346*
'cdpath' 'cd' string (default: equivalent to $CDPATH or ",,")
global
- {not available when compiled without the
- |+file_in_path| feature}
This is a list of directories which will be searched when using the
|:cd| and |:lcd| commands, provided that the directory being searched
for has a relative path, not an absolute part starting with "/", "./"
@@ -1216,14 +1192,13 @@ A jump table for the options with a short description can be found at |Q_op|.
*'channel'*
'channel' number (default: 0)
local to buffer
- |Channel| connected to the buffer. Currently only used by
- |terminal-emulator|. Is 0 if no terminal is open. Cannot be changed.
+ |channel| connected to the buffer, or 0 if no channel is connected.
+ In a |:terminal| buffer this is the terminal channel.
+ Read-only.
*'charconvert'* *'ccv'* *E202* *E214* *E513*
'charconvert' 'ccv' string (default "")
global
- {only available when compiled with the |+multi_byte|
- and |+eval| features}
An expression that is used for character encoding conversion. It is
evaluated when a file that is to be read or has been written has a
different encoding from what is desired.
@@ -1341,8 +1316,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'colorcolumn'* *'cc'*
'colorcolumn' 'cc' string (default "")
local to window
- {not available when compiled without the |+syntax|
- feature}
'colorcolumn' is a comma separated list of screen columns that are
highlighted with ColorColumn |hl-ColorColumn|. Useful to align
text. Will make screen redrawing slower.
@@ -1383,8 +1356,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'commentstring'* *'cms'* *E537*
'commentstring' 'cms' string (default "/*%s*/")
local to buffer
- {not available when compiled without the |+folding|
- feature}
A template for a comment. The "%s" in the value is replaced with the
comment text. Currently only used to add markers for folding, see
|fold-marker|.
@@ -1427,8 +1398,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'completefunc'* *'cfu'*
'completefunc' 'cfu' string (default: empty)
local to buffer
- {not available when compiled without the |+eval|
- or |+insert_expand| features}
This option specifies a function to be used for Insert mode completion
with CTRL-X CTRL-U. |i_CTRL-X_CTRL-U|
See |complete-functions| for an explanation of how the function is
@@ -1439,8 +1408,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'completeopt'* *'cot'*
'completeopt' 'cot' string (default: "menu,preview")
global
- {not available when compiled without the
- |+insert_expand| feature}
A comma separated list of options for Insert mode completion
|ins-completion|. The supported values are:
@@ -1491,8 +1458,8 @@ A jump table for the options with a short description can be found at |Q_op|.
displayed. E.g., when moving vertically it may change column.
-'conceallevel' 'cole' *'conceallevel'* *'cole'*
- number (default 0)
+ *'conceallevel'* *'cole'*
+'conceallevel' 'cole' number (default 0)
local to window
Determine how text with the "conceal" syntax attribute |:syn-conceal|
is shown:
@@ -1518,7 +1485,7 @@ A jump table for the options with a short description can be found at |Q_op|.
global
When 'confirm' is on, certain operations that would normally
fail because of unsaved changes to a buffer, e.g. ":q" and ":e",
- instead raise a |dialog| asking if you wish to save the current
+ instead raise a dialog asking if you wish to save the current
file(s). You can still use a ! to unconditionally |abandon| a buffer.
If 'confirm' is off you can still activate confirmation for one
command only (this is most useful in mappings) with the |:confirm|
@@ -1569,10 +1536,10 @@ A jump table for the options with a short description can be found at |Q_op|.
See also |map_bar|.
*cpo-B*
B A backslash has no special meaning in mappings,
- abbreviations and the "to" part of the menu commands.
- Remove this flag to be able to use a backslash like a
- CTRL-V. For example, the command ":map X \<Esc>"
- results in X being mapped to:
+ abbreviations, user commands and the "to" part of the
+ menu commands. Remove this flag to be able to use a
+ backslash like a CTRL-V. For example, the command
+ ":map X \<Esc>" results in X being mapped to:
'B' included: "\^[" (^[ is a real <Esc>)
'B' excluded: "<Esc>" (5 characters)
*cpo-c*
@@ -1603,7 +1570,7 @@ A jump table for the options with a short description can be found at |Q_op|.
*cpo-E*
E It is an error when using "y", "d", "c", "g~", "gu" or
"gU" on an Empty region. The operators only work when
- at least one character is to be operate on. Example:
+ at least one character is to be operated on. Example:
This makes "y0" fail in the first column.
*cpo-f*
f When included, a ":read" command with a file name
@@ -1822,8 +1789,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'cursorcolumn'* *'cuc'* *'nocursorcolumn'* *'nocuc'*
'cursorcolumn' 'cuc' boolean (default off)
local to window
- {not available when compiled without the |+syntax|
- feature}
Highlight the screen column of the cursor with CursorColumn
|hl-CursorColumn|. Useful to align text. Will make screen redrawing
slower.
@@ -1836,8 +1801,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'cursorline'* *'cul'* *'nocursorline'* *'nocul'*
'cursorline' 'cul' boolean (default off)
local to window
- {not available when compiled without the |+syntax|
- feature}
Highlight the screen line of the cursor with CursorLine
|hl-CursorLine|. Useful to easily spot the cursor. Will make screen
redrawing slower.
@@ -1877,8 +1840,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'delcombine'* *'deco'* *'nodelcombine'* *'nodeco'*
'delcombine' 'deco' boolean (default off)
global
- {only available when compiled with the |+multi_byte|
- feature}
If editing Unicode and this option is set, backspace and Normal mode
"x" delete each combining character on its own. When it is off (the
default) the character along with its combining characters are
@@ -1943,6 +1904,15 @@ A jump table for the options with a short description can be found at |Q_op|.
When omitted a context of six lines is used.
See |fold-diff|.
+ iblank Ignore changes where lines are all blank. Adds
+ the "-B" flag to the "diff" command if
+ 'diffexpr' is empty. Check the documentation
+ of the "diff" command for what this does
+ exactly.
+ NOTE: the diff windows will get out of sync,
+ because no differences between blank lines are
+ taken into account.
+
icase Ignore changes in case of text. "a" and "A"
are considered the same. Adds the "-i" flag
to the "diff" command if 'diffexpr' is empty.
@@ -1954,12 +1924,27 @@ A jump table for the options with a short description can be found at |Q_op|.
exactly. It should ignore adding trailing
white space, but not leading white space.
+ iwhiteall Ignore all white space changes. Adds
+ the "-w" flag to the "diff" command if
+ 'diffexpr' is empty. Check the documentation
+ of the "diff" command for what this does
+ exactly.
+
+ iwhiteeol Ignore white space changes at end of line.
+ Adds the "-Z" flag to the "diff" command if
+ 'diffexpr' is empty. Check the documentation
+ of the "diff" command for what this does
+ exactly.
+
horizontal Start diff mode with horizontal splits (unless
explicitly specified otherwise).
vertical Start diff mode with vertical splits (unless
explicitly specified otherwise).
+ hiddenoff Do not use diff mode for a buffer when it
+ becomes hidden.
+
foldcolumn:{n} Set the 'foldcolumn' option to {n} when
starting diff mode. Without this 2 is used.
@@ -1972,8 +1957,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'digraph'* *'dg'* *'nodigraph'* *'nodg'*
'digraph' 'dg' boolean (default off)
global
- {not available when compiled without the |+digraphs|
- feature}
Enable the entering of digraphs in Insert mode with {char1} <BS>
{char2}. See |digraphs|.
@@ -2038,8 +2021,8 @@ A jump table for the options with a short description can be found at |Q_op|.
instead of using ^C and ~C.
msgsep When showing messages longer than 'cmdheight', only
scroll the message lines, not the entire screen. The
- separator line is decorated by |MsgSeparator| and the
- "msgsep" flag of 'fillchars'.
+ separator line is decorated by |hl-MsgSeparator| and
+ the "msgsep" flag of 'fillchars'.
When neither "lastline" nor "truncate" is included, a last line that
doesn't fit is replaced with "@" lines.
@@ -2055,9 +2038,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'emoji'* *'emo'*
'emoji' 'emo' boolean (default: on)
global
- {not in Vi}
- {only available when compiled with the |+multi_byte|
- feature}
When on all Unicode emoji characters are considered to be full width.
@@ -2125,8 +2105,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'errorfile'* *'ef'*
'errorfile' 'ef' string (default: "errors.err")
global
- {not available when compiled without the |+quickfix|
- feature}
Name of the errorfile for the QuickFix mode (see |:cf|).
When the "-q" command-line argument is used, 'errorfile' is set to the
following argument. See |-q|.
@@ -2139,8 +2117,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'errorformat'* *'efm'*
'errorformat' 'efm' string (default is very long)
global or local to buffer |global-local|
- {not available when compiled without the |+quickfix|
- feature}
Scanf-like description of the format for the lines in the error file
(see |errorformat|).
@@ -2223,8 +2199,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'fileencodings'* *'fencs'*
'fileencodings' 'fencs' string (default: "ucs-bom,utf-8,default,latin1")
global
- {only available when compiled with the |+multi_byte|
- feature}
This is a list of character encodings considered when starting to edit
an existing file. When a file is read, Vim tries to use the first
mentioned character encoding. If an error is detected, the next one
@@ -2381,8 +2355,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'fillchars'* *'fcs'*
'fillchars' 'fcs' string (default "")
global
- {not available when compiled without the |+windows|
- and |+folding| features}
Characters to fill the statuslines and vertical separators.
It is a comma separated list of items:
@@ -2421,7 +2393,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'fixendofline'* *'fixeol'* *'nofixendofline'* *'nofixeol'*
'fixendofline' 'fixeol' boolean (default on)
local to buffer
- {not in Vi}
When writing a file and this option is on, <EOL> at the end of file
will be restored if missing. Turn this option off if you want to
preserve the situation from the original file.
@@ -2439,8 +2410,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'foldclose'* *'fcl'*
'foldclose' 'fcl' string (default "")
global
- {not available when compiled without the |+folding|
- feature}
When set to "all", a fold is closed when the cursor isn't in it and
its level is higher than 'foldlevel'. Useful if you want folds to
automatically close when moving out of them.
@@ -2448,8 +2417,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'foldcolumn'* *'fdc'*
'foldcolumn' 'fdc' number (default 0)
local to window
- {not available when compiled without the |+folding|
- feature}
When non-zero, a column with the specified width is shown at the side
of the window which indicates open and closed folds. The maximum
value is 12.
@@ -2458,8 +2425,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'foldenable'* *'fen'* *'nofoldenable'* *'nofen'*
'foldenable' 'fen' boolean (default on)
local to window
- {not available when compiled without the |+folding|
- feature}
When off, all folds are open. This option can be used to quickly
switch between showing all text unfolded and viewing the text with
folds (including manually opened or closed folds). It can be toggled
@@ -2471,8 +2436,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'foldexpr'* *'fde'*
'foldexpr' 'fde' string (default: "0")
local to window
- {not available when compiled without the |+folding|
- or |+eval| features}
The expression used for when 'foldmethod' is "expr". It is evaluated
for each line to obtain its fold level. See |fold-expr|.
@@ -2487,8 +2450,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'foldignore'* *'fdi'*
'foldignore' 'fdi' string (default: "#")
local to window
- {not available when compiled without the |+folding|
- feature}
Used only when 'foldmethod' is "indent". Lines starting with
characters in 'foldignore' will get their fold level from surrounding
lines. White space is skipped before checking for this character.
@@ -2497,8 +2458,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'foldlevel'* *'fdl'*
'foldlevel' 'fdl' number (default: 0)
local to window
- {not available when compiled without the |+folding|
- feature}
Sets the fold level: Folds with a higher level will be closed.
Setting this option to zero will close all folds. Higher numbers will
close fewer folds.
@@ -2508,8 +2467,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'foldlevelstart'* *'fdls'*
'foldlevelstart' 'fdls' number (default: -1)
global
- {not available when compiled without the |+folding|
- feature}
Sets 'foldlevel' when starting to edit another buffer in a window.
Useful to always start editing with all folds closed (value zero),
some folds closed (one) or no folds closed (99).
@@ -2523,8 +2480,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'foldmarker'* *'fmr'* *E536*
'foldmarker' 'fmr' string (default: "{{{,}}}")
local to window
- {not available when compiled without the |+folding|
- feature}
The start and end marker used when 'foldmethod' is "marker". There
must be one comma, which separates the start and end marker. The
marker is a literal string (a regular expression would be too slow).
@@ -2533,8 +2488,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'foldmethod'* *'fdm'*
'foldmethod' 'fdm' string (default: "manual")
local to window
- {not available when compiled without the |+folding|
- feature}
The kind of folding used for the current window. Possible values:
|fold-manual| manual Folds are created manually.
|fold-indent| indent Lines with equal indent form a fold.
@@ -2546,8 +2499,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'foldminlines'* *'fml'*
'foldminlines' 'fml' number (default: 1)
local to window
- {not available when compiled without the |+folding|
- feature}
Sets the number of screen lines above which a fold can be displayed
closed. Also for manually closed folds. With the default value of
one a fold can only be closed if it takes up two or more screen lines.
@@ -2559,8 +2510,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'foldnestmax'* *'fdn'*
'foldnestmax' 'fdn' number (default: 20)
local to window
- {not available when compiled without the |+folding|
- feature}
Sets the maximum nesting of folds for the "indent" and "syntax"
methods. This avoids that too many folds will be created. Using more
than 20 doesn't work, because the internal limit is 20.
@@ -2569,8 +2518,6 @@ A jump table for the options with a short description can be found at |Q_op|.
'foldopen' 'fdo' string (default: "block,hor,mark,percent,quickfix,
search,tag,undo")
global
- {not available when compiled without the |+folding|
- feature}
Specifies for which type of commands folds will be opened, if the
command moves the cursor into a closed fold. It is a comma separated
list of items.
@@ -2605,8 +2552,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'foldtext'* *'fdt'*
'foldtext' 'fdt' string (default: "foldtext()")
local to window
- {not available when compiled without the |+folding|
- feature}
An expression which is used to specify the text displayed for a closed
fold. See |fold-foldtext|.
@@ -2619,8 +2564,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'formatexpr'* *'fex'*
'formatexpr' 'fex' string (default "")
local to buffer
- {not available when compiled without the |+eval|
- feature}
Expression which is evaluated to format a range of lines for the |gq|
operator or automatic formatting (see 'formatoptions'). When this
option is empty 'formatprg' is used.
@@ -2792,17 +2735,27 @@ A jump table for the options with a short description can be found at |Q_op|.
of the numbers is zero, there is no blinking. E.g.: >
:set guicursor=n:blinkon0
< {group-name}
- a highlight group name, that sets the color and font
- for the cursor
+ Highlight group name that sets the color and font for
+ the cursor. |inverse|/reverse and no group-name are
+ interpreted as "the host terminal default cursor
+ colors" which usually invert bg and fg colors.
{group-name}/{group-name}
Two highlight group names, the first is used when
no language mappings are used, the other when they
are. |language-mapping|
Examples of parts:
- n-c-v:block-nCursor in Normal, Command-line and Visual mode, use a
+ n-c-v:block-nCursor In Normal, Command-line and Visual mode, use a
block cursor with colors from the "nCursor"
highlight group
+ n-v-c-sm:block,i-ci-ve:ver25-Cursor,r-cr-o:hor20
+ In Normal et al. modes, use a block cursor
+ with the default colors defined by the host
+ terminal. In Insert-likes modes, use
+ a vertical bar cursor with colors from
+ "Cursor" highlight group. In Replace-likes
+ modes, use a underline cursor with
+ default colors.
i-ci:ver30-iCursor-blinkwait300-blinkon200-blinkoff150
In Insert and Command-line Insert mode, use a
30% vertical bar cursor with colors from the
@@ -2822,7 +2775,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*E235* *E596*
'guifont' 'gfn' string (default "")
global
- {only available when compiled with GUI enabled}
This is a list of fonts which will be used for the GUI version of Vim.
In its simplest form the value is just one font name. When
the font cannot be found you will get an error message. To try other
@@ -2851,8 +2803,7 @@ A jump table for the options with a short description can be found at |Q_op|.
:set guifont=*
< will bring up a font requester, where you can pick the font you want.
- The font name depends on the GUI used. See |setting-guifont| for a
- way to set 'guifont' for various systems.
+ The font name depends on the GUI used.
For Mac OSX you can use something like this: >
:set guifont=Monaco:h10
@@ -2889,8 +2840,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*E250* *E252* *E234* *E597* *E598*
'guifontset' 'gfs' string (default "")
global
- {only available when compiled with GUI enabled and
- with the |+xfontset| feature}
When not empty, specifies two (or more) fonts to be used. The first
one for normal English, the second one for your special language. See
|xfontset|.
@@ -2911,7 +2860,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'guifontwide'* *'gfw'* *E231* *E533* *E534*
'guifontwide' 'gfw' string (default "")
global
- {only available when compiled with GUI enabled}
When not empty, specifies a comma-separated list of fonts to be used
for double-width characters. The first font that can be loaded is
used.
@@ -2930,7 +2878,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'guioptions'* *'go'*
'guioptions' 'go' string (default "egmrLT" (MS-Windows))
global
- {only available when compiled with GUI enabled}
This option only has an effect in the GUI version of Vim. It is a
sequence of letters which describes what components and options of the
GUI should be used.
@@ -3026,8 +2973,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'guitablabel'* *'gtl'*
'guitablabel' 'gtl' string (default empty)
global
- {only available when compiled with GUI enabled and
- with the |+windows| feature}
When nonempty describes the text to use in a label of the GUI tab
pages line. When empty and when the result is empty Vim will use a
default label. See |setting-guitablabel| for more info.
@@ -3044,8 +2989,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'guitabtooltip'* *'gtt'*
'guitabtooltip' 'gtt' string (default empty)
global
- {only available when compiled with GUI enabled and
- with the |+windows| feature}
When nonempty describes the text to use in a tooltip for the GUI tab
pages line. When empty Vim will use a default tooltip.
This option is otherwise just like 'guitablabel' above.
@@ -3070,8 +3013,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'helpheight'* *'hh'*
'helpheight' 'hh' number (default 20)
global
- {not available when compiled without the |+windows|
- feature}
Minimal initial height of the help window when it is opened with the
":help" command. The initial height of the help window is half of the
current window, or (when the 'ea' option is on) the same as other
@@ -3081,8 +3022,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'helplang'* *'hlg'*
'helplang' 'hlg' string (default: messages language or empty)
global
- {only available when compiled with the |+multi_lang|
- feature}
Comma separated list of languages. Vim will use the first language
for which the desired help can be found. The English help will always
be used as a last resort. You can add "en" to prefer English over
@@ -3136,8 +3075,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'hlsearch'* *'hls'* *'nohlsearch'* *'nohls'*
'hlsearch' 'hls' boolean (default on)
global
- {not available when compiled without the
- |+extra_search| feature}
When there is a previous search pattern, highlight all its matches.
The |hl-Search| highlight group determines the highlighting. Note that
only the matching text is highlighted, any offsets are not applied.
@@ -3157,8 +3094,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'icon'* *'noicon'*
'icon' boolean (default off, on when title can be restored)
global
- {not available when compiled without the |+title|
- feature}
When on, the icon text of the window will be set to the value of
'iconstring' (if it is not empty), or to the name of the file
currently being edited. Only the last part of the name is used.
@@ -3168,15 +3103,12 @@ A jump table for the options with a short description can be found at |Q_op|.
*'iconstring'*
'iconstring' string (default "")
global
- {not available when compiled without the |+title|
- feature}
When this option is not empty, it will be used for the icon text of
the window. This happens only when the 'icon' option is on.
Only works if the terminal supports setting window icon text
When this option contains printf-style '%' items, they will be
expanded according to the rules used for 'statusline'. See
'titlestring' for example settings.
- {not available when compiled without the |+statusline| feature}
*'ignorecase'* *'ic'* *'noignorecase'* *'noic'*
'ignorecase' 'ic' boolean (default off)
@@ -3190,8 +3122,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'imcmdline'* *'imc'* *'noimcmdline'* *'noimc'*
'imcmdline' 'imc' boolean (default off)
global
- {only available when compiled with the |+xim|,
- |+multi_byte_ime| or |global-ime| features}
When set the Input Method is always on when starting to edit a command
line, unless entering a search pattern (see 'imsearch' for that).
Setting this option is useful when your input method allows entering
@@ -3201,8 +3131,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'imdisable'* *'imd'* *'noimdisable'* *'noimd'*
'imdisable' 'imd' boolean (default off, on for some systems (SGI))
global
- {only available when compiled with the |+xim|,
- |+multi_byte_ime| or |global-ime| features}
When set the Input Method is never used. This is useful to disable
the IM when it doesn't work properly.
Currently this option is on by default for SGI/IRIX machines. This
@@ -3258,8 +3186,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'include'* *'inc'*
'include' 'inc' string (default "^\s*#\s*include")
global or local to buffer |global-local|
- {not available when compiled without the
- |+find_in_path| feature}
Pattern to be used to find an include command. It is a search
pattern, just like for the "/" command (See |pattern|). The default
value is for C programs. This option is used for the commands "[i",
@@ -3275,8 +3201,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'includeexpr'* *'inex'*
'includeexpr' 'inex' string (default "")
local to buffer
- {not available when compiled without the
- |+find_in_path| or |+eval| features}
Expression to be used to transform the string found with the 'include'
option to a file name. Mostly useful to change "." to "/" for Java: >
:set includeexpr=substitute(v:fname,'\\.','/','g')
@@ -3299,7 +3223,7 @@ A jump table for the options with a short description can be found at |Q_op|.
so far, matches. The matched string is highlighted. If the pattern
is invalid or not found, nothing is shown. The screen will be updated
often, this is only useful on fast terminals.
- Note that the match will be shown, but the cursor will return to its
+< Note that the match will be shown, but the cursor will return to its
original position when no match is found and when pressing <Esc>. You
still need to finish the search command with <Enter> to move the
cursor to the match.
@@ -3309,11 +3233,11 @@ A jump table for the options with a short description can be found at |Q_op|.
pattern and/or a lot of text the match may not be found. This is to
avoid that Vim hangs while you are typing the pattern.
The |hl-IncSearch| highlight group determines the highlighting.
- When 'hlsearch' is on, all matched strings are highlighted too while typing
- a search command. See also: 'hlsearch'.
- If you don't want turn 'hlsearch' on, but want to highlight all matches
- while searching, you can turn on and off 'hlsearch' with autocmd.
- Example: >
+ When 'hlsearch' is on, all matched strings are highlighted too while
+ typing a search command. See also: 'hlsearch'.
+ If you don't want to turn 'hlsearch' on, but want to highlight all
+ matches while searching, you can turn on and off 'hlsearch' with
+ autocmd. Example: >
augroup vimrc-incsearch-highlight
autocmd!
autocmd CmdlineEnter /,\? :set hlsearch
@@ -3466,7 +3390,7 @@ A jump table for the options with a short description can be found at |Q_op|.
Identifiers are used in recognizing environment variables and after a
match of the 'define' option. It is also used for "\i" in a
|pattern|. See 'isfname' for a description of the format of this
- option.
+ option. For '@' only characters up to 255 are used.
Careful: If you change this option, it might break expanding
environment variables. E.g., when '/' is included and Vim tries to
expand "$HOME/.local/share/nvim/shada/main.shada". Maybe you should
@@ -3478,8 +3402,9 @@ A jump table for the options with a short description can be found at |Q_op|.
local to buffer
Keywords are used in searching and recognizing with many commands:
"w", "*", "[i", etc. It is also used for "\k" in a |pattern|. See
- 'isfname' for a description of the format of this option. For C
- programs you could use "a-z,A-Z,48-57,_,.,-,>".
+ 'isfname' for a description of the format of this option. For '@'
+ characters above 255 check the "word" character class.
+ For C programs you could use "a-z,A-Z,48-57,_,.,-,>".
For a help file it is set to all non-blank printable characters except
'*', '"' and '|' (so that CTRL-] on a command finds the help for that
command).
@@ -3526,8 +3451,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'keymap'* *'kmp'* *E544*
'keymap' 'kmp' string (default "")
local to buffer
- {only available when compiled with the |+keymap|
- feature}
Name of a keyboard mapping. See |mbyte-keymap|.
Setting this option to a valid keymap name has the side effect of
setting 'iminsert' to one, so that the keymap becomes effective.
@@ -3568,8 +3491,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'langmap'* *'lmap'* *E357* *E358*
'langmap' 'lmap' string (default "")
global
- {only available when compiled with the |+langmap|
- feature}
This option allows switching your keyboard into a special language
mode. When you are typing text in Insert mode the characters are
inserted directly. When in Normal mode the 'langmap' option takes
@@ -3613,8 +3534,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'langmenu'* *'lm'*
'langmenu' 'lm' string (default "")
global
- {only available when compiled with the |+menu| and
- |+multi_lang| features}
Language to use for menu translation. Tells which file is loaded
from the "lang" directory in 'runtimepath': >
"lang/menu_" . &langmenu . ".vim"
@@ -3663,8 +3582,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'linebreak'* *'lbr'* *'nolinebreak'* *'nolbr'*
'linebreak' 'lbr' boolean (default off)
local to window
- {not available when compiled without the |+linebreak|
- feature}
If on, Vim will wrap long lines at a character in 'breakat' rather
than at the last character that fits on the screen. Unlike
'wrapmargin' and 'textwidth', this does not insert <EOL>s in the file,
@@ -3704,8 +3621,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'lisp'* *'nolisp'*
'lisp' boolean (default off)
local to buffer
- {not available when compiled without the |+lispindent|
- feature}
Lisp mode: When <Enter> is typed in insert mode set the indent for
the next line to Lisp standards (well, sort of). Also happens with
"cc" or "S". 'autoindent' must also be on for this to work. The 'p'
@@ -3719,8 +3634,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'lispwords'* *'lw'*
'lispwords' 'lw' string (default is very long)
global or local to buffer |global-local|
- {not available when compiled without the |+lispindent|
- feature}
Comma separated list of words that influence the Lisp indenting.
|'lisp'|
@@ -3813,8 +3726,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'makeef'* *'mef'*
'makeef' 'mef' string (default: "")
global
- {not available when compiled without the |+quickfix|
- feature}
Name of the errorfile for the |:make| command (see |:make_makeprg|)
and the |:grep| command.
When it is empty, an internally generated temp file will be used.
@@ -3830,9 +3741,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'makeencoding'* *'menc'*
'makeencoding' 'menc' string (default "")
global or local to buffer |global-local|
- {only available when compiled with the |+multi_byte|
- feature}
- {not in Vi}
Encoding used for reading the output of external commands. When empty,
encoding is not converted.
This is used for `:make`, `:lmake`, `:grep`, `:lgrep`, `:grepadd`,
@@ -3898,14 +3806,12 @@ A jump table for the options with a short description can be found at |Q_op|.
*'maxfuncdepth'* *'mfd'*
'maxfuncdepth' 'mfd' number (default 100)
global
- {not available when compiled without the |+eval|
- feature}
Maximum depth of function calls for user functions. This normally
catches endless recursion. When using a recursive function with
more depth, set 'maxfuncdepth' to a bigger number. But this will use
more memory, there is the danger of failing when memory is exhausted.
Increasing this limit above 200 also changes the maximum for Ex
- command resursion, see |E169|.
+ command recursion, see |E169|.
See also |:function|.
*'maxmapdepth'* *'mmd'* *E223*
@@ -3928,13 +3834,14 @@ A jump table for the options with a short description can be found at |Q_op|.
Running into the limit often means that the pattern is very
inefficient or too complex. This may already happen with the pattern
"\(.\)*" on a very long line. ".*" works much better.
- Vim may run out of memory before hitting the 'maxmempattern' limit.
+ Might also happen on redraw, when syntax rules try to match a complex
+ text structure.
+ Vim may run out of memory before hitting the 'maxmempattern' limit, in
+ which case you get an "Out of memory" error instead.
*'menuitems'* *'mis'*
'menuitems' 'mis' number (default 25)
global
- {not available when compiled without the |+menu|
- feature}
Maximum number of items to use in a menu. Used for menus that are
generated from a list of items, e.g., the Buffers menu. Changing this
option has no direct effect, the menu must be refreshed first.
@@ -3942,8 +3849,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'mkspellmem'* *'msm'*
'mkspellmem' 'msm' string (default "460000,2000,500")
global
- {not available when compiled without the |+syntax|
- feature}
Parameters for |:mkspell|. This tunes when to start compressing the
word tree. Compression can be slow when there are many words, but
it's needed to avoid running out of memory. The amount of memory used
@@ -4017,6 +3922,8 @@ A jump table for the options with a short description can be found at |Q_op|.
an explanation.
When 'buftype' is "nowrite" or "nofile" this option may be set, but
will be ignored.
+ Note that the text may actually be the same, e.g. 'modified' is set
+ when using "rA" on an "A".
*'more'* *'nomore'*
'more' boolean (Vim default: on, Vi default: off)
@@ -4029,9 +3936,14 @@ A jump table for the options with a short description can be found at |Q_op|.
'mouse' string (default "")
global
- Enable the use of the mouse. Only works for certain terminals.
- For using the mouse in the GUI, see |gui-mouse|. The mouse can be
- enabled for different modes:
+ Enables mouse support. For example, to enable the mouse in Normal mode
+ and Visual mode: >
+ :set mouse=nv
+<
+ To temporarily disable mouse support, hold the shift key while using
+ the mouse.
+
+ Mouse support can be enabled for different modes:
n Normal mode
v Visual mode
i Insert mode
@@ -4039,17 +3951,42 @@ A jump table for the options with a short description can be found at |Q_op|.
h all previous modes when editing a help file
a all previous modes
r for |hit-enter| and |more-prompt| prompt
- Normally you would enable the mouse in all four modes with: >
- :set mouse=a
-< When the mouse is not enabled, the GUI will still use the mouse for
- modeless selection. This doesn't move the text cursor.
- See |mouse-using|. Also see |'clipboard'|.
+ Left-click anywhere in a text buffer to place the cursor there. This
+ works with operators too, e.g. type |d| then left-click to delete text
+ from the current cursor position to the position where you clicked.
+
+ Drag the |status-line| or vertical separator of a window to resize it.
+
+ If enabled for "v" (Visual mode) then double-click selects word-wise,
+ triple-click makes it line-wise, and quadruple-click makes it
+ rectangular block-wise.
+
+ For scrolling with a mouse wheel see |scroll-mouse-wheel|.
Note: When enabling the mouse in a terminal, copy/paste will use the
- "* register if there is access to an X-server. The xterm handling of
- the mouse buttons can still be used by keeping the shift key pressed.
- Also see the 'clipboard' option.
+ "* register if possible. See also 'clipboard'.
+
+ Related options:
+ 'mousefocus' window focus follows mouse pointer
+ 'mousemodel' what mouse button does which action
+ 'mousehide' hide mouse pointer while typing text
+ 'selectmode' whether to start Select mode or Visual mode
+
+ The :behave command provides some "profiles" for mouse behavior.
+ *:behave* *:be*
+ :be[have] {model} Set behavior for mouse and selection. Valid
+ arguments are:
+ mswin MS-Windows behavior
+ xterm Xterm behavior
+
+ Using ":behave" changes these options:
+ option mswin xterm ~
+ 'selectmode' "mouse,key" ""
+ 'mousemodel' "popup" "extend"
+ 'keymodel' "startsel,stopsel" ""
+ 'selection' "exclusive" "inclusive"
+
*'mousefocus'* *'mousef'* *'nomousefocus'* *'nomousef'*
'mousefocus' 'mousef' boolean (default off)
@@ -4069,7 +4006,7 @@ A jump table for the options with a short description can be found at |Q_op|.
The mouse pointer is restored when the mouse is moved.
*'mousemodel'* *'mousem'*
-'mousemodel' 'mousem' string (default "extend", "popup" for Windows)
+'mousemodel' 'mousem' string (default "extend")
global
Sets the model to use for the mouse. The name mostly specifies what
the right mouse button is used for:
@@ -4096,10 +4033,30 @@ A jump table for the options with a short description can be found at |Q_op|.
In the "popup" model the right mouse button produces a pop-up menu.
You need to define this first, see |popup-menu|.
+ In a terminal the popup menu works if Vim is compiled with the
+ |+insert_expand| option.
Note that you can further refine the meaning of buttons with mappings.
- See |gui-mouse-mapping|. But mappings are NOT used for modeless
- selection (because that's handled in the GUI code directly).
+ See |mouse-overview|. But mappings are NOT used for modeless selection.
+
+ Example: >
+ :map <S-LeftMouse> <RightMouse>
+ :map <S-LeftDrag> <RightDrag>
+ :map <S-LeftRelease> <RightRelease>
+ :map <2-S-LeftMouse> <2-RightMouse>
+ :map <2-S-LeftDrag> <2-RightDrag>
+ :map <2-S-LeftRelease> <2-RightRelease>
+ :map <3-S-LeftMouse> <3-RightMouse>
+ :map <3-S-LeftDrag> <3-RightDrag>
+ :map <3-S-LeftRelease> <3-RightRelease>
+ :map <4-S-LeftMouse> <4-RightMouse>
+ :map <4-S-LeftDrag> <4-RightDrag>
+ :map <4-S-LeftRelease> <4-RightRelease>
+<
+ Mouse commands requiring the CTRL modifier can be simulated by typing
+ the "g" key before using the mouse:
+ "g<LeftMouse>" is "<C-LeftMouse> (jump to tag under mouse click)
+ "g<RightMouse>" is "<C-RightMouse> ("CTRL-T")
The 'mousemodel' option is set by the |:behave| command.
@@ -4107,8 +4064,6 @@ A jump table for the options with a short description can be found at |Q_op|.
'mouseshape' 'mouses' string (default "i:beam,r:beam,s:updown,sd:cross,
m:no,ml:up-arrow,v:rightup-arrow")
global
- {only available when compiled with the |+mouseshape|
- feature}
This option tells Vim what the mouse pointer should look like in
different modes. The option is a comma separated list of parts, much
like used for 'guicursor'. Each part consist of a mode/location-list
@@ -4201,12 +4156,11 @@ A jump table for the options with a short description can be found at |Q_op|.
Print the line number in front of each line. When the 'n' option is
excluded from 'cpoptions' a wrapped line will not use the column of
line numbers.
- The 'numberwidth' option can be used to set the room used for the line
- number.
+ Use the 'numberwidth' option to adjust the room for the line number.
When a long, wrapped line doesn't start with the first character, '-'
characters are put before the number.
- See |hl-LineNr| and |hl-CursorLineNr| for the highlighting used for
- the number.
+ For highlighting see |hl-LineNr|, |hl-CursorLineNr|, and the
+ |:sign-define| "numhl" argument.
*number_relativenumber*
The 'relativenumber' option changes the displayed number to be
relative to the cursor. Together with 'number' there are these
@@ -4223,8 +4177,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'numberwidth'* *'nuw'*
'numberwidth' 'nuw' number (Vim default: 4 Vi default: 8)
local to window
- {only available when compiled with the |+linebreak|
- feature}
Minimal number of columns to use for the line number. Only relevant
when the 'number' or 'relativenumber' option is set or printing lines
with a line number. Since one space is always between the number and
@@ -4239,8 +4191,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'omnifunc'* *'ofu'*
'omnifunc' 'ofu' string (default: empty)
local to buffer
- {not available when compiled without the |+eval|
- or |+insert_expand| features}
This option specifies a function to be used for Insert mode omni
completion with CTRL-X CTRL-O. |i_CTRL-X_CTRL-O|
See |complete-functions| for an explanation of how the function is
@@ -4273,7 +4223,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'packpath'* *'pp'*
'packpath' 'pp' string (default: see 'runtimepath')
- {not in Vi}
Directories used to find packages. See |packages|.
@@ -4368,11 +4317,11 @@ A jump table for the options with a short description can be found at |Q_op|.
copy of the original file will be kept. The name of the copy is the
name of the original file with the string in the 'patchmode' option
appended. This option should start with a dot. Use a string like
- ".org". 'backupdir' must not be empty for this to work (Detail: The
- backup file is renamed to the patchmode file after the new file has
- been successfully written, that's why it must be possible to write a
- backup file). If there was no file to be backed up, an empty file is
- created.
+ ".orig" or ".org". 'backupdir' must not be empty for this to work
+ (Detail: The backup file is renamed to the patchmode file after the
+ new file has been successfully written, that's why it must be possible
+ to write a backup file). If there was no file to be backed up, an
+ empty file is created.
When the 'backupskip' pattern matches, a patchmode file is not made.
Using 'patchmode' for compressed files appends the extension at the
end (e.g., "file.gz.orig"), thus the resulting name isn't always
@@ -4408,7 +4357,6 @@ A jump table for the options with a short description can be found at |Q_op|.
"http://www.vim.org" will make ":find index.html" work.
- Search upwards and downwards in a directory tree using "*", "**" and
";". See |file-searching| for info and syntax.
- {not available when compiled without the |+path_extra| feature}
- Careful with '\' characters, type two to get one in the option: >
:set path=.,c:\\include
< Or just use '/' instead: >
@@ -4451,8 +4399,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'previewheight'* *'pvh'*
'previewheight' 'pvh' number (default 12)
global
- {not available when compiled without the |+windows| or
- |+quickfix| features}
Default height for a preview window. Used for |:ptag| and associated
commands. Used for |CTRL-W_}| when no count is given.
@@ -4460,8 +4406,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'pvw'* *'nopvw'* *E590*
'previewwindow' 'pvw' boolean (default off)
local to window
- {not available when compiled without the |+windows| or
- |+quickfix| features}
Identifies the preview window. Only one window can have this option
set. It's normally not set directly, but by using one of the commands
|:ptag|, |:pedit|, etc.
@@ -4469,26 +4413,20 @@ A jump table for the options with a short description can be found at |Q_op|.
*'printdevice'* *'pdev'*
'printdevice' 'pdev' string (default empty)
global
- {only available when compiled with the |+printer|
- feature}
The name of the printer to be used for |:hardcopy|.
See |pdev-option|.
This option cannot be set from a |modeline| or in the |sandbox|, for
security reasons.
*'printencoding'* *'penc'*
-'printencoding' 'penc' String (default empty, except for some systems)
+'printencoding' 'penc' string (default empty, except for some systems)
global
- {only available when compiled with the |+printer|
- and |+postscript| features}
Sets the character encoding used when printing.
See |penc-option|.
*'printexpr'* *'pexpr'*
-'printexpr' 'pexpr' String (default: see below)
+'printexpr' 'pexpr' string (default: see below)
global
- {only available when compiled with the |+printer|
- and |+postscript| features}
Expression used to print the PostScript produced with |:hardcopy|.
See |pexpr-option|.
This option cannot be set from a |modeline| or in the |sandbox|, for
@@ -4497,39 +4435,30 @@ A jump table for the options with a short description can be found at |Q_op|.
*'printfont'* *'pfn'*
'printfont' 'pfn' string (default "courier")
global
- {only available when compiled with the |+printer|
- feature}
The name of the font that will be used for |:hardcopy|.
See |pfn-option|.
*'printheader'* *'pheader'*
'printheader' 'pheader' string (default "%<%f%h%m%=Page %N")
global
- {only available when compiled with the |+printer|
- feature}
The format of the header produced in |:hardcopy| output.
See |pheader-option|.
*'printmbcharset'* *'pmbcs'*
'printmbcharset' 'pmbcs' string (default "")
global
- {only available when compiled with the |+printer|,
- |+postscript| and |+multi_byte| features}
The CJK character set to be used for CJK output from |:hardcopy|.
See |pmbcs-option|.
*'printmbfont'* *'pmbfn'*
'printmbfont' 'pmbfn' string (default "")
global
- {only available when compiled with the |+printer|,
- |+postscript| and |+multi_byte| features}
List of font names to be used for CJK output from |:hardcopy|.
See |pmbfn-option|.
*'printoptions'* *'popt'*
'printoptions' 'popt' string (default "")
global
- {only available when compiled with |+printer| feature}
List of items that control the format of the output of |:hardcopy|.
See |popt-option|.
@@ -4541,8 +4470,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'pumheight'* *'ph'*
'pumheight' 'ph' number (default 0)
global
- {not available when compiled without the
- |+insert_expand| feature}
Determines the maximum number of items to show in the popup menu for
Insert mode completion. When zero as much space as available is used.
|ins-completion-menu|.
@@ -4572,8 +4499,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'redrawtime'* *'rdt'*
'redrawtime' 'rdt' number (default 2000)
global
- {only available when compiled with the |+reltime|
- feature}
Time in milliseconds for redrawing the display. Applies to
'hlsearch', 'inccommand' and |:match| highlighting.
When redrawing takes more than this many milliseconds no further
@@ -4697,8 +4622,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'rulerformat'* *'ruf'*
'rulerformat' 'ruf' string (default empty)
global
- {not available when compiled without the |+statusline|
- feature}
When this option is not empty, it determines the content of the ruler
string, as displayed for the 'ruler' option.
The format of this option is like that of 'statusline'.
@@ -4787,6 +4710,8 @@ A jump table for the options with a short description can be found at |Q_op|.
to find files which replace a distributed runtime files. You can put
a directory after $VIMRUNTIME to find files which add to distributed
runtime files.
+ When Vim is started with |--clean| the home directory entries are not
+ included.
This option cannot be set from a |modeline| or in the |sandbox|, for
security reasons.
@@ -4812,8 +4737,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'scrollbind'* *'scb'* *'noscrollbind'* *'noscb'*
'scrollbind' 'scb' boolean (default off)
local to window
- {not available when compiled without the |+scrollbind|
- feature}
See also |scroll-binding|. When this option is set, the current
window scrolls as other scrollbind windows (windows that also have
this option set) scroll. This option is useful for viewing the
@@ -4847,8 +4770,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'scrollopt'* *'sbo'*
'scrollopt' 'sbo' string (default "ver,jump")
global
- {not available when compiled without the |+scrollbind|
- feature}
This is a comma-separated list of words that specifies how
'scrollbind' windows should behave. 'sbo' stands for ScrollBind
Options.
@@ -4965,6 +4886,8 @@ A jump table for the options with a short description can be found at |Q_op|.
tabpages all tab pages; without this only the current tab page
is restored, so that you can make a session for each
tab page separately
+ terminal include terminal windows where the command can be
+ restored
unix with Unix end-of-line format (single <NL>), even when
on Windows or DOS
winpos position of the whole Vim window
@@ -5346,8 +5269,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'showbreak'* *'sbr'* *E595*
'showbreak' 'sbr' string (default "")
global
- {not available when compiled without the |+linebreak|
- feature}
String to put at the start of lines that have been wrapped. Useful
values are "> " or "+++ ": >
:set showbreak=>\
@@ -5417,8 +5338,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'showtabline'* *'stal'*
'showtabline' 'stal' number (default 1)
global
- {not available when compiled without the |+windows|
- feature}
The value of this option specifies when the line with tab page labels
will be displayed:
0: never
@@ -5478,8 +5397,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'smartindent'* *'si'* *'nosmartindent'* *'nosi'*
'smartindent' 'si' boolean (default off)
local to buffer
- {not available when compiled without the
- |+smartindent| feature}
Do smart autoindenting when starting a new line. Works for C-like
programs, but can also be used for other languages. 'cindent' does
something like this, works better in most cases, but is more strict,
@@ -5539,16 +5456,12 @@ A jump table for the options with a short description can be found at |Q_op|.
*'spell'* *'nospell'*
'spell' boolean (default off)
local to window
- {not available when compiled without the |+syntax|
- feature}
When on spell checking will be done. See |spell|.
The languages are specified with 'spelllang'.
*'spellcapcheck'* *'spc'*
'spellcapcheck' 'spc' string (default "[.?!]\_[\])'" \t]\+")
local to buffer
- {not available when compiled without the |+syntax|
- feature}
Pattern to locate the end of a sentence. The following word will be
checked to start with a capital letter. If not then it is highlighted
with SpellCap |hl-SpellCap| (unless the word is also badly spelled).
@@ -5562,8 +5475,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'spellfile'* *'spf'*
'spellfile' 'spf' string (default empty)
local to buffer
- {not available when compiled without the |+syntax|
- feature}
Name of the word list file where words are added for the |zg| and |zw|
commands. It must end in ".{encoding}.add". You need to include the
path, otherwise the file is placed in the current directory.
@@ -5588,8 +5499,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'spelllang'* *'spl'*
'spelllang' 'spl' string (default "en")
local to buffer
- {not available when compiled without the |+syntax|
- feature}
A comma separated list of word list names. When the 'spell' option is
on spellchecking will be done for these languages. Example: >
set spelllang=en_us,nl,medical
@@ -5628,8 +5537,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'spellsuggest'* *'sps'*
'spellsuggest' 'sps' string (default "best")
global
- {not available when compiled without the |+syntax|
- feature}
Methods used for spelling suggestions. Both for the |z=| command and
the |spellsuggest()| function. This is a comma-separated list of
items:
@@ -5693,8 +5600,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'splitbelow'* *'sb'* *'nosplitbelow'* *'nosb'*
'splitbelow' 'sb' boolean (default off)
global
- {not available when compiled without the |+windows|
- feature}
When on, splitting a window will put the new window below the current
one. |:split|
@@ -5720,8 +5625,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'statusline'* *'stl'* *E540* *E542*
'statusline' 'stl' string (default empty)
global or local to window |global-local|
- {not available when compiled without the |+statusline|
- feature}
When nonempty, this option determines the content of the status line.
Also see |status-line|.
@@ -5868,7 +5771,7 @@ A jump table for the options with a short description can be found at |Q_op|.
line is displayed. The current buffer and current window will be set
temporarily to that of the window (and buffer) whose statusline is
currently being drawn. The expression will evaluate in this context.
- The variable "actual_curbuf" is set to the 'bufnr()' number of the
+ The variable "g:actual_curbuf" is set to the `bufnr()` number of the
real current buffer.
The 'statusline' option will be evaluated in the |sandbox| if set from
@@ -5926,8 +5829,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'suffixesadd'* *'sua'*
'suffixesadd' 'sua' string (default "")
local to buffer
- {not available when compiled without the
- |+file_in_path| feature}
Comma separated list of suffixes, which are used when searching for a
file for the "gf", "[I", etc. commands. Example: >
:set suffixesadd=.java
@@ -5949,6 +5850,7 @@ A jump table for the options with a short description can be found at |Q_op|.
Also see |swap-file|.
If you want to open a new buffer without creating a swap file for it,
use the |:noswapfile| modifier.
+ See 'directory' for where the swap file is created.
This option is used together with 'bufhidden' and 'buftype' to
specify special kinds of buffers. See |special-buffers|.
@@ -5977,8 +5879,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'synmaxcol'* *'smc'*
'synmaxcol' 'smc' number (default 3000)
local to buffer
- {not available when compiled without the |+syntax|
- feature}
Maximum column in which to search for syntax items. In long lines the
text after this column is not highlighted and following lines may not
be highlighted correctly, because the syntax state is cleared.
@@ -5989,8 +5889,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'syntax'* *'syn'*
'syntax' 'syn' string (default empty)
local to buffer
- {not available when compiled without the |+syntax|
- feature}
When this option is set, the syntax with this name is loaded, unless
syntax highlighting has been switched off with ":syntax off".
Otherwise this option does not always reflect the current syntax (the
@@ -6018,8 +5916,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'tabline'* *'tal'*
'tabline' 'tal' string (default empty)
global
- {not available when compiled without the |+windows|
- feature}
When nonempty, this option determines the content of the tab pages
line at the top of the Vim window. When empty Vim will use a default
tab pages line. See |setting-tabline| for more info.
@@ -6041,8 +5937,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'tabpagemax'* *'tpm'*
'tabpagemax' 'tpm' number (default 50)
global
- {not available when compiled without the |+windows|
- feature}
Maximum number of tab pages to be opened by the |-p| command line
argument or the ":tab all" command. |tabpage|
@@ -6128,7 +6022,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'tagcase'* *'tc'*
'tagcase' 'tc' string (default "followic")
global or local to buffer |global-local|
- {not in Vi}
This option specifies how case is handled when searching the tags
file:
followic Follow the 'ignorecase' option
@@ -6162,8 +6055,7 @@ A jump table for the options with a short description can be found at |Q_op|.
a directory tree. See |file-searching|. E.g., "/lib/**/tags" will
find all files named "tags" below "/lib". The filename itself cannot
contain wildcards, it is used as-is. E.g., "/lib/**/tags?" will find
- files called "tags?". {not available when compiled without the
- |+path_extra| feature}
+ files called "tags?".
The |tagfiles()| function can be used to get a list of the file names
actually used.
The use of |:set+=| and |:set-=| is preferred when adding or removing
@@ -6230,7 +6122,7 @@ A jump table for the options with a short description can be found at |Q_op|.
non-keyword characters (white space is preferred). Maximum line
length is 510 bytes.
To obtain a file to be used here, check out this ftp site:
- [Sorry this link doesn't work anymore, do you know the right one?]
+ [Sorry this link doesn't work anymore, do you know the right one?]
ftp://ftp.ox.ac.uk/pub/wordlists/ First get the README file.
To include a comma in a file name precede it with a backslash. Spaces
after a comma are ignored, otherwise spaces are included in the file
@@ -6328,7 +6220,6 @@ A jump table for the options with a short description can be found at |Q_op|.
separating space only when needed.
NOTE: Use of special characters in 'titlestring' may cause the display
to be garbled (e.g., when it contains a CR or NL character).
- {not available when compiled without the |+statusline| feature}
*'ttyfast'* *'tf'* *'nottyfast'* *'notf'*
'ttyfast' 'tf' Removed. |vim-differences| {Nvim}
@@ -6336,7 +6227,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'undodir'* *'udir'* *E5003*
'undodir' 'udir' string (default "$XDG_DATA_HOME/nvim/undo")
global
- {only when compiled with the |+persistent_undo| feature}
List of directory names for undo files, separated with commas.
See |'backupdir'| for details of the format.
"." means using the directory of the file. The undo file name for
@@ -6355,7 +6245,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'undofile'* *'noundofile'* *'udf'* *'noudf'*
'undofile' 'udf' boolean (default off)
local to buffer
- {only when compiled with the |+persistent_undo| feature}
When on, Vim automatically saves undo history to an undo file when
writing a buffer to a file, and restores undo history from the same
file on buffer read.
@@ -6459,8 +6348,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'viewdir'* *'vdir'*
'viewdir' 'vdir' string (default: "$XDG_DATA_HOME/nvim/view")
global
- {not available when compiled without the |+mksession|
- feature}
Name of the directory where to store files for |:mkview|.
This option cannot be set from a |modeline| or in the |sandbox|, for
security reasons.
@@ -6468,8 +6355,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'viewoptions'* *'vop'*
'viewoptions' 'vop' string (default: "folds,options,cursor,curdir")
global
- {not available when compiled without the |+mksession|
- feature}
Changes the effect of the |:mkview| command. It is a comma separated
list of words. Each word enables saving and restoring something:
word save and restore ~
@@ -6492,8 +6377,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'virtualedit'* *'ve'*
'virtualedit' 've' string (default "")
global
- {not available when compiled without the
- |+virtualedit| feature}
A comma separated list of these words:
block Allow virtual editing in Visual block mode.
insert Allow virtual editing in Insert mode.
@@ -6584,8 +6467,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'wildignore'* *'wig'*
'wildignore' 'wig' string (default "")
global
- {not available when compiled without the |+wildignore|
- feature}
A list of file patterns. A file that matches with one of these
patterns is ignored when expanding |wildcards|, completing file or
directory names, and influences the result of |expand()|, |glob()| and
@@ -6611,8 +6492,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'wildmenu'* *'wmnu'* *'nowildmenu'* *'nowmnu'*
'wildmenu' 'wmnu' boolean (default on)
global
- {not available if compiled without the |+wildmenu|
- feature}
When 'wildmenu' is on, command-line completion operates in an enhanced
mode. On pressing 'wildchar' (usually <Tab>) to invoke completion,
the possible matches are shown just above the command line, with the
@@ -6688,8 +6567,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'wildoptions'* *'wop'*
'wildoptions' 'wop' string (default "")
global
- {not available when compiled without the |+wildignore|
- feature}
A list of words that change how command line completion is done.
Currently only one word is allowed:
tagfile When using CTRL-D to list matching tags, the kind of
@@ -6708,8 +6585,7 @@ A jump table for the options with a short description can be found at |Q_op|.
menu. This conflicts with the use of the ALT key for mappings and
entering special characters. This option tells what to do:
no Don't use ALT keys for menus. ALT key combinations can be
- mapped, but there is no automatic handling. This can then be
- done with the |:simalt| command.
+ mapped, but there is no automatic handling.
yes ALT key handling is done by the windowing system. ALT key
combinations cannot be mapped.
menu Using ALT in combination with a character that is a menu
@@ -6735,8 +6611,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'winheight'* *'wh'* *E591*
'winheight' 'wh' number (default 1)
global
- {not available when compiled without the |+windows|
- feature}
Minimal number of lines for the current window. This is not a hard
minimum, Vim will use fewer lines if there is not enough room. If the
focus goes to a window that is smaller, its size is increased, at the
@@ -6764,8 +6638,8 @@ A jump table for the options with a short description can be found at |Q_op|.
syntax highlighting (use |:ownsyntax| for that).
Highlights of vertical separators are determined by the window to the
- left of the separator. The highlight of a tabpage in |tabline| is
- determined by the last-focused window of the tabpage. Highlights of
+ left of the separator. The 'tabline' highlight of a tabpage is
+ decided by the last-focused window of the tabpage. Highlights of
the popupmenu are determined by the current window. Highlights in the
message area cannot be overridden.
@@ -6775,8 +6649,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'winfixheight'* *'wfh'* *'nowinfixheight'* *'nowfh'*
'winfixheight' 'wfh' boolean (default off)
local to window
- {not available when compiled without the |+windows|
- feature}
Keep the window height when windows are opened or closed and
'equalalways' is set. Also for |CTRL-W_=|. Set by default for the
|preview-window| and |quickfix-window|.
@@ -6785,8 +6657,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'winfixwidth'* *'wfw'* *'nowinfixwidth'* *'nowfw'*
'winfixwidth' 'wfw' boolean (default off)
local to window
- {not available when compiled without the |+windows|
- feature}
Keep the window width when windows are opened or closed and
'equalalways' is set. Also for |CTRL-W_=|.
The width may be changed anyway when running out of room.
@@ -6794,8 +6664,6 @@ A jump table for the options with a short description can be found at |Q_op|.
*'winminheight'* *'wmh'*
'winminheight' 'wmh' number (default 1)
global
- {not available when compiled without the |+windows|
- feature}
The minimal height of a window, when it's not the current window.
This is a hard minimum, windows will never become smaller.
When set to zero, windows may be "squashed" to zero lines (i.e. just a
@@ -6906,4 +6774,4 @@ A jump table for the options with a short description can be found at |Q_op|.
When negative, all redrawn characters cause a delay, even if the
character already was displayed by the UI. For debugging purposes.
- vim:tw=78:ts=8:ft=help:noet:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/pattern.txt b/runtime/doc/pattern.txt
index cc485b655d..88b7f65209 100644
--- a/runtime/doc/pattern.txt
+++ b/runtime/doc/pattern.txt
@@ -282,6 +282,14 @@ the "#" is under your left hand middle finger (search to the left and up) and
the "*" is under your right hand middle finger (search to the right and down).
(this depends on your keyboard layout though).
+ *E956*
+In very rare cases a regular expression is used recursively. This can happen
+when executing a pattern takes a long time and when checkig for messages on
+channels a callback is invoked that also uses a pattern or an autocommand is
+triggered. In most cases this should be fine, but if a pattern is in use when
+it's used again it fails. Usually this means there is something wrong with
+the pattern.
+
==============================================================================
2. The definition of a pattern *search-pattern* *pattern* *[pattern]*
*regular-expression* *regexp* *Pattern*
@@ -888,7 +896,7 @@ $ At end of pattern or in front of "\|", "\)" or "\n" ('magic' on):
becomes invalid. Vim doesn't automatically update the matches.
Similar to moving the cursor for "\%#" |/\%#|.
- */\%l* */\%>l* */\%<l*
+ */\%l* */\%>l* */\%<l* *E951*
\%23l Matches in a specific line.
\%<23l Matches above a specific line (lower line number).
\%>23l Matches below a specific line (higher line number).
@@ -1148,7 +1156,8 @@ x A single character, with no special meaning, matches itself
- Matching with a collection can be slow, because each character in
the text has to be compared with each character in the collection.
Use one of the other atoms above when possible. Example: "\d" is
- much faster than "[0-9]" and matches the same characters.
+ much faster than "[0-9]" and matches the same characters. However,
+ the new |NFA| regexp engine deals with this better than the old one.
*/\%[]* *E69* *E70* *E369*
\%[] A sequence of optionally matched atoms. This always matches.
@@ -1390,4 +1399,4 @@ Finally, these constructs are unique to Perl:
":2match" for another plugin.
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/pi_gzip.txt b/runtime/doc/pi_gzip.txt
index f024db1260..0363a8e34a 100644
--- a/runtime/doc/pi_gzip.txt
+++ b/runtime/doc/pi_gzip.txt
@@ -38,4 +38,4 @@ compression. Thus editing the patchmode file will not give you the automatic
decompression. You have to rename the file if you want this.
==============================================================================
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/pi_msgpack.txt b/runtime/doc/pi_msgpack.txt
index e9f77e70b0..951b897f55 100644
--- a/runtime/doc/pi_msgpack.txt
+++ b/runtime/doc/pi_msgpack.txt
@@ -1,4 +1,4 @@
-*pi_msgpack.txt* Nvim
+*pi_msgpack.txt* msgpack utilities
Author: Nikolay Pavlov <kp-pav@yandex.ru>
Copyright: (c) 2015 by Nikolay Pavlov
@@ -49,7 +49,7 @@ does not check whether argument matches its description.
*{msgpack-value}* Either |msgpack-special-dict| or a regular value, but
not function reference.
-*{msgpack-integer}* Any value for which |msgpack#type| will return
+*{msgpack-integer}* Any value for which |msgpack#type()| will return
"integer".
*{msgpack-special-int}* |msgpack-special-dict| representing integer.
diff --git a/runtime/doc/pi_netrw.txt b/runtime/doc/pi_netrw.txt
index 3e19f0b4af..a0e071d4dd 100644
--- a/runtime/doc/pi_netrw.txt
+++ b/runtime/doc/pi_netrw.txt
@@ -3719,8 +3719,6 @@ netrw:
or
http://vim.sourceforge.net/scripts/script.php?script_id=120
- Decho.vim is provided as a "vimball"; see |vimball-intro|.
-
2. Edit the <netrw.vim> file by typing: >
vim netrw.vim
@@ -4100,4 +4098,4 @@ netrw:
==============================================================================
Modelines: {{{1
- vim:tw=78:ts=8:ft=help:norl:fdm=marker
+ vim:tw=78:ts=8:noet:ft=help:norl:fdm=marker
diff --git a/runtime/doc/pi_paren.txt b/runtime/doc/pi_paren.txt
index 4b425c6cbb..77083362da 100644
--- a/runtime/doc/pi_paren.txt
+++ b/runtime/doc/pi_paren.txt
@@ -56,4 +56,4 @@ used. This plugin also helps to skip matches in comments. This is unrelated
to the matchparen highlighting, they use a different mechanism.
==============================================================================
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/pi_spec.txt b/runtime/doc/pi_spec.txt
index f4949db2af..6d45a0f064 100644
--- a/runtime/doc/pi_spec.txt
+++ b/runtime/doc/pi_spec.txt
@@ -108,4 +108,4 @@ If you don't like the release updating feature and don't want to answer
Good luck!!
-vim:tw=78:ts=8:ft=help:norl:
+vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/pi_tar.txt b/runtime/doc/pi_tar.txt
index a189d006dd..59b318b7fd 100644
--- a/runtime/doc/pi_tar.txt
+++ b/runtime/doc/pi_tar.txt
@@ -148,4 +148,4 @@ Copyright 2005-2012: *tar-copyright*
v1 (original) * Michael Toren (see http://michael.toren.net/code/)
==============================================================================
-vim:tw=78:ts=8:ft=help
+vim:tw=78:ts=8:noet:ft=help
diff --git a/runtime/doc/pi_zip.txt b/runtime/doc/pi_zip.txt
index c20bda1fa1..7a5e7166ba 100644
--- a/runtime/doc/pi_zip.txt
+++ b/runtime/doc/pi_zip.txt
@@ -149,4 +149,4 @@ Copyright: Copyright (C) 2005-2015 Charles E Campbell *zip-copyright*
v1 Sep 15, 2005 * Initial release, had browsing, reading, and writing
==============================================================================
-vim:tw=78:ts=8:ft=help:fdm=marker
+vim:tw=78:ts=8:noet:ft=help:fdm=marker
diff --git a/runtime/doc/print.txt b/runtime/doc/print.txt
index 3ffb52b5ae..084ad4e521 100644
--- a/runtime/doc/print.txt
+++ b/runtime/doc/print.txt
@@ -36,6 +36,8 @@ Note: If you have problems printing with |:hardcopy|, an alternative is to use
'printexpr' through |v:cmdarg|. Otherwise [arguments]
is ignored. 'printoptions' can be used to specify
paper size, duplex, etc.
+ Note: If you want PDF, there are tools such as
+ "ps2pdf" that can convert the PostScript to PDF.
:[range]ha[rdcopy][!] >{filename}
As above, but write the resulting PostScript in file
@@ -729,4 +731,4 @@ to adjust the number of lines before a formfeed character to prevent
accidental blank pages.
==============================================================================
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/provider.txt b/runtime/doc/provider.txt
index 8b5798a5a5..0e26dc4515 100644
--- a/runtime/doc/provider.txt
+++ b/runtime/doc/provider.txt
@@ -13,44 +13,44 @@ Nvim delegates some features to dynamic "providers".
==============================================================================
Python integration *provider-python*
-Nvim supports Python |remote-plugin|s and the Vim legacy |python-vim| and
+Nvim supports Python |remote-plugin|s and the Vim legacy |python2| and
|python3| interfaces (which are implemented as remote-plugins).
Note: Only the Vim 7.3 API is supported; bindeval (Vim 7.4) is not.
PYTHON QUICKSTART ~
-If you used a package manager to install Nvim, you might already have the
-required "neovim" Python package. Run |:checkhealth| to verify.
+Install the "neovim" Python package:
-To install the package with "pip":
+- Run |:checkhealth| to see if you already have the package (some package
+ managers install the "neovim" Python package with Nvim itself).
- For Python 2 plugins, make sure Python 2.7 is available in your $PATH, then
- install the "neovim" Python package systemwide: >
+ install the package systemwide: >
sudo pip2 install --upgrade neovim
-<
- or for the current user: >
+< or for the current user: >
pip2 install --user --upgrade neovim
-<
+< If "pip2" is missing, try "pip".
+
- For Python 3 plugins, make sure Python 3.4+ is available in your $PATH, then
- install the "neovim" Python package systemwide: >
+ install the package systemwide: >
sudo pip3 install --upgrade neovim
-<
- or for the current user: >
+< or for the current user: >
pip3 install --user --upgrade neovim
-<
-Note: "pip" may refer to Python 2 or Python 3, so the steps above mention
-"pip2" and "pip3" explicitly. If one is missing, try "pip".
+< If "pip3" is missing, try "pip".
-Note: The `--upgrade` flag ensures you have the latest version even if
-a previous version was already installed.
+- The `--upgrade` flag ensures you have the latest version even if a previous
+ version was already installed.
PYTHON PROVIDER CONFIGURATION ~
*g:python_host_prog*
+Path to Python 2 interpreter. Setting this makes startup faster. Also useful
+for working with virtualenvs. >
+ let g:python_host_prog = '/path/to/python' " Python 2
+<
*g:python3_host_prog*
-Program to use for evaluating Python code. Setting this makes startup faster.
-Also useful for working with virtualenvs. >
- let g:python_host_prog = '/path/to/python'
- let g:python3_host_prog = '/path/to/python3'
+Path to Python 3 interpreter. Setting this makes startup faster. Also useful
+for working with virtualenvs. >
+ let g:python3_host_prog = '/path/to/python3' " Python 3
<
*g:loaded_python_provider*
To disable Python 2 support: >
@@ -62,21 +62,21 @@ To disable Python 3 support: >
PYTHON VIRTUALENVS ~
-If you plan to use per-project virtualenvs often, you should assign
-a virtualenv for Neovim and hard-code the interpreter path via
-|g:python_host_prog| (or |g:python3_host_prog|) so that the "neovim" python
-package is not required for each Environment. Example using pyenv: >
+If you plan to use per-project virtualenvs often, you should assign one
+virtualenv for Neovim and hard-code the interpreter path via
+|g:python3_host_prog| (or |g:python_host_prog|) so that the "neovim" package
+is not required for each virtualenv.
+
+Example using pyenv: >
pyenv install 3.4.4
- pyenv virtualenv 3.4.4 py3neovim
- pyenv activate py3neovim
+ pyenv virtualenv 3.4.4 py3nvim
+ pyenv activate py3nvim
pip install neovim
pyenv which python # Note the path
+The last command reports the interpreter path, add it to your init.vim: >
+ let g:python3_host_prog = '/path/to/py3nvim/bin/python'
-The last command reports the interpreter path. Add it to your init.vim: >
- let g:python3_host_prog = '/full/path/to/py3neovim/bin/python'
-
-More information:
-https://github.com/zchee/deoplete-jedi/wiki/Setting-up-Python-for-Neovim
+See also: https://github.com/zchee/deoplete-jedi/wiki/Setting-up-Python-for-Neovim
==============================================================================
Ruby integration *provider-ruby*
@@ -84,13 +84,13 @@ Ruby integration *provider-ruby*
Nvim supports Ruby |remote-plugin|s and the Vim legacy |ruby-vim| interface
(which is itself implemented as a Nvim remote-plugin).
-Run |:checkhealth| to see if your system is up-to-date.
-
RUBY QUICKSTART ~
To use Ruby plugins with Nvim, install the latest "neovim" RubyGem: >
gem install neovim
+Run |:checkhealth| to see if your system is up-to-date.
+
RUBY PROVIDER CONFIGURATION ~
*g:loaded_ruby_provider*
To disable Ruby support: >
@@ -103,11 +103,10 @@ avoid the need to install the "neovim" gem in every project.
To use an absolute path (e.g. to an rbenv installation): >
let g:ruby_host_prog = '~/.rbenv/versions/2.4.1/bin/neovim-ruby-host'
-<
To use the RVM "system" Ruby installation: >
let g:ruby_host_prog = 'rvm system do neovim-ruby-host'
-<
+
==============================================================================
Node.js integration *provider-nodejs*
@@ -130,7 +129,7 @@ To disable Node.js support: >
Command to start the Node.js host. Setting this makes startup faster.
By default, Nvim searches for "neovim-node-host" using "npm root -g", which
-can be slow. To avoid this, set g:node_host_prog to an absolute path: >
+can be slow. To avoid this, set g:node_host_prog to the host path: >
let g:node_host_prog = '/usr/local/bin/neovim-node-host'
<
==============================================================================
@@ -187,15 +186,15 @@ The contents of selections are held by the originating application (e.g., upon
a copy), and only passed to another application when that other application
requests them (e.g., upon a paste).
- *quoteplus* *quote+*
+ *primary-selection* *quotestar* *quoteplus* *quote+*
-There are three documented X11 selections: `PRIMARY`, `SECONDARY`, and `CLIPBOARD`.
-`CLIPBOARD` is typically used in X11 applications for copy/paste operations
-(`Ctrl-c`/`v`), while `PRIMARY` is used for the last selected text, which is
+There are three documented X11 selections: PRIMARY, SECONDARY, and CLIPBOARD.
+CLIPBOARD is typically used in X11 applications for copy/paste operations
+(CTRL-c/CTRL-v), while PRIMARY is used for the last selected text, which is
generally inserted with the middle mouse button.
-Nvim's X11 clipboard providers only utilize the `PRIMARY` and `CLIPBOARD`
-selections, used for the '*' and '+' registers, respectively.
+Nvim's X11 clipboard providers only use the PRIMARY and CLIPBOARD selections,
+for the "*" and "+" registers, respectively.
==============================================================================
vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/quickfix.txt b/runtime/doc/quickfix.txt
index f280286290..7aa81f612b 100644
--- a/runtime/doc/quickfix.txt
+++ b/runtime/doc/quickfix.txt
@@ -33,7 +33,7 @@ compiler (see |errorformat| below).
*quickfix-ID*
Each quickfix list has a unique identifier called the quickfix ID and this
-number will not change within a Vim session. The getqflist() function can be
+number will not change within a Vim session. The |getqflist()| function can be
used to get the identifier assigned to a list. There is also a quickfix list
number which may change whenever more than ten lists are added to a quickfix
stack.
@@ -51,6 +51,14 @@ When a window with a location list is split, the new window gets a copy of the
location list. When there are no longer any references to a location list,
the location list is destroyed.
+ *quickfix-changedtick*
+Every quickfix and location list has a read-only changedtick variable that
+tracks the total number of changes made to the list. Every time the quickfix
+list is modified, this count is incremented. This can be used to perform an
+action only when the list has changed. The |getqflist()| and |getloclist()|
+functions can be used to query the current value of changedtick. You cannot
+change the changedtick variable.
+
The following quickfix commands can be used. The location list commands are
similar to the quickfix commands, replacing the 'c' prefix in the quickfix
command with 'l'.
@@ -281,6 +289,10 @@ processing a quickfix or location list command, it will be aborted.
from the last error backwards, -1 being the last error.
The 'switchbuf' settings are respected when jumping
to a buffer.
+ The |:filter| command can be used to display only the
+ quickfix entries matching a supplied pattern. The
+ pattern is matched against the filename, module name,
+ pattern and text of the entry.
:cl[ist] +{count} List the current and next {count} valid errors. This
is similar to ":clist from from+count", where "from"
@@ -299,8 +311,7 @@ processing a quickfix or location list command, it will be aborted.
8386: ^ ~
8387: symbol: method Fmainx() ~
- *:lli* *:llist*
-:lli[st] [from] [, [to]]
+:lli[st] [from] [, [to]] *:lli* *:llist*
Same as ":clist", except the location list for the
current window is used instead of the quickfix list.
@@ -333,6 +344,51 @@ use this code: >
au QuickfixCmdPost make call QfMakeConv()
Another option is using 'makeencoding'.
+ *quickfix-title*
+Every quickfix and location list has a title. By default the title is set to
+the command that created the list. The |getqflist()| and |getloclist()|
+functions can be used to get the title of a quickfix and a location list
+respectively. The |setqflist()| and |setloclist()| functions can be used to
+modify the title of a quickfix and location list respectively. Examples: >
+ call setqflist([], 'a', {'title' : 'Cmd output'})
+ echo getqflist({'title' : 1})
+ call setloclist(3, [], 'a', {'title' : 'Cmd output'})
+ echo getloclist(3, {'title' : 1})
+<
+ *quickfix-size*
+You can get the number of entries (size) in a quickfix and a location list
+using the |getqflist()| and |getloclist()| functions respectively. Examples: >
+ echo getqflist({'size' : 1})
+ echo getloclist(5, {'size' : 1})
+<
+ *quickfix-context*
+Any Vim type can be associated as a context with a quickfix or location list.
+The |setqflist()| and the |setloclist()| functions can be used to associate a
+context with a quickfix and a location list respectively. The |getqflist()|
+and the |getloclist()| functions can be used to retrieve the context of a
+quickfix and a location list respectively. This is useful for a Vim plugin
+dealing with multiple quickfix/location lists.
+Examples: >
+
+ let somectx = {'name' : 'Vim', 'type' : 'Editor'}
+ call setqflist([], 'a', {'context' : somectx})
+ echo getqflist({'context' : 1})
+
+ let newctx = ['red', 'green', 'blue']
+ call setloclist(2, [], 'a', {'id' : qfid, 'context' : newctx})
+ echo getloclist(2, {'id' : qfid, 'context' : 1})
+<
+ *quickfix-parse*
+You can parse a list of lines using 'errorformat' without creating or
+modifying a quickfix list using the |getqflist()| function. Examples: >
+ echo getqflist({'lines' : ["F1:10:Line10", "F2:20:Line20"]})
+ echo getqflist({'lines' : systemlist('grep -Hn quickfix *')})
+This returns a dictionary where the 'items' key contains the list of quickfix
+entries parsed from lines. The following shows how to use a custom
+'errorformat' to parse the lines without modifying the 'errorformat' option: >
+ echo getqflist({'efm' : '%f#%l#%m', 'lines' : ['F1#10#Line']})
+<
+
EXECUTE A COMMAND IN ALL THE BUFFERS IN QUICKFIX OR LOCATION LIST:
*:cdo*
:cdo[!] {cmd} Execute {cmd} in each valid entry in the quickfix list.
@@ -358,8 +414,7 @@ EXECUTE A COMMAND IN ALL THE BUFFERS IN QUICKFIX OR LOCATION LIST:
autocommand event is disabled by adding it to
'eventignore'. This considerably speeds up editing
each buffer.
- {not in Vi} {not available when compiled without the
- |+listcmds| feature}
+ {not in Vi}
Also see |:bufdo|, |:tabdo|, |:argdo|, |:windo|,
|:ldo|, |:cfdo| and |:lfdo|.
@@ -372,8 +427,7 @@ EXECUTE A COMMAND IN ALL THE BUFFERS IN QUICKFIX OR LOCATION LIST:
:{cmd}
etc.
< Otherwise it works the same as `:cdo`.
- {not in Vi} {not available when compiled without the
- |+listcmds| feature}
+ {not in Vi}
*:ldo*
:ld[o][!] {cmd} Execute {cmd} in each valid entry in the location list
@@ -386,8 +440,7 @@ EXECUTE A COMMAND IN ALL THE BUFFERS IN QUICKFIX OR LOCATION LIST:
etc.
< Only valid entries in the location list are used.
Otherwise it works the same as `:cdo`.
- {not in Vi} {not available when compiled without the
- |+listcmds| feature}
+ {not in Vi}
*:lfdo*
:lfdo[!] {cmd} Execute {cmd} in each file in the location list for
@@ -399,8 +452,7 @@ EXECUTE A COMMAND IN ALL THE BUFFERS IN QUICKFIX OR LOCATION LIST:
:{cmd}
etc.
< Otherwise it works the same as `:ldo`.
- {not in Vi} {not available when compiled without the
- |+listcmds| feature}
+ {not in Vi}
=============================================================================
2. The error window *quickfix-window*
@@ -423,7 +475,9 @@ EXECUTE A COMMAND IN ALL THE BUFFERS IN QUICKFIX OR LOCATION LIST:
which will indicate the command that produced the
quickfix list. This can be used to compose a custom
status line if the value of 'statusline' is adjusted
- properly.
+ properly. Whenever this buffer is modified by a
+ quickfix command or function, the |b:changedtick|
+ variable is incremented.
*:lop* *:lopen*
:lop[en] [height] Open a window to show the location list for the
@@ -531,6 +585,117 @@ In all of the above cases, if the location list for the selected window is not
yet set, then it is set to the location list displayed in the location list
window.
+ *quickfix-window-ID*
+You can use the |getqflist()| and |getloclist()| functions to obtain the
+window ID of the quickfix window and location list window respectively (if
+present). Examples: >
+ echo getqflist({'winid' : 1}).winid
+ echo getloclist(2, {'winid' : 1}).winid
+<
+ *getqflist-examples*
+The |getqflist()| and |getloclist()| functions can be used to get the various
+attributes of a quickfix and location list respectively. Some examples for
+using these functions are below:
+>
+ " get the title of the current quickfix list
+ :echo getqflist({'title' : 0}).title
+
+ " get the identifier of the current quickfix list
+ :let qfid = getqflist({'id' : 0}).id
+
+ " get the identifier of the fourth quickfix list in the stack
+ :let qfid = getqflist({'nr' : 4, 'id' : 0}).id
+
+ " check whether a quickfix list with a specific identifier exists
+ :if getqflist({'id' : qfid}).id == qfid
+
+ " get the index of the current quickfix list in the stack
+ :let qfnum = getqflist({'nr' : 0}).nr
+
+ " get the items of a quickfix list specified by an identifier
+ :echo getqflist({'id' : qfid, 'items' : 0}).items
+
+ " get the number of entries in a quickfix list specified by an id
+ :echo getqflist({'id' : qfid, 'size' : 0}).size
+
+ " get the context of the third quickfix list in the stack
+ :echo getqflist({'nr' : 3, 'context' : 0}).context
+
+ " get the number of quickfix lists in the stack
+ :echo getqflist({'nr' : '$'}).nr
+
+ " get the number of times the current quickfix list is changed
+ :echo getqflist({'changedtick' : 0}).changedtick
+
+ " get the current entry in a quickfix list specified by an identifier
+ :echo getqflist({'id' : qfid, 'idx' : 0}).idx
+
+ " get all the quickfix list attributes using an identifier
+ :echo getqflist({'id' : qfid, 'all' : 0})
+
+ " parse text from a List of lines and return a quickfix list
+ :let myList = ["a.java:10:L10", "b.java:20:L20"]
+ :echo getqflist({'lines' : myList}).items
+
+ " parse text using a custom 'efm' and return a quickfix list
+ :echo getqflist({'lines' : ['a.c#10#Line 10'], 'efm':'%f#%l#%m'}).items
+
+ " get the quickfix list window id
+ :echo getqflist({'winid' : 0}).winid
+
+ " get the context of the current location list
+ :echo getloclist(0, {'context' : 0}).context
+
+ " get the location list window id of the third window
+ :echo getloclist(3, {'winid' : 0}).winid
+<
+ *setqflist-examples*
+The |setqflist()| and |setloclist()| functions can be used to set the various
+attributes of a quickfix and location list respectively. Some examples for
+using these functions are below:
+>
+ " create an empty quickfix list with a title and a context
+ :let t = 'Search results'
+ :let c = {'cmd' : 'grep'}
+ :call setqflist([], ' ', {'title' : t, 'context' : c})
+
+ " set the title of the current quickfix list
+ :call setqflist([], 'a', {'title' : 'Mytitle'})
+
+ " set the context of a quickfix list specified by an identifier
+ :call setqflist([], 'a', {'id' : qfid, 'context' : {'val' : 100}})
+
+ " create a new quickfix list from a command output
+ :call setqflist([], ' ', {'lines' : systemlist('grep -Hn main *.c')})
+
+ " parse text using a custom efm and add to a particular quickfix list
+ :call setqflist([], 'a', {'id' : qfid,
+ \ 'lines' : ["a.c#10#L10", "b.c#20#L20"], 'efm':'%f#%l#%m'})
+
+ " add items to the quickfix list specified by an identifier
+ :let newItems = [{'filename' : 'a.txt', 'lnum' : 10, 'text' : "Apple"},
+ \ {'filename' : 'b.txt', 'lnum' : 20, 'text' : "Orange"}]
+ :call setqflist([], 'a', {'id' : qfid, 'items' : newItems})
+
+ " empty a quickfix list specified by an identifier
+ :call setqflist([], 'r', {'id' : qfid, 'items' : []})
+
+ " free all the quickfix lists in the stack
+ :call setqflist([], 'f')
+
+ " set the title of the fourth quickfix list
+ :call setqflist([], 'a', {'nr' : 4, 'title' : 'SomeTitle'})
+
+ " create a new quickfix list at the end of the stack
+ :call setqflist([], ' ', {'nr' : '$',
+ \ 'lines' : systemlist('grep -Hn class *.java')})
+
+ " create a new location list from a command output
+ :call setloclist(0, [], ' ', {'lines' : systemlist('grep -Hn main *.c')})
+
+ " replace the location list entries for the third window
+ :call setloclist(3, [], 'r', {'items' : newItems})
+<
=============================================================================
3. Using more than one list of errors *quickfix-error-lists*
@@ -575,6 +740,14 @@ list, one newer list is overwritten. This is especially useful if you are
browsing with ":grep" |grep|. If you want to keep the more recent error
lists, use ":cnewer 99" first.
+To get the number of lists in the quickfix and location list stack, you can
+use the |getqflist()| and |getloclist()| functions respectively with the list
+number set to the special value '$'. Examples: >
+ echo getqflist({'nr' : '$'}).nr
+ echo getloclist(3, {'nr' : '$'}).nr
+To get the number of the current list in the stack: >
+ echo getqflist({'nr' : 0}).nr
+<
=============================================================================
4. Using :make *:make_makeprg*
@@ -1067,7 +1240,7 @@ or >
to indicate the column of the error. This is to be used in a multi-line error
message. See |errorformat-javac| for a useful example.
-The "%s" conversion specifies the text to search for to locate the error line.
+The "%s" conversion specifies the text to search for, to locate the error line.
The text is used as a literal string. The anchors "^" and "$" are added to
the text to locate the error line exactly matching the search text and the
text is prefixed with the "\V" atom to make it "very nomagic". The "%s"
@@ -1336,6 +1509,22 @@ The backslashes before the pipe character are required to avoid it to be
recognized as a command separator. The backslash before each space is
required for the set command.
+ *cfilter-plugin* *Cfilter* *Lfilter*
+If you have too many matching messages, you can use the cfilter plugin to
+reduce the number of entries. Load the plugin with: >
+ packadd cfilter
+
+Then you can use these command: >
+ :Cfilter[!] /{pat}/
+ :Lfilter[!] /{pat}/
+
+:Cfilter creates a new quickfix list from entries matching {pat} in the
+current quickfix list. Both the file name and the text of the entries are
+matched against {pat}. If ! is supplied, then entries not matching {pat} are
+used.
+
+:Lfilter does the same as :Cfilter but operates on the current location list.
+
=============================================================================
8. The directory stack *quickfix-directory-stack*
@@ -1573,4 +1762,4 @@ by Vim.
- vim:noet:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/quickref.txt b/runtime/doc/quickref.txt
index 7067c60d2f..cf0efd7a75 100644
--- a/runtime/doc/quickref.txt
+++ b/runtime/doc/quickref.txt
@@ -614,7 +614,8 @@ Short explanation of each option: *option-list*
'backupext' 'bex' extension used for the backup file
'backupskip' 'bsk' no backup for files that match these patterns
'balloondelay' 'bdlay' delay in mS before a balloon may pop up
-'ballooneval' 'beval' switch on balloon evaluation
+'ballooneval' 'beval' switch on balloon evaluation in the GUI
+'balloonevalterm' 'bevalterm' switch on balloon evaluation in the terminal
'balloonexpr' 'bexpr' expression to show in balloon
'belloff' 'bo' do not ring the bell for these reasons
'binary' 'bin' read/write/edit file in binary mode
@@ -809,6 +810,7 @@ Short explanation of each option: *option-list*
'printoptions' 'popt' controls the format of :hardcopy output
'prompt' 'prompt' enable prompt in Ex mode
'pumheight' 'ph' maximum height of the popup menu
+'pumwidth' 'pw' minimum width of the popup menu
'pythondll' name of the Python 2 dynamic library
'pythonthreedll' name of the Python 3 dynamic library
'quoteescape' 'qe' escape characters used in a string
@@ -906,6 +908,8 @@ Short explanation of each option: *option-list*
'undoreload' 'ur' max nr of lines to save for undo on a buffer reload
'updatecount' 'uc' after this many characters flush swap file
'updatetime' 'ut' after this many milliseconds flush swap file
+'varsofttabstop' 'vsts' a list of number of spaces when typing <Tab>
+'vartabstop' 'vts' a list of number of spaces for <Tab>s
'verbose' 'vbs' give informative messages
'verbosefile' 'vfile' file to write messages in
'viewdir' 'vdir' directory where to store files with :mkview
@@ -1372,4 +1376,4 @@ Context-sensitive completion on the command-line:
|zN| zN fold normal set 'foldenable'
|zi| zi invert 'foldenable'
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/recover.txt b/runtime/doc/recover.txt
index ffea514870..7789d4bdbc 100644
--- a/runtime/doc/recover.txt
+++ b/runtime/doc/recover.txt
@@ -27,6 +27,9 @@ You can see the name of the current swap file being used with the command:
:sw[apname] *:sw* *:swapname*
+Or you can use the |swapname()| function, which also allows for seeing the
+swap file name of other buffers.
+
The name of the swap file is normally the same as the file you are editing,
with the extension ".swp".
- On Unix, a '.' is prepended to swap file names in the same directory as the
@@ -170,4 +173,4 @@ Once you are sure the recovery is ok delete the swap file. Otherwise, you
will continue to get warning messages that the ".swp" file already exists.
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/remote.txt b/runtime/doc/remote.txt
index 039d8b582e..6c2ceb45be 100644
--- a/runtime/doc/remote.txt
+++ b/runtime/doc/remote.txt
@@ -167,10 +167,6 @@ a client and send strings to other instances of Vim on the same X11 display.
When an X11 GUI Vim (gvim) is started, it will try to register a send-server
name on the 'VimRegistry' property on the root window.
-A non GUI Vim with access to the X11 display (|xterm-clipboard| enabled), can
-also act as a command server if a server name is explicitly given with the
---servername argument.
-
An empty --servername argument will cause the command server to be disabled.
To send commands to a Vim server from another application, read the source
@@ -190,4 +186,4 @@ When using gvim, the --remote-wait only works properly this way: >
start /w gvim --remote-wait file.txt
<
- vim:tw=78:sw=4:ts=8:ft=help:norl:
+ vim:tw=78:sw=4:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/repeat.txt b/runtime/doc/repeat.txt
index 42889cca50..82a8c4c5cc 100644
--- a/runtime/doc/repeat.txt
+++ b/runtime/doc/repeat.txt
@@ -226,6 +226,10 @@ For writing a Vim script, see chapter 41 of the user manual |usr_41.txt|.
If the directory pack/*/opt/{name}/after exists it is
added at the end of 'runtimepath'.
+ If loading packages from "pack/*/start" was skipped,
+ then this directory is searched first:
+ pack/*/start/{name} ~
+
Note that {name} is the directory name, not the name
of the .vim file. All the files matching the pattern
pack/*/opt/{name}/plugin/**/*.vim ~
@@ -958,4 +962,4 @@ mind there are various things that may clobber the results:
- The "self" time is wrong when a function is used recursively.
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/rileft.txt b/runtime/doc/rileft.txt
index ba9bb1eba7..8fd67c9602 100644
--- a/runtime/doc/rileft.txt
+++ b/runtime/doc/rileft.txt
@@ -112,4 +112,4 @@ o When both 'rightleft' and 'revins' are on: 'textwidth' does not work.
o There is no full bidirectionality (bidi) support.
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/russian.txt b/runtime/doc/russian.txt
index 8c6076146c..724c4f9454 100644
--- a/runtime/doc/russian.txt
+++ b/runtime/doc/russian.txt
@@ -68,4 +68,4 @@ In order to use the Russian documentation, make sure you have set the
releases of gettext.
===============================================================================
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/scroll.txt b/runtime/doc/scroll.txt
index 99ebd26db3..7906214111 100644
--- a/runtime/doc/scroll.txt
+++ b/runtime/doc/scroll.txt
@@ -27,6 +27,7 @@ seen):
*CTRL-E*
CTRL-E Scroll window [count] lines downwards in the buffer.
+ The text moves upwards on the screen.
Mnemonic: Extra lines.
*CTRL-D*
@@ -65,6 +66,7 @@ seen):
*CTRL-Y*
CTRL-Y Scroll window [count] lines upwards in the buffer.
+ The text moves downwards on the screen.
Note: When using the MS-Windows key bindings CTRL-Y is
remapped to redo.
@@ -248,4 +250,4 @@ the scroll wheel move one line or half a page in Normal mode: >
:map <S-ScrollWheelDown> <C-D>
You can also use Alt and Ctrl modifiers.
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/sign.txt b/runtime/doc/sign.txt
index 977d73b7b2..273d2b984c 100644
--- a/runtime/doc/sign.txt
+++ b/runtime/doc/sign.txt
@@ -79,12 +79,15 @@ DEFINING A SIGN. *:sign-define* *E255* *E160* *E612*
will cause redraw problems.
toolkit supports ~
Win32 .bmp, .ico, .cur
- pixmap (.xpm) |+xpm_w32|
linehl={group}
Highlighting group used for the whole line the sign is placed
in. Most useful is defining a background color.
+ numhl={group}
+ Highlighting group used for 'number' column at the associated
+ line. Overrides |hl-LineNr|, |hl-CursorLineNr|.
+
text={text} *E239*
Define the text that is displayed when there is no icon or the
GUI is not being used. Only printable characters are allowed
@@ -192,4 +195,4 @@ JUMPING TO A SIGN *:sign-jump* *E157*
have a name.
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/spell.txt b/runtime/doc/spell.txt
index 718b5d4c1f..875f3f2c08 100644
--- a/runtime/doc/spell.txt
+++ b/runtime/doc/spell.txt
@@ -1733,4 +1733,4 @@ This isn't ideal, because the longer Vim is running the higher the counts
become. But in practice it is a noticeable improvement over not using the word
count.
- vim:tw=78:sw=4:ts=8:ft=help:norl:
+ vim:tw=78:sw=4:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/sponsor.txt b/runtime/doc/sponsor.txt
deleted file mode 100644
index cfdf21abea..0000000000
--- a/runtime/doc/sponsor.txt
+++ /dev/null
@@ -1,216 +0,0 @@
-*sponsor.txt* Nvim
-
-
- VIM REFERENCE MANUAL by Bram Moolenaar
-
-
-
-SPONSOR VIM DEVELOPMENT *sponsor*
-
-Fixing bugs and adding new features takes a lot of time and effort. To show
-your appreciation for the work and motivate Bram and others to continue
-working on Vim please send a donation.
-
-Since Bram is back to a paid job the money will now be used to help children
-in Uganda. See |uganda|. But at the same time donations increase Bram's
-motivation to keep working on Vim!
-
-For the most recent information about sponsoring look on the Vim web site:
-
- http://www.vim.org/sponsor/
-
-More explanations can be found in the |sponsor-faq|.
-
-
-REGISTERED VIM USER *register*
-
-You can become a registered Vim user by sending at least 10 euro. This works
-similar to sponsoring Vim, see |sponsor| above. Registration was made
-possible for the situation where your boss or bookkeeper may be willing to
-register software, but does not like the terms "sponsoring" and "donation".
-
-More explanations can be found in the |register-faq|.
-
-
-VOTE FOR FEATURES *vote-for-features*
-
-To give registered Vim users and sponsors an advantage over lurkers they can
-vote for the items Bram should work on. How does this voting work?
-
-1. You send at least 10 euro. See below for ways to transfer money
- |send-money|.
-
-2. You will be e-mailed a registration key. Enter this key on your account
- page on the Vim website. You can easily create an account if you don't
- have one yet.
-
-3. You can enter your votes on the voting page. There is a link to that page
- on your account page after entering a registration key. Your votes will
- be counted for two years.
-
-4. The voting results appear on the results page, which is visible for
- everybody: http://www.vim.org/sponsor/vote_results.php
-
-Additionally, once you have sent 100 euro or more in total, your name appears
-in the "Vim hall of honour": http://www.vim.org/sponsor/hall_of_honour.php
-But only if you enable this on your account page.
-
-
-HOW TO SEND MONEY *send-money*
-
-Credit card Through PayPal, see the PayPal site for information:
- https://www.paypal.com/en_US/mrb/pal=XAC62PML3GF8Q
- The e-mail address for sending sponsorship money is:
- donate@vim.org
- The e-mail address for Vim registration is:
- register@vim.org
- Using Euro is preferred, other currencies are also accepted.
- In Euro countries a bank transfer is preferred, this has lower
- costs.
-
-Other methods See |iccf-donations|.
- Include "Vim sponsor" or "Vim registration" in the comment of
- your money transfer. Send me an e-mail that mentions the
- amount you transferred if you want to vote for features and
- show others you are a registered Vim user or sponsor.
-
-Cash Small amounts can be sent with ordinary mail. Put something
- around the money, so that it's not noticeable from the
- outside. Mention your e-mail address if you want to vote for
- features and show others you are a registered Vim user or
- sponsor.
-
-You can use this permanent address:
- Bram Moolenaar
- Finsterruetihof 1
- 8134 Adliswil
- Switzerland
-
-
-
-QUESTIONS AND ANSWERS *sponsor-faq* *register-faq*
-
-Why should I give money?
-
-If you do not show your appreciation for Vim then Bram will be less motivated
-to fix bugs and add new features. He will do something else instead.
-
-
-How much money should I send?
-
-That is up to you. The more you give, the more children will be helped.
-An indication for individuals that use Vim at home: 10 Euro per year. For
-professional use: 30 Euro per year per person. Send at least 10 euro to be
-able to vote for features.
-
-
-What do I get in return?
-
-Each registered Vim user and sponsor who donates at least 10 euro will be able
-to vote for new features. These votes will give priority to the work on Vim.
-The votes are valid for two years. The more money you send the more your
-votes count |votes-counted|.
-
-If you send 100 Euro or more in total you will be mentioned on the "Vim hall
-of honour" page on the Vim web site. But only if you enable this on your
-account page. You can also select whether the amount will be visible.
-
-
-How do I become a Vim sponsor or registered Vim user?
-
-Send money, as explained above |send-money| and include your e-mail address.
-When the money has been received you will receive a unique registration key.
-This key can be used on the Vim website to activate voting on your Vim
-account. You will then get an extra page where you can vote for features and
-choose whether others will be able to see that you donated. There is a link
-to this page on your "My Account" page.
-
-
-What is the difference between sponsoring and registering?
-
-It has a different name. Use the term "registration" if your boss doesn't
-like "sponsoring" or "donation". The benefits are the same.
-
-
-How can I send money?
-
-See |send-money|. Check the web site for the most recent information:
-http://www.vim.org/sponsor/
-
-
-Why don't you use the SourceForge donation system?
-
-SourceForge takes 5% of the donations for themselves. If you want to support
-SourceForge you can send money to them directly.
-
-
-I cannot afford to send money, may I still use Vim?
-
-Yes.
-
-
-I did not register Vim, can I use all available features?
-
-Yes.
-
-
-I noticed a bug, do I need to register before I can report it?
-
-No, suggestions for improving Vim can always be given. For improvements use
-the developer |maillist|, for reporting bugs see |bugs|.
-
-
-How are my votes counted? *votes-counted*
-
-You may vote when you send 10 euro or more. You can enter up to ten votes.
-You can select the same item several times to give it more points. You can
-also enter three counter votes, these count as negative points.
-
-When you send 30 euro or more the points are doubled. Above 100 euro they
-count four times, above 300 euro they count six times, above 1000 euro ten
-times.
-
-
-Can I change my votes?
-
-You can change your votes any time you like, up to two years after you
-sent money. The points will be counted right away.
-
-
-Can I add an item to vote on?
-
-Not directly. You can suggest items to vote on to Bram. He will consider
-fitting your item into the list.
-
-
-How about Charityware?
-
-Currently the Vim donations go to |uganda| anyway. Thus it doesn't matter if
-you sponsor Vim or ICCF. Except that Vim sponsoring will allow you to vote
-for features.
-
-
-I donated $$$, now please add feature XYZ!
-
-There is no direct relation between your donation and the work Bram does.
-Otherwise you would be paying for work and we would have to pay tax over the
-donation. If you want to hire Bram for specific work, contact him directly,
-don't use the donation system.
-
-
-Are the donations tax deductible?
-
-That depends on your country. The donations to help the children in |Uganda|
-are tax deductible in Holland, Germany, Canada and in the USA. See the ICCF
-website http://iccf-holland.org/donate.html. You must send an e-mail to Bram
-to let him know that the donation is done because of the use of Vim.
-
-
-Can you send me a bill?
-
-No, because there is no relation between the money you send and the work that
-is done. But a receipt is possible.
-
-
-
- vim:tw=78:ts=8:ft=help:norl:
diff --git a/runtime/doc/starting.txt b/runtime/doc/starting.txt
index ad1077bcab..1da2441929 100644
--- a/runtime/doc/starting.txt
+++ b/runtime/doc/starting.txt
@@ -76,7 +76,8 @@ The option arguments may be given in any order. Single-letter options can be
combined after one dash. There can be no option arguments after the "--"
argument.
---help *-h* *--help*
+--help *-h* *--help* *-?*
+-?
-h Give usage (help) message and exit.
See |info-message| about capturing the text.
@@ -347,21 +348,37 @@ argument.
*--embed*
--embed Use stdin/stdout as a msgpack-RPC channel, so applications can
- embed and control Nvim via the |rpc-api|. Implies |--headless|.
- Equivalent to: >
+ embed and control Nvim via the |rpc-api|.
+
+ By default nvim will wait for the embedding process to call
+ `nvim_ui_attach` before sourcing startup files and reading
+ buffers. This is so that UI can show startup messages and
+ possible swap file dialog for the first loaded file. The
+ process can do requests before the `nvim_ui_attach`, for
+ instance a `nvim_get_api_info` call so that UI features can be
+ safely detected by the UI before attaching.
+
+ See |ui-startup| for more information about UI startup.
+
+ To embed nvim without using the UI protocol, `--headless` should
+ be supplied together with `--embed`. Then initialization is
+ performed without waiting for an UI. This is also equivalent
+ to the following alternative: >
nvim --headless --cmd "call stdioopen({'rpc': v:true})"
<
See also |channel-stdio|.
*--headless*
---headless Do not start the default UI, so stdio can be used as an
- arbitrary communication channel. |channel-stdio|
+--headless Start nvim without an UI. The TUI is not used, so stdio
+ can be used as an arbitrary communication channel.
+ |channel-stdio| When used together with `--embed`, do not wait
+ for the embedder to attach an UI.
Also useful for scripting (tests) to see messages that would
not be printed by |-es|.
To detect if a UI is available, check if |nvim_list_uis()| is
- empty after |VimEnter|.
+ empty in or after |VimEnter|.
To read stdin as text, "-" must be given explicitly:
--headless cannot assume that stdin is just text. >
@@ -408,9 +425,6 @@ accordingly. Vim proceeds in this order:
Windows $XDG_CONFIG_HOME/nvim/init.vim
(default for $XDG_CONFIG_HOME is ~/AppData/Local)
- The files are searched in the order specified above and only the first
- one that is found is read.
-
RECOMMENDATION: Put all your Vim configuration stuff in the
$HOME/.config/nvim/ directory. That makes it easy to copy it to
another system.
@@ -685,27 +699,25 @@ greps in the help files) you might be able to use this: >
4. Suspending *suspend*
*iconize* *iconise* *CTRL-Z* *v_CTRL-Z*
-CTRL-Z Suspend Vim, like ":stop".
+CTRL-Z Suspend Nvim, like ":stop".
Works in Normal and in Visual mode. In Insert and
Command-line mode, the CTRL-Z is inserted as a normal
- character. In Visual mode Vim goes back to Normal
+ character. In Visual mode Nvim goes back to Normal
mode.
:sus[pend][!] or *:sus* *:suspend* *:st* *:stop*
-:st[op][!] Suspend Vim. Vim will continue if you make it the
- foreground job again.
- If the '!' is not given and 'autowrite' is set, every
+:st[op][!] Suspend Nvim using OS "job control"; it will continue
+ if you make it the foreground job again. Triggers
+ |VimSuspend| before suspending and |VimResume| when
+ resumed.
+ If "!" is not given and 'autowrite' is set, every
buffer with changes and a file name is written out.
- If the '!' is given or 'autowrite' is not set, changed
- buffers are not written, don't forget to bring Vim
+ If "!" is given or 'autowrite' is not set, changed
+ buffers are not written, don't forget to bring Nvim
back to the foreground later!
In the GUI, suspending is implementation-defined.
-In X-windows the selection is disowned when Vim suspends. this means you
-can't paste it in another application (since Vim is going to sleep an attempt
-to get the selection would make the program hang).
-
==============================================================================
5. Exiting *exiting*
@@ -837,7 +849,7 @@ resulting file, when executed with a ":source" command:
such as creating menu items in the GUI version.
After restoring the Session, the full filename of your current Session is
-available in the internal variable "v:this_session" |this_session-variable|.
+available in the internal variable |v:this_session|.
An example mapping: >
:nmap <F2> :wa<Bar>exe "mksession! " . v:this_session<CR>:so ~/sessions/
This saves the current Session, and starts off the command to load another.
@@ -1089,6 +1101,8 @@ SHADA FILE NAME *shada-file-name*
- The "-i" Vim argument can be used to set another file name, |-i|. When the
file name given is "NONE" (all uppercase), no ShaDa file is ever read or
written. Also not for the commands below!
+- The 'viminfofile' option can be used like the "-i" argument. In fact, the
+ value form the "-i" argument is stored in the 'viminfofile' option.
- For the commands below, another file name can be given, overriding the
default and the name given with 'shada' or "-i" (unless it's NONE).
@@ -1359,7 +1373,7 @@ file when reading and include:
9. Standard Paths *standard-path*
Nvim stores configuration and data in standard locations. Plugins are strongly
-encouraged to follow this pattern also.
+encouraged to follow this pattern also. Use |stdpath()| to get the paths.
*base-directories* *xdg*
The "base" (root) directories conform to the XDG Base Directory Specification.
@@ -1367,18 +1381,18 @@ https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html
The $XDG_CONFIG_HOME and $XDG_DATA_HOME environment variables are used if they
exist, otherwise default values (listed below) are used.
-Note: Throughout the user manual these defaults are used as placeholders, e.g.
-"~/.config" is understood to mean "$XDG_CONFIG_HOME or ~/.config".
+CONFIG DIRECTORY (DEFAULT) ~
+ *$XDG_CONFIG_HOME* Nvim: stdpath("config")
+ Unix: ~/.config ~/.config/nvim
+ Windows: ~/AppData/Local ~/AppData/Local/nvim
-CONFIG DIRECTORY *$XDG_CONFIG_HOME*
- Base Nvim ~
-Unix: ~/.config ~/.config/nvim
-Windows: ~/AppData/Local ~/AppData/Local/nvim
+DATA DIRECTORY (DEFAULT) ~
+ *$XDG_DATA_HOME* Nvim: stdpath("data")
+ Unix: ~/.local/share ~/.local/share/nvim
+ Windows: ~/AppData/Local ~/AppData/Local/nvim-data
-DATA DIRECTORY *$XDG_DATA_HOME*
- Base Nvim ~
-Unix: ~/.local/share ~/.local/share/nvim
-Windows: ~/AppData/Local ~/AppData/Local/nvim-data
+Note: Throughout the user manual these defaults are used as placeholders, e.g.
+"~/.config" is understood to mean "$XDG_CONFIG_HOME or ~/.config".
LOG FILE *$NVIM_LOG_FILE*
Besides 'debug' and 'verbose', Nvim keeps a general log file for internal
diff --git a/runtime/doc/syntax.txt b/runtime/doc/syntax.txt
index 094b280697..4c3c7d329a 100644
--- a/runtime/doc/syntax.txt
+++ b/runtime/doc/syntax.txt
@@ -1243,7 +1243,7 @@ doxygen_javadoc_autobrief 1 Set to 0 to disable javadoc autobrief
doxygen_end_punctuation '[.]' Set to regexp match for the ending
punctuation of brief
-There are also some hilight groups worth mentioning as they can be useful in
+There are also some highlight groups worth mentioning as they can be useful in
configuration.
Highlight Effect ~
@@ -1947,7 +1947,7 @@ set "lite_minlines" to the value you desire. Example: >
LPC *lpc.vim* *ft-lpc-syntax*
-LPC stands for a simple, memory-efficient language: Lars Pensj| C. The
+LPC stands for a simple, memory-efficient language: Lars Pensjö C. The
file name of LPC is usually *.c. Recognizing these files as LPC would bother
users writing only C programs. If you want to use LPC syntax in Vim, you
should set a variable in your vimrc file: >
@@ -2610,6 +2610,48 @@ Any combination of these three variables is legal, but might highlight more
commands than are actually available to you by the game.
+R *r.vim* *ft-r-syntax*
+
+The parsing of R code for syntax highlight starts 40 lines backwards, but you
+can set a different value in your |vimrc|. Example: >
+ let r_syntax_minlines = 60
+
+You can also turn off syntax highlighting of ROxygen: >
+ let r_syntax_hl_roxygen = 0
+
+enable folding of code delimited by parentheses, square brackets and curly
+braces: >
+ let r_syntax_folding = 1
+
+and highlight as functions all keywords followed by an opening parenthesis: >
+ let r_syntax_fun_pattern = 1
+
+
+R MARKDOWN *rmd.vim* *ft-rmd-syntax*
+
+To disable syntax highlight of YAML header, add to your |vimrc|: >
+ let rmd_syn_hl_yaml = 0
+
+To disable syntax highlighting of citation keys: >
+ let rmd_syn_hl_citations = 0
+
+To highlight R code in knitr chunk headers: >
+ let rmd_syn_hl_chunk = 1
+
+By default, chunks of R code will be highlighted following the rules of R
+language. If you want proper syntax highlighting of chunks of other languages,
+you should add them to either `markdown_fenced_languages` or
+`rmd_fenced_languages`. For example to properly highlight both R and Python,
+you may add this to your |vimrc|: >
+ let rmd_fenced_languages = ['r', 'python']
+
+
+R RESTRUCTURED TEXT *rrst.vim* *ft-rrst-syntax*
+
+To highlight R code in knitr chunk headers, add to your |vimrc|: >
+ let rrst_syn_hl_chunk = 1
+
+
READLINE *readline.vim* *ft-readline-syntax*
The readline library is primarily used by the BASH shell, which adds quite a
@@ -2748,13 +2790,10 @@ Ruby syntax will perform spellchecking of strings if you define
SCHEME *scheme.vim* *ft-scheme-syntax*
-By default only R5RS keywords are highlighted and properly indented.
+By default only R7RS keywords are highlighted and properly indented.
-MzScheme-specific stuff will be used if b:is_mzscheme or g:is_mzscheme
-variables are defined.
-
-Also scheme.vim supports keywords of the Chicken Scheme->C compiler. Define
-b:is_chicken or g:is_chicken, if you need them.
+scheme.vim also supports extensions of the CHICKEN Scheme->C compiler.
+Define b:is_chicken or g:is_chicken, if you need them.
SDL *sdl.vim* *ft-sdl-syntax*
@@ -2848,17 +2887,17 @@ This covers syntax highlighting for the older Unix (Bourne) sh, and newer
shells such as bash, dash, posix, and the Korn shells.
Vim attempts to determine which shell type is in use by specifying that
-various filenames are of specific types: >
+various filenames are of specific types, e.g.: >
ksh : .kshrc* *.ksh
bash: .bashrc* bashrc bash.bashrc .bash_profile* *.bash
<
-If none of these cases pertain, then the first line of the file is examined
-(ex. looking for /bin/sh /bin/ksh /bin/bash). If the first line specifies a
-shelltype, then that shelltype is used. However some files (ex. .profile) are
-known to be shell files but the type is not apparent. Furthermore, on many
-systems sh is symbolically linked to "bash" (Linux, Windows+cygwin) or "ksh"
-(Posix).
+See $VIMRUNTIME/filetype.vim for the full list of patterns. If none of these
+cases pertain, then the first line of the file is examined (ex. looking for
+/bin/sh /bin/ksh /bin/bash). If the first line specifies a shelltype, then
+that shelltype is used. However some files (ex. .profile) are known to be
+shell files but the type is not apparent. Furthermore, on many systems sh is
+symbolically linked to "bash" (Linux, Windows+cygwin) or "ksh" (Posix).
One may specify a global default by instantiating one of the following
variables in your vimrc:
@@ -3141,6 +3180,12 @@ by syntax/tex.vim. Please consider uploading any extensions that you write,
which typically would go in $HOME/after/syntax/tex/[pkgname].vim, to
http://vim.sf.net/.
+I've included some support for various popular packages on my website: >
+
+ http://www.drchip.org/astronaut/vim/index.html#LATEXPKGS
+<
+The syntax files there go into your .../after/syntax/tex/ directory.
+
*tex-error* *g:tex_no_error*
Tex: Excessive Error Highlighting? ~
@@ -4585,7 +4630,9 @@ in their own color.
runtime colors/evening.vim
hi Statement ctermfg=Blue guifg=Blue
-< After the color scheme has been loaded the
+< Before the color scheme will be loaded the
+ |ColorSchemePre| autocommand event is triggered.
+ After the color scheme has been loaded the
|ColorScheme| autocommand event is triggered.
For info about writing a colorscheme file: >
:edit $VIMRUNTIME/colors/README.txt
@@ -4665,8 +4712,8 @@ cterm={attr-list} *attr-list* *highlight-cterm* *E418*
Note that "bold" can be used here and by using a bold font. They
have the same effect.
- If running in a terminal, "undercurl" acts as an alias for "underline".
- It is set using |highlight-guisp|.
+ "undercurl" falls back to "underline" in a terminal that does not
+ support it. The color is set using |highlight-guisp|.
start={term-list} *highlight-start* *E422*
stop={term-list} *term-list* *highlight-stop*
@@ -4799,7 +4846,8 @@ guifg={color-name} *highlight-guifg*
guibg={color-name} *highlight-guibg*
guisp={color-name} *highlight-guisp*
These give the foreground (guifg), background (guibg) and special
- (guisp) color to use in the GUI. "guisp" is used for undercurl.
+ (guisp) color to use in the GUI. "guisp" is used for undercurl
+ and underline.
There are a few special names:
NONE no color (transparent)
bg use normal background color
@@ -4946,6 +4994,11 @@ StatusLine status line of current window
StatusLineNC status lines of not-current windows
Note: if this is equal to "StatusLine" Vim will use "^^^" in
the status line of the current window.
+ *hl-StatusLineTerm*
+StatusLineTerm status line of current window, if it is a |terminal| window.
+ *hl-StatusLineTermNC*
+StatusLineTermNC status lines of not-current windows that is a |terminal|
+ window.
*hl-TabLine*
TabLine tab pages line, not active tab page label
*hl-TabLineFill*
@@ -5189,7 +5242,7 @@ To test your color setup, a file has been included in the Vim distribution.
To use it, execute this command: >
:runtime syntax/colortest.vim
-Nvim uses |256-color| and |true-color| terminal capabilities whereever possible.
+Nvim uses 256-color and |true-color| terminal capabilities whereever possible.
==============================================================================
18. When syntax is slow *:syntime*
@@ -5249,4 +5302,4 @@ literal text specify the size of that text (in bytes):
"<\@1<=span" Matches the same, but only tries one byte before "span".
- vim:tw=78:sw=4:ts=8:ft=help:norl:
+ vim:tw=78:sw=4:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/tabpage.txt b/runtime/doc/tabpage.txt
index 6be7cf9746..a0459d27bc 100644
--- a/runtime/doc/tabpage.txt
+++ b/runtime/doc/tabpage.txt
@@ -203,7 +203,8 @@ gT Go to the previous tab page. Wraps around from the first one
:tabN[ext] {count}
{count}<C-PageUp>
{count}gT Go {count} tab pages back. Wraps around from the first one
- to the last one.
+ to the last one. Note that the use of {count} is different
+ from |:tabnext|, where it is used as the tab page number.
:tabr[ewind] *:tabfir* *:tabfirst* *:tabr* *:tabrewind*
:tabfir[st] Go to the first tab page.
@@ -230,8 +231,10 @@ REORDERING TAB PAGES:
:tabm[ove] [N] *:tabm* *:tabmove*
:[N]tabm[ove]
Move the current tab page to after tab page N. Use zero to
- make the current tab page the first one. Without N the tab
- page is made the last one. >
+ make the current tab page the first one. N is counted before
+ the move, thus if the second tab is the current one,
+ `:tabmove 1` and `:tabmove 2` have no effect.
+ Without N the tab page is made the last one. >
:.tabmove " do nothing
:-tabmove " move the tab page to the left
:+tabmove " move the tab page to the right
@@ -463,4 +466,4 @@ If you want to show something specific for a tab page, you might want to use a
tab page local variable. |t:var|
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/tagsrch.txt b/runtime/doc/tagsrch.txt
index f0ad2cfd43..367da7750e 100644
--- a/runtime/doc/tagsrch.txt
+++ b/runtime/doc/tagsrch.txt
@@ -31,12 +31,12 @@ An easy way back is with the CTRL-T command. Also read about the tag stack
below.
*:ta* *:tag* *E426* *E429*
-:[count]ta[g][!] {ident}
- Jump to the definition of {ident}, using the
- information in the tags file(s). Put {ident} in the
+:[count]ta[g][!] {name}
+ Jump to the definition of {name}, using the
+ information in the tags file(s). Put {name} in the
tag stack. See |tag-!| for [!].
- {ident} can be a regexp pattern, see |tag-regexp|.
- When there are several matching tags for {ident}, jump
+ {name} can be a regexp pattern, see |tag-regexp|.
+ When there are several matching tags for {name}, jump
to the [count] one. When [count] is omitted the
first one is jumped to. See |tag-matchlist| for
jumping to other matching tags.
@@ -44,15 +44,15 @@ below.
g<LeftMouse> *g<LeftMouse>*
<C-LeftMouse> *<C-LeftMouse>* *CTRL-]*
CTRL-] Jump to the definition of the keyword under the
- cursor. Same as ":tag {ident}", where {ident} is the
+ cursor. Same as ":tag {name}", where {name} is the
keyword under or after cursor.
- When there are several matching tags for {ident}, jump
+ When there are several matching tags for {name}, jump
to the [count] one. When no [count] is given the
first one is jumped to. See |tag-matchlist| for
jumping to other matching tags.
*v_CTRL-]*
-{Visual}CTRL-] Same as ":tag {ident}", where {ident} is the text that
+{Visual}CTRL-] Same as ":tag {name}", where {name} is the text that
is highlighted.
*telnet-CTRL-]*
@@ -76,7 +76,7 @@ When there are multiple matches for a tag, this priority is used:
Note that when the current file changes, the priority list is mostly not
changed, to avoid confusion when using ":tnext". It is changed when using
-":tag {ident}".
+":tag {name}".
The ignore-case matches are not found for a ":tag" command when:
- the 'ignorecase' option is off and 'tagcase' is "followic"
@@ -161,7 +161,7 @@ You can get from main to FuncA by using CTRL-] on the call to FuncA. Then
you can CTRL-] to get to FuncC. If you now want to go back to main you can
use CTRL-T twice. Then you can CTRL-] to FuncB.
-If you issue a ":ta {ident}" or CTRL-] command, this tag is inserted at the
+If you issue a ":ta {name}" or CTRL-] command, this tag is inserted at the
current position in the stack. If the stack was full (it can hold up to 20
entries), the oldest entry is deleted and the older entries shift one
position up (their index number is decremented by one). If the last used
@@ -185,14 +185,14 @@ between them. Note that these commands don't change the tag stack, they keep
the same entry.
*:ts* *:tselect*
-:ts[elect][!] [ident] List the tags that match [ident], using the
+:ts[elect][!] [name] List the tags that match [name], using the
information in the tags file(s).
- When [ident] is not given, the last tag name from the
+ When [name] is not given, the last tag name from the
tag stack is used.
See |tag-!| for [!].
With a '>' in the first column is indicated which is
the current position in the list (if there is one).
- [ident] can be a regexp pattern, see |tag-regexp|.
+ [name] can be a regexp pattern, see |tag-regexp|.
See |tag-priority| for the priorities used in the
listing.
Example output:
@@ -220,7 +220,7 @@ the same entry.
type 'q' and enter the number.
*:sts* *:stselect*
-:sts[elect][!] [ident] Does ":tselect[!] [ident]" and splits the window for
+:sts[elect][!] [name] Does ":tselect[!] [name]" and splits the window for
the selected tag.
*g]*
@@ -231,11 +231,11 @@ g] Like CTRL-], but use ":tselect" instead of ":tag".
identifier.
*:tj* *:tjump*
-:tj[ump][!] [ident] Like ":tselect", but jump to the tag directly when
+:tj[ump][!] [name] Like ":tselect", but jump to the tag directly when
there is only one match.
*:stj* *:stjump*
-:stj[ump][!] [ident] Does ":tjump[!] [ident]" and splits the window for the
+:stj[ump][!] [name] Does ":tjump[!] [name]" and splits the window for the
selected tag.
*g_CTRL-]*
@@ -267,9 +267,9 @@ g CTRL-] Like CTRL-], but use ":tjump" instead of ":tag".
:tl[ast][!] Jump to last matching tag. See |tag-!| for [!].
*:lt* *:ltag*
-:lt[ag][!] [ident] Jump to tag [ident] and add the matching tags to a new
- location list for the current window. [ident] can be
- a regexp pattern, see |tag-regexp|. When [ident] is
+:lt[ag][!] [name] Jump to tag [name] and add the matching tags to a new
+ location list for the current window. [name] can be
+ a regexp pattern, see |tag-regexp|. When [name] is
not given, the last tag name from the tag stack is
used. The search pattern to locate the tag line is
prefixed with "\V" to escape all the special
@@ -300,11 +300,11 @@ the same as above, with a "p" prepended.
{not available when compiled without the |+quickfix| feature}
*:pts* *:ptselect*
-:pts[elect][!] [ident] Does ":tselect[!] [ident]" and shows the new tag in a
+:pts[elect][!] [name] Does ":tselect[!] [name]" and shows the new tag in a
"Preview" window. See |:ptag| for more info.
*:ptj* *:ptjump*
-:ptj[ump][!] [ident] Does ":tjump[!] [ident]" and shows the new tag in a
+:ptj[ump][!] [name] Does ":tjump[!] [name]" and shows the new tag in a
"Preview" window. See |:ptag| for more info.
*:ptn* *:ptnext*
@@ -819,4 +819,4 @@ Common arguments for the commands above:
< For a ":djump", ":dsplit", ":dlist" and ":dsearch" command the pattern
is used as a literal string, not as a search pattern.
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/term.txt b/runtime/doc/term.txt
index 418623687f..9de5745e92 100644
--- a/runtime/doc/term.txt
+++ b/runtime/doc/term.txt
@@ -257,90 +257,14 @@ effect on some UIs.
==============================================================================
Using the mouse *mouse-using*
-This section is about using the mouse on a terminal or a terminal window. How
-to use the mouse in a GUI window is explained in |gui-mouse|. For scrolling
-with a mouse wheel see |scroll-mouse-wheel|.
-
-These characters in the 'mouse' option tell in which situations the mouse will
-be used by Vim:
- n Normal mode
- v Visual mode
- i Insert mode
- c Command-line mode
- h all previous modes when in a help file
- a all previous modes
- r for |hit-enter| prompt
-
-If you only want to use the mouse in a few modes or also want to use it for
-the two questions you will have to concatenate the letters for those modes.
-For example: >
- :set mouse=nv
-Will make the mouse work in Normal mode and Visual mode. >
- :set mouse=h
-Will make the mouse work in help files only (so you can use "g<LeftMouse>" to
-jump to tags).
-
-Whether the selection that is started with the mouse is in Visual mode or
-Select mode depends on whether "mouse" is included in the 'selectmode'
-option.
-
-In an xterm, with the currently active mode included in the 'mouse' option,
-normal mouse clicks are used by Vim, mouse clicks with the shift or ctrl key
-pressed go to the xterm. With the currently active mode not included in
-'mouse' all mouse clicks go to the xterm.
-
- *xterm-clipboard*
-The middle mouse button will insert the unnamed register. In that case, here
-is how you copy and paste a piece of text:
-
-Copy/paste with the mouse and Visual mode ('mouse' option must be set, see
-above):
-1. Press left mouse button on first letter of text, move mouse pointer to last
- letter of the text and release the button. This will start Visual mode and
- highlight the selected area.
-2. Press "y" to yank the Visual text in the unnamed register.
-3. Click the left mouse button at the insert position.
-4. Click the middle mouse button.
-
-Shortcut: If the insert position is on the screen at the same time as the
-Visual text, you can do 2, 3 and 4 all in one: Click the middle mouse button
-at the insert position.
-
- *xterm-copy-paste*
-NOTE: In some (older) xterms, it's not possible to move the cursor past column
-95 or 223. This is an xterm problem, not Vim's. Get a newer xterm
-|color-xterm|.
-
-Copy/paste in xterm with (current mode NOT included in 'mouse'):
-1. Press left mouse button on first letter of text, move mouse pointer to last
- letter of the text and release the button.
-2. Use normal Vim commands to put the cursor at the insert position.
-3. Press "a" to start Insert mode.
-4. Click the middle mouse button.
-5. Press ESC to end Insert mode.
-(The same can be done with anything in 'mouse' if you keep the shift key
-pressed while using the mouse.)
-
-Note: if you lose the 8th bit when pasting (special characters are translated
-into other characters), you may have to do "stty cs8 -istrip -parenb" in your
-shell before starting Vim.
-
-Thus in an xterm the shift and ctrl keys cannot be used with the mouse. Mouse
-commands requiring the CTRL modifier can be simulated by typing the "g" key
-before using the mouse:
- "g<LeftMouse>" is "<C-LeftMouse> (jump to tag under mouse click)
- "g<RightMouse>" is "<C-RightMouse> ("CTRL-T")
-
*bracketed-paste-mode*
-Bracketed paste mode allows terminal applications to distinguish between typed
-text and pasted text. Thus you can paste text without Nvim trying to format or
-indent the text. See also https://cirw.in/blog/bracketed-paste
-
-Nvim enables bracketed paste by default. If it does not work in your terminal,
-try the 'paste' option instead.
+Nvim enables bracketed paste by default. Bracketed paste mode allows terminal
+applications to distinguish between typed text and pasted text. Thus you can
+paste text without Nvim trying to format or indent the text.
+See also https://cirw.in/blog/bracketed-paste
*mouse-mode-table* *mouse-overview*
-A short overview of what the mouse buttons do, when 'mousemodel' is "extend":
+Overview of what the mouse buttons do, when 'mousemodel' is "extend":
Normal Mode:
event position selection change action ~
@@ -451,14 +375,6 @@ In Insert mode, when a selection is started, Vim goes into Normal mode
temporarily. When Visual or Select mode ends, it returns to Insert mode.
This is like using CTRL-O in Insert mode. Select mode is used when the
'selectmode' option contains "mouse".
- *drag-status-line*
-When working with several windows, the size of the windows can be changed by
-dragging the status line with the mouse. Point the mouse at a status line,
-press the left button, move the mouse to the new position of the status line,
-release the button. Just clicking the mouse in a status line makes that window
-the current window, without moving the cursor. If by selecting a window it
-will change position or size, the dragging of the status line will look
-confusing, but it will work (just try it).
*<MiddleRelease>* *<MiddleDrag>*
Mouse clicks can be mapped. The codes for mouse clicks are:
diff --git a/runtime/doc/tips.txt b/runtime/doc/tips.txt
index 011e0f0565..1362b730b7 100644
--- a/runtime/doc/tips.txt
+++ b/runtime/doc/tips.txt
@@ -446,4 +446,4 @@ A slightly more advanced version is used in the |matchparen| plugin.
autocmd InsertEnter * match none
<
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/uganda.txt b/runtime/doc/uganda.txt
index cdd677cbd5..97a67befb9 100644
--- a/runtime/doc/uganda.txt
+++ b/runtime/doc/uganda.txt
@@ -281,4 +281,4 @@ Address to send checks to:
This address is expected to be valid for a long time.
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/ui.txt b/runtime/doc/ui.txt
index 3ce8ac1d89..c021f236c8 100644
--- a/runtime/doc/ui.txt
+++ b/runtime/doc/ui.txt
@@ -16,19 +16,23 @@ RPC API. The UI model consists of a terminal-like grid with a single,
monospace font size. Some elements (UI "widgets") can be drawn separately from
the grid ("externalized").
+
*ui-options*
-After connecting to Nvim (usually a spawned, embedded instance) use the
-|nvim_ui_attach| API method to tell Nvim that your program wants to draw the
-Nvim screen grid with a size of width × height cells. `options` must be
+The |nvim_ui_attach()| API method is used to tell Nvim that your program wants to
+draw the Nvim screen grid with a size of width × height cells. This is typically
+done by an embedder, see |ui-startup| below for details, but an UI can also
+connect to a running nvim instance and invoke this method. `options` must be
a dictionary with these (optional) keys:
- `rgb` Decides the color format.
+ `rgb` Decides the color format. *ui-rgb*
Set true (default) for 24-bit RGB colors.
Set false for terminal colors (max of 256).
*ui-ext-options*
`ext_popupmenu` Externalize the popupmenu. |ui-popupmenu|
`ext_tabline` Externalize the tabline. |ui-tabline|
`ext_cmdline` Externalize the cmdline. |ui-cmdline|
- `ext_wildmenu` Externalize the wildmenu. |ui-ext-wildmenu|
+ `ext_wildmenu` Externalize the wildmenu. |ui-wildmenu|
+ `ext_linegrid` Use new revision of the grid events. |ui-linegrid|
+ `ext_hlstate` Use detailed highlight state. |ui-hlstate|
Specifying a non-existent option is an error. UIs can check the |api-metadata|
`ui_options` key for supported options. Additionally Nvim (currently) requires
@@ -41,28 +45,74 @@ Nvim sends msgpack-rpc notifications to all attached UIs, with method name
Each update event is itself an array whose first element is the event name and
remaining elements are event-parameter tuples. This allows multiple events of
the same kind to be sent in a row without the event name being repeated. This
-batching is mostly used for "put", because each "put" event puts contents in
-one screen cell, but clients must be prepared for multiple argument sets being
-batched for all event kinds.
-
-Events must be handled in-order. The user should only see the updated screen
-state after all events in the same "redraw" batch are processed (not any
-intermediate state after processing only part of the array).
-
-Nvim sends |ui-global| and |ui-grid| events unconditionally; these suffice to
-implement a terminal-like layout.
+batching is mostly used for "grid_line", because each "grid_line" event puts
+contents in one screen line, but clients must be prepared for multiple argument
+sets being batched for all event kinds.
+
+Events must be handled in-order. A "flush" event is sent when nvim is done
+redrawing the entire screen (so that all windows have a consistent view of
+buffer state, options etc). Clients should be prepared that several "redraw"
+batches are sent before the entire screen has been redrawn, and only the last
+batch will end in "flush". The user should only see the final state when
+"flush" is sent, and not any intermediate state after processing only part of
+the batch array, nor after a batch not ending with "flush".
+
+By default, Nvim sends |ui-global| and |ui-grid-old| events; these suffice to
+implement a terminal-like interface. However there are two revisions of the
+grid part of the protocol. The newer revision |ui-linegrid|, enabled by
+`ext_linegrid` option, has a more effecient representation of text (especially
+highlighted text), and room for futher enhancements that will use
+multiple grids. The older revision is available and used by default only for
+backwards compatibility reasons. New UIs are strongly recommended to use
+|ui-linegrid|, as further protocol extensions will require it.
Nvim optionally sends screen elements "semantically" as structured events
instead of raw grid-lines, controlled by |ui-ext-options|. The UI must present
-those elements itself; Nvim will not draw those elements on the |ui-grid|.
+those elements itself; Nvim will not draw those elements on the grid.
Future versions of Nvim may add new update kinds and may append new parameters
to existing update kinds. Clients must be prepared to ignore such extensions,
for forward-compatibility. |api-contract|
==============================================================================
+UI startup *ui-startup*
+
+Nvim defines a standard procedure for how an embedding UI should interact with
+the startup phase of Nvim. When spawning the nvim process, use the |--embed| flag
+but not the |--headless| flag. The started Nvim process will pause before loading
+startup files and reading buffers, and give the UI a chance to invoke requests
+to do early initialization. As soon as the UI invokes |nvim_ui_attach()|, the
+startup will continue.
+
+A simple UI only need to do a single |nvim_ui_attach()| request and then
+be prepared to handle any UI event. A more featureful UI, which might need
+additional configuration of the nvim process, should use the following startup
+procedure:
+
+1. Invoke |nvim_get_api_info()|, if this is needed to setup the client library
+ and/or to get the list of supported UI extensions.
+2. At this time, any configuration that should be happen before init.vim
+ loading should be done. Buffers and windows are not available at this
+ point, but this could be used to set |g:| variables visible to init.vim
+3. If the UI wants to do additional setup after the init.vim file was loaded
+ register an autocmd for VimEnter at this point: >
+
+ nvim_command("autocmd VimEnter * call rpcrequest(1, 'vimenter')")
+
+<4. Now invoke |nvim_ui_attach()|. The UI will need to handle keyboard input
+ at this point, as sourcing init.vim and loading buffers might lead to
+ blocking prompts.
+5. If step 3 was used, nvim will send a blocking "vimenter" request to the
+ UI. Inside this request handler, the UI can safely do any initialization
+ before entering normal mode, for instance reading variables set by
+ init.vim.
+
+==============================================================================
Global Events *ui-global*
+The following events will always be available, and describe global state of
+the editor.
+
["set_title", title]
["set_icon", icon]
Set the window title, and icon (minimized) window title, respectively.
@@ -81,13 +131,18 @@ Global Events *ui-global*
`cursor_shape`: "block", "horizontal", "vertical"
`cell_percentage`: Cell % occupied by the cursor.
`blinkwait`, `blinkon`, `blinkoff`: See |cursor-blinking|.
- `hl_id`: Cursor highlight group.
- `hl_lm`: Cursor highlight group if 'langmap' is active.
+ `attr_id`: Cursor attribute id (defined by `hl_attr_define`)
+ `attr_id_lm`: Cursor attribute id for when 'langmap' is active.
`short_name`: Mode code name, see 'guicursor'.
`name`: Mode descriptive name.
`mouse_shape`: (To be implemented.)
Some keys are missing in some modes.
+
+ The following keys are deprecated:
+
+ `hl_id`: Use `attr_id` instead.
+ `hl_lm`: Use `attr_id_lm` instead.
["option_set", name, value]
UI-related option changed, where `name` is one of:
@@ -112,7 +167,7 @@ Global Events *ui-global*
mouse support is active. Some options like 'ambiwidth' have already
taken effect on the grid, where appropriate empty cells are added,
however a UI might still use such options when rendering raw text
- sent from Nvim, like for |ui-ext-cmdline|.
+ sent from Nvim, like for |ui-cmdline|.
["mode_change", mode, mode_idx]
The mode changed. The first parameter `mode` is a string representing
@@ -131,15 +186,15 @@ Global Events *ui-global*
would conflict with other usages of the mouse. It is safe for a client
to ignore this and always send mouse events.
-["busy_on"]
-["busy_off"]
+["busy_start"]
+["busy_stop"]
Nvim started or stopped being busy, and possibly not responsive to
user input. This could be indicated to the user by hiding the cursor.
["suspend"]
- |:suspend| command or |Ctrl-Z| mapping is used. A terminal client (or other
- client where it makes sense) could suspend itself. Other clients can
- safely ignore it.
+ |:suspend| command or |CTRL-Z| mapping is used. A terminal client (or
+ another client where it makes sense) could suspend itself. Other
+ clients can safely ignore it.
["update_menu"]
The menu mappings changed.
@@ -148,8 +203,160 @@ Global Events *ui-global*
["visual_bell"]
Notify the user with an audible or visual bell, respectively.
+["flush"]
+ Nvim is done redrawing the screen. For an implementation that renders
+ to an internal buffer, this is the time to display the redrawn parts
+ to the user.
+
+==============================================================================
+Grid Events (line-based) *ui-linegrid*
+
+These events are used if `ext_linegrid` option is set (recommended for all new
+UIs). The biggest change compared to previous revision is to use a single
+event `grid_line` to update the contents of a screen line (where the old
+protocol used a combination of cursor, highlight and text events)
+
+Most of these events take a `grid` index as first parameter. Grid 1 is the
+global grid used by default for the entire editor screen state. Grids other
+than that will be defined by future extensions. Just activating the
+`ext_linegrid` option by itself will never cause any additional grids to be
+created.
+
+Highlight attribute groups are predefined. UIs should maintain a table to map
+numerical highlight `id`:s to the actual attributes.
+
+["grid_resize", grid, width, height]
+ Resize a `grid`. If `grid` wasn't seen by the client before, a new grid is
+ being created with this size.
+
+["default_colors_set", rgb_fg, rgb_bg, rgb_sp, cterm_fg, cterm_bg]
+ The first three arguments set the default foreground, background and
+ special colors respectively. `cterm_fg` and `cterm_bg` specifies the
+ default color codes to use in a 256-color terminal.
+
+ Note: unlike the corresponding events in the first revision, the
+ screen is not always cleared after sending this event. The GUI has to
+ repaint the screen with changed background color itself.
+
+ *ui-event-hl_attr_define*
+["hl_attr_define", id, rgb_attr, cterm_attr, info]
+ Add a highlight with `id` to the highlight table, with the
+ attributes specified by the `rgb_attr` and `cterm_attr` dicts, with the
+ following (all optional) keys.
+
+ `foreground`: foreground color.
+ `background`: background color.
+ `special`: color to use for underline and undercurl, when present.
+ `reverse`: reverse video. Foreground and background colors are
+ switched.
+ `italic`: italic text.
+ `bold`: bold text.
+ `underline`: underlined text. The line has `special` color.
+ `undercurl`: undercurled text. The curl has `special` color.
+
+ For absent color keys the default color should be used. Don't store
+ the default value in the table, rather a sentinel value, so that
+ a changed default color will take effect.
+ All boolean keys default to false, and will only be sent when they
+ are true.
+
+ Highlights are always transmitted both for both the rgb format and as
+ terminal 256-color codes, as the `rgb_attr` and `cterm_attr` parameters
+ respectively. The |ui-rgb| option has no effect effect anymore.
+ Most external UIs will only need to store and use the `rgb_attr`
+ attributes.
+
+ `id` 0 will always be used for the default highlight with colors defined
+ by `default_colors_set` and no styles applied.
+
+ Note: `id`:s can be reused if Nvim's internal highlight table is full.
+ In this case, Nvim will always issue redraws of screen cells that are
+ affected by redefined `id`:s, so UIs do not need to keep track of this
+ themselves.
+
+ `info` is an empty array per default, and will be used by the
+ |ui-hlstate| extension explaned below.
+
+ *ui-event-grid_line*
+["grid_line", grid, row, col_start, cells]
+ Redraw a continous part of a `row` on a `grid`, starting at the column
+ `col_start`. `cells` is an array of arrays each with 1 to 3 items:
+ `[text(, hl_id, repeat)]` . `text` is the UTF-8 text that should be put in
+ a cell, with the highlight `hl_id` defined by a previous `hl_attr_define`
+ call. If `hl_id` is not present the most recently seen `hl_id` in
+ the same call should be used (it is always sent for the first
+ cell in the event). If `repeat` is present, the cell should be
+ repeated `repeat` times (including the first time), otherwise just
+ once.
+
+ The right cell of a double-width char will be represented as the empty
+ string. Double-width chars never use `repeat`.
+
+ If the array of cell changes doesn't reach to the end of the line, the
+ rest should remain unchanged. A whitespace char, repeated
+ enough to cover the remaining line, will be sent when the rest of the
+ line should be cleared.
+
+["grid_clear", grid]
+ Clear a `grid`.
+
+["grid_destroy", grid]
+ `grid` will not be used anymore and the UI can free any data associated
+ with it.
+
+["grid_cursor_goto", grid, row, column]
+ Makes `grid` the current grid and `row, column` the cursor position on this
+ grid. This event will be sent at most once in a `redraw` batch and
+ indicates the visible cursor position.
+
+["grid_scroll", grid, top, bot, left, right, rows, cols]
+ Scroll the text in the a region of `grid`. The diagrams below illustrate
+ what will happen, depending on the scroll direction. "=" is used to
+ represent the SR(scroll region) boundaries and "-" the moved rectangles.
+ Note that dst and src share a common region.
+
+ If `rows` is bigger than 0, move a rectangle in the SR up, this can
+ happen while scrolling down.
+>
+ +-------------------------+
+ | (clipped above SR) | ^
+ |=========================| dst_top |
+ | dst (still in SR) | |
+ +-------------------------+ src_top |
+ | src (moved up) and dst | |
+ |-------------------------| dst_bot |
+ | src (invalid) | |
+ +=========================+ src_bot
+<
+ If `rows` is less than zero, move a rectangle in the SR down, this can
+ happen while scrolling up.
+>
+ +=========================+ src_top
+ | src (invalid) | |
+ |------------------------ | dst_top |
+ | src (moved down) and dst| |
+ +-------------------------+ src_bot |
+ | dst (still in SR) | |
+ |=========================| dst_bot |
+ | (clipped below SR) | v
+ +-------------------------+
+<
+ `cols` is always zero in this version of Nvim, and reserved for future
+ use.
+
+ Note when updating code from |ui-grid-old| events: ranges are
+ end-exclusive, which is consistent with API conventions, but different
+ from `set_scroll_region` which was end-inclusive.
+
+ The scrolled-in area will be filled using |ui-event-grid_line| directly
+ after the scroll event. The UI thus doesn't need to clear this area as
+ part of handling the scroll event.
+
==============================================================================
-Grid Events *ui-grid*
+Legacy Grid Events (cell based) *ui-grid-old*
+
+This is an older representation of the screen grid, used if `ext_linegrid`
+option is not set. New UIs should use |ui-linegrid|.
["resize", width, height]
The grid is resized to `width` and `height` cells.
@@ -173,7 +380,7 @@ Grid Events *ui-grid*
Set the default foreground, background and special colors
respectively.
- *ui-event-highlight_set*
+ *ui-event-highlight_set*
["highlight_set", attrs]
Set the attributes that the next text put on the grid will have.
`attrs` is a dict with the keys below. Any absent key is reset
@@ -197,6 +404,9 @@ Grid Events *ui-grid*
["set_scroll_region", top, bot, left, right]
Define the scroll region used by `scroll` below.
+
+ Note: ranges are end-inclusive, which is inconsistent with API
+ conventions.
["scroll", count]
Scroll the text in the scroll region. The diagrams below illustrate
@@ -231,6 +441,41 @@ Grid Events *ui-grid*
+-------------------------+
<
==============================================================================
+Detailed highlight state Extension *ui-hlstate*
+
+Only sent if `ext_hlstate` option is set in |ui-options|. `ext_hlstate` implies
+`ext_linegrid`.
+
+By default, nvim will only describe grid cells using the final calculated
+higlight attributes, as described by the dict keys in |ui-event-highlight_set|.
+The `ext_hlstate` extension allows to the UI to also receive a semantic
+describtion of the higlights active in a cell. In this mode highlights will be
+predefined in a table, see |ui-event-hl_attr_define| and |ui-event-grid_line|.
+The `info` parameter in `hl_attr_define` will contain a semantic description
+of the highlights. As highlight groups can be combined, this will be an array
+of items, with the item with highest priority last. Each item is a dictionary
+with the following possible keys:
+
+ `kind`: always present. One of the following values:
+ "ui": A builtin ui highlight.
+ "syntax": highlight applied to a buffer by a syntax declaration or
+ other runtime/plugin functionallity such as
+ |nvim_buf_add_highlight()|
+ "terminal": highlight from a process running in a |terminal-emulator|.
+ Contains no futher semantic information.
+ `ui_name`: Name of the builtin highlight. See |highlight-groups| for
+ possible values. Only present for "ui".
+ `hi_name`: Name of the final |:highlight| group where the used
+ attributes are defined.
+ `id`: Unique numeric id representing this item.
+
+Note: "ui" items will have both `ui_name` and `hi_name` present. These can
+differ, because the builtin group was linked to another group |:hi-link| , or
+because 'winhighlight' was used. UI items will be transmitted, even if the
+highlight group is cleared, so `ui_name` can always be used to reliably identify
+screen elements, even if no attributes have been applied.
+
+==============================================================================
Popupmenu Events *ui-popupmenu*
Only sent if `ext_popupmenu` option is set in |ui-options|
@@ -288,7 +533,7 @@ Only sent if `ext_cmdline` option is set in |ui-options|
typing `<c-r>=` at the command line prompt. The `level` field is used
to distinguish different command lines active at the same time. The
first invoked command line has level 1, the next recursively-invoked
- prompt has level 2. A command line invoked from the |cmd-line-window|
+ prompt has level 2. A command line invoked from the |cmdline-window|
has a higher level than than the edited command line.
["cmdline_pos", pos, level]
diff --git a/runtime/doc/undo.txt b/runtime/doc/undo.txt
index f8f6049119..a500e87e35 100644
--- a/runtime/doc/undo.txt
+++ b/runtime/doc/undo.txt
@@ -383,4 +383,4 @@ if it is not what you want do 'u.'. This will remove the contents of the
first put, and repeat the put command for the second register. Repeat the
'u.' until you got what you want.
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_01.txt b/runtime/doc/usr_01.txt
index bc55e7cdce..3deaf181e5 100644
--- a/runtime/doc/usr_01.txt
+++ b/runtime/doc/usr_01.txt
@@ -68,9 +68,9 @@ For more info see |vimrc|.
==============================================================================
*01.3* Using the Vim tutor *tutor* *vimtutor*
-Instead of reading the text (boring!) you can use the vimtutor to learn your
-first Vim commands. This is a 30 minute tutorial that teaches the most basic
-Vim functionality hands-on.
+Instead of reading the text (boring!) you can use :Tutor to learn your first
+Vim commands. This is a 30 minute tutorial that teaches the most basic Vim
+functionality hands-on.
To start the tutorial, execute >
@@ -109,4 +109,4 @@ donate part of the profit to help AIDS victims in Uganda. See |iccf|.
Next chapter: |usr_02.txt| The first steps in Vim
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_02.txt b/runtime/doc/usr_02.txt
index a1e3d606ec..9ebbd11ac7 100644
--- a/runtime/doc/usr_02.txt
+++ b/runtime/doc/usr_02.txt
@@ -687,4 +687,4 @@ Summary: *help-summary* >
Next chapter: |usr_03.txt| Moving around
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_03.txt b/runtime/doc/usr_03.txt
index 989914687f..2649534900 100644
--- a/runtime/doc/usr_03.txt
+++ b/runtime/doc/usr_03.txt
@@ -650,4 +650,4 @@ You will notice a few special marks. These include:
Next chapter: |usr_04.txt| Making small changes
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_04.txt b/runtime/doc/usr_04.txt
index e02a50e494..a327a09a71 100644
--- a/runtime/doc/usr_04.txt
+++ b/runtime/doc/usr_04.txt
@@ -511,4 +511,4 @@ else:
Next chapter: |usr_05.txt| Set your settings
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_05.txt b/runtime/doc/usr_05.txt
index d1491e6b31..af17d75656 100644
--- a/runtime/doc/usr_05.txt
+++ b/runtime/doc/usr_05.txt
@@ -317,14 +317,13 @@ when you use Vim. There are only two steps for adding a global plugin:
GETTING A GLOBAL PLUGIN
Where can you find plugins?
+- Some are always loaded, you can see them in the directory $VIMRUNTIME/plugin.
- Some come with Vim. You can find them in the directory $VIMRUNTIME/macros
- and its sub-directories.
+ and its sub-directories and under $VIM/vimfiles/pack/dist/opt/.
- Download from the net. There is a large collection on http://www.vim.org.
-- They are sometimes posted in a Vim |maillist|.
+- They are sometimes posted in a Vim maillist.
- You could write one yourself, see |write-plugin|.
-Some plugins come as a vimball archive, see |vimball|.
-
USING A GLOBAL PLUGIN
@@ -611,4 +610,4 @@ This does mean there is less room to edit text, thus it's a compromise.
Next chapter: |usr_06.txt| Using syntax highlighting
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_06.txt b/runtime/doc/usr_06.txt
index 48f672be78..beffb92877 100644
--- a/runtime/doc/usr_06.txt
+++ b/runtime/doc/usr_06.txt
@@ -274,4 +274,4 @@ others look at the colored text.
Next chapter: |usr_07.txt| Editing more than one file
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_07.txt b/runtime/doc/usr_07.txt
index 683c9879a7..c44a54d76c 100644
--- a/runtime/doc/usr_07.txt
+++ b/runtime/doc/usr_07.txt
@@ -476,4 +476,4 @@ This protects you from accidentally overwriting another file.
Next chapter: |usr_08.txt| Splitting windows
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_08.txt b/runtime/doc/usr_08.txt
index ef91bf9c0a..559ca6f1ef 100644
--- a/runtime/doc/usr_08.txt
+++ b/runtime/doc/usr_08.txt
@@ -597,4 +597,4 @@ For more information about tab pages see |tab-page|.
Next chapter: |usr_09.txt| Using the GUI
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_09.txt b/runtime/doc/usr_09.txt
index f53076a2ec..757d13e0f3 100644
--- a/runtime/doc/usr_09.txt
+++ b/runtime/doc/usr_09.txt
@@ -5,9 +5,10 @@
Using the GUI
-Vim works in an ordinary terminal. GVim can do the same things and a few
-more. The GUI offers menus, a toolbar, scrollbars and other items. This
-chapter is about these extra things that the GUI offers.
+Vim works in an ordinary terminal, while gVim has a Graphical User Interface
+(GUI). It can do the same things and a few more. The GUI offers menus, a
+toolbar, scrollbars and other items. This chapter is about these extra things
+that the GUI offers.
|09.1| Parts of the GUI
|09.2| Using the mouse
@@ -282,4 +283,4 @@ You can tune the way Select mode works with the 'selectmode' option.
Next chapter: |usr_10.txt| Making big changes
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_10.txt b/runtime/doc/usr_10.txt
index 044cb1582b..3646786052 100644
--- a/runtime/doc/usr_10.txt
+++ b/runtime/doc/usr_10.txt
@@ -820,4 +820,4 @@ has written. To tell Vim to redraw the screen: >
Next chapter: |usr_11.txt| Recovering from a crash
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_11.txt b/runtime/doc/usr_11.txt
index 42aa1d9100..e5591ac1d1 100644
--- a/runtime/doc/usr_11.txt
+++ b/runtime/doc/usr_11.txt
@@ -234,7 +234,7 @@ that file, be prepared to redo your last changes.
WHAT TO DO? *swap-exists-choices*
-If dialogs are supported you will be asked to select one of five choices:
+If dialogs are supported you will be asked to select one of six choices:
Swap file ".main.c.swp" already exists! ~
[O]pen Read-Only, (E)dit anyway, (R)ecover, (Q)uit, (A)bort, (D)elete it: ~
@@ -283,6 +283,8 @@ machines. Therefore, don't rely on Vim always warning you.
If you really don't want to see this message, you can add the 'A' flag to the
'shortmess' option. But it's very unusual that you need this.
+For programatic access to the swap file, see |swapinfo()|.
+
==============================================================================
*11.4* Further reading
@@ -299,4 +301,4 @@ If you really don't want to see this message, you can add the 'A' flag to the
Next chapter: |usr_12.txt| Clever tricks
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_12.txt b/runtime/doc/usr_12.txt
index e87ed81c97..21efa36a25 100644
--- a/runtime/doc/usr_12.txt
+++ b/runtime/doc/usr_12.txt
@@ -343,4 +343,4 @@ matches and where they are.
Next chapter: |usr_20.txt| Typing command-line commands quickly
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_20.txt b/runtime/doc/usr_20.txt
index 3b8eeae175..8eee7aedb7 100644
--- a/runtime/doc/usr_20.txt
+++ b/runtime/doc/usr_20.txt
@@ -381,4 +381,4 @@ there can be only one.
Next chapter: |usr_21.txt| Go away and come back
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_21.txt b/runtime/doc/usr_21.txt
index cfb8c90027..99a78e7b05 100644
--- a/runtime/doc/usr_21.txt
+++ b/runtime/doc/usr_21.txt
@@ -488,4 +488,4 @@ For more details see |modeline|.
Next chapter: |usr_22.txt| Finding the file to edit
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_22.txt b/runtime/doc/usr_22.txt
index 255211f668..96fc02aaa5 100644
--- a/runtime/doc/usr_22.txt
+++ b/runtime/doc/usr_22.txt
@@ -397,4 +397,4 @@ can't be editing nothing!
Next chapter: |usr_23.txt| Editing other files
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_23.txt b/runtime/doc/usr_23.txt
index cb776d2b5c..810da05ff8 100644
--- a/runtime/doc/usr_23.txt
+++ b/runtime/doc/usr_23.txt
@@ -256,4 +256,4 @@ decompression. You might need to install the programs first.
Next chapter: |usr_24.txt| Inserting quickly
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_24.txt b/runtime/doc/usr_24.txt
index b74ed879e0..3c4ff6f55e 100644
--- a/runtime/doc/usr_24.txt
+++ b/runtime/doc/usr_24.txt
@@ -538,8 +538,8 @@ a 16 bit and a 32 bit number (e.g., for a Unicode character): >
*24.9* Digraphs
Some characters are not on the keyboard. For example, the copyright character
-(). To type these characters in Vim, you use digraphs, where two characters
-represent one. To enter a , for example, you press three keys: >
+(©). To type these characters in Vim, you use digraphs, where two characters
+represent one. To enter a ©, for example, you press three keys: >
CTRL-K Co
@@ -549,12 +549,12 @@ To find out what digraphs are available, use the following command: >
Vim will display the digraph table. Here are three lines of it:
- AC ~_ 159 NS | 160 !I 161 Ct 162 Pd 163 Cu 164 Ye 165 ~
- BB 166 SE 167 ': 168 Co 169 -a 170 << 171 NO 172 ~
- -- 173 Rg 174 'm 175 DG 176 +- 177 2S 178 3S 179 ~
+ AC ~_ 159 NS | 160 !I ¡ 161 Ct ¢ 162 Pd £ 163 Cu ¤ 164 Ye ¥ 165 ~
+ BB ¦ 166 SE § 167 ': ¨ 168 Co © 169 -a ª 170 << « 171 NO ¬ 172 ~
+ -- ­ 173 Rg ® 174 'm ¯ 175 DG ° 176 +- ± 177 2S ² 178 3S ³ 179 ~
This shows, for example, that the digraph you get by typing CTRL-K Pd is the
-character (). This is character number 163 (decimal).
+character (£). This is character number 163 (decimal).
Pd is short for Pound. Most digraphs are selected to give you a hint about
the character they will produce. If you look through the list you will
understand the logic.
@@ -569,9 +569,9 @@ that combination. Thus CTRL-K dP also works. Since there is no digraph for
You can define your own digraphs. Example: >
- :digraph a"
+ :digraph a" ä
-This defines that CTRL-K a" inserts an character. You can also specify the
+This defines that CTRL-K a" inserts an ä character. You can also specify the
character with a decimal number. This defines the same digraph: >
:digraph a" 228
@@ -603,4 +603,4 @@ This deletes up to the third word into register g.
Next chapter: |usr_25.txt| Editing formatted text
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_25.txt b/runtime/doc/usr_25.txt
index ae3d3c4422..3a58af6412 100644
--- a/runtime/doc/usr_25.txt
+++ b/runtime/doc/usr_25.txt
@@ -579,4 +579,4 @@ The "gR" command uses Virtual Replace mode. This preserves the layout:
Next chapter: |usr_26.txt| Repeating
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_26.txt b/runtime/doc/usr_26.txt
index 7b0b940da2..4e8f1979f4 100644
--- a/runtime/doc/usr_26.txt
+++ b/runtime/doc/usr_26.txt
@@ -207,4 +207,4 @@ start all over, use the "-W" argument. It overwrites any existing file.
Next chapter: |usr_27.txt| Search commands and patterns
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_27.txt b/runtime/doc/usr_27.txt
index afea67bd0b..cd01308c6e 100644
--- a/runtime/doc/usr_27.txt
+++ b/runtime/doc/usr_27.txt
@@ -225,9 +225,9 @@ specify a line offset, this can cause trouble. For example: >
/const/-2
This finds the next word "const" and then moves two lines up. If you
-use "n" to search again, Vim could start at the current position and find the same
-"const" match. Then using the offset again, you would be back where you started.
-You would be stuck!
+use "n" to search again, Vim could start at the current position and find the
+same "const" match. Then using the offset again, you would be back where you
+started. You would be stuck!
It could be worse: Suppose there is another match with "const" in the next
line. Then repeating the forward search would find this match and move two
lines up. Thus you would actually move the cursor back!
@@ -560,4 +560,4 @@ and "\w" for "[0-9A-Za-z_]".
Next chapter: |usr_28.txt| Folding
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_28.txt b/runtime/doc/usr_28.txt
index 24e995d9ab..86aa20597e 100644
--- a/runtime/doc/usr_28.txt
+++ b/runtime/doc/usr_28.txt
@@ -423,4 +423,4 @@ the defined folds. Then you can delete or add folds manually.
Next chapter: |usr_29.txt| Moving through programs
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_29.txt b/runtime/doc/usr_29.txt
index b0cb9d7e88..3381d1870c 100644
--- a/runtime/doc/usr_29.txt
+++ b/runtime/doc/usr_29.txt
@@ -608,4 +608,4 @@ for the identifier. Example (cursor on "idx"):
Next chapter: |usr_30.txt| Editing programs
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_30.txt b/runtime/doc/usr_30.txt
index 786f2d1800..b729c7a263 100644
--- a/runtime/doc/usr_30.txt
+++ b/runtime/doc/usr_30.txt
@@ -640,4 +640,4 @@ For more details see |format-comments|.
Next chapter: |usr_31.txt| Exploiting the GUI
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_31.txt b/runtime/doc/usr_31.txt
index 2354e27b42..fb9a4fd223 100644
--- a/runtime/doc/usr_31.txt
+++ b/runtime/doc/usr_31.txt
@@ -269,4 +269,4 @@ another font size, for example.
Next chapter: |usr_32.txt| The undo tree
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_32.txt b/runtime/doc/usr_32.txt
index fca802872d..8b489ea1e0 100644
--- a/runtime/doc/usr_32.txt
+++ b/runtime/doc/usr_32.txt
@@ -177,4 +177,4 @@ use the |undotree()| function. To see what it returns: >
Next chapter: |usr_40.txt| Make new commands
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_40.txt b/runtime/doc/usr_40.txt
index 4092af703e..e5d55fb857 100644
--- a/runtime/doc/usr_40.txt
+++ b/runtime/doc/usr_40.txt
@@ -654,4 +654,4 @@ To set it back to the normal behavior, make 'eventignore' empty: >
Next chapter: |usr_41.txt| Write a Vim script
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_41.txt b/runtime/doc/usr_41.txt
index 51d8143440..4adb69aaee 100644
--- a/runtime/doc/usr_41.txt
+++ b/runtime/doc/usr_41.txt
@@ -882,9 +882,11 @@ Interactive: *interactive-functions*
GUI: *gui-functions*
getfontname() get name of current font being used
- getwinposx() X position of the GUI Vim window
- getwinposy() Y position of the GUI Vim window
+ getwinpos() position of the Vim window
+ getwinposx() X position of the Vim window
+ getwinposy() Y position of the Vim window
balloon_show() set the balloon content
+ balloon_split() split a message for a balloon
Vim server: *server-functions*
serverlist() return the list of server names
@@ -900,6 +902,7 @@ Vim server: *server-functions*
Window size and position: *window-size-functions*
winheight() get height of a specific window
winwidth() get width of a specific window
+ win_screenpos() get screen position of a window
winrestcmd() return command to restore window sizes
winsaveview() get view of current window
winrestview() restore saved view of current window
@@ -919,7 +922,8 @@ Testing: *test-functions*
assert_false() assert that an expression is false
assert_true() assert that an expression is true
assert_exception() assert that a command throws an exception
- assert_fails() assert that a function call fails
+ assert_beeps() assert that a command beeps
+ assert_fails() assert that a command fails
Timers: *timer-functions*
timer_start() create a timer
@@ -2506,11 +2510,8 @@ Vim scripts can be used on any system. There might not be a tar or gzip
command. If you want to pack files together and/or compress them the "zip"
utility is recommended.
-For utmost portability use Vim itself to pack scripts together. This can be
-done with the Vimball utility. See |vimball|.
-
==============================================================================
Next chapter: |usr_42.txt| Add new menus
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_42.txt b/runtime/doc/usr_42.txt
index ad04555f8c..501f02e745 100644
--- a/runtime/doc/usr_42.txt
+++ b/runtime/doc/usr_42.txt
@@ -355,4 +355,4 @@ is...
Next chapter: |usr_43.txt| Using filetypes
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_43.txt b/runtime/doc/usr_43.txt
index 765a525692..04e9f9c000 100644
--- a/runtime/doc/usr_43.txt
+++ b/runtime/doc/usr_43.txt
@@ -175,4 +175,4 @@ and sources a script or executes a function to check the contents of the file.
Next chapter: |usr_44.txt| Your own syntax highlighted
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_44.txt b/runtime/doc/usr_44.txt
index b06557b950..722c3de26c 100644
--- a/runtime/doc/usr_44.txt
+++ b/runtime/doc/usr_44.txt
@@ -716,4 +716,4 @@ up scrolling backwards and CTRL-L.
Next chapter: |usr_45.txt| Select your language
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_45.txt b/runtime/doc/usr_45.txt
index 9bbbe82113..be33f0be6d 100644
--- a/runtime/doc/usr_45.txt
+++ b/runtime/doc/usr_45.txt
@@ -203,8 +203,7 @@ USING UNICODE IN A UNICODE TERMINAL
There are terminals that support Unicode directly. The standard xterm that
comes with XFree86 is one of them. Let's use that as an example.
- First of all, the xterm must have been compiled with Unicode support. See
-|UTF8-xterm| how to check that and how to compile it when needed.
+ First of all, the xterm must have been compiled with Unicode support.
Start the xterm with the "-u8" argument. You might also need so specify a
font. Example: >
@@ -392,4 +391,4 @@ Don't type the spaces. See |i_CTRL-V_digit| for the details.
==============================================================================
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/usr_toc.txt b/runtime/doc/usr_toc.txt
index ed14d78d22..148dd161ac 100644
--- a/runtime/doc/usr_toc.txt
+++ b/runtime/doc/usr_toc.txt
@@ -335,4 +335,4 @@ Make Vim work as you like it.
==============================================================================
-Copyright: see |manual-copyright| vim:tw=78:ts=8:ft=help:norl:
+Copyright: see |manual-copyright| vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/various.txt b/runtime/doc/various.txt
index 2a9a181b7a..5f40ccf2ec 100644
--- a/runtime/doc/various.txt
+++ b/runtime/doc/various.txt
@@ -37,23 +37,34 @@ CTRL-L Clear and redraw the screen. The redraw may happen
<
:as[cii] or *ga* *:as* *:ascii*
ga Print the ascii value of the character under the
- cursor in decimal, hexadecimal and octal. For
- example, when the cursor is on a 'R':
+ cursor in decimal, hexadecimal and octal.
+ Mnemonic: Get Ascii value.
+
+ For example, when the cursor is on a 'R':
<R> 82, Hex 52, Octal 122 ~
When the character is a non-standard ASCII character,
but printable according to the 'isprint' option, the
- non-printable version is also given. When the
- character is larger than 127, the <M-x> form is also
- printed. For example:
+ non-printable version is also given.
+
+ When the character is larger than 127, the <M-x> form
+ is also printed. For example:
<~A> <M-^A> 129, Hex 81, Octal 201 ~
<p> <|~> <M-~> 254, Hex fe, Octal 376 ~
(where <p> is a special character)
+
The <Nul> character in a file is stored internally as
<NL>, but it will be shown as:
<^@> 0, Hex 00, Octal 000 ~
+
If the character has composing characters these are
also shown. The value of 'maxcombine' doesn't matter.
- Mnemonic: Get ASCII value.
+
+ If the character can be inserted as a digraph, also
+ output the two characters that can be used to create
+ the character:
+ <ö> 246, Hex 00f6, Oct 366, Digr o: ~
+ This shows you can type CTRL-K o : to insert ö.
+
*g8*
g8 Print the hex values of the bytes used in the
@@ -370,7 +381,7 @@ T *+tag_binary* binary searching in tags file |tag-binary-search|
N *+tag_old_static* old method for static tags |tag-old-static|
m *+tag_any_white* any white space allowed in tags file |tag-any-white|
B *+termguicolors* 24-bit color in xterm-compatible terminals support
-N *+termresponse* support for |t_RV| and |v:termresponse|
+N *+termresponse* support for t_RV and |v:termresponse|
N *+textobjects* |text-objects| selection
N *+timers* the |timer_start()| function
N *+title* Setting the window 'title' and 'icon'
@@ -381,6 +392,7 @@ N *+virtualedit* |'virtualedit'|
S *+visual* Visual mode |Visual-mode| Always enabled since 7.4.200.
N *+visualextra* extra Visual mode commands |blockwise-operators|
N *+vreplace* |gR| and |gr|
+ *+vtp* on MS-Windows console: support for 'termguicolors'
N *+wildignore* |'wildignore'|
N *+wildmenu* |'wildmenu'|
*+windows* more than one window
@@ -388,7 +400,6 @@ m *+writebackup* |'writebackup'| is default on
m *+xim* X input method |xim|
*+xfontset* X fontset support |xfontset|
*+xpm* pixmap support
-m *+xpm_w32* Win32 GUI only: pixmap support |w32-xpm-support|
*/dyn* *E370* *E448*
To some of the features "/dyn" is added when the
diff --git a/runtime/doc/vi_diff.txt b/runtime/doc/vi_diff.txt
index 139cd3749a..d908f484c6 100644
--- a/runtime/doc/vi_diff.txt
+++ b/runtime/doc/vi_diff.txt
@@ -322,7 +322,7 @@ Scripts and Expressions. |expression|
Debugging and profiling are supported. |debug-scripts| |profile|
If this is not enough, an interface is provided to |Python|.
-Viminfo. |viminfo-file|
+Viminfo.
The command-line history, marks and registers can be stored in a file
that is read on startup. This can be used to repeat a search command
or command-line command after exiting and restarting Vim. It is also
@@ -363,4 +363,4 @@ Move cursor beyond lines.
and figures easily.
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/vim_diff.txt b/runtime/doc/vim_diff.txt
index 8bda114639..4fbfb0d7a0 100644
--- a/runtime/doc/vim_diff.txt
+++ b/runtime/doc/vim_diff.txt
@@ -55,6 +55,7 @@ a complete and centralized reference of those differences.
- 'smarttab' is set by default
- 'tabpagemax' defaults to 50
- 'tags' defaults to "./tags;,tags"
+- 'ttimeoutlen' defaults to 50
- 'ttyfast' is always set
- 'undodir' defaults to ~/.local/share/nvim/undo (|xdg|), auto-created
- 'viminfo' includes "!"
@@ -111,7 +112,7 @@ ARCHITECTURE ~
External plugins run in separate processes. |remote-plugin| This improves
stability and allows those plugins to work without blocking the editor. Even
-"legacy" Python and Ruby plugins which use the old Vim interfaces (|if_py| and
+"legacy" Python and Ruby plugins which use the old Vim interfaces (|if_pyth|,
|if_ruby|) run out-of-process.
Platform and I/O facilities are built upon libuv. Nvim benefits from libuv
@@ -135,6 +136,7 @@ Commands:
|:cquit| can use [count] to set the exit code
|:drop| is always available
|:Man| is available by default, with many improvements such as completion
+ |:sign-define| accepts a `numhl` argument, to highlight the line number
|:tchdir| tab-local |current-directory|
Events:
@@ -182,7 +184,7 @@ Options:
'display' flag `msgsep` to minimize scrolling when showing messages
'guicursor' works in the terminal
'fillchars' flags: `msgsep` (see 'display' above)
- and `eob` for |EndOfBuffer| marker
+ and `eob` for |hl-EndOfBuffer| marker
'inccommand' shows interactive results for |:substitute|-like commands
'scrollback'
'statusline' supports unlimited alignment sections
@@ -204,19 +206,8 @@ certain features removed/added at compile-time. |feature-compile|
If a Python interpreter is available on your `$PATH`, |:python| and |:python3|
are always available and may be used simultaneously. See |provider-python|.
-|:!| does not support "interactive" commands. Use |:terminal| instead.
-(GUI Vim has a similar limitation, see ":help gui-pty" in Vim.)
-
-:!start is not special-cased on Windows.
-
-|system()| does not support writing/reading "backgrounded" commands. |E5677|
-
|:redir| nested in |execute()| works.
-Nvim may throttle (skip) messages from shell commands (|:!|, |:grep|, |:make|)
-if there is too much output. No data is lost, this only affects display and
-makes things faster. |:terminal| output is never throttled.
-
|mkdir()| behaviour changed:
1. Assuming /tmp/foo does not exist and /tmp can be written to
mkdir('/tmp/foo/bar', 'p', 0700) will create both /tmp/foo and /tmp/foo/bar
@@ -245,7 +236,7 @@ makes things faster. |:terminal| output is never throttled.
4. Stringifyed infinite and NaN values now use |str2float()| and can be evaled
back.
5. (internal) Trying to print or stringify VAR_UNKNOWN in Vim results in
- nothing, |E908|, in Neovim it is internal error.
+ nothing, E908, in Nvim it is internal error.
|json_decode()| behaviour changed:
1. It may output |msgpack-special-dict|.
@@ -287,12 +278,11 @@ coerced to strings. See |id()| for more details, currently it uses
Lua interface (|if_lua.txt|):
-- `:lua print("a\0b")` will print `a^@b`, like with `:echomsg "a\nb"` . In Vim
+- `:lua print("a\0b")` will print `a^@b`, like with `:echomsg "a\nb"` . In Vim
that prints `a` and `b` on separate lines, exactly like
`:lua print("a\nb")` .
-- `:lua error('TEST')` will print “TEST” as the error in Vim and “E5105: Error
- while calling lua chunk: [string "<VimL compiled string>"]:1: TEST” in
- Neovim.
+- `:lua error('TEST')` emits the error “E5105: Error while calling lua chunk:
+ [string "<VimL compiled string>"]:1: TEST”, whereas Vim emits only “TEST”.
- Lua has direct access to Nvim |API| via `vim.api`.
- Lua package.path and package.cpath are automatically updated according to
'runtimepath': |lua-require|.
@@ -323,6 +313,22 @@ Normal commands:
Options:
'ttimeout', 'ttimeoutlen' behavior was simplified
+Shell:
+ Shell output (|:!|, |:make|, …) is always routed through the UI, so it
+ cannot "mess up" the screen. (You can still use "chansend(v:stderr,…)" if
+ you want to mess up the screen :)
+
+ Nvim throttles (skips) messages from shell commands (|:!|, |:grep|, |:make|)
+ if there is too much output. No data is lost, this only affects display and
+ improves performance. |:terminal| output is never throttled.
+
+ |:!| does not support "interactive" commands. Use |:terminal| instead.
+ (GUI Vim has a similar limitation, see ":help gui-pty" in Vim.)
+
+ :!start is not special-cased on Windows.
+
+ |system()| does not support writing/reading "backgrounded" commands. |E5677|
+
Startup:
|-e| and |-es| invoke the same "improved Ex mode" as -E and -Es.
|-E| and |-Es| reads stdin as text (into buffer 1).
@@ -347,11 +353,14 @@ TUI:
only 8 colours plus bright foreground on Linux VTs.
Vim combines what is in its |builtin-terms| with what it reads from terminfo,
- and has a |ttybuiltin| setting to control how that combination works. Nvim
+ and has a 'ttybuiltin' setting to control how that combination works. Nvim
uses one or the other, it does not attempt to merge the two.
VimL (Vim script) compatibility:
`count` does not alias to |v:count|
+ `errmsg` does not alias to |v:errmsg|
+ `shell_error` does not alias to |v:shell_error|
+ `this_session` does not alias to |v:this_session|
==============================================================================
5. Missing legacy features *nvim-features-missing*
diff --git a/runtime/doc/visual.txt b/runtime/doc/visual.txt
index 176ce562d8..252a1ca8b8 100644
--- a/runtime/doc/visual.txt
+++ b/runtime/doc/visual.txt
@@ -70,10 +70,7 @@ position.
selected.
*CTRL-V* *blockwise-visual*
-[count]CTRL-V Start Visual mode blockwise. Note: Under Windows
- CTRL-V could be mapped to paste text, it doesn't work
- to start Visual mode then, see |CTRL-V-alternative|.
- [count] is used as with `v` above.
+[count]CTRL-V Start Visual mode blockwise.
If you use <Esc>, click the left mouse button or use any command that
does a jump to another buffer while in Visual mode, the highlighting stops
@@ -302,8 +299,8 @@ Visual-block Insert *v_b_I*
With a blockwise selection, I{string}<ESC> will insert {string} at the start
of block on every line of the block, provided that the line extends into the
block. Thus lines that are short will remain unmodified. TABs are split to
-retain visual columns.
-See |v_b_I_example|.
+retain visual columns. Works only for adding text to a line, not for
+deletions. See |v_b_I_example|.
Visual-block Append *v_b_A*
With a blockwise selection, A{string}<ESC> will append {string} to the end of
@@ -319,6 +316,7 @@ See |v_b_A_example|.
Note: "I" and "A" behave differently for lines that don't extend into the
selected block. This was done intentionally, so that you can do it the way
you want.
+Works only for adding text to a line, not for deletions.
Visual-block change *v_b_c*
All selected text in the block will be replaced by the same text string. When
@@ -526,4 +524,4 @@ g CTRL-H Start Select mode, blockwise. This is like CTRL-V,
but starts Select mode instead of Visual mode.
Mnemonic: "get Highlighted".
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/windows.txt b/runtime/doc/windows.txt
index e83377471c..44464c1cef 100644
--- a/runtime/doc/windows.txt
+++ b/runtime/doc/windows.txt
@@ -1046,10 +1046,8 @@ list of buffers. |unlisted-buffer|
:%bdelete " delete all buffers
<
:bdelete[!] {bufname} *E93* *E94*
- Like ":bdelete[!] [N]", but buffer given by name. Note that a
- buffer whose name is a number cannot be referenced by that
- name; use the buffer number instead. Insert a backslash
- before a space in a buffer name.
+ Like ":bdelete[!] [N]", but buffer given by name, see
+ |{bufname}|.
:bdelete[!] N1 N2 ...
Do ":bdelete[!]" for buffer N1, N2, etc. The arguments can be
@@ -1085,10 +1083,8 @@ list of buffers. |unlisted-buffer|
into a loaded buffer.
:bunload[!] {bufname}
- Like ":bunload[!] [N]", but buffer given by name. Note that a
- buffer whose name is a number cannot be referenced by that
- name; use the buffer number instead. Insert a backslash
- before a space in a buffer name.
+ Like ":bunload[!] [N]", but buffer given by name.
+ Also see |{bufname}|.
:N,Mbunload[!] Do ":bunload[!]" for all buffers in the range N to M
|inclusive|.
@@ -1106,10 +1102,16 @@ list of buffers. |unlisted-buffer|
list, without setting the 'buflisted' flag.
Also see |+cmd|.
-:[N]b[uffer][!] [+cmd] {bufname}
- Edit buffer for {bufname} from the buffer list. See
- |:buffer-!| for [!]. This will also edit a buffer that is not
- in the buffer list, without setting the 'buflisted' flag.
+:[N]b[uffer][!] [+cmd] {bufname} *{bufname}*
+ Edit buffer for {bufname} from the buffer list. A partial
+ name also works, so long as it is unique in the list of
+ buffers.
+ Note that a buffer whose name is a number cannot be referenced
+ by that name; use the buffer number instead.
+ Insert a backslash before a space in a buffer name.
+ See |:buffer-!| for [!].
+ This will also edit a buffer that is not in the buffer list,
+ without setting the 'buflisted' flag.
Also see |+cmd|.
:[N]sb[uffer] [+cmd] [N] *:sb* *:sbuffer*
@@ -1121,7 +1123,7 @@ list of buffers. |unlisted-buffer|
Also see |+cmd|.
:[N]sb[uffer] [+cmd] {bufname}
- Split window and edit buffer for {bufname} from the buffer
+ Split window and edit buffer for |{bufname}| from the buffer
list. This will also edit a buffer that is not in the buffer
list, without setting the 'buflisted' flag.
Note: If what you want to do is split the buffer, make a copy
@@ -1271,4 +1273,4 @@ unlisted The buffer is not in the buffer list. It is not used for
:setlocal nobuflisted
<
- vim:tw=78:ts=8:ft=help:norl:
+ vim:tw=78:ts=8:noet:ft=help:norl: