Skip to content

Commit 8a3ac0a

Browse files
committed
Merge remote-tracking branch 'vim/master'
2 parents 355cfeb + 3266c85 commit 8a3ac0a

39 files changed

+765
-369
lines changed

runtime/compiler/tidy.vim

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
" Vim compiler file
22
" Compiler: HTML Tidy
33
" Maintainer: Doug Kearns <[email protected]>
4-
" Last Change: 2013 Jul 7
4+
" Last Change: 2016 Apr 21
55

66
if exists("current_compiler")
77
finish
@@ -12,8 +12,8 @@ if exists(":CompilerSet") != 2 " older Vim always used :setlocal
1212
command -nargs=* CompilerSet setlocal <args>
1313
endif
1414

15-
CompilerSet makeprg=tidy\ -quiet\ -errors\ --gnu-emacs\ yes\ %
15+
CompilerSet makeprg=tidy\ -quiet\ -errors\ --gnu-emacs\ yes\ %:S
1616

17-
" sample warning: foo.html:8:1: Warning: inserting missing 'foobar' element
18-
" sample error: foo.html:9:2: Error: <foobar> is not recognized!
19-
CompilerSet errorformat=%f:%l:%c:\ Error:%m,%f:%l:%c:\ Warning:%m,%-G%.%#
17+
" foo.html:8:1: Warning: inserting missing 'foobar' element
18+
" foo.html:9:2: Error: <foobar> is not recognized!
19+
CompilerSet errorformat=%f:%l:%c:\ %trror:%m,%f:%l:%c:\ %tarning:%m,%-G%.%#

runtime/doc/channel.txt

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*channel.txt* For Vim version 7.4. Last change: 2016 Mar 28
1+
*channel.txt* For Vim version 7.4. Last change: 2016 Apr 26
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -396,6 +396,7 @@ To obtain the status of a channel: ch_status(channel). The possible results
396396
are:
397397
"fail" Failed to open the channel.
398398
"open" The channel can be used.
399+
"buffered" The channel was closed but there is data to read.
399400
"closed" The channel was closed.
400401

401402
To obtain the job associated with a channel: ch_getjob(channel)
@@ -451,7 +452,7 @@ it like this: >
451452
func MyHandler(channel, msg)
452453
453454
Without the handler you need to read the output with |ch_read()| or
454-
|ch_readraw()|.
455+
|ch_readraw()|. You can do this in the close callback, see |read-in-close-cb|.
455456

456457
The handler defined for "out_cb" will not receive stderr. If you want to
457458
handle that separately, add an "err_cb" handler: >
@@ -490,6 +491,21 @@ time a line is added to the buffer, the last-but-one line will be send to the
490491
job stdin. This allows for editing the last line and sending it when pressing
491492
Enter.
492493

494+
495+
Reading job output in the close callback ~
496+
*read-in-close-cb*
497+
If the job can take some time and you don't need intermediate results, you can
498+
add a close callback and read the output there: >
499+
500+
func! CloseHandler(channel)
501+
while ch_status(a:channel) == 'buffered'
502+
echomsg ch_read(a:channel)
503+
endwhile
504+
endfunc
505+
let job = job_start(command, {'close_cb': 'CloseHandler'})
506+
507+
You will want to do something more useful than "echomsg".
508+
493509
==============================================================================
494510
9. Starting a job without a channel *job-start-nochannel*
495511

runtime/doc/eval.txt

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*eval.txt* For Vim version 7.4. Last change: 2016 Apr 20
1+
*eval.txt* For Vim version 7.4. Last change: 2016 Apr 26
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -46,6 +46,7 @@ Float A floating point number. |floating-point-format| *Float*
4646
{only when compiled with the |+float| feature}
4747
Examples: 123.456 1.15e-6 -1.1e3
4848

49+
*E928*
4950
String A NUL terminated string of 8-bit unsigned characters (bytes).
5051
|expr-string| Examples: "ab\txx\"--" 'x-z''a,c'
5152

