diff options
Diffstat (limited to 'runtime/doc')
-rw-r--r-- | runtime/doc/autocmd.txt | 3 | ||||
-rw-r--r-- | runtime/doc/change.txt | 12 | ||||
-rw-r--r-- | runtime/doc/eval.txt | 14 | ||||
-rw-r--r-- | runtime/doc/if_pyth.txt | 4 | ||||
-rw-r--r-- | runtime/doc/map.txt | 9 | ||||
-rw-r--r-- | runtime/doc/options.txt | 46 | ||||
-rw-r--r-- | runtime/doc/recover.txt | 3 |
7 files changed, 66 insertions, 25 deletions
diff --git a/runtime/doc/autocmd.txt b/runtime/doc/autocmd.txt index bacd0e7cf1..9601dfb0f2 100644 --- a/runtime/doc/autocmd.txt +++ b/runtime/doc/autocmd.txt @@ -856,6 +856,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|, diff --git a/runtime/doc/change.txt b/runtime/doc/change.txt index ec122d3a13..c73b460767 100644 --- a/runtime/doc/change.txt +++ b/runtime/doc/change.txt @@ -667,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 @@ -677,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 diff --git a/runtime/doc/eval.txt b/runtime/doc/eval.txt index ac3c93c18f..1109225d6a 100644 --- a/runtime/doc/eval.txt +++ b/runtime/doc/eval.txt @@ -2230,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} @@ -2423,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), @@ -4058,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 @@ -5452,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 @@ -7718,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] diff --git a/runtime/doc/if_pyth.txt b/runtime/doc/if_pyth.txt index 38a78294b7..81a7816c93 100644 --- a/runtime/doc/if_pyth.txt +++ b/runtime/doc/if_pyth.txt @@ -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. @@ -91,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 diff --git a/runtime/doc/map.txt b/runtime/doc/map.txt index 0898dd98b9..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. diff --git a/runtime/doc/options.txt b/runtime/doc/options.txt index 2e335e969c..7cf3aa1d60 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 +. @@ -1458,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: @@ -1904,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. @@ -1915,6 +1924,18 @@ 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). @@ -3370,7 +3391,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 @@ -3382,8 +3403,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). @@ -4398,13 +4420,13 @@ A jump table for the options with a short description can be found at |Q_op|. security reasons. *'printencoding'* *'penc'* -'printencoding' 'penc' String (default empty, except for some systems) +'printencoding' 'penc' string (default empty, except for some systems) global 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 Expression used to print the PostScript produced with |:hardcopy|. See |pexpr-option|. diff --git a/runtime/doc/recover.txt b/runtime/doc/recover.txt index 654a9cde7b..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 |