diff options
Diffstat (limited to 'runtime/doc/options.txt')
-rw-r--r-- | runtime/doc/options.txt | 66 |
1 files changed, 48 insertions, 18 deletions
diff --git a/runtime/doc/options.txt b/runtime/doc/options.txt index 9d03397821..2e0c1f8cc4 100644 --- a/runtime/doc/options.txt +++ b/runtime/doc/options.txt @@ -312,6 +312,17 @@ Note: In the future more global options can be made |global-local|. Using ":setlocal" on a global option might work differently then. + *option-value-function* +Some options ('completefunc', 'imactivatefunc', 'imstatusfunc', 'omnifunc', +'operatorfunc', 'quickfixtextfunc' and 'tagfunc') are set to a function name +or a function reference or a lambda function. Examples: +> + set opfunc=MyOpFunc + set opfunc=function("MyOpFunc") + set opfunc=funcref("MyOpFunc") + set opfunc={t\ ->\ MyOpFunc(t)} +< + Setting the filetype :setf[iletype] [FALLBACK] {filetype} *:setf* *:setfiletype* @@ -591,7 +602,11 @@ A jump table for the options with a short description can be found at |Q_op|. "double": Use twice the width of ASCII characters. *E834* *E835* The value "double" cannot be used if 'listchars' or 'fillchars' - contains a character that would be double width. + contains a character that would be double width. These errors may + also be given when calling setcellwidths(). + + The values are overruled for characters specified with + |setcellwidths()|. There are a number of CJK fonts for which the width of glyphs for those characters are solely based on how many octets they take in @@ -614,7 +629,8 @@ A jump table for the options with a short description can be found at |Q_op|. 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 - or selected. + or selected. When a buffer has no name it also has no directory, thus + the current directory won't change when navigating to it. Note: When this option is on some plugins may not work. *'arabic'* *'arab'* *'noarabic'* *'noarab'* @@ -1321,7 +1337,9 @@ A jump table for the options with a short description can be found at |Q_op|. page can have a different value. When 'cmdheight' is zero, there is no command-line unless it is being - used. Any messages will cause the |hit-enter| prompt. + used. Some informative messages will not be displayed, any other + messages will cause the |hit-enter| prompt. Expect some other + unexpected behavior too. *'cmdwinheight'* *'cwh'* 'cmdwinheight' 'cwh' number (default 7) @@ -2139,7 +2157,8 @@ A jump table for the options with a short description can be found at |Q_op|. When on all Unicode emoji characters are considered to be full width. This excludes "text emoji" characters, which are normally displayed as single width. Unfortunately there is no good specification for this - and it has been determined on trial-and-error basis. + and it has been determined on trial-and-error basis. Use the + |setcellwidths()| function to change the behavior. *'encoding'* *'enc'* *E543* 'encoding' 'enc' @@ -3731,8 +3750,8 @@ 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| - Comma-separated list of words that influence the Lisp indenting. - |'lisp'| + Comma-separated list of words that influence the Lisp indenting when + enabled with the |'lisp'| option. *'list'* *'nolist'* 'list' boolean (default off) @@ -4395,7 +4414,9 @@ A jump table for the options with a short description can be found at |Q_op|. 'operatorfunc' 'opfunc' string (default: empty) global This option specifies a function to be called by the |g@| operator. - See |:map-operator| for more info and an example. + See |:map-operator| for more info and an example. The value can be + the name of a function, a |lambda| or a |Funcref|. See + |option-value-function| for more information. This option cannot be set from a |modeline| or in the |sandbox|, for security reasons. @@ -4689,8 +4710,9 @@ A jump table for the options with a short description can be found at |Q_op|. customize the information displayed in the quickfix or location window for each entry in the corresponding quickfix or location list. See |quickfix-window-function| for an explanation of how to write the - function and an example. The value can be the name of a function or a - lambda. + function and an example. The value can be the name of a function, a + |lambda| or a |Funcref|. See |option-value-function| for more + information. This option cannot be set from a |modeline| or in the |sandbox|, for security reasons. @@ -4712,8 +4734,8 @@ A jump table for the options with a short description can be found at |Q_op|. in read-only mode ("vim -R") or when the executable is called "view". When using ":w!" the 'readonly' option is reset for the current buffer, unless the 'Z' flag is in 'cpoptions'. - When using the ":view" command the 'readonly' option is - set for the newly edited buffer. + When using the ":view" command the 'readonly' option is set for the + newly edited buffer. See 'modifiable' for disallowing changes to the buffer. *'redrawdebug'* *'rdb'* @@ -4834,7 +4856,7 @@ A jump table for the options with a short description can be found at |Q_op|. search "/" and "?" commands - This is useful for languages such as Hebrew and Arabic. + This is useful for languages such as Hebrew, Arabic and Farsi. The 'rightleft' option must be set for 'rightleftcmd' to take effect. *'ruler'* *'ru'* *'noruler'* *'noru'* @@ -5870,6 +5892,11 @@ A jump table for the options with a short description can be found at |Q_op|. suggestions is never more than the value of 'lines' minus two. + timeout:{millisec} Limit the time searching for suggestions to + {millisec} milli seconds. Applies to the following + methods. When omitted the limit is 5000. When + negative there is no limit. + file:{filename} Read file {filename}, which must have two columns, separated by a slash. The first column contains the bad word, the second column the suggested good word. @@ -6185,7 +6212,7 @@ A jump table for the options with a short description can be found at |Q_op|. global This option controls the behavior when switching between buffers. Mostly for |quickfix| commands some values are also used for other - commands, as mentioned below. + commands, as mentioned below. Possible values (comma-separated list): useopen If included, jump to the first open window that contains the specified buffer (if there is one). @@ -6993,7 +7020,8 @@ A jump table for the options with a short description can be found at |Q_op|. *'wildoptions'* *'wop'* 'wildoptions' 'wop' string (default "pum,tagfile") global - List of words that change how |cmdline-completion| is done. + A list of words that change how |cmdline-completion| is done. + The following values are supported: pum Display the completion matches using the popup menu in the same style as the |ins-completion-menu|. tagfile When using CTRL-D to list matching tags, the kind of @@ -7084,10 +7112,12 @@ A jump table for the options with a short description can be found at |Q_op|. 'winhighlight' 'winhl' string (default empty) local to window Window-local highlights. Comma-delimited list of highlight - |group-name| pairs "{hl-builtin}:{hl},..." where each {hl-builtin} is - a built-in |highlight-groups| item to be overridden by {hl} group in - the window. Only built-in |highlight-groups| are supported, not - syntax highlighting (use |:ownsyntax| for that). + |group-name| pairs "{hl-from}:{hl-to},..." where each {hl-from} is + a |highlight-groups| item to be overridden by {hl-to} group in + the window. + + Note: highlight namespaces take precedence over 'winhighlight'. + See |nvim_win_set_hl_ns| and |nvim_set_hl|. Highlights of vertical separators are determined by the window to the left of the separator. The 'tabline' highlight of a tabpage is |