@@ -2922,8 +2923,11 @@ ch_status({handle}) *ch_status()*
29222923
Return the status of {handle}:
29232924
"fail" failed to open the channel
29242925
"open" channel can be used
2926+
"buffered" channel can be read, not written to
29252927
"closed" channel can not be used
29262928
{handle} can be Channel or a Job that has a Channel.
2929+
"buffered" is used when the channel was closed but there is
2930+
still data that can be obtained with |ch_read()|.
29272931

29282932
*copy()*
29292933
copy({expr}) Make a copy of {expr}. For Numbers and Strings this isn't
@@ -6314,6 +6318,7 @@ setqflist({list} [, {action}]) *setqflist()*
63146318
Note that the list is not exactly the same as what
63156319
|getqflist()| returns.
63166320

6321+
*E927*
63176322
If {action} is set to 'a', then the items from {list} are
63186323
added to the existing quickfix list. If there is no existing
63196324
list, then a new list is created. If {action} is set to 'r',
@@ -7742,6 +7747,7 @@ tag_any_white Compiled with support for any white characters in tags
77427747
tcl Compiled with Tcl interface.
77437748
terminfo Compiled with terminfo instead of termcap.
77447749
termresponse Compiled with support for |t_RV| and |v:termresponse|.
7750+
termtruecolor Compiled with true color in terminal support.
77457751
textobjects Compiled with support for |text-objects|.
77467752
tgetent Compiled with tgetent support, able to use a termcap
77477753
or terminfo file.

runtime/doc/filetype.txt

Lines changed: 36 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*filetype.txt* For Vim version 7.4. Last change: 2015 Dec 06
1+
*filetype.txt* For Vim version 7.4. Last change: 2016 Apr 30
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -586,6 +586,41 @@ folding style instead. For example: >
586586
autocmd FileType man setlocal foldmethod=indent foldenable
587587
588588
589+
MANPAGER *manpager.vim*
590+
591+
The :Man command allows you to turn Vim into a manpager (that syntax highlights
592+
manpages and follows linked manpages on hitting CTRL-]).
593+
594+
Works on:
595+
596+
- Linux
597+
- Mac OS
598+
- FreeBSD
599+
- Cygwin
600+
- Win 10 under Bash
601+
602+
Untested:
603+
604+
- Amiga OS
605+
- BeOS
606+
- OS/2
607+
608+
For bash,zsh,ksh or dash by adding to the config file (.bashrc,.zshrc, ...)
609+
610+
export MANPAGER="env MAN_PN=1 vim -M +MANPAGER -"
611+
612+
For (t)csh by adding to the config file
613+
614+
setenv MANPAGER "env MAN_PN=1 vim -M +MANPAGER -"
615+
616+
For fish by adding to the config file
617+
618+
set -x MANPAGER "env MAN_PN=1 vim -M +MANPAGER -"
619+
620+
If man sets the $MAN_PN environment variable, like man-db, the most common
621+
implementation on Linux and Mac OS, then the "env MAN_PN=1 " part above is
622+
superfluous.
623+
589624
PDF *ft-pdf-plugin*
590625

591626
Two maps, <C-]> and <C-T>, are provided to simulate a tag stack for navigating

runtime/doc/options.txt

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -3572,18 +3572,6 @@ A jump table for the options with a short description can be found at |Q_op|.
35723572
This option cannot be set from a |modeline| or in the |sandbox|, for
35733573
security reasons.
35743574

3575-
*'guicolors'* *'gcol'*
3576-
'guicolors' 'gcol' boolean (default off)
3577-
global
3578-
{not in Vi}
3579-
{not available when compiled without the
3580-
|+termtruecolor| feature}
3581-
When on, uses |highlight-guifg| and |highlight-guibg| attributes in
3582-
the terminal (thus using 24-bit color). Requires a ISO-8613-3
3583-
compatible terminal.
3584-
If setting this option does not work (produces a colorless UI)
3585-
reading |xterm-true-color| might help.
3586-
35873575
*'guicursor'* *'gcr'* *E545* *E546* *E548* *E549*
35883576
'guicursor' 'gcr' string (default "n-v-c:block-Cursor/lCursor,
35893577
ve:ver35-Cursor,
@@ -7690,6 +7678,18 @@ A jump table for the options with a short description can be found at |Q_op|.
76907678
:set encoding=utf-8
76917679
< You need to do this when your system has no locale support for UTF-8.
76927680

7681+
*'termguicolors'* *'tgc'*
7682+
'termguicolors' 'tgc' boolean (default off)
7683+
global
7684+
{not in Vi}
7685+
{not available when compiled without the
7686+
|+termguicolors| feature}
7687+
When on, uses |highlight-guifg| and |highlight-guibg| attributes in
7688+
the terminal (thus using 24-bit color). Requires a ISO-8613-3
7689+
compatible terminal.
7690+
If setting this option does not work (produces a colorless UI)
7691+
reading |xterm-true-color| might help.
7692+
76937693
*'terse'* *'noterse'*
76947694
'terse' boolean (default off)
76957695
global

runtime/doc/pattern.txt

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*pattern.txt* For Vim version 7.4. Last change: 2016 Apr 03
1+
*pattern.txt* For Vim version 7.4. Last change: 2016 Apr 26
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -1079,16 +1079,16 @@ x A single character, with no special meaning, matches itself
10791079
belonging to that character class. The following character classes
10801080
are supported:
10811081
Name Contents ~
1082-
*[:alnum:]* [:alnum:] letters and digits
1083-
*[:alpha:]* [:alpha:] letters
1082+
*[:alnum:]* [:alnum:] ASCII letters and digits
1083+
*[:alpha:]* [:alpha:] ASCII letters
10841084
*[:blank:]* [:blank:] space and tab characters
10851085
*[:cntrl:]* [:cntrl:] control characters
10861086
*[:digit:]* [:digit:] decimal digits
10871087
*[:graph:]* [:graph:] printable characters excluding space
10881088
*[:lower:]* [:lower:] lowercase letters (all letters when
10891089
'ignorecase' is used)
10901090
*[:print:]* [:print:] printable characters including space
1091-
*[:punct:]* [:punct:] punctuation characters
1091+
*[:punct:]* [:punct:] ASCII punctuation characters
10921092
*[:space:]* [:space:] whitespace characters
10931093
*[:upper:]* [:upper:] uppercase letters (all letters when
10941094
'ignorecase' is used)
@@ -1105,7 +1105,8 @@ x A single character, with no special meaning, matches itself
11051105
These items only work for 8-bit characters, except [:lower:] and
11061106
[:upper:] also work for multi-byte characters when using the new
11071107
regexp engine. See |two-engines|. In the future these items may
1108-
work for multi-byte characters.
1108+
work for multi-byte characters. For now, to get all "alpha"
1109+
characters you can use: [[:lower:][:upper:]].
11091110
*/[[=* *[==]*
11101111
- An equivalence class. This means that characters are matched that
11111112
have almost the same meaning, e.g., when ignoring accents. This

runtime/doc/quickref.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*quickref.txt* For Vim version 7.4. Last change: 2016 Mar 30
1+
*quickref.txt* For Vim version 7.4. Last change: 2016 Apr 29
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -920,6 +920,7 @@ Short explanation of each option: *option-list*
920920
'term' name of the terminal
921921
'termbidi' 'tbidi' terminal takes care of bi-directionality
922922
'termencoding' 'tenc' character encoding used by the terminal
923+
'termguicolors' 'tgc' use GUI colors for the terminal
923924
'terse' shorten some messages
924925
'textauto' 'ta' obsolete, use 'fileformats'
925926
'textmode' 'tx' obsolete, use 'fileformat'

runtime/doc/starting.txt

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*starting.txt* For Vim version 7.4. Last change: 2016 Apr 05
1+
*starting.txt* For Vim version 7.4. Last change: 2016 Apr 22
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -249,7 +249,8 @@ a slash. Thus "-R" means recovery and "-/R" readonly.
249249
-Z Restricted mode. All commands that make use of an external
250250
shell are disabled. This includes suspending with CTRL-Z,
251251
":sh", filtering, the system() function, backtick expansion,
252-
delete(), rename(), mkdir(), writefile(), libcall(), etc.
252+
delete(), rename(), mkdir(), writefile(), libcall(),
253+
job_start(), etc.
253254
{not in Vi}
254255

255256
*-g*

runtime/doc/tags

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -925,6 +925,8 @@ $VIM_POSIX vi_diff.txt /*$VIM_POSIX*
925925
't_%1' term.txt /*'t_%1'*
926926
't_%i' term.txt /*'t_%i'*
927927
't_&8' term.txt /*'t_&8'*
928+
't_8b' term.txt /*'t_8b'*
929+
't_8f' term.txt /*'t_8f'*
928930
't_@7' term.txt /*'t_@7'*
929931
't_AB' term.txt /*'t_AB'*
930932
't_AF' term.txt /*'t_AF'*
@@ -1060,11 +1062,13 @@ $VIM_POSIX vi_diff.txt /*$VIM_POSIX*
10601062
'term' options.txt /*'term'*
10611063
'termbidi' options.txt /*'termbidi'*
10621064
'termencoding' options.txt /*'termencoding'*
1065+
'termguicolors' options.txt /*'termguicolors'*
10631066
'terse' options.txt /*'terse'*
10641067
'textauto' options.txt /*'textauto'*
10651068
'textmode' options.txt /*'textmode'*
10661069
'textwidth' options.txt /*'textwidth'*
10671070
'tf' options.txt /*'tf'*
1071+
'tgc' options.txt /*'tgc'*
10681072
'tgst' options.txt /*'tgst'*
10691073
'thesaurus' options.txt /*'thesaurus'*
10701074
'tildeop' options.txt /*'tildeop'*
@@ -1304,6 +1308,7 @@ $VIM_POSIX vi_diff.txt /*$VIM_POSIX*
13041308
+tag_old_static various.txt /*+tag_old_static*
13051309
+tcl various.txt /*+tcl*
13061310
+tcl/dyn various.txt /*+tcl\/dyn*
1311+
+termguicolors various.txt /*+termguicolors*
13071312
+terminfo various.txt /*+terminfo*
13081313
+termresponse various.txt /*+termresponse*
13091314
+textobjects various.txt /*+textobjects*
@@ -4492,6 +4497,8 @@ E923 eval.txt /*E923*
44924497
E924 quickfix.txt /*E924*
44934498
E925 quickfix.txt /*E925*
44944499
E926 quickfix.txt /*E926*
4500+
E927 eval.txt /*E927*
4501+
E928 eval.txt /*E928*
44954502
E93 windows.txt /*E93*
44964503
E94 windows.txt /*E94*
44974504
E95 message.txt /*E95*
@@ -6313,6 +6320,7 @@ g:netrw_special_syntax pi_netrw.txt /*g:netrw_special_syntax*
63136320
g:netrw_ssh_browse_reject pi_netrw.txt /*g:netrw_ssh_browse_reject*
63146321
g:netrw_ssh_cmd pi_netrw.txt /*g:netrw_ssh_cmd*
63156322
g:netrw_sshport pi_netrw.txt /*g:netrw_sshport*
6323+
g:netrw_suppress_gx_mesg pi_netrw.txt /*g:netrw_suppress_gx_mesg*
63166324
g:netrw_timefmt pi_netrw.txt /*g:netrw_timefmt*
63176325
g:netrw_tmpfile_escape pi_netrw.txt /*g:netrw_tmpfile_escape*
63186326
g:netrw_uid pi_netrw.txt /*g:netrw_uid*
@@ -7145,6 +7153,7 @@ maillist intro.txt /*maillist*
71457153
maillist-archive intro.txt /*maillist-archive*
71467154
make.vim syntax.txt /*make.vim*
71477155
man.vim filetype.txt /*man.vim*
7156+
manpager.vim filetype.txt /*manpager.vim*
71487157
manual-copyright usr_01.txt /*manual-copyright*
71497158
map() eval.txt /*map()*
71507159
map-<SID> map.txt /*map-<SID>*
@@ -7961,6 +7970,7 @@ r change.txt /*r*
79617970
range() eval.txt /*range()*
79627971
raw-terminal-mode term.txt /*raw-terminal-mode*
79637972
rcp pi_netrw.txt /*rcp*
7973+
read-in-close-cb channel.txt /*read-in-close-cb*
79647974
read-messages insert.txt /*read-messages*
79657975
read-only-share editing.txt /*read-only-share*
79667976
read-stdin version5.txt /*read-stdin*
@@ -8426,6 +8436,8 @@ t_#4 term.txt /*t_#4*
84268436
t_%1 term.txt /*t_%1*
84278437
t_%i term.txt /*t_%i*
84288438
t_&8 term.txt /*t_&8*
8439+
t_8b term.txt /*t_8b*
8440+
t_8f term.txt /*t_8f*
84298441
t_@7 term.txt /*t_@7*
84308442
t_AB term.txt /*t_AB*
84318443
t_AF term.txt /*t_AF*
@@ -9281,6 +9293,7 @@ xterm-save-screen tips.txt /*xterm-save-screen*
92819293
xterm-screens tips.txt /*xterm-screens*
92829294
xterm-scroll-region term.txt /*xterm-scroll-region*
92839295
xterm-shifted-keys term.txt /*xterm-shifted-keys*
9296+
xterm-true-color term.txt /*xterm-true-color*
92849297
y change.txt /*y*
92859298
yaml.vim syntax.txt /*yaml.vim*
92869299
yank change.txt /*yank*

runtime/doc/term.txt

Lines changed: 18 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*term.txt* For Vim version 7.4. Last change: 2016 Apr 21
1+
*term.txt* For Vim version 7.4. Last change: 2016 Apr 29
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -302,7 +302,6 @@ Added by Vim (there are no standard codes for these):
302302
t_u7 request cursor position (for xterm) *t_u7* *'t_u7'*
303303
see |'ambiwidth'|
304304
t_RB request terminal background color *t_RB* *'t_RB'*
305-
see |'ambiwidth'|
306305
t_8f set foreground color (R, G, B) *t_8f* *'t_8f'*
307306
|xterm-true-color|
308307
t_8b set background color (R, G, B) *t_8b* *'t_8b'*
@@ -425,19 +424,23 @@ Vim has started, the escape sequences may not be recognized anymore.
425424

426425
*xterm-true-color*
427426
Vim supports using true colors in the terminal (taken from |highlight-guifg|
428-
and |highlight-guibg|), given that terminal supports this. To make this
429-
work, 'guicolors' option needs to be set.
430-
431-
Sometimes setting 'guicolors' is not enough and one has to set the |t_8f| and
432-
|t_8b| options explicitly. Default values of these options are
433-
`^[[38;2;%lu;%lu;%lum` and `^[[48;2;%lu;%lu;%lum` (replace `^[` with real
434-
escape) respectively, but it is only set when `$TERM` is `xterm`. Some
435-
terminals accept the same sequences, but with all semicolons replaced by
436-
colons (this is actually more compatible, but less widely supported). These
437-
options contain printf strings, with |printf()| (actually, its C equivalent
438-
hence `l` modifier) invoked with the t_ option value and three unsigned long
439-
integers that may have any value between 0 and 255 (inclusive) representing
440-
red, green and blue colors respectively.
427+
and |highlight-guibg|), given that the terminal supports this. To make this
428+
work the 'termguicolors' option needs to be set.
429+
430+
Sometimes setting 'termguicolors' is not enough and one has to set the |t_8f|
431+
and |t_8b| options explicitly. Default values of these options are
432+
"^[[38;2;%lu;%lu;%lum" and "^[[48;2;%lu;%lu;%lum" respectively, but it is only
433+
set when `$TERM` is `xterm`. Some terminals accept the same sequences, but
434+
with all semicolons replaced by colons (this is actually more compatible, but
435+
less widely supported): >
436+
set t_8f=^[[38:2:%lu:%lu:%lum
437+
set t_8b=^[[48:2:%lu:%lu:%lum
438+
(replace `^[` with real escape)
439+
440+
These options contain printf strings, with |printf()| (actually, its C
441+
equivalent hence `l` modifier) invoked with the t_ option value and three
442+
unsigned long integers that may have any value between 0 and 255 (inclusive)
443+
representing red, green and blue colors respectively.
441444

442445
*xterm-resize*
443446
Window resizing with xterm only works if the allowWindowOps resource is

0 commit comments

Comments
 (0)