Compare commits

...

272 Commits

Author SHA1 Message Date
0bbcb5c8ef patch 7.4.807
Problem:    After CTRL-V CTRL-A mode isn't updated. (Hirohito Higashi)
Solution:   Clear the command line or update the displayed command.
2015-08-04 19:18:52 +02:00
cc218ab3ca patch 7.4.806
Problem:    CTRL-A in Visual mode doesn't work properly with "alpha" in
            'nrformat'.
Solution:   Make it work. (Christian Brabandt)
2015-08-04 18:23:22 +02:00
29bc9db36e patch 7.4.805
Problem:    The ruler shows "Bot" even when there are only filler lines
            missing. (Gary Johnson)
Solution:   Use "All" when the first line and one filler line are visible.
2015-08-04 17:43:25 +02:00
43fe32900c patch 7.4.804
Problem:    Xxd doesn't have a license notice.
Solution:   Add license as indicated by Juergen.
2015-08-04 17:29:07 +02:00
f7bb86dc59 patch 7.4.803
Problem:    C indent does not support C11 raw strings. (Mark Lodato)
Solution:   Do not change indent inside the raw string.
2015-07-28 21:17:36 +02:00
52e21cf057 patch 7.4.802
Problem:    Using "A" in Visual mode while 'linebreak' is set is not tested.
Solution:   Add a test for this, verifies the problem is fixed. (Ingo Karkat)
2015-07-28 17:16:33 +02:00
278236000f patch 7.4.801
Problem:    Test for ":diffoff" doesn't catch all potential problems.
Solution:   Add a :diffthis and a :diffoff command. (Olaf Dabrunz)
2015-07-28 14:42:45 +02:00
829aef1eb4 patch 7.4.800
Problem:    Using freed memory when triggering CmdUndefined autocommands.
Solution:   Set pointer to NULL. (Dominique Pelle)
2015-07-28 14:25:48 +02:00
6b9be1b6f2 patch 7.4.799
Problem:    Accessing memory before an allocated block.
Solution:   Check for not going before the start of a pattern. (Dominique
            Pelle)
2015-07-28 13:33:45 +02:00
31b259bf95 patch 7.4.798
Problem:    Repeating a change in Visual mode does not work as expected.
            (Urtica Dioica)
Solution:   Make redo in Visual mode work better. (Christian Brabandt)
2015-07-28 11:21:32 +02:00
5f95f288a2 patch 7.4.797
Problem:    Crash when using more lines for the command line than
            'maxcombine'.
Solution:   Use the correct array index.  Also, do not try redrawing when
            exiting.  And use screen_Columns instead of Columns.
2015-07-25 22:53:00 +02:00
33c3a694fc patch 7.4.796
Problem:    Warning from 64 bit compiler.
Solution:   Add type cast. (Mike Williams)
2015-07-22 22:46:13 +02:00
dd1616e6ce Correct optwin script, update PHP complete. 2015-07-22 22:22:59 +02:00
b388be0abf patch 7.4.795
Problem:    The 'fixeol' option is not copied to a new window.
Solution:   Copy the option value. (Yasuhiro Matsumoto)
2015-07-22 22:19:38 +02:00
d4a95c3bc5 patch 7.4.794
Problem:    Visual Studio 2015 is not recognized.
Solution:   Add the version numbers to the makefile. (Taro Muraoka)
2015-07-21 20:22:12 +02:00
f91328100d Updated and new runtime files. 2015-07-21 19:19:13 +02:00
165bc69d1b patch 7.4.793
Problem:    Can't specify when not to ring the bell.
Solution:   Add the 'belloff' option. (Christian Brabandt)
2015-07-21 17:53:25 +02:00
6561d52ecb patch 7.4.792
Problem:    Can only conceal text by defining syntax items.
Solution:   Use matchadd() to define concealing. (Christian Brabandt)
2015-07-21 15:48:27 +02:00
d51cb706a4 patch 7.4.791
Problem:    The buffer list can be very long.
Solution:   Add an argument to ":ls" to specify the type of buffer to list.
            (Marcin Szamotulski)
2015-07-21 15:03:06 +02:00
d113a80c77 patch 7.4.790
Problem:    Test fails when the autochdir feature is not available.  Test
            output contains the test script.
Solution:   Check for the autochdir feature. (Kazunobu Kuriyama)  Only write
            the relevant test output.
2015-07-21 10:57:44 +02:00
9cac424d05 patch 7.4.789
Problem:    Using freed memory and crash. (Dominique Pellej)
Solution:   Correct use of pointers. (Hirohito Higashi)
2015-07-19 14:42:23 +02:00
5cbb8dbc32 patch 7.4.788
Problem:    Can't build without the crypt feature. (John Marriott)
Solution:   Add #ifdef's.
2015-07-17 23:08:29 +02:00
fb9bc4829a patch 7.4.787
Problem:    snprintf() isn't available everywhere.
Solution:   Use vim_snprintf(). (Ken Takata)
2015-07-17 22:04:48 +02:00
537443018d patch 7.4.786
Problem:    It is not possible for a plugin to adjust to a changed setting.
Solution:   Add the OptionSet autocommand event. (Christian Brabandt)
2015-07-17 17:38:22 +02:00
34d72d4b6c patch 7.4.785
Problem:    On some systems automatically adding the missing EOL causes
            problems. Setting 'binary' has too many side effects.
Solution:   Add the 'fixeol' option, default on. (Pavel Samarkin)
2015-07-17 14:18:08 +02:00
2cf6938706 patch 7.4.784
Problem:    Using both "noinsert" and "noselect" in 'completeopt' does not
            work properly.
Solution:   Change the ins_complete() calls. (Ozaki Kiichi)
2015-07-17 13:42:23 +02:00
2536d4f396 patch 7.4.783
Problem:    copy_chars() and copy_spaces() are inefficient.
Solution:   Use memset() instead. (Dominique Pelle)
2015-07-17 13:22:51 +02:00
5d1bc78a2b patch 7.4.782
Problem:    Still a few problems with CTRL-A and CTRL-X in Visual mode.
Solution:   Fix the reported problems. (Christian Brabandt)
2015-07-17 13:03:48 +02:00
fe6f186877 patch 7.4.781
Problem:    line2byte() returns one less when 'bin' and 'noeol' are set.
Solution:   Only adjust the size for the last line. (Rob Wu)
2015-07-12 17:52:57 +02:00
1db43b1145 patch 7.4.780
Problem:    Compiler complains about uninitialized variable and clobbered
            variables.
Solution:   Add Initialization.  Make variables static.
2015-07-12 16:21:23 +02:00
3ec3261980 patch 7.4.779
Problem:    Using CTRL-A in a line without a number moves the cursor. May
            cause a crash when at the start of the line. (Urtica Dioica)
Solution:   Do not move the cursor if no number was changed.
2015-07-12 15:02:38 +02:00
ae2fe73abc patch 7.4.778
Problem:    Coverity warns for uninitialized variable.
Solution:   Change condition of assignment.
2015-07-10 22:38:00 +02:00
86ae720d75 Updated runtime files. 2015-07-10 19:31:35 +02:00
694cac7a35 patch 7.4.777
Problem:    The README file doesn't look nice on github.
Solution:   Add a markdown version of the README file.
2015-07-10 19:22:03 +02:00
2c61ec65e8 patch 7.4.776
Problem:    Equivalence class for 'd' does not work correctly.
Solution:   Fix 0x1e0f and 0x1d0b. (Dominique Pelle)
2015-07-10 19:16:34 +02:00
efcabd6892 Add files missing from patch 7.4.771. 2015-07-10 18:23:59 +02:00
b6be1e2390 patch 7.4.775
Problem:    It is not possible to avoid using the first item of completion.
Solution:   Add the "noinsert" and "noselect" values to 'completeopt'. (Shougo
            Matsu)
2015-07-10 18:18:40 +02:00
42a4512f62 patch 7.4.774
Problem:    When using the CompleteDone autocommand event it's difficult to
            get to the completed items.
Solution:   Add the v:completed_items variable. (Shougo Matsu)
2015-07-10 17:56:23 +02:00
ae94b7718a patch 7.4.773
Problem:    'langmap' is used in command-line mode when checking for mappings.
            Issue 376.
Solution:   Do not use 'langmap' in command-line mode. (Larry Velazquez)
2015-07-10 17:19:30 +02:00
5c5c9801b1 patch 7.4.772
Problem:    Racket 6.2 is not supported on MS-Windows.
Solution:   Check for the "racket" subdirectory. (Weiyong Mao)
2015-07-10 16:12:48 +02:00
5f1e68b7bc patch 7.4.771
Problem:    Search does not handle multi-byte character at the start position
            correctly.
Solution:   Take byte size of character into account. (Yukihiro Nakadaira)
2015-07-10 14:43:35 +02:00
46fd4df719 patch 7.4.770
Problem:    Background color response with transparency is not ignored.
Solution:   Change the way escape sequences are recognized. (partly by
            Hirohito Higashi)
2015-07-10 14:05:10 +02:00
2693ca21ce patch 7.4.769
Problem:    Behavior of :diffoff is not tested.
Solution:   Add a bit of testing. (Olaf Dabrunz)
2015-07-04 15:05:14 +02:00
4392996461 patch 7.4.768
Problem:    :diffoff only works properly once.
Solution:   Also make :diffoff work when used a second time. (Olaf Dabrunz)
2015-07-03 15:06:56 +02:00
fafeee6b9e patch 7.4.767
Problem:    --remote-tab-silent can fail on MS-Windows.
Solution:   Use single quotes to avoid problems with backslashes. (Idea by
            Weiyong Mao)
2015-07-03 13:33:01 +02:00
92abe859ed patch 7.4.766
Problem:    Background color check does not work on Tera Term.
Solution:   Also recognize ST as a termination character. (Hirohito Higashi)
2015-07-03 13:05:50 +02:00
9bb1930af9 patch 7.4.765
Problem:    CTRL-A and CTRL-X in Visual mode do not always work well.
Solution:   Improvements for increment and decrement. (Christian Brabandt)
2015-07-03 12:44:07 +02:00
6a57cce048 patch 7.4.764
Problem:    test_increment fails on MS-Windows. (Ken Takata)
Solution:   Clear Visual mappings. (Taro Muraoka)
2015-06-28 19:24:39 +02:00
1f860d8590 patch 7.4.763
Problem:    Building with Lua 5.1 doesn't work.
Solution:   Define lua_replace and lua_remove. (KF Leong)
2015-06-27 18:36:16 +02:00
4921c24b31 patch 7.4.762
Problem:    Comment for may_req_bg_color() is wrong. (Christ van Willegen)
Solution:   Rewrite the comment.
2015-06-27 18:34:24 +02:00
979243b990 Update help files. 2015-06-26 19:35:49 +02:00
e5401220b0 patch 7.4.761
Problem:    The request-background termcode implementation is incomplete.
Solution:   Add the missing pieces.
2015-06-25 19:16:56 +02:00
5081d20247 patch 7.4.760
Problem:    Spelling mistakes are not displayed after ":syn spell".
Solution:   Force a redraw after ":syn spell" command. (Christian Brabandt)
2015-06-25 18:36:26 +02:00
9514b1f9a1 patch 7.4.759
Problem:    Building with Lua 5.3 doesn't work, symbols have changed.
Solution:   Use the new names for the new version. (Felix Schnizlein)
2015-06-25 18:27:32 +02:00
fa67fbe6b8 patch 7.4.758
Problem:    When 'conceallevel' is 1 and quitting the command-line window with
            CTRL-C the first character ':' is erased.
Solution:   Reset 'conceallevel' in the command-line window. (Hirohito
            Higashi)
2015-06-25 18:20:36 +02:00
b5c3265521 patch 7.4.757
Problem:    Cannot detect the background color of a terminal.
Solution:   Add T_RBG to request the background color if possible. (Lubomir
            Rintel)
2015-06-25 17:03:36 +02:00
367fbf17da patch 7.4.756
Problem:    Can't use strawberry Perl 5.22 x64 on MS-Windows.
Solution:   Add new defines and #if. (Ken Takata)
2015-06-25 16:13:46 +02:00
641e48c224 patch 7.4.755
Problem:    It is not easy to count the number of characters.
Solution:   Add the skipcc argument to strchars(). (Hirohito Higashi, Ken
            Takata)
2015-06-25 16:09:26 +02:00
3a304b2382 patch 7.4.754
Problem:    Using CTRL-A in Visual mode does not work well. (Gary Johnson)
Solution:   Make it increment all numbers in the Visual area. (Christian
            Brabandt)
2015-06-25 13:57:36 +02:00
74db34cc91 patch 7.4.753
Problem:    Appending in Visual mode with 'linebreak' set does not work
            properly.  Also when 'selection' is "exclusive". (Ingo Karkat)
Solution:   Recalculate virtual columns. (Christian Brabandt)
2015-06-25 13:30:46 +02:00
66312acf14 patch 7.4.752
Problem:    Unicode 8.0 not supported.
Solution:   Update tables for Unicode 8.0.  Avoid E36 when running the script.
            (James McCoy)
2015-06-21 14:22:00 +02:00
70b5a5f5b9 patch 7.4.751
Problem:    It is not obvious how to enable the address sanitizer.
Solution:   Add commented-out flags in the Makefile. (Dominique Pelle)
            Also add missing test targets.
2015-06-21 13:44:13 +02:00
280a868a24 patch 7.4.750
Problem:    Cannot build with clang 3.5 on Cygwin with perl enabled.
Solution:   Strip "-fdebug-prefix-map" in configure. (Ken Takata)
2015-06-21 13:41:08 +02:00
0e7c4b99c6 patch 7.4.749
Problem:    For some options two consecutive commas are OK. (Nikolay Pavlov)
Solution:   Add the P_ONECOMMA flag.
2015-06-20 15:30:03 +02:00
6a7e2a668b patch 7.4.748
Problem:    Buffer overflow.
Solution:   Make the buffer larger. (Kazunobu Kuriyama)
2015-06-19 21:06:11 +02:00
e2db6c975b Add the logiPat plugin to the distribution. 2015-06-19 18:48:41 +02:00
b8c890035e patch 7.4.747
Problem:    ":cnext" may jump to the wrong column when setting
            'virtualedit=all' (cs86661)
Solution:   Reset the coladd field. (Hirohito Higashi)
2015-06-19 18:35:34 +02:00
01cf376da1 patch 7.4.746
Problem:    ":[count]tag" is not always working. (cs86661)
Solution:   Set cur_match a bit later. (Hirohito Higashi)
2015-06-19 16:45:43 +02:00
0fce425772 patch 7.4.745
Problem:    The entries added by matchaddpos() are returned by getmatches()
            but can't be set with setmatches(). (Lcd)
Solution:   Fix setmatches(). (Christian Brabandt)
2015-06-19 16:32:57 +02:00
cf0213ef7e patch 7.4.744
Problem:    No tests for Ruby and Perl.
Solution:   Add minimal tests. (Ken Takata)
2015-06-19 15:45:29 +02:00
c004bc2726 patch 7.4.743
Problem:    "p" in Visual mode causes an unexpected line split.
Solution:   Advance the cursor first. (Yukihiro Nakadaira)
2015-06-19 15:17:55 +02:00
a594d77ffc patch 7.4.742
Problem:    Cannot specify a vertical split when loading a buffer for a
            quickfix command.
Solution:   Add the "vsplit" value to 'switchbuf'. (Brook Hong)
2015-06-19 14:41:49 +02:00
a7b7b1cef9 patch 7.4.741
Problem:    When using += with ":set" a trailing comma is not recognized.
            (Issue 365)
Solution:   Don't add a second comma. Add a test. (partly by Christian
            Brabandt)
2015-06-19 14:06:43 +02:00
541f92d6cf Updated runtime files. 2015-06-19 13:27:23 +02:00
c7a0d32c83 patch 7.4.740
Problem:    ":1quit" works like ":.quit". (Bohr Shaw)
Solution:   Don't exit Vim when a range is specified. (Christian Brabandt)
2015-06-19 12:43:07 +02:00
acc39888cd patch 7.4.739
Problem:    In a string "\U" only takes 4 digits, while after CTRL-V U eight
            digits can be used.
Solution:   Make "\U" also take eight digits. (Christian Brabandt)
2015-06-19 12:08:13 +02:00
d710e0d247 patch 7.4.738
Problem:    Can't compile without the syntax highlighting feature.
Solution:   Add #ifdef around use of w_p_cul. (Hirohito Higashi)
2015-06-10 12:16:47 +02:00
6e8d3b0d41 patch 7.4.737
Problem:    On MS-Windows vimgrep over arglist doesn't work (Issue 361)
Solution:   Only escape backslashes in ## expansion when it is not used as the
            path separator. (James McCoy)
2015-06-09 21:33:31 +02:00
b878bbbca6 patch 7.4.736
Problem:    Invalid memory access.
Solution:   Avoid going over the end of a NUL terminated string. (Dominique
            Pelle)
2015-06-09 20:39:24 +02:00
e2e4b98622 patch 7.4.735
Problem:    Wrong argument for sizeof().
Solution:   Use a pointer argument. (Chris Hall)
2015-06-09 20:30:51 +02:00
d009e86826 patch 7.4.734
Problem:    ml_get error when using "p" in a Visual selection in the last
            line.
Solution:   Change the behavior at the last line. (Yukihiro Nakadaira)
2015-06-09 20:20:03 +02:00
d68f2219b5 patch 7.4.733
Problem:    test_listchars breaks on MS-Windows. (Kenichi Ito)
Solution:   Set fileformat to "unix". (Christian Brabandt)
2015-06-09 19:58:32 +02:00
f2571c61d5 Updated runtime files. 2015-06-09 19:44:55 +02:00
d0d0fe09cf patch 7.4.732
Problem:    The cursor line is not always updated for the "O" command.
Solution:   Reset the VALID_CROW flag. (Christian Brabandt)
2015-06-09 19:23:46 +02:00
7098ee5c37 patch 7.4.731
Problem:    The tab menu shows "Close tab" even when it doesn't work.
Solution:   Don't show "Close tab" for the last tab. (John Marriott)
2015-06-09 19:14:24 +02:00
bc56336bb4 patch 7.4.730
Problem:    When setting the crypt key and using a swap file, text may be
            encrypted twice or unencrypted text remains in the swap file.
            (Issue 369)
Solution:   Call ml_preserve() before re-encrypting.  Set correct index for
            next pointer block.
2015-06-09 18:35:25 +02:00
0481fee488 patch 7.4.729
Problem:    Occasional crash with 'list' set.
Solution:   Fix off-by-one error. (Christian Brabandt)
2015-05-14 05:56:09 +02:00
4270496716 patch 7.4.728
Problem:    Can't build with some version of Visual Studio 2015.
Solution:   Recognize another version 14 number. (Sinan)
2015-05-06 11:33:47 +02:00
9c60161888 patch 7.4.727
Problem:    Cannot build GvimExt with MingW.
Solution:   Add -lgdi32.  (KF Leong)
2015-05-06 06:51:50 +02:00
1fd3e30ce9 patch 7.4.726
Problem:    Cannot build GvimExt.
Solution:   Set APPVER to 5.0.  (KF Leong)
2015-05-05 10:25:16 +02:00
659c94d483 patch 7.4.725
Problem:    ":call setreg('"', [])" reports an internal error.
Solution:   Make the register empty. (Yasuhiro Matsumoto)
2015-05-04 20:19:21 +02:00
7bc25aed33 patch 7.4.724
Problem:    Vim icon does not show in Windows context menu. (issue 249)
Solution:   Load the icon in GvimExt.
2015-05-04 18:27:36 +02:00
4032cfdf17 patch 7.4.723
Problem:    For indenting, finding the C++ baseclass can be slow.
Solution:   Cache the result. (Hirohito Higashi)
2015-05-04 17:50:33 +02:00
73284b973a patch 7.4.722
Problem:    0x202f is not recognized as a non-breaking space character.
Solution:   Add 0x202f to the list. (Christian Brabandt)
2015-05-04 17:28:22 +02:00
d59c099120 patch 7.4.721
Problem:    When 'list' is set Visual mode does not highlight anything in
            empty lines. (mgaleski)
Solution:   Check the value of lcs_eol in another place. (Christian Brabandt)
2015-05-04 16:52:01 +02:00
f300ad230b patch 7.4.720
Problem:    Can't build with Visual Studio 2015.
Solution:   Recognize the "version 14" numbers and omit /nodefaultlib when
            appropriate. (Paul Moore)
2015-05-04 16:18:42 +02:00
c4dc286fe6 patch 7.4.719
Problem:    Overflow when adding MAXCOL to a pointer.
Solution:   Subtract pointers instead. (James McCoy)
2015-05-04 16:10:26 +02:00
81278efadf patch 7.4.718
Problem:    Autocommands triggered by quickfix cannot get the current title
            value.
Solution:   Set w:quickfix_title earlier. (Yannick)
            Also move the check for a title into the function.
2015-05-04 12:34:22 +02:00
1cd5e613b0 patch 7.4.717
Problem:    ":let list += list" can change a locked list.
Solution:   Check for the lock earlier. (Olaf Dabrunz)
2015-05-04 11:10:27 +02:00
cad2fc9935 patch 7.4.716
Problem:    When using the 'c' flag of ":substitute" and selecting "a" or "l"
            at the prompt the flags are not remembered for ":&&". (Ingo
            Karkat)
Solution:   Save the flag values and restore them. (Hirohito Higashi)
2015-05-04 10:46:03 +02:00
2186ffa2c7 patch 7.4.715
Problem:    Invalid memory access when there are illegal bytes.
Solution:   Get the length from the text, not from the character. (Dominique
            Pelle)
2015-05-04 10:33:15 +02:00
069dd08d8d patch 7.4.714
Problem:    Illegal memory access when there are illegal bytes.
Solution:   Check the byte length of the character. (Dominique Pelle)
2015-05-04 09:56:49 +02:00
ea98f8b4d6 patch 7.4.713
Problem:    Wrong condition for #ifdef.
Solution:   Change USR_EXRC_FILE2 to USR_VIMRC_FILE2. (Mikael Fourrier)
2015-05-04 09:31:11 +02:00
1510f996c5 patch 7.4.712
Problem:    Missing change in another file.
Solution:   Also change message.c
2015-04-22 22:18:22 +02:00
4c6b3b20dd patch 7.4.711
Problem:    Missing change in one file.
Solution:   Also change option.c
2015-04-21 19:10:48 +02:00
7927836733 patch 7.4.710
Problem:    It is not possible to make spaces visibible in list mode.
Solution:   Add the "space" item to 'listchars'. (David Bürgin, issue 350)
2015-04-21 18:33:48 +02:00
40ce3a4e1f patch 7.4.709
Problem:    ":tabmove" does not work as documented.
Solution:   Make it work consistently.  Update documentation and add tests.
            (Hirohito Higashi)
2015-04-21 18:08:39 +02:00
77354e78a8 patch 7.4.708
Problem:    gettext() is called too often.
Solution:   Do not call gettext() for messages until they are actually used.
            (idea by Yasuhiro Matsumoto)
2015-04-21 16:49:05 +02:00
3cbac309f7 patch 7.4.707
Problem:    Undo files can have their executable bit set.
Solution:   Strip of the executable bit. (Mikael Berthe)
2015-04-21 16:12:06 +02:00
5b14f89164 patch 7.4.706
Problem:    Window drawn wrong when 'laststatus' is zero and there is a
            command-line window. (Yclept Nemo)
Solution:   Set the status height a bit later. (Christian Brabandt)
2015-04-21 15:43:05 +02:00
bbc1a592a0 patch 7.4.705
Problem:    Can't build with Ruby 2.2.
Solution:   Add #ifdefs to handle the incompatible change. (Andrei Olsen)
2015-04-21 15:25:31 +02:00
d82a2a990b patch 7.4.704
Problem:    Searching for a character matches an illegal byte and causes
            invalid memory access. (Dominique Pelle)
Solution:   Do not match an invalid byte when search for a character in a
            string.  Fix equivalence classes using negative numbers, which
            result in illegal bytes.
2015-04-21 14:02:35 +02:00
f9bde2b152 patch 7.4.703
Problem:    Compiler warning for start_dir unused when building unittests.
Solution:   Move start_dir inside the #ifdef.
2015-04-17 22:08:16 +02:00
d39a751280 patch 7.4.702
Problem:    Joining an empty list does uneccessary work.
Solution:   Let join() return early. (Marco Hinz)
2015-04-16 22:51:22 +02:00
ec45c4a6df patch 7.4.701
Problem:    Compiler warning for using uninitialized variable. (Yasuhiro
            Matsumoto)
Solution:   Initialize it.
2015-04-15 14:27:49 +02:00
ba172f2eab Remove local-additions entries from help.txt. 2015-04-15 14:13:18 +02:00
0a63dedf99 Updated runtime files. 2015-04-15 13:31:24 +02:00
d5f6933d5c patch 7.4.700
Problem:    Fold can't be opened after ":move". (Ein Brown)
Solution:   Delete the folding information and update it afterwards.
            (Christian Brabandt)
2015-04-15 12:43:50 +02:00
05b20fb14e patch 7.4.699
Problem:    E315 when trying to delete a fold. (Yutao Yuan)
Solution:   Make sure the fold doesn't go beyond the last buffer line.
            (Christian Brabandt)
2015-04-13 20:52:36 +02:00
9bc174b69d patch 7.4.698
Problem:    Various problems with locked and fixed lists and dictionaries.
Solution:   Disallow changing locked items, fix a crash, add tests. (Olaf
            Dabrunz)
2015-04-13 16:16:38 +02:00
d94682ffb4 patch 7.4.697
Problem:    The filename used for ":profile" must be given literally.
Solution:   Expand "~" and environment variables. (Marco Hinz)
2015-04-13 15:37:56 +02:00
50ab994ab3 patch 7.4.696
Problem:    Not freeing memory when encountering an error.
Solution:   Free the stack before returning. (Eliseo Martínez)
2015-04-13 15:28:12 +02:00
7c94ce910f patch 7.4.695
Problem:    Out-of-bounds read, dectected by Coverity.
Solution:   Remember the value of cmap for the first matching encoding.  Reset
            cmap to that value if first matching encoding is going to be used.
            (Eliseo Martínez)
2015-04-13 14:45:27 +02:00
83d1b19015 More updated runtime files. 2015-04-13 14:22:40 +02:00
29d54df5cd patch 7.4.694
Problem:    Running tests changes the .viminfo file.
Solution:   Disable viminfo in the text objects test.
2015-04-13 12:58:12 +02:00
5a5f45917d Updated runtime files. 2015-04-13 12:43:06 +02:00
695baeefe1 patch 7.4.693
Problem:    Session file is not correct when there are multiple tab pages.
Solution:   Reset the current window number for each tab page. (Jacob Niehus)
2015-04-13 12:39:22 +02:00
de1502f2b4 patch 7.4.692 for Problem: Defining SOLARIS for no good reason. (Danek Duvall)
Solution:   Remove it.
2015-04-09 22:08:21 +02:00
f630387827 patch 7.4.691 for Problem: Can't build with MzScheme.
Solution:   Change "cwd" into the global variable "start_dir".
2015-04-03 17:59:43 +02:00
da6365774d patch 7.4.690 for Problem: Memory access errors when changing indent in Ex mode. Also missing
redraw when using CTRL-U. (Knil Ino)
Solution:   Update pointers after calling ga_grow().
2015-04-03 17:11:45 +02:00
d87c36ea5e updated for version 7.4.689
Problem:    On MS-Windows, when 'autochdir' is set, diff mode with files in
            different directories does not work. (Axel Bender)
Solution:   Remember the current directory and use it where needed. (Christian
            Brabandt)
2015-04-03 14:56:49 +02:00
478c46e50f updated for version 7.4.688
Problem:    When "$" is in 'cpo' the popup menu isn't undrawn correctly.
            (Issue 166)
Solution:   When using the popup menu remove the "$".
2015-03-31 19:18:00 +02:00
1e7813a187 updated for version 7.4.687
Problem:    There is no way to use a different in Replace mode for a terminal.
Solution:   Add t_SR. (Omar Sandoval)
2015-03-31 18:31:03 +02:00
7d2757a472 updated for version 7.4.686
Problem:    "zr" and "zm" do not take a count.
Solution:   Implement the count, restrict the fold level to the maximum
            nesting depth.  (Marcin Szamotulski)
2015-03-31 17:46:22 +02:00
0e462411ca updated for version 7.4.685
Problem:    When there are illegal utf-8 characters the old regexp engine may
            go past the end of a string.
Solution:   Only advance to the end of the string. (Dominique Pelle)
2015-03-31 14:17:31 +02:00
e5c421cfd7 updated for version 7.4.684
Problem:    When starting several Vim instances in diff mode, the temp files
            used may not be unique. (Issue 353)
Solution:   Add an argument to vim_tempname() to keep the file.
2015-03-31 13:33:08 +02:00
1ca2e361a8 updated for version 7.4.683
Problem:    Typo in the vimtutor command.
Solution:   Fix the typo. (Corey Farwell, github pull 349)
2015-03-25 20:24:04 +01:00
09deeb7c94 updated for version 7.4.682
Problem:    The search highlighting and match highlighting replaces the
            cursorline highlighting, this doesn't look good.
Solution:   Combine the highlighting. (Yasuhiro Matsumoto)
2015-03-24 18:22:41 +01:00
dbcf19dc49 Add test files for patch 7.4.680. 2015-03-24 17:57:45 +01:00
71371b1579 updated for version 7.4.681
Problem:    MS-Windows: When Vim is minimized the window height is computed
            incorrectly.
Solution:   When minimized use the previously computed size. (Ingo Karkat)
2015-03-24 17:57:12 +01:00
310f2d59b2 updated for version 7.4.680
Problem:    CTRL-W in Insert mode does not work well for multi-byte
            characters.
Solution:   Use mb_get_class(). (Yasuhiro Matsumoto)
2015-03-24 17:49:51 +01:00
6383b92d8c updated for version 7.4.679
Problem:    Color values greater than 255 cause problems on MS-Windows.
Solution:   Truncate to 255 colors. (Yasuhiro Matsumoto)
2015-03-24 17:12:19 +01:00
f11ce667b0 updated for version 7.4.678
Problem:    When using --remote the directory may end up being wrong.
Solution:   Use localdir() to find out what to do. (Xaizek)
2015-03-24 16:48:58 +01:00
a161e26d55 updated for version 7.4.677
Problem:    Configure fails when specifying a python-config-dir. (Lcd)
Solution:   Check if PYTHONFRAMEWORKPREFIX is set.
2015-03-24 15:14:27 +01:00
6c927557e2 updated for version 7.4.676
Problem:    On Mac, when not using the default Python framework configure
            doesn't do the right thing.
Solution:   Use a linker search path. (Kazunobu Kuriyama)
2015-03-24 12:21:33 +01:00
eab316bdf9 updated for version 7.4.675
Problem:    When a FileReadPost autocommand moves the cursor inside a line it
            gets moved back.
Solution:   When checking whether an autocommand moved the cursor store the
            column as well. (Christian Brabandt)
2015-03-24 11:46:30 +01:00
77b7710d4e updated for version 7.4.674
Problem:    Missing changes in one file.
Solution:   Also change the win32 file.
2015-03-21 22:18:41 +01:00
e7154eb5c3 updated for version 7.4.673
Problem:    The first syntax entry gets sequence number zero, which doesn't
            work. (Clinton McKay)
Solution:   Start at number one. (Bjorn Linse)
2015-03-21 21:46:13 +01:00
5837f1f447 Update runtime files. 2015-03-21 18:06:14 +01:00
b5971141df updated for version 7.4.672
Problem:    When completing a shell command, directories in the current
            directory are not listed.
Solution:   When "." is not in $PATH also look in the current directory for
            directories.
2015-03-21 17:32:19 +01:00
4df702999d updated for version 7.4.671
Problem:    Warning for shadowing a variable.
Solution:   Rename off to mb_off. (Kazunobu Kuriyama)
2015-03-21 14:20:16 +01:00
dcefba9934 updated for version 7.4.670
Problem:    Using 'cindent' for Javascript is less than perfect.
Solution:   Improve indenting of continuation lines. (Hirohito Higashi)
2015-03-20 19:06:06 +01:00
3b7b83649c updated for version 7.4.669
Problem:    When netbeans is active the sign column always shows up.
Solution:   Only show the sign column once a sign has been added. (Xavier de
            Gaye)
2015-03-20 18:11:48 +01:00
825e7ab423 updated for version 7.4.668
Problem:    Can't use a glob pattern as a regexp pattern.
Solution:   Add glob2regpat(). (Christian Brabandt)
2015-03-20 17:36:42 +01:00
fbc25b20cb updated for version 7.4.667
Problem:    'colorcolumn' isn't drawn in a closed fold while 'cursorcolumn'
            is. (Carlos Pita)
Solution:   Make it consistent. (Christian Brabandt)
2015-03-20 17:16:27 +01:00
b1fc2bf29c updated for version 7.4.666
Problem:    There is a chance that Vim may lock up.
Solution:   Handle timer events differently. (Aaron Burrow)
2015-03-20 16:26:54 +01:00
76feaf1bfe updated for version 7.4.665
Problem:    'linebreak' does not work properly with multi-byte characters.
Solution:   Compute the pointer offset with mb_head_off().  (Yasuhiro
            Matsumoto)
2015-03-20 15:58:52 +01:00
6b31467aa7 updated for version 7.4.664
Problem:    When 'compatible' is reset 'numberwidth' is set to 4, but the
            effect doesn't show until a change is made.
Solution:   Check if 'numberwidth' changed. (Christian Brabandt)
2015-03-20 15:42:10 +01:00
404c942fb8 updated for version 7.4.663
Problem:    When using netbeans a buffer is not found in another tab.
Solution:   When 'switchbuf' is set to "usetab" then switch to another tab
            when possible. (Xavier de Gaye)
2015-03-14 15:35:52 +01:00
438b64ab71 updated for version 7.4.662
Problem:    When 'M' is in the 'cpo' option then selecting a text object in
            parenthesis does not work correctly.
Solution:   Keep 'M' in 'cpo' when finding a match. (Hirohito Higashi)
2015-03-13 15:03:00 +01:00
6c5bdb751c updated for version 7.4.661
Problem:    Using "0 CTRL-D" in Insert mode may have CursorHoldI interfere.
            (Gary Johnson)
Solution:   Don't store K_CURSORHOLD as the last character. (Christian
            Brabandt)
2015-03-13 13:24:23 +01:00
c7dc1f4a53 updated for version 7.4.660
Problem:    Using freed memory when g:colors_name is changed in the colors
            script. (oni-link)
Solution:   Make a copy of the variable value.
2015-03-13 12:53:37 +01:00
488eb26ec7 updated for version 7.4.659
Problem:    When 'ruler' is set the preferred column is reset. (Issue 339)
Solution:   Don't set curswant when redrawing the status lines.
2015-03-13 11:23:50 +01:00
0f8dd840fc updated for version 7.4.658
Problem:    'formatexpr' is evaluated too often.
Solution:   Only invoke it when beyond the 'textwidth' column, as it is
            documented. (James McCoy)
2015-03-08 14:48:49 +01:00
ab11a5914b updated for version 7.4.657
Problem:    Compiler warnings for pointer mismatch.
Solution:   Add a typecast. (John Marriott)
2015-03-06 22:00:11 +01:00
d8b77f7dc0 updated for version 7.4.656
Problem:    Missing changes for glob() in one file.
Solution:   Add the missing changes.
2015-03-05 21:21:19 +01:00
b6c2735c56 updated for version 7.4.655
Problem:    Text deleted by "dit" depends on indent of closing tag.
            (Jan Parthey)
Solution:   Do not adjust oap->end in do_pending_operator(). (Christian
            Brabandt)
2015-03-05 19:57:49 +01:00
a245bc79b4 updated for version 7.4.654
Problem:    glob() and globpath() cannot include links to non-existing files.
            (Charles Campbell)
Solution:   Add an argument to include all links with glob(). (James McCoy)
            Also for globpath().
2015-03-05 19:35:25 +01:00
e421450a5e updated for version 7.4.653
Problem:    Insert mode completion with complete() may have CTRL-L work like
            CTRL-P.
Solution:   Handle completion with complete() differently. (Yasuhiro
            Matsumoto, Christian Brabandt, Hirohito Higashi)
2015-03-05 18:08:43 +01:00
4dcdf29910 updated for version 7.4.652
Problem:    Xxd lacks a few features.
Solution:   Use 8 characters for the file position.  Add the -e and -o
            arguments. (Vadim Vygonets)
2015-03-05 17:51:15 +01:00
4f36dc3bf7 updated for version 7.4.651
Problem:    Can't match "%>80v" properly for multi-byte characters.
Solution:   Multiply the character number by the maximum number of bytes in a
            character. (Yasuhiro Matsumoto)
2015-03-05 17:16:06 +01:00
5d3fbf3bfe updated for version 7.4.650
Problem:    Configure check may fail because the dl library is not used.
Solution:   Put "-ldl" in LIBS rather than LDFLAGS. (Oazki Kiichi)
2015-03-05 16:47:20 +01:00
cf48767cd1 updated for version 7.4.649
Problem:    Compiler complains about ignoring return value of fwrite().
            (Michael Jarvis)
Solution:   Add (void).
2015-03-05 13:36:00 +01:00
f3c2afb77f Update a few runtime files. 2015-03-02 23:16:07 +01:00
2b8388bd01 Updated runtime files. 2015-02-28 13:11:45 +01:00
bac203ea2d updated for version 7.4.648
Problem:    Tests broken on MS-Windows.
Solution:   Delete wrong copy line. (Ken Takata)
2015-02-27 22:12:34 +01:00
13cf77ba17 updated for version 7.4.647
Problem:    After running the tests on MS-Windows many files differ from their
            originals as they were checked out.
Solution:   Use a temp directory for executing the tests. (Ken Takata, Taro
            Muraoka)
2015-02-27 21:11:02 +01:00
e25bb90b2e updated for version 7.4.646
Problem:    ":bufdo" may start at a deleted buffer.
Solution:   Find the first not deleted buffer. (Shane Harper)
2015-02-27 20:33:37 +01:00
8da9bbfd02 updated for version 7.4.645
Problem:    When splitting the window in a BufAdd autocommand while still in
            the first, empty buffer the window count is wrong.
Solution:   Do not reset b_nwindows to zero and don't increment it.
2015-02-27 19:34:56 +01:00
ba17ed6797 updated for version 7.4.644
Problem:    Stratus VOS doesn't have sync().
Solution:   Use fflush(). (Karli Aurelia)
2015-02-27 18:25:16 +01:00
c6b7217ff5 updated for version 7.4.643
Problem:    Using the default file format for Mac files. (Issue 77)
Solution:   Reset the try_mac counter in the right place. (Oswald)
2015-02-27 17:48:09 +01:00
d45c07ac74 updated for version 7.4.642
Problem:    When using "gf" escaped spaces are not handled.
Solution:   Recognize escaped spaces.
2015-02-27 17:19:10 +01:00
dfd7691bb8 updated for version 7.4.641
Problem:    The tabline menu was using ":999tabnew" which is now invalid.
Solution:   Use ":$tabnew" instead. (Florian Degner)
2015-02-27 15:03:58 +01:00
c3bbad085c updated for version 7.4.640
Problem:    After deleting characters in Insert mode such that lines are
            joined undo does not work properly. (issue 324)
Solution:   Use Insstart instead of Insstart_orig. (Christian Brabandt)
2015-02-17 17:50:26 +01:00
8fc6bc7126 updated for version 7.4.639
Problem:    Combination of linebreak and conceal doesn't work well.
Solution:   Fix the display problems. (Christian Brabandt)
2015-02-17 17:26:10 +01:00
46538ee46c updated for version 7.4.638
Problem:    Can't build with Lua 5.3 on Windows.
Solution:   use luaL_optinteger() instead of LuaL_optlong(). (Ken Takata)
2015-02-17 16:28:55 +01:00
1e997827f1 updated for version 7.4.637
Problem:    Incorrectly read the number of buffer for which an autocommand
            should be registered.
Solution:   Reverse check for "<buffer=abuf>". (Lech Lorens)
2015-02-17 16:04:57 +01:00
35e7594dd4 Add missing test files from 7.4.634 to the repository. 2015-02-17 15:47:46 +01:00
4653911950 updated for version 7.4.636
Problem:    A search with end offset gets stuck at end of file. (Gary Johnson)
Solution:   When a search doesn't move the cursor repeat it with a higher
            count. (Christian Brabandt)
2015-02-17 15:43:57 +01:00
05eb612ff3 updated for version 7.4.635
Problem:    If no NL or CR is found in the first block of a file then the
            'fileformat' may be set to "mac". (Issue 77)
Solution:   Check if a CR was found. (eswald)
2015-02-17 14:15:19 +01:00
f65aad5554 updated for version 7.4.634
Problem:    Marks are not restored after redo + undo.
Solution:   Fix the way marks are restored. (Olaf Dabrunz)
2015-02-17 13:43:40 +01:00
be20f9fa5d updated for version 7.4.633
Problem:    After 7.4.630 the problem persists.
Solution:   Also skip redo when calling a user function.
2015-02-17 12:44:09 +01:00
eaa330e8e9 updated for version 7.4.632
Problem:    7.4.592 breaks the netrw plugin, because the autocommands are
            skipped.
Solution:   Roll back the change.
2015-02-17 12:17:14 +01:00
4a42710695 updated for version 7.4.631
Problem:    The default conceal character is documented to be a space but it's
            initially a dash. (Christian Brabandt)
Solution:   Make the intial value a space.
2015-02-17 11:11:48 +01:00
c51b02d7d9 updated for version 7.4.630
Problem:    When using Insert mode completion combined with autocommands the
            redo command may not work.
Solution:   Do not save the redo buffer when executing autocommands. (Yasuhiro
            Matsumoto)
2015-02-17 10:58:25 +01:00
98f52500b6 updated for version 7.4.629
Problem:    Coverity warning for Out-of-bounds read.
Solution:   Increase MAXWLEN to 254. (Eliseo Martínez)
2015-02-10 20:03:45 +01:00
8872ef1b4e updated for version 7.4.628
Problem:    Compiler warning for variable might be clobbered by longjmp.
Solution:   Add volatile. (Michael Jarvis)
2015-02-10 19:27:05 +01:00
494838a3fe updated for version 7.4.627
Problem:    The last screen cell is not updated.
Solution:   Respect the "tn" termcap feature. (Hayaki Saito)
2015-02-10 19:20:37 +01:00
eb2928595b updated for version 7.4.626
Problem:    MSVC with W4 gives useless warnings.
Solution:   Disable more warnings. (Mike Williams)
2015-02-10 18:47:58 +01:00
24a6ff88bc updated for version 7.4.625
Problem:    Possible NULL pointer dereference.
Solution:   Check for NULL before using it. (Mike Williams)
2015-02-10 18:41:58 +01:00
9abd5c6507 updated for version 7.4.624
Problem:    May leak memory or crash when vim_realloc() returns NULL.
Solution:   Handle a NULL value properly. (Mike Williams)
2015-02-10 18:34:01 +01:00
a1d2c58985 updated for version 7.4.623
Problem:    Crash with pattern: \(\)\{80000}  (Dominique Pelle)
Solution:   When the max limit is large fall back to the old engine.
2015-02-10 18:18:17 +01:00
168e04966c updated for version 7.4.622
Problem:    Compiler warning for unused argument.
Solution:   Add UNUSED.
2015-02-05 20:29:59 +01:00
f554a3285e updated for version 7.4.621
Problem:    Returning 1 in the wrong function. (Raymond Ko)
Solution:   Return 1 in the right function (hopefully).
2015-02-04 23:08:01 +01:00
934b136193 updated for version 7.4.620
Problem:    Compiler warning for unitinialized variable. (Tony Mechelynck)
Solution:   Initialize "did_free". (Ben Fritz)
2015-02-04 23:06:45 +01:00
b84634de30 updated for version 7.4.619
Problem:    luaV_setref() not returning the correct value.
Solution:   Return one.
2015-02-04 22:02:37 +01:00
9d49da8cbb updated for version 7.4.618
Problem:    luaV_setref() is missing a return statement. (Ozaki Kiichi)
Solution:   Put the return statement back.
2015-02-03 23:10:46 +01:00
0122c4070f Update runtime files. 2015-02-03 19:13:34 +01:00
c0a37b9db3 updated for version 7.4.617
Problem:    Wrong ":argdo" range does not cause an error.
Solution:   Reset "cmd" to NULL. (Marcin Szamotulski, Ingo Karkat)
2015-02-03 19:10:53 +01:00
f2c03d7301 updated for version 7.4.616
Problem:    Cannot insert a tab in front of a block.
Solution:   Correctly compute aop->start. (Christian Brabandt)
2015-02-03 18:36:44 +01:00
e71eea801e updated for version 7.4.615
Problem:    Vim hangs when freeing a lot of objects.
Solution:   Do not go back to the start of the list every time.  (Yasuhiro
            Matsumoto and Ariya Mizutani)
2015-02-03 17:10:06 +01:00
d7ce7a9ad2 updated for version 7.4.614
Problem:    There is no test for what patch 7.4.601 fixes.
Solution:   Add a test. (Christian Brabandt)
2015-02-03 16:53:51 +01:00
70781ee403 updated for version 7.4.613
Problem:    The NFA engine does not implement the 'redrawtime' time limit.
Solution:   Implement the time limit.
2015-02-03 16:49:24 +01:00
e08dd4e49e updated for version 7.4.612
Problem:    test_eval fails on Mac.
Solution:   Use the * register instead of the + register. (Jun Takimoto)
2015-02-03 16:07:47 +01:00
b641df4965 updated for version 7.4.611
Problem:    Syntax error.
Solution:   Change statement to return.
2015-02-03 13:16:04 +01:00
016154919e updated for version 7.4.610
Problem:    Some function headers may be missing from generated .pro files.
Solution:   Add PROTO to the #ifdef.
2015-02-03 13:00:38 +01:00
2459a5ecaa updated for version 7.4.609
Problem:    For complicated list and dict use the garbage collector can run
            out of stack space.
Solution:   Use a stack of dicts and lists to be marked, thus making it
            iterative instead of recursive. (Ben Fritz)
2015-02-03 12:55:18 +01:00
4ac163ae5f updated for version 7.4.608
Problem:    test_eval fails when the clipboard feature is missing.
Solution:   Skip part of the test. Reduce the text used.
2015-01-27 22:52:15 +01:00
73a156bf36 updated for version 7.4.607
Problem:    Compiler warnings for unused variables.
Solution:   Move them inside #ifdef. (Kazunobu Kuriyama)
2015-01-27 21:39:05 +01:00
7cc8ec4720 updated for version 7.4.606
Problem:    May crash when using a small window.
Solution:   Avoid dividing by zero. (Christian Brabandt)
2015-01-27 20:59:31 +01:00
3b3a9498d1 updated for version 7.4.605
Problem:    The # register is not writable, it cannot be restored after
            jumping around.
Solution:   Make the # register writable. (Marcin Szamotulski)
2015-01-27 18:44:16 +01:00
6bf7c523ad updated for version 7.4.604
Problem:    Running tests changes viminfo.
Solution:   Disable viminfo.
2015-01-27 17:12:00 +01:00
1c93429c48 updated for version 7.4.603
Problem:    'foldcolumn' may be set such that it fills the whole window, not
            leaving space for text.
Solution:   Reduce the foldcolumn width when there is not sufficient room.
            (idea by Christian Brabandt)
2015-01-27 16:39:29 +01:00
18400e6430 updated for version 7.4.602
Problem:    ":set" does not accept hex numbers as documented.
Solution:   Use vim_str2nr(). (ZyX)
2015-01-27 15:58:40 +01:00
0a988df731 updated for version 7.4.601
Problem:    It is not possible to have feedkeys() insert characters.
Solution:   Add the 'i' flag.
2015-01-27 15:19:24 +01:00
0cd040b96a updated for version 7.4.600
Problem:    Memory wasted in struct because of aligning.
Solution:   Split pos in lnum and col. (Dominique Pelle)
2015-01-27 14:54:11 +01:00
aaf3047de2 updated for version 7.4.599
Problem:    Out-of-memory error.
Solution:   Avoid trying to allocate a negative amount of memory, use size_t
            instead of int. (Dominique Pelle)
2015-01-27 14:40:00 +01:00
5c27fd100a updated for version 7.4.598
Problem:    ":tabdo windo echo 'hi'" causes "* register not to be changed.
            (Salman Halim)
Solution:   Change how clip_did_set_selection is used and add
            clipboard_needs_update and global_change_count.  (Christian
            Brabandt)
2015-01-27 14:09:37 +01:00
9a492d456d updated for version 7.4.597
Problem:    Cannot change the result of systemlist().
Solution:   Initialize v_lock. (Yukihiro Nakadaira)
2015-01-27 13:49:31 +01:00
932d88662f updated for version 7.4.596
Problem:    Tiny build doesn't compile.  (Ike Devolder)
Solution:   Add #ifdef.
2015-01-27 13:33:23 +01:00
322a24af83 updated for version 7.4.595
Problem:    The test_command_count test fails when using Japanese.
Solution:   Force the language to C. (Hirohito Higashi)
2015-01-27 13:28:46 +01:00
1dc92334eb updated for version 7.4.594
Problem:    Using a block delete while 'breakindent' is set does not work
            properly.
Solution:   Use "line" instead of "prev_pend" as the first argument to
            lbr_chartabsize_adv().  (Hirohito Higashi)
2015-01-27 13:22:20 +01:00
e0ad365498 updated for version 7.4.593
Problem:    Crash when searching for "x\{0,90000}". (Dominique Pelle)
Solution:   Bail out from the NFA engine when the max limit is much higher
            than the min limit.
2015-01-27 12:59:55 +01:00
df5caa08f6 updated for version 7.4.592
Problem:    When doing ":e foobar" when already editing "foobar" and 'buftype'
            is "nofile" the buffer is cleared. (Xavier de Gaye)
Solution:   Do no clear the buffer.
2015-01-27 11:26:15 +01:00
8a94d873aa Update runtime files. 2015-01-25 13:02:57 +01:00
df82661c9c updated for version 7.4.591
Problem:    test_listlbr_utf8 fails when the conceal feature is not available.
Solution:   Check for the conceal feature. (Kazunobu Kuriyama)
2015-01-22 22:41:56 +01:00
eea478f885 updated for version 7.4.590
Problem:    Using ctrl_x_mode as if it contains flags.
Solution:   Don't use AND with CTRL_X_OMNI. (Hirohito Higashi)
2015-01-22 22:40:20 +01:00
1ec4dd41de updated for version 7.4.589
Problem:    In the MS-Windows console Vim can't handle greek characters when
            encoding is utf-8.
Solution:   Escape K_NUL. (Yasuhiro Matsumoto)
2015-01-20 19:39:35 +01:00
4bde00c595 updated for version 7.4.588
Problem:    ":0argedit foo" puts the new argument in the second place instead
            of the first.
Solution:   Adjust the range type. (Ingo Karkat)
2015-01-20 19:31:02 +01:00
6a6028cf4b updated for version 7.4.587
Problem:    Conceal does not work properly with 'linebreak'. (cs86661)
Solution:   Save and restore boguscols. (Christian Brabandt)
2015-01-20 19:01:35 +01:00
6bf7a5933f updated for version 7.4.586
Problem:    Parallel building of the documentation html files is not reliable.
Solution:   Remove a cyclic dependency. (Reiner Herrmann)
2015-01-20 17:27:22 +01:00
e823183254 updated for version 7.4.585
Problem:    Range for :bdelete does not work. (Ronald Schild)
Solution:   Also allow unloaded buffers.
2015-01-20 13:29:49 +01:00
ff8a75dab7 updated for version 7.4.584
Problem:    With tiny features test_command_count may fail.
Solution:   Source small.vim. (Christian Brabandt)
2015-01-20 12:39:39 +01:00
ff13610d7b updated for version 7.4.583
Problem:    With tiny features test 16 may fail.
Solution:   Source small.vim. (Christian Brabandt)
2015-01-20 12:14:01 +01:00
ef795d1a5b updated for version 7.4.582
Problem:    Can't match "%>80v" properly. (Axel Bender)
Solution:   Correctly handle ">". (Christian Brabandt)
2015-01-18 16:46:32 +01:00
7cbc703fdc updated for version 7.4.581
Problem:    Compiler warnings for unitinialized variables. (John Little)
Solution:   Initialize the variables.
2015-01-18 14:08:56 +01:00
164f3269b1 updated for version 7.4.580
Problem:    ":52wincmd v" still gives an invalid range error. (Charles
            Campbell)
Solution:   Skip over white space.
2015-01-14 21:22:01 +01:00
83caecf314 Updated runtime files. 2015-01-14 19:42:21 +01:00
d574ea2f80 updated for version 7.4.579
Problem:    Wrong cursor positioning when 'linebreak' is set and lines wrap.
Solution:   (Christian Brabandt)
2015-01-14 19:35:14 +01:00
084abaec06 updated for version 7.4.578
Problem:    Using getcurpos() after "$" in an empty line returns a negative
            number.
Solution:   Don't add one when this would overflow. (Hirohito Higashi)
2015-01-14 19:00:38 +01:00
a20bcad15c updated for version 7.4.577
Problem:    Matching with a virtual column has a lot of overhead on very long
            lines. (Issue 310)
Solution:   Bail out early if there can't be a match. (Christian Brabandt)
            Also check for CTRL-C at every position.
2015-01-14 18:40:28 +01:00
ba3f58e296 updated for version 7.4.576
Problem:    Redrawing problem with 'relativenumber' and 'linebreak'.
Solution:   Temporarily reset 'linebreak' and restore it in more places.
            (Christian Brabandt)
2015-01-14 17:52:30 +01:00
ea67672534 updated for version 7.4.575
Problem:    Unicode character properties are outdated.
Solution:   Update the tables with the latest version.
2015-01-14 17:40:09 +01:00
615b9978dd updated for version 7.4.574
Problem:    No error for eval('$').
Solution:   Check for empty name. (Yasuhiro Matsumoto)
2015-01-14 17:15:05 +01:00
5000869712 updated for version 7.4.573
Problem:    Mapping CTRL-C in Visual mode doesn't work. (Ingo Karkat)
Solution:   Call get_real_state() instead of using State directly.
2015-01-14 16:08:32 +01:00
84c8e5ab9c updated for version 7.4.572
Problem:    Address type of :wincmd depends on the argument.
Solution:   Check the argument.
2015-01-14 15:47:36 +01:00
435797304a updated for version 7.4.571
Problem:    Can't build with tiny features. (Ike Devolder)
Solution:   Add #ifdef.
2015-01-14 14:08:44 +01:00
0c7485fdbb updated for version 7.4.570
Problem:    Building with dynamic library does not work for Ruby 2.2.0
Solution:   Change #ifdefs and #defines. (Ken Takata)
2015-01-14 14:04:10 +01:00
9da7ff70cc Updated runtime files. 2015-01-14 12:52:36 +01:00
651863c94a updated for version 7.4.569
Problem:    Having CTRL-C interrupt or not does not check the mode of the
            mapping. (Ingo Karkat)
Solution:   Use a bitmask with the map mode. (Christian Brabandt)
2015-01-14 12:44:41 +01:00
8be6388b76 updated for version 7.4.568
Problem:    Giving an error for ":0wincmd w" is a problem for some plugins.
Solution:   Allow the zero in the range. (Marcin Szamotulski)
2015-01-14 11:25:05 +01:00
e271909625 Updated syntax files. 2015-01-10 15:09:25 +01:00
c60c4f6e06 updated for version 7.4.567
Problem:    Non-ascii vertical separater characters are always redrawn.
Solution:   Compare only the one byte that's stored. (Thiago Padilha)
2015-01-07 19:04:28 +01:00
8feef4ff62 Update runtime files. 2015-01-07 16:57:10 +01:00
a162bc555e updated for version 7.4.566
Problem:    :argdo, :bufdo, :windo and :tabdo don't take a range.
Solution:   Support the range. (Marcin Szamotulski)
2015-01-07 16:54:21 +01:00
3ffc79a4a8 updated for version 7.4.565
Problem:    Ranges for arguments, buffers, tabs, etc. are not checked to be
            valid but limited to the maximum.  This can cause the wrong thing
            to happen.
Solution:   Give an error for an invalid value. (Marcin Szamotulski)
            Use windows range for ":wincmd".
2015-01-07 15:57:17 +01:00
49a6ed8a8a updated for version 7.4.564
Problem:    FEAT_OSFILETYPE is used even though it's never defined.
Solution:   Remove the code. (Christian Brabandt)
2015-01-07 14:43:39 +01:00
684d409f63 updated for version 7.4.563
Problem:    No test for replacing on a tab in Virtual replace mode.
Solution:   Add a test. (Elias Diem)
2015-01-07 14:02:52 +01:00
0027c218e9 updated for version 7.4.562
Problem:    Segfault with wide screen and error in 'rulerformat'. (Ingo Karkat)
Solution:   Check there is enough space. (Christian Brabandt)
2015-01-07 13:31:52 +01:00
abe382cd2a updated for version 7.4.561
Problem:    Ex range handling is wrong for buffer-local user commands.
Solution:   Check for CMD_USER_BUF. (Marcin Szamotulski)
2015-01-07 13:15:45 +01:00
e88b0033f6 updated for version 7.4.560
Problem:    Memory leak using :wviminfo. Issue 296.
Solution:   Free memory when needed. (idea by Christian Brabandt)
2014-12-17 21:00:49 +01:00
fc3f23bedf updated for version 7.4.559
Problem:    Appending a block in the middle of a tab does not work correctly
            when virtualedit is set.
Solution:   Decrement spaces and count, don't reset them. (James McCoy)
2014-12-17 18:35:42 +01:00
309 changed files with 17422 additions and 5980 deletions

2
.gitignore vendored
View File

@ -69,5 +69,7 @@ src/testdir/lua.vim
src/testdir/small.vim
src/testdir/tiny.vim
src/testdir/test*.out
src/testdir/test*.failed
src/testdir/test.log
src/testdir/dostmp/*
src/memfile_test

View File

@ -481,6 +481,7 @@ SRC_EXTRA = \
# runtime files for all distributions
RT_ALL = \
README.txt \
README.md \
runtime/bugreport.vim \
runtime/doc/*.awk \
runtime/doc/*.pl \

112
README.md Normal file
View File

@ -0,0 +1,112 @@
`README.md` for version 7.4 of Vim: Vi IMproved.
## What is VIM ##
Vim is an almost compatible version of the UNIX editor Vi. Many new features
have been added: multi-level undo, syntax highlighting, command line history,
on-line help, spell checking, filename completion, block operations, etc.
There is also a Graphical User Interface (GUI) available. See
`runtime/doc/vi_diff.txt` for differences with Vi.
This editor is very useful for editing programs and other plain text files.
All commands are given with normal keyboard characters, so those who can type
with ten fingers can work very fast. Additionally, function keys can be
defined by the user, and the mouse can be used.
Vim runs under Amiga DOS, MS-DOS, MS-Windows (95, 98, Me, NT, 2000, XP, Vista,
7), Atari MiNT, Macintosh, BeOS, VMS, RISC OS, OS/2 and almost all flavours of
UNIX. Porting to other systems should not be very difficult.
## Distribution ##
There are separate distributions for Unix, PC, Amiga and some other systems.
This `README.md` file comes with the runtime archive. It includes the
documentation, syntax files and other files that are used at runtime. To run
Vim you must get either one of the binary archives or a source archive.
Which one you need depends on the system you want to run it on and whether you
want or must compile it yourself. Check http://www.vim.org/download.php for
an overview of currently available distributions.
## Documentation ##
The vim tutor is a one hour training course for beginners. Mostly it can be
started as `vimtutor`. See `:help tutor` for more information.
The best is to use `:help` in Vim. If you don't have an executable yet, read
`runtime/doc/help.txt`. It contains pointers to the other documentation
files. The User Manual reads like a book and is recommended to learn to use
Vim. See `:help user-manual`.
## Copying ##
Vim is Charityware. You can use and copy it as much as you like, but you are
encouraged to make a donation to help orphans in Uganda. Please read the file
`runtime/doc/uganda.txt` for details (do `:help uganda` inside Vim).
Summary of the license: There are no restrictions on using or distributing an
unmodified copy of Vim. Parts of Vim may also be distributed, but the license
text must always be included. For modified versions a few restrictions apply.
The license is GPL compatible, you may compile Vim with GPL libraries and
distribute it.
## Sponsoring ##
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 `runtime/doc/uganda.txt`. 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/
## Compiling ##
If you obtained a binary distribution you don't need to compile Vim. If you
obtained a source distribution, all the stuff for compiling Vim is in the
`src` directory. See `src/INSTALL` for instructions.
## Installation ##
See one of these files for system-specific instructions:
README_ami.txt Amiga
README_unix.txt Unix
README_dos.txt MS-DOS and MS-Windows
README_os2.txt OS/2
README_mac.txt Macintosh
README_vms.txt VMS
There are more `README_*.txt` files, depending on the distribution you used.
## Information ##
The latest news about Vim can be found on the Vim home page:
http://www.vim.org/
If you have problems, have a look at the Vim documentation or tips:
http://www.vim.org/docs.php
http://vim.wikia.com/wiki/Vim_Tips_Wiki
If you still have problems or any other questions, use one of the mailing
lists to discuss them with Vim users and developers:
http://www.vim.org/maillist.php
If nothing else works, report bugs directly:
Bram Moolenaar <Bram@vim.org>
## Main author ##
Send any other comments, patches, flowers and suggestions to:
Bram Moolenaar <Bram@vim.org>

View File

@ -94,8 +94,9 @@ INFORMATION
The latest news about Vim can be found on the Vim home page:
http://www.vim.org/
If you have problems, have a look at the Vim FAQ:
http://vimdoc.sf.net/vimfaq.html
If you have problems, have a look at the Vim documentation or tips:
http://www.vim.org/docs.php
http://vim.wikia.com/wiki/Vim_Tips_Wiki
If you still have problems or any other questions, use one of the mailing
lists to discuss them with Vim users and developers:
@ -110,6 +111,3 @@ MAIN AUTHOR
Send any other comments, patches, flowers and suggestions to:
Bram Moolenaar E-mail: Bram@vim.org
Finsterruetihof 1
8134 Adliswil
Switzerland

File diff suppressed because it is too large Load Diff

View File

@ -1,7 +1,7 @@
" netrwSettings.vim: makes netrw settings simpler
" Date: Aug 27, 2013
" Date: Dec 30, 2014
" Maintainer: Charles E Campbell <drchipNOSPAM at campbellfamily dot biz>
" Version: 14
" Version: 15
" Copyright: Copyright (C) 1999-2007 Charles E. Campbell {{{1
" Permission is hereby granted to use and distribute this code,
" with or without modifications, provided that this copyright
@ -19,7 +19,7 @@
if exists("g:loaded_netrwSettings") || &cp
finish
endif
let g:loaded_netrwSettings = "v14"
let g:loaded_netrwSettings = "v15"
if v:version < 700
echohl WarningMsg
echo "***warning*** this version of netrwSettings needs vim 7.0"
@ -31,7 +31,7 @@ endif
" NetrwSettings: {{{1
fun! netrwSettings#NetrwSettings()
" this call is here largely just to insure that netrw has been loaded
call netrw#NetrwSavePosn()
call netrw#SavePosn()
if !exists("g:loaded_netrw")
echohl WarningMsg | echomsg "***sorry*** netrw needs to be loaded prior to using NetrwSettings" | echohl None
return
@ -177,6 +177,7 @@ fun! netrwSettings#NetrwSettings()
put = 'let g:netrw_sort_direction = '.g:netrw_sort_direction
put = 'let g:netrw_sort_options = '.g:netrw_sort_options
put = 'let g:netrw_sort_sequence = '.g:netrw_sort_sequence
put = 'let g:netrw_servername = '.g:netrw_servername
put = 'let g:netrw_special_syntax = '.g:netrw_special_syntax
put = 'let g:netrw_ssh_browse_reject = '.g:netrw_ssh_browse_reject
put = 'let g:netrw_ssh_cmd = '.g:netrw_ssh_cmd

View File

@ -61,9 +61,16 @@ function! netrw_gitignore#Hide(...)
" convert gitignore patterns to Netrw/Vim regex patterns
let escaped_lines = []
for line in gitignore_lines
let escaped = line
let escaped = substitute(escaped, '\.', '\\.', 'g')
let escaped = substitute(escaped, '*', '.*', 'g')
let escaped = line
let escaped = substitute(escaped, '\*\*', '*', 'g')
let escaped = substitute(escaped, '\.', '\\.', 'g')
let escaped = substitute(escaped, '\$', '\\$', 'g')
let escaped = substitute(escaped, '*', '.*', 'g')
" correction: dot, dollar and asterisks chars shouldn't be escaped when
" within regex matching groups.
let escaped = substitute(escaped, '\(\[[^]]*\)\zs\\\.', '\.', 'g')
let escaped = substitute(escaped, '\(\[[^]]*\)\zs\\\$', '\$', 'g')
let escaped = substitute(escaped, '\(\[[^]]*\)\zs\.\*', '*', 'g')
let escaped_lines = add(escaped_lines, escaped)
endfor

View File

@ -3,7 +3,7 @@
" Maintainer: Dávid Szabó ( complex857 AT gmail DOT com )
" Previous Maintainer: Mikolaj Machowski ( mikmach AT wp DOT pl )
" URL: https://github.com/shawncplus/phpcomplete.vim
" Last Change: 2014 Dec 01
" Last Change: 2015 Jul 13
"
" OPTIONS:
"
@ -141,71 +141,80 @@ function! phpcomplete#CompletePHP(findstart, base) " {{{
if a:base != ""
let context = substitute(context, '\s*[$a-zA-Z_0-9\x7f-\xff]*$', '', '')
end
else
let context = ''
end
let [current_namespace, imports] = phpcomplete#GetCurrentNameSpace(getline(0, line('.')))
try
let winheight = winheight(0)
let winnr = winnr()
if context =~? '^use\s'
return phpcomplete#CompleteUse(a:base)
endif
let [current_namespace, imports] = phpcomplete#GetCurrentNameSpace(getline(0, line('.')))
if context =~ '\(->\|::\)$'
" {{{
" Get name of the class
let classname = phpcomplete#GetClassName(line('.'), context, current_namespace, imports)
if context =~? '^use\s' || context ==? 'use'
return phpcomplete#CompleteUse(a:base)
endif
" Get location of class definition, we have to iterate through all
if classname != ''
if classname =~ '\'
" split the last \ segment as a classname, everything else is the namespace
let classname_parts = split(classname, '\')
let namespace = join(classname_parts[0:-2], '\')
let classname = classname_parts[-1]
if context =~ '\(->\|::\)$'
" {{{
" Get name of the class
let classname = phpcomplete#GetClassName(line('.'), context, current_namespace, imports)
" Get location of class definition, we have to iterate through all
if classname != ''
if classname =~ '\'
" split the last \ segment as a classname, everything else is the namespace
let classname_parts = split(classname, '\')
let namespace = join(classname_parts[0:-2], '\')
let classname = classname_parts[-1]
else
let namespace = '\'
endif
let classlocation = phpcomplete#GetClassLocation(classname, namespace)
else
let namespace = '\'
let classlocation = ''
endif
let classlocation = phpcomplete#GetClassLocation(classname, namespace)
if classlocation != ''
if classlocation == 'VIMPHP_BUILTINOBJECT' && has_key(g:php_builtin_classes, tolower(classname))
return phpcomplete#CompleteBuiltInClass(context, classname, a:base)
endif
if filereadable(classlocation)
let classfile = readfile(classlocation)
let classcontent = ''
let classcontent .= "\n".phpcomplete#GetClassContents(classlocation, classname)
let sccontent = split(classcontent, "\n")
let visibility = expand('%:p') == fnamemodify(classlocation, ':p') ? 'private' : 'public'
return phpcomplete#CompleteUserClass(context, a:base, sccontent, visibility)
endif
endif
return phpcomplete#CompleteUnknownClass(a:base, context)
" }}}
elseif context =~? 'implements'
return phpcomplete#CompleteClassName(a:base, ['i'], current_namespace, imports)
elseif context =~? 'extends\s\+.\+$' && a:base == ''
return ['implements']
elseif context =~? 'extends'
let kinds = context =~? 'class\s' ? ['c'] : ['i']
return phpcomplete#CompleteClassName(a:base, kinds, current_namespace, imports)
elseif context =~? 'class [a-zA-Z_\x7f-\xff\\][a-zA-Z_0-9\x7f-\xff\\]*'
" special case when you've typed the class keyword and the name too, only extends and implements allowed there
return filter(['extends', 'implements'], 'stridx(v:val, a:base) == 0')
elseif context =~? 'new'
return phpcomplete#CompleteClassName(a:base, ['c'], current_namespace, imports)
endif
if a:base =~ '^\$'
return phpcomplete#CompleteVariable(a:base)
else
let classlocation = ''
return phpcomplete#CompleteGeneral(a:base, current_namespace, imports)
endif
if classlocation != ''
if classlocation == 'VIMPHP_BUILTINOBJECT' && has_key(g:php_builtin_classes, tolower(classname))
return phpcomplete#CompleteBuiltInClass(context, classname, a:base)
endif
if filereadable(classlocation)
let classfile = readfile(classlocation)
let classcontent = ''
let classcontent .= "\n".phpcomplete#GetClassContents(classlocation, classname)
let sccontent = split(classcontent, "\n")
let visibility = expand('%:p') == fnamemodify(classlocation, ':p') ? 'private' : 'public'
return phpcomplete#CompleteUserClass(context, a:base, sccontent, visibility)
endif
endif
return phpcomplete#CompleteUnknownClass(a:base, context)
" }}}
elseif context =~? 'implements'
return phpcomplete#CompleteClassName(a:base, ['i'], current_namespace, imports)
elseif context =~? 'extends\s\+.\+$'
return ['implements']
elseif context =~? 'extends'
let kinds = context =~? 'class\s' ? ['c'] : ['i']
return phpcomplete#CompleteClassName(a:base, kinds, current_namespace, imports)
elseif context =~? 'class [a-zA-Z_\x7f-\xff\\][a-zA-Z_0-9\x7f-\xff\\]*'
" special case when you've typed the class keyword and the name too, only extends and implements allowed there
return filter(['extends', 'implements'], 'stridx(v:val, a:base) == 0')
elseif context =~? 'new'
return phpcomplete#CompleteClassName(a:base, ['c'], current_namespace, imports)
endif
if a:base =~ '^\$'
return phpcomplete#CompleteVariable(a:base)
else
return phpcomplete#CompleteGeneral(a:base, current_namespace, imports)
endif
finally
silent! exec winnr.'resize '.winheight
endtry
endfunction
" }}}
@ -244,12 +253,13 @@ function! phpcomplete#CompleteUse(base) " {{{
if has_key(tag, 'namespace')
let patched_ctags_detected = 1
endif
if tag.kind ==? 'n' && tag.name =~? '^'.namespace_match_pattern
let patched_ctags_detected = 1
call add(namespaced_matches, {'word': tag.name, 'kind': 'n', 'menu': tag.filename, 'info': tag.filename })
elseif has_key(tag, 'namespace') && (tag.kind ==? 'c' || tag.kind ==? 'i') && tag.namespace ==? namespace_for_class
elseif has_key(tag, 'namespace') && (tag.kind ==? 'c' || tag.kind ==? 'i' || tag.kind ==? 't') && tag.namespace ==? namespace_for_class
call add(namespaced_matches, {'word': namespace_for_class.'\'.tag.name, 'kind': tag.kind, 'menu': tag.filename, 'info': tag.filename })
elseif (tag.kind ==? 'c' || tag.kind ==? 'i')
elseif (tag.kind ==? 'c' || tag.kind ==? 'i' || tag.kind ==? 't')
call add(no_namespace_matches, {'word': namespace_for_class.'\'.tag.name, 'kind': tag.kind, 'menu': tag.filename, 'info': tag.filename })
endif
endfor
@ -272,6 +282,10 @@ function! phpcomplete#CompleteUse(base) " {{{
endfor
endif
for comp in res
let comp.word = substitute(comp.word, '^\\', '', '')
endfor
return res
endfunction
" }}}
@ -304,7 +318,7 @@ function! phpcomplete#CompleteGeneral(base, current_namespace, imports) " {{{
\ '^&\?\zs[a-zA-Z_\x7f-\xff][a-zA-Z_0-9\x7f-\xff]*\ze')
if f_name =~? '^'.substitute(a:base, '\\', '\\\\', 'g')
let f_args = matchstr(i,
\ '^&\?[a-zA-Z_\x7f-\xff][a-zA-Z_0-9\x7f-\xff]*\s*(\zs.\{-}\ze)\_s*\({\|$\)')
\ '^&\?[a-zA-Z_\x7f-\xff][a-zA-Z_0-9\x7f-\xff]*\s*(\zs.\{-}\ze)\_s*\(;\|{\|$\)')
let int_functions[f_name.'('] = f_args.')'
endif
endfor
@ -326,6 +340,7 @@ function! phpcomplete#CompleteGeneral(base, current_namespace, imports) " {{{
let ext_functions = {}
let ext_constants = {}
let ext_classes = {}
let ext_traits = {}
let ext_interfaces = {}
let ext_namespaces = {}
@ -420,7 +435,7 @@ function! phpcomplete#CompleteGeneral(base, current_namespace, imports) " {{{
endif
endif
endif
elseif tag.kind ==? 'c' || tag.kind ==? 'i'
elseif tag.kind ==? 'c' || tag.kind ==? 'i' || tag.kind ==? 't'
let info = ' - '.tag.filename
let key = ''
@ -441,6 +456,8 @@ function! phpcomplete#CompleteGeneral(base, current_namespace, imports) " {{{
let ext_classes[key] = info
elseif tag.kind ==? 'i'
let ext_interfaces[key] = info
elseif tag.kind ==? 't'
let ext_traits[key] = info
endif
endif
endif
@ -463,7 +480,7 @@ function! phpcomplete#CompleteGeneral(base, current_namespace, imports) " {{{
endfor
for [interfacename, info] in items(g:php_builtin_interfacenames)
if interfacename =~? '^'.base
let builtin_interfaces[leading_slash.interfacename] = info
let builtin_interfaces[leading_slash.g:php_builtin_interfaces[tolower(interfacename)].name] = info
endif
endfor
endif
@ -511,6 +528,8 @@ function! phpcomplete#CompleteGeneral(base, current_namespace, imports) " {{{
else
let ext_interfaces[imported_name] = ' '.import.name.' - '.import.filename
endif
elseif import.kind ==? 't'
let ext_traits[imported_name] = ' '.import.name.' - '.import.filename
endif
" no builtin interfaces
@ -540,6 +559,9 @@ function! phpcomplete#CompleteGeneral(base, current_namespace, imports) " {{{
" Add external interfaces
call extend(all_values, ext_interfaces)
" Add external traits
call extend(all_values, ext_traits)
" Add built-in classes
call extend(all_values, builtin_classnames)
@ -566,6 +588,8 @@ function! phpcomplete#CompleteGeneral(base, current_namespace, imports) " {{{
elseif has_key(ext_interfaces, i) || has_key(builtin_interfaces, i)
let info = has_key(ext_interfaces, i) ? ext_interfaces[i] : builtin_interfaces[i].' - builtin'
let final_list += [{'word':i, 'kind': 'i', 'menu': info, 'info': i.info}]
elseif has_key(ext_traits, i)
let final_list += [{'word':i, 'kind': 't', 'menu': ext_traits[i], 'info': ext_traits[i]}]
elseif has_key(int_constants, i) || has_key(builtin_constants, i)
let info = has_key(int_constants, i) ? int_constants[i] : ' - builtin'
let final_list += [{'word':i, 'kind': 'd', 'menu': info, 'info': i.info}]
@ -622,7 +646,7 @@ function! phpcomplete#CompleteUnknownClass(base, context) " {{{
let f_name = matchstr(i,
\ '^&\?\zs[a-zA-Z_\x7f-\xff][a-zA-Z_0-9\x7f-\xff]*\ze')
let f_args = matchstr(i,
\ '^&\?[a-zA-Z_\x7f-\xff][a-zA-Z_0-9\x7f-\xff]*\s*(\zs.\{-}\ze)\_s*\({\|$\)')
\ '^&\?[a-zA-Z_\x7f-\xff][a-zA-Z_0-9\x7f-\xff]*\s*(\zs.\{-}\ze)\_s*\(;\|{\|$\)')
let int_functions[f_name.'('] = f_args.')'
endfor
@ -784,7 +808,7 @@ function! phpcomplete#CompleteClassName(base, kinds, current_namespace, imports)
let tags = []
if len(tag_match_pattern) >= g:phpcomplete_min_num_of_chars_for_namespace_completion
let tags = phpcomplete#GetTaglist('^'.tag_match_pattern)
let tags = phpcomplete#GetTaglist('^\c'.tag_match_pattern)
endif
if len(tags)
@ -861,6 +885,39 @@ function! phpcomplete#CompareCompletionRow(i1, i2) " {{{
endfunction
" }}}
function! s:getNextCharWithPos(filelines, current_pos) " {{{
let line_no = a:current_pos[0]
let col_no = a:current_pos[1]
let last_line = a:filelines[len(a:filelines) - 1]
let end_pos = [len(a:filelines) - 1, strlen(last_line) - 1]
if line_no > end_pos[0] || line_no == end_pos[0] && col_no > end_pos[1]
return ['EOF', 'EOF']
endif
" we've not reached the end of the current line break
if col_no + 1 < strlen(a:filelines[line_no])
let col_no += 1
else
" we've reached the end of the current line, jump to the next
" non-blank line (blank lines have no position where we can read from,
" not even a whitespace. The newline char does not positionable by vim
let line_no += 1
while strlen(a:filelines[line_no]) == 0
let line_no += 1
endwhile
let col_no = 0
endif
" return 'EOF' string to signal end of file, normal results only one char
" in length
if line_no == end_pos[0] && col_no > end_pos[1]
return ['EOF', 'EOF']
endif
return [[line_no, col_no], a:filelines[line_no][col_no]]
endfunction " }}}
function! phpcomplete#EvaluateModifiers(modifiers, required_modifiers, prohibited_modifiers) " {{{
" if theres no modifier, and no modifier is allowed and no modifier is required
if len(a:modifiers) == 0 && len(a:required_modifiers) == 0
@ -924,7 +981,7 @@ function! phpcomplete#CompleteUserClass(context, base, sccontent, visibility) "
let f_name = matchstr(i,
\ 'function\s*&\?\zs[a-zA-Z_\x7f-\xff][a-zA-Z_0-9\x7f-\xff]*\ze')
let f_args = matchstr(i,
\ 'function\s*&\?[a-zA-Z_\x7f-\xff][a-zA-Z_0-9\x7f-\xff]*\s*(\zs.\{-}\ze)\_s*\({\|\_$\)')
\ 'function\s*&\?[a-zA-Z_\x7f-\xff][a-zA-Z_0-9\x7f-\xff]*\s*(\zs.\{-}\ze)\_s*\(;\|{\|\_$\)')
if f_name != '' && stridx(f_name, '__') != 0
let c_functions[f_name.'('] = f_args
if g:phpcomplete_parse_docblock_comments
@ -1322,8 +1379,8 @@ function! phpcomplete#GetCallChainReturnType(classname_candidate, class_candidat
" Get Structured information of all classes and subclasses including namespace and includes
" try to find the method's return type in docblock comment
for classstructure in classcontents
let doclock_target_pattern = 'function\s\+&\?'.method.'\|\(public\|private\|protected\|var\).\+\$'.method
let doc_str = phpcomplete#GetDocBlock(split(classstructure.content, '\n'), doclock_target_pattern)
let docblock_target_pattern = 'function\s\+&\?'.method.'\|\(public\|private\|protected\|var\).\+\$'.method
let doc_str = phpcomplete#GetDocBlock(split(classstructure.content, '\n'), docblock_target_pattern)
if doc_str != ''
break
endif
@ -1475,21 +1532,19 @@ function! phpcomplete#GetClassName(start_line, context, current_namespace, impor
return ''
endif
if line =~? '\v^\s*(abstract\s+|final\s+)*\s*class'
let class_name = matchstr(line, '\c\s*class\s*\zs'.class_name_pattern.'\ze')
if line =~? '\v^\s*(abstract\s+|final\s+)*\s*class\s'
let class_name = matchstr(line, '\cclass\s\+\zs'.class_name_pattern.'\ze')
let extended_class = matchstr(line, '\cclass\s\+'.class_name_pattern.'\s\+extends\s\+\zs'.class_name_pattern.'\ze')
let classname_candidate = a:context =~? 'parent::' ? extended_class : class_name
else
let i += 1
continue
if classname_candidate != ''
let [classname_candidate, class_candidate_namespace] = phpcomplete#GetCallChainReturnType(classname_candidate, class_candidate_namespace, class_candidate_imports, methodstack)
" return absolute classname, without leading \
return (class_candidate_namespace == '\' || class_candidate_namespace == '') ? classname_candidate : class_candidate_namespace.'\'.classname_candidate
endif
endif
if classname_candidate != ''
let [classname_candidate, class_candidate_namespace] = phpcomplete#GetCallChainReturnType(classname_candidate, class_candidate_namespace, class_candidate_imports, methodstack)
" return absolute classname, without leading \
return (class_candidate_namespace == '\' || class_candidate_namespace == '') ? classname_candidate : class_candidate_namespace.'\'.classname_candidate
endif
let i += 1
endwhile
elseif a:context =~? '(\s*new\s\+'.class_name_pattern.'\s*)->'
let classname_candidate = matchstr(a:context, '\cnew\s\+\zs'.class_name_pattern.'\ze')
@ -1602,26 +1657,26 @@ function! phpcomplete#GetClassName(start_line, context, current_namespace, impor
endif
endif
" in-file lookup for typehinted function arguments
" - the function can have a name or be anonymous (e.g., function qux() { ... } vs. function () { ... })
" - the type-hinted argument can be anywhere in the arguments list.
if line =~? 'function\(\s\+'.function_name_pattern.'\)\?\s*(.\{-}'.class_name_pattern.'\s\+'.object && !object_is_array
let f_args = matchstr(line, '\cfunction\(\s\+'.function_name_pattern.'\)\?\s*(\zs.\{-}\ze)')
let args = split(f_args, '\s*\zs,\ze\s*')
for arg in args
if arg =~# object.'\(,\|$\)'
let classname_candidate = matchstr(arg, '\s*\zs'.class_name_pattern.'\ze\s\+'.object)
let [classname_candidate, class_candidate_namespace] = phpcomplete#ExpandClassName(classname_candidate, a:current_namespace, a:imports)
" function declaration line
if line =~? 'function\(\s\+'.function_name_pattern.'\)\?\s*('
let function_lines = join(reverse(copy(lines)), " ")
" search for type hinted arguments
if function_lines =~? 'function\(\s\+'.function_name_pattern.'\)\?\s*(.\{-}'.class_name_pattern.'\s\+'.object && !object_is_array
let f_args = matchstr(function_lines, '\cfunction\(\s\+'.function_name_pattern.'\)\?\s*(\zs.\{-}\ze)')
let args = split(f_args, '\s*\zs,\ze\s*')
for arg in args
if arg =~# object.'\(,\|$\)'
let classname_candidate = matchstr(arg, '\s*\zs'.class_name_pattern.'\ze\s\+'.object)
let [classname_candidate, class_candidate_namespace] = phpcomplete#ExpandClassName(classname_candidate, a:current_namespace, a:imports)
break
endif
endfor
if classname_candidate != ''
break
endif
endfor
if classname_candidate != ''
break
endif
endif
" if we see a function declaration, try loading the docblock for it and look for matching @params
if line =~? 'function\(\s\+'.function_name_pattern.'\)\?\s*(.\{-}'.object
" search for docblock for the function
let match_line = substitute(line, '\\', '\\\\', 'g')
let sccontent = getline(0, a:start_line - i)
let doc_str = phpcomplete#GetDocBlock(sccontent, match_line)
@ -1641,13 +1696,16 @@ function! phpcomplete#GetClassName(start_line, context, current_namespace, impor
endif
" assignment for the variable in question with a variable on the right hand side
if line =~# '^\s*'.object.'\s*=&\?\s*'.variable_name_pattern
if line =~# '^\s*'.object.'\s*=&\?\s\+\(clone\)\?\s*'.variable_name_pattern
" try to find the next non-comment or string ";" char
let start_col = match(line, '^\s*'.object.'\C\s*=\zs&\?\s*'.variable_name_pattern)
let filelines = reverse(lines)
let [pos, char] = s:getNextCharWithPos(filelines, [a:start_line - i - 1, start_col])
let start_col = match(line, '^\s*'.object.'\C\s*=\zs&\?\s\+\(clone\)\?\s*'.variable_name_pattern)
let filelines = reverse(copy(lines))
let [pos, char] = s:getNextCharWithPos(filelines, [len(filelines) - i, start_col])
let chars_read = 1
let last_pos = pos
" function_boundary == 0 if we are not in a function
let real_lines_offset = len(function_boundary) == 1 ? 1 : function_boundary[0][0]
" read while end of the file
while char != 'EOF' && chars_read < 1000
let last_pos = pos
@ -1655,7 +1713,11 @@ function! phpcomplete#GetClassName(start_line, context, current_namespace, impor
let chars_read += 1
" we got a candidate
if char == ';'
let synIDName = synIDattr(synID(pos[0] + 1, pos[1] + 1, 0), 'name')
" pos values is relative to the function's lines,
" line 0 need to be offsetted with the line number
" where te function was started to get the line number
" in real buffer terms
let synIDName = synIDattr(synID(real_lines_offset + pos[0], pos[1] + 1, 0), 'name')
" it's not a comment or string, end search
if synIDName !~? 'comment\|string'
break
@ -1663,7 +1725,7 @@ function! phpcomplete#GetClassName(start_line, context, current_namespace, impor
endif
endwhile
let prev_context = phpcomplete#GetCurrentInstruction(last_pos[0] + 1, last_pos[1], b:phpbegin)
let prev_context = phpcomplete#GetCurrentInstruction(real_lines_offset + last_pos[0], last_pos[1], b:phpbegin)
if prev_context == ''
" cannot get previous context give up
return
@ -1683,12 +1745,14 @@ function! phpcomplete#GetClassName(start_line, context, current_namespace, impor
" assignment for the variable in question with a function on the right hand side
if line =~# '^\s*'.object.'\s*=&\?\s*'.function_invocation_pattern
" try to find the next non-comment or string ";" char
let start_col = match(line, '\C^\s*'.object.'\s*=\zs&\?\s*'.function_invocation_pattern)
let filelines = reverse(lines)
let [pos, char] = s:getNextCharWithPos(filelines, [a:start_line - i - 1, start_col])
let filelines = reverse(copy(lines))
let [pos, char] = s:getNextCharWithPos(filelines, [len(filelines) - i, start_col])
let chars_read = 1
let last_pos = pos
" function_boundary == 0 if we are not in a function
let real_lines_offset = len(function_boundary) == 1 ? 1 : function_boundary[0][0]
" read while end of the file
while char != 'EOF' && chars_read < 1000
let last_pos = pos
@ -1696,7 +1760,11 @@ function! phpcomplete#GetClassName(start_line, context, current_namespace, impor
let chars_read += 1
" we got a candidate
if char == ';'
let synIDName = synIDattr(synID(pos[0] + 1, pos[1] + 1, 0), 'name')
" pos values is relative to the function's lines,
" line 0 need to be offsetted with the line number
" where te function was started to get the line number
" in real buffer terms
let synIDName = synIDattr(synID(real_lines_offset + pos[0], pos[1] + 1, 0), 'name')
" it's not a comment or string, end search
if synIDName !~? 'comment\|string'
break
@ -1704,7 +1772,7 @@ function! phpcomplete#GetClassName(start_line, context, current_namespace, impor
endif
endwhile
let prev_context = phpcomplete#GetCurrentInstruction(last_pos[0] + 1, last_pos[1], b:phpbegin)
let prev_context = phpcomplete#GetCurrentInstruction(real_lines_offset + last_pos[0], last_pos[1], b:phpbegin)
if prev_context == ''
" cannot get previous context give up
return
@ -1807,6 +1875,9 @@ function! phpcomplete#GetClassLocation(classname, namespace) " {{{
if has_key(g:php_builtin_classes, tolower(a:classname)) && (a:namespace == '' || a:namespace == '\')
return 'VIMPHP_BUILTINOBJECT'
endif
if has_key(g:php_builtin_interfaces, tolower(a:classname)) && (a:namespace == '' || a:namespace == '\')
return 'VIMPHP_BUILTINOBJECT'
endif
if a:namespace == '' || a:namespace == '\'
let search_namespace = '\'
@ -1819,7 +1890,7 @@ function! phpcomplete#GetClassLocation(classname, namespace) " {{{
let i = 1
while i < line('.')
let line = getline(line('.')-i)
if line =~? '^\s*\(abstract\s\+\|final\s\+\)*\s*class\s*'.a:classname.'\(\s\+\|$\)' && tolower(current_namespace) == search_namespace
if line =~? '^\s*\(abstract\s\+\|final\s\+\)*\s*\(class\|interface\|trait\)\s*'.a:classname.'\(\s\+\|$\|{\)' && tolower(current_namespace) == search_namespace
return expand('%:p')
else
let i += 1
@ -1831,7 +1902,9 @@ function! phpcomplete#GetClassLocation(classname, namespace) " {{{
let no_namespace_candidate = ''
let tags = phpcomplete#GetTaglist('^'.a:classname.'$')
for tag in tags
if tag.kind == 'c' || tag.kind == 'i'
" We'll allow interfaces and traits to be handled classes since you
" can't have colliding names with different kinds anyway
if tag.kind == 'c' || tag.kind == 'i' || tag.kind == 't'
if !has_key(tag, 'namespace')
let no_namespace_candidate = tag.filename
else
@ -1981,7 +2054,7 @@ function! phpcomplete#GetClassContentsStructure(file_path, file_lines, class_nam
silent! below 1new
silent! 0put =cfile
call search('\(class\|interface\)\_s\+'.a:class_name.'\(\>\|$\)')
call search('\c\(class\|interface\|trait\)\_s\+'.a:class_name.'\(\>\|$\)')
let cfline = line('.')
call search('{')
let endline = line('.')
@ -1989,13 +2062,62 @@ function! phpcomplete#GetClassContentsStructure(file_path, file_lines, class_nam
let content = join(getline(cfline, endline), "\n")
" Catch extends
if content =~? 'extends'
let extends_class = matchstr(content, 'class\_s\+'.a:class_name.'\_s\+extends\_s\+\zs'.class_name_pattern.'\ze')
let extends_string = matchstr(content, '\(class\|interface\)\_s\+'.a:class_name.'\_.\+extends\_s\+\zs\('.class_name_pattern.'\(,\|\_s\)*\)\+\ze\(extends\|{\)')
let extended_classes = map(split(extends_string, '\(,\|\_s\)\+'), 'substitute(v:val, "\\_s\\+", "", "g")')
else
let extends_class = ''
let extended_classes = ''
endif
" Catch implements
if content =~? 'implements'
let implements_string = matchstr(content, 'class\_s\+'.a:class_name.'\_.\+implements\_s\+\zs\('.class_name_pattern.'\(,\|\_s\)*\)\+\ze')
let implemented_interfaces = map(split(implements_string, '\(,\|\_s\)\+'), 'substitute(v:val, "\\_s\\+", "", "g")')
else
let implemented_interfaces = []
endif
call searchpair('{', '', '}', 'W')
let classcontent = join(getline(cfline, line('.')), "\n")
let class_closing_bracket_line = line('.')
let classcontent = join(getline(cfline, class_closing_bracket_line), "\n")
let used_traits = []
" move back to the line next to the class's definition
call cursor(endline + 1, 1)
let keep_searching = 1
while keep_searching != 0
" try to grab "use..." keywords
let [lnum, col] = searchpos('\c^\s\+use\s\+'.class_name_pattern, 'cW', class_closing_bracket_line)
let syn_name = synIDattr(synID(lnum, col, 0), "name")
if syn_name =~? 'string\|comment'
call cursor(lnum + 1, 1)
continue
endif
let trait_line = getline(lnum)
if trait_line !~? ';'
" try to find the next line containing ';'
let l = lnum
let search_line = trait_line
" add lines from the file until theres no ';' in them
while search_line !~? ';' && l > 0
" file lines are reversed so we need to go backwards
let l += 1
let search_line = getline(l)
let trait_line .= ' '.substitute(search_line, '\(^\s\+\|\s\+$\)', '', 'g')
endwhile
endif
let use_expression = matchstr(trait_line, '^\s*use\s\+\zs.\{-}\ze;')
let use_parts = map(split(use_expression, '\s*,\s*'), 'substitute(v:val, "\\s+", " ", "g")')
let used_traits += map(use_parts, 'substitute(v:val, "\\s", "", "g")')
call cursor(lnum + 1, 1)
if [lnum, col] == [0, 0]
let keep_searching = 0
endif
endwhile
silent! bw! %
let [current_namespace, imports] = phpcomplete#GetCurrentNameSpace(a:file_lines[0:cfline])
" go back to original window
exe phpcomplete_original_window.'wincmd w'
@ -2008,21 +2130,35 @@ function! phpcomplete#GetClassContentsStructure(file_path, file_lines, class_nam
\ 'mtime': getftime(full_file_path),
\ })
if extends_class != ''
let [extends_class, namespace] = phpcomplete#ExpandClassName(extends_class, current_namespace, imports)
if namespace == ''
let namespace = '\'
endif
let classlocation = phpcomplete#GetClassLocation(extends_class, namespace)
if classlocation == "VIMPHP_BUILTINOBJECT"
let result += [phpcomplete#GenerateBuiltinClassStub(g:php_builtin_classes[tolower(extends_class)])]
elseif classlocation != '' && filereadable(classlocation)
let full_file_path = fnamemodify(classlocation, ':p')
let result += phpcomplete#GetClassContentsStructure(full_file_path, readfile(full_file_path), extends_class)
elseif tolower(current_namespace) == tolower(namespace)
" try to find the declaration in the same file.
let result += phpcomplete#GetClassContentsStructure(full_file_path, a:file_lines, extends_class)
endif
let all_extends = used_traits
if len(extended_classes) > 0
call extend(all_extends, extended_classes)
endif
if len(implemented_interfaces) > 0
call extend(all_extends, implemented_interfaces)
endif
if len(all_extends) > 0
for class in all_extends
let [class, namespace] = phpcomplete#ExpandClassName(class, current_namespace, imports)
if namespace == ''
let namespace = '\'
endif
let classlocation = phpcomplete#GetClassLocation(class, namespace)
if classlocation == "VIMPHP_BUILTINOBJECT"
if has_key(g:php_builtin_classes, tolower(class))
let result += [phpcomplete#GenerateBuiltinClassStub('class', g:php_builtin_classes[tolower(class)])]
endif
if has_key(g:php_builtin_interfaces, tolower(class))
let result += [phpcomplete#GenerateBuiltinClassStub('interface', g:php_builtin_interfaces[tolower(class)])]
endif
elseif classlocation != '' && filereadable(classlocation)
let full_file_path = fnamemodify(classlocation, ':p')
let result += phpcomplete#GetClassContentsStructure(full_file_path, readfile(full_file_path), class)
elseif tolower(current_namespace) == tolower(namespace) && match(join(a:file_lines, "\n"), '\c\(class\|interface\|trait\)\_s\+'.class.'\(\>\|$\)') != -1
" try to find the declaration in the same file.
let result += phpcomplete#GetClassContentsStructure(full_file_path, a:file_lines, class)
endif
endfor
endif
return result
@ -2039,43 +2175,53 @@ function! phpcomplete#GetClassContents(classlocation, class_name) " {{{
endfunction
" }}}
function! phpcomplete#GenerateBuiltinClassStub(class_info) " {{{
let re = 'class '.a:class_info['name']." {"
for [name, initializer] in items(a:class_info.constants)
let re .= "\n\tconst ".name." = ".initializer.";"
endfor
for [name, info] in items(a:class_info.properties)
let re .= "\n\t// @var $".name." ".info.type
let re .= "\n\tpublic $".name.";"
endfor
for [name, info] in items(a:class_info.static_properties)
let re .= "\n\t// @var ".name." ".info.type
let re .= "\n\tpublic static ".name." = ".info.initializer.";"
endfor
for [name, info] in items(a:class_info.methods)
if name =~ '^__'
continue
endif
let re .= "\n\t/**"
let re .= "\n\t * ".name
let re .= "\n\t *"
let re .= "\n\t * @return ".info.return_type
let re .= "\n\t */"
let re .= "\n\tpublic function ".name."(".info.signature."){"
let re .= "\n\t}"
endfor
for [name, info] in items(a:class_info.static_methods)
let re .= "\n\t/**"
let re .= "\n\t * ".name
let re .= "\n\t *"
let re .= "\n\t * @return ".info.return_type
let re .= "\n\t */"
let re .= "\n\tpublic static function ".name."(".info.signature."){"
let re .= "\n\t}"
endfor
function! phpcomplete#GenerateBuiltinClassStub(type, class_info) " {{{
let re = a:type.' '.a:class_info['name']." {"
if has_key(a:class_info, 'constants')
for [name, initializer] in items(a:class_info.constants)
let re .= "\n\tconst ".name." = ".initializer.";"
endfor
endif
if has_key(a:class_info, 'properties')
for [name, info] in items(a:class_info.properties)
let re .= "\n\t// @var $".name." ".info.type
let re .= "\n\tpublic $".name.";"
endfor
endif
if has_key(a:class_info, 'static_properties')
for [name, info] in items(a:class_info.static_properties)
let re .= "\n\t// @var ".name." ".info.type
let re .= "\n\tpublic static ".name." = ".info.initializer.";"
endfor
endif
if has_key(a:class_info, 'methods')
for [name, info] in items(a:class_info.methods)
if name =~ '^__'
continue
endif
let re .= "\n\t/**"
let re .= "\n\t * ".name
let re .= "\n\t *"
let re .= "\n\t * @return ".info.return_type
let re .= "\n\t */"
let re .= "\n\tpublic function ".name."(".info.signature."){"
let re .= "\n\t}"
endfor
endif
if has_key(a:class_info, 'static_methods')
for [name, info] in items(a:class_info.static_methods)
let re .= "\n\t/**"
let re .= "\n\t * ".name
let re .= "\n\t *"
let re .= "\n\t * @return ".info.return_type
let re .= "\n\t */"
let re .= "\n\tpublic static function ".name."(".info.signature."){"
let re .= "\n\t}"
endfor
endif
let re .= "\n}"
return { 'class': a:class_info['name'],
return { a:type : a:class_info['name'],
\ 'content': re,
\ 'namespace': '',
\ 'imports': {},
@ -2099,8 +2245,11 @@ function! phpcomplete#GetDocBlock(sccontent, search) " {{{
" start backward serch for the comment block
while l != 0
let line = a:sccontent[l]
" if comment end found save line position and end search
if line =~? '^\s*\*/'
" if it's a one line docblock like comment and we can just return it right away
if line =~? '^\s*\/\*\*.\+\*\/\s*$'
return substitute(line, '\v^\s*(\/\*\*\s*)|(\s*\*\/)\s*$', '', 'g')
"... or if comment end found save line position and end search
elseif line =~? '^\s*\*/'
let comment_end = l
break
" ... or the line doesn't blank (only whitespace or nothing) end search
@ -2122,6 +2271,7 @@ function! phpcomplete#GetDocBlock(sccontent, search) " {{{
endif
let l -= 1
endwhile
" no docblock comment start found
if comment_start == -1
return ''
@ -2270,19 +2420,48 @@ endfunction!
" }}}
function! phpcomplete#GetCurrentNameSpace(file_lines) " {{{
let original_window = winnr()
silent! below 1new
silent! 0put =a:file_lines
normal! G
" clear out classes, functions and other blocks
while 1
let block_start_pos = searchpos('\c\(class\|trait\|function\|interface\)\s\+\_.\{-}\zs{', 'Web')
if block_start_pos == [0, 0]
break
endif
let block_end_pos = searchpairpos('{', '', '}\|\%$', 'W', 'synIDattr(synID(line("."), col("."), 0), "name") =~? "string\\|comment"')
if block_end_pos != [0, 0]
" end of the block found, just delete it
silent! exec block_start_pos[0].','.block_end_pos[0].'d _'
else
" block pair not found, use block start as beginning and the end
" of the buffer instead
silent! exec block_start_pos[0].',$d _'
endif
endwhile
normal! G
" grab the remains
let file_lines = reverse(getline(1, line('.') - 1))
silent! bw! %
exe original_window.'wincmd w'
let namespace_name_pattern = '[a-zA-Z_\x7f-\xff\\][a-zA-Z_0-9\x7f-\xff\\]*'
let file_lines = reverse(copy(a:file_lines))
let i = 0
let file_length = len(file_lines)
let imports = {}
let current_namespace = '\'
while i < file_length
let line = file_lines[i]
if line =~? '^\s*namespace\s*'.namespace_name_pattern
let current_namespace = matchstr(line, '^\s*namespace\s*\zs'.namespace_name_pattern.'\ze')
if line =~? '^\(<?php\)\?\s*namespace\s*'.namespace_name_pattern
let current_namespace = matchstr(line, '\c^\(<?php\)\?\s*namespace\s*\zs'.namespace_name_pattern.'\ze')
break
endif
@ -2303,11 +2482,11 @@ function! phpcomplete#GetCurrentNameSpace(file_lines) " {{{
let use_line .= ' '.substitute(search_line, '\(^\s\+\|\s\+$\)', '', 'g')
endwhile
endif
let use_expression = matchstr(use_line, '^\s*use\s\+\zs.\{-}\ze;')
let use_expression = matchstr(use_line, '^\c\s*use\s\+\zs.\{-}\ze;')
let use_parts = map(split(use_expression, '\s*,\s*'), 'substitute(v:val, "\\s+", " ", "g")')
for part in use_parts
if part =~? '\s\+as\s\+'
let [object, name] = split(part, '\s\+as\s\+')
let [object, name] = split(part, '\s\+as\s\+\c')
let object = substitute(object, '^\\', '', '')
let name = substitute(name, '^\\', '', '')
else
@ -2343,7 +2522,7 @@ function! phpcomplete#GetCurrentNameSpace(file_lines) " {{{
break
endif
" if the name matches with the extracted classname and namespace
if (tag.kind == 'c' || tag.kind == 'i') && tag.name == classname
if (tag.kind == 'c' || tag.kind == 'i' || tag.kind == 't') && tag.name == classname
if has_key(tag, 'namespace')
let patched_ctags_detected = 1
if tag.namespace == namespace_for_classes
@ -2386,7 +2565,7 @@ function! phpcomplete#GetCurrentNameSpace(file_lines) " {{{
let tags = phpcomplete#GetTaglist('^'.import['name'].'$')
for tag in tags
" search for the first matchin namespace, class, interface with no namespace
if !has_key(tag, 'namespace') && (tag.kind == 'n' || tag.kind == 'c' || tag.kind == 'i')
if !has_key(tag, 'namespace') && (tag.kind == 'n' || tag.kind == 'c' || tag.kind == 'i' || tag.kind == 't')
call extend(import, tag)
let import['builtin'] = 0
break
@ -2445,7 +2624,7 @@ endfunction
function! phpcomplete#ExpandClassName(classname, current_namespace, imports) " {{{
" if there's an imported class, just use that class's information
if has_key(a:imports, a:classname) && (a:imports[a:classname].kind == 'c' || a:imports[a:classname].kind == 'i')
if has_key(a:imports, a:classname) && (a:imports[a:classname].kind == 'c' || a:imports[a:classname].kind == 'i' || a:imports[a:classname].kind == 't')
let namespace = has_key(a:imports[a:classname], 'namespace') ? a:imports[a:classname].namespace : ''
return [a:imports[a:classname].name, namespace]
endif

View File

@ -75,6 +75,7 @@ DOCS = \
pattern.txt \
pi_getscript.txt \
pi_gzip.txt \
pi_logipat.txt \
pi_netrw.txt \
pi_paren.txt \
pi_spec.txt \
@ -207,6 +208,7 @@ HTMLS = \
pattern.html \
pi_getscript.html \
pi_gzip.html \
pi_logipat.html \
pi_netrw.html \
pi_paren.html \
pi_spec.html \
@ -229,7 +231,6 @@ HTMLS = \
starting.html \
syntax.html \
tabpage.html \
tags.html \
tagsrch.html \
term.html \
tips.html \

View File

@ -1,4 +1,4 @@
*autocmd.txt* For Vim version 7.4. Last change: 2014 Sep 23
*autocmd.txt* For Vim version 7.4. Last change: 2015 Jul 20
VIM REFERENCE MANUAL by Bram Moolenaar
@ -259,6 +259,7 @@ Name triggered by ~
|Syntax| when the 'syntax' option has been set
|EncodingChanged| after the 'encoding' option has been changed
|TermChanged| after the value of 'term' has changed
|OptionSet| after setting any option
Startup and exit
|VimEnter| after doing all the startup stuff
@ -505,6 +506,8 @@ ColorScheme After loading a color scheme. |:colorscheme|
CompleteDone After Insert mode completion is done. Either
when something was completed or abandoning
completion. |ins-completion|
The |v:completed_item| variable contains
information about the completed item.
*CursorHold*
CursorHold When the user doesn't press a key for the time
@ -742,6 +745,29 @@ MenuPopup Just before showing the popup menu (under the
o Operator-pending
i Insert
c Command line
*OptionSet*
OptionSet After setting an option. The pattern is
matched against the long option name.
The |v:option_old| variable indicates the
old option value, |v:option_new| variable
indicates the newly set value, the
|v:option_type| variable indicates whether
it's global or local scoped and |<amatch>|
indicates what option has been set.
Is not triggered on startup and for the 'key'
option for obvious reasons.
Usage example: Check for the existence of the
directory in the 'backupdir' and 'undodir'
options, create the directory if it doesn't
exist yet.
Note: It's a bad idea to reset an option
during this autocommand, this may break a
plugin. You can always use `:noa` to prevent
triggering this autocommand.
*QuickFixCmdPre*
QuickFixCmdPre Before a quickfix command is run (|:make|,
|:lmake|, |:grep|, |:lgrep|, |:grepadd|,
@ -933,6 +959,13 @@ WinLeave Before leaving a window. If the window to be
==============================================================================
6. Patterns *autocmd-patterns* *{pat}*
The {pat} argument can be a comma separated list. This works as if the
command was given with each pattern separately. Thus this command: >
:autocmd BufRead *.txt,*.info set et
Is equivalent to: >
:autocmd BufRead *.txt set et
:autocmd BufRead *.info set et
The file pattern {pat} is tested for a match against the file name in one of
two ways:
1. When there is no '/' in the pattern, Vim checks for a match against only

View File

@ -1,4 +1,4 @@
*change.txt* For Vim version 7.4. Last change: 2014 Jun 26
*change.txt* For Vim version 7.4. Last change: 2015 Jun 25
VIM REFERENCE MANUAL by Bram Moolenaar
@ -379,10 +379,43 @@ Adding and subtracting ~
CTRL-A Add [count] to the number or alphabetic character at
or after the cursor. {not in Vi}
*v_CTRL-A*
{Visual}CTRL-A Add [count] to the number or alphabetic character in
the highlighted text. {not in Vi}
*v_g_CTRL-A*
{Visual}g CTRL-A Add [count] to the number or alphabetic character in
the highlighted text. If several lines are
highlighted, each one will be incremented by an
additional [count] (so effectively creating a
[count] incrementing sequence). {not in Vi}
For Example, if you have this list of numbers:
1. ~
1. ~
1. ~
1. ~
Move to the second "1." and Visually select three
lines, pressing g CTRL-A results in:
1. ~
2. ~
3. ~
4. ~
*CTRL-X*
CTRL-X Subtract [count] from the number or alphabetic
character at or after the cursor. {not in Vi}
*v_CTRL-X*
{Visual}CTRL-X Subtract [count] from the number or alphabetic
character in the highlighted text. {not in Vi}
*v_g_CTRL-X*
{Visual}g CTRL-X Subtract [count] from the number or alphabetic
character in the highlighted text. If several lines
are highlighted, each value will be decremented by an
additional [count] (so effectively creating a [count]
decrementing sequence). {not in Vi}
The CTRL-A and CTRL-X commands work for (signed) decimal numbers, unsigned
octal and hexadecimal numbers and alphabetic characters. This depends on the
'nrformats' option.
@ -399,6 +432,10 @@ octal and hexadecimal numbers and alphabetic characters. This depends on the
under or after the cursor. This is useful to make lists with an alphabetic
index.
For decimals a leading negative sign is considered for incrementing/
decrementing, for octal and hex values, it won't be considered.
To 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
"0077" results in "0100", CTRL-X on "0x100" results in "0x0ff".
@ -1103,11 +1140,12 @@ There are nine types of registers: *registers* *E354*
2. 10 numbered registers "0 to "9
3. The small delete register "-
4. 26 named registers "a to "z or "A to "Z
5. four read-only registers ":, "., "% and "#
6. the expression register "=
7. The selection and drop registers "*, "+ and "~
8. The black hole register "_
9. Last search pattern register "/
5. three read-only registers ":, "., "%
6. alternate buffer register "#
7. the expression register "=
8. The selection and drop registers "*, "+ and "~
9. The black hole register "_
10. Last search pattern register "/
1. Unnamed register "" *quote_quote* *quotequote*
Vim fills this register with text deleted with the "d", "c", "s", "x" commands
@ -1153,7 +1191,7 @@ letters to replace their previous contents or as uppercase letters to append
to their previous contents. When the '>' flag is present in 'cpoptions' then
a line break is inserted before the appended text.
5. Read-only registers ":, "., "% and "#
5. Read-only registers ":, ". and "%
These are '%', '#', ':' and '.'. You can use them only with the "p", "P",
and ":put" commands and with CTRL-R. {not in Vi}
*quote_.* *quote.* *E29*
@ -1164,8 +1202,6 @@ and ":put" commands and with CTRL-R. {not in Vi}
('textwidth' and other options affect what is inserted).
*quote_%* *quote%*
"% Contains the name of the current file.
*quote_#* *quote#*
"# Contains the name of the alternate file.
*quote_:* *quote:* *E30*
": Contains the most recent executed command-line. Example: Use
"@:" to repeat the previous command-line command.
@ -1174,16 +1210,33 @@ and ":put" commands and with CTRL-R. {not in Vi}
the command was completely from a mapping.
{not available when compiled without the |+cmdline_hist|
feature}
*quote_#* *quote#*
6. Alternate file register "#
Contains the name of the alternate file for the current window. It will
change how the |CTRL-^| command works.
This register is writable, mainly to allow for restoring it after a plugin has
changed it. It accepts buffer number: >
let altbuf = bufnr(@#)
...
let @# = altbuf
It will give error |E86| if you pass buffer number and this buffer does not
exist.
It can also accept a match with an existing buffer name: >
let @# = 'buffer_name'
Error |E93| if there is more than one buffer matching the given name or |E94|
if none of buffers matches the given name.
6. Expression register "= *quote_=* *quote=* *@=*
7. Expression register "= *quote_=* *quote=* *@=*
This is not really a register that stores text, but is a way to use an
expression in commands which use a register. The expression register is
read-only; you cannot put text into it. After the '=', the cursor moves to
the command-line, where you can enter any expression (see |expression|). All
normal command-line editing commands are available, including a special
history for expressions. When you end the command-line by typing <CR>, Vim
computes the result of the expression. If you end it with <Esc>, Vim abandons
the expression. If you do not enter an expression, Vim uses the previous
read-write.
When typing the '=' after " or CTRL-R the cursor moves to the command-line,
where you can enter any expression (see |expression|). All normal
command-line editing commands are available, including a special history for
expressions. When you end the command-line by typing <CR>, Vim computes the
result of the expression. If you end it with <Esc>, Vim abandons the
expression. If you do not enter an expression, Vim uses the previous
expression (like with the "/" command).
The expression must evaluate to a String. A Number is always automatically
@ -1196,7 +1249,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. {not in Vi}
7. Selection and drop registers "*, "+ and "~
8. Selection and drop 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 the clipboard
@ -1218,17 +1271,17 @@ GTK GUI}
Note: The "~ register is only used when dropping plain text onto Vim.
Drag'n'drop of URI lists is handled internally.
8. Black hole register "_ *quote_*
9. Black hole register "_ *quote_*
When writing to this register, nothing happens. This can be used to delete
text without affecting the normal registers. When reading from this register,
nothing is returned. {not in Vi}
9. Last search pattern register "/ *quote_/* *quote/*
10. Last search pattern register "/ *quote_/* *quote/*
Contains the most recent search-pattern. This is used for "n" and 'hlsearch'.
It is writable with `:let`, you can change it to have 'hlsearch' highlight
other matches without actually searching. You can't yank or delete into this
register. The search direction is available in |v:searchforward|.
Note that the valued is restored when returning from a function
Note that the value is restored when returning from a function
|function-search-undo|.
{not in Vi}
@ -1443,10 +1496,10 @@ When you hit Return in a C-comment, Vim will insert the middle comment leader
for the new line: " * ". To close this comment you just have to type "/"
before typing anything else on the new line. This will replace the
middle-comment leader with the end-comment leader and apply any specified
alignment, leaving just " */". There is no need to hit BackSpace first.
alignment, leaving just " */". There is no need to hit Backspace first.
When there is a match with a middle part, but there also is a maching end part
which is longer, the end part is used. This makes a C style comment work
When there is a match with a middle part, but there also is a matching end
part which is longer, the end part is used. This makes a C style comment work
without requiring the middle part to end with a space.
Here is an example of alignment flags at work to make a comment stand out

View File

@ -1,4 +1,4 @@
*cmdline.txt* For Vim version 7.4. Last change: 2014 Sep 06
*cmdline.txt* For Vim version 7.4. Last change: 2015 Jul 21
VIM REFERENCE MANUAL by Bram Moolenaar
@ -597,6 +597,7 @@ starts editing the three files "foo bar", "goes to" and "school ".
When you want to use the special characters '"' or '|' in a command, or want
to use '%' or '#' in a file name, precede them with a backslash. The
backslash is not required in a range and in the ":substitute" command.
See also |`=|.
*:_!*
The '!' (bang) character after an Ex command makes the command behave in a
@ -750,7 +751,7 @@ example, "%" stands for the current file name, while CTRL-R % inserts the
current file name right away. See |c_CTRL-R|.
Note: If you want to avoid the special characters in a Vim script you may want
to use |fnameescape()|.
to use |fnameescape()|. Also see |`=|.
In Ex commands, at places where a file name can be used, the following
@ -790,7 +791,7 @@ it, no matter how many backslashes.
# alternate.file
\# #
\\# \#
Also see |`=|.
*:<cword>* *:<cWORD>* *:<cfile>* *<cfile>*
*:<sfile>* *<sfile>* *:<afile>* *<afile>*
*:<abuf>* *<abuf>* *:<amatch>* *<amatch>*
@ -946,6 +947,7 @@ Examples: (alternate file name is "?readme?")
:e #.* :e {files matching "?readme?.*"}
:cd <cfile> :cd {file name under cursor}
:cd <cfile>* :cd {file name under cursor plus "*" and then expanded}
Also see |`=|.
When the expanded argument contains a "!" and it is used for a shell command
(":!cmd", ":r !cmd" or ":w !cmd"), the "!" is escaped with a backslash to
@ -971,6 +973,7 @@ for the file "$home" in the root directory. A few examples:
\$home file "$home" in current directory
/\$home file "$home" in root directory
\\$home file "\\", followed by expanded $home
Also see |`=|.
==============================================================================
7. Command-line window *cmdline-window* *cmdwin*

View File

@ -1,4 +1,4 @@
*diff.txt* For Vim version 7.4. Last change: 2014 Oct 31
*diff.txt* For Vim version 7.4. Last change: 2015 Jul 03
VIM REFERENCE MANUAL by Bram Moolenaar
@ -132,8 +132,9 @@ file for a moment and come back to the same file and be in diff mode again.
if the current window does not have 'diff' set then no options
in it are changed.
The ":diffoff" command resets the relevant options to the values they had when
using |:diffsplit|, |:diffpatch| , |:diffthis|. or starting Vim in diff mode.
The `:diffoff` command resets the relevant options to the values they had when
using `:diffsplit`, `:diffpatch` , `:diffthis`. or starting Vim in diff mode.
When using `:diffoff` twice the last saved values are restored.
Otherwise they are set to their default value:
'diff' off
@ -314,6 +315,19 @@ name or a part of a buffer name. Examples:
Also see |'diffopt'| and the "diff" item of |'fillchars'|.
*diff-slow* *diff_translations*
For very long lines, the diff syntax highlighting might be slow, especially
since it tries to match all different kind of localisations. To disable
localisations and speed up the syntax highlighting, set the global variable
g:diff_translations to zero: >
let g:diff_translations = 0
<
After setting this variable, Reload the syntax script: >
set syntax=diff
<
FINDING THE DIFFERENCES *diff-diffexpr*

View File

@ -1,4 +1,4 @@
*editing.txt* For Vim version 7.4. Last change: 2014 Dec 05
*editing.txt* For Vim version 7.4. Last change: 2015 Jul 21
VIM REFERENCE MANUAL by Bram Moolenaar
@ -304,7 +304,8 @@ CTRL-^ Edit the alternate file. Mostly the alternate file is
Mnemonic: "goto file".
Uses the 'isfname' option to find out which characters
are supposed to be in a file name. Trailing
punctuation characters ".,:;!" are ignored.
punctuation characters ".,:;!" are ignored. Escaped
spaces "\ " are reduced to a single space.
Uses the 'path' option as a list of directory names to
look for the file. See the 'path' option for details
about relative directories and wildcards.
@ -430,6 +431,8 @@ does apply like to other wildcards.
If the expression returns a string then names are to be separated with line
breaks. When the result is a |List| then each item is used as a name. Line
breaks also separate names.
Note that such expressions are only supported in places where a filename is
expected as an argument to an Ex-command.
*++opt* *[++opt]*
The [++opt] argument can be used to force the value of 'fileformat',
@ -832,8 +835,9 @@ current window. The two windows then share this list, until one of them uses
USING THE ARGUMENT LIST
*:argdo*
:argdo[!] {cmd} Execute {cmd} for each file in the argument list.
It works like doing this: >
:[range]argdo[!] {cmd} Execute {cmd} for each file in the argument list or
if [range] is specified only for arguments in that
range. It works like doing this: >
:rewind
:{cmd}
:next
@ -1391,7 +1395,7 @@ reveal it to others. The 'viminfo' file is not encrypted.
You could do this to edit very secret text: >
:set noundofile viminfo=
:noswapfile edit secrets.txt
Keep in mind that without a swap file you risk loosing your work in a crash.
Keep in mind that without a swap file you risk losing your work in a crash.
WARNING: If you make a typo when entering the key and then write the file and
exit, the text will be lost!

View File

@ -1,4 +1,4 @@
*eval.txt* For Vim version 7.4. Last change: 2014 Dec 07
*eval.txt* For Vim version 7.4. Last change: 2015 Jul 21
VIM REFERENCE MANUAL by Bram Moolenaar
@ -525,7 +525,7 @@ Funcref to a Dictionary, but the "self" variable is not available then.
To avoid the extra name for the function it can be defined and directly
assigned to a Dictionary in this way: >
:let mydict = {'data': [0, 1, 2, 3]}
:function mydict.len() dict
:function mydict.len()
: return len(self.data)
:endfunction
:echo mydict.len()
@ -956,7 +956,7 @@ Decimal, Hexadecimal (starting with 0x or 0X), or Octal (starting with 0).
Floating point numbers can be written in two forms:
[-+]{N}.{M}
[-+]{N}.{M}e[-+]{exp}
[-+]{N}.{M}[eE][-+]{exp}
{N} and {M} are numbers. Both {N} and {M} must be present and can only
contain digits.
@ -1005,7 +1005,7 @@ function. Example: >
string *string* *expr-string* *E114*
string *string* *String* *expr-string* *E114*
------
"string" string constant *expr-quote*
@ -1021,7 +1021,7 @@ A string constant accepts these special characters:
\X. same as \x.
\u.... character specified with up to 4 hex numbers, stored according to the
current value of 'encoding' (e.g., "\u02a4")
\U.... same as \u....
\U.... same as \u but allows up to 8 hex numbers.
\b backspace <BS>
\e escape <Esc>
\f formfeed <FF>
@ -1330,6 +1330,12 @@ v:cmdbang Set like v:cmdarg for a file read/write command. When a "!"
can only be used in autocommands. For user commands |<bang>|
can be used.
*v:completed_item* *completed_item-variable*
v:completed_item
|Dictionary| containing the |complete-items| for the most
recently completed word after |CompleteDone|. The
|Dictionary| is empty if the completion failed.
*v:count* *count-variable*
v:count The count given for the last Normal mode command. Can be used
to get the count before a mapping. Read-only. Example: >
@ -1462,7 +1468,9 @@ v:hlsearch Variable that indicates whether search highlighting is on.
requires |+extra_search|. Setting this variable to zero acts
the like |:nohlsearch| command, setting it to one acts like >
let &hlsearch = &hlsearch
<
< Note that the value is restored when returning from a
function. |function-search-undo|.
*v:insertmode* *insertmode-variable*
v:insertmode Used for the |InsertEnter| and |InsertChange| autocommand
events. Values:
@ -1527,6 +1535,15 @@ v:oldfiles List of file names that is loaded from the |viminfo| file on
than String this will cause trouble.
{only when compiled with the |+viminfo| feature}
*v:option_new*
v:option_new New value of the option. Valid while executing an |OptionSet|
autocommand.
*v:option_old*
v:option_old Old value of the option. Valid while executing an |OptionSet|
autocommand.
*v:option_type*
v:option_type Scope of the set command. Valid while executing an
|OptionSet| autocommand. Can be either "global" or "local"
*v:operator* *operator-variable*
v:operator The last operator given in Normal mode. This is a single
character except for commands starting with <g> or <z>,
@ -1834,9 +1851,10 @@ getwinposx() Number X coord in pixels of GUI Vim window
getwinposy() Number Y coord in pixels of GUI Vim window
getwinvar( {nr}, {varname} [, {def}])
any variable {varname} in window {nr}
glob( {expr} [, {nosuf} [, {list}]])
glob( {expr} [, {nosuf} [, {list} [, {alllinks}]]])
any expand file wildcards in {expr}
globpath( {path}, {expr} [, {nosuf} [, {list}]])
glob2regpat( {expr}) String convert a glob pat into a search pat
globpath( {path}, {expr} [, {nosuf} [, {list} [, {alllinks}]]])
String do glob({expr}) for all dirs in {path}
has( {feature}) Number TRUE if feature {feature} supported
has_key( {dict}, {key}) Number TRUE if {dict} has entry {key}
@ -1984,7 +2002,7 @@ split( {expr} [, {pat} [, {keepempty}]])
sqrt( {expr}) Float square root of {expr}
str2float( {expr}) Float convert String to Float
str2nr( {expr} [, {base}]) Number convert String to Number
strchars( {expr}) Number character length of the String {expr}
strchars( {expr} [, {skipcc}]) Number character length of the String {expr}
strdisplaywidth( {expr} [, {col}]) Number display length of the String {expr}
strftime( {format}[, {time}]) String time in specified format
stridx( {haystack}, {needle}[, {start}])
@ -2960,14 +2978,19 @@ extend({expr1}, {expr2} [, {expr3}]) *extend()*
{expr1} is changed when {expr2} is not empty. If necessary
make a copy of {expr1} first.
{expr2} remains unchanged.
When {expr1} is locked and {expr2} is not empty the operation
fails.
Returns {expr1}.
feedkeys({string} [, {mode}]) *feedkeys()*
Characters in {string} are queued for processing as if they
come from a mapping or were typed by the user. They are added
to the end of the typeahead buffer, thus if a mapping is still
being executed these characters come after them.
come from a mapping or were typed by the user.
By default the string is added to the end of the typeahead
buffer, thus if a mapping is still being executed the
characters come after them. Use the 'i' flag to insert before
other characters, they will be executed next, before any
characters from a mapping.
The function does not wait for processing of keys contained in
{string}.
To include special keys into {string}, use double-quotes
@ -2981,6 +3004,7 @@ feedkeys({string} [, {mode}]) *feedkeys()*
't' Handle keys as if typed; otherwise they are handled as
if coming from a mapping. This matters for undo,
opening folds, etc.
'i' Insert the string instead of appending (see above).
Return value is always 0.
filereadable({file}) *filereadable()*
@ -3310,7 +3334,7 @@ getchar([expr]) *getchar()*
: endwhile
:endfunction
<
You may also receive syntetic characters, such as
You may also receive synthetic characters, such as
|<CursorHold>|. Often you will want to ignore this and get
another character: >
:function GetKey()
@ -3634,7 +3658,7 @@ getwinvar({winnr}, {varname} [, {def}]) *getwinvar()*
:let list_is_on = getwinvar(2, '&list')
:echo "myvar = " . getwinvar(1, 'myvar')
<
glob({expr} [, {nosuf} [, {list}]]) *glob()*
glob({expr} [, {nosuf} [, {list} [, {alllinks}]]]) *glob()*
Expand the file wildcards in {expr}. See |wildcards| for the
use of special characters.
@ -3651,8 +3675,11 @@ glob({expr} [, {nosuf} [, {list}]]) *glob()*
matches, they are separated by <NL> characters.
If the expansion fails, the result is an empty String or List.
A name for a non-existing file is not included. A symbolic
link is only included if it points to an existing file.
However, when the {alllinks} argument is present and it is
non-zero then all symbolic links are included.
For most systems backticks can be used to get files names from
any external command. Example: >
@ -3664,7 +3691,16 @@ glob({expr} [, {nosuf} [, {list}]]) *glob()*
See |expand()| for expanding special Vim variables. See
|system()| for getting the raw output of an external command.
globpath({path}, {expr} [, {nosuf} [, {list}]]) *globpath()*
glob2regpat({expr}) *glob2regpat()*
Convert a file pattern, as used by glob(), into a search
pattern. The result can be used to match with a string that
is a file name. E.g. >
if filename =~ glob2regpat('Make*.mak')
< This is equivalent to: >
if filename =~ '^Make.*\.mak$'
<
*globpath()*
globpath({path}, {expr} [, {nosuf} [, {list} [, {allinks}]]])
Perform glob() on all directories in {path} and concatenate
the results. Example: >
:echo globpath(&rtp, "syntax/c.vim")
@ -3690,6 +3726,8 @@ globpath({path}, {expr} [, {nosuf} [, {list}]]) *globpath()*
they are separated by <NL> characters. Example: >
:echo globpath(&rtp, "syntax/c.vim", 0, 1)
<
{allinks} is used as with |glob()|.
The "**" item can be used to search in a directory tree.
For example, to find all "README.txt" files in the directories
in 'runtimepath' and below: >
@ -4367,7 +4405,7 @@ match({expr}, {pat}[, {start}[, {count}]]) *match()*
done like 'magic' is set and 'cpoptions' is empty.
*matchadd()* *E798* *E799* *E801*
matchadd({group}, {pattern}[, {priority}[, {id}]])
matchadd({group}, {pattern}[, {priority}[, {id} [, {dict}]]])
Defines a pattern to be highlighted in the current window (a
"match"). It will be highlighted with {group}. Returns an
identification number (ID), which can be used to delete the
@ -4375,6 +4413,8 @@ matchadd({group}, {pattern}[, {priority}[, {id}]])
Matching is case sensitive and magic, unless case sensitivity
or magicness are explicitly overridden in {pattern}. The
'magic', 'smartcase' and 'ignorecase' options are not used.
The "Conceal" value is special, it causes the match to be
concealed.
The optional {priority} argument assigns a priority to the
match. A match with a high priority will have its
@ -4392,9 +4432,18 @@ matchadd({group}, {pattern}[, {priority}[, {id}]])
message will appear and the match will not be added. An ID
is specified as a positive integer (zero excluded). IDs 1, 2
and 3 are reserved for |:match|, |:2match| and |:3match|,
respectively. If the {id} argument is not specified,
respectively. If the {id} argument is not specified or -1,
|matchadd()| automatically chooses a free ID.
The optional {dict} argmument allows for further custom
values. Currently this is used to specify a match specifc
conceal character that will be shown for |hl-Conceal|
highlighted matches. The dict can have the following members:
conceal Special character to show instead of the
match (only for |hl-Conceal| highlighed
matches, see |:syn-cchar|)
The number of matches is not limited, as it is the case with
the |:match| commands.
@ -4408,7 +4457,7 @@ matchadd({group}, {pattern}[, {priority}[, {id}]])
available from |getmatches()|. All matches can be deleted in
one operation by |clearmatches()|.
matchaddpos({group}, {pos}[, {priority}[, {id}]]) *matchaddpos()*
matchaddpos({group}, {pos}[, {priority}[, {id}[, {dict}]]]) *matchaddpos()*
Same as |matchadd()|, but requires a list of positions {pos}
instead of a pattern. This command is faster than |matchadd()|
because it does not require to handle regular expressions and
@ -4762,6 +4811,7 @@ printf({fmt}, {expr1} ...) *printf()*
s The text of the String argument is used. If a
precision is specified, no more bytes than the number
specified are used.
*printf-S*
S The text of the String argument is used. If a
precision is specified, no more display cells than the
number specified are used. Without the |+multi_byte|
@ -4823,7 +4873,7 @@ py3eval({expr}) *py3eval()*
Evaluate Python expression {expr} and return its result
converted to Vim data structures.
Numbers and strings are returned as they are (strings are
copied though, unicode strings are additionally converted to
copied though, Unicode strings are additionally converted to
'encoding').
Lists are represented as Vim |List| type.
Dictionaries are represented as Vim |Dictionary| type with
@ -4867,7 +4917,7 @@ readfile({fname} [, {binary} [, {max}]])
separated with CR will result in a single long line (unless a
NL appears somewhere).
All NUL characters are replaced with a NL character.
When {binary/append} contains "b" binary mode is used:
When {binary} contains "b" binary mode is used:
- When the last line ends in a NL an extra empty list item is
added.
- No CR characters are removed.
@ -5562,7 +5612,7 @@ setwinvar({nr}, {varname}, {val}) *setwinvar()*
:call setwinvar(2, "myvar", "foobar")
sha256({string}) *sha256()*
Returns a String with 64 hex charactes, which is the SHA256
Returns a String with 64 hex characters, which is the SHA256
checksum of {string}.
{only available when compiled with the |+cryptv| feature}
@ -5817,15 +5867,35 @@ str2nr( {expr} [, {base}]) *str2nr()*
Text after the number is silently ignored.
strchars({expr}) *strchars()*
strchars({expr} [, {skipcc}]) *strchars()*
The result is a Number, which is the number of characters
String {expr} occupies. Composing characters are counted
separately.
in String {expr}.
When {skipcc} is omitted or zero, composing characters are
counted separately.
When {skipcc} set to 1, Composing characters are ignored.
Also see |strlen()|, |strdisplaywidth()| and |strwidth()|.
{skipcc} is only available after 7.4.755. For backward
compatibility, you can define a wrapper function: >
if has("patch-7.4.755")
function s:strchars(str, skipcc)
return strchars(a:str, a:skipcc)
endfunction
else
function s:strchars(str, skipcc)
if a:skipcc
return strlen(substitute(a:str, ".", "x", "g"))
else
return strchars(a:str)
endif
endfunction
endif
<
strdisplaywidth({expr}[, {col}]) *strdisplaywidth()*
The result is a Number, which is the number of display cells
String {expr} occupies on the screen when it starts a {col}.
String {expr} occupies on the screen when it starts at {col}.
When {col} is omitted zero is used. Otherwise it is the
screen column where to start. This matters for Tab
characters.
@ -5891,15 +5961,11 @@ string({expr}) Return {expr} converted to a String. If {expr} is a Number,
*strlen()*
strlen({expr}) The result is a Number, which is the length of the String
{expr} in bytes.
If you want to count the number of multi-byte characters (not
counting composing characters) use something like this: >
:let len = strlen(substitute(str, ".", "x", "g"))
<
If the argument is a Number it is first converted to a String.
For other types an error is given.
Also see |len()|, |strchars()|, |strdisplaywidth()| and
|strwidth()|.
If you want to count the number of multi-byte characters use
|strchars()|.
Also see |len()|, |strdisplaywidth()| and |strwidth()|.
strpart({src}, {start}[, {len}]) *strpart()*
The result is a String, which is part of {src}, starting from
@ -7371,7 +7437,7 @@ This does NOT work: >
:unlet v
< *E741*
If you try to change a locked variable you get an
error message: "E741: Value of {name} is locked"
error message: "E741: Value is locked: {name}"
[depth] is relevant when locking a |List| or
|Dictionary|. It specifies how deep the locking goes:
@ -8275,7 +8341,7 @@ You can catch all Vim errors by the pattern >
*catch-text*
NOTE: You should never catch the error message text itself: >
:catch /No such variable/
only works in the english locale, but not when the user has selected
only works in the English locale, but not when the user has selected
a different language by the |:language| command. It is however helpful to
cite the message text in a comment: >
:catch /^Vim(\a\+):E108:/ " No such variable

View File

@ -222,7 +222,7 @@ o Keyboard
Note:
<09> stands for Farsi PSP (break without space)
<09> stands for Farsi PCN (for HAMZE attribute )
<09> stands for Farsi PCN (for HAMZE attribute)
Restrictions
------------

View File

@ -365,7 +365,7 @@ zX Undo manually opened and closed folds: re-apply 'foldlevel'.
Also forces recomputing folds, like |zx|.
*zm*
zm Fold more: Subtract one from 'foldlevel'. If 'foldlevel' was
zm Fold more: Subtract |v:count1| from 'foldlevel'. If 'foldlevel' was
already zero nothing happens.
'foldenable' will be set.
@ -374,7 +374,7 @@ zM Close all folds: set 'foldlevel' to 0.
'foldenable' will be set.
*zr*
zr Reduce folding: Add one to 'foldlevel'.
zr Reduce folding: Add |v:count1| to 'foldlevel'.
*zR*
zR Open all folds. This sets 'foldlevel' to highest fold level.

View File

@ -1,4 +1,4 @@
*gui_w32.txt* For Vim version 7.4. Last change: 2012 Aug 04
*gui_w32.txt* For Vim version 7.4. Last change: 2014 Dec 20
VIM REFERENCE MANUAL by Bram Moolenaar
@ -452,9 +452,10 @@ detailed elsewhere: see |'mouse'|, |win32-hidden-menus|.
You can drag and drop one or more files into the Vim window, where they will
be opened as normal. See |drag-n-drop|.
*:simalt* *:si*
*:simalt* *:sim*
:sim[alt] {key} simulate pressing {key} while holding Alt pressed.
{not in Vi} {only for Win32 versions}
Note: ":si" means ":s" with the "i" flag.
Normally, Vim takes control of all Alt-<Key> combinations, to increase the
number of possible mappings. This clashes with the standard use of Alt as the

View File

@ -1,4 +1,4 @@
*help.txt* For Vim version 7.4. Last change: 2012 Dec 06
*help.txt* For Vim version 7.4. Last change: 2015 Jun 21
VIM - main help file
k
@ -24,6 +24,7 @@ Get specific help: It is possible to go directly to whatever you want help
Command-line editing c_ :help c_<Del>
Vim command argument - :help -r
Option ' :help 'textwidth'
Regular expression / :help /[
Search for help: Type ":help word", then hit CTRL-D to see matching
help entries for "word".
Or use ":helpgrep word". |:helpgrep|
@ -196,6 +197,7 @@ Remarks about specific systems ~
Standard plugins ~
|pi_getscript.txt| Downloading latest version of Vim scripts
|pi_gzip.txt| Reading and writing compressed files
|pi_logipat.txt| Logical operators on patterns
|pi_netrw.txt| Reading and writing files over a network
|pi_paren.txt| Highlight matching parens
|pi_tar.txt| Tar file explorer

View File

@ -197,7 +197,7 @@ files in it.
--remote-silent "+call cursor(10, 27)"
- Places the cursor on line 10 column 27
In Vim >
:h --remote-silent for mor details
:h --remote-silent for more details
[.Net remarks provided by Dave Fishburn and Brian Sturk]

View File

@ -1,4 +1,4 @@
*if_ruby.txt* For Vim version 7.4. Last change: 2012 Aug 02
*if_ruby.txt* For Vim version 7.4. Last change: 2015 Feb 22
VIM REFERENCE MANUAL by Shugo Maeda
@ -120,9 +120,13 @@ VIM::command({cmd})
*ruby-evaluate*
VIM::evaluate({expr})
Evaluates {expr} using the vim internal expression evaluator (see
|expression|). Returns the expression result as a string.
A |List| is turned into a string by joining the items and inserting
line breaks.
|expression|). Returns the expression result as:
- a Integer if the Vim expression evaluates to a number
- a Float if the Vim expression evaluates to a float
- a String if the Vim expression evaluates to a string
- a Array if the Vim expression evaluates to a Vim list
- a Hash if the Vim expression evaluates to a Vim dictionary
Dictionaries and lists are recursively expanded.
==============================================================================
3. VIM::Buffer objects *ruby-buffer*

View File

@ -1,4 +1,4 @@
*index.txt* For Vim version 7.4. Last change: 2014 Sep 19
*index.txt* For Vim version 7.4. Last change: 2015 Feb 12
VIM REFERENCE MANUAL by Bram Moolenaar
@ -702,12 +702,16 @@ tag char note action in Normal mode ~
|g'| g'{mark} 1 like |'| but without changing the jumplist
|g`| g`{mark} 1 like |`| but without changing the jumplist
|gstar| g* 1 like "*", but without using "\<" and "\>"
|g+| g+ go to newer text state N times
|g,| g, 1 go to N newer position in change list
|g-| g- go to older text state N times
|g0| g0 1 when 'wrap' off go to leftmost character of
the current line that is on the screen;
when 'wrap' on go to the leftmost character
of the current screen line
|g8| g8 print hex value of bytes used in UTF-8
character under the cursor
|g;| g; 1 go to N older position in change list
|g<| g< display previous command output
|g?| g? 2 Rot13 encoding operator
|g?g?| g?? 2 Rot13 encode current line
@ -736,6 +740,7 @@ tag char note action in Normal mode ~
the screen; when 'wrap' on go to the
leftmost non-white character of the current
screen line
|g_| g_ 1 cursor to the last CHAR N - 1 lines lower
|ga| ga print ascii value of character under the
cursor
|gd| gd 1 go to definition of word under the cursor
@ -1465,7 +1470,7 @@ tag command action ~
buffer list
|:sbrewind| :sbr[ewind] split window and go to first file in the
buffer list
|:scriptnames| :scrip[tnames] list names of all sourced Vim scripts
|:scriptnames| :scr[iptnames] list names of all sourced Vim scripts
|:scriptencoding| :scripte[ncoding] encoding used in sourced Vim script
|:scscope| :scs[cope] split window and execute cscope command
|:set| :se[t] show or set options

View File

@ -1,4 +1,4 @@
*insert.txt* For Vim version 7.4. Last change: 2014 Aug 04
*insert.txt* For Vim version 7.4. Last change: 2015 Jun 20
VIM REFERENCE MANUAL by Bram Moolenaar
@ -81,9 +81,11 @@ CTRL-W Delete the word before the cursor (see |i_backspacing| about
joining lines). See the section "word motions",
|word-motions|, for the definition of a word.
*i_CTRL-U*
CTRL-U Delete all entered characters in the current line (see
|i_backspacing| about joining lines).
CTRL-U Delete all entered characters before the cursor in the current
line. If there are no newly entered characters and
'backspace' is not empty, delete all characters before the
cursor in the current line.
See |i_backspacing| about joining lines.
*i_CTRL-I* *i_<Tab>* *i_Tab*
<Tab> or CTRL-I Insert a tab. If the 'expandtab' option is on, the
equivalent number of spaces is inserted (use CTRL-V <Tab> to

View File

@ -1,4 +1,4 @@
*intro.txt* For Vim version 7.4. Last change: 2014 May 24
*intro.txt* For Vim version 7.4. Last change: 2015 Jan 20
VIM REFERENCE MANUAL by Bram Moolenaar
@ -135,7 +135,7 @@ http://www.vim.org/maillist.php
Bug reports: *bugs* *bug-reports* *bugreport.vim*
Send bug reports to: Vim Developers <vim_dev@vim.org>
Send bug reports to: Vim Developers <vim-dev@vim.org>
This is a maillist, you need to become a member first and many people will see
the message. If you don't want that, e.g. because it is a security issue,
send it to <bugs@vim.org>, this only goes to the Vim maintainer (that's Bram).

View File

@ -1,4 +1,4 @@
*motion.txt* For Vim version 7.4. Last change: 2014 Feb 11
*motion.txt* For Vim version 7.4. Last change: 2015 Jun 06
VIM REFERENCE MANUAL by Bram Moolenaar
@ -172,6 +172,8 @@ CTRL-H or *CTRL-H* *<BS>*
l or *l*
<Right> or *<Right>* *<Space>*
<Space> [count] characters to the right. |exclusive| motion.
See the 'whichwrap' option for adjusting the behavior
at end of line
*0*
0 To the first character of the line. |exclusive|

View File

@ -1,4 +1,4 @@
*netbeans.txt* For Vim version 7.4. Last change: 2012 Jan 26
*netbeans.txt* For Vim version 7.4. Last change: 2015 Mar 14
VIM REFERENCE MANUAL by Gordon Prieur et al.
@ -306,7 +306,12 @@ bufID Buffer number. A message may be either for a specific buffer
or generic. Generic messages use a bufID of zero. NOTE: this
buffer ID is assigned by the IDE, it is not Vim's buffer
number. The bufID must be a sequentially rising number,
starting at one.
starting at one. When the 'switchbuf' option is set to
"usetab" and the "bufID" buffer is not found in the current
tab page, the netbeans commands and functions that set this
buffer as the current buffer will jump to the first open
window that contains this buffer in other tab pages instead of
replacing the buffer in the current window.
seqno The IDE uses a sequence number for Commands and Functions. A
Reply must use the sequence number of the Function that it is

View File

@ -1,4 +1,4 @@
*options.txt* For Vim version 7.4. Last change: 2014 Nov 05
*options.txt* For Vim version 7.4. Last change: 2015 Jul 17
VIM REFERENCE MANUAL by Bram Moolenaar
@ -59,9 +59,7 @@ achieve special effects. These options come in three forms:
:se[t] {option}:{value}
Set string or number option to {value}.
For numeric options the value can be given in decimal,
hex (preceded with 0x) or octal (preceded with '0')
(hex and octal are only available for machines which
have the strtol() function).
hex (preceded with 0x) or octal (preceded with '0').
The old value can be inserted by typing 'wildchar' (by
default this is a <Tab> or CTRL-E if 'compatible' is
set). See |cmdline-completion|.
@ -538,11 +536,11 @@ number can be specified where "vim:" or "Vim:" is used:
vim<{vers}: version before {vers}
vim={vers}: version {vers}
vim>{vers}: version after {vers}
{vers} is 600 for Vim 6.0 (hundred times the major version plus minor).
For example, to use a modeline only for Vim 6.0 and later:
/* vim600: set foldmethod=marker: */ ~
To use a modeline for Vim before version 5.7:
/* vim<570: set sw=4: */ ~
{vers} is 700 for Vim 7.0 (hundred times the major version plus minor).
For example, to use a modeline only for Vim 7.0:
/* vim700: set foldmethod=marker */ ~
To use a modeline for Vim after version 7.2:
/* vim>702: set cole=2: */ ~
There can be no blanks between "vim" and the ":".
@ -730,8 +728,6 @@ A jump table for the options with a short description can be found at |Q_op|.
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.
This option is provided for backward compatibility with the Vim
released with Sun ONE Studio 4 Enterprise Edition.
Note: When this option is on some plugins may not work.
*'arabic'* *'arab'* *'noarabic'* *'noarab'*
@ -1128,6 +1124,47 @@ A jump table for the options with a short description can be found at |Q_op|.
expression evaluates to a |List| this is equal to using each List item
as a string and putting "\n" in between them.
*'belloff'* *'bo'*
'belloff' 'bo' string (default "")
global
{not in Vi}
Specifies for which events the bell will not be rung. It is a comma
separated list of items. For each item that is present, the bell
will be silenced. This is most useful to specify specific events in
insert mode to be silenced.
item meaning when present ~
all All events.
backspace When hitting <BS> or <Del> and deleting results in an
error.
cursor Fail to move around using the cursor keys or
<PageUp>/<PageDown> in |Insert-mode|.
complete Error occurred when using |i_CTRL-X_CTRL-K| or
|i_CTRL-X_CTRL-T|.
copy Cannot copy char from insert mode using |i_CTRL-Y| or
|i_CTRL-E|.
ctrlg Unknown Char after <C-G> in Insert mode.
error Other Error occurred (e.g. try to join last line)
(mostly used in |Normal-mode| or |Cmdline-mode|).
esc hitting <Esc> in |Normal-mode|.
ex In |Visual-mode|, hitting |Q| results in an error.
hangul Error occurred when using hangul input.
insertmode Pressing <Esc> in 'insertmode'.
lang Calling the beep module for Lua/Mzscheme/TCL.
mess No output available for |g<|.
showmatch Error occurred for 'showmatch' function.
operator Empty region error |cpo-E|.
register Unknown register after <C-R> in |Insert-mode|.
shell Bell from shell output |:!|.
spell Error happened on spell suggest.
wildmode More matches in |cmdline-completion| available
(depends on the 'wildmode' setting).
This is most useful, to fine tune when in insert mode the bell should
be rung. For normal mode and ex commands, the bell is often rung to
indicate that an error occurred. It can be silenced by adding the
"error" keyword.
*'binary'* *'bin'* *'nobinary'* *'nobin'*
'binary' 'bin' boolean (default off)
local to buffer
@ -1320,6 +1357,9 @@ A jump table for the options with a short description can be found at |Q_op|.
nofile only: The buffer name is fixed, it is not handled like a
file name. It is not modified in response to a |:cd|
command.
both: When using ":e bufname" and already editing "bufname"
the buffer is made empty and autocommands are
triggered as usual for |:edit|.
*E676*
"acwrite" implies that the buffer name is not related to a file, like
"nofile", but it will be written. Thus, in contrast to "nofile" and
@ -1820,6 +1860,14 @@ A jump table for the options with a short description can be found at |Q_op|.
completion in the preview window. Only works in
combination with "menu" or "menuone".
noinsert Do not insert any text for a match until the user selects
a match from the menu. Only works in combination with
"menu" or "menuone". No effect if "longest" is present.
noselect Do not select a match in the menu, force the user to
select one from the menu. Only works in combination with
"menu" or "menuone".
*'concealcursor'* *'cocu'*
'concealcursor' 'cocu' string (default: "")
@ -2664,15 +2712,16 @@ A jump table for the options with a short description can be found at |Q_op|.
local to buffer
{not in Vi}
When writing a file and this option is off and the 'binary' option
is on, no <EOL> will be written for the last line in the file. This
option is automatically set when starting to edit a new file, unless
the file does not have an <EOL> for the last line in the file, in
which case it is reset. Normally you don't have to set or reset this
option. When 'binary' is off the value is not used when writing the
file. When 'binary' is on it is used to remember the presence of a
<EOL> for the last line in the file, so that when you write the file
the situation from the original file can be kept. But you can change
it if you want to.
is on, or 'fixeol' option is off, no <EOL> will be written for the
last line in the file. This option is automatically set or reset when
starting to edit a new file, depending on whether file has an <EOL>
for the last line in the file. Normally you don't have to set or
reset this option.
When 'binary' is off and 'fixeol' is on the value is not used when
writing the file. When 'binary' is on or 'fixeol' is off it is used
to remember the presence of a <EOL> for the last line in the file, so
that when you write the file the situation from the original file can
be kept. But you can change it if you want to.
*'equalalways'* *'ea'* *'noequalalways'* *'noea'*
'equalalways' 'ea' boolean (default on)
@ -2713,7 +2762,8 @@ A jump table for the options with a short description can be found at |Q_op|.
makes a difference for error messages, the bell will be used always
for a lot of errors without a message (e.g., hitting <Esc> in Normal
mode). See 'visualbell' on how to make the bell behave like a beep,
screen flash or do nothing.
screen flash or do nothing. See 'belloff' to finetune when to ring the
bell.
*'errorfile'* *'ef'*
'errorfile' 'ef' string (Amiga default: "AztecC.Err",
@ -2952,8 +3002,8 @@ A jump table for the options with a short description can be found at |Q_op|.
2. If a <NL> is found and 'fileformats' includes "unix", 'fileformat'
is set to "unix". Note that when a <NL> is found without a
preceding <CR>, "unix" is preferred over "dos".
3. If 'fileformat' has not yet been set, and if 'fileformats'
includes "mac", 'fileformat' is set to "mac".
3. If 'fileformat' has not yet been set, and if a <CR> is found, and
if 'fileformats' includes "mac", 'fileformat' is set to "mac".
This means that "mac" is only chosen when:
"unix" is not present or no <NL> is found in the file, and
"dos" is not present or no <CR><NL> is found in the file.
@ -3057,6 +3107,17 @@ A jump table for the options with a short description can be found at |Q_op|.
fold:c Folded |hl-Folded|
diff:c DiffDelete |hl-DiffDelete|
*'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.
When the 'binary' option is set the value of this option doesn't
matter.
See the 'endofline' option.
*'fkmap'* *'fk'* *'nofkmap'* *'nofk'*
'fkmap' 'fk' boolean (default off) *E198*
global
@ -3421,7 +3482,8 @@ A jump table for the options with a short description can be found at |Q_op|.
the height of the cursor can be changed. This can be done by
specifying a block cursor, or a percentage for a vertical or
horizontal cursor.
For a console the 't_SI' and 't_EI' escape sequences are used.
For a console the 't_SI', 't_SR', and 't_EI' escape sequences are
used.
The option is a comma separated list of parts. Each part consist of a
mode-list and an argument-list:
@ -4717,33 +4779,38 @@ A jump table for the options with a short description can be found at |Q_op|.
{not in Vi}
Strings to use in 'list' mode and for the |:list| command. It is a
comma separated list of string settings.
*lcs-eol*
*lcs-eol*
eol:c Character to show at the end of each line. When
omitted, there is no extra character at the end of the
line.
*lcs-tab*
*lcs-tab*
tab:xy Two characters to be used to show a tab. The first
char is used once. The second char is repeated to
fill the space that the tab normally occupies.
"tab:>-" will show a tab that takes four spaces as
">---". When omitted, a tab is show as ^I.
*lcs-trail*
*lcs-space*
space:c Character to show for a space. When omitted, spaces
are left blank.
*lcs-trail*
trail:c Character to show for trailing spaces. When omitted,
trailing spaces are blank.
*lcs-extends*
trailing spaces are blank. Overrides the "space"
setting for trailing spaces.
*lcs-extends*
extends:c Character to show in the last column, when 'wrap' is
off and the line continues beyond the right of the
screen.
*lcs-precedes*
*lcs-precedes*
precedes:c Character to show in the first column, when 'wrap'
is off and there is text preceding the character
visible in the first column.
*lcs-conceal*
*lcs-conceal*
conceal:c Character to show in place of concealed text, when
'conceallevel' is set to 1.
*lcs-nbsp*
nbsp:c Character to show for a non-breakable space (character
0xA0, 160). Left blank when omitted.
*lcs-nbsp*
nbsp:c Character to show for a non-breakable space character
(0xA0 (160 decimal) and U+202F). Left blank when
omitted.
The characters ':' and ',' should not be used. UTF-8 characters can
be used when 'encoding' is "utf-8", otherwise only printable
@ -4754,7 +4821,7 @@ A jump table for the options with a short description can be found at |Q_op|.
:set lcs=tab:>-,eol:<,nbsp:%
:set lcs=extends:>,precedes:<
< The "NonText" highlighting will be used for "eol", "extends" and
"precedes". "SpecialKey" for "nbsp", "tab" and "trail".
"precedes". "SpecialKey" for "nbsp", "space", "tab" and "trail".
|hl-NonText| |hl-SpecialKey|
*'lpl'* *'nolpl'* *'loadplugins'* *'noloadplugins'*
@ -7062,6 +7129,7 @@ A jump table for the options with a short description can be found at |Q_op|.
split If included, split the current window before loading
a buffer for a |quickfix| command that display errors.
Otherwise: do not split, use current window.
vsplit Just like "split" but split vertically.
newtab Like "split", but open a new tab page. Overrules
"split" when both are present.

View File

@ -1,4 +1,4 @@
*pattern.txt* For Vim version 7.4. Last change: 2014 Sep 06
*pattern.txt* For Vim version 7.4. Last change: 2015 Mar 16
VIM REFERENCE MANUAL by Bram Moolenaar
@ -59,6 +59,8 @@ explanations are in chapter 27 |usr_27.txt|.
*n*
n Repeat the latest "/" or "?" [count] times.
If the cursor doesn't move the search is repeated with
count + 1.
|last-pattern| {Vi: no count}
*N*
@ -1058,7 +1060,10 @@ x A single character, with no special meaning, matches itself
*E769*
When the ']' is not there Vim will not give an error message but
assume no collection is used. Useful to search for '['. However, you
do get E769 for internal searching.
do get E769 for internal searching. And be aware that in a
`:substitute` command the whole command becomes the pattern. E.g.
":s/[/x/" searches for "[/x" and replaces it with nothing. It does
not search for "[" and replaces it with "x"!
If the sequence begins with "^", it matches any single character NOT
in the collection: "[^xyz]" matches anything but 'x', 'y' and 'z'.

117
runtime/doc/pi_logipat.txt Normal file
View File

@ -0,0 +1,117 @@
*pi_logipat.txt* Logical Patterns Mar 13, 2013
Author: Charles E. Campbell <NdrOchip@ScampbellPfamily.AbizM>
Copyright: (c) 2004-2013 by Charles E. Campbell *logipat-copyright*
The VIM LICENSE applies to LogiPat.vim and LogiPat.txt
(see |copyright|) except use "LogiPat" instead of "Vim"
No warranty, express or implied. Use At-Your-Own-Risk.
==============================================================================
1. Contents *logipat* *logipat-contents*
1. Contents.................: |logipat-contents|
2. LogiPat Manual...........: |logipat-manual|
3. LogiPat Examples.........: |logipat-examples|
4. Caveat...................: |logipat-caveat|
5. LogiPat History..........: |logipat-history|
==============================================================================
2. LogiPat Manual *logipat-manual* *logipat-man*
*logipat-arg* *logipat-input* *logipat-pattern* *logipat-operators*
Boolean logic patterns are composed of
operators ! = not
| = logical-or
& = logical-and
grouping ( ... )
patterns "pattern"
:LogiPat {boolean-logic pattern} *:LogiPat*
:LogiPat is a command which takes a boolean-logic
argument (|logipat-arg|).
:LP {boolean-logic pattern} *:LP*
:LP is a shorthand command version of :LogiPat
(|:LogiPat|).
:ELP {boolean-logic pattern} *:ELP*
No search is done, but the conversion from the
boolean logic pattern to the regular expression
is performed and echoed onto the display.
:LogiPatFlags {search flags} *LogiPat-flags*
:LogiPatFlags {search flags}
LogiPat uses the |search()| command. The flags
passed to that call to search() may be specified
by the :LogiPatFlags command.
:LPF {search flags} *:LPF*
:LPF is a shorthand version of :LogiPatFlags.
:let pat=LogiPat({boolean-logic pattern}) *LogiPat()*
If one calls LogiPat() directly, no search
is done, but the transformation from the boolean
logic pattern into a regular expression pattern
is performed and returned.
To get a " inside a pattern, as opposed to having it delimit
the pattern, double it.
==============================================================================
3. LogiPat Examples *logipat-examples*
LogiPat takes Boolean logic arguments and produces a regular
expression which implements the choices. A series of examples
follows:
>
:LogiPat "abc"
< will search for lines containing the string :abc:
>
:LogiPat "ab""cd"
< will search for lines containing the string :ab"c:
>
:LogiPat !"abc"
< will search for lines which don't contain the string :abc:
>
:LogiPat "abc"|"def"
< will search for lines which contain either the string
:abc: or the string :def:
>
:LogiPat !("abc"|"def")
< will search for lines which don't contain either
of the strings :abc: or :def:
>
:LogiPat "abc"&"def"
< will search for lines which contain both of the strings
:abc: and :def:
>
:let pat= LogiPat('!"abc"')
< will return the regular expression which will match
all lines not containing :abc: . The double quotes
are needed to pass normal patterns to LogiPat, and
differentiate such patterns from boolean logic
operators.
==============================================================================
4. Caveat *logipat-caveat*
The "not" operator may be fragile; ie. it may not always play well
with the & (logical-and) and | (logical-or) operators. Please try out
your patterns, possibly with :set hls, to insure that what is matching
is what you want.
==============================================================================
3. LogiPat History *logipat-history*
v3 Sep 25, 2006 * LP_Or() fixed; it now encapsulates its output
in \%(...\) parentheses
Dec 12, 2011 * |:ELP| added
* "" is mapped to a single " and left inside patterns
v2 May 31, 2005 * LPF and LogiPatFlags commands weren't working
v1 May 23, 2005 * initial release
==============================================================================
vim:tw=78:ts=8:ft=help

File diff suppressed because it is too large Load Diff

View File

@ -693,7 +693,7 @@ It is possible to achieve a poor man's version of duplex printing using the PS
utility psselect. This utility has options -e and -o for printing just the
even or odd pages of a PS file respectively.
First generate a PS file with the 'hardcopy' command, then generate a new
First generate a PS file with the 'hardcopy' command, then generate new
files with all the odd and even numbered pages with: >
psselect -o test.ps odd.ps

View File

@ -1,4 +1,4 @@
*quickref.txt* For Vim version 7.4. Last change: 2014 Nov 19
*quickref.txt* For Vim version 7.4. Last change: 2015 Jul 21
VIM REFERENCE MANUAL by Bram Moolenaar
@ -620,6 +620,7 @@ Short explanation of each option: *option-list*
'balloondelay' 'bdlay' delay in mS before a balloon may pop up
'ballooneval' 'beval' switch on balloon evaluation
'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
'bioskey' 'biosk' MS-DOS: use bios calls for input characters
'bomb' prepend a Byte Order Mark to the file
@ -696,6 +697,7 @@ Short explanation of each option: *option-list*
'fileignorecase' 'fic' ignore case when using file names
'filetype' 'ft' type of file, used for autocommands
'fillchars' 'fcs' characters to use for displaying special items
'fixendofline' 'fixeol' make sure last line in file has <EOL>
'fkmap' 'fk' Farsi keyboard mapping
'foldclose' 'fcl' close a fold when the cursor leaves it
'foldcolumn' 'fdc' width of the column used to indicate folds
@ -710,10 +712,10 @@ Short explanation of each option: *option-list*
'foldnestmax' 'fdn' maximum fold depth
'foldopen' 'fdo' for which commands a fold will be opened
'foldtext' 'fdt' expression used to display for a closed fold
'formatexpr' 'fex' expression used with "gq" command
'formatlistpat' 'flp' pattern used to recognize a list header
'formatoptions' 'fo' how automatic formatting is to be done
'formatprg' 'fp' name of external program used with "gq" command
'formatexpr' 'fex' expression used with "gq" command
'fsync' 'fs' whether to invoke fsync() after file write
'gdefault' 'gd' the ":substitute" flag 'g' is default on
'grepformat' 'gfm' format of 'grepprg' output
@ -732,15 +734,15 @@ Short explanation of each option: *option-list*
'helplang' 'hlg' preferred help languages
'hidden' 'hid' don't unload buffer when it is |abandon|ed
'highlight' 'hl' sets highlighting mode for various occasions
'hlsearch' 'hls' highlight matches with last search pattern
'history' 'hi' number of command-lines that are remembered
'hkmap' 'hk' Hebrew keyboard mapping
'hkmapp' 'hkp' phonetic Hebrew keyboard mapping
'hlsearch' 'hls' highlight matches with last search pattern
'icon' let Vim set the text of the window icon
'iconstring' string to use for the Vim icon text
'ignorecase' 'ic' ignore case in search patterns
'imactivatekey' 'imak' key that activates the X input method
'imactivatefunc' 'imaf' function to enable/disable the X input method
'imactivatekey' 'imak' key that activates the X input method
'imcmdline' 'imc' use IM when starting to edit a command line
'imdisable' 'imd' do not use the IM in any mode
'iminsert' 'imi' use :lmap or IM in Insert mode
@ -893,9 +895,9 @@ Short explanation of each option: *option-list*
'switchbuf' 'swb' sets behavior when switching to another buffer
'synmaxcol' 'smc' maximum column to find syntax items
'syntax' 'syn' syntax to be loaded for current buffer
'tabstop' 'ts' number of spaces that <Tab> in file uses
'tabline' 'tal' custom format for the console tab pages line
'tabpagemax' 'tpm' maximum number of tab pages for |-p| and "tab all"
'tabstop' 'ts' number of spaces that <Tab> in file uses
'tagbsearch' 'tbs' use binary searching in tags files
'taglength' 'tl' number of significant characters for a tag
'tagrelative' 'tr' file names in tag file are relative

View File

@ -178,14 +178,14 @@ Hurrah for VIM!! It is "at your fingertips" like vi, and has the extensions
that vi sorely needs: highlighting for executing commands on blocks, an easily
navigable and digestible help screen, and more. (Paul Pax)
The reason WHY I don't have this amazingly useful macro any more, is that I
The reason WHY I don't have this amazingly useful macro anymore, is that I
now use VIM - and this is built in!! (Stephen Riehm, Germany)
I am a user of VIM and I love it. I use it to do all my programming, C,
C++, HTML what ever. (Tim Allwine)
I discovered VIM after years of struggling with the original vi, and I just
can't live without it any more. (Emmanuel Mogenet, USA)
can't live without it anymore. (Emmanuel Mogenet, USA)
Emacs has not a bit of chance to survive so long as VIM is around. Besides,
it also has the most detailed software documentation I have ever seen---much

View File

@ -1,4 +1,4 @@
*remote.txt* For Vim version 7.4. Last change: 2008 May 24
*remote.txt* For Vim version 7.4. Last change: 2015 Mar 01
VIM REFERENCE MANUAL by Bram Moolenaar
@ -36,7 +36,8 @@ The following command line arguments are available:
The remote Vim is raised. If you don't want
this use >
vim --remote-send "<C-\><C-N>:n filename<CR>"
< --remote-silent [+{cmd}] {file} ... *--remote-silent*
<
--remote-silent [+{cmd}] {file} ... *--remote-silent*
As above, but don't complain if there is no
server and the file is edited locally.
--remote-wait [+{cmd}] {file} ... *--remote-wait*

View File

@ -1,4 +1,4 @@
*repeat.txt* For Vim version 7.4. Last change: 2014 Oct 29
*repeat.txt* For Vim version 7.4. Last change: 2015 Apr 13
VIM REFERENCE MANUAL by Bram Moolenaar
@ -235,8 +235,8 @@ For writing a Vim script, see chapter 41 of the user manual |usr_41.txt|.
command is ignored.
{not in Vi}
*:scrip* *:scriptnames*
:scrip[tnames] List all sourced script names, in the order they were
*:scr* *:scriptnames*
:scr[iptnames] List all sourced script names, in the order they were
first sourced. The number is used for the script ID
|<SID>|.
{not in Vi} {not available when compiled without the
@ -600,6 +600,7 @@ For example, to profile the one_script.vim script file: >
:prof[ile] start {fname} *:prof* *:profile* *E750*
Start profiling, write the output in {fname} upon exit.
"~/" and environment variables in {fname} will be expanded.
If {fname} already exists it will be silently overwritten.
The variable |v:profiling| is set to one.

View File

@ -1,4 +1,4 @@
*syntax.txt* For Vim version 7.4. Last change: 2014 Nov 19
*syntax.txt* For Vim version 7.4. Last change: 2015 Jul 21
VIM REFERENCE MANUAL by Bram Moolenaar
@ -211,7 +211,8 @@ thing. These are then linked to a highlight group that specifies the color.
A syntax group name doesn't specify any color or attributes itself.
The name for a highlight or syntax group must consist of ASCII letters, digits
and the underscore. As a regexp: "[a-zA-Z0-9_]*"
and the underscore. As a regexp: "[a-zA-Z0-9_]*". However, Vim does not give
an error when using other characters.
To be able to allow each user to pick his favorite set of colors, there must
be preferred names for highlight groups that are common for many languages.
@ -1128,6 +1129,16 @@ to standard by placing this in your vimrc file: >
:let enforce_freedesktop_standard = 1
DIFF *diff.vim*
The diff highlighting normally finds translated headers. This can be slow if
there are very long lines in the file. To disable translations: >
:let diff_translations = 0
Also see |diff-slow|.
DIRCOLORS *dircolors.vim* *ft-dircolors-syntax*
The dircolors utility highlighting definition has one option. It exists to
@ -3311,6 +3322,32 @@ must not click outside of the pixel strings, but feel free to improve it.
It will look much better with a font in a quadratic cell size, e.g. for X: >
:set guifont=-*-clean-medium-r-*-*-8-*-*-*-*-80-*
YAML *yaml.vim* *ft-yaml-syntax*
*g:yaml_schema* *b:yaml_schema*
A YAML schema is a combination of a set of tags and a mechanism for resolving
non-specific tags. For user this means that YAML parser may, depending on
plain scalar contents, treat plain scalar (which can actually be only string
and nothing else) as a value of the other type: null, boolean, floating-point,
integer. `g:yaml_schema` option determines according to which schema values
will be highlighted specially. Supported schemas are
Schema Description ~
failsafe No additional highlighting.
json Supports JSON-style numbers, booleans and null.
core Supports more number, boolean and null styles.
pyyaml In addition to core schema supports highlighting timestamps,
but there are some differences in what is recognized as
numbers and many additional boolean values not present in core
schema.
Default schema is `core`.
Note that schemas are not actually limited to plain scalars, but this is the
only difference between schemas defined in YAML specification and the only
difference defined in the syntax file.
==============================================================================
5. Defining a syntax *:syn-define* *E410*
@ -3662,6 +3699,7 @@ Whether or not it is actually concealed depends on the value of the
'conceallevel' option. The 'concealcursor' option is used to decide whether
concealable items in the current line are displayed unconcealed to be able to
edit the line.
Another way to conceal text with with |matchadd()|.
concealends *:syn-concealends*
@ -4243,7 +4281,7 @@ If the "maxlines={N}" argument is given, the number of lines that are searched
for a comment or syncing pattern is restricted to N lines backwards (after
adding "minlines"). This is useful if you have few things to sync on and a
slow machine. Example: >
:syntax sync ccomment maxlines=500
:syntax sync maxlines=500 ccomment
<
*:syn-sync-linebreaks*
When using a pattern that matches multiple lines, a change in one line may
@ -4637,6 +4675,8 @@ ctermbg={color-nr} *highlight-ctermbg*
Note that for some color terminals these names may result in the wrong
colors!
You can also use "NONE" to remove the color.
*:hi-normal-cterm*
When setting the "ctermfg" or "ctermbg" colors for the Normal group,
these will become the colors used for the non-highlighted text.

View File

@ -1,4 +1,4 @@
*tabpage.txt* For Vim version 7.4. Last change: 2014 Nov 27
*tabpage.txt* For Vim version 7.4. Last change: 2015 Jan 04
VIM REFERENCE MANUAL by Bram Moolenaar
@ -202,30 +202,38 @@ REORDERING TAB PAGES:
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. >
:.tabmove " do nothing
:-tabmove " move the tab page to the left
:tabmove " move the tab page to the right
:.tabmove " as above
:+tabmove " as above
:0tabmove " move the tab page to the begining of the tab
:+tabmove " move the tab page to the right
:0tabmove " move the tab page to the beginning of the tab
" list
:$tabmove " move the tab page to the end of the tab list
<
:tabmove 0 " as above
:tabmove " move the tab page to the last
:$tabmove " as above
:tabmove $ " as above
:tabm[ove] +[N]
:tabm[ove] -[N]
Move the current tab page N places to the right (with +) or to
the left (with -).
the left (with -). >
:tabmove - " move the tab page to the left
:tabmove -1 " as above
:tabmove + " move the tab page to the right
:tabmove +1 " as above
Note that although it is possible to move a tab behind the N-th one by using
:Ntabmove, it is impossible to move it by N places by using :+Ntabmove. For
clarification what +N means in this context see |[range]|.
:Ntabmove. And move it by N places by using :+Ntabmove. For clarification what
+N means in this context see |[range]|.
LOOPING OVER TAB PAGES:
*:tabd* *:tabdo*
:tabd[o] {cmd} Execute {cmd} in each tab page.
It works like doing this: >
:[range]tabd[o] {cmd}
Execute {cmd} in each tab page or if [range] is given only in
tab pages which tab page number is in the [range]. It works
like doing this: >
:tabfirst
:{cmd}
:tabnext
@ -271,8 +279,8 @@ window on the same buffer and then edit another buffer. Thus ":tabnew"
triggers:
WinLeave leave current window
TabLeave leave current tab page
TabEnter enter new tab page
WinEnter enter window in new tab page
TabEnter enter new tab page
BufLeave leave current buffer
BufEnter enter new empty buffer

View File

@ -76,6 +76,7 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
'bdir' options.txt /*'bdir'*
'bdlay' options.txt /*'bdlay'*
'beautify' vi_diff.txt /*'beautify'*
'belloff' options.txt /*'belloff'*
'beval' options.txt /*'beval'*
'bex' options.txt /*'bex'*
'bexpr' options.txt /*'bexpr'*
@ -89,6 +90,7 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
'bk' options.txt /*'bk'*
'bkc' options.txt /*'bkc'*
'bl' options.txt /*'bl'*
'bo' options.txt /*'bo'*
'bomb' options.txt /*'bomb'*
'breakat' options.txt /*'breakat'*
'breakindent' options.txt /*'breakindent'*
@ -246,6 +248,8 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
'fileignorecase' options.txt /*'fileignorecase'*
'filetype' options.txt /*'filetype'*
'fillchars' options.txt /*'fillchars'*
'fixendofline' options.txt /*'fixendofline'*
'fixeol' options.txt /*'fixeol'*
'fk' options.txt /*'fk'*
'fkmap' options.txt /*'fkmap'*
'fl' vi_diff.txt /*'fl'*
@ -540,6 +544,8 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
'nofen' options.txt /*'nofen'*
'nofic' options.txt /*'nofic'*
'nofileignorecase' options.txt /*'nofileignorecase'*
'nofixendofline' options.txt /*'nofixendofline'*
'nofixeol' options.txt /*'nofixeol'*
'nofk' options.txt /*'nofk'*
'nofkmap' options.txt /*'nofkmap'*
'nofoldenable' options.txt /*'nofoldenable'*
@ -929,9 +935,11 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
't_KJ' term.txt /*'t_KJ'*
't_KK' term.txt /*'t_KK'*
't_KL' term.txt /*'t_KL'*
't_RB' term.txt /*'t_RB'*
't_RI' term.txt /*'t_RI'*
't_RV' term.txt /*'t_RV'*
't_SI' term.txt /*'t_SI'*
't_SR' term.txt /*'t_SR'*
't_Sb' term.txt /*'t_Sb'*
't_Sf' term.txt /*'t_Sf'*
't_WP' term.txt /*'t_WP'*
@ -995,6 +1003,7 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
't_ve' term.txt /*'t_ve'*
't_vi' term.txt /*'t_vi'*
't_vs' term.txt /*'t_vs'*
't_xn' term.txt /*'t_xn'*
't_xs' term.txt /*'t_xs'*
'ta' options.txt /*'ta'*
'tabline' options.txt /*'tabline'*
@ -1398,6 +1407,8 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
.dic spell.txt /*.dic*
.exrc starting.txt /*.exrc*
.gvimrc gui.txt /*.gvimrc*
.netrwbook pi_netrw.txt /*.netrwbook*
.netrwhist pi_netrw.txt /*.netrwhist*
.vimrc starting.txt /*.vimrc*
/ pattern.txt /*\/*
/$ pattern.txt /*\/$*
@ -1833,6 +1844,7 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
:CompilerSet usr_41.txt /*:CompilerSet*
:DiffOrig diff.txt /*:DiffOrig*
:DoMatchParen pi_paren.txt /*:DoMatchParen*
:ELP pi_logipat.txt /*:ELP*
:Explore pi_netrw.txt /*:Explore*
:GLVS pi_getscript.txt /*:GLVS*
:GetLatestVimScripts_dat pi_getscript.txt /*:GetLatestVimScripts_dat*
@ -1840,7 +1852,10 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
:GnatPretty ft_ada.txt /*:GnatPretty*
:GnatTags ft_ada.txt /*:GnatTags*
:Hexplore pi_netrw.txt /*:Hexplore*
:LP pi_logipat.txt /*:LP*
:LPF pi_logipat.txt /*:LPF*
:Lexplore pi_netrw.txt /*:Lexplore*
:LogiPat pi_logipat.txt /*:LogiPat*
:Man filetype.txt /*:Man*
:MkVimball pi_vimball.txt /*:MkVimball*
:N editing.txt /*:N*
@ -2726,7 +2741,7 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
:sbr windows.txt /*:sbr*
:sbrewind windows.txt /*:sbrewind*
:sbuffer windows.txt /*:sbuffer*
:scrip repeat.txt /*:scrip*
:scr repeat.txt /*:scr*
:scripte repeat.txt /*:scripte*
:scriptencoding repeat.txt /*:scriptencoding*
:scriptnames repeat.txt /*:scriptnames*
@ -2761,7 +2776,6 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
:sfirst windows.txt /*:sfirst*
:sh various.txt /*:sh*
:shell various.txt /*:shell*
:si gui_w32.txt /*:si*
:sig sign.txt /*:sig*
:sign sign.txt /*:sign*
:sign-define sign.txt /*:sign-define*
@ -2774,6 +2788,7 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
:sign-unplace sign.txt /*:sign-unplace*
:sil various.txt /*:sil*
:silent various.txt /*:silent*
:sim gui_w32.txt /*:sim*
:simalt gui_w32.txt /*:simalt*
:sl various.txt /*:sl*
:sla windows.txt /*:sla*
@ -4417,6 +4432,8 @@ L motion.txt /*L*
Linux-backspace options.txt /*Linux-backspace*
List eval.txt /*List*
Lists eval.txt /*Lists*
LogiPat() pi_logipat.txt /*LogiPat()*
LogiPat-flags pi_logipat.txt /*LogiPat-flags*
Lua if_lua.txt /*Lua*
M motion.txt /*M*
MDI starting.txt /*MDI*
@ -4463,6 +4480,7 @@ OffTheSpot mbyte.txt /*OffTheSpot*
OnTheSpot mbyte.txt /*OnTheSpot*
Operator-pending intro.txt /*Operator-pending*
Operator-pending-mode intro.txt /*Operator-pending-mode*
OptionSet autocmd.txt /*OptionSet*
OverTheSpot mbyte.txt /*OverTheSpot*
P change.txt /*P*
PATHEXT eval.txt /*PATHEXT*
@ -4552,6 +4570,7 @@ SourcePre autocmd.txt /*SourcePre*
SpellFileMissing autocmd.txt /*SpellFileMissing*
StdinReadPost autocmd.txt /*StdinReadPost*
StdinReadPre autocmd.txt /*StdinReadPre*
String eval.txt /*String*
SwapExists autocmd.txt /*SwapExists*
Syntax autocmd.txt /*Syntax*
T motion.txt /*T*
@ -4871,6 +4890,7 @@ b:current_syntax-variable syntax.txt /*b:current_syntax-variable*
b:netrw_lastfile pi_netrw.txt /*b:netrw_lastfile*
b:tex_stylish syntax.txt /*b:tex_stylish*
b:var eval.txt /*b:var*
b:yaml_schema syntax.txt /*b:yaml_schema*
baan-folding syntax.txt /*baan-folding*
baan-syntax syntax.txt /*baan-syntax*
baan.vim syntax.txt /*baan.vim*
@ -5197,6 +5217,7 @@ complete_CTRL-E insert.txt /*complete_CTRL-E*
complete_CTRL-Y insert.txt /*complete_CTRL-Y*
complete_add() eval.txt /*complete_add()*
complete_check() eval.txt /*complete_check()*
completed_item-variable eval.txt /*completed_item-variable*
completion-functions usr_41.txt /*completion-functions*
complex-change change.txt /*complex-change*
complex-repeat repeat.txt /*complex-repeat*
@ -5414,9 +5435,12 @@ diff-mode diff.txt /*diff-mode*
diff-options diff.txt /*diff-options*
diff-original-file diff.txt /*diff-original-file*
diff-patchexpr diff.txt /*diff-patchexpr*
diff-slow diff.txt /*diff-slow*
diff.txt diff.txt /*diff.txt*
diff.vim syntax.txt /*diff.vim*
diff_filler() eval.txt /*diff_filler()*
diff_hlID() eval.txt /*diff_hlID()*
diff_translations diff.txt /*diff_translations*
digraph digraph.txt /*digraph*
digraph-arg change.txt /*digraph-arg*
digraph-encoding digraph.txt /*digraph-encoding*
@ -5877,6 +5901,7 @@ ft-xhtml-omni insert.txt /*ft-xhtml-omni*
ft-xml-omni insert.txt /*ft-xml-omni*
ft-xml-syntax syntax.txt /*ft-xml-syntax*
ft-xpm-syntax syntax.txt /*ft-xpm-syntax*
ft-yaml-syntax syntax.txt /*ft-yaml-syntax*
ft_ada.txt ft_ada.txt /*ft_ada.txt*
ft_sql.txt ft_sql.txt /*ft_sql.txt*
ftdetect filetype.txt /*ftdetect*
@ -6008,6 +6033,7 @@ g:netrw_errorlvl pi_netrw.txt /*g:netrw_errorlvl*
g:netrw_fastbrowse pi_netrw.txt /*g:netrw_fastbrowse*
g:netrw_fetch_cmd pi_netrw.txt /*g:netrw_fetch_cmd*
g:netrw_ffkeep pi_netrw.txt /*g:netrw_ffkeep*
g:netrw_file_cmd pi_netrw.txt /*g:netrw_file_cmd*
g:netrw_fname_escape pi_netrw.txt /*g:netrw_fname_escape*
g:netrw_ftp pi_netrw.txt /*g:netrw_ftp*
g:netrw_ftp_browse_reject pi_netrw.txt /*g:netrw_ftp_browse_reject*
@ -6019,6 +6045,7 @@ g:netrw_ftp_timelist_cmd pi_netrw.txt /*g:netrw_ftp_timelist_cmd*
g:netrw_ftpextracmd pi_netrw.txt /*g:netrw_ftpextracmd*
g:netrw_ftpmode pi_netrw.txt /*g:netrw_ftpmode*
g:netrw_glob_escape pi_netrw.txt /*g:netrw_glob_escape*
g:netrw_gx pi_netrw.txt /*g:netrw_gx*
g:netrw_hide pi_netrw.txt /*g:netrw_hide*
g:netrw_home pi_netrw.txt /*g:netrw_home*
g:netrw_http_cmd pi_netrw.txt /*g:netrw_http_cmd*
@ -6026,10 +6053,13 @@ g:netrw_http_put_cmd pi_netrw.txt /*g:netrw_http_put_cmd*
g:netrw_http_xcmd pi_netrw.txt /*g:netrw_http_xcmd*
g:netrw_ignorenetrc pi_netrw.txt /*g:netrw_ignorenetrc*
g:netrw_keepdir pi_netrw.txt /*g:netrw_keepdir*
g:netrw_keepj pi_netrw.txt /*g:netrw_keepj*
g:netrw_list_cmd pi_netrw.txt /*g:netrw_list_cmd*
g:netrw_list_cmd_options pi_netrw.txt /*g:netrw_list_cmd_options*
g:netrw_list_hide pi_netrw.txt /*g:netrw_list_hide*
g:netrw_liststyle pi_netrw.txt /*g:netrw_liststyle*
g:netrw_localcopycmd pi_netrw.txt /*g:netrw_localcopycmd*
g:netrw_localcopydircmd pi_netrw.txt /*g:netrw_localcopydircmd*
g:netrw_localmkdir pi_netrw.txt /*g:netrw_localmkdir*
g:netrw_localmovecmd pi_netrw.txt /*g:netrw_localmovecmd*
g:netrw_localrmdir pi_netrw.txt /*g:netrw_localrmdir*
@ -6050,6 +6080,7 @@ g:netrw_rsync_cmd pi_netrw.txt /*g:netrw_rsync_cmd*
g:netrw_scp_cmd pi_netrw.txt /*g:netrw_scp_cmd*
g:netrw_scpport pi_netrw.txt /*g:netrw_scpport*
g:netrw_sepchr pi_netrw.txt /*g:netrw_sepchr*
g:netrw_servername pi_netrw.txt /*g:netrw_servername*
g:netrw_sftp_cmd pi_netrw.txt /*g:netrw_sftp_cmd*
g:netrw_silent pi_netrw.txt /*g:netrw_silent*
g:netrw_sort_by pi_netrw.txt /*g:netrw_sort_by*
@ -6100,6 +6131,7 @@ g:vimsyn_folding syntax.txt /*g:vimsyn_folding*
g:vimsyn_maxlines syntax.txt /*g:vimsyn_maxlines*
g:vimsyn_minlines syntax.txt /*g:vimsyn_minlines*
g:vimsyn_noerror syntax.txt /*g:vimsyn_noerror*
g:yaml_schema syntax.txt /*g:yaml_schema*
g:zip_nomax pi_zip.txt /*g:zip_nomax*
g:zip_shq pi_zip.txt /*g:zip_shq*
g:zip_unzipcmd pi_zip.txt /*g:zip_unzipcmd*
@ -6190,6 +6222,7 @@ gi insert.txt /*gi*
gj motion.txt /*gj*
gk motion.txt /*gk*
glob() eval.txt /*glob()*
glob2regpat() eval.txt /*glob2regpat()*
global-ime mbyte.txt /*global-ime*
global-local options.txt /*global-local*
global-variable eval.txt /*global-variable*
@ -6716,6 +6749,7 @@ lcs-eol options.txt /*lcs-eol*
lcs-extends options.txt /*lcs-extends*
lcs-nbsp options.txt /*lcs-nbsp*
lcs-precedes options.txt /*lcs-precedes*
lcs-space options.txt /*lcs-space*
lcs-tab options.txt /*lcs-tab*
lcs-trail options.txt /*lcs-trail*
left-right-motions motion.txt /*left-right-motions*
@ -6763,6 +6797,18 @@ location-list quickfix.txt /*location-list*
location-list-window quickfix.txt /*location-list-window*
log() eval.txt /*log()*
log10() eval.txt /*log10()*
logipat pi_logipat.txt /*logipat*
logipat-arg pi_logipat.txt /*logipat-arg*
logipat-caveat pi_logipat.txt /*logipat-caveat*
logipat-contents pi_logipat.txt /*logipat-contents*
logipat-copyright pi_logipat.txt /*logipat-copyright*
logipat-examples pi_logipat.txt /*logipat-examples*
logipat-history pi_logipat.txt /*logipat-history*
logipat-input pi_logipat.txt /*logipat-input*
logipat-man pi_logipat.txt /*logipat-man*
logipat-manual pi_logipat.txt /*logipat-manual*
logipat-operators pi_logipat.txt /*logipat-operators*
logipat-pattern pi_logipat.txt /*logipat-pattern*
long-lines version5.txt /*long-lines*
love intro.txt /*love*
lowercase change.txt /*lowercase*
@ -6998,6 +7044,8 @@ netrw-:Hexplore pi_netrw.txt /*netrw-:Hexplore*
netrw-:Lexplore pi_netrw.txt /*netrw-:Lexplore*
netrw-:MF pi_netrw.txt /*netrw-:MF*
netrw-:MT pi_netrw.txt /*netrw-:MT*
netrw-:NetrwC pi_netrw.txt /*netrw-:NetrwC*
netrw-:NetrwMB pi_netrw.txt /*netrw-:NetrwMB*
netrw-:Rexplore pi_netrw.txt /*netrw-:Rexplore*
netrw-:Sexplore pi_netrw.txt /*netrw-:Sexplore*
netrw-:Texplore pi_netrw.txt /*netrw-:Texplore*
@ -7006,6 +7054,7 @@ netrw-C pi_netrw.txt /*netrw-C*
netrw-D pi_netrw.txt /*netrw-D*
netrw-O pi_netrw.txt /*netrw-O*
netrw-P pi_netrw.txt /*netrw-P*
netrw-P18 pi_netrw.txt /*netrw-P18*
netrw-R pi_netrw.txt /*netrw-R*
netrw-S pi_netrw.txt /*netrw-S*
netrw-Tb pi_netrw.txt /*netrw-Tb*
@ -7035,6 +7084,7 @@ netrw-createfile pi_netrw.txt /*netrw-createfile*
netrw-credits pi_netrw.txt /*netrw-credits*
netrw-ctrl-h pi_netrw.txt /*netrw-ctrl-h*
netrw-ctrl-l pi_netrw.txt /*netrw-ctrl-l*
netrw-ctrl-r pi_netrw.txt /*netrw-ctrl-r*
netrw-ctrl_l pi_netrw.txt /*netrw-ctrl_l*
netrw-curdir pi_netrw.txt /*netrw-curdir*
netrw-d pi_netrw.txt /*netrw-d*
@ -7061,6 +7111,7 @@ netrw-gf pi_netrw.txt /*netrw-gf*
netrw-gh pi_netrw.txt /*netrw-gh*
netrw-gitignore pi_netrw.txt /*netrw-gitignore*
netrw-gp pi_netrw.txt /*netrw-gp*
netrw-grep pi_netrw.txt /*netrw-grep*
netrw-gx pi_netrw.txt /*netrw-gx*
netrw-handler pi_netrw.txt /*netrw-handler*
netrw-help pi_netrw.txt /*netrw-help*
@ -7082,6 +7133,7 @@ netrw-login pi_netrw.txt /*netrw-login*
netrw-mB pi_netrw.txt /*netrw-mB*
netrw-mF pi_netrw.txt /*netrw-mF*
netrw-mT pi_netrw.txt /*netrw-mT*
netrw-mX pi_netrw.txt /*netrw-mX*
netrw-mb pi_netrw.txt /*netrw-mb*
netrw-mc pi_netrw.txt /*netrw-mc*
netrw-md pi_netrw.txt /*netrw-md*
@ -7099,6 +7151,7 @@ netrw-mr pi_netrw.txt /*netrw-mr*
netrw-ms pi_netrw.txt /*netrw-ms*
netrw-mt pi_netrw.txt /*netrw-mt*
netrw-mu pi_netrw.txt /*netrw-mu*
netrw-mv pi_netrw.txt /*netrw-mv*
netrw-mx pi_netrw.txt /*netrw-mx*
netrw-mz pi_netrw.txt /*netrw-mz*
netrw-netrc pi_netrw.txt /*netrw-netrc*
@ -7118,6 +7171,7 @@ netrw-p13 pi_netrw.txt /*netrw-p13*
netrw-p14 pi_netrw.txt /*netrw-p14*
netrw-p15 pi_netrw.txt /*netrw-p15*
netrw-p16 pi_netrw.txt /*netrw-p16*
netrw-p17 pi_netrw.txt /*netrw-p17*
netrw-p2 pi_netrw.txt /*netrw-p2*
netrw-p3 pi_netrw.txt /*netrw-p3*
netrw-p4 pi_netrw.txt /*netrw-p4*
@ -7398,6 +7452,7 @@ php3.vim syntax.txt /*php3.vim*
phtml.vim syntax.txt /*phtml.vim*
pi_getscript.txt pi_getscript.txt /*pi_getscript.txt*
pi_gzip.txt pi_gzip.txt /*pi_gzip.txt*
pi_logipat.txt pi_logipat.txt /*pi_logipat.txt*
pi_netrw.txt pi_netrw.txt /*pi_netrw.txt*
pi_paren.txt pi_paren.txt /*pi_paren.txt*
pi_spec.txt pi_spec.txt /*pi_spec.txt*
@ -7444,6 +7499,7 @@ printf() eval.txt /*printf()*
printf-% eval.txt /*printf-%*
printf-E eval.txt /*printf-E*
printf-G eval.txt /*printf-G*
printf-S eval.txt /*printf-S*
printf-X eval.txt /*printf-X*
printf-c eval.txt /*printf-c*
printf-d eval.txt /*printf-d*
@ -8078,9 +8134,11 @@ t_KI term.txt /*t_KI*
t_KJ term.txt /*t_KJ*
t_KK term.txt /*t_KK*
t_KL term.txt /*t_KL*
t_RB term.txt /*t_RB*
t_RI term.txt /*t_RI*
t_RV term.txt /*t_RV*
t_SI term.txt /*t_SI*
t_SR term.txt /*t_SR*
t_Sb term.txt /*t_Sb*
t_Sf term.txt /*t_Sf*
t_WP term.txt /*t_WP*
@ -8183,6 +8241,7 @@ t_vb term.txt /*t_vb*
t_ve term.txt /*t_ve*
t_vi term.txt /*t_vi*
t_vs term.txt /*t_vs*
t_xn term.txt /*t_xn*
t_xs term.txt /*t_xs*
tab intro.txt /*tab*
tab-page tabpage.txt /*tab-page*
@ -8441,6 +8500,7 @@ v:charconvert_from eval.txt /*v:charconvert_from*
v:charconvert_to eval.txt /*v:charconvert_to*
v:cmdarg eval.txt /*v:cmdarg*
v:cmdbang eval.txt /*v:cmdbang*
v:completed_item eval.txt /*v:completed_item*
v:count eval.txt /*v:count*
v:count1 eval.txt /*v:count1*
v:ctype eval.txt /*v:ctype*
@ -8468,6 +8528,9 @@ v:mouse_lnum eval.txt /*v:mouse_lnum*
v:mouse_win eval.txt /*v:mouse_win*
v:oldfiles eval.txt /*v:oldfiles*
v:operator eval.txt /*v:operator*
v:option_new eval.txt /*v:option_new*
v:option_old eval.txt /*v:option_old*
v:option_type eval.txt /*v:option_type*
v:prevcount eval.txt /*v:prevcount*
v:profiling eval.txt /*v:profiling*
v:progname eval.txt /*v:progname*
@ -8499,11 +8562,13 @@ v_<Esc> visual.txt /*v_<Esc>*
v_= change.txt /*v_=*
v_> change.txt /*v_>*
v_C change.txt /*v_C*
v_CTRL-A change.txt /*v_CTRL-A*
v_CTRL-C visual.txt /*v_CTRL-C*
v_CTRL-G visual.txt /*v_CTRL-G*
v_CTRL-H change.txt /*v_CTRL-H*
v_CTRL-O visual.txt /*v_CTRL-O*
v_CTRL-V visual.txt /*v_CTRL-V*
v_CTRL-X change.txt /*v_CTRL-X*
v_CTRL-Z starting.txt /*v_CTRL-Z*
v_CTRL-\_CTRL-G intro.txt /*v_CTRL-\\_CTRL-G*
v_CTRL-\_CTRL-N intro.txt /*v_CTRL-\\_CTRL-N*
@ -8559,7 +8624,9 @@ v_gJ change.txt /*v_gJ*
v_gN visual.txt /*v_gN*
v_gV visual.txt /*v_gV*
v_g] tagsrch.txt /*v_g]*
v_g_CTRL-A change.txt /*v_g_CTRL-A*
v_g_CTRL-G editing.txt /*v_g_CTRL-G*
v_g_CTRL-X change.txt /*v_g_CTRL-X*
v_g_CTRL-] tagsrch.txt /*v_g_CTRL-]*
v_gf editing.txt /*v_gf*
v_gn visual.txt /*v_gn*
@ -8864,6 +8931,7 @@ xterm-screens tips.txt /*xterm-screens*
xterm-scroll-region term.txt /*xterm-scroll-region*
xterm-shifted-keys term.txt /*xterm-shifted-keys*
y change.txt /*y*
yaml.vim syntax.txt /*yaml.vim*
yank change.txt /*yank*
ye-option-gone version4.txt /*ye-option-gone*
year-2000 intro.txt /*year-2000*

View File

@ -1,4 +1,4 @@
*term.txt* For Vim version 7.4. Last change: 2014 May 13
*term.txt* For Vim version 7.4. Last change: 2015 Jun 25
VIM REFERENCE MANUAL by Bram Moolenaar
@ -224,10 +224,11 @@ The options are listed below. The associated termcap code is always equal to
the last two characters of the option name. Only one termcap code is
required: Cursor motion, 't_cm'.
The options 't_da', 't_db', 't_ms', 't_xs' represent flags in the termcap.
When the termcap flag is present, the option will be set to "y". But any
non-empty string means that the flag is set. An empty string means that the
flag is not set. 't_CS' works like this too, but it isn't a termcap flag.
The options 't_da', 't_db', 't_ms', 't_xs', 't_xn' represent flags in the
termcap. When the termcap flag is present, the option will be set to "y".
But any non-empty string means that the flag is set. An empty string means
that the flag is not set. 't_CS' works like this too, but it isn't a termcap
flag.
OUTPUT CODES
option meaning ~
@ -281,6 +282,9 @@ OUTPUT CODES
t_vs cursor very visible *t_vs* *'t_vs'*
*t_xs* *'t_xs'*
t_xs if non-empty, standout not erased by overwriting (hpterm)
*t_xn* *'t_xn'*
t_xn if non-empty, writing a character at the last screen cell
does not cause scrolling
t_ZH italics mode *t_ZH* *'t_ZH'*
t_ZR italics end *t_ZR* *'t_ZR'*
@ -290,12 +294,15 @@ Added by Vim (there are no standard codes for these):
t_WP set window position (Y, X) in pixels *t_WP* *'t_WP'*
t_WS set window size (height, width) in characters *t_WS* *'t_WS'*
t_SI start insert mode (bar cursor shape) *t_SI* *'t_SI'*
t_EI end insert mode (block cursor shape) *t_EI* *'t_EI'*
t_SR start replace mode (underline cursor shape) *t_SR* *'t_SR'*
t_EI end insert or replace mode (block cursor shape) *t_EI* *'t_EI'*
|termcap-cursor-shape|
t_RV request terminal version string (for xterm) *t_RV* *'t_RV'*
|xterm-8bit| |v:termresponse| |'ttymouse'| |xterm-codes|
t_u7 request cursor position (for xterm) *t_u7* *'t_u7'*
see |'ambiwidth'|
t_RB request terminal background color *t_RB* *'t_RB'*
see |'ambiwidth'|
KEY CODES
Note: Use the <> form if possible
@ -410,7 +417,7 @@ adjust the various t_ codes. This avoids the problem that the xterm can
produce different codes, depending on the mode it is in (8-bit, VT102,
VT220, etc.). The result is that codes like <xF1> are no longer needed.
Note: This is only done on startup. If the xterm options are changed after
Vim has started, the escape sequences may not be recognized any more.
Vim has started, the escape sequences may not be recognized anymore.
*xterm-resize*
Window resizing with xterm only works if the allowWindowOps resource is
@ -434,13 +441,16 @@ If one of these is not available, 't_Sb' and 't_Sf' are used. 't_me' is used
to reset to the default colors.
*termcap-cursor-shape* *termcap-cursor-color*
When Vim enters Insert mode the 't_SI' escape sequence is sent. When leaving
Insert mode 't_EI' is used. But only if both are defined. This can be used
to change the shape or color of the cursor in Insert mode. These are not
standard termcap/terminfo entries, you need to set them yourself.
When Vim enters Insert mode the 't_SI' escape sequence is sent. When Vim
enters Replace mode the 't_SR' escape sequence is sent if it is set, otherwise
't_SI' is sent. When leaving Insert mode or Replace mode 't_EI' is used. This
can be used to change the shape or color of the cursor in Insert or Replace
mode. These are not standard termcap/terminfo entries, you need to set them
yourself.
Example for an xterm, this changes the color of the cursor: >
if &term =~ "xterm"
let &t_SI = "\<Esc>]12;purple\x7"
let &t_SR = "\<Esc>]12;red\x7"
let &t_EI = "\<Esc>]12;blue\x7"
endif
NOTE: When Vim exits the shape for Normal mode will remain. The shape from

View File

@ -1,4 +1,4 @@
*todo.txt* For Vim version 7.4. Last change: 2014 Dec 14
*todo.txt* For Vim version 7.4. Last change: 2015 Jul 21
VIM REFERENCE MANUAL by Bram Moolenaar
@ -35,8 +35,10 @@ not be repeated below, unless there is extra information.
-------------------- Known bugs and current work -----------------------
Regexp problems:
- The NFA engine does not implement the time limit passed to
nfa_regexec_multi()
- The old engine does not find a match for "/\%#=1\(\)\{80}", the new engine
matches everywhere.
- Using win_linetabsize() can still be slow. Cache the result, store col and
vcol. Reset them when moving to another line.
- Very slow with a long line and Ruby highlighting. (John Whitley, 2014 Dec 4)
- Bug with pattern: '\vblock (\d+)\.\n.*\d+%(\1)@<!\.$'
(Lech Lorens, 2014 Feb 3)
@ -51,100 +53,130 @@ Regexp problems:
- Does not work with NFA regexp engine:
\%u, \%x, \%o, \%d followed by a composing character
- Bug relating to back references. (Ingo Karkat, 2014 Jul 24)
- New RE does not give an error for empty group: "\(\)\{2}" (Dominique Pelle,
2015 Feb 7)
- Using back reference before the capturing group sometimes works with the old
engine, can we do this with the new engine? E.g. with
"/\%(<\1>\)\@<=.*\%(<\/\(\w\+\)>\)\@=" matching text inside HTML tags.
This problem is probably the same: "\%(^\1.*$\n\)\@<=\(\d\+\).*$".
(guotuofeng, 2015 Jun 22)
- Strange matching with "\(Hello\n\)\@<=A". (Anas Syed, 2015 Feb 12)
- Problem with \v(A)@<=b+\1c. (Issue 334)
- Diff highlighting can be very slow. (Issue 309)
- Using %> for a virtual column has a check based on 'tabsize'. Better would
be to cache the result of win_linetabsize(col), storing both col and vcol,
and use them to decide whether win_linetabsize() needs to be called. Reset
col and vcol when moving to another line.
- this doesn't work: "syntax match ErrorMsg /.\%9l\%>20c\&\%<28c/". Leaving
out the \& works. Seems any column check after \& fails.
Still using freed memory after using setloclist(). (lcd, 2014 Jul 23)
More info Jul 24. Not clear why.
RXVT sends a different background color response. (Higashi, 2015 Jul 5)
More tests for :diffoff. Olaf Dabrunz, (2015 Jul 4)
Problem that a previous silent ":throw" causes a following try/catch not to
work. (ZyX, 2013 Sep 28)
Problem using ":try" inside ":execute". (ZyX, 2013 Sep 15)
Regression for v_b_A. (Ingo Karkat, 2015 May 18)
":cd C:\Windows\System32\drivers\etc*" does not work, even though the
directory exists. (Sergio Gallelli, 2013 Dec 29)
Invalid memory access in regexp.c. (Dominique Pelle, 2015 May 23)
Using ":windo" to set options in all windows has the side effect that it
changes the window layout and the current window. Make a variant that saves
and restores. Use in the matchparen plugin.
Perhaps we can use ":silent window"?
C indent: should recognize C11 raw strings. (Mark Lodato, 2015 Mar 1)
Need to recognize R"string" for 'cindent'.
Crash when changing the 'tags' option from a remote command.
(Benjamin Fritz, 2015 Mar 18, stack trace Mar 20)
Gvim: when both Tab and CTRL-I are mapped, use CTRL-I not for Tab.
Can src/GvimExt/Make_cyg.mak be removed?
Same for src/xxd/Make_cyg.mak
Python: ":py raw_input('prompt')" doesn't work. (Manu Hack)
MS-Windows: When editing a file with a leading space, writing it uses the
wrong name. (Aram, 2014 Nov 7) Vim 7.4.
Can't recognize the $ProgramFiles(x86) environment variable. Recognize it
specifically? First try with the parens, then without.
Value returned by virtcol() changes depending on how lines wrap. This is
inconsistent with the documentation.
Better greek spell checking. Issue 299.
When complete() first argument is before where insert started and 'backspace'
is Vi compatible, the completion fails. (Hirohito Higashi, 2015 Feb 19)
Test 44 fails when [[=A=]] is changed to [[=À=]]. Caused by getcmdline() not
handling the 0x80 as a second byte correctly? (Dominique Pelle, 2015 Jun 10)
Weird encryption problems on Windows. (Ben Fritz, 2015 Feb 13)
Goes away when disabling the swap file. (might1, Feb 16)
MS-Windows: Crash opening very long file name starting with "\\".
(Christian Brock, 2012 Jun 29)
The argument for "-S" is not taken literally, the ":so" command expands
wildcards. Add a ":nowild" command modifier? (ZyX, 2015 March 4)
Build with Python on Mac does not always use the right library.
(Kazunobu Kuriyama, 2015 Mar 28)
ml_updatechunk() is slow when retrying for another encoding. (John Little,
2014 Sep 11)
When 'showbreak' is set repeating a Visual operation counts the size of the
'showbreak' text as part of the operation. (Axel Bender, 2015 Jul 20)
Patch for multi-byte characters in langmap and applying a mapping on them.
(Christian Brabandt, 2015 Jun 12)
Is this the right solution?
Patch to add grepfile(). (Scott Prager, 2015 May 26)
Work in progress.
Patch to make getregtype() return the right size for non-linux systems.
(Yasuhiro Matsumoto, 2014 Jul 8)
Breaks test_eval. Inefficient, can we only compute y_width when needed?
Problem that a previous silent ":throw" causes a following try/catch not to
work. (ZyX, 2013 Sep 28)
Patch to use different terminal mode settings for system(). (Hayaki Saito)
Does this work for everybody?
":cd C:\Windows\System32\drivers\etc*" does not work, even though the
directory exists. (Sergio Gallelli, 2013 Dec 29)
Patch to fix that wide characters do not work properly after exiting.
(Yasuhiro Matsumoto, 2015 May 24) Better patch to come.
Gvim: when both Tab and CTRL-I are mapped, use CTRL-I not for Tab.
Patch for man.vim. (SungHyun Nam, 2015 May 20)
Doesn't work completely (Dominique Orban)
Problem using ":try" inside ":execute". (ZyX, 2013 Sep 15)
When a session file is created and there are "nofile" buffers, these are not
filled. Need to trigger BufReadCmd autocommands. Also handle deleting the
initial empty buffer better. (ZyX, 2015 March 8)
Python: ":py raw_input('prompt')" doesn't work. (Manu Hack)
Extended file attributes lost on write (backupcopy=no). Issue 306.
When window number in Ex range is too high, should give an error:
:3close " fails if there are only 2 windows.
Patch from Marcin Szamotulski, 2014 Dec 13.
Patch to add :lockjumps. (Carlo Baldassi, 2015 May 25)
OK to not block marks?
Patch to recover from X server restart: hint on Issue 203 (2014 Nov 21 18:44)
Mixup of highlighting when there is a match and SpellBad. (ZyX, 2015 Jan 1)
Insert a block with virtualedit set does not work correctly.
Patch by James McCoy, 2014 Dec 10.
Patch for drag&drop reordering of GUI tab pages reordering.
(Ken Takata, 2013 Nov 22, second one, also by Masamichi Abe)
MS-Windows: When editing a file with a leading space, writing it uses the
wrong name. (Aram, 2014 Nov 7) Vim 7.4.
Add LessCss support. (Jenoma / Alessandro Vioni, 2014 Nov 24)
Now with updated license, Nov 24.
Memory leak using :wviminfo. Issue 296. With Patch by Christian.
patch to remove FEAT_OSFILETYPE from fileio.c. (Christian, 2014 Nov 12)
Value returned by virtcol() changes depending on how lines wrap. This is
inconsistent with the documentation.
Patch to also support range for :argdo, :bufdo, etc.
(Marcin Szamotulski, 2014 Dec 7)
Asked for tests.
Ukrainian vimtutor. (Issue 288)
Regenerate the Unicode tables in mbyte.c.
Diff from ZyX, 2014 Dec 6.
Patch to fix relative numbers. (Christian Brabandt, 2014 Nov 17)
Update Nov 26.
Patch to fix that getcurpos() returns a negative number, instead of MAXCOL.
(Hirohito Higashi, 2014 Dec 8)
Patch to fix wrong formatting if 'linebreak' is set. (Christian Brabandt, 2014
Nov 12)
Patch to avoid recognizing polkit as hog files. (Issue 292)
Patch 7.4.468 changed how CTRL-C is handled. It does not take care of mapping
CTRL-C in different modes. (Ingo Karkat, 2014 Dec 12)
Patch from Christian Brabandt, 2014 Dec 13.
Needs to be improved.
Patch to support hex values for setting option value.
(Zyx, 2015 Nov 6)
On MS-Windows running tests with Mercurial has problems when the fileformat of
the input files are changed. (Ken Takata, Taro Muraoka, 2014 Sep 25)
Update Nov 5.
MS-Windows: Crash opening very long file name starting with "\\".
(Christian Brock, 2012 Jun 29)
Cursorline background color not mixed with character highlight.
Patch by Yasuhiro Matsumoto, 2014 Dec 3.
Problem using diff syntax with cp932 encoding. Idea from Yasuhiro Matsumoto,
patch from Ken Takata (2014 Nov 6)
ml_updatechunk() is slow when retrying for another encoding. (John Little,
2014 Sep 11)
Patch to add a different escape sequence for replace mode.
(Omar Sandoval, 2014 Nov 30)
Patch to allow values greater than 255 for ctermfg/ctermbg on Windows.
(Yasuhiro Matsumoto, 2014 Dec 5)
Patch on Issue 72: 'autochdir' causes problems for :vimgrep.
When 'balloonexpr' returns a list the result has a trailing newline.
Just remove one trailing newline. (lcd, 2014 Oct 17)
@ -165,11 +197,11 @@ Syntax highlighting slow (hangs) in SASS file. (Niek Bosch, 2013 Aug 21)
Patch to add the EndOfBuffer highlight group, used instead of NonText for "~"
lines. (Marco Hinz, 2014 Nov 2)
Patch for fixing a problem of the combination of conceal and linebreak.
(Christian Brabandt, 2014 Dec 11)
Adding "~" to 'cdpath' doesn't work for completion? (Davido, 2013 Aug 19)
Should be easy to highlight all matches with 'incsearch'. Idea by Itchyny,
2015 Feb 6.
Plugins need to make a lot of effort, lots of mappings, to know what happened
before pressing the key that triggers a plugin action. How about keeping the
last N pressed keys, so that they do not need to be mapped?
@ -183,23 +215,45 @@ With test, Nov 23.
Wrong scrolling when using incsearch. Patch by Christian Brabandt, 2014 Dec 4.
Is this a good solution?
Patch to allow setting w:quickfix_title via setqflist() and setloclist()
functions. (Christian Brabandt, 2013 May 8, update May 21)
Patch to add getlocstack() / setlocstack(). (Christian Brabandt, 2013 May 14)
Second one. Update May 22.
Update by Daniel Hahler, 2014 Jul 4, Aug 14, Oct 14, Oct 15.
Patch: Let rare word highlighting overrule good word highlighting.
(Jakson A. Aquino, 2010 Jul 30, again 2011 Jul 2)
Patch to add digits argument to round(). (Yasuhiro Matsumoto, 2015 Apr 26)
Can assign to s:type when a function s:type has been defined.
Also the other way around: define a function while a variable with that name
was already defined.
(Yasuhiro Matsumoto, 2014 Nov 3)
Patch for ordered dict. (Ozaki Kiichi, 2015 May 7)
Patch to make closed folds line up. (Charles Campbell, 2014 Sep 12)
Remark from Roland Eggner: does it cause crashes? (2014 Dec 12)
Updated patch by Roland Eggner, Dec 16
Updated patch from Charles, Dec 29.
Patch to open folds for 'incsearch'. (Christian Brabandt, 2015 Jan 6)
Patch for building a 32bit Vim with 64bit MingW compiler.
(Michael Soyka, 2014 Oct 15)
Delete old code in os_msdos.c, mch_FullName().
Patch: On MS-Windows shellescape() may have to triple double quotes.
(Ingo Karkat, 2015 Jan 16)
Redo only remembers the last change. Could use "{count}g." to redo an older
change. How does the user know which change? At least have a way to list
them: ":repeats".
Patch for glob(), adding slash to normal files. (Ingo Karkat, 2014 Dec 22)
Using "." to repeat an Ex command puts that command in history. Probably
should not happen. If the command is the result of a mapping it's not put in
history either. (Jacob Niehus, 2014 Nov 2)
@ -218,30 +272,25 @@ Patch to add argument to :cquit. (Thinca, 2014 Oct 12)
No error for missing endwhile. (ZyX, 2014 Mar 20)
start_global_changes() plus end_global_changes() causes problem for
clip_unnamed_plus. (Jason Pleau, 2014 Sep 12)
The entries added by matchaddpos() are returned by getmatches() but can't be
set with setmatches(). (lcd47, 2014 Jun 29)
Patch to make extend() fail early when it might fail at some point.
(Olaf Dabrunz, 2015 May 2) Makes extend() slower, do we still want it?
Perhaps only the checks that can be done without looping over the dict or
arguments.
Patch to add :arglocal and :arglists. (Marcin Szamotulski, 2014 Aug 6)
PHP syntax is extremely slow. (Anhad Jai Singh, 2014 Jan 19)
Spell files use a latin single quote. Unicode also has another single quote:
0x2019. (Ron Aaron, 2014 Apr 4)
New OpenOffice spell files support this with ICONV. But they are not
compatible with Vim spell files. The old files can no longer be downloaded.
Patch to make FocusGained and FocusLost work in modern terminals. (Hayaki
Saito, 2013 Apr 24) Has a problem (email 2015 Jan 7).
Update 2015 Jan 10.
Win32: patch to use 64 bit stat() if possible. (Ken Takata, 2014 May 12)
More tests May 14. Update May 29. Update Aug 10.
The garbage collector may use too much stack. Make set_ref_in_item()
iterative instead of recursive. Test program by Marc Weber (2013 Dec 10)
Patch by Ben Fritz, 2014 Jun 22.
Related: Vim hangs when freeing a lot of objects. Patch by Yasuhiro
Matsumoto, 2014 Aug 26.
Idea: For a window in the middle (has window above and below it), use
right-mouse-drag on the status line to move a window up/down without changing
its height? It's like dragging the status bar above it at the same time.
@ -251,6 +300,9 @@ What for systems that don't have unsetenv()?
Patch to add a :domodeline command. (Christian Brabandt, 2014 Oct 21)
Patch to add TabNew, TabNewEntered and TabClosed autocommand events.
(Felipe Morales, 2015 Feb 1)
This does not give an error: (Andre Sihera, 2014 Mar 21)
vim -u NONE 1 2 3 -c 'bufdo if 1 | echo 1'
This neither: (ZyX)
@ -314,7 +366,7 @@ Editing an ascii file as ucs-2 or ucs-4 causes display errors.
":Next 1 some-arg" does not complain about trailing argument. Also for
various other commands. (ZyX, 2014 Mar 30)
patch to skip sort if no line matches the expression.
Patch to skip sort if no line matches the expression.
(Christian Brabandt, 2014 Jun 25)
Patch to add sortuniq(). (Cade Forester, 2014 Mar 19)
@ -341,8 +393,6 @@ Remark on the docs. Should not be a compile time feature. But then what?
Completion of ":e" is ":earlier", should be ":edit". Complete to the matching
command instead of doing this alphabetically. (Mikel Jorgensen)
Patch to add v:completed_item. (Shougo Matsu, 2013 Nov 29).
Patch to get MSVC version in a nicer way. (Ken Takata, 2014 Jul 24)
Patch to define macros for hardcoded values. (Elias Diem, 2013 Dec 14)
@ -350,10 +400,8 @@ Patch to define macros for hardcoded values. (Elias Diem, 2013 Dec 14)
Several syntax file match "^\s*" which may get underlined if that's in the
highlight group. Add a "\zs" after it?
Patch to fix temp directories for Windows, so that it works without tweaking.
Issue 28.
Go through more coverity reports.
The undo file name can get too long. (Issue 346)
For the path use a hash instead of dir%dir%dir%name hash%name.
Patch to add ":undorecover", get as much text out of the undo file as
possible. (Christian Brabandt, 2014 Mar 12, update Aug 22)
@ -405,15 +453,9 @@ When evaluating expression in backticks, autoload doesn't work.
Using <nr>ifoobar<esc> can slow down Vim. Patch by Christian Brabandt, 2013
Dec 13.
Fold can't be opened after ":move". (Ein Brown)
Patch from Christian Brabandt doesn't fix it completely.
Patch from Christian Brabandt to preserve upper case marks when wiping out a
buffer. (2013 Dec 9)
Patch for drag&drop reordering of GUI tab pages reordering.
(Ken Takata, 2013 Nov 22, second one, also by Masamichi Abe)
GTK: problem with 'L' in 'guioptions' changing the window width.
(Aaron Cornelius, 2012 Feb 6)
@ -441,9 +483,6 @@ Works OK for echo, just not for ":call" and ":call call()". (Ted, 2011 Mar
Patch by Christian Brabandt, 2013 Mar 23.
Not 100% sure this is the right solution.
Problem caused by patch 7.3.638: window->open does not update window
correctly. Issue 91.
Patch to add {lhs} to :mapclear: clear all maps starting with {lhs}.
(Christian Brabandt, 2013 Dec 9)
@ -486,12 +525,6 @@ Dialog is too big on Linux too. (David Fishburn, 2013 Sep 2)
Patch to check whether a buffer is quickfix or a location list.
(Yasuhiro Matsumoto, 2014 Dec 9)
Patch to allow setting w:quickfix_title via setqflist() and setloclist()
functions. (Christian Brabandt, 2013 May 8, update May 21)
Patch to add getlocstack() / setlocstack(). (Christian Brabandt, 2013 May 14)
Second one. Update May 22.
Update by Daniel Hahler, 2014 Jul 4, Aug 14, Oct 14, Oct 15.
Patch to make fold updates much faster. (Christian Brabandt, 2012 Dec)
Issue 54: document behavior of -complete, also expands arg.
@ -502,8 +535,6 @@ Patch by Christian Brabandt, 2013 Apr 20, unfinished.
Bug: findfile("any", "file:///tmp;") does not work.
'ff' is wrong for one-line file without EOL. (Issue 77)
Patch to set antialiasing style on Windows. (Ondrej Balaz, 2013 Mar 14)
Needs a different check for CLEARTYPE_QUALITY.
@ -542,10 +573,6 @@ signs? Patch by Christian Brabandt, 2013 Aug 22.
Patch to remove flicker from popup menu. (Yasuhiro Matsumoto, 2013 Aug 15)
Patch to add 'completeselect' option. Specifies how to select a candidate in
insert completion. (Shougo, 2013 May 29)
Update to add to existing 'completeopt'. 2013 May 30
Problem with refresh:always in completion. (Tyler Wade, 2013 Mar 17)
b:undo_ftplugin cannot call a script-local function. (Boris Danilov, 2013 Jan
@ -567,15 +594,10 @@ Patch to improve equivalence classes in regexp patterns.
Patch with suggestions for starting.txt. (Tony Mechelynck, 2012 Oct 24)
But use Gnome instead of GTK?
Patch to make FocusGained and FocusLost work in modern terminals. (Hayaki
Saito, 2013 Apr 24)
Should be possible to enable/disable matchparen per window or buffer.
Add a check for b:no_match_paren in Highlight_matching_Pair() (Marcin
Szamotulski, 2012 Nov 8)
Issue 72: 'autochdir' causes problems for :vimgrep.
Session file creation: 'autochdir' causes trouble. Keep it off until after
loading all files.
@ -584,7 +606,9 @@ line are opened again, but from the wrong directory. Apply 'autochdir' only
after starting up?
Patch to add ":ldo" and ":cdo", execute commands over quickfix list and
location list. (Yegappan Lakshmanan, 2013 Jun 2)
location list. (Yegappan Lakshmanan, 2013 Jun 2, update 2015 Mar 21)
Update by Florian Walch, 2015 Jul 1.
Yegappan will send an update in July.
8 "stl" and "stlnc" in 'fillchars' don't work for multi-byte characters.
Patch by Christian Wellenbrock, 2013 Jul 5.
@ -977,9 +1001,6 @@ Patch for GVimExt to show an icon. (Dominik Riebeling, 2010 Nov 7)
When writing a file > 2Gbyte, the reported number of bytes is negative.
(Antonio Colombo, 2010 Dec 18)
Patch: Let rare word highlighting overrule good word highlighting.
(Jakson A. Aquino, 2010 Jul 30, again 2011 Jul 2)
When 'lines' is 25 and 'scrolloff' is 12, "j" scrolls zero or two lines
instead of one. (Constantin Pan, 2010 Sep 10)
@ -1037,8 +1058,8 @@ Dominique can't reproduce it.
":function f(x) keepjumps" creates a function where every command is executed
like it has ":keepjumps" before it.
Coverity: ask someone to create new user: Dominique.
Check if there are new reported defects: http://scan.coverity.com/rung2.html
Coverity: Check if there are new reported defects:
https://scan.coverity.com/projects/241
Patch to support :undo absolute jump to file save number. (Christian Brabandt,
2010 Nov 5)
@ -1074,7 +1095,7 @@ string value.
Invalid read error in Farsi mode. (Dominique Pelle, 2009 Aug 2)
For running gvim on an USB stick: avoid the OLE registration. Use a command
For running gvim on a USB stick: avoid the OLE registration. Use a command
line argument -noregister.
When using an expression in 'statusline' leading white space sometimes goes
@ -1388,6 +1409,7 @@ Kondakoff, 2009 May 13)
Problem with 'langmap' being used on the rhs of a mapping. (Nikolai Weibull,
2008 May 14)
Possibly related problem: Alexey Muranov, 2015 Apr 2
Problem with CTRL-F. (Charles Campbell, 2008 March 21)
Only happens with "gvim -geometry "160x26+4+27" -u NONE -U NONE prop.c".
@ -1648,12 +1670,6 @@ Check for this and use iconv? (Edward L. Fox, 2007 Sep 12)
Does the conversion in the other direction work when 'fileencodings' is set
properly?
Add a few features to xxd. (Vadim Vygonets, 2013 Nov 11)
Patches: 2013 Nov 19
1: Add -e: little endian hexdump
2: Add -o: add offset to displayed position
3: Change displayed file position width to 8 chars
Cursor displayed in the wrong position when using 'numberwidth'. (James Vega,
2007 Jun 21)
@ -2098,8 +2114,6 @@ Awaiting updated patches:
Search in 'runtimepath'?
More docs needed about how to use this.
How to get the messages into the .po files?
strchars() Like strlen() and strwidth() but counting characters
instead of bytes.
confirm() add "flags" argument, with 'v' for vertical
layout and 'c' for console dialog. (Haegg)
Flemming Madsen has a patch for the 'c' flag
@ -4034,8 +4048,6 @@ Autocommands:
8 Autocommand for when modified files have been found, when getting input
focus again (e.g., FileChangedFocus).
Check when: getting focus, jumping to another buffer, ...
7 Autocommand for when an option is changed. Match buffer name or option
name?
8 Autocommands should not change registers. And marks? And the jumplist?
And anything else? Add a command to save and restore these things.
8 Add autocommands, user functions and user commands to ":mkvimrc".
@ -4649,7 +4661,6 @@ Searching:
should be ignored (like "*/" or "#endif" inside /* */).
Also: use "%" to jump from start to end of syntax region and back.
Alternative: use matchit.vim
8 "/:/e+1" gets stuck on a match at the end of the line. Do we care?
8 A pattern like "\([^a]\+\)\+" takes an awful long time. Recognize that
the recursive "\+" is meaningless and optimize for it.
This one is also very slow on "/* some comment */": "^\/\*\(.*[^/]\)*$".
@ -5076,8 +5087,6 @@ Argument list:
Registers:
8 Don't display empty registers with ":display". (Etienne)
8 Make the # register writable, so that it can be restored after jumping
around in windows.
8 Add put command that overwrites existing text. Should also work for
blocks. Useful to move text around in a table. Works like using "R ^R r"
for every line.

View File

@ -194,7 +194,7 @@ child, you should have the intention to do this for at least one year.
How do you know that the money will be spent right? First of all you have my
personal guarantee as the author of Vim. I trust the people that are working
at the centre, I know them personally. Further more, the centre has been
at the centre, I know them personally. Furthermore, the centre has been
co-sponsored and inspected by World Vision, Save the Children Fund and is now
under the supervision of Pacific Academy Outreach Society. The centre is
visited about once a year to check the progress (at our own cost). I have

View File

@ -1,4 +1,4 @@
*usr_02.txt* For Vim version 7.4. Last change: 2010 Jul 20
*usr_02.txt* For Vim version 7.4. Last change: 2015 Apr 12
VIM USER MANUAL - by Bram Moolenaar
@ -527,9 +527,11 @@ Summary: *help-summary* >
:help subject()
< Function "subject". >
:help -subject
< Command-line option "-subject". >
< Command-line argument "-subject". >
:help +subject
< Compile-time feature "+subject". >
:help /*
< Regular expression item "*" >
:help EventName
< Autocommand event "EventName". >
:help digraphs.txt

View File

@ -532,7 +532,7 @@ MATCHING ANY SINGLE CHARACTER
The . (dot) character matches any existing character. For example, the
pattern "c.m" matches a string whose first character is a c, whose second
character is anything, and whose the third character is m. Example:
character is anything, and whose third character is m. Example:
We use a computer that became the cummin winter. ~
xxx xxx xxx

View File

@ -135,7 +135,7 @@ For the first file the cursor will be positioned on line "num".
If "num" is missing, the cursor will be positioned on the last line.
.TP
+/{pat}
For the first file the cursor will be positioned on the
For the first file the cursor will be positioned in the line with the
first occurrence of {pat}.
See ":help search\-pattern" for the available search patterns.
.TP

View File

@ -1,4 +1,4 @@
VIM(1) VIM(1)
VIM(1) General Commands Manual VIM(1)
@ -21,13 +21,13 @@ DESCRIPTION
to edit all kinds of plain text. It is especially useful for editing
programs.
There are a lot of enhancements above Vi: multi level undo, multi win-
There are a lot of enhancements above Vi: multi level undo, multi win
dows and buffers, syntax highlighting, command line editing, filename
completion, on-line help, visual selection, etc.. See ":help
vi_diff.txt" for a summary of the differences between Vim and Vi.
While running Vim a lot of help can be obtained from the on-line help
system, with the ":help" command. See the ON-LINE HELP section below.
system, with the ":help" command. See the ON-LINE HELP section below.
Most often Vim is started to edit a single file with the command
@ -38,44 +38,44 @@ DESCRIPTION
vim [options] [filelist]
If the filelist is missing, the editor will start with an empty buffer.
Otherwise exactly one out of the following four may be used to choose
Otherwise exactly one out of the following four may be used to choose
one or more files to be edited.
file .. A list of filenames. The first one will be the current
file and read into the buffer. The cursor will be posi-
file .. A list of filenames. The first one will be the current
file and read into the buffer. The cursor will be posi
tioned on the first line of the buffer. You can get to the
other files with the ":next" command. To edit a file that
other files with the ":next" command. To edit a file that
starts with a dash, precede the filelist with "--".
- The file to edit is read from stdin. Commands are read
- The file to edit is read from stdin. Commands are read
from stderr, which should be a tty.
-t {tag} The file to edit and the initial cursor position depends on
a "tag", a sort of goto label. {tag} is looked up in the
a "tag", a sort of goto label. {tag} is looked up in the
tags file, the associated file becomes the current file and
the associated command is executed. Mostly this is used
for C programs, in which case {tag} could be a function
the associated command is executed. Mostly this is used
for C programs, in which case {tag} could be a function
name. The effect is that the file containing that function
becomes the current file and the cursor is positioned on
becomes the current file and the cursor is positioned on
the start of the function. See ":help tag-commands".
-q [errorfile]
Start in quickFix mode. The file [errorfile] is read and
the first error is displayed. If [errorfile] is omitted,
Start in quickFix mode. The file [errorfile] is read and
the first error is displayed. If [errorfile] is omitted,
the filename is obtained from the 'errorfile' option
(defaults to "AztecC.Err" for the Amiga, "errors.err" on
other systems). Further errors can be jumped to with the
(defaults to "AztecC.Err" for the Amiga, "errors.err" on
other systems). Further errors can be jumped to with the
":cn" command. See ":help quickfix".
Vim behaves differently, depending on the name of the command (the exe-
Vim behaves differently, depending on the name of the command (the exe
cutable may still be the same file).
vim The "normal" way, everything is default.
ex Start in Ex mode. Go to Normal mode with the ":vi" command.
ex Start in Ex mode. Go to Normal mode with the ":vi" command.
Can also be done with the "-e" argument.
view Start in read-only mode. You will be protected from writing
view Start in read-only mode. You will be protected from writing
the files. Can also be done with the "-R" argument.
gvim gview
@ -87,102 +87,102 @@ DESCRIPTION
be done with the "-y" argument.
rvim rview rgvim rgview
Like the above, but with restrictions. It will not be possi-
ble to start shell commands, or suspend Vim. Can also be
Like the above, but with restrictions. It will not be possi
ble to start shell commands, or suspend Vim. Can also be
done with the "-Z" argument.
OPTIONS
The options may be given in any order, before or after filenames.
The options may be given in any order, before or after filenames.
Options without an argument can be combined after a single dash.
+[num] For the first file the cursor will be positioned on line
"num". If "num" is missing, the cursor will be positioned
+[num] For the first file the cursor will be positioned on line
"num". If "num" is missing, the cursor will be positioned
on the last line.
+/{pat} For the first file the cursor will be positioned on the
first occurrence of {pat}. See ":help search-pattern" for
the available search patterns.
+/{pat} For the first file the cursor will be positioned in the
line with the first occurrence of {pat}. See ":help
search-pattern" for the available search patterns.
+{command}
-c {command}
{command} will be executed after the first file has been
read. {command} is interpreted as an Ex command. If the
{command} contains spaces it must be enclosed in double
quotes (this depends on the shell that is used). Example:
{command} will be executed after the first file has been
read. {command} is interpreted as an Ex command. If the
{command} contains spaces it must be enclosed in double
quotes (this depends on the shell that is used). Example:
Vim "+set si" main.c
Note: You can use up to 10 "+" or "-c" commands.
-S {file} {file} will be sourced after the first file has been read.
This is equivalent to -c "source {file}". {file} cannot
-S {file} {file} will be sourced after the first file has been read.
This is equivalent to -c "source {file}". {file} cannot
start with '-'. If {file} is omitted "Session.vim" is used
(only works when -S is the last argument).
--cmd {command}
Like using "-c", but the command is executed just before
processing any vimrc file. You can use up to 10 of these
Like using "-c", but the command is executed just before
processing any vimrc file. You can use up to 10 of these
commands, independently from "-c" commands.
-A If Vim has been compiled with ARABIC support for editing
right-to-left oriented files and Arabic keyboard mapping,
this option starts Vim in Arabic mode, i.e. 'arabic' is
-A If Vim has been compiled with ARABIC support for editing
right-to-left oriented files and Arabic keyboard mapping,
this option starts Vim in Arabic mode, i.e. 'arabic' is
set. Otherwise an error message is given and Vim aborts.
-b Binary mode. A few options will be set that makes it pos-
-b Binary mode. A few options will be set that makes it pos
sible to edit a binary or executable file.
-C Compatible. Set the 'compatible' option. This will make
Vim behave mostly like Vi, even though a .vimrc file
-C Compatible. Set the 'compatible' option. This will make
Vim behave mostly like Vi, even though a .vimrc file
exists.
-d Start in diff mode. There should be two, three or four
file name arguments. Vim will open all the files and show
-d Start in diff mode. There should be two, three or four
file name arguments. Vim will open all the files and show
differences between them. Works like vimdiff(1).
-d {device} Open {device} for use as a terminal. Only on the Amiga.
-d {device} Open {device} for use as a terminal. Only on the Amiga.
Example: "-d con:20/30/600/150".
-D Debugging. Go to debugging mode when executing the first
-D Debugging. Go to debugging mode when executing the first
command from a script.
-e Start Vim in Ex mode, just like the executable was called
-e Start Vim in Ex mode, just like the executable was called
"ex".
-E Start Vim in improved Ex mode, just like the executable was
called "exim".
-f Foreground. For the GUI version, Vim will not fork and
-f Foreground. For the GUI version, Vim will not fork and
detach from the shell it was started in. On the Amiga, Vim
is not restarted to open a new window. This option should
be used when Vim is executed by a program that will wait
for the edit session to finish (e.g. mail). On the Amiga
is not restarted to open a new window. This option should
be used when Vim is executed by a program that will wait
for the edit session to finish (e.g. mail). On the Amiga
the ":sh" and ":!" commands will not work.
--nofork Foreground. For the GUI version, Vim will not fork and
--nofork Foreground. For the GUI version, Vim will not fork and
detach from the shell it was started in.
-F If Vim has been compiled with FKMAP support for editing
right-to-left oriented files and Farsi keyboard mapping,
this option starts Vim in Farsi mode, i.e. 'fkmap' and
'rightleft' are set. Otherwise an error message is given
and Vim aborts.
-g If Vim has been compiled with GUI support, this option
enables the GUI. If no GUI support was compiled in, an
error message is given and Vim aborts.
-h Give a bit of help about the command line arguments and
options. After this Vim exits.
-H If Vim has been compiled with RIGHTLEFT support for editing
right-to-left oriented files and Hebrew keyboard mapping,
this option starts Vim in Hebrew mode, i.e. 'hkmap' and
-F If Vim has been compiled with FKMAP support for editing
right-to-left oriented files and Farsi keyboard mapping,
this option starts Vim in Farsi mode, i.e. 'fkmap' and
'rightleft' are set. Otherwise an error message is given
and Vim aborts.
-g If Vim has been compiled with GUI support, this option
enables the GUI. If no GUI support was compiled in, an
error message is given and Vim aborts.
-h Give a bit of help about the command line arguments and
options. After this Vim exits.
-H If Vim has been compiled with RIGHTLEFT support for editing
right-to-left oriented files and Hebrew keyboard mapping,
this option starts Vim in Hebrew mode, i.e. 'hkmap' and
'rightleft' are set. Otherwise an error message is given
and Vim aborts.
-i {viminfo}
When using the viminfo file is enabled, this option sets
the filename to use, instead of the default "~/.viminfo".
When using the viminfo file is enabled, this option sets
the filename to use, instead of the default "~/.viminfo".
This can also be used to skip the use of the .viminfo file,
by giving the name "NONE".
@ -190,92 +190,92 @@ OPTIONS
-l Lisp mode. Sets the 'lisp' and 'showmatch' options on.
-m Modifying files is disabled. Resets the 'write' option.
You can still modify the buffer, but writing a file is not
-m Modifying files is disabled. Resets the 'write' option.
You can still modify the buffer, but writing a file is not
possible.
-M Modifications not allowed. The 'modifiable' and 'write'
options will be unset, so that changes are not allowed and
files can not be written. Note that these options can be
-M Modifications not allowed. The 'modifiable' and 'write'
options will be unset, so that changes are not allowed and
files can not be written. Note that these options can be
set to enable making modifications.
-N No-compatible mode. Reset the 'compatible' option. This
will make Vim behave a bit better, but less Vi compatible,
-N No-compatible mode. Reset the 'compatible' option. This
will make Vim behave a bit better, but less Vi compatible,
even though a .vimrc file does not exist.
-n No swap file will be used. Recovery after a crash will be
impossible. Handy if you want to edit a file on a very
slow medium (e.g. floppy). Can also be done with ":set
-n No swap file will be used. Recovery after a crash will be
impossible. Handy if you want to edit a file on a very
slow medium (e.g. floppy). Can also be done with ":set
uc=0". Can be undone with ":set uc=200".
-nb Become an editor server for NetBeans. See the docs for
-nb Become an editor server for NetBeans. See the docs for
details.
-o[N] Open N windows stacked. When N is omitted, open one window
for each file.
-O[N] Open N windows side by side. When N is omitted, open one
-O[N] Open N windows side by side. When N is omitted, open one
window for each file.
-p[N] Open N tab pages. When N is omitted, open one tab page for
each file.
-R Read-only mode. The 'readonly' option will be set. You
can still edit the buffer, but will be prevented from acci-
dently overwriting a file. If you do want to overwrite a
file, add an exclamation mark to the Ex command, as in
":w!". The -R option also implies the -n option (see
below). The 'readonly' option can be reset with ":set
-R Read-only mode. The 'readonly' option will be set. You
can still edit the buffer, but will be prevented from acci
dently overwriting a file. If you do want to overwrite a
file, add an exclamation mark to the Ex command, as in
":w!". The -R option also implies the -n option (see
below). The 'readonly' option can be reset with ":set
noro". See ":help 'readonly'".
-r List swap files, with information about using them for
-r List swap files, with information about using them for
recovery.
-r {file} Recovery mode. The swap file is used to recover a crashed
editing session. The swap file is a file with the same
-r {file} Recovery mode. The swap file is used to recover a crashed
editing session. The swap file is a file with the same
filename as the text file with ".swp" appended. See ":help
recovery".
-s Silent mode. Only when started as "Ex" or when the "-e"
-s Silent mode. Only when started as "Ex" or when the "-e"
option was given before the "-s" option.
-s {scriptin}
The script file {scriptin} is read. The characters in the
file are interpreted as if you had typed them. The same
The script file {scriptin} is read. The characters in the
file are interpreted as if you had typed them. The same
can be done with the command ":source! {scriptin}". If the
end of the file is reached before the editor exits, further
characters are read from the keyboard.
-T {terminal}
Tells Vim the name of the terminal you are using. Only
required when the automatic way doesn't work. Should be a
terminal known to Vim (builtin) or defined in the termcap
Tells Vim the name of the terminal you are using. Only
required when the automatic way doesn't work. Should be a
terminal known to Vim (builtin) or defined in the termcap
or terminfo file.
-u {vimrc} Use the commands in the file {vimrc} for initializations.
All the other initializations are skipped. Use this to
edit a special kind of files. It can also be used to skip
all initializations by giving the name "NONE". See ":help
-u {vimrc} Use the commands in the file {vimrc} for initializations.
All the other initializations are skipped. Use this to
edit a special kind of files. It can also be used to skip
all initializations by giving the name "NONE". See ":help
initialization" within vim for more details.
-U {gvimrc} Use the commands in the file {gvimrc} for GUI initializa-
tions. All the other GUI initializations are skipped. It
can also be used to skip all GUI initializations by giving
the name "NONE". See ":help gui-init" within vim for more
-U {gvimrc} Use the commands in the file {gvimrc} for GUI initializa
tions. All the other GUI initializations are skipped. It
can also be used to skip all GUI initializations by giving
the name "NONE". See ":help gui-init" within vim for more
details.
-V[N] Verbose. Give messages about which files are sourced and
for reading and writing a viminfo file. The optional num-
-V[N] Verbose. Give messages about which files are sourced and
for reading and writing a viminfo file. The optional num
ber N is the value for 'verbose'. Default is 10.
-v Start Vim in Vi mode, just like the executable was called
"vi". This only has effect when the executable is called
-v Start Vim in Vi mode, just like the executable was called
"vi". This only has effect when the executable is called
"ex".
-w {scriptout}
All the characters that you type are recorded in the file
{scriptout}, until you exit Vim. This is useful if you
want to create a script file to be used with "vim -s" or
All the characters that you type are recorded in the file
{scriptout}, until you exit Vim. This is useful if you
want to create a script file to be used with "vim -s" or
":source!". If the {scriptout} file exists, characters are
appended.
@ -285,27 +285,27 @@ OPTIONS
-x Use encryption when writing files. Will prompt for a crypt
key.
-X Don't connect to the X server. Shortens startup time in a
terminal, but the window title and clipboard will not be
-X Don't connect to the X server. Shortens startup time in a
terminal, but the window title and clipboard will not be
used.
-y Start Vim in easy mode, just like the executable was called
"evim" or "eview". Makes Vim behave like a click-and-type
"evim" or "eview". Makes Vim behave like a click-and-type
editor.
-Z Restricted mode. Works like the executable starts with
-Z Restricted mode. Works like the executable starts with
"r".
-- Denotes the end of the options. Arguments after this will
be handled as a file name. This can be used to edit a
-- Denotes the end of the options. Arguments after this will
be handled as a file name. This can be used to edit a
filename that starts with a '-'.
--echo-wid GTK GUI only: Echo the Window ID on stdout.
--help Give a help message and exit, just like "-h".
--literal Take file name arguments literally, do not expand wild-
cards. This has no effect on Unix where the shell expands
--literal Take file name arguments literally, do not expand wild
cards. This has no effect on Unix where the shell expands
wildcards.
--noplugin Skip loading plugins. Implied by -u NONE.
@ -315,18 +315,18 @@ OPTIONS
is given and the files are edited in the current Vim.
--remote-expr {expr}
Connect to a Vim server, evaluate {expr} in it and print
Connect to a Vim server, evaluate {expr} in it and print
the result on stdout.
--remote-send {keys}
Connect to a Vim server and send {keys} to it.
--remote-silent
As --remote, but without the warning when no server is
As --remote, but without the warning when no server is
found.
--remote-wait
As --remote, but Vim does not exit until the files have
As --remote, but Vim does not exit until the files have
been edited.
--remote-wait-silent
@ -337,31 +337,31 @@ OPTIONS
List the names of all Vim servers that can be found.
--servername {name}
Use {name} as the server name. Used for the current Vim,
Use {name} as the server name. Used for the current Vim,
unless used with a --remote argument, then it's the name of
the server to connect to.
--socketid {id}
GTK GUI only: Use the GtkPlug mechanism to run gvim in
GTK GUI only: Use the GtkPlug mechanism to run gvim in
another window.
--version Print version information and exit.
ON-LINE HELP
Type ":help" in Vim to get started. Type ":help subject" to get help
on a specific subject. For example: ":help ZZ" to get help for the
"ZZ" command. Use <Tab> and CTRL-D to complete subjects (":help cmd-
line-completion"). Tags are present to jump from one place to another
Type ":help" in Vim to get started. Type ":help subject" to get help
on a specific subject. For example: ":help ZZ" to get help for the
"ZZ" command. Use <Tab> and CTRL-D to complete subjects (":help cmd
line-completion"). Tags are present to jump from one place to another
(sort of hypertext links, see ":help"). All documentation files can be
viewed in this way, for example ":help syntax.txt".
FILES
/usr/local/lib/vim/doc/*.txt
The Vim documentation files. Use ":help doc-file-list"
The Vim documentation files. Use ":help doc-file-list"
to get the complete list.
/usr/local/lib/vim/doc/tags
The tags file used for finding information in the docu-
The tags file used for finding information in the docu
mentation files.
/usr/local/lib/vim/syntax/syntax.vim
@ -381,7 +381,7 @@ FILES
~/.gvimrc Your personal gvim initializations.
/usr/local/lib/vim/optwin.vim
Script used for the ":options" command, a nice way to
Script used for the ":options" command, a nice way to
view and set options.
/usr/local/lib/vim/menu.vim
@ -391,11 +391,11 @@ FILES
Script to generate a bug report. See ":help bugs".
/usr/local/lib/vim/filetype.vim
Script to detect the type of a file by its name. See
Script to detect the type of a file by its name. See
":help 'filetype'".
/usr/local/lib/vim/scripts.vim
Script to detect the type of a file by its contents.
Script to detect the type of a file by its contents.
See ":help 'filetype'".
/usr/local/lib/vim/print/*.ps
@ -410,8 +410,8 @@ SEE ALSO
AUTHOR
Most of Vim was made by Bram Moolenaar, with a lot of help from others.
See ":help credits" in Vim.
Vim is based on Stevie, worked on by: Tim Thompson, Tony Andrews and
G.R. (Fred) Walter. Although hardly any of the original code remains.
Vim is based on Stevie, worked on by: Tim Thompson, Tony Andrews and
G.R. (Fred) Walter. Although hardly any of the original code remains.
BUGS
Probably. See ":help todo" for a list of known problems.

View File

@ -1,4 +1,4 @@
*windows.txt* For Vim version 7.4. Last change: 2014 Dec 05
*windows.txt* For Vim version 7.4. Last change: 2015 Jul 21
VIM REFERENCE MANUAL by Bram Moolenaar
@ -698,8 +698,9 @@ can also get to them with the buffer list commands, like ":bnext".
8. Do a command in all buffers or windows *list-repeat*
*:windo*
:windo {cmd} Execute {cmd} in each window.
It works like doing this: >
:[range]windo {cmd} Execute {cmd} in each window or if [range] is given
only in windows for which the window number lies in
the [range]. It works like doing this: >
CTRL-W t
:{cmd}
CTRL-W w
@ -717,8 +718,10 @@ can also get to them with the buffer list commands, like ":bnext".
Also see |:tabdo|, |:argdo| and |:bufdo|.
*:bufdo*
:bufdo[!] {cmd} Execute {cmd} in each buffer in the buffer list.
It works like doing this: >
:[range]bufdo[!] {cmd} Execute {cmd} in each buffer in the buffer list or if
[range] is given only for buffers for which their
buffer numer is in the [range]. It works like doing
this: >
:bfirst
:{cmd}
:bnext
@ -983,9 +986,10 @@ A buffer can also be unlisted. This means it exists, but it is not in the
list of buffers. |unlisted-buffer|
:files[!] *:files*
:buffers[!] *:buffers* *:ls*
:ls[!] Show all buffers. Example:
:files[!] [flags] *:files*
:buffers[!] [flags] *:buffers* *:ls*
:ls[!] [flags]
Show all buffers. Example:
1 #h "/test/text" line 1 ~
2u "asdf" line 0 ~
@ -995,8 +999,8 @@ list of buffers. |unlisted-buffer|
(the term "unlisted" is a bit confusing then...).
Each buffer has a unique number. That number will not change,
so you can always go to a specific buffer with ":buffer N" or
"N CTRL-^", where N is the buffer number.
thus you can always go to a specific buffer with ":buffer N"
or "N CTRL-^", where N is the buffer number.
Indicators (chars in the same column are mutually exclusive):
u an unlisted buffer (only displayed when [!] is used)
@ -1011,6 +1015,21 @@ list of buffers. |unlisted-buffer|
+ a modified buffer
x a buffer with read errors
[flags] can be a combination of the following characters,
which restrict the buffers to be listed:
+ modified buffers
- buffers with 'modifiable' off
= readonly buffers
a active buffers
u unloaded buffers (overrides the "!")
h hidden buffers
x buffers with a read error
% current buffer
# alternate buffer
Combining flags means they are "and"ed together, e.g.:
h+ hidden buffers which are modified
a+ active buffers which are modified
*:bad* *:badd*
:bad[d] [+lnum] {fname}
Add file name {fname} to the buffer list, without loading it.

View File

@ -76,6 +76,16 @@ Change the character encoding in the righthand column from ASCII to EBCDIC.
This does not change the hexadecimal representation. The option is
meaningless in combinations with \-r, \-p or \-i.
.TP
.IR \-e
Switch to little-endian hexdump.
This option treats byte groups as words in little-endian byte order.
The default grouping of 4 bytes may be changed using
.RI "" \-g .
This option only applies to hexdump, leaving the ASCII (or EBCDIC)
representation unchanged.
The command line switches
\-r, \-p, \-i do not work with this mode.
.TP
.IR "\-g bytes " | " \-groupsize bytes"
separate the output of every
.RI < bytes >
@ -84,7 +94,7 @@ Specify
.I \-g 0
to suppress grouping.
.RI < Bytes "> defaults to " 2
in normal mode and \fI1\fP in bits mode.
in normal mode, \fI4\fP in little-endian mode and \fI1\fP in bits mode.
Grouping does not apply to postscript or include style.
.TP
.IR \-h " | " \-help
@ -99,6 +109,11 @@ stop after writing
.RI < len >
octets.
.TP
.I \-o offset
add
.RI < offset >
to the displayed file position.
.TP
.IR \-p " | " \-ps " | " \-postscript " | " \-plain
output in postscript continuous hexdump style. Also known as plain hexdump
style.

View File

@ -1,4 +1,4 @@
XXD(1) XXD(1)
XXD(1) General Commands Manual XXD(1)
@ -14,30 +14,29 @@ DESCRIPTION
xxd creates a hex dump of a given file or standard input. It can also
convert a hex dump back to its original binary form. Like uuencode(1)
and uudecode(1) it allows the transmission of binary data in a `mail-
safe' ASCII representation, but has the advantage of decoding to stan-
safe' ASCII representation, but has the advantage of decoding to stan
dard output. Moreover, it can be used to perform binary file patching.
OPTIONS
If no infile is given, standard input is read. If infile is specified
as a `-' character, then input is taken from standard input. If no
If no infile is given, standard input is read. If infile is specified
as a `-' character, then input is taken from standard input. If no
outfile is given (or a `-' character is in its place), results are sent
to standard output.
Note that a "lazy" parser is used which does not check for more than
the first option letter, unless the option is followed by a parameter.
Spaces between a single option letter and its parameter are optional.
Note that a "lazy" parser is used which does not check for more than
the first option letter, unless the option is followed by a parameter.
Spaces between a single option letter and its parameter are optional.
Parameters to options can be specified in decimal, hexadecimal or octal
notation. Thus -c8, -c 8, -c 010 and -cols 8 are all equivalent.
-a | -autoskip
toggle autoskip: A single '*' replaces nul-lines. Default off.
toggle autoskip: A single '*' replaces nul-lines. Default off.
-b | -bits
Switch to bits (binary digits) dump, rather than hexdump. This
option writes octets as eight digits "1"s and "0"s instead of a
normal hexadecimal dump. Each line is preceded by a line number
in hexadecimal and followed by an ascii (or ebcdic) representa-
in hexadecimal and followed by an ascii (or ebcdic) representa
tion. The command line switches -r, -p, -i do not work with this
mode.
@ -50,25 +49,34 @@ OPTIONS
to EBCDIC. This does not change the hexadecimal representation.
The option is meaningless in combinations with -r, -p or -i.
-e Switch to little-endian hexdump. This option treats byte groups
as words in little-endian byte order. The default grouping of 4
bytes may be changed using -g. This option only applies to hex
dump, leaving the ASCII (or EBCDIC) representation unchanged.
The command line switches -r, -p, -i do not work with this mode.
-g bytes | -groupsize bytes
separate the output of every <bytes> bytes (two hex characters
or eight bit-digits each) by a whitespace. Specify -g 0 to sup-
press grouping. <Bytes> defaults to 2 in normal mode and 1 in
bits mode. Grouping does not apply to postscript or include
style.
or eight bit-digits each) by a whitespace. Specify -g 0 to sup
press grouping. <Bytes> defaults to 2 in normal mode, 4 in lit
tle-endian mode and 1 in bits mode. Grouping does not apply to
postscript or include style.
-h | -help
print a summary of available commands and exit. No hex dumping
is performed.
-i | -include
output in C include file style. A complete static array defini-
output in C include file style. A complete static array defini
tion is written (named after the input file), unless xxd reads
from stdin.
-l len | -len len
stop after writing <len> octets.
-o offset
add <offset> to the displayed file position.
-p | -ps | -postscript | -plain
output in postscript continuous hexdump style. Also known as
plain hexdump style.
@ -76,8 +84,8 @@ OPTIONS
-r | -revert
reverse operation: convert (or patch) hexdump into binary. If
not writing to stdout, xxd writes into its output file without
truncating it. Use the combination -r -p to read plain hexadeci-
mal dumps without line number information and without a particu-
truncating it. Use the combination -r -p to read plain hexadeci
mal dumps without line number information and without a particu
lar column layout. Additional Whitespace and line-breaks are
allowed anywhere.
@ -101,7 +109,7 @@ OPTIONS
CAVEATS
xxd -r has some builtin magic while evaluating line number information.
If the output file is seekable, then the linenumbers at the start of
each hexdump line may be out of order, lines may be missing, or over-
each hexdump line may be out of order, lines may be missing, or over
lapping. In these cases xxd will lseek(2) to the next position. If the
output file is not seekable, only gaps are allowed, which will be
filled by null-bytes.
@ -112,8 +120,8 @@ CAVEATS
input line after reading enough columns of hexadecimal data (see option
-c). This also means, that changes to the printable ascii (or ebcdic)
columns are always ignored. Reverting a plain (or postscript) style
hexdump with xxd -r -p does not depend on the correct number of col-
umns. Here anything that looks like a pair of hex-digits is inter-
hexdump with xxd -r -p does not depend on the correct number of col
umns. Here anything that looks like a pair of hex-digits is inter
preted.
Note the difference between
@ -218,7 +226,6 @@ EXAMPLES
% stty < /dev/term/b -echo -opost -isig -icanon min 1
% echo -n foo > /dev/term/b
RETURN VALUES
The following error values are returned:
@ -256,7 +263,4 @@ AUTHOR
<tony@sctnugen.ppp.gu.edu.au> <T.Nugent@sct.gu.edu.au>
Small changes by Bram Moolenaar. Edited by Juergen Weigert.
Manual page for xxd August 1996 XXD(1)

View File

@ -1,7 +1,7 @@
" Vim support file to detect file types
"
" Maintainer: Bram Moolenaar <Bram@vim.org>
" Last Change: 2014 Dec 06
" Last Change: 2015 Jun 06
" Listen very carefully, I will say this only once
if exists("did_load_filetypes")
@ -499,7 +499,7 @@ au BufNewFile,BufRead *.prg
\ endif
" Clojure
au BufNewFile,BufRead *.clj,*.cljs setf clojure
au BufNewFile,BufRead *.clj,*.cljs,*.cljx,*.cljc setf clojure
" Cmake
au BufNewFile,BufRead CMakeLists.txt,*.cmake,*.cmake.in setf cmake
@ -776,10 +776,9 @@ au BufNewFile,BufRead *.mo,*.gdmo setf gdmo
au BufNewFile,BufRead *.ged,lltxxxxx.txt setf gedcom
" Git
au BufNewFile,BufRead *.git/COMMIT_EDITMSG setf gitcommit
au BufNewFile,BufRead *.git/MERGE_MSG setf gitcommit
au BufNewFile,BufRead COMMIT_EDITMSG setf gitcommit
au BufNewFile,BufRead MERGE_MSG setf gitcommit
au BufNewFile,BufRead *.git/config,.gitconfig,.gitmodules setf gitconfig
au BufNewFile,BufRead *.git/modules/*/COMMIT_EDITMSG setf gitcommit
au BufNewFile,BufRead *.git/modules/*/config setf gitconfig
au BufNewFile,BufRead */.config/git/config setf gitconfig
if !empty($XDG_CONFIG_HOME)
@ -1052,6 +1051,9 @@ au BufNewFile,BufRead *.ldif setf ldif
" Ld loader
au BufNewFile,BufRead *.ld setf ld
" Less
au BufNewFile,BufRead *.less setf less
" Lex
au BufNewFile,BufRead *.lex,*.l,*.lxx,*.l++ setf lex
@ -1264,8 +1266,8 @@ au BufNewFile,BufRead */etc/modules.conf,*/etc/modules,*/etc/conf.modules setf m
" Mplayer config
au BufNewFile,BufRead mplayer.conf,*/.mplayer/config setf mplayerconf
" Moterola S record
au BufNewFile,BufRead *.s19,*.s28,*.s37 setf srec
" Motorola S record
au BufNewFile,BufRead *.s19,*.s28,*.s37,*.mot,*.srec setf srec
" Mrxvtrc
au BufNewFile,BufRead mrxvtrc,.mrxvtrc setf mrxvtrc
@ -1292,7 +1294,7 @@ au BufNewFile,BufRead *.mush setf mush
au BufNewFile,BufRead Mutt{ng,}rc setf muttrc
" Nano
au BufNewFile,BufRead */etc/nanorc,.nanorc setf nanorc
au BufNewFile,BufRead */etc/nanorc,*.nanorc setf nanorc
" Nastran input/DMAP
"au BufNewFile,BufRead *.dat setf nastran
@ -2026,6 +2028,10 @@ func! s:FTRules()
setf conf " Better than hog
return
endif
if path =~ '^/\(etc\|usr/share\)/polkit-1/rules\.d'
setf javascript
return
endif
try
let config_lines = readfile('/etc/udev/udev.conf')
catch /^Vim\%((\a\+)\)\=:E484/
@ -2163,6 +2169,9 @@ au BufNewFile,BufRead *.tli setf tli
" Telix Salt
au BufNewFile,BufRead *.slt setf tsalt
" Tera Term Language
au BufRead,BufNewFile *.ttl setf teraterm
" Terminfo
au BufNewFile,BufRead *.ti setf terminfo

View File

@ -2,7 +2,7 @@
" Language: J
" Maintainer: David Bürgin <676c7473@gmail.com>
" URL: https://github.com/glts/vim-j
" Last Change: 2014-04-05
" Last Change: 2015-03-27
if exists('b:did_ftplugin')
finish
@ -16,39 +16,38 @@ setlocal iskeyword=48-57,A-Z,_,a-z
setlocal comments=:NB.
setlocal commentstring=NB.\ %s
setlocal formatoptions-=t
setlocal shiftwidth=2 softtabstop=2 expandtab
setlocal matchpairs=(:)
let b:undo_ftplugin = 'setlocal matchpairs< expandtab< softtabstop< shiftwidth< formatoptions< commentstring< comments< iskeyword<'
let b:undo_ftplugin = 'setlocal matchpairs< formatoptions< commentstring< comments< iskeyword<'
" Section movement with ]] ][ [[ []. The start/end patterns below are amended
" inside the function in order to avoid matching on the current cursor line.
let s:sectionstart = '.\{-}\<\%([0-4]\|13\|noun\|adverb\|conjunction\|verb\|monad\|dyad\)\s\+\%(:\s*0\|def\s\+0\|define\)\>.*'
let s:sectionstart = '\%(\s*Note\|.\{-}\<\%([0-4]\|13\|noun\|adverb\|conjunction\|verb\|monad\|dyad\)\s\+\%(:\s*0\|def\s\+0\|define\)\)\>.*'
let s:sectionend = '\s*)\s*'
function! s:SearchSection(end, backwards, visualmode) abort
if a:visualmode !=# ''
normal! gv
endif
let flags = a:backwards ? 'bsW' : 'sW'
let l:flags = a:backwards ? 'bsW' : 'sW'
if a:end
call search('^' . s:sectionend . (a:backwards ? '\n\_.\{-}\%#' : '$'), flags)
call search('^' . s:sectionend . (a:backwards ? '\n\_.\{-}\%#' : '$'), l:flags)
else
call search('^' . s:sectionstart . (a:backwards ? '\n\_.\{-}\%#' : '$'), flags)
call search('^' . s:sectionstart . (a:backwards ? '\n\_.\{-}\%#' : '$'), l:flags)
endif
endfunction
noremap <script> <buffer> <silent> ]] :<C-U>call <SID>SearchSection(0, 0, '')<CR>
xnoremap <script> <buffer> <silent> ]] :<C-U>call <SID>SearchSection(0, 0, visualmode())<CR>
noremap <buffer> <silent> ]] :<C-U>call <SID>SearchSection(0, 0, '')<CR>
xnoremap <buffer> <silent> ]] :<C-U>call <SID>SearchSection(0, 0, visualmode())<CR>
sunmap <buffer> ]]
noremap <script> <buffer> <silent> ][ :<C-U>call <SID>SearchSection(1, 0, '')<CR>
xnoremap <script> <buffer> <silent> ][ :<C-U>call <SID>SearchSection(1, 0, visualmode())<CR>
noremap <buffer> <silent> ][ :<C-U>call <SID>SearchSection(1, 0, '')<CR>
xnoremap <buffer> <silent> ][ :<C-U>call <SID>SearchSection(1, 0, visualmode())<CR>
sunmap <buffer> ][
noremap <script> <buffer> <silent> [[ :<C-U>call <SID>SearchSection(0, 1, '')<CR>
xnoremap <script> <buffer> <silent> [[ :<C-U>call <SID>SearchSection(0, 1, visualmode())<CR>
noremap <buffer> <silent> [[ :<C-U>call <SID>SearchSection(0, 1, '')<CR>
xnoremap <buffer> <silent> [[ :<C-U>call <SID>SearchSection(0, 1, visualmode())<CR>
sunmap <buffer> [[
noremap <script> <buffer> <silent> [] :<C-U>call <SID>SearchSection(1, 1, '')<CR>
xnoremap <script> <buffer> <silent> [] :<C-U>call <SID>SearchSection(1, 1, visualmode())<CR>
noremap <buffer> <silent> [] :<C-U>call <SID>SearchSection(1, 1, '')<CR>
xnoremap <buffer> <silent> [] :<C-U>call <SID>SearchSection(1, 1, visualmode())<CR>
sunmap <buffer> []
let b:undo_ftplugin .= ' | silent! execute "unmap <buffer> ]]"'
@ -66,7 +65,7 @@ endif
" Enhanced "%" matching (see ":help matchit")
if exists('loaded_matchit') && !exists('b:match_words')
let b:match_ignorecase = 0
let b:match_words = '^.\{-}\<\%([0-4]\|13\|noun\|adverb\|conjunction\|verb\|monad\|dyad\)\s\+\%(\:\s*0\|def\s\+0\|define\)\>:^\s*\:\s*$:^\s*)\s*$'
let b:match_words = '^\%(\s*Note\|.\{-}\<\%([0-4]\|13\|noun\|adverb\|conjunction\|verb\|monad\|dyad\)\s\+\%(\:\s*0\|def\s\+0\|define\)\)\>:^\s*\:\s*$:^\s*)\s*$'
\ . ',\<\%(for\%(_\a\k*\)\=\|if\|select\|try\|whil\%(e\|st\)\)\.:\<\%(case\|catch[dt]\=\|else\%(if\)\=\|fcase\)\.:\<end\.'
let b:undo_ftplugin .= ' | unlet! b:match_ignorecase b:match_words'
endif

View File

@ -1,6 +1,10 @@
" Vim filetype plugin file
" Maintainer: Nikolai Weibull <now@bitwi.se>
" Latest Revision: 2008-07-09
" Vim syntax file
" Maintainer: Christian Brabandt <cb@256bit.org>
" Previous Maintainer: Nikolai Weibull <now@bitwi.se>
" Latest Revision: 2015-05-29
" License: Vim (see :h license)
" Repository: https://github.com/chrisbra/vim-kconfig
if exists("b:did_ftplugin")
finish
@ -14,5 +18,10 @@ let b:undo_ftplugin = "setl com< cms< fo<"
setlocal comments=:# commentstring=#\ %s formatoptions-=t formatoptions+=croql
" For matchit.vim
if exists("loaded_matchit")
let b:match_words = '^\<menu\>:\<endmenu\>,^\<if\>:\<endif\>,^\<choice\>:\<endchoice\>'
endif
let &cpo = s:cpo_save
unlet s:cpo_save

20
runtime/ftplugin/less.vim Normal file
View File

@ -0,0 +1,20 @@
" Vim filetype plugin
" Language: less
" Maintainer: Alessandro Vioni <jenoma@gmail.com>
" URL: https://github.com/genoma/vim-less
" Last Change: 2014 November 24
" Only do this when not done yet for this buffer
if exists("b:did_ftplugin")
finish
endif
let b:did_ftplugin = 1
let b:undo_ftplugin = "setl cms< def< inc< inex< ofu< sua<"
setlocal formatoptions-=t formatoptions+=croql
setlocal comments=:// commentstring=//\ %s
setlocal omnifunc=csscomplete#CompleteCSS
setlocal suffixesadd=.less

View File

@ -1,7 +1,7 @@
" Vim filetype plugin file
" Language: man
" Maintainer: SungHyun Nam <goweol@gmail.com>
" Last Change: 2014 Nov 12
" Last Change: 2014 Dec 29
" To make the ":Man" command available before editing a manual page, source
" this script from your startup vimrc file.
@ -159,10 +159,10 @@ func <SID>GetPage(...)
silent exec "r!/usr/bin/man ".s:GetCmdArg(sect, page)." | col -b"
" Remove blank lines from top and bottom.
while getline(1) =~ '^\s*$'
silent norm ggdd
silent keepj norm ggdd
endwhile
while getline('$') =~ '^\s*$'
silent norm Gdd
silent keepj norm Gdd
endwhile
1
setl ft=man nomod

View File

@ -1,7 +1,10 @@
" Vim filetype plugin file
" Language: matlab
" Maintainer: Jake Wasserman <jwasserman at gmail dot com>
" Last Changed: 2006 Jan 12
" Last Changed: 2014 Dec 30
" Contributors:
" Charles Campbell
if exists("b:did_ftplugin")
finish
@ -12,10 +15,11 @@ let s:save_cpo = &cpo
set cpo-=C
if exists("loaded_matchit")
let s:conditionalEnd = '\(([^()]*\)\@!\<end\>\([^()]*)\)\@!'
let b:match_words = '\<if\>\|\<while\>\|\<for\>\|\<switch\>:' .
\ s:conditionalEnd . ',\<if\>:\<elseif\>:\<else\>:' .
\ s:conditionalEnd
let s:conditionalEnd = '\%(([^()]*\)\@!\<end\>\%([^()]*)\)\@!'
let b:match_words=
\ '\<\%(if\|switch\|for\|while\)\>:\<\%(elseif\|case\|break\|continue\|else\|otherwise\)\>:'.s:conditionalEnd.','.
\ '\<function\>:\<return\>:\<endfunction\>'
unlet s:conditionalEnd
endif
setlocal suffixesadd=.m

View File

@ -2,7 +2,7 @@
" Filename: spec.vim
" Maintainer: Igor Gnatenko i.gnatenko.brain@gmail.com
" Former Maintainer: Gustavo Niemeyer <niemeyer@conectiva.com> (until March 2014)
" Last Change: Sun Mar 2 11:24 MSK 2014 Igor Gnatenko
" Last Change: Mon Jun 01 21:15 MSK 2015 Igor Gnatenko
if exists("b:did_ftplugin")
finish
@ -18,13 +18,40 @@ if !exists("no_plugin_maps") && !exists("no_spec_maps")
endif
endif
noremap <buffer> <unique> <script> <Plug>SpecChangelog :call <SID>SpecChangelog("")<CR>
if !hasmapto("call <SID>SpecChangelog(\"\")<CR>")
noremap <buffer> <unique> <script> <Plug>SpecChangelog :call <SID>SpecChangelog("")<CR>
endif
if !exists("*s:GetRelVer")
function! s:GetRelVer()
if has('python')
python << PYEND
import sys, datetime, shutil, tempfile
import vim
try:
import rpm
except ImportError:
pass
else:
specfile = vim.current.buffer.name
if specfile:
spec = rpm.spec(specfile)
headers = spec.packages[0].header
version = headers['Version']
release = ".".join(headers['Release'].split(".")[:-1])
vim.command("let ver = " + version)
vim.command("let rel = " + release)
PYEND
endif
endfunction
endif
if !exists("*s:SpecChangelog")
function s:SpecChangelog(format)
if strlen(a:format) == 0
if !exists("g:spec_chglog_format")
let email = input("Email address: ")
let email = input("Name <email address>: ")
let g:spec_chglog_format = "%a %b %d %Y " . l:email
echo "\r"
endif
@ -69,6 +96,9 @@ if !exists("*s:SpecChangelog")
else
let include_release_info = 0
endif
call s:GetRelVer()
if (chgline == -1)
let option = confirm("Can't find %changelog. Create one? ","&End of file\n&Here\n&Cancel",3)
if (option == 1)
@ -83,7 +113,7 @@ if !exists("*s:SpecChangelog")
endif
endif
if (chgline != -1)
let parsed_format = "* ".strftime(format)
let parsed_format = "* ".strftime(format)." - ".ver."-".rel
let release_info = "+ ".name."-".ver."-".rel
let wrong_format = 0
let wrong_release = 0

View File

@ -1,7 +1,10 @@
" Vim filetype plugin file
" Language: Zsh shell script
" Maintainer: Nikolai Weibull <now@bitwi.se>
" Latest Revision: 2011-01-23
" Language: Zsh shell script
" Maintainer: Christian Brabandt <cb@256bit.org>
" Previous Maintainer: Nikolai Weibull <now@bitwi.se>
" Latest Revision: 2015-05-29
" License: Vim (see :h license)
" Repository: https://github.com/chrisbra/vim-zsh
if exists("b:did_ftplugin")
finish

View File

@ -1,9 +1,11 @@
" Vim indent file
" Language: Fortran95 (and Fortran90, Fortran77, F and elf90)
" Version: 0.40
" Last Change: 2011 Dec. 28
" Maintainer: Ajit J. Thakkar <ajit@unb.ca>; <http://www.unb.ca/chem/ajit/>
" Language: Fortran 2008 (and earlier versions: 2003, 95, 90, and 77)
" Version: 0.41
" Last Change: 2015 Jan. 15
" Maintainer: Ajit J. Thakkar <ajit@unb.ca>; <http://www2.unb.ca/~ajit/>
" Usage: Do :help fortran-indent from Vim
" Credits:
" Useful suggestions were made by: Albert Oliver Serra.
" Only load this indent file when no other was loaded.
if exists("b:did_indent")
@ -36,8 +38,8 @@ if !exists("b:fortran_fixed_source")
else
" f90 and f95 allow both fixed and free source form
" assume fixed source form unless signs of free source form
" are detected in the first five columns of the first 250 lines
" Detection becomes more accurate and time-consuming if more lines
" are detected in the first five columns of the first s:lmax lines.
" Detection becomes more accurate and more time-consuming if more lines
" are checked. Increase the limit below if you keep lots of comments at
" the very top of each file and you have a fast computer
let s:lmax = 500
@ -129,7 +131,7 @@ function FortranGetIndent(lnum)
if getline(v:lnum) =~? '^\s*\(\d\+\s\)\=\s*'
\. '\(else\|else\s*if\|else\s*where\|case\|'
\. 'end\s*\(if\|where\|select\|interface\|'
\. 'type\|forall\|associate\|enum\)\)\>'
\. 'type\|forall\|associate\|enum\|block\)\)\>'
let ind = ind - &sw
" Fix indent for case statement immediately after select
if prevstat =~? '\<select\s\+\(case\|type\)\>'
@ -141,8 +143,11 @@ function FortranGetIndent(lnum)
if prevstat =~ '&\s*$' && prev2stat !~ '&\s*$'
let ind = ind + &sw
endif
if prevstat =~ '&\s*$' && prevstat =~ '\<else\s*if\>'
let ind = ind - &sw
endif
"Line after last continuation line
if prevstat !~ '&\s*$' && prev2stat =~ '&\s*$'
if prevstat !~ '&\s*$' && prev2stat =~ '&\s*$' && prevstat !~? '\<then\>'
let ind = ind - &sw
endif

View File

@ -2,7 +2,7 @@
" Header: "{{{
" Maintainer: Bram Moolenaar
" Original Author: Andy Wokula <anwoku@yahoo.de>
" Last Change: 2014 Aug 23
" Last Change: 2015 Jun 12
" Version: 1.0
" Description: HTML indent script with cached state for faster indenting on a
" range of lines.
@ -94,7 +94,7 @@ func! HtmlIndent_CheckUserSettings()
let autotags = g:html_indent_autotags
endif
let b:hi_removed_tags = {}
if autotags
if len(autotags) > 0
call s:RemoveITags(b:hi_removed_tags, split(autotags, ","))
endif
@ -245,6 +245,10 @@ call s:AddITags(s:indent_tags, [
\ 'header', 'group', 'keygen', 'mark', 'math', 'meter', 'nav', 'output',
\ 'progress', 'ruby', 'section', 'svg', 'texture', 'time', 'video',
\ 'wbr', 'text'])
" Tags added for web components:
call s:AddITags(s:indent_tags, [
\ 'content', 'shadow', 'template'])
"}}}
" Add Block Tags: these contain alien content
@ -287,7 +291,7 @@ func! s:CountITags(text)
let s:nextrel = 0 " relative indent steps for next line [unit &sw]:
let s:block = 0 " assume starting outside of a block
let s:countonly = 1 " don't change state
call substitute(a:text, '<\zs/\=\w\+\>\|<!--\|-->', '\=s:CheckTag(submatch(0))', 'g')
call substitute(a:text, '<\zs/\=\w\+\(-\w\+\)*\>\|<!--\|-->', '\=s:CheckTag(submatch(0))', 'g')
let s:countonly = 0
endfunc "}}}
@ -299,7 +303,7 @@ func! s:CountTagsAndState(text)
let s:nextrel = 0 " relative indent steps for next line [unit &sw]:
let s:block = b:hi_newstate.block
let tmp = substitute(a:text, '<\zs/\=\w\+\>\|<!--\|-->', '\=s:CheckTag(submatch(0))', 'g')
let tmp = substitute(a:text, '<\zs/\=\w\+\(-\w\+\)*\>\|<!--\|-->', '\=s:CheckTag(submatch(0))', 'g')
if s:block == 3
let b:hi_newstate.scripttype = s:GetScriptType(matchstr(tmp, '\C.*<SCRIPT\>\zs[^>]*'))
endif
@ -311,6 +315,9 @@ func! s:CheckTag(itag)
"{{{
" Returns an empty string or "SCRIPT".
" a:itag can be "tag" or "/tag" or "<!--" or "-->"
if (s:CheckCustomTag(a:itag))
return ""
endif
let ind = s:get_tag(a:itag)
if ind == -1
" closing tag
@ -365,6 +372,36 @@ func! s:CheckBlockTag(blocktag, ind)
return ""
endfunc "}}}
" Used by s:CheckTag().
func! s:CheckCustomTag(ctag)
"{{{
" Returns 1 if ctag is the tag for a custom element, 0 otherwise.
" a:ctag can be "tag" or "/tag" or "<!--" or "-->"
let pattern = '\%\(\w\+-\)\+\w\+'
if match(a:ctag, pattern) == -1
return 0
endif
if matchstr(a:ctag, '\/\ze.\+') == "/"
" closing tag
if s:block != 0
" ignore ctag within a block
return 1
endif
if s:nextrel == 0
let s:curind -= 1
else
let s:nextrel -= 1
endif
else
" opening tag
if s:block != 0
return 1
endif
let s:nextrel += 1
endif
return 1
endfunc "}}}
" Return the <script> type: either "javascript" or ""
func! s:GetScriptType(str)
"{{{
@ -883,7 +920,7 @@ endfunc "}}}
" THE MAIN INDENT FUNCTION. Return the amount of indent for v:lnum.
func! HtmlIndent()
"{{{
if prevnonblank(v:lnum - 1) <= 1
if prevnonblank(v:lnum - 1) < 1
" First non-blank line has no indent.
return 0
endif

View File

@ -2,7 +2,7 @@
" Language: J
" Maintainer: David Bürgin <676c7473@gmail.com>
" URL: https://github.com/glts/vim-j
" Last Change: 2014-04-05
" Last Change: 2015-01-11
if exists('b:did_indent')
finish
@ -26,25 +26,25 @@ if !exists('g:j_indent_definitions')
endif
function GetJIndent() abort
let prevlnum = prevnonblank(v:lnum-1)
if prevlnum == 0
let l:prevlnum = prevnonblank(v:lnum - 1)
if l:prevlnum == 0
return 0
endif
let indent = indent(prevlnum)
let prevline = getline(prevlnum)
if prevline =~# '^\s*\%(case\|catch[dt]\=\|do\|else\%(if\)\=\|fcase\|for\%(_\a\k*\)\=\|if\|select\|try\|whil\%(e\|st\)\)\.\%(\%(\<end\.\)\@!.\)*$'
let l:indent = indent(l:prevlnum)
let l:prevline = getline(l:prevlnum)
if l:prevline =~# '^\s*\%(case\|catch[dt]\=\|do\|else\%(if\)\=\|fcase\|for\%(_\a\k*\)\=\|if\|select\|try\|whil\%(e\|st\)\)\.\%(\%(\<end\.\)\@!.\)*$'
" Increase indentation after an initial control word that starts or
" continues a block and is not terminated by "end."
let indent += shiftwidth()
elseif g:j_indent_definitions && (prevline =~# '\<\%([1-4]\|13\|adverb\|conjunction\|verb\|monad\|dyad\)\s\+\%(:\s*0\|def\s\+0\|define\)\>' || prevline =~# '^\s*:\s*$')
let l:indent += shiftwidth()
elseif g:j_indent_definitions && (l:prevline =~# '\<\%([1-4]\|13\|adverb\|conjunction\|verb\|monad\|dyad\)\s\+\%(:\s*0\|def\s\+0\|define\)\>' || l:prevline =~# '^\s*:\s*$')
" Increase indentation in explicit definitions of adverbs, conjunctions,
" and verbs
let indent += shiftwidth()
let l:indent += shiftwidth()
endif
" Decrease indentation in lines that start with either control words that
" continue or end a block, or the special items ")" and ":"
if getline(v:lnum) =~# '^\s*\%()\|:\|\%(case\|catch[dt]\=\|do\|else\%(if\)\=\|end\|fcase\)\.\)'
let indent -= shiftwidth()
let l:indent -= shiftwidth()
endif
return indent
return l:indent
endfunction

View File

@ -1,7 +1,7 @@
" Vim indent file
" Language: Javascript
" Maintainer: None! Wanna improve this?
" Last Change: 2007 Jan 22
" Maintainer: Going to be Darrick Wiebe
" Last Change: 2015 Jun 09
" Only load this indent file when no other was loaded.
if exists("b:did_indent")
@ -12,5 +12,7 @@ let b:did_indent = 1
" C indenting is not too bad.
setlocal cindent
setlocal cinoptions+=j1,J1
setlocal cinkeys-=0#
setlocal cinkeys+=0]
let b:undo_indent = "setl cin<"

13
runtime/indent/less.vim Normal file
View File

@ -0,0 +1,13 @@
" Vim indent file
" Language: less
" Maintainer: Alessandro Vioni <jenoma@gmail.com>
" URL: https://github.com/genoma/vim-less
" Last Change: 2014 November 24
if exists("b:did_indent")
finish
endif
runtime! indent/css.vim
" vim:set sw=2:

View File

@ -1,12 +1,12 @@
" Vim indent file
" Language: R
" Author: Jakson Alves de Aquino <jalvesaq@gmail.com>
" Last Change: Fri Feb 15, 2013 08:11PM
" Last Change: Thu Mar 26, 2015 05:36PM
" Only load this indent file when no other was loaded.
if exists("b:did_indent")
finish
finish
endif
let b:did_indent = 1
@ -15,478 +15,501 @@ setlocal indentexpr=GetRIndent()
" Only define the function once.
if exists("*GetRIndent")
finish
finish
endif
" Options to make the indentation more similar to Emacs/ESS:
if !exists("g:r_indent_align_args")
let g:r_indent_align_args = 1
let g:r_indent_align_args = 1
endif
if !exists("g:r_indent_ess_comments")
let g:r_indent_ess_comments = 0
let g:r_indent_ess_comments = 0
endif
if !exists("g:r_indent_comment_column")
let g:r_indent_comment_column = 40
let g:r_indent_comment_column = 40
endif
if ! exists("g:r_indent_ess_compatible")
let g:r_indent_ess_compatible = 0
let g:r_indent_ess_compatible = 0
endif
if ! exists("g:r_indent_op_pattern")
let g:r_indent_op_pattern = '\(+\|-\|\*\|/\|=\|\~\|%\)$'
endif
function s:RDelete_quotes(line)
let i = 0
let j = 0
let line1 = ""
let llen = strlen(a:line)
while i < llen
if a:line[i] == '"'
let i += 1
let line1 = line1 . 's'
while !(a:line[i] == '"' && ((i > 1 && a:line[i-1] == '\' && a:line[i-2] == '\') || a:line[i-1] != '\')) && i < llen
let i += 1
endwhile
if a:line[i] == '"'
let i += 1
endif
else
if a:line[i] == "'"
let i += 1
let line1 = line1 . 's'
while !(a:line[i] == "'" && ((i > 1 && a:line[i-1] == '\' && a:line[i-2] == '\') || a:line[i-1] != '\')) && i < llen
let i += 1
endwhile
if a:line[i] == "'"
let i += 1
endif
else
if a:line[i] == "`"
let i += 1
let line1 = line1 . 's'
while a:line[i] != "`" && i < llen
let i += 1
endwhile
if a:line[i] == "`"
let i += 1
endif
endif
endif
endif
if i == llen
break
endif
let line1 = line1 . a:line[i]
let j += 1
let i = 0
let j = 0
let line1 = ""
let llen = strlen(a:line)
while i < llen
if a:line[i] == '"'
let i += 1
let line1 = line1 . 's'
while !(a:line[i] == '"' && ((i > 1 && a:line[i-1] == '\' && a:line[i-2] == '\') || a:line[i-1] != '\')) && i < llen
let i += 1
endwhile
return line1
endwhile
if a:line[i] == '"'
let i += 1
endif
else
if a:line[i] == "'"
let i += 1
let line1 = line1 . 's'
while !(a:line[i] == "'" && ((i > 1 && a:line[i-1] == '\' && a:line[i-2] == '\') || a:line[i-1] != '\')) && i < llen
let i += 1
endwhile
if a:line[i] == "'"
let i += 1
endif
else
if a:line[i] == "`"
let i += 1
let line1 = line1 . 's'
while a:line[i] != "`" && i < llen
let i += 1
endwhile
if a:line[i] == "`"
let i += 1
endif
endif
endif
endif
if i == llen
break
endif
let line1 = line1 . a:line[i]
let j += 1
let i += 1
endwhile
return line1
endfunction
" Convert foo(bar()) int foo()
function s:RDelete_parens(line)
if s:Get_paren_balance(a:line, "(", ")") != 0
return a:line
endif
let i = 0
let j = 0
let line1 = ""
let llen = strlen(a:line)
while i < llen
let line1 = line1 . a:line[i]
if a:line[i] == '('
let nop = 1
while nop > 0 && i < llen
let i += 1
if a:line[i] == ')'
let nop -= 1
else
if a:line[i] == '('
let nop += 1
endif
endif
endwhile
let line1 = line1 . a:line[i]
endif
if s:Get_paren_balance(a:line, "(", ")") != 0
return a:line
endif
let i = 0
let j = 0
let line1 = ""
let llen = strlen(a:line)
while i < llen
let line1 = line1 . a:line[i]
if a:line[i] == '('
let nop = 1
while nop > 0 && i < llen
let i += 1
endwhile
return line1
if a:line[i] == ')'
let nop -= 1
else
if a:line[i] == '('
let nop += 1
endif
endif
endwhile
let line1 = line1 . a:line[i]
endif
let i += 1
endwhile
return line1
endfunction
function! s:Get_paren_balance(line, o, c)
let line2 = substitute(a:line, a:o, "", "g")
let openp = strlen(a:line) - strlen(line2)
let line3 = substitute(line2, a:c, "", "g")
let closep = strlen(line2) - strlen(line3)
return openp - closep
let line2 = substitute(a:line, a:o, "", "g")
let openp = strlen(a:line) - strlen(line2)
let line3 = substitute(line2, a:c, "", "g")
let closep = strlen(line2) - strlen(line3)
return openp - closep
endfunction
function! s:Get_matching_brace(linenr, o, c, delbrace)
let line = SanitizeRLine(getline(a:linenr))
if a:delbrace == 1
let line = substitute(line, '{$', "", "")
endif
let pb = s:Get_paren_balance(line, a:o, a:c)
let i = a:linenr
while pb != 0 && i > 1
let i -= 1
let pb += s:Get_paren_balance(SanitizeRLine(getline(i)), a:o, a:c)
endwhile
return i
let line = SanitizeRLine(getline(a:linenr))
if a:delbrace == 1
let line = substitute(line, '{$', "", "")
endif
let pb = s:Get_paren_balance(line, a:o, a:c)
let i = a:linenr
while pb != 0 && i > 1
let i -= 1
let pb += s:Get_paren_balance(SanitizeRLine(getline(i)), a:o, a:c)
endwhile
return i
endfunction
" This function is buggy because there 'if's without 'else'
" It must be rewritten relying more on indentation
function! s:Get_matching_if(linenr, delif)
" let filenm = expand("%")
" call writefile([filenm], "/tmp/matching_if_" . a:linenr)
let line = SanitizeRLine(getline(a:linenr))
if a:delif
let line = substitute(line, "if", "", "g")
endif
let elsenr = 0
let i = a:linenr
let ifhere = 0
while i > 0
let line2 = substitute(line, '\<else\>', "xxx", "g")
let elsenr += strlen(line) - strlen(line2)
if line =~ '.*\s*if\s*()' || line =~ '.*\s*if\s*()'
let elsenr -= 1
if elsenr == 0
let ifhere = i
break
endif
endif
let i -= 1
let line = SanitizeRLine(getline(i))
endwhile
if ifhere
return ifhere
else
return a:linenr
let line = SanitizeRLine(getline(a:linenr))
if a:delif
let line = substitute(line, "if", "", "g")
endif
let elsenr = 0
let i = a:linenr
let ifhere = 0
while i > 0
let line2 = substitute(line, '\<else\>', "xxx", "g")
let elsenr += strlen(line) - strlen(line2)
if line =~ '.*\s*if\s*()' || line =~ '.*\s*if\s*()'
let elsenr -= 1
if elsenr == 0
let ifhere = i
break
endif
endif
let i -= 1
let line = SanitizeRLine(getline(i))
endwhile
if ifhere
return ifhere
else
return a:linenr
endif
endfunction
function! s:Get_last_paren_idx(line, o, c, pb)
let blc = a:pb
let line = substitute(a:line, '\t', s:curtabstop, "g")
let theidx = -1
let llen = strlen(line)
let idx = 0
while idx < llen
if line[idx] == a:o
let blc -= 1
if blc == 0
let theidx = idx
endif
else
if line[idx] == a:c
let blc += 1
endif
endif
let idx += 1
endwhile
return theidx + 1
let blc = a:pb
let line = substitute(a:line, '\t', s:curtabstop, "g")
let theidx = -1
let llen = strlen(line)
let idx = 0
while idx < llen
if line[idx] == a:o
let blc -= 1
if blc == 0
let theidx = idx
endif
else
if line[idx] == a:c
let blc += 1
endif
endif
let idx += 1
endwhile
return theidx + 1
endfunction
" Get previous relevant line. Search back until getting a line that isn't
" comment or blank
function s:Get_prev_line(lineno)
let lnum = a:lineno - 1
let lnum = a:lineno - 1
let data = getline( lnum )
while lnum > 0 && (data =~ '^\s*#' || data =~ '^\s*$')
let lnum = lnum - 1
let data = getline( lnum )
while lnum > 0 && (data =~ '^\s*#' || data =~ '^\s*$')
let lnum = lnum - 1
let data = getline( lnum )
endwhile
return lnum
endwhile
return lnum
endfunction
" This function is also used by r-plugin/common_global.vim
" Delete from '#' to the end of the line, unless the '#' is inside a string.
function SanitizeRLine(line)
let newline = s:RDelete_quotes(a:line)
let newline = s:RDelete_parens(newline)
let newline = substitute(newline, '#.*', "", "")
let newline = substitute(newline, '\s*$', "", "")
return newline
let newline = s:RDelete_quotes(a:line)
let newline = s:RDelete_parens(newline)
let newline = substitute(newline, '#.*', "", "")
let newline = substitute(newline, '\s*$', "", "")
if &filetype == "rhelp" && newline =~ '^\\method{.*}{.*}(.*'
let newline = substitute(newline, '^\\method{\(.*\)}{.*}', '\1', "")
endif
return newline
endfunction
function GetRIndent()
let clnum = line(".") " current line
let clnum = line(".") " current line
let cline = getline(clnum)
if cline =~ '^\s*#'
if g:r_indent_ess_comments == 1
if cline =~ '^\s*###'
return 0
endif
if cline !~ '^\s*##'
return g:r_indent_comment_column
endif
endif
endif
let cline = SanitizeRLine(cline)
if cline =~ '^\s*}' || cline =~ '^\s*}\s*)$'
let indline = s:Get_matching_brace(clnum, '{', '}', 1)
if indline > 0 && indline != clnum
let iline = SanitizeRLine(getline(indline))
if s:Get_paren_balance(iline, "(", ")") == 0 || iline =~ '(\s*{$'
return indent(indline)
else
let indline = s:Get_matching_brace(indline, '(', ')', 1)
return indent(indline)
endif
endif
endif
" Find the first non blank line above the current line
let lnum = s:Get_prev_line(clnum)
" Hit the start of the file, use zero indent.
if lnum == 0
let cline = getline(clnum)
if cline =~ '^\s*#'
if g:r_indent_ess_comments == 1
if cline =~ '^\s*###'
return 0
endif
if cline !~ '^\s*##'
return g:r_indent_comment_column
endif
endif
endif
let line = SanitizeRLine(getline(lnum))
let cline = SanitizeRLine(cline)
if &filetype == "rhelp"
if cline =~ '^\\dontshow{' || cline =~ '^\\dontrun{' || cline =~ '^\\donttest{' || cline =~ '^\\testonly{'
return 0
endif
if line =~ '^\\examples{' || line =~ '^\\usage{' || line =~ '^\\dontshow{' || line =~ '^\\dontrun{' || line =~ '^\\donttest{' || line =~ '^\\testonly{'
return 0
endif
if line =~ '^\\method{.*}{.*}(.*'
let line = substitute(line, '^\\method{\(.*\)}{.*}', '\1', "")
endif
if cline =~ '^\s*}' || cline =~ '^\s*}\s*)$'
let indline = s:Get_matching_brace(clnum, '{', '}', 1)
if indline > 0 && indline != clnum
let iline = SanitizeRLine(getline(indline))
if s:Get_paren_balance(iline, "(", ")") == 0 || iline =~ '(\s*{$'
return indent(indline)
else
let indline = s:Get_matching_brace(indline, '(', ')', 1)
return indent(indline)
endif
endif
endif
if cline =~ '^\s*{'
if g:r_indent_ess_compatible && line =~ ')$'
let nlnum = lnum
let nline = line
while s:Get_paren_balance(nline, '(', ')') < 0
let nlnum = s:Get_prev_line(nlnum)
let nline = SanitizeRLine(getline(nlnum)) . nline
endwhile
if nline =~ '^\s*function\s*(' && indent(nlnum) == &sw
return 0
endif
endif
if s:Get_paren_balance(line, "(", ")") == 0
return indent(lnum)
endif
" Find the first non blank line above the current line
let lnum = s:Get_prev_line(clnum)
" Hit the start of the file, use zero indent.
if lnum == 0
return 0
endif
let line = SanitizeRLine(getline(lnum))
if &filetype == "rhelp"
if cline =~ '^\\dontshow{' || cline =~ '^\\dontrun{' || cline =~ '^\\donttest{' || cline =~ '^\\testonly{'
return 0
endif
" line is an incomplete command:
if line =~ '\<\(if\|while\|for\|function\)\s*()$' || line =~ '\<else$' || line =~ '<-$'
return indent(lnum) + &sw
if line =~ '^\\examples{' || line =~ '^\\usage{' || line =~ '^\\dontshow{' || line =~ '^\\dontrun{' || line =~ '^\\donttest{' || line =~ '^\\testonly{'
return 0
endif
endif
" Deal with () and []
if &filetype == "rnoweb" && line =~ "^<<.*>>="
return 0
endif
let pb = s:Get_paren_balance(line, '(', ')')
if cline =~ '^\s*{'
if g:r_indent_ess_compatible && line =~ ')$'
let nlnum = lnum
let nline = line
while s:Get_paren_balance(nline, '(', ')') < 0
let nlnum = s:Get_prev_line(nlnum)
let nline = SanitizeRLine(getline(nlnum)) . nline
endwhile
if nline =~ '^\s*function\s*(' && indent(nlnum) == &sw
return 0
endif
endif
if s:Get_paren_balance(line, "(", ")") == 0
return indent(lnum)
endif
endif
if line =~ '^\s*{$' || line =~ '(\s*{' || (pb == 0 && (line =~ '{$' || line =~ '(\s*{$'))
return indent(lnum) + &sw
" line is an incomplete command:
if line =~ '\<\(if\|while\|for\|function\)\s*()$' || line =~ '\<else$' || line =~ '<-$'
return indent(lnum) + &sw
endif
" Deal with () and []
let pb = s:Get_paren_balance(line, '(', ')')
if line =~ '^\s*{$' || line =~ '(\s*{' || (pb == 0 && (line =~ '{$' || line =~ '(\s*{$'))
return indent(lnum) + &sw
endif
let s:curtabstop = repeat(' ', &tabstop)
if g:r_indent_align_args == 1
if pb > 0 && line =~ '{$'
return s:Get_last_paren_idx(line, '(', ')', pb) + &sw
endif
let bb = s:Get_paren_balance(line, '[', ']')
let s:curtabstop = repeat(' ', &tabstop)
if g:r_indent_align_args == 1
if pb == 0 && bb == 0 && (line =~ '.*[,&|\-\*+<>]$' || cline =~ '^\s*[,&|\-\*+<>]')
return indent(lnum)
endif
if pb > 0
if &filetype == "rhelp"
let ind = s:Get_last_paren_idx(line, '(', ')', pb)
else
let ind = s:Get_last_paren_idx(getline(lnum), '(', ')', pb)
endif
return ind
endif
if pb < 0 && line =~ '.*[,&|\-\*+<>]$'
let lnum = s:Get_prev_line(lnum)
while pb < 1 && lnum > 0
let line = SanitizeRLine(getline(lnum))
let line = substitute(line, '\t', s:curtabstop, "g")
let ind = strlen(line)
while ind > 0
if line[ind] == ')'
let pb -= 1
else
if line[ind] == '('
let pb += 1
endif
endif
if pb == 1
return ind + 1
endif
let ind -= 1
endwhile
let lnum -= 1
endwhile
return 0
endif
if bb > 0
let ind = s:Get_last_paren_idx(getline(lnum), '[', ']', bb)
return ind
endif
if pb > 0
if &filetype == "rhelp"
let ind = s:Get_last_paren_idx(line, '(', ')', pb)
else
let ind = s:Get_last_paren_idx(getline(lnum), '(', ')', pb)
endif
return ind
endif
let post_block = 0
if line =~ '}$'
let lnum = s:Get_matching_brace(lnum, '{', '}', 0)
if pb < 0 && line =~ '.*[,&|\-\*+<>]$'
let lnum = s:Get_prev_line(lnum)
while pb < 1 && lnum > 0
let line = SanitizeRLine(getline(lnum))
if lnum > 0 && line =~ '^\s*{'
let lnum = s:Get_prev_line(lnum)
let line = SanitizeRLine(getline(lnum))
endif
let pb = s:Get_paren_balance(line, '(', ')')
let post_block = 1
endif
let post_fun = 0
if pb < 0 && line !~ ')\s*[,&|\-\*+<>]$'
let post_fun = 1
while pb < 0 && lnum > 0
let lnum -= 1
let linepiece = SanitizeRLine(getline(lnum))
let pb += s:Get_paren_balance(linepiece, "(", ")")
let line = linepiece . line
endwhile
if line =~ '{$' && post_block == 0
return indent(lnum) + &sw
endif
" Now we can do some tests again
if cline =~ '^\s*{'
return indent(lnum)
endif
if post_block == 0
let newl = SanitizeRLine(line)
if newl =~ '\<\(if\|while\|for\|function\)\s*()$' || newl =~ '\<else$' || newl =~ '<-$'
return indent(lnum) + &sw
let line = substitute(line, '\t', s:curtabstop, "g")
let ind = strlen(line)
while ind > 0
if line[ind] == ')'
let pb -= 1
else
if line[ind] == '('
let pb += 1
endif
endif
endif
if cline =~ '^\s*else'
if line =~ '<-\s*if\s*()'
return indent(lnum) + &sw
else
if line =~ '\<if\s*()'
return indent(lnum)
else
return indent(lnum) - &sw
endif
endif
endif
if bb < 0 && line =~ '.*]'
while bb < 0 && lnum > 0
let lnum -= 1
let linepiece = SanitizeRLine(getline(lnum))
let bb += s:Get_paren_balance(linepiece, "[", "]")
let line = linepiece . line
endif
if pb == 1
return ind + 1
endif
let ind -= 1
endwhile
let line = s:RDelete_parens(line)
let lnum -= 1
endwhile
return 0
endif
let plnum = s:Get_prev_line(lnum)
let ppost_else = 0
if plnum > 0
let pline = SanitizeRLine(getline(plnum))
let ppost_block = 0
if pline =~ '}$'
let ppost_block = 1
let plnum = s:Get_matching_brace(plnum, '{', '}', 0)
let pline = SanitizeRLine(getline(plnum))
if pline =~ '^\s*{$' && plnum > 0
let plnum = s:Get_prev_line(plnum)
let pline = SanitizeRLine(getline(plnum))
endif
endif
if pline =~ 'else$'
let ppost_else = 1
let plnum = s:Get_matching_if(plnum, 0)
let pline = SanitizeRLine(getline(plnum))
endif
if pline =~ '^\s*else\s*if\s*('
let pplnum = s:Get_prev_line(plnum)
let ppline = SanitizeRLine(getline(pplnum))
while ppline =~ '^\s*else\s*if\s*(' || ppline =~ '^\s*if\s*()\s*\S$'
let plnum = pplnum
let pline = ppline
let pplnum = s:Get_prev_line(plnum)
let ppline = SanitizeRLine(getline(pplnum))
endwhile
while ppline =~ '\<\(if\|while\|for\|function\)\s*()$' || ppline =~ '\<else$' || ppline =~ '<-$'
let plnum = pplnum
let pline = ppline
let pplnum = s:Get_prev_line(plnum)
let ppline = SanitizeRLine(getline(pplnum))
endwhile
endif
let ppb = s:Get_paren_balance(pline, '(', ')')
if ppb < 0 && (pline =~ ')\s*{$' || pline =~ ')$')
while ppb < 0 && plnum > 0
let plnum -= 1
let linepiece = SanitizeRLine(getline(plnum))
let ppb += s:Get_paren_balance(linepiece, "(", ")")
let pline = linepiece . pline
endwhile
let pline = s:RDelete_parens(pline)
endif
if bb > 0
let ind = s:Get_last_paren_idx(getline(lnum), '[', ']', bb)
return ind
endif
endif
let ind = indent(lnum)
let pind = indent(plnum)
if g:r_indent_align_args == 0 && pb != 0
let ind += pb * &sw
return ind
let post_block = 0
if line =~ '}$'
let lnum = s:Get_matching_brace(lnum, '{', '}', 0)
let line = SanitizeRLine(getline(lnum))
if lnum > 0 && line =~ '^\s*{'
let lnum = s:Get_prev_line(lnum)
let line = SanitizeRLine(getline(lnum))
endif
let pb = s:Get_paren_balance(line, '(', ')')
let post_block = 1
endif
if g:r_indent_align_args == 0 && bb != 0
let ind += bb * &sw
return ind
" Indent after operator pattern
let olnum = s:Get_prev_line(lnum)
let oline = getline(olnum)
if olnum > 0
if line =~ g:r_indent_op_pattern
if oline =~ g:r_indent_op_pattern
return indent(lnum)
else
return indent(lnum) + &sw
endif
else
if oline =~ g:r_indent_op_pattern
return indent(lnum) - &sw
endif
endif
endif
if ind == pind || (ind == (pind + &sw) && pline =~ '{$' && ppost_else == 0)
return ind
endif
let pline = getline(plnum)
let pbb = s:Get_paren_balance(pline, '[', ']')
while pind < ind && plnum > 0 && ppb == 0 && pbb == 0
let ind = pind
let plnum = s:Get_prev_line(plnum)
let pline = getline(plnum)
let ppb = s:Get_paren_balance(pline, '(', ')')
let pbb = s:Get_paren_balance(pline, '[', ']')
while pline =~ '^\s*else'
let plnum = s:Get_matching_if(plnum, 1)
let pline = getline(plnum)
let ppb = s:Get_paren_balance(pline, '(', ')')
let pbb = s:Get_paren_balance(pline, '[', ']')
endwhile
let pind = indent(plnum)
if ind == (pind + &sw) && pline =~ '{$'
return ind
endif
let post_fun = 0
if pb < 0 && line !~ ')\s*[,&|\-\*+<>]$'
let post_fun = 1
while pb < 0 && lnum > 0
let lnum -= 1
let linepiece = SanitizeRLine(getline(lnum))
let pb += s:Get_paren_balance(linepiece, "(", ")")
let line = linepiece . line
endwhile
if line =~ '{$' && post_block == 0
return indent(lnum) + &sw
endif
" Now we can do some tests again
if cline =~ '^\s*{'
return indent(lnum)
endif
if post_block == 0
let newl = SanitizeRLine(line)
if newl =~ '\<\(if\|while\|for\|function\)\s*()$' || newl =~ '\<else$' || newl =~ '<-$'
return indent(lnum) + &sw
endif
endif
endif
if cline =~ '^\s*else'
if line =~ '<-\s*if\s*()'
return indent(lnum) + &sw
else
if line =~ '\<if\s*()'
return indent(lnum)
else
return indent(lnum) - &sw
endif
endif
endif
let bb = s:Get_paren_balance(line, '[', ']')
if bb < 0 && line =~ '.*]'
while bb < 0 && lnum > 0
let lnum -= 1
let linepiece = SanitizeRLine(getline(lnum))
let bb += s:Get_paren_balance(linepiece, "[", "]")
let line = linepiece . line
endwhile
let line = s:RDelete_parens(line)
endif
let plnum = s:Get_prev_line(lnum)
let ppost_else = 0
if plnum > 0
let pline = SanitizeRLine(getline(plnum))
let ppost_block = 0
if pline =~ '}$'
let ppost_block = 1
let plnum = s:Get_matching_brace(plnum, '{', '}', 0)
let pline = SanitizeRLine(getline(plnum))
if pline =~ '^\s*{$' && plnum > 0
let plnum = s:Get_prev_line(plnum)
let pline = SanitizeRLine(getline(plnum))
endif
endif
if pline =~ 'else$'
let ppost_else = 1
let plnum = s:Get_matching_if(plnum, 0)
let pline = SanitizeRLine(getline(plnum))
endif
if pline =~ '^\s*else\s*if\s*('
let pplnum = s:Get_prev_line(plnum)
let ppline = SanitizeRLine(getline(pplnum))
while ppline =~ '^\s*else\s*if\s*(' || ppline =~ '^\s*if\s*()\s*\S$'
let plnum = pplnum
let pline = ppline
let pplnum = s:Get_prev_line(plnum)
let ppline = SanitizeRLine(getline(pplnum))
endwhile
while ppline =~ '\<\(if\|while\|for\|function\)\s*()$' || ppline =~ '\<else$' || ppline =~ '<-$'
let plnum = pplnum
let pline = ppline
let pplnum = s:Get_prev_line(plnum)
let ppline = SanitizeRLine(getline(pplnum))
endwhile
endif
let ppb = s:Get_paren_balance(pline, '(', ')')
if ppb < 0 && (pline =~ ')\s*{$' || pline =~ ')$')
while ppb < 0 && plnum > 0
let plnum -= 1
let linepiece = SanitizeRLine(getline(plnum))
let ppb += s:Get_paren_balance(linepiece, "(", ")")
let pline = linepiece . pline
endwhile
let pline = s:RDelete_parens(pline)
endif
endif
let ind = indent(lnum)
let pind = indent(plnum)
if g:r_indent_align_args == 0 && pb != 0
let ind += pb * &sw
return ind
endif
if g:r_indent_align_args == 0 && bb != 0
let ind += bb * &sw
return ind
endif
if ind == pind || (ind == (pind + &sw) && pline =~ '{$' && ppost_else == 0)
return ind
endif
let pline = getline(plnum)
let pbb = s:Get_paren_balance(pline, '[', ']')
while pind < ind && plnum > 0 && ppb == 0 && pbb == 0
let ind = pind
let plnum = s:Get_prev_line(plnum)
let pline = getline(plnum)
let ppb = s:Get_paren_balance(pline, '(', ')')
let pbb = s:Get_paren_balance(pline, '[', ']')
while pline =~ '^\s*else'
let plnum = s:Get_matching_if(plnum, 1)
let pline = getline(plnum)
let ppb = s:Get_paren_balance(pline, '(', ')')
let pbb = s:Get_paren_balance(pline, '[', ']')
endwhile
let pind = indent(plnum)
if ind == (pind + &sw) && pline =~ '{$'
return ind
endif
endwhile
return ind
endfunction
" vim: sw=4
" vim: sw=2

View File

@ -1,7 +1,7 @@
" Vim indent file
" Language: R Documentation (Help), *.Rd
" Author: Jakson Alves de Aquino <jalvesaq@gmail.com>
" Last Change: Wed Jul 09, 2014 07:34PM
" Last Change: Thu Oct 16, 2014 07:07AM
" Only load this indent file when no other was loaded.
@ -12,22 +12,18 @@ runtime indent/r.vim
let s:RIndent = function(substitute(&indentexpr, "()", "", ""))
let b:did_indent = 1
setlocal indentkeys=0{,0},:,!^F,o,O,e
setlocal indentexpr=GetRHelpIndent()
" Only define the function once.
if exists("*GetRHelpIndent")
finish
endif
setlocal noautoindent
setlocal nocindent
setlocal nosmartindent
setlocal nolisp
setlocal indentkeys=0{,0},:,!^F,o,O,e
setlocal indentexpr=GetCorrectRHelpIndent()
" Only define the functions once.
if exists("*GetRHelpIndent")
finish
endif
function s:SanitizeRHelpLine(line)
let newline = substitute(a:line, '\\\\', "x", "g")
let newline = substitute(newline, '\\{', "x", "g")

View File

@ -1,7 +1,7 @@
" Vim indent file
" Language: Rmd
" Author: Jakson Alves de Aquino <jalvesaq@gmail.com>
" Last Change: Wed Jul 09, 2014 07:33PM
" Last Change: Thu Jul 10, 2014 07:11PM
" Only load this indent file when no other was loaded.
@ -33,10 +33,10 @@ function GetMdIndent()
endfunction
function GetRmdIndent()
if getline(".") =~ '^```{r .*}$' || getline(".") =~ '^```$'
if getline(".") =~ '^[ \t]*```{r .*}$' || getline(".") =~ '^[ \t]*```$'
return 0
endif
if search('^```{r', "bncW") > search('^```$', "bncW")
if search('^[ \t]*```{r', "bncW") > search('^[ \t]*```$', "bncW")
return s:RIndent()
else
return GetMdIndent()

View File

@ -1,7 +1,7 @@
" Vim indent file
" Language: Rnoweb
" Author: Jakson Alves de Aquino <jalvesaq@gmail.com>
" Last Change: Wed Jul 09, 2014 07:28PM
" Last Change: Sun Mar 22, 2015 09:28AM
" Only load this indent file when no other was loaded.
@ -23,7 +23,8 @@ if exists("*GetRnowebIndent")
endif
function GetRnowebIndent()
if getline(".") =~ "^<<.*>>=$"
let curline = getline(".")
if curline =~ '^<<.*>>=$' || curline =~ '^\s*@$'
return 0
endif
if search("^<<", "bncW") > search("^@", "bncW")

View File

@ -1,6 +1,8 @@
" Vim indent file
" Language: Shell Script
" Maintainer: Peter Aronoff <telemachus@arpinum.org>
" Maintainer: Currently unmaintained. If you want to take it, please
" email Bram
" Previous Maintainer: Peter Aronoff <telemachus@arpinum.org>
" Original Author: Nikolai Weibull <now@bitwi.se>
" Latest Revision: 2014-08-22

View File

@ -0,0 +1,67 @@
" Vim indent file
" Language: Tera Term Language (TTL)
" Based on Tera Term Version 4.86
" Maintainer: Ken Takata
" URL: https://github.com/k-takata/vim-teraterm
" Last Change: 2015 Jun 4
" Filenames: *.ttl
" License: VIM License
if exists("b:did_indent")
finish
endif
let b:did_indent = 1
setlocal nosmartindent
setlocal noautoindent
setlocal indentexpr=GetTeraTermIndent(v:lnum)
setlocal indentkeys=!^F,o,O,e
setlocal indentkeys+==elseif,=endif,=loop,=next,=enduntil,=endwhile
if exists("*GetTeraTermIndent")
finish
endif
" The shiftwidth() function is relatively new.
" Don't require it to exist.
if exists('*shiftwidth')
function s:sw() abort
return shiftwidth()
endfunction
else
function s:sw() abort
return &shiftwidth
endfunction
endif
function! GetTeraTermIndent(lnum)
let l:prevlnum = prevnonblank(a:lnum-1)
if l:prevlnum == 0
" top of file
return 0
endif
" grab the previous and current line, stripping comments.
let l:prevl = substitute(getline(l:prevlnum), ';.*$', '', '')
let l:thisl = substitute(getline(a:lnum), ';.*$', '', '')
let l:previ = indent(l:prevlnum)
let l:ind = l:previ
if l:prevl =~ '^\s*if\>.*\<then\s*$'
" previous line opened a block
let l:ind += s:sw()
endif
if l:prevl =~ '^\s*\%(elseif\|else\|do\|until\|while\|for\)\>'
" previous line opened a block
let l:ind += s:sw()
endif
if l:thisl =~ '^\s*\%(elseif\|else\|endif\|enduntil\|endwhile\|loop\|next\)\>'
" this line closed a block
let l:ind -= s:sw()
endif
return l:ind
endfunction
" vim: ts=8 sw=2 sts=2

View File

@ -1,7 +1,10 @@
" Vim indent file
" Language: Zsh Shell Script
" Maintainer: Nikolai Weibull <now@bitwi.se>
" Latest Revision: 2006-04-19
" Language: Zsh shell script
" Maintainer: Christian Brabandt <cb@256bit.org>
" Previous Maintainer: Nikolai Weibull <now@bitwi.se>
" Latest Revision: 2015-05-29
" License: Vim (see :h license)
" Repository: https://github.com/chrisbra/vim-zsh
if exists("b:did_indent")
finish

View File

@ -0,0 +1,104 @@
" Vim Keymap file for russian characters, layout 'jcuken', MS Windows variant
" (slightly incompatible with XFree86 'ru' keymap - makes use of NUMERO SIGN)
" Useful mainly with utf-8 but may work with other encodings
" Derived from russian-jcuken.vim by Artem Chuprina <ran@ran.pp.ru>
" Typewriter variant of standart russian layout
" Maintainer: Denis Proskurin <danwerspb@gmail.com>
" Last Changed: 2015 May 15
" All characters are given literally, conversion to another encoding (e.g.,
" UTF-8) should work.
scriptencoding utf-8
let b:keymap_name = "ru"
loadkeymap
~ + CYRILLIC CAPITAL LETTER IO
` | CYRILLIC SMALL LETTER IO
F А CYRILLIC CAPITAL LETTER A
< Б CYRILLIC CAPITAL LETTER BE
D В CYRILLIC CAPITAL LETTER VE
U Г CYRILLIC CAPITAL LETTER GHE
L Д CYRILLIC CAPITAL LETTER DE
T Е CYRILLIC CAPITAL LETTER IE
: Ж CYRILLIC CAPITAL LETTER ZHE
P З CYRILLIC CAPITAL LETTER ZE
B И CYRILLIC CAPITAL LETTER I
Q Й CYRILLIC CAPITAL LETTER SHORT I
R К CYRILLIC CAPITAL LETTER KA
K Л CYRILLIC CAPITAL LETTER EL
V М CYRILLIC CAPITAL LETTER EM
Y Н CYRILLIC CAPITAL LETTER EN
J О CYRILLIC CAPITAL LETTER O
G П CYRILLIC CAPITAL LETTER PE
H Р CYRILLIC CAPITAL LETTER ER
C С CYRILLIC CAPITAL LETTER ES
N Т CYRILLIC CAPITAL LETTER TE
E У CYRILLIC CAPITAL LETTER U
A Ф CYRILLIC CAPITAL LETTER EF
{ Х CYRILLIC CAPITAL LETTER HA
W Ц CYRILLIC CAPITAL LETTER TSE
X Ч CYRILLIC CAPITAL LETTER CHE
I Ш CYRILLIC CAPITAL LETTER SHA
O Щ CYRILLIC CAPITAL LETTER SHCHA
} Ъ CYRILLIC CAPITAL LETTER HARD SIGN
S Ы CYRILLIC CAPITAL LETTER YERU
M Ь CYRILLIC CAPITAL LETTER SOFT SIGN
\" Э CYRILLIC CAPITAL LETTER E
> Ю CYRILLIC CAPITAL LETTER YU
Z Я CYRILLIC CAPITAL LETTER YA
f а CYRILLIC SMALL LETTER A
, б CYRILLIC SMALL LETTER BE
d в CYRILLIC SMALL LETTER VE
u г CYRILLIC SMALL LETTER GHE
l д CYRILLIC SMALL LETTER DE
t е CYRILLIC SMALL LETTER IE
; ж CYRILLIC SMALL LETTER ZHE
p з CYRILLIC SMALL LETTER ZE
b и CYRILLIC SMALL LETTER I
q й CYRILLIC SMALL LETTER SHORT I
r к CYRILLIC SMALL LETTER KA
k л CYRILLIC SMALL LETTER EL
v м CYRILLIC SMALL LETTER EM
y н CYRILLIC SMALL LETTER EN
j о CYRILLIC SMALL LETTER O
g п CYRILLIC SMALL LETTER PE
h р CYRILLIC SMALL LETTER ER
c с CYRILLIC SMALL LETTER ES
n т CYRILLIC SMALL LETTER TE
e у CYRILLIC SMALL LETTER U
a ф CYRILLIC SMALL LETTER EF
[ х CYRILLIC SMALL LETTER HA
w ц CYRILLIC SMALL LETTER TSE
x ч CYRILLIC SMALL LETTER CHE
i ш CYRILLIC SMALL LETTER SHA
o щ CYRILLIC SMALL LETTER SHCHA
] ъ CYRILLIC SMALL LETTER HARD SIGN
s ы CYRILLIC SMALL LETTER YERU
m ь CYRILLIC SMALL LETTER SOFT SIGN
' э CYRILLIC SMALL LETTER E
. ю CYRILLIC SMALL LETTER YU
z я CYRILLIC SMALL LETTER YA
@ "
# № NUMERO SIGN
$ ;
^ :
& ?
/ ё
? Ё
1
2 -
3 /
4 "
5 :
6 ,
7 .
8 _
9 ?
0 %
- !
= ;
\\ )
\| (

View File

@ -1,7 +1,7 @@
" These commands create the option window.
"
" Maintainer: Bram Moolenaar <Bram@vim.org>
" Last Change: 2014 Nov 19
" Last Change: 2015 Jul 22
" If there already is an option window, jump to that one.
if bufwinnr("option-window") > 0
@ -705,6 +705,8 @@ call append("$", "errorbells\tring the bell for error messages")
call <SID>BinOptionG("eb", &eb)
call append("$", "visualbell\tuse a visual bell instead of beeping")
call <SID>BinOptionG("vb", &vb)
call append("$", "belloff\tdo not ring the bell for these reasons")
call <SID>OptionG("belloff", &belloff)
if has("multi_lang")
call append("$", "helplang\tlist of preferred languages for finding help")
call <SID>OptionG("hlg", &hlg)
@ -954,6 +956,9 @@ call <SID>BinOptionL("bin")
call append("$", "endofline\tlast line in the file has an end-of-line")
call append("$", "\t(local to buffer)")
call <SID>BinOptionL("eol")
call append("$", "fixendofline\tfixes missing end-of-line at end of text file")
call append("$", "\t(local to buffer)")
call <SID>BinOptionL("fixeol")
if has("multi_byte")
call append("$", "bomb\tprepend a Byte Order Mark to the file")
call append("$", "\t(local to buffer)")

View File

@ -5,6 +5,7 @@ Look in the file for hints on how it can be disabled without deleting it.
getscriptPlugin.vim get latest version of Vim scripts
gzip.vim edit compressed files
logiPat.vim logical operators on patterns
matchparen.vim highlight paren matching the one under the cursor
netrwPlugin.vim edit files over a network and browse (remote) directories
rrhelper.vim used for --remote-wait editing

335
runtime/plugin/logiPat.vim Normal file
View File

@ -0,0 +1,335 @@
" LogiPat:
" Author: Charles E. Campbell
" Date: Mar 13, 2013
" Version: 3
" Purpose: to do Boolean-logic based regular expression pattern matching
" Copyright: Copyright (C) 1999-2011 Charles E. Campbell {{{1
" Permission is hereby granted to use and distribute this code,
" with or without modifications, provided that this copyright
" notice is copied with it. Like most anything else that's free,
" LogiPat.vim is provided *as is* and comes with no warranty
" of any kind, either expressed or implied. By using this
" plugin, you agree that in no event will the copyright
" holder be liable for any damages resulting from the use
" of this software.
"
" Usage: {{{1
" :LogiPat ...
"
" Boolean logic supported:
" () grouping operators
" ! not the following pattern
" | logical or
" & logical and
" "..pattern.."
" Example: {{{1
" :LogiPat !("january"|"february")
" would match all strings not containing the strings january
" or february
" GetLatestVimScripts: 1290 1 :AutoInstall: LogiPat.vim
"
" Behold, you will conceive in your womb, and bring forth a son, {{{1
" and will call his name Jesus. He will be great, and will be
" called the Son of the Most High. The Lord God will give him the
" throne of his father, David, and he will reign over the house of
" Jacob forever. There will be no end to his kingdom. (Luke 1:31-33 WEB)
" ---------------------------------------------------------------------
" Load Once: {{{1
if &cp || exists("loaded_logipat")
finish
endif
let g:loaded_LogiPat = "v3"
let s:keepcpo = &cpo
set cpo&vim
"DechoRemOn
" ---------------------------------------------------------------------
" Public Interface: {{{1
com! -nargs=* LogiPat call LogiPat(<q-args>,1)
silent! com -nargs=* LP call LogiPat(<q-args>,1)
com! -nargs=+ ELP echomsg LogiPat(<q-args>)
com! -nargs=+ LogiPatFlags let s:LogiPatFlags="<args>"
silent! com -nargs=+ LPF let s:LogiPatFlags="<args>"
" =====================================================================
" Functions: {{{1
" ---------------------------------------------------------------------
" LogiPat: this function interprets the boolean-logic pattern {{{2
fun! LogiPat(pat,...)
" call Dfunc("LogiPat(pat<".a:pat.">)")
" LogiPat(pat,dosearch)
if a:0 > 0
let dosearch= a:1
else
let dosearch= 0
endif
let s:npatstack = 0
let s:nopstack = 0
let s:preclvl = 0
let expr = a:pat
" Lexer/Parser
while expr != ""
" call Decho("expr<".expr.">")
if expr =~ '^"'
" push a Pattern; accept "" as a single " in the pattern
let expr = substitute(expr,'^\s*"','','')
let pat = substitute(expr,'^\(\%([^"]\|\"\"\)\{-}\)"\([^"].*$\|$\)','\1','')
let pat = substitute(pat,'""','"','g')
let expr = substitute(expr,'^\(\%([^"]\|\"\"\)\{-}\)"\([^"].*$\|$\)','\2','')
let expr = substitute(expr,'^\s*','','')
" call Decho("pat<".pat."> expr<".expr.">")
call s:LP_PatPush('.*'.pat.'.*')
elseif expr =~ '^[!()|&]'
" push an operator
let op = strpart(expr,0,1)
let expr = strpart(expr,strlen(op))
" allow for those who can't resist doubling their and/or operators
if op =~ '[|&]' && expr[0] == op
let expr = strpart(expr,strlen(op))
endif
call s:LP_OpPush(op)
elseif expr =~ '^\s'
" skip whitespace
let expr= strpart(expr,1)
else
echoerr "operator<".strpart(expr,0,1)."> not supported (yet)"
let expr= strpart(expr,1)
endif
endwhile
" Final Execution
call s:LP_OpPush('Z')
let result= s:LP_PatPop(1)
" call Decho("result=".result)
" sanity checks and cleanup
if s:npatstack > 0
echoerr s:npatstack." patterns left on stack!"
let s:npatstack= 0
endif
if s:nopstack > 0
echoerr s:nopstack." operators left on stack!"
let s:nopstack= 0
endif
" perform the indicated search
if dosearch
if exists("s:LogiPatFlags")
" call Decho("search(result<".result."> LogiPatFlags<".s:LogiPatFlags.">)")
call search(result,s:LogiPatFlags)
else
" call Decho("search(result<".result.">)")
call search(result)
endif
let @/= result
endif
" call Dret("LogiPat ".result)
return result
endfun
" ---------------------------------------------------------------------
" s:String: Vim6.4 doesn't have string() {{{2
func! s:String(str)
return "'".escape(a:str, '"')."'"
endfunc
" ---------------------------------------------------------------------
" LP_PatPush: {{{2
fun! s:LP_PatPush(pat)
" call Dfunc("LP_PatPush(pat<".a:pat.">)")
let s:npatstack = s:npatstack + 1
let s:patstack_{s:npatstack} = a:pat
" call s:StackLook("patpush") "Decho
" call Dret("LP_PatPush : npatstack=".s:npatstack)
endfun
" ---------------------------------------------------------------------
" LP_PatPop: pop a number/variable from LogiPat's pattern stack {{{2
fun! s:LP_PatPop(lookup)
" call Dfunc("LP_PatPop(lookup=".a:lookup.")")
if s:npatstack > 0
let ret = s:patstack_{s:npatstack}
let s:npatstack = s:npatstack - 1
else
let ret= "---error---"
echoerr "(LogiPat) invalid expression"
endif
" call s:StackLook("patpop") "Decho
" call Dret("LP_PatPop ".ret)
return ret
endfun
" ---------------------------------------------------------------------
" LP_OpPush: {{{2
fun! s:LP_OpPush(op)
" call Dfunc("LP_OpPush(op<".a:op.">)")
" determine new operator's precedence level
if a:op == '('
let s:preclvl= s:preclvl + 10
let preclvl = s:preclvl
elseif a:op == ')'
let s:preclvl= s:preclvl - 10
if s:preclvl < 0
let s:preclvl= 0
echoerr "too many )s"
endif
let preclvl= s:preclvl
elseif a:op =~ '|'
let preclvl= s:preclvl + 2
elseif a:op =~ '&'
let preclvl= s:preclvl + 4
elseif a:op == '!'
let preclvl= s:preclvl + 6
elseif a:op == 'Z'
let preclvl= -1
else
echoerr "expr<".expr."> not supported (yet)"
let preclvl= s:preclvl
endif
" call Decho("new operator<".a:op."> preclvl=".preclvl)
" execute higher-precdence operators
" call Decho("execute higher-precedence operators")
call s:LP_Execute(preclvl)
" push new operator onto operator-stack
" call Decho("push new operator<".a:op."> onto stack with preclvl=".preclvl." at nopstack=".(s:nopstack+1))
if a:op =~ '!'
let s:nopstack = s:nopstack + 1
let s:opprec_{s:nopstack} = preclvl
let s:opstack_{s:nopstack} = a:op
elseif a:op =~ '|'
let s:nopstack = s:nopstack + 1
let s:opprec_{s:nopstack} = preclvl
let s:opstack_{s:nopstack} = a:op
elseif a:op == '&'
let s:nopstack = s:nopstack + 1
let s:opprec_{s:nopstack} = preclvl
let s:opstack_{s:nopstack} = a:op
endif
" call s:StackLook("oppush") "Decho
" call Dret("LP_OpPush : s:preclvl=".s:preclvl)
endfun
" ---------------------------------------------------------------------
" LP_Execute: execute operators from opstack using pattern stack {{{2
fun! s:LP_Execute(preclvl)
" call Dfunc("LP_Execute(preclvl=".a:preclvl.") npatstack=".s:npatstack." nopstack=".s:nopstack)
" execute all higher precedence operators
while s:nopstack > 0 && a:preclvl < s:opprec_{s:nopstack}
let op= s:opstack_{s:nopstack}
" call Decho("op<".op."> nop=".s:nopstack." [preclvl=".a:preclvl."] < [opprec_".s:nopstack."=".s:opprec_{s:nopstack}."]")
let s:nopstack = s:nopstack - 1
if op == '!'
let n1= s:LP_PatPop(1)
call s:LP_PatPush(s:LP_Not(n1))
elseif op == '|'
let n1= s:LP_PatPop(1)
let n2= s:LP_PatPop(1)
call s:LP_PatPush(s:LP_Or(n2,n1))
elseif op =~ '&'
let n1= s:LP_PatPop(1)
let n2= s:LP_PatPop(1)
call s:LP_PatPush(s:LP_And(n2,n1))
endif
" call s:StackLook("execute") "Decho
endwhile
" call Dret("LP_Execute")
endfun
" ---------------------------------------------------------------------
" LP_Not: writes a logical-not for a pattern {{{2
fun! s:LP_Not(pat)
" call Dfunc("LP_Not(pat<".a:pat.">)")
if a:pat =~ '^\.\*' && a:pat =~ '\.\*$'
let pat= substitute(a:pat,'^\.\*\(.*\)\.\*$','\1','')
let ret= '^\%(\%('.pat.'\)\@!.\)*$'
else
let ret= '^\%(\%('.a:pat.'\)\@!.\)*$'
endif
" call Dret("LP_Not ".ret)
return ret
endfun
" ---------------------------------------------------------------------
" LP_Or: writes a logical-or branch using two patterns {{{2
fun! s:LP_Or(pat1,pat2)
" call Dfunc("LP_Or(pat1<".a:pat1."> pat2<".a:pat2.">)")
let ret= '\%('.a:pat1.'\|'.a:pat2.'\)'
" call Dret("LP_Or ".ret)
return ret
endfun
" ---------------------------------------------------------------------
" LP_And: writes a logical-and concat using two patterns {{{2
fun! s:LP_And(pat1,pat2)
" call Dfunc("LP_And(pat1<".a:pat1."> pat2<".a:pat2.">)")
let ret= '\%('.a:pat1.'\&'.a:pat2.'\)'
" call Dret("LP_And ".ret)
return ret
endfun
" ---------------------------------------------------------------------
" StackLook: {{{2
fun! s:StackLook(description)
" call Dfunc("StackLook(description<".a:description.">)")
let iop = 1
let ifp = 1
" call Decho("Pattern Operator")
" print both pattern and operator
while ifp <= s:npatstack && iop <= s:nopstack
let fp = s:patstack_{ifp}
let op = s:opstack_{iop}." (P".s:opprec_{s:nopstack}.')'
let fplen= strlen(fp)
if fplen < 30
let fp= fp.strpart(" ",1,30-fplen)
endif
" call Decho(fp.op)
let ifp = ifp + 1
let iop = iop + 1
endwhile
" print just pattern
while ifp <= s:npatstack
let fp = s:patstack_{ifp}
" call Decho(fp)
let ifp = ifp + 1
endwhile
" print just operator
while iop <= s:nopstack
let op = s:opstack_{iop}." (P".s:opprec_{s:nopstack}.')'
" call Decho(" ".op)
let iop = iop + 1
endwhile
" call Dret("StackLook")
endfun
" ---------------------------------------------------------------------
" Cleanup And Modeline: {{{1
let &cpo= s:keepcpo
unlet s:keepcpo
" vim: ts=4 fdm=marker

View File

@ -1,6 +1,6 @@
" netrwPlugin.vim: Handles file transfer and remote directory listing across a network
" PLUGIN SECTION
" Date: Jan 22, 2014
" Date: Nov 07, 2014
" Maintainer: Charles E Campbell <NdrOchip@ScampbellPfamily.AbizM-NOSPAM>
" GetLatestVimScripts: 1075 1 :AutoInstall: netrw.vim
" Copyright: Copyright (C) 1999-2013 Charles E. Campbell {{{1
@ -20,7 +20,7 @@
if &cp || exists("g:loaded_netrwPlugin")
finish
endif
let g:loaded_netrwPlugin = "v152"
let g:loaded_netrwPlugin = "v153"
if v:version < 702
echohl WarningMsg
echo "***warning*** you need vim version 7.2 for this version of netrw"
@ -54,15 +54,15 @@ augroup END
" Network Browsing Reading Writing: {{{2
augroup Network
au!
au BufReadCmd file://* call netrw#FileUrlRead(expand("<amatch>"))
au BufReadCmd ftp://*,rcp://*,scp://*,http://*,https://*,dav://*,davs://*,rsync://*,sftp://* exe "sil doau BufReadPre ".fnameescape(expand("<amatch>"))|call netrw#Nread(2,expand("<amatch>"))|exe "sil doau BufReadPost ".fnameescape(expand("<amatch>"))
au FileReadCmd ftp://*,rcp://*,scp://*,http://*,https://*,dav://*,davs://*,rsync://*,sftp://* exe "sil doau FileReadPre ".fnameescape(expand("<amatch>"))|call netrw#Nread(1,expand("<amatch>"))|exe "sil doau FileReadPost ".fnameescape(expand("<amatch>"))
au BufWriteCmd ftp://*,rcp://*,scp://*,http://*,dav://*,davs://*,rsync://*,sftp://* exe "sil doau BufWritePre ".fnameescape(expand("<amatch>"))|exe 'Nwrite '.fnameescape(expand("<amatch>"))|exe "sil doau BufWritePost ".fnameescape(expand("<amatch>"))
au FileWriteCmd ftp://*,rcp://*,scp://*,http://*,dav://*,davs://*,rsync://*,sftp://* exe "sil doau FileWritePre ".fnameescape(expand("<amatch>"))|exe "'[,']".'Nwrite '.fnameescape(expand("<amatch>"))|exe "sil doau FileWritePost ".fnameescape(expand("<amatch>"))
try
au SourceCmd ftp://*,rcp://*,scp://*,http://*,https://*,dav://*,davs://*,rsync://*,sftp://* exe 'Nsource '.fnameescape(expand("<amatch>"))
catch /^Vim\%((\a\+)\)\=:E216/
au SourcePre ftp://*,rcp://*,scp://*,http://*,https://*,dav://*,davs://*,rsync://*,sftp://* exe 'Nsource '.fnameescape(expand("<amatch>"))
au BufReadCmd file://* call netrw#FileUrlRead(expand("<amatch>"))
au BufReadCmd ftp://*,rcp://*,scp://*,http://*,file://*,https://*,dav://*,davs://*,rsync://*,sftp://* exe "sil doau BufReadPre ".fnameescape(expand("<amatch>"))|call netrw#Nread(2,expand("<amatch>"))|exe "sil doau BufReadPost ".fnameescape(expand("<amatch>"))
au FileReadCmd ftp://*,rcp://*,scp://*,http://*,file://*,https://*,dav://*,davs://*,rsync://*,sftp://* exe "sil doau FileReadPre ".fnameescape(expand("<amatch>"))|call netrw#Nread(1,expand("<amatch>"))|exe "sil doau FileReadPost ".fnameescape(expand("<amatch>"))
au BufWriteCmd ftp://*,rcp://*,scp://*,http://*,file://*,dav://*,davs://*,rsync://*,sftp://* exe "sil doau BufWritePre ".fnameescape(expand("<amatch>"))|exe 'Nwrite '.fnameescape(expand("<amatch>"))|exe "sil doau BufWritePost ".fnameescape(expand("<amatch>"))
au FileWriteCmd ftp://*,rcp://*,scp://*,http://*,file://*,dav://*,davs://*,rsync://*,sftp://* exe "sil doau FileWritePre ".fnameescape(expand("<amatch>"))|exe "'[,']".'Nwrite '.fnameescape(expand("<amatch>"))|exe "sil doau FileWritePost ".fnameescape(expand("<amatch>"))
try
au SourceCmd ftp://*,rcp://*,scp://*,http://*,file://*,https://*,dav://*,davs://*,rsync://*,sftp://* exe 'Nsource '.fnameescape(expand("<amatch>"))
catch /^Vim\%((\a\+)\)\=:E216/
au SourcePre ftp://*,rcp://*,scp://*,http://*,file://*,https://*,dav://*,davs://*,rsync://*,sftp://* exe 'Nsource '.fnameescape(expand("<amatch>"))
endtry
augroup END
@ -81,18 +81,26 @@ com! -nargs=* -bar -bang -count=0 -complete=dir Vexplore call netrw#Explore(<cou
com! -nargs=* -bar -count=0 -complete=dir Texplore call netrw#Explore(<count>,0,6 ,<q-args>)
com! -nargs=* -bar -bang Nexplore call netrw#Explore(-1,0,0,<q-args>)
com! -nargs=* -bar -bang Pexplore call netrw#Explore(-2,0,0,<q-args>)
com! -nargs=* -bar -complete=dir Lexplore call netrw#Lexplore(<q-args>)
com! -nargs=* -bar -bang -count=0 -complete=dir Lexplore call netrw#Lexplore(<count>,<bang>0,<q-args>)
" Commands: NetrwSettings {{{2
com! -nargs=0 NetrwSettings call netrwSettings#NetrwSettings()
com! -bang NetrwClean call netrw#Clean(<bang>0)
" Maps:
if !exists("g:netrw_nogx") && maparg('gx','n') == ""
if !hasmapto('<Plug>NetrwBrowseX')
nmap <unique> gx <Plug>NetrwBrowseX
if !exists("g:netrw_nogx")
if maparg('gx','n') == ""
if !hasmapto('<Plug>NetrwBrowseX')
nmap <unique> gx <Plug>NetrwBrowseX
endif
nno <silent> <Plug>NetrwBrowseX :call netrw#BrowseX(expand((exists("g:netrw_gx")? g:netrw_gx : '<cfile>')),netrw#CheckIfRemote())<cr>
endif
if maparg('gx','v') == ""
if !hasmapto('<Plug>NetrwBrowseXVis')
vmap <unique> gx <Plug>NetrwBrowseXVis
endif
vno <silent> <Plug>NetrwBrowseXVis :<c-u>call netrw#BrowseXVis()<cr>
endif
nno <silent> <Plug>NetrwBrowseX :call netrw#NetrwBrowseX(expand("<cfile>"),0)<cr>
endif
" ---------------------------------------------------------------------
@ -119,7 +127,7 @@ fun! s:LocalBrowse(dirname)
" call Decho("(LocalBrowse) dirname<".a:dirname."> (isdirectory, amiga)")
if a:dirname != '' && isdirectory(a:dirname)
sil! call netrw#LocalBrowseCheck(a:dirname)
if exists("w:netrw_bannercnt")
if exists("w:netrw_bannercnt") && line('.') < w:netrw_bannercnt
exe w:netrw_bannercnt
endif
endif
@ -128,7 +136,7 @@ fun! s:LocalBrowse(dirname)
" call Decho("(LocalBrowse) dirname<".a:dirname."> ft=".&ft." (isdirectory, not amiga)")
" call Dredir("LocalBrowse ft last set: ","verbose set ft")
sil! call netrw#LocalBrowseCheck(a:dirname)
if exists("w:netrw_bannercnt")
if exists("w:netrw_bannercnt") && line('.') < w:netrw_bannercnt
exe w:netrw_bannercnt
endif

View File

@ -1,9 +1,9 @@
" Vim syntax file
" Language: AmigaDos
" Maintainer: Dr. Charles E. Campbell, Jr. <NdrOchipS@PcampbellAfamily.Mbiz>
" Last Change: Sep 11, 2006
" Version: 6
" URL: http://mysite.verizon.net/astronaut/vim/index.html#vimlinks_syntax
" Maintainer: Charles E. Campbell <NdrOchipS@PcampbellAfamily.Mbiz>
" Last Change: Oct 23, 2014
" Version: 7
" URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_AMIGA
" For version 5.x: Clear all syntax items
" For version 6.x: Quit when a syntax file was already loaded

View File

@ -1,8 +1,9 @@
" Vim syntax file
" Language: Asterisk config file
" Maintainer: brc007
" Maintainer: Jean Aunis <jean.aunis@yahoo.fr>
" Previous Maintainer: brc007
" Updated for 1.2 by Tilghman Lesher (Corydon76)
" Last Change: 2006 Mar 20
" Last Change: 2015 Feb 27
" version 0.4
"
if version < 600
@ -17,18 +18,19 @@ syn sync fromstart
syn keyword asteriskTodo TODO contained
syn match asteriskComment ";.*" contains=asteriskTodo
syn match asteriskContext "\[.\{-}\]"
syn match asteriskExten "^\s*exten\s*=>\?\s*[^,]\+" contains=asteriskPattern
syn match asteriskExten "^\s*\zsexten\s*=>\?\s*[^,]\+\ze," contains=asteriskPattern nextgroup=asteriskPriority
syn match asteriskExten "^\s*\zssame\s*=>\?\s*\ze" nextgroup=asteriskPriority
syn match asteriskExten "^\s*\(register\|channel\|ignorepat\|include\|\(no\)\?load\)\s*=>\?"
syn match asteriskPattern "_\(\[[[:alnum:]#*\-]\+\]\|[[:alnum:]#*]\)*\.\?" contained
syn match asteriskPattern "[^A-Za-z0-9,]\zs[[:alnum:]#*]\+\ze" contained
syn match asteriskApp ",\zs[a-zA-Z]\+\ze$"
syn match asteriskApp ",\zs[a-zA-Z]\+\ze("
" Digits plus oldlabel (newlabel)
syn match asteriskPriority ",\zs[[:digit:]]\+\(+[[:alpha:]][[:alnum:]_]*\)\?\(([[:alpha:]][[:alnum:]_]*)\)\?\ze," contains=asteriskLabel
syn match asteriskPriority "\zs[[:digit:]]\+\(+[[:alpha:]][[:alnum:]_]*\)\?\(([[:alpha:]][[:alnum:]_]*)\)\?\ze," contains=asteriskLabel
" oldlabel plus digits (newlabel)
syn match asteriskPriority ",\zs[[:alpha:]][[:alnum:]_]*+[[:digit:]]\+\(([[:alpha:]][[:alnum:]_]*)\)\?\ze," contains=asteriskLabel
syn match asteriskPriority "\zs[[:alpha:]][[:alnum:]_]*+[[:digit:]]\+\(([[:alpha:]][[:alnum:]_]*)\)\?\ze," contains=asteriskLabel
" s or n plus digits (newlabel)
syn match asteriskPriority ",\zs[sn]\(+[[:digit:]]\+\)\?\(([[:alpha:]][[:alnum:]_]*)\)\?\ze," contains=asteriskLabel
syn match asteriskPriority "\zs[sn]\(+[[:digit:]]\+\)\?\(([[:alpha:]][[:alnum:]_]*)\)\?\ze," contains=asteriskLabel
syn match asteriskLabel "(\zs[[:alpha:]][[:alnum:]]*\ze)" contained
syn match asteriskError "^\s*#\s*[[:alnum:]]*"
syn match asteriskInclude "^\s*#\s*\(include\|exec\)\s.*"

View File

@ -1,13 +1,15 @@
" Vim syntax file
" Language: awk, nawk, gawk, mawk
" Maintainer: Antonio Colombo <azc100@gmail.com>
" Last Change: 2012 May 18
" Last Change: 2014 Oct 21
" AWK ref. is: Alfred V. Aho, Brian W. Kernighan, Peter J. Weinberger
" The AWK Programming Language, Addison-Wesley, 1988
" GAWK ref. is: Arnold D. Robbins
" Effective AWK Programming, Third Edition, O'Reilly, 2001
" Effective AWK Programming, Fourth Edition, O'Reilly, 2015
" (also available with the gawk source distribution)
" MAWK is a "new awk" meaning it implements AWK ref.
" mawk conforms to the Posix 1003.2 (draft 11.3)
@ -33,17 +35,27 @@ set cpo&vim
syn keyword awkStatement break continue delete exit
syn keyword awkStatement function getline next
syn keyword awkStatement print printf return
" GAWK ref. p. 117
" GAWK ref. Chapter 7
syn keyword awkStatement nextfile
" AWK ref. p. 42, GAWK ref. p. 142-166
syn keyword awkFunction atan2 close cos exp fflush int log rand sin sqrt srand
syn keyword awkFunction gsub index length match split sprintf sub
syn keyword awkFunction substr system
" GAWK ref. p. 142-166
syn keyword awkFunction asort gensub mktime strftime strtonum systime
"
" GAWK ref. Chapter 9, Functions
"
" Numeric Functions
syn keyword awkFunction atan2 cos div exp int log rand sin sqrt srand
" String Manipulation Functions
syn keyword awkFunction asort asort1 gensub gsub index length match
syn keyword awkFunction patsplit split sprintf strtonum sub substr
syn keyword awkFunction tolower toupper
syn keyword awkFunction and or xor compl lshift rshift
syn keyword awkFunction dcgettext bindtextdomain
" Input Output Functions
syn keyword awkFunction close fflush system
" Time Functions
syn keyword awkFunction mktime strftime systime
" Bit Manipulation Functions
syn keyword awkFunction and compl lshift or rshift xor
" Getting Type Function
syn keyword awkFunction isarray
" String-Translation Functions
syn keyword awkFunction bindtextdomain dcgettext dcngetext
syn keyword awkConditional if else
syn keyword awkRepeat while for
@ -51,13 +63,16 @@ syn keyword awkRepeat while for
syn keyword awkTodo contained TODO
syn keyword awkPatterns BEGIN END
" AWK ref. p. 36
syn keyword awkVariables ARGC ARGV FILENAME FNR FS NF NR
syn keyword awkVariables OFMT OFS ORS RLENGTH RS RSTART SUBSEP
" GAWK ref. p. 120-126
syn keyword awkVariables ARGIND BINMODE CONVFMT ENVIRON ERRNO
syn keyword awkVariables FIELDWIDTHS IGNORECASE LINT PROCINFO
syn keyword awkVariables RT RLENGTH TEXTDOMAIN
" GAWK ref. Chapter 7
" Built-in Variables That Control awk
syn keyword awkVariables BINMODE CONVFMT FIELDWIDTHS FPAT FS
syn keyword awkVariables IGNORECASE LINT OFMT OFS ORS PREC
syn keyword awkVariables ROUNDMODE RS SUBSEP TEXTDOMAIN
" Built-in Variables That Convey Information
syn keyword awkVariables ARGC ARGV ARGIND ENVIRON ERRNO FILENAME
syn keyword awkVariables FNR NF FUNCTAB NR PROCINFO RLENGTH RSTART
syn keyword awkVariables RT SYMTAB
syn keyword awkRepeat do
@ -115,15 +130,15 @@ syn case match
"syn match awkIdentifier "\<[a-zA-Z_][a-zA-Z0-9_]*\>"
" Arithmetic operators: +, and - take care of ++, and --
"syn match awkOperator "+\|-\|\*\|/\|%\|="
"syn match awkOperator "+=\|-=\|\*=\|/=\|%="
"syn match awkOperator "^\|^="
syn match awkOperator "+\|-\|\*\|/\|%\|="
syn match awkOperator "+=\|-=\|\*=\|/=\|%="
syn match awkOperator "^\|^="
" Comparison expressions.
"syn match awkExpression "==\|>=\|=>\|<=\|=<\|\!="
"syn match awkExpression "\~\|\!\~"
"syn match awkExpression "?\|:"
"syn keyword awkExpression in
syn match awkExpression "==\|>=\|=>\|<=\|=<\|\!="
syn match awkExpression "\~\|\!\~"
syn match awkExpression "?\|:"
syn keyword awkExpression in
" Boolean Logic (OR, AND, NOT)
"syn match awkBoolLogic "||\|&&\|\!"
@ -187,8 +202,8 @@ if version >= 508 || !exists("did_awk_syn_inits")
HiLink awkFloat Float
HiLink awkFileIO Special
"HiLink awkOperator Special
"HiLink awkExpression Special
HiLink awkOperator Special
HiLink awkExpression Special
HiLink awkBoolLogic Special
HiLink awkPatterns Special

View File

@ -1,7 +1,7 @@
" Vim syntax file
" Language: C
" Maintainer: Bram Moolenaar <Bram@vim.org>
" Last Change: 2014 Nov 13
" Last Change: 2015 Mar 05
" Quit when a (custom) syntax file was already loaded
if exists("b:current_syntax")
@ -47,16 +47,17 @@ if !exists("c_no_cformat")
endif
" cCppString: same as cString, but ends at end of line
if s:ft ==# "cpp" && !exists("cpp_no_cpp11")
if s:ft ==# "cpp" && !exists("cpp_no_cpp11") && !exists("c_no_cformat")
" ISO C++11
syn region cString start=+\(L\|u\|u8\|U\|R\|LR\|u8R\|uR\|UR\)\="+ skip=+\\\\\|\\"+ end=+"+ contains=cSpecial,cFormat,@Spell extend
syn region cCppString start=+\(L\|u\|u8\|U\|R\|LR\|u8R\|uR\|UR\)\="+ skip=+\\\\\|\\"\|\\$+ excludenl end=+"+ end='$' contains=cSpecial,cFormat,@Spell
elseif s:ft ==# "c" && !exists("c_no_c11")
elseif s:ft ==# "c" && !exists("c_no_c11") && !exists("c_no_cformat")
" ISO C99
syn region cString start=+\%(L\|U\|u8\)\="+ skip=+\\\\\|\\"+ end=+"+ contains=cSpecial,cFormat,@Spell extend
syn region cCppString start=+\%(L\|U\|u8\)\="+ skip=+\\\\\|\\"\|\\$+ excludenl end=+"+ end='$' contains=cSpecial,cFormat,@Spell
else
" older C or C++
syn match cFormat display "%%" contained
syn region cString start=+L\="+ skip=+\\\\\|\\"+ end=+"+ contains=cSpecial,cFormat,@Spell extend
syn region cCppString start=+L\="+ skip=+\\\\\|\\"\|\\$+ excludenl end=+"+ end='$' contains=cSpecial,cFormat,@Spell
endif
@ -80,7 +81,11 @@ syn match cSpecialCharacter display "L'\\x\x\+'"
if (s:ft ==# "c" && !exists("c_no_c11")) || (s:ft ==# "cpp" && !exists("cpp_no_cpp11"))
" ISO C11 or ISO C++ 11
syn region cString start=+\%(U\|u8\=\)"+ skip=+\\\\\|\\"+ end=+"+ contains=cSpecial,cFormat,@Spell extend
if exists("c_no_cformat")
syn region cString start=+\%(U\|u8\=\)"+ skip=+\\\\\|\\"+ end=+"+ contains=cSpecial,@Spell extend
else
syn region cString start=+\%(U\|u8\=\)"+ skip=+\\\\\|\\"+ end=+"+ contains=cSpecial,cFormat,@Spell extend
endif
syn match cCharacter "[Uu]'[^\\]'"
syn match cCharacter "[Uu]'[^']*'" contains=cSpecial
if exists("c_gnu")
@ -330,6 +335,8 @@ if !exists("c_no_ansi") || exists("c_ansi_constants") || exists("c_gnu")
" POSIX 2001
syn keyword cConstant SIGBUS SIGPOLL SIGPROF SIGSYS SIGURG
syn keyword cConstant SIGVTALRM SIGXCPU SIGXFSZ
" non-POSIX signals
syn keyword cConstant SIGWINCH SIGINFO
" Add POSIX errors as well
syn keyword cConstant E2BIG EACCES EAGAIN EBADF EBADMSG EBUSY
syn keyword cConstant ECANCELED ECHILD EDEADLK EDOM EEXIST EFAULT
@ -387,8 +394,13 @@ endif
syn cluster cLabelGroup contains=cUserLabel
syn match cUserCont display "^\s*\I\i*\s*:$" contains=@cLabelGroup
syn match cUserCont display ";\s*\I\i*\s*:$" contains=@cLabelGroup
syn match cUserCont display "^\s*\I\i*\s*:[^:]"me=e-1 contains=@cLabelGroup
syn match cUserCont display ";\s*\I\i*\s*:[^:]"me=e-1 contains=@cLabelGroup
if s:ft ==# 'cpp'
syn match cUserCont display "^\s*\%(class\|struct\|enum\)\@!\I\i*\s*:[^:]"me=e-1 contains=@cLabelGroup
syn match cUserCont display ";\s*\%(class\|struct\|enum\)\@!\I\i*\s*:[^:]"me=e-1 contains=@cLabelGroup
else
syn match cUserCont display "^\s*\I\i*\s*:[^:]"me=e-1 contains=@cLabelGroup
syn match cUserCont display ";\s*\I\i*\s*:[^:]"me=e-1 contains=@cLabelGroup
endif
syn match cUserLabel display "\I\i*" contained

View File

@ -1,10 +1,10 @@
" Vim syntax file
" Language: COBOL
" Maintainer: Tim Pope <vimNOSPAM@tpope.info>
" Language: COBOL
" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
" (formerly Davyd Ondrejko <vondraco@columbus.rr.com>)
" (formerly Sitaram Chamarty <sitaram@diac.com> and
" James Mitchell <james_mitchell@acm.org>)
" $Id: cobol.vim,v 1.2 2007/05/05 18:23:43 vimboss Exp $
" James Mitchell <james_mitchell@acm.org>)
" Last Change: 2015 Feb 13
" For version 5.x: Clear all syntax items
" For version 6.x: Quit when a syntax file was already loaded
@ -145,7 +145,7 @@ syn match cobolString /'[^']*\('\|$\)/
syn match cobolIndicator "\%7c[D-]" contained
if exists("cobol_legacy_code")
syn region cobolCondFlow contains=ALLBUT,cobolLine start="\<\(IF\|INVALID\|END\|EOP\)\>" skip=/\('\|"\)[^"]\{-}\("\|'\|$\)/ end="\." keepend
syn region cobolCondFlow contains=ALLBUT,cobolLine,cobolBadLine start="\<\(IF\|INVALID\|END\|EOP\)\>" skip=/\('\|"\)[^"]\{-}\("\|'\|$\)/ end="\." keepend
endif
" many legacy sources have junk in columns 1-6: must be before others

View File

@ -1,11 +1,13 @@
" Vim syntax file
" Language: configure.in script: M4 with sh
" Maintainer: Christian Hammesr <ch@lathspell.westend.com>
" Last Change: 2008 Sep 03
" Last Change: 2015 Jan 14
" (patch from Yngve Inntjore Levinsen to detect AC_MSG)
" (patch from Khym Chanur to add @Spell)
" Well, I actually even do not know much about m4. This explains why there
" is probably very much missing here, yet !
" But I missed a good hilighting when editing my GNU autoconf/automake
" But I missed good highlighting when editing my GNU autoconf/automake
" script, so I wrote this quick and dirty patch.
@ -20,14 +22,19 @@ endif
" define the config syntax
syn match configdelimiter "[()\[\];,]"
syn match configoperator "[=|&\*\+\<\>]"
syn match configcomment "\(dnl.*\)\|\(#.*\)"
syn match configcomment "\(dnl.*\)\|\(#.*\)" contains=configDnl,@Spell
syn match configfunction "\<[A-Z_][A-Z0-9_]*\>"
syn match confignumber "[-+]\=\<\d\+\(\.\d*\)\=\>"
syn keyword configDnl dnl contained
syn keyword configkeyword if then else fi test for in do done
syn keyword configspecial cat rm eval
syn region configstring start=+"+ skip=+\\"+ end=+"+
syn region configstring start=+'+ skip=+\\'+ end=+'+
syn region configstring start=+`+ skip=+\\'+ end=+`+
" This shortens the script, see syn-ext-match..
syn region configstring start=+\z(["'`]\)+ skip=+\\\z1+ end=+\z1+ contains=@Spell
" Anything inside AC_MSG_TYPE([...]) and AC_MSG_TYPE(...) is a string.
syn region configstring matchgroup=configfunction start="AC_MSG_[A-Z]*\ze(\[" matchgroup=configdelimiter end="\])" contains=configdelimiter,@Spell
syn region configstring matchgroup=configfunction start="AC_MSG_[A-Z]*\ze([^[]" matchgroup=configdelimiter end=")" contains=configdelimiter,@Spell
" Define the default highlighting.
" For version 5.7 and earlier: only when not done already
@ -43,6 +50,7 @@ if version >= 508 || !exists("did_config_syntax_inits")
HiLink configdelimiter Delimiter
HiLink configoperator Operator
HiLink configcomment Comment
HiLink configDnl Comment
HiLink configfunction Function
HiLink confignumber Number
HiLink configkeyword Keyword

View File

@ -1,8 +1,8 @@
" Vim syntax file
" Language: C++
" Current Maintainer: vim-jp (https://github.com/vim-jp/cpp-vim)
" Current Maintainer: vim-jp (https://github.com/vim-jp/vim-cpp)
" Previous Maintainer: Ken Shan <ccshan@post.harvard.edu>
" Last Change: 2014 May 14
" Last Change: 2015 May 04
" For version 5.x: Clear all syntax items
" For version 6.x: Quit when a syntax file was already loaded
@ -32,14 +32,21 @@ syn match cppCast "\<\(const\|static\|dynamic\|reinterpret\)_cast\s*$"
syn keyword cppStorageClass mutable
syn keyword cppStructure class typename template namespace
syn keyword cppBoolean true false
syn keyword cppConstant __cplusplus
" C++ 11 extensions
if !exists("cpp_no_cpp11")
syn keyword cppType override final
syn keyword cppExceptions noexcept
syn keyword cppStorageClass constexpr decltype
syn keyword cppStorageClass constexpr decltype thread_local
syn keyword cppConstant nullptr
syn region cppRawString matchgroup=cppRawDelimiter start=+\%(u8\|[uLU]\)\=R"\z([[:alnum:]_{}[\]#<>%:;.?*\+\-/\^&|~!=,"']\{,16}\)(+ end=+)\z1"+ contains=@Spell
syn keyword cppConstant ATOMIC_FLAG_INIT ATOMIC_VAR_INIT
syn keyword cppConstant ATOMIC_BOOL_LOCK_FREE ATOMIC_CHAR_LOCK_FREE
syn keyword cppConstant ATOMIC_CHAR16_T_LOCK_FREE ATOMIC_CHAR32_T_LOCK_FREE
syn keyword cppConstant ATOMIC_WCHAR_T_LOCK_FREE ATOMIC_SHORT_LOCK_FREE
syn keyword cppConstant ATOMIC_INT_LOCK_FREE ATOMIC_LONG_LOCK_FREE
syn keyword cppConstant ATOMIC_LLONG_LOCK_FREE ATOMIC_POINTER_LOCK_FREE
syn region cppRawString matchgroup=cppRawStringDelimiter start=+\%(u8\|[uLU]\)\=R"\z([[:alnum:]_{}[\]#<>%:;.?*\+\-/\^&|~!=,"']\{,16}\)(+ end=+)\z1"+ contains=@Spell
endif
" The minimum and maximum operators in GNU C++
@ -63,7 +70,7 @@ if version >= 508 || !exists("did_cpp_syntax_inits")
HiLink cppStructure Structure
HiLink cppBoolean Boolean
HiLink cppConstant Constant
HiLink cppRawDelimiter Delimiter
HiLink cppRawStringDelimiter Delimiter
HiLink cppRawString String
delcommand HiLink
endif

View File

@ -5,7 +5,7 @@
" License: This file can be redistribued and/or modified under the same terms
" as Vim itself.
" Filenames: /tmp/crontab.* used by "crontab -e"
" Last Change: 2012-05-16
" Last Change: 2015-01-20
"
" crontab line format:
" Minutes Hours Days Months Days_of_Week Commands # comments
@ -13,11 +13,17 @@
" For version 5.x: Clear all syntax items
" For version 6.x: Quit when a syntax file was already loaded
if version < 600
syntax clear
syntax clear
elseif exists("b:current_syntax")
finish
finish
endif
syntax match crontabNick "^\s*@\(reboot\|yearly\|annually\|monthly\|weekly\|daily\|midnight\|hourly\)\>" nextgroup=crontabCmd skipwhite
syntax match crontabVar "^\s*\k\w*\s*="me=e-1
syntax case ignore
syntax match crontabMin "^\s*[-0-9/,.*]\+" nextgroup=crontabHr skipwhite
syntax match crontabHr "\s[-0-9/,.*]\+" nextgroup=crontabDay skipwhite contained
syntax match crontabDay "\s[-0-9/,.*]\+" nextgroup=crontabMnth skipwhite contained
@ -32,45 +38,41 @@ syntax region crontabCmd start="\S" end="$" skipwhite contained keepend contains
syntax match crontabCmnt "^\s*#.*" contains=@Spell
syntax match crontabPercent "[^\\]%.*"lc=1 contained
syntax match crontabNick "^\s*@\(reboot\|yearly\|annually\|monthly\|weekly\|daily\|midnight\|hourly\)\>" nextgroup=crontabCmd skipwhite
syntax match crontabVar "^\s*\k\w*\s*="me=e-1
" Define the default highlighting.
" For version 5.7 and earlier: only when not done already
" For version 5.8 and later: only when an item doesn't have highlighting yet
if version >= 508 || !exists("did_crontab_syn_inits")
if version < 508
let did_crontab_syn_inits = 1
command -nargs=+ HiLink hi link <args>
else
command -nargs=+ HiLink hi def link <args>
endif
if version < 508
let did_crontab_syn_inits = 1
command -nargs=+ HiLink hi link <args>
else
command -nargs=+ HiLink hi def link <args>
endif
HiLink crontabMin Number
HiLink crontabHr PreProc
HiLink crontabDay Type
HiLink crontabMin Number
HiLink crontabHr PreProc
HiLink crontabDay Type
HiLink crontabMnth Number
HiLink crontabMnth12 Number
HiLink crontabMnthS Number
HiLink crontabMnthN Number
HiLink crontabMnth Number
HiLink crontabMnth12 Number
HiLink crontabMnthS Number
HiLink crontabMnthN Number
HiLink crontabDow PreProc
HiLink crontabDow7 PreProc
HiLink crontabDowS PreProc
HiLink crontabDowN PreProc
HiLink crontabDow PreProc
HiLink crontabDow7 PreProc
HiLink crontabDowS PreProc
HiLink crontabDowN PreProc
HiLink crontabNick Special
HiLink crontabVar Identifier
HiLink crontabPercent Special
HiLink crontabNick Special
HiLink crontabVar Identifier
HiLink crontabPercent Special
" comment out next line for to suppress unix commands coloring.
HiLink crontabCmd Statement
HiLink crontabCmd Statement
HiLink crontabCmnt Comment
HiLink crontabCmnt Comment
delcommand HiLink
delcommand HiLink
endif
let b:current_syntax = "crontab"

View File

@ -1,9 +1,9 @@
" Vim syntax file
" Language: C-shell (csh)
" Maintainer: Dr. Charles E. Campbell, Jr. <NdrOchipS@PcampbellAfamily.Mbiz>
" Version: 10
" Last Change: Sep 11, 2006
" URL: http://mysite.verizon.net/astronaut/vim/index.html#vimlinks_syntax
" Maintainer: Charles E. Campbell <NdrOchipS@PcampbellAfamily.Mbiz>
" Last Change: Oct 23, 2014
" Version: 11
" URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_CSH
" For version 5.x: Clear all syntax items
" For version 6.x: Quit when a syntax file was already loaded

View File

@ -6,7 +6,7 @@
" Nikolai Weibull (Add CSS2 support)
" Maintainer: Jules Wang <w.jq0722@gmail.com>
" URL: https://github.com/JulesWang/css.vim
" Last Change: 2013 Nov.27
" Last Change: 2015 Apr.17
" For version 5.x: Clear all syntax items
" For version 6.x: Quit when a syntax file was already loaded
@ -26,18 +26,19 @@ set cpo&vim
syn case ignore
" All HTML4 tags
syn keyword cssTagName abbr acronym address applet area a b base
syn keyword cssTagName basefont bdo big blockquote body br button
syn keyword cssTagName caption center cite code col colgroup dd del
syn keyword cssTagName dfn dir div dl dt em fieldset font form frame
syn keyword cssTagName frameset h1 h2 h3 h4 h5 h6 head hr html img i
syn keyword cssTagName iframe img input ins isindex kbd label legend li
syn keyword cssTagName link map menu meta noframes noscript ol optgroup
syn keyword cssTagName option p param pre q s samp script select small
syn keyword cssTagName span strike strong style sub sup table tbody td
syn keyword cssTagName textarea tfoot th thead title tr tt ul u var
" HTML4 tags
syn keyword cssTagName abbr address area a b base
syn keyword cssTagName bdo blockquote body br button
syn keyword cssTagName caption cite code col colgroup dd del
syn keyword cssTagName dfn div dl dt em fieldset form
syn keyword cssTagName h1 h2 h3 h4 h5 h6 head hr html img i
syn keyword cssTagName iframe input ins isindex kbd label legend li
syn keyword cssTagName link map menu meta noscript ol optgroup
syn keyword cssTagName option p param pre q s samp script small
syn keyword cssTagName span strong sub sup tbody td
syn keyword cssTagName textarea tfoot th thead title tr ul u var
syn keyword cssTagName object svg
syn match cssTagName /\<select\>\|\<style\>\|\<table\>/
" 34 HTML5 tags
syn keyword cssTagName article aside audio bdi canvas command data
@ -47,8 +48,8 @@ syn keyword cssTagName output progress rt rp ruby section
syn keyword cssTagName source summary time track video wbr
" Tags not supported in HTML5
syn keyword cssDeprecated acronym applet basefont big center dir
syn keyword cssDeprecated font frame frameset noframes strike tt
" acronym applet basefont big center dir
" font frame frameset noframes strike tt
syn match cssTagName "\*"
@ -70,13 +71,13 @@ endtry
" digits
syn match cssValueInteger contained "[-+]\=\d\+" contains=cssUnitDecorators
syn match cssValueNumber contained "[-+]\=\d\+\(\.\d*\)\=" contains=cssUnitDecorators
syn match cssValueLength contained "[-+]\=\d\+\(\.\d*\)\=\(%\|mm\|cm\|in\|pt\|pc\|em\|ex\|px\|rem\|dpi\|dppx\|dpcm\)" contains=cssUnitDecorators
syn match cssValueAngle contained "[-+]\=\d\+\(\.\d*\)\=\(deg\|grad\|rad\)" contains=cssUnitDecorators
syn match cssValueTime contained "+\=\d\+\(\.\d*\)\=\(ms\|s\)" contains=cssUnitDecorators
syn match cssValueFrequency contained "+\=\d\+\(\.\d*\)\=\(Hz\|kHz\)" contains=cssUnitDecorators
syn match cssValueLength contained "[-+]\=\d\+\(\.\d*\)\=\(%\|mm\|cm\|in\|pt\|pc\|em\|ex\|px\|rem\|dpi\|dppx\|dpcm\)\>" contains=cssUnitDecorators
syn match cssValueAngle contained "[-+]\=\d\+\(\.\d*\)\=\(deg\|grad\|rad\)\>" contains=cssUnitDecorators
syn match cssValueTime contained "+\=\d\+\(\.\d*\)\=\(ms\|s\)\>" contains=cssUnitDecorators
syn match cssValueFrequency contained "+\=\d\+\(\.\d*\)\=\(Hz\|kHz\)\>" contains=cssUnitDecorators
syn match cssIncludeKeyword /@\(-[a-z]+-\)\=\(media\|keyframes\|import\|charset\|namespace\|page\)/ contained
syn match cssIncludeKeyword /@\(-[a-z]\+-\)\=\(media\|keyframes\|import\|charset\|namespace\|page\)/ contained
" @media
syn region cssInclude start=/@media\>/ end=/\ze{/ skipwhite skipnl contains=cssMediaProp,cssValueLength,cssMediaKeyword,cssValueInteger,cssMediaAttr,cssVendor,cssMediaType,cssIncludeKeyword,cssMediaComma,cssComment nextgroup=cssMediaBlock
syn keyword cssMediaType contained screen print aural braille embossed handheld projection tty tv speech all contained skipwhite skipnl
@ -86,7 +87,7 @@ syn match cssMediaComma "," skipwhite skipnl contained
" Reference: http://www.w3.org/TR/css3-mediaqueries/
syn keyword cssMediaProp contained width height orientation scan grid
syn match cssMediaProp contained /\(\(device\)-\)\=aspect-ratio/
syn match cssMediaProp contained /\(\(max\|min\)-\)\=\(\(device\)-\)\=aspect-ratio/
syn match cssMediaProp contained /\(\(max\|min\)-\)\=device-pixel-ratio/
syn match cssMediaProp contained /\(\(max\|min\)-\)\=device-\(height\|width\)/
syn match cssMediaProp contained /\(\(max\|min\)-\)\=\(height\|width\|resolution\|monochrome\|color\(-index\)\=\)/
@ -104,7 +105,7 @@ syn keyword cssPageProp contained orphans widows
" @keyframe
" http://www.w3.org/TR/css3-animations/#keyframes
syn match cssKeyFrame "@\(-[a-z]+-\)\=keyframes\>[^{]*{\@=" nextgroup=cssKeyFrameWrap contains=cssVendor,cssIncludeKeyword skipwhite skipnl transparent
syn match cssKeyFrame "@\(-[a-z]\+-\)\=keyframes\>[^{]*{\@=" nextgroup=cssKeyFrameWrap contains=cssVendor,cssIncludeKeyword skipwhite skipnl transparent
syn region cssKeyFrameWrap contained transparent matchgroup=cssBraces start="{" end="}" contains=cssKeyFrameSelector
syn match cssKeyFrameSelector /\(\d*%\|from\|to\)\=/ contained skipwhite skipnl nextgroup=cssDefinition
@ -116,15 +117,27 @@ syn region cssInclude start=/@namespace\>/ end=/\ze;/ transparent contains=cssSt
" @font-face
" http://www.w3.org/TR/css3-fonts/#at-font-face-rule
syn match cssFontDescriptor "@font-face\>" nextgroup=cssFontDescriptorBlock skipwhite skipnl
syn region cssFontDescriptorBlock contained transparent matchgroup=cssBraces start="{" end="}" contains=cssComment,cssError,cssUnicodeEscape,cssFontProp,cssFontAttr,cssCommonAttr,cssStringQ,cssStringQQ,cssFontDescriptorProp,cssValue.*,cssFontDescriptorFunction,cssUnicodeRange,cssFontDescriptorAttr
"syn match cssFontDescriptorProp contained "\<\(unicode-range\|unit-per-em\|panose-1\|cap-height\|x-height\|definition-src\)\>"
"syn keyword cssFontDescriptorProp contained src stemv stemh slope ascent descent widths bbox baseline centerline mathline topline
syn region cssFontDescriptorBlock contained transparent matchgroup=cssBraces start="{" end="}" contains=cssComment,cssError,cssUnicodeEscape,cssCommonAttr,cssFontDescriptorProp,cssValue.*,cssFontDescriptorFunction,cssFontDescriptorAttr,cssNoise
syn match cssFontDescriptorProp contained "\<font-family\>"
syn keyword cssFontDescriptorProp contained src
syn match cssFontDescriptorProp contained "\<font-\(style\|weight\|stretch\)\>"
syn match cssFontDescriptorProp contained "\<unicode-range\>"
syn keyword cssFontDescriptorAttr contained all
syn match cssFontDescriptorProp contained "\<font-\(variant\|feature-settings\)\>"
" src functions
syn region cssFontDescriptorFunction contained matchgroup=cssFunctionName start="\<\(uri\|url\|local\|format\)\s*(" end=")" contains=cssStringQ,cssStringQQ oneline keepend
syn match cssUnicodeRange contained "U+[0-9A-Fa-f?]\+"
syn match cssUnicodeRange contained "U+\x\+-\x\+"
" font-sytle and font-weight attributes
syn keyword cssFontDescriptorAttr contained normal italic oblique bold
" font-stretch attributes
syn match cssFontDescriptorAttr contained "\<\(\(ultra\|extra\|semi\)-\)\=\(condensed\|expanded\)\>"
" unicode-range attributes
syn match cssFontDescriptorAttr contained "U+[0-9A-Fa-f?]\+"
syn match cssFontDescriptorAttr contained "U+\x\+-\x\+"
" font-feature-settings attributes
syn keyword cssFontDescriptorAttr contained on off
" The 16 basic color names
syn keyword cssColor contained aqua black blue fuchsia gray green lime maroon navy olive purple red silver teal yellow
@ -133,23 +146,23 @@ syn keyword cssColor contained aqua black blue fuchsia gray green lime maroon na
syn keyword cssColor contained aliceblue antiquewhite aquamarine azure
syn keyword cssColor contained beige bisque blanchedalmond blueviolet brown burlywood
syn keyword cssColor contained cadetblue chartreuse chocolate coral cornflowerblue cornsilk crimson cyan
syn match cssColor contained /dark\(blue\|cyan\|goldenrod\|gray\|green\|grey\|khaki\)/
syn match cssColor contained /dark\(magenta\|olivegreen\|orange\|orchid\|red\|salmon\|seagreen\)/
syn match cssColor contained /darkslate\(blue\|gray\|grey\)/
syn match cssColor contained /dark\(turquoise\|violet\)/
syn match cssColor contained /\<dark\(blue\|cyan\|goldenrod\|gray\|green\|grey\|khaki\)\>/
syn match cssColor contained /\<dark\(magenta\|olivegreen\|orange\|orchid\|red\|salmon\|seagreen\)\>/
syn match cssColor contained /\<darkslate\(blue\|gray\|grey\)\>/
syn match cssColor contained /\<dark\(turquoise\|violet\)\>/
syn keyword cssColor contained deeppink deepskyblue dimgray dimgrey dodgerblue firebrick
syn keyword cssColor contained floralwhite forestgreen gainsboro ghostwhite gold
syn keyword cssColor contained goldenrod greenyellow grey honeydew hotpink
syn keyword cssColor contained indianred indigo ivory khaki lavender lavenderblush lawngreen
syn keyword cssColor contained lemonchiffon limegreen linen magenta
syn match cssColor contained /light\(blue\|coral\|cyan\|goldenrodyellow\|gray\|green\)/
syn match cssColor contained /light\(grey\|pink\|salmon\|seagreen\|skyblue\|yellow\)/
syn match cssColor contained /light\(slategray\|slategrey\|steelblue\)/
syn match cssColor contained /medium\(aquamarine\|blue\|orchid\|purple\|seagreen\)/
syn match cssColor contained /medium\(slateblue\|springgreen\|turquoise\|violetred\)/
syn match cssColor contained /\<light\(blue\|coral\|cyan\|goldenrodyellow\|gray\|green\)\>/
syn match cssColor contained /\<light\(grey\|pink\|salmon\|seagreen\|skyblue\|yellow\)\>/
syn match cssColor contained /\<light\(slategray\|slategrey\|steelblue\)\>/
syn match cssColor contained /\<medium\(aquamarine\|blue\|orchid\|purple\|seagreen\)\>/
syn match cssColor contained /\<medium\(slateblue\|springgreen\|turquoise\|violetred\)\>/
syn keyword cssColor contained midnightblue mintcream mistyrose moccasin navajowhite
syn keyword cssColor contained oldlace olivedrab orange orangered orchid
syn match cssColor contained /pale\(goldenrod\|green\|turquoise\|violetred\)/
syn match cssColor contained /\<pale\(goldenrod\|green\|turquoise\|violetred\)\>/
syn keyword cssColor contained papayawhip peachpuff peru pink plum powderblue
syn keyword cssColor contained rosybrown royalblue saddlebrown salmon sandybrown
syn keyword cssColor contained seagreen seashell sienna skyblue slateblue
@ -167,11 +180,12 @@ syn case ignore
syn match cssImportant contained "!\s*important\>"
syn match cssColor contained "\<transparent\>"
syn match cssColor contained "\<currentColor\>"
syn match cssColor contained "\<white\>"
syn match cssColor contained "#[0-9A-Fa-f]\{3\}\>" contains=cssUnitDecorators
syn match cssColor contained "#[0-9A-Fa-f]\{6\}\>" contains=cssUnitDecorators
syn region cssURL contained matchgroup=cssFunctionName start="\<url\s*(" end=")" oneline extend
syn region cssURL contained matchgroup=cssFunctionName start="\<url\s*(" end=")" contains=cssStringQ,cssStringQQ oneline
syn region cssFunction contained matchgroup=cssFunctionName start="\<\(rgb\|clip\|attr\|counter\|rect\|cubic-bezier\|steps\)\s*(" end=")" oneline contains=cssValueInteger,cssValueNumber,cssValueLength,cssFunctionComma
syn region cssFunction contained matchgroup=cssFunctionName start="\<\(rgba\|hsl\|hsla\|color-stop\|from\|to\)\s*(" end=")" oneline contains=cssColor,cssValueInteger,cssValueNumber,cssValueLength,cssFunctionComma,cssFunction
syn region cssFunction contained matchgroup=cssFunctionName start="\<\(linear-\|radial-\)\=\gradient\s*(" end=")" oneline contains=cssColor,cssValueInteger,cssValueNumber,cssValueLength,cssFunction,cssGradientAttr,cssFunctionComma
@ -196,6 +210,9 @@ syn keyword cssAnimationAttr contained forwards backwards both
" animation-play-state attributes
syn keyword cssAnimationAttr contained running paused
" animation-iteration-count attributes
syn keyword cssAnimationAttr contained infinite
"------------------------------------------------
" CSS Backgrounds and Borders Module Level 3
" http://www.w3.org/TR/css3-background/
@ -253,7 +270,7 @@ syn keyword cssDimensionProp contained width
syn match cssFlexibleBoxProp contained "\<box-\(align\|direction\|flex\|ordinal-group\|orient\|pack\|shadow\|sizing\)\>"
syn keyword cssFlexibleBoxAttr contained start end baseline
syn keyword cssFlexibleBoxAttr contained reverse
syn keyword cssFlexibleBoxAttr contained single mulitple
syn keyword cssFlexibleBoxAttr contained single multiple
syn keyword cssFlexibleBoxAttr contained horizontal
syn match cssFlexibleBoxAttr contained "\<vertical\(-align\)\@!\>" "escape vertical-align
syn match cssFlexibleBoxAttr contained "\<\(inline\|block\)-axis\>"
@ -261,6 +278,7 @@ syn match cssFlexibleBoxAttr contained "\<\(inline\|block\)-axis\>"
" CSS Fonts Module Level 3
" http://www.w3.org/TR/css-fonts-3/
syn match cssFontProp contained "\<font\(-\(family\|\|feature-settings\|kerning\|language-override\|size\(-adjust\)\=\|stretch\|style\|synthesis\|variant\(-\(alternates\|caps\|east-asian\|ligatures\|numeric\|position\)\)\=\|weight\)\)\=\>"
" font attributes
syn keyword cssFontAttr contained icon menu caption
syn match cssFontAttr contained "\<small-\(caps\|caption\)\>"
@ -268,27 +286,21 @@ syn match cssFontAttr contained "\<message-box\>"
syn match cssFontAttr contained "\<status-bar\>"
syn keyword cssFontAttr contained larger smaller
syn match cssFontAttr contained "\<\(x\{1,2\}-\)\=\(large\|small\)\>"
" font-family attributes
syn match cssFontAttr contained "\<\(sans-\)\=serif\>"
syn keyword cssFontAttr contained Antiqua Arial Black Book Charcoal Comic Courier Dingbats Gadget Geneva Georgia Grande Helvetica Impact Linotype Lucida MS Monaco Neue New Palatino Roboto Roman Symbol Tahoma Times Trebuchet Unicode Verdana Webdings Wingdings York Zapf
syn keyword cssFontAttr contained Antiqua Arial Black Book Charcoal Comic Courier Dingbats Gadget Geneva Georgia Grande Helvetica Impact Linotype Lucida MS Monaco Neue New Palatino Roboto Roman Symbol Tahoma Times Trebuchet Verdana Webdings Wingdings York Zapf
syn keyword cssFontAttr contained cursive fantasy monospace
" font-feature-settings attributes
syn keyword cssFontAttr contained on off
" font-stretch attributes
syn match cssFontAttr contained "\<\(\(ultra\|extra\|semi\)-\)\=\(condensed\|expanded\)\>"
" font-style attributes
syn keyword cssFontAttr contained italic oblique
" font-variant-caps attributes
syn match cssFontAttr contained "\<\(all-\)\=\(small-\|petite-\|titling-\)caps\>"
syn keyword cssFontAttr contained unicase
" font-synthesis attributes
syn keyword cssFontAttr contained weight style
" font-weight attributes
syn keyword cssFontAttr contained bold bolder lighter
" TODO: font-variant-* attributes
"------------------------------------------------
" Webkit specific property/attributes
@ -448,7 +460,7 @@ syn match cssMobileTextProp contained "\<text-size-adjust\>"
syn match cssBraces contained "[{}]"
syn match cssError contained "{@<>"
syn region cssDefinition transparent matchgroup=cssBraces start='{' end='}' contains=cssAttrRegion,css.*Prop,cssComment,cssValue.*,cssColor,cssURL,cssImportant,cssError,cssStringQ,cssStringQQ,cssFunction,cssUnicodeEscape,cssVendor,cssDefinition,cssHacks keepend fold
syn region cssDefinition transparent matchgroup=cssBraces start='{' end='}' contains=cssAttrRegion,css.*Prop,cssComment,cssValue.*,cssColor,cssURL,cssImportant,cssError,cssStringQ,cssStringQQ,cssFunction,cssUnicodeEscape,cssVendor,cssDefinition,cssHacks,cssNoise fold
syn match cssBraceError "}"
syn match cssAttrComma ","
@ -466,6 +478,9 @@ syn match cssPseudoClassId contained "\<selection\>"
syn match cssPseudoClassId contained "\<focus\(-inner\)\=\>"
syn match cssPseudoClassId contained "\<\(input-\)\=placeholder\>"
" Misc highlight groups
syntax match cssUnitDecorators /\(#\|-\|%\|mm\|cm\|in\|pt\|pc\|em\|ex\|px\|ch\|rem\|vh\|vw\|vmin\|vmax\|dpi\|dppx\|dpcm\|Hz\|kHz\|s\|ms\|deg\|grad\|rad\)/ contained
syntax match cssNoise contained /\(:\|;\|\/\)/
" Comment
syn region cssComment start="/\*" end="\*/" contains=@Spell fold
@ -487,17 +502,13 @@ syn match cssVendor contained "\(-\(webkit\|moz\|o\|ms\)-\)"
" http://www.paulirish.com/2009/browser-specific-css-hacks/
syn match cssHacks contained /\(_\|*\)/
" Misc highlight groups
syntax match cssUnitDecorators /\(#\|-\|%\|mm\|cm\|in\|pt\|pc\|em\|ex\|px\|rem\|dpi\|dppx\|dpcm\|Hz\|kHz\|s\|ms\|deg\|grad\|rad\)/ contained
syntax match cssNoise contained /\(:\|;\|\/\)/
" Attr Enhance
" Some keywords are both Prop and Attr, so we have to handle them
syn region cssAttrRegion start=/:/ end=/;/ contained keepend contains=css.*Attr,cssColor,cssImportant,cssValue.*,cssFunction,cssString.*,cssURL,cssComment,cssUnicodeEscape,cssVendor,cssError,cssAttrComma,cssNoise
syn region cssAttrRegion start=/:/ end=/\ze\(;\|)\|}\)/ contained contains=css.*Attr,cssColor,cssImportant,cssValue.*,cssFunction,cssString.*,cssURL,cssComment,cssUnicodeEscape,cssVendor,cssError,cssAttrComma,cssNoise
" Hack for transition
" The 'transition' Prop has Props after ':'.
syn region cssAttrRegion start=/transition\s*:/ end=/;/ contained keepend contains=css.*Prop,css.*Attr,cssColor,cssImportant,cssValue.*,cssFunction,cssString.*,cssURL,cssComment,cssUnicodeEscape,cssVendor,cssError,cssAttrComma,cssNoise
" 'transition' has Props after ':'.
syn region cssAttrRegion start=/transition\s*:/ end=/\ze\(;\|)\|}\)/ contained contains=css.*Prop,css.*Attr,cssColor,cssImportant,cssValue.*,cssFunction,cssString.*,cssURL,cssComment,cssUnicodeEscape,cssVendor,cssError,cssAttrComma,cssNoise
if main_syntax == "css"
@ -635,7 +646,7 @@ if version >= 508 || !exists("did_css_syn_inits")
HiLink cssAttr Constant
HiLink cssUnitDecorators Number
HiLink cssNoise Noise
HiLink atKeyword Comment
HiLink atKeyword PreProc
delcommand HiLink
endif

View File

@ -1,9 +1,9 @@
" Vim syntax file
" Language: DCL (Digital Command Language - vms)
" Maintainer: Dr. Charles E. Campbell, Jr. <NdrOchipS@PcampbellAfamily.Mbiz>
" Last Change: Sep 11, 2006
" Version: 6
" URL: http://mysite.verizon.net/astronaut/vim/index.html#vimlinks_syntax
" Maintainer: Charles E. Campbell <NdrOchipS@PcampbellAfamily.Mbiz>
" Last Change: Oct 23, 2014
" Version: 7
" URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_DCL
" For version 5.x: Clear all syntax items
" For version 6.x: Quit when a syntax file was already loaded

View File

@ -3,7 +3,7 @@
" Maintainer: Debian Vim Maintainers <pkg-vim-maintainers@lists.alioth.debian.org>
" Former Maintainers: Gerfried Fuchs <alfie@ist.org>
" Wichert Akkerman <wakkerma@debian.org>
" Last Change: 2014 Jul 11
" Last Change: 2015 Apr 30
" URL: http://anonscm.debian.org/hg/pkg-vim/vim/raw-file/unstable/runtime/syntax/debchangelog.vim
" Standard syntax initialization
@ -16,10 +16,14 @@ endif
" Case doesn't matter for us
syn case ignore
let urgency='urgency=\(low\|medium\|high\|critical\)\( [^[:space:],][^,]*\)\='
let binNMU='binary-only=yes'
" Define some common expressions we can use later on
syn match debchangelogName contained "^[[:alnum:]][[:alnum:].+-]\+ "
syn match debchangelogUrgency contained "; urgency=\(low\|medium\|high\|critical\|emergency\)\( \S.*\)\="
syn match debchangelogTarget contained "\v %(frozen|unstable|%(testing|%(old)=stable)%(-proposed-updates|-security)=|experimental|squeeze-%(backports%(-sloppy)=|volatile)|wheezy-backports|%(devel|lucid|precise|trusty|utopic)%(-%(security|proposed|updates|backports|commercial|partner))=)+"
exe 'syn match debchangelogFirstKV contained "; \('.urgency.'\|'.binNMU.'\)"'
exe 'syn match debchangelogOtherKV contained ", \('.urgency.'\|'.binNMU.'\)"'
syn match debchangelogTarget contained "\v %(frozen|unstable|sid|%(testing|%(old)=stable)%(-proposed-updates|-security)=|experimental|squeeze-%(backports%(-sloppy)=|volatile|lts|security)|wheezy-%(backports%(-sloppy)=|security)|jessie%(-backports|-security)=|stretch|%(devel|lucid|precise|trusty|utopic)%(-%(security|proposed|updates|backports|commercial|partner))=)+"
syn match debchangelogVersion contained "(.\{-})"
syn match debchangelogCloses contained "closes:\_s*\(bug\)\=#\=\_s\=\d\+\(,\_s*\(bug\)\=#\=\_s\=\d\+\)*"
syn match debchangelogLP contained "\clp:\s\+#\d\+\(,\s*#\d\+\)*"
@ -27,7 +31,7 @@ syn match debchangelogEmail contained "[_=[:alnum:].+-]\+@[[:alnum:]./\-]\+"
syn match debchangelogEmail contained "<.\{-}>"
" Define the entries that make up the changelog
syn region debchangelogHeader start="^[^ ]" end="$" contains=debchangelogName,debchangelogUrgency,debchangelogTarget,debchangelogVersion oneline
syn region debchangelogHeader start="^[^ ]" end="$" contains=debchangelogName,debchangelogFirstKV,debchangelogOtherKV,debchangelogTarget,debchangelogVersion,debchangelogBinNMU oneline
syn region debchangelogFooter start="^ [^ ]" end="$" contains=debchangelogEmail oneline
syn region debchangelogEntry start="^ " end="$" contains=debchangelogCloses,debchangelogLP oneline
@ -45,7 +49,8 @@ if version >= 508 || !exists("did_debchangelog_syn_inits")
HiLink debchangelogEntry Normal
HiLink debchangelogCloses Statement
HiLink debchangelogLP Statement
HiLink debchangelogUrgency Identifier
HiLink debchangelogFirstKV Identifier
HiLink debchangelogOtherKV Identifier
HiLink debchangelogName Comment
HiLink debchangelogVersion Identifier
HiLink debchangelogTarget Identifier

View File

@ -3,7 +3,7 @@
" Maintainer: Debian Vim Maintainers <pkg-vim-maintainers@lists.alioth.debian.org>
" Former Maintainers: Gerfried Fuchs <alfie@ist.org>
" Wichert Akkerman <wakkerma@debian.org>
" Last Change: 2014 May 01
" Last Change: 2014 Oct 08
" URL: http://anonscm.debian.org/hg/pkg-vim/vim/raw-file/unstable/runtime/syntax/debcontrol.vim
" Standard syntax initialization
@ -50,7 +50,7 @@ syn match debcontrolDmUpload contained "\cyes"
syn match debcontrolHTTPUrl contained "\vhttps?://[[:alnum:]][-[:alnum:]]*[[:alnum:]]?(\.[[:alnum:]][-[:alnum:]]*[[:alnum:]]?)*\.[[:alpha:]][-[:alnum:]]*[[:alpha:]]?(:\d+)?(/[^[:space:]]*)?$"
syn match debcontrolVcsSvn contained "\vsvn%(\+ssh)?://[[:alnum:]][-[:alnum:]]*[[:alnum:]]?(\.[[:alnum:]][-[:alnum:]]*[[:alnum:]]?)*\.[[:alpha:]][-[:alnum:]]*[[:alpha:]]?(:\d+)?(/[^[:space:]]*)?$"
syn match debcontrolVcsCvs contained "\v%(\-d *)?:pserver:[^@]+\@[[:alnum:]][-[:alnum:]]*[[:alnum:]]?(\.[[:alnum:]][-[:alnum:]]*[[:alnum:]]?)*\.[[:alpha:]][-[:alnum:]]*[[:alpha:]]?:/[^[:space:]]*%( [^[:space:]]+)?$"
syn match debcontrolVcsGit contained "\v%(git|http)://[[:alnum:]][-[:alnum:]]*[[:alnum:]]?(\.[[:alnum:]][-[:alnum:]]*[[:alnum:]]?)*\.[[:alpha:]][-[:alnum:]]*[[:alpha:]]?(:\d+)?(/[^[:space:]]*)?%(\s+-b\s+[^ ~^:?*[\\]+)?$"
syn match debcontrolVcsGit contained "\v%(git|https?)://[[:alnum:]][-[:alnum:]]*[[:alnum:]]?(\.[[:alnum:]][-[:alnum:]]*[[:alnum:]]?)*\.[[:alpha:]][-[:alnum:]]*[[:alpha:]]?(:\d+)?(/[^[:space:]]*)?%(\s+-b\s+[^ ~^:?*[\\]+)?$"
" An email address
syn match debcontrolEmail "[_=[:alnum:]\.+-]\+@[[:alnum:]\./\-]\+"

View File

@ -2,7 +2,7 @@
" Language: Debian sources.list
" Maintainer: Debian Vim Maintainers <pkg-vim-maintainers@lists.alioth.debian.org>
" Former Maintainer: Matthijs Mohlmann <matthijs@cacholong.nl>
" Last Change: 2014 Jul 11
" Last Change: 2015 May 25
" URL: http://anonscm.debian.org/hg/pkg-vim/vim/raw-file/unstable/runtime/syntax/debsources.vim
" Standard syntax initialization
@ -21,15 +21,35 @@ syn match debsourcesKeyword /\(deb-src\|deb\|main\|contrib\|non-free\|res
" Match comments
syn match debsourcesComment /#.*/ contains=@Spell
let s:cpo = &cpo
set cpo-=C
let s:supported = [
\ 'oldstable', 'stable', 'testing', 'unstable', 'experimental',
\ 'squeeze', 'wheezy', 'jessie', 'stretch', 'sid', 'rc-buggy',
\
\ 'precise', 'trusty', 'utopic', 'vivid', 'wily', 'devel'
\ ]
let s:unsupported = [
\ 'buzz', 'rex', 'bo', 'hamm', 'slink', 'potato',
\ 'woody', 'sarge', 'etch', 'lenny',
\
\ 'warty', 'hoary', 'breezy', 'dapper', 'edgy', 'feisty',
\ 'gutsy', 'hardy', 'intrepid', 'jaunty', 'karmic', 'lucid',
\ 'maverick', 'natty', 'oneiric', 'quantal', 'raring', 'saucy'
\ ]
let &cpo=s:cpo
" Match uri's
syn match debsourcesUri +\(http://\|ftp://\|[rs]sh://\|debtorrent://\|\(cdrom\|copy\|file\):\)[^' <>"]\++
syn match debsourcesDistrKeyword +\([[:alnum:]_./]*\)\(squeeze\|wheezy\|jessie\|\(old\)\=stable\|testing\|unstable\|sid\|rc-buggy\|experimental\|devel\|lucid\|precise\|trusty\|utopic\)\([-[:alnum:]_./]*\)+
exe 'syn match debsourcesDistrKeyword +\([[:alnum:]_./]*\)\('. join(s:supported, '\|'). '\)\([-[:alnum:]_./]*\)+'
exe 'syn match debsourcesUnsupportedDistrKeyword +\([[:alnum:]_./]*\)\('. join(s:unsupported, '\|') .'\)\([-[:alnum:]_./]*\)+'
" Associate our matches and regions with pretty colours
hi def link debsourcesLine Error
hi def link debsourcesKeyword Statement
hi def link debsourcesDistrKeyword Type
hi def link debsourcesComment Comment
hi def link debsourcesUri Constant
hi def link debsourcesLine Error
hi def link debsourcesKeyword Statement
hi def link debsourcesDistrKeyword Type
hi def link debsourcesUnsupportedDistrKeyword WarningMsg
hi def link debsourcesComment Comment
hi def link debsourcesUri Constant
let b:current_syntax = "debsources"

View File

@ -2,7 +2,7 @@
" Language: Diff (context or unified)
" Maintainer: Bram Moolenaar <Bram@vim.org>
" Translations by Jakson Alves de Aquino.
" Last Change: 2014 Nov 12
" Last Change: 2015 Feb 03
" Quit when a (custom) syntax file was already loaded
if exists("b:current_syntax")
@ -18,6 +18,9 @@ syn match diffIsA "^File .* is a .* while file .* is a .*"
syn match diffNoEOL "^\\ No newline at end of file .*"
syn match diffCommon "^Common subdirectories: .*"
" Disable the translations by setting diff_translations to zero.
if !exists("diff_translations") || diff_translations
" ca
syn match diffOnly "^Només a .*"
syn match diffIdentical "^Els fitxers .* i .* són idèntics$"
@ -120,13 +123,17 @@ syn match diffNoEOL "^\\ Non hai un salto de liña na fin da liña"
syn match diffCommon "^Subdirectorios comúns: .* e .*"
" he
syn match diffOnly "^.*-ב קר אצמנ .*"
syn match diffIdentical "^םיהז םניה .*-ו .* םיצבקה$"
syn match diffDiffer "^הזמ הז םינוש `.*'-ו `.*' םיצבקה$"
syn match diffBDiffer "^הזמ הז םינוש `.*'-ו `.*' םיירניב םיצבק$"
syn match diffIsA "^.* .*-ל .* .* תוושהל ןתינ אל$"
syn match diffNoEOL "^\\ ץבוקה ףוסב השד.-הרוש ות רס."
syn match diffCommon "^.*-ו .* :תוהז תויקית-תת$"
" ^.* are expansive patterns for long lines, so disabled unless we can match
" some specific hebrew chars
if search('\%u05d5\|\%u05d1', 'nw', '', 100)
syn match diffOnly "^.*-ב קר אצמנ .*"
syn match diffIdentical "^םיהז םניה .*-ו .* םיצבקה$"
syn match diffDiffer "^הזמ הז םינוש `.*'-ו `.*' םיצבקה$"
syn match diffBDiffer "^הזמ הז םינוש `.*'-ו `.*' םיירניב םיצבק$"
syn match diffIsA "^.* .*-ל .* .* תוושהל ןתינ אל$"
syn match diffNoEOL "^\\ ץבוקה ףוסב השד.-הרוש ות רס."
syn match diffCommon "^.*-ו .* :תוהז תויקית-תת$"
endif
" hr
syn match diffOnly "^Samo u .*"
@ -320,6 +327,8 @@ syn match diffIsA "^檔案 .* 是.*而檔案 .* 是.*"
syn match diffNoEOL "^\\ 檔案末沒有 newline 字元"
syn match diffCommon "^.* 和 .* 有共同的副目錄$"
endif
syn match diffRemoved "^-.*"
syn match diffRemoved "^<.*"

View File

@ -1,9 +1,9 @@
" Vim syntax file
" Language: Elm Filter rules
" Maintainer: Dr. Charles E. Campbell, Jr. <NdrOchipS@PcampbellAfamily.Mbiz>
" Last Change: Sep 11, 2006
" Version: 5
" URL: http://mysite.verizon.net/astronaut/vim/index.html#vimlinks_syntax
" Maintainer: Charles E. Campbell <NdrOchipS@PcampbellAfamily.Mbiz>
" Last Change: Oct 23, 2014
" Version: 6
" URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_ELMFILT
" For version 5.x: Clear all syntax items
" For version 6.x: Quit when a syntax file was already loaded

View File

@ -1,10 +1,10 @@
" Vim syntax file
" Language: exports
" Maintainer: Dr. Charles E. Campbell, Jr. <NdrOchipS@PcampbellAfamily.Mbiz>
" Last Change: Sep 06, 2005
" Version: 4
" Maintainer: Charles E. Campbell <NdrOchipS@PcampbellAfamily.Mbiz>
" Last Change: Oct 23, 2014
" Version: 5
" Notes: This file includes both SysV and BSD 'isms
" URL: http://mysite.verizon.net/astronaut/vim/index.html#vimlinks_syntax
" URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_EXPORTS
" For version 5.x: Clear all syntax items
" For version 6.x: Quit when a syntax file was already loaded

View File

@ -1,15 +1,15 @@
" Vim syntax file
" Language: Fortran 2008 (and earlier versions: 2003, 95, 90, and 77)
" Version: 0.94
" Last Change: 2012 June 18
" Maintainer: Ajit J. Thakkar (ajit AT unb.ca); <http://www.unb.ca/chem/ajit/>
" Version: 0.95
" Last Change: 2015 Jan. 15
" Maintainer: Ajit J. Thakkar <ajit@unb.ca>; <http://www2.unb.ca/~ajit/>
" Usage: For instructions, do :help fortran-syntax from Vim
" Credits:
" Version 0.1 was based on the fortran 77 syntax file by Mario Eusebio and
" Preben Guldberg. Useful suggestions were made by: Andrej Panjkov,
" Bram Moolenaar, Thomas Olsen, Michael Sternberg, Christian Reile,
" Walter Dieudonn<6E>, Alexander Wagner, Roman Bertle, Charles Rendleman,
" Andrew Griffiths, Joe Krahn, and Hendrik Merx.
" Andrew Griffiths, Joe Krahn, Hendrik Merx, and Matt Thompson.
if exists("b:current_syntax")
finish
@ -298,6 +298,41 @@ if b:fortran_dialect == "f08"
syn keyword fortranIntrinsic bge bgt ble blt dshiftl dshiftr findloc iall iany iparity image_index lcobound ucobound maskl maskr num_images parity popcnt poppar shifta shiftl shiftr this_image
syn keyword fortranIO newunit
syn keyword fortranType contiguous
" CUDA fortran
syn match fortranTypeCUDA "\<attributes\>"
syn keyword fortranTypeCUDA host global device value
syn keyword fortranTypeCUDA shared constant pinned texture
syn keyword fortranTypeCUDA dim1 dim2 dim3 dim4
syn keyword fortranTypeCUDA cudadeviceprop cuda_count_kind cuda_stream_kind
syn keyword fortranTypeCUDA cudaEvent cudaFuncAttributes cudaArrayPtr
syn keyword fortranTypeCUDA cudaSymbol cudaChannelFormatDesc cudaPitchedPtr
syn keyword fortranTypeCUDA cudaExtent cudaMemcpy3DParms
syn keyword fortranTypeCUDA cudaFuncCachePreferNone cudaFuncCachePreferShared
syn keyword fortranTypeCUDA cudaFuncCachePreferL1 cudaLimitStackSize
syn keyword fortranTypeCUDA cudaLimitPrintfSize cudaLimitMallocHeapSize
syn keyword fortranTypeCUDA cudaSharedMemBankSizeDefault cudaSharedMemBankSizeFourByte cudaSharedMemBankSizeEightByte
syn keyword fortranTypeCUDA cudaEventDefault cudaEventBlockingSync cudaEventDisableTiming
syn keyword fortranTypeCUDA cudaMemcpyHostToDevice cudaMemcpyDeviceToHost
syn keyword fortranTypeCUDA cudaMemcpyDeviceToDevice
syn keyword fortranTypeCUDA cudaErrorNotReady cudaSuccess cudaErrorInvalidValue
syn keyword fortranTypeCUDA c_devptr
syn match fortranStringCUDA "blockidx%[xyz]"
syn match fortranStringCUDA "blockdim%[xyz]"
syn match fortranStringCUDA "griddim%[xyz]"
syn match fortranStringCUDA "threadidx%[xyz]"
syn keyword fortranIntrinsicCUDA warpsize syncthreads syncthreads_and syncthreads_count syncthreads_or threadfence threadfence_block threadfence_system gpu_time allthreads anythread ballot
syn keyword fortranIntrinsicCUDA atomicadd atomicsub atomicmax atomicmin atomicand atomicor atomicxor atomicexch atomicinc atomicdec atomiccas sizeof __shfl __shfl_up __shfl_down __shfl_xor
syn keyword fortranIntrinsicCUDA cudaChooseDevice cudaDeviceGetCacheConfig cudaDeviceGetLimit cudaDeviceGetSharedMemConfig cudaDeviceReset cudaDeviceSetCacheConfig cudaDeviceSetLimit cudaDeviceSetSharedMemConfig cudaDeviceSynchronize cudaGetDevice cudaGetDeviceCount cudaGetDeviceProperties cudaSetDevice cudaSetDeviceFlags cudaSetValidDevices
syn keyword fortranIntrinsicCUDA cudaThreadExit cudaThreadSynchronize cudaGetLastError cudaGetErrorString cudaPeekAtLastError cudaStreamCreate cudaStreamDestroy cudaStreamQuery cudaStreamSynchronize cudaStreamWaitEvent cudaEventCreate cudaEventCreateWithFlags cudaEventDestroy cudaEventElapsedTime cudaEventQuery cudaEventRecord cudaEventSynchronize
syn keyword fortranIntrinsicCUDA cudaFuncGetAttributes cudaFuncSetCacheConfig cudaFuncSetSharedMemConfig cudaSetDoubleForDevice cudaSetDoubleForHost cudaFree cudaFreeArray cudaFreeHost cudaGetSymbolAddress cudaGetSymbolSize
syn keyword fortranIntrinsicCUDA cudaHostAlloc cudaHostGetDevicePointer cudaHostGetFlags cudaHostRegister cudaHostUnregister cudaMalloc cudaMallocArray cudaMallocHost cudaMallocPitch cudaMalloc3D cudaMalloc3DArray
syn keyword fortranIntrinsicCUDA cudaMemcpy cudaMemcpyArraytoArray cudaMemcpyAsync cudaMemcpyFromArray cudaMemcpyFromSymbol cudaMemcpyFromSymbolAsync cudaMemcpyPeer cudaMemcpyPeerAsync cudaMemcpyToArray cudaMemcpyToSymbol cudaMemcpyToSymbolAsync cudaMemcpy2D cudaMemcpy2DArrayToArray cudaMemcpy2DAsync cudaMemcpy2DFromArray cudaMemcpy2DToArray cudaMemcpy3D cudaMemcpy3DAsync
syn keyword fortranIntrinsicCUDA cudaMemGetInfo cudaMemset cudaMemset2D cudaMemset3D cudaDeviceCanAccessPeer cudaDeviceDisablePeerAccess cudaDeviceEnablePeerAccess cudaPointerGetAttributes cudaDriverGetVersion cudaRuntimeGetVersion
syn region none matchgroup=fortranType start="<<<" end=">>>" contains=ALLBUT,none
endif
syn cluster fortranCommentGroup contains=fortranTodo
@ -453,6 +488,11 @@ else
hi! def link fortranConditionalR fortranConditional
endif
" CUDA
hi def link fortranIntrinsicCUDA fortranIntrinsic
hi def link fortranTypeCUDA fortranType
hi def link fortranStringCUDA fortranString
hi def link fortranFormatSpec Identifier
hi def link fortranFloat Float
hi def link fortranPreCondit PreCondit

View File

@ -2,9 +2,9 @@
" Language: Groovy
" Original Author: Alessio Pace <billy.corgan@tiscali.it>
" Maintainer: Tobias Rapp <yahuxo@gmx.de>
" Version: 0.1.13
" Version: 0.1.14
" URL: http://www.vim.org/scripts/script.php?script_id=945
" Last Change: 2013 Apr 24
" Last Change: 2015 Apr 21
" THE ORIGINAL AUTHOR'S NOTES:
"
@ -157,7 +157,7 @@ syn match groovyOperator "\.\."
syn match groovyOperator "<\{2,3}"
syn match groovyOperator ">\{2,3}"
syn match groovyOperator "->"
syn match groovyExternal '^#!.*[/\\]groovy\>'
syn match groovyLineComment '^\%1l#!.*' " Shebang line
syn match groovyExceptions "\<Exception\>\|\<[A-Z]\{1,}[a-zA-Z0-9]*Exception\>"
" Groovy JDK stuff
@ -220,7 +220,6 @@ syn region groovyComment start="/\*" end="\*/" contains=@groovyCommen
syn match groovyCommentStar contained "^\s*\*[^/]"me=e-1
syn match groovyCommentStar contained "^\s*\*$"
syn match groovyLineComment "//.*" contains=@groovyCommentSpecial2,groovyTodo,@Spell
syn match groovyLineComment "#.*" contains=@groovyCommentSpecial2,groovyTodo,@Spell
GroovyHiLink groovyCommentString groovyString
GroovyHiLink groovyComment2String groovyString
GroovyHiLink groovyCommentCharacter groovyCharacter

View File

@ -1,7 +1,29 @@
" Vim syntax file
" Language: Intel hex MCS51
" Maintainer: Sams Ricahrd <sams@ping.at>
" Last Change: 2003 Apr 25
" Language: Intel HEX
" Maintainer: Markus Heidelberg <markus.heidelberg@web.de>
" Previous version: Sams Ricahrd <sams@ping.at>
" Last Change: 2015 Feb 24
" Each record (line) is built as follows:
"
" field digits states
"
" +----------+
" | start | 1 (':') hexRecStart
" +----------+
" | count | 2 hexDataByteCount
" +----------+
" | address | 4 hexNoAddress, hexDataAddress, (hexAddressFieldUnknown)
" +----------+
" | type | 2 hexRecType, (hexRecTypeUnknown)
" +----------+
" | data | 0..510 hexDataOdd, hexDataEven, hexExtendedAddress, hexStartAddress, (hexDataFieldUnknown, hexDataUnexpected)
" +----------+
" | checksum | 2 hexChecksum
" +----------+
"
" States in parentheses in the upper format description indicate that they
" should not appear in a valid file.
" For version 5.x: Clear all syntax items
" For version 6.x: Quit when a syntax file was already loaded
@ -11,21 +33,39 @@ elseif exists("b:current_syntax")
finish
endif
syn case ignore
syn match hexRecStart "^:"
" storage types
syn match hexDataByteCount "^:[0-9a-fA-F]\{2}" contains=hexRecStart nextgroup=hexAddress
syn match hexChecksum "[0-9a-fA-F]\{2}$"
syn match hexAdress "^:[0-9a-fA-F]\{6}" contains=hexDataByteCount
syn match hexRecType "^:[0-9a-fA-F]\{8}" contains=hexAdress
syn match hexDataByteCount contained "^:[0-9a-fA-F]\{2}" contains=hexStart
syn match hexStart contained "^:"
syn match hexExtAdrRec "^:02000002[0-9a-fA-F]\{4}" contains=hexSpecRec
syn match hexExtLinAdrRec "^:02000004[0-9a-fA-F]\{4}" contains=hexSpecRec
syn match hexSpecRec contained "^:0[02]00000[124]" contains=hexStart
syn match hexEOF "^:00000001" contains=hexStart
syn match hexAddress "[0-9a-fA-F]\{4}" transparent contained nextgroup=hexRecTypeUnknown,hexRecType
" The address field groups include the record type field in the last 2
" characters, the proper match for highlighting follows below.
syn match hexAddressFieldUnknown "^:[0-9a-fA-F]\{8}" contains=hexDataByteCount nextgroup=hexDataFieldUnknown,hexChecksum
syn match hexDataAddress "^:[0-9a-fA-F]\{6}00" contains=hexDataByteCount nextgroup=hexDataOdd,hexChecksum
syn match hexNoAddress "^:[0-9a-fA-F]\{6}01" contains=hexDataByteCount nextgroup=hexDataUnexpected,hexChecksum
syn match hexNoAddress "^:[0-9a-fA-F]\{6}0[24]" contains=hexDataByteCount nextgroup=hexExtendedAddress
syn match hexNoAddress "^:[0-9a-fA-F]\{6}0[35]" contains=hexDataByteCount nextgroup=hexStartAddress
syn case match
syn match hexRecTypeUnknown "[0-9a-fA-F]\{2}" contained
syn match hexRecType "0[0-5]" contained
syn match hexDataFieldUnknown "[0-9a-fA-F]\{2}" contained nextgroup=hexDataFieldUnknown,hexChecksum
" alternating highlight per byte for easier reading
syn match hexDataOdd "[0-9a-fA-F]\{2}" contained nextgroup=hexDataEven,hexChecksum
syn match hexDataEven "[0-9a-fA-F]\{2}" contained nextgroup=hexDataOdd,hexChecksum
" data bytes which should not exist
syn match hexDataUnexpected "[0-9a-fA-F]\{2}" contained nextgroup=hexDataUnexpected,hexChecksum
" Data digit pair regex usage also results in only highlighting the checksum
" if the number of data characters is even.
" special data fields
syn match hexExtendedAddress "[0-9a-fA-F]\{4}" contained nextgroup=hexDataUnexpected,hexChecksum
syn match hexStartAddress "[0-9a-fA-F]\{8}" contained nextgroup=hexDataUnexpected,hexChecksum
syn match hexChecksum "[0-9a-fA-F]\{2}$" contained
" Folding Data Records below an Extended Segment/Linear Address Record
syn region hexExtAdrBlock start="^:[0-9a-fA-F]\{7}[24]" skip="^:[0-9a-fA-F]\{7}0" end="^:"me=s-1 fold transparent
" Define the default highlighting.
" For version 5.7 and earlier: only when not done already
@ -38,16 +78,21 @@ if version >= 508 || !exists("did_hex_syntax_inits")
command -nargs=+ HiLink hi def link <args>
endif
" The default methods for highlighting. Can be overridden later
HiLink hexStart SpecialKey
HiLink hexDataByteCount Constant
HiLink hexAdress Comment
HiLink hexRecType WarningMsg
HiLink hexChecksum Search
HiLink hexExtAdrRec hexAdress
HiLink hexEOF hexSpecRec
HiLink hexExtLinAdrRec hexAdress
HiLink hexSpecRec DiffAdd
" The default methods for highlighting. Can be overridden later
HiLink hexRecStart hexRecType
HiLink hexDataByteCount Constant
hi def hexAddressFieldUnknown term=italic cterm=italic gui=italic
HiLink hexDataAddress Comment
HiLink hexNoAddress DiffAdd
HiLink hexRecTypeUnknown hexRecType
HiLink hexRecType WarningMsg
hi def hexDataFieldUnknown term=italic cterm=italic gui=italic
hi def hexDataOdd term=bold cterm=bold gui=bold
hi def hexDataEven term=NONE cterm=NONE gui=NONE
HiLink hexDataUnexpected Error
HiLink hexExtendedAddress hexDataAddress
HiLink hexStartAddress hexDataAddress
HiLink hexChecksum DiffChange
delcommand HiLink
endif

View File

@ -2,7 +2,8 @@
" Language: HTML
" Maintainer: Claudio Fleiner <claudio@fleiner.com>
" URL: http://www.fleiner.com/vim/syntax/html.vim
" Last Change: 2012 Oct 05
" Last Change: 2015 Jan 07
" included patch from David Felix
" Please check :help html.vim for some comments and a description of the options
@ -168,7 +169,7 @@ if main_syntax != 'java' || exists("java_javascript")
" JAVA SCRIPT
syn include @htmlJavaScript syntax/javascript.vim
unlet b:current_syntax
syn region javaScript start=+<script\_[^>]*>+ keepend end=+</script>+me=s-1 contains=@htmlJavaScript,htmlCssStyleComment,htmlScriptTag,@htmlPreproc
syn region javaScript start=+<script\_[^>]*>+ keepend end=+</script\_[^>]*>+me=s-1 contains=@htmlJavaScript,htmlCssStyleComment,htmlScriptTag,@htmlPreproc
syn region htmlScriptTag contained start=+<script+ end=+>+ fold contains=htmlTagN,htmlString,htmlArg,htmlValue,htmlTagError,htmlEvent
HtmlHiLink htmlScriptTag htmlTag
@ -193,7 +194,7 @@ if main_syntax != 'java' || exists("java_vb")
" VB SCRIPT
syn include @htmlVbScript syntax/vb.vim
unlet b:current_syntax
syn region javaScript start=+<script \_[^>]*language *=\_[^>]*vbscript\_[^>]*>+ keepend end=+</script>+me=s-1 contains=@htmlVbScript,htmlCssStyleComment,htmlScriptTag,@htmlPreproc
syn region javaScript start=+<script \_[^>]*language *=\_[^>]*vbscript\_[^>]*>+ keepend end=+</script\_[^>]*>+me=s-1 contains=@htmlVbScript,htmlCssStyleComment,htmlScriptTag,@htmlPreproc
endif
syn cluster htmlJavaScript add=@htmlPreproc

View File

@ -2,7 +2,7 @@
" Language: J
" Maintainer: David Bürgin <676c7473@gmail.com>
" URL: https://github.com/glts/vim-j
" Last Change: 2014-10-05
" Last Change: 2015-01-11
if exists('b:current_syntax')
finish
@ -23,12 +23,12 @@ syntax match jControl /\<\%(for\|goto\|label\)_\a\k*\./
" Standard library names. A few names need to be defined with ":syntax match"
" because they would otherwise take precedence over the corresponding jControl
" and jDefineExpression items.
syntax keyword jStdlibNoun ARGV BINPATH CR CRLF DEL Debug EAV EMPTY FF FHS IF64 IFIOS IFJCDROID IFJHS IFQT IFRASPI IFUNIX IFWIN IFWINCE IFWINE IFWOW64 JB01 JBOXED JCHAR JCMPX JFL JINT JPTR JSIZES JSTR JTYPES JVERSION LF LF2 TAB UNAME UNXLIB andurl dbhelp libjqt
syntax keyword jStdlibAdverb define each every fapplylines inv inverse items leaf rows table
syntax keyword jStdlibNoun ARGV BINPATH CR CRLF DEL Debug EAV EMPTY FF FHS IF64 IFIOS IFJCDROID IFJHS IFQT IFRASPI IFUNIX IFWIN IFWINCE IFWINE IFWOW64 JB01 JBOXED JCHAR JCMPX JFL JINT JPTR JSIZES JSTR JTYPES JVERSION LF LF2 TAB UNAME UNXLIB dbhelp libjqt
syntax keyword jStdlibAdverb define each every fapplylines inv inverse items leaf rows rxapply rxmerge table
syntax keyword jStdlibConjunction bind cuts def on
syntax keyword jStdlibVerb AND Endian IFDEF Note OR XOR alpha17 alpha27 anddf android_exec_host andunzip apply boxopen boxxopen bx calendar cd cdcb cder cderx cdf charsub chopstring clear coclass cocreate cocurrent codestroy coerase cofind cofindv cofullname coinfo coinsert coname conames conew conl conouns conounsx copath copathnl copathnlx coreset costate cut cutLF cutopen cutpara datatype dbctx dberm dberr dbg dbjmp dblocals dblxq dblxs dbnxt dbq dbr dbret dbrr dbrrx dbrun dbs dbsig dbsq dbss dbst dbstack dbstk dbstop dbstopme dbstopnext dbstops dbtrace dbview deb debc delstring detab dfh dir dircompare dircompares dirfind dirpath dirss dirssrplc dirtree dirused dlb dltb dltbs dquote drop dropafter dropto dtb dtbs echo empty endian erase evtloop exit expand f2utf8 fappend fappends fboxname fc fcopynew fdir ferase fetch fexist fexists fgets file2url fixdotdot fliprgb fmakex foldpara foldtext fpathcreate fpathname fputs fread freadblock freadr freads frename freplace fsize fss fssrplc fstamp fstringreplace ftype fview fwrite fwritenew fwrites getargs getdate getenv getqtbin hfd hostpathsep ic install iospath isatty isotimestamp isutf8 jcwdpath joinstring jpathsep jsystemdefs list ljust load loadd mema memf memr memw nameclass namelist names nc nl pick quote require rjust rplc script scriptd setbreak show sign sminfo smoutput sort split splitnostring splitstring ss startupandroid startupconsole startupide stderr stdin stdout stringreplace symdat symget symset take takeafter taketo timespacex timestamp timex tmoutput toCRLF toHOST toJ todate todayno tolower topara toupper tsdiff tsrep tstamp type ucp ucpcount unxlib usleep utf8 uucp valdate wcsize weekday weeknumber weeksinyear winpathsep
syntax keyword jStdlibVerb AND Endian IFDEF OR XOR anddf android_exec_am android_exec_host andunzip apply boxopen boxxopen bx calendar cd cdcb cder cderx cdf charsub chopstring cleartags clear coclass cocreate cocurrent codestroy coerase cofind cofindv cofullname coinfo coinsert compare coname conames conew conl conouns conounsx copath copathnl copathnlx coreset costate cut cutLF cutopen cutpara datatype dbctx dberm dberr dbg dbjmp dblocals dblxq dblxs dbnxt dbq dbr dbret dbrr dbrrx dbrun dbs dbsig dbsq dbss dbst dbstack dbstk dbstop dbstopme dbstopnext dbstops dbtrace dbview deb debc delstring detab dfh dir dircompare dircompares dirfind dirpath dirss dirssrplc dirtree dirused dlb dltb dltbs dquote drop dropafter dropto dtb dtbs echo empty endian erase evtloop exit expand f2utf8 fappend fappends fboxname fc fcompare fcompares fcopynew fdir ferase fetch fexist fexists fgets file2url fixdotdot fliprgb fmakex foldpara foldtext fpathcreate fpathname fputs fread freadblock freadr freads frename freplace fsize fss fssrplc fstamp fstringreplace ftype fview fwrite fwritenew fwrites getalpha getargs getdate getenv getqtbin hfd hostpathsep ic install iospath isatty isotimestamp isutf8 jcwdpath joinstring jpath jpathsep jsystemdefs launch list ljust load loadd loadtags mema memf memr memw nameclass namelist names nc nl pick quote require rjust rplc rxE rxall rxcomp rxcut rxeq rxerror rxfirst rxfree rxfrom rxhandles rxin rxindex rxinfo rxmatch rxmatches rxrplc rxutf8 script scriptd scripts setalpha setbreak shell show sign sminfo smoutput sort split splitnostring splitstring ss startupandroid startupconsole startupide stderr stdin stdout stringreplace symdat symget symset ta tagcp tagopen tagselect take takeafter taketo timespacex timestamp timex tmoutput toCRLF toHOST toJ todate todayno tolower topara toupper tsdiff tsrep tstamp type ucp ucpcount unxlib usleep utf8 uucp valdate wcsize weekday weeknumber weeksinyear winpathsep xedit
syntax match jStdlibNoun /\<\%(adverb\|conjunction\|dyad\|monad\|noun\|verb\)\>/
syntax match jStdlibVerb /\<\%(assert\|break\|do\)\>\.\@!/
syntax match jStdlibVerb /\<\%(Note\|\%(assert\|break\|do\)\.\@!\)\>/
" Numbers. Matching J numbers is difficult. In fact, the job cannot be done
" with regular expressions alone. Below is a sketch of the pattern used. It
@ -75,12 +75,12 @@ syntax match jConjunction /;\.\|\^:\|![.:]/
" the next line. The trick is to split the problem into two regions and link
" them with "nextgroup=". The fold wrapper provides syntax folding.
syntax region jNounDefineFold
\ matchgroup=NONE start=/\<\%(\%(0\|noun\)\s\+\%(\:\s*0\|def\s\+0\|define\)\>\)\@=/
\ matchgroup=NONE start=/\%(\%(\%(^\s*Note\)\|\<\%(0\|noun\)\s\+\%(\:\s*0\|def\s\+0\|define\)\)\>\)\@=/
\ keepend matchgroup=NONE end=/^\s*)\s*$/
\ contains=jNounDefineStart
\ fold
syntax region jNounDefineStart
\ matchgroup=jDefineExpression start=/\<\%(0\|noun\)\s\+\%(\:\s*0\|def\s\+0\|define\)\>/
\ matchgroup=jDefineExpression start=/\%(\%(^\s*Note\)\|\<\%(0\|noun\)\s\+\%(\:\s*0\|def\s\+0\|define\)\)\>/
\ keepend matchgroup=NONE end=/$/
\ contains=@jStdlibItems,@jPrimitiveItems,jNumber,jString,jParenGroup,jParen,jComment
\ contained oneline skipempty nextgroup=jDefineEnd,jNounDefine
@ -112,7 +112,7 @@ syntax region jParenGroup
\ oneline transparent
syntax keyword jTodo contained TODO FIXME XXX
syntax match jComment /NB\..*$/ contains=jTodo,@Spell
syntax match jComment /\<NB\..*$/ contains=jTodo,@Spell
syntax match jSharpBang /\%^#!.*$/

View File

@ -2,7 +2,7 @@
" Language: Java
" Maintainer: Claudio Fleiner <claudio@fleiner.com>
" URL: http://www.fleiner.com/vim/syntax/java.vim
" Last Change: 2012 Oct 05
" Last Change: 2015 March 01
" Please check :help java.vim for comments on some of the options available.
@ -30,7 +30,7 @@ endif
" some characters that cannot be in a java program (outside a string)
syn match javaError "[\\@`]"
syn match javaError "<<<\|\.\.\|=>\|||=\|&&=\|[^-]->\|\*\/"
syn match javaError "<<<\|\.\.\|=>\|||=\|&&=\|\*\/"
syn match javaOK "\.\.\."
@ -63,7 +63,7 @@ syn match javaTypedef "\.\s*\<class\>"ms=s+1
syn keyword javaClassDecl enum
syn match javaClassDecl "^class\>"
syn match javaClassDecl "[^.]\s*\<class\>"ms=s+1
syn match javaAnnotation "@\([_$a-zA-Z][_$a-zA-Z0-9]*\.\)*[_$a-zA-Z][_$a-zA-Z0-9]*\>"
syn match javaAnnotation "@\([_$a-zA-Z][_$a-zA-Z0-9]*\.\)*[_$a-zA-Z][_$a-zA-Z0-9]*\>\(([^)]*)\)\=" contains=javaString
syn match javaClassDecl "@interface\>"
syn keyword javaBranch break continue nextgroup=javaUserLabelRef skipwhite
syn match javaUserLabelRef "\k\+" contained
@ -121,7 +121,7 @@ if exists("java_space_errors")
endif
endif
syn region javaLabelRegion transparent matchgroup=javaLabel start="\<case\>" matchgroup=NONE end=":" contains=javaNumber,javaCharacter
syn region javaLabelRegion transparent matchgroup=javaLabel start="\<case\>" matchgroup=NONE end=":" contains=javaNumber,javaCharacter,javaString
syn match javaUserLabel "^\s*[_$a-zA-Z][_$a-zA-Z0-9_]*\s*:"he=e-1 contains=javaLabel
syn keyword javaLabel default
@ -188,10 +188,10 @@ syn region javaString start=+"+ end=+"+ end=+$+ contains=javaSpecialChar,javaS
syn match javaCharacter "'[^']*'" contains=javaSpecialChar,javaSpecialCharError
syn match javaCharacter "'\\''" contains=javaSpecialChar
syn match javaCharacter "'[^\\]'"
syn match javaNumber "\<\(0[0-7]*\|0[xX]\x\+\|\d\+\)[lL]\=\>"
syn match javaNumber "\(\<\d\+\.\d*\|\.\d\+\)\([eE][-+]\=\d\+\)\=[fFdD]\="
syn match javaNumber "\<\d\+[eE][-+]\=\d\+[fFdD]\=\>"
syn match javaNumber "\<\d\+\([eE][-+]\=\d\+\)\=[fFdD]\>"
syn match javaNumber "\<\(0[bB][0-1]\+\|0[0-7]*\|0[xX]\x\+\|\d\(\d\|_\d\)*\)[lL]\=\>"
syn match javaNumber "\(\<\d\(\d\|_\d\)*\.\(\d\(\d\|_\d\)*\)\=\|\.\d\(\d\|_\d\)*\)\([eE][-+]\=\d\(\d\|_\d\)*\)\=[fFdD]\="
syn match javaNumber "\<\d\(\d\|_\d\)*[eE][-+]\=\d\(\d\|_\d\)*[fFdD]\=\>"
syn match javaNumber "\<\d\(\d\|_\d\)*\([eE][-+]\=\d\(\d\|_\d\)*\)\=[fFdD]\>"
" unicode characters
syn match javaSpecial "\\u\d\{4\}"
@ -200,19 +200,21 @@ syn cluster javaTop add=javaString,javaCharacter,javaNumber,javaSpecial,javaStri
if exists("java_highlight_functions")
if java_highlight_functions == "indent"
syn match javaFuncDef "^\(\t\| \{8\}\)[_$a-zA-Z][_$a-zA-Z0-9_. \[\]]*([^-+*/()]*)" contains=javaScopeDecl,javaType,javaStorageClass,@javaClasses
syn region javaFuncDef start=+^\(\t\| \{8\}\)[$_a-zA-Z][$_a-zA-Z0-9_. \[\]]*([^-+*/()]*,\s*+ end=+)+ contains=javaScopeDecl,javaType,javaStorageClass,@javaClasses
syn match javaFuncDef "^ [$_a-zA-Z][$_a-zA-Z0-9_. \[\]]*([^-+*/()]*)" contains=javaScopeDecl,javaType,javaStorageClass,@javaClasses
syn region javaFuncDef start=+^ [$_a-zA-Z][$_a-zA-Z0-9_. \[\]]*([^-+*/()]*,\s*+ end=+)+ contains=javaScopeDecl,javaType,javaStorageClass,@javaClasses
syn match javaFuncDef "^\(\t\| \{8\}\)[_$a-zA-Z][_$a-zA-Z0-9_. \[\]<>]*([^-+*/]*)" contains=javaScopeDecl,javaType,javaStorageClass,@javaClasses,javaAnnotation
syn region javaFuncDef start=+^\(\t\| \{8\}\)[$_a-zA-Z][$_a-zA-Z0-9_. \[\]<>]*([^-+*/]*,\s*+ end=+)+ contains=javaScopeDecl,javaType,javaStorageClass,@javaClasses,javaAnnotation
syn match javaFuncDef "^ [$_a-zA-Z][$_a-zA-Z0-9_. \[\]<>]*([^-+*/]*)" contains=javaScopeDecl,javaType,javaStorageClass,@javaClasses,javaAnnotation
syn region javaFuncDef start=+^ [$_a-zA-Z][$_a-zA-Z0-9_. \[\]<>]*([^-+*/]*,\s*+ end=+)+ contains=javaScopeDecl,javaType,javaStorageClass,@javaClasses,javaAnnotation
else
" This line catches method declarations at any indentation>0, but it assumes
" two things:
" 1. class names are always capitalized (ie: Button)
" 2. method names are never capitalized (except constructors, of course)
syn region javaFuncDef start=+^\s\+\(\(public\|protected\|private\|static\|abstract\|final\|native\|synchronized\)\s\+\)*\(\(void\|boolean\|char\|byte\|short\|int\|long\|float\|double\|\([A-Za-z_][A-Za-z0-9_$]*\.\)*[A-Z][A-Za-z0-9_$]*\)\(<[^>]*>\)\=\(\[\]\)*\s\+[a-z][A-Za-z0-9_$]*\|[A-Z][A-Za-z0-9_$]*\)\s*([^0-9]+ end=+)+ contains=javaScopeDecl,javaType,javaStorageClass,javaComment,javaLineComment,@javaClasses
"syn region javaFuncDef start=+^\s\+\(\(public\|protected\|private\|static\|abstract\|final\|native\|synchronized\)\s\+\)*\(\(void\|boolean\|char\|byte\|short\|int\|long\|float\|double\|\([A-Za-z_][A-Za-z0-9_$]*\.\)*[A-Z][A-Za-z0-9_$]*\)\(<[^>]*>\)\=\(\[\]\)*\s\+[a-z][A-Za-z0-9_$]*\|[A-Z][A-Za-z0-9_$]*\)\s*([^0-9]+ end=+)+ contains=javaScopeDecl,javaType,javaStorageClass,javaComment,javaLineComment,@javaClasses
syn region javaFuncDef start=+^\s\+\(\(public\|protected\|private\|static\|abstract\|final\|native\|synchronized\)\s\+\)*\(<.*>\s\+\)\?\(\(void\|boolean\|char\|byte\|short\|int\|long\|float\|double\|\([A-Za-z_][A-Za-z0-9_$]*\.\)*[A-Z][A-Za-z0-9_$]*\)\(<[^(){}]*>\)\=\(\[\]\)*\s\+[a-z][A-Za-z0-9_$]*\|[A-Z][A-Za-z0-9_$]*\)\s*(+ end=+)+ contains=javaScopeDecl,javaType,javaStorageClass,javaComment,javaLineComment,@javaClasses,javaAnnotation
endif
syn match javaLambdaDef "[a-zA-Z_][a-zA-Z0-9_]*\s*->"
syn match javaBraces "[{}]"
syn cluster javaTop add=javaFuncDef,javaBraces
syn cluster javaTop add=javaFuncDef,javaBraces,javaLambdaDef
endif
if exists("java_highlight_debug")
@ -266,18 +268,23 @@ if exists("java_mark_braces_in_parens_as_errors")
endif
" catch errors caused by wrong parenthesis
syn region javaParenT transparent matchgroup=javaParen start="(" end=")" contains=@javaTop,javaParenT1
syn region javaParenT transparent matchgroup=javaParen start="(" end=")" contains=@javaTop,javaParenT1
syn region javaParenT1 transparent matchgroup=javaParen1 start="(" end=")" contains=@javaTop,javaParenT2 contained
syn region javaParenT2 transparent matchgroup=javaParen2 start="(" end=")" contains=@javaTop,javaParenT contained
syn match javaParenError ")"
" catch errors caused by wrong square parenthesis
syn region javaParenT transparent matchgroup=javaParen start="\[" end="\]" contains=@javaTop,javaParenT1
syn region javaParenT transparent matchgroup=javaParen start="\[" end="\]" contains=@javaTop,javaParenT1
syn region javaParenT1 transparent matchgroup=javaParen1 start="\[" end="\]" contains=@javaTop,javaParenT2 contained
syn region javaParenT2 transparent matchgroup=javaParen2 start="\[" end="\]" contains=@javaTop,javaParenT contained
syn match javaParenError "\]"
JavaHiLink javaParenError javaError
if exists("java_highlight_functions")
syn match javaLambdaDef "([a-zA-Z0-9_<>\[\], \t]*)\s*->"
" needs to be defined after the parenthesis error catcher to work
endif
if !exists("java_minlines")
let java_minlines = 10
endif
@ -288,6 +295,7 @@ if version >= 508 || !exists("did_java_syn_inits")
if version < 508
let did_java_syn_inits = 1
endif
JavaHiLink javaLambdaDef Function
JavaHiLink javaFuncDef Function
JavaHiLink javaVarArg Function
JavaHiLink javaBraces Function

View File

@ -1,6 +1,9 @@
" Vim syntax file
" Maintainer: Nikolai Weibull <now@bitwi.se>
" Latest Revision: 2009-05-25
" Maintainer: Christian Brabandt <cb@256bit.org>
" Previous Maintainer: Nikolai Weibull <now@bitwi.se>
" Latest Revision: 2015-05-29
" License: Vim (see :h license)
" Repository: https://github.com/chrisbra/vim-kconfig
if exists("b:current_syntax")
finish

79
runtime/syntax/less.vim Normal file
View File

@ -0,0 +1,79 @@
" Vim syntax file
" Language: less
" Maintainer: Alessandro Vioni <jenoma@gmail.com>
" URL: https://github.com/genoma/vim-less
" Last Change: 2014 November 24
if exists("b:current_syntax")
finish
endif
runtime! syntax/css.vim
runtime! after/syntax/css.vim
syn case ignore
syn cluster lessCssProperties contains=cssFontProp,cssFontDescriptorProp,cssColorProp,cssTextProp,cssBoxProp,cssGeneratedContentProp,cssPagingProp,cssUIProp,cssRenderProp,cssAuralProp,cssTableProp
syn cluster lessCssAttributes contains=css.*Attr,lessEndOfLineComment,lessComment,cssValue.*,cssColor,cssURL,lessDefault,cssImportant,cssError,cssStringQ,cssStringQQ,cssFunction,cssUnicodeEscape,cssRenderProp
syn region lessDefinition matchgroup=cssBraces start="{" end="}" contains=TOP
syn match lessProperty "\%([{};]\s*\|^\)\@<=\%([[:alnum:]-]\|#{[^{}]*}\)\+\s*:" contains=css.*Prop skipwhite nextgroup=lessCssAttribute contained containedin=lessDefinition
syn match lessProperty "^\s*\zs\s\%(\%([[:alnum:]-]\|#{[^{}]*}\)\+\s*:\|:[[:alnum:]-]\+\)"hs=s+1 contains=css.*Prop skipwhite nextgroup=lessCssAttribute
syn match lessProperty "^\s*\zs\s\%(:\=[[:alnum:]-]\+\s*=\)"hs=s+1 contains=css.*Prop skipwhite nextgroup=lessCssAttribute
syn match lessCssAttribute +\%("\%([^"]\|\\"\)*"\|'\%([^']\|\\'\)*'\|#{[^{}]*}\|[^{};]\)*+ contained contains=@lessCssAttributes,lessVariable,lessFunction,lessInterpolation
syn match lessDefault "!default\>" contained
" less variables and media queries
syn match lessVariable "@[[:alnum:]_-]\+" nextgroup=lessCssAttribute skipwhite
syn match lessMedia "@media" nextgroup=lessCssAttribute skipwhite
" Less functions
syn match lessFunction "\<\%(escape\|e\|unit\)\>(\@=" contained
syn match lessFunction "\<\%(ceil\|floor\|percentage\|round\|sqrt\|abs\|sin\|asin\|cos\|acos\|tan\|atan\|pi\|pow\|min\|max\)\>(\@=" contained
syn match lessFunction "\<\%(rgb\|rgba\|argb\|argb\|hsl\|hsla\|hsv\|hsva\)\>(\@=" contained
syn match lessFunction "\<\%(hue\|saturation\|lightness\|red\|green\|blue\|alpha\|luma\)\>(\@=" contained
syn match lessFunction "\<\%(saturate\|desaturate\|lighten\|darken\|fadein\|fadeout\|fade\|spin\|mix\|greyscale\|contrast\)\>(\@=" contained
syn match lessFunction "\<\%(multiply\|screen\|overlay\|softlight\|hardlight\|difference\|exclusion\|average\|negation\)\>(\@=" contained
" Less id class visualization
syn match lessIdChar "#[[:alnum:]_-]\@=" nextgroup=lessId,lessClassIdCall
syn match lessId "[[:alnum:]_-]\+" contained
syn match lessClassIdCall "[[:alnum:]_-]\+()" contained
syn match lessClassChar "\.[[:alnum:]_-]\@=" nextgroup=lessClass,lessClassCall
syn match lessClass "[[:alnum:]_-]\+" contained
syn match lessClassCall "[[:alnum:]_-]\+()" contained
syn match lessAmpersand "&" contains=lessIdChar,lessClassChar
syn region lessInclude start="@import" end=";\|$" contains=lessComment,cssURL,cssUnicodeEscape,cssMediaType,cssStringQ,cssStringQQ
syn keyword lessTodo FIXME NOTE TODO OPTIMIZE XXX contained
syn region lessComment start="^\z(\s*\)//" end="^\%(\z1 \)\@!" contains=lessTodo,@Spell
syn region lessCssComment start="^\z(\s*\)/\*" end="^\%(\z1 \)\@!" contains=lessTodo,@Spell
syn match lessEndOfLineComment "//.*" contains=lessComment,lessTodo,@Spell
hi def link lessEndOfLineComment lessComment
hi def link lessCssComment lessComment
hi def link lessComment Comment
hi def link lessDefault cssImportant
hi def link lessVariable Identifier
hi def link lessFunction PreProc
hi def link lessTodo Todo
hi def link lessInclude Include
hi def link lessIdChar Special
hi def link lessClassChar Special
hi def link lessAmpersand Character
hi def link lessId Identifier
hi def link lessClass Type
hi def link lessCssAttribute PreProc
hi def link lessClassCall Type
hi def link lessClassIdCall Type
hi def link lessTagName cssTagName
hi def link lessDeprecated cssDeprecated
hi def link lessMedia cssMedia
let b:current_syntax = "less"
" vim:set sw=2:

View File

@ -1,28 +1,23 @@
" Vim syntax file
" Language: Lisp
" Maintainer: Dr. Charles E. Campbell, Jr. <NdrOchipS@PcampbellAfamily.Mbiz>
" Last Change: Nov 16, 2010
" Version: 22
" URL: http://mysite.verizon.net/astronaut/vim/index.html#vimlinks_syntax
" Maintainer: Charles E. Campbell <NdrOchipS@PcampbellAfamily.Mbiz>
" Last Change: Oct 06, 2014
" Version: 23
" URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_LISP
"
" Thanks to F Xavier Noria for a list of 978 Common Lisp symbols
" taken from the HyperSpec
" Thanks to F Xavier Noria for a list of 978 Common Lisp symbols taken from HyperSpec
" Clisp additions courtesy of http://clisp.cvs.sourceforge.net/*checkout*/clisp/clisp/emacs/lisp.vim
" ---------------------------------------------------------------------
" Load Once: {{{1
" For vim-version 5.x: Clear all syntax items
" For vim-version 6.x: Quit when a syntax file was already loaded
if version < 600
syntax clear
elseif exists("b:current_syntax")
finish
if exists("b:current_syntax")
finish
endif
if version >= 600
setlocal iskeyword=38,42,43,45,47-58,60-62,64-90,97-122,_
if exists("g:lisp_isk")
exe "setl isk=".g:lisp_isk
else
set iskeyword=38,42,43,45,47-58,60-62,64-90,97-122,_
setl isk=38,42,43,45,47-58,60-62,64-90,97-122,_
endif
if exists("g:lispsyntax_ignorecase") || exists("g:lispsyntax_clisp")

View File

@ -2,7 +2,7 @@
" Language: Makefile
" Maintainer: Claudio Fleiner <claudio@fleiner.com>
" URL: http://www.fleiner.com/vim/syntax/make.vim
" Last Change: 2012 Oct 05
" Last Change: 2015 Feb 28
" For version 5.x: Clear all syntax items
" For version 6.x: Quit when a syntax file was already loaded
@ -43,8 +43,8 @@ syn region makeIdent start="\$(" skip="\\)\|\\\\" end=")" contains=makeStatement
syn region makeIdent start="\${" skip="\\}\|\\\\" end="}" contains=makeStatement,makeIdent,makeSString,makeDString
syn match makeIdent "\$\$\w*"
syn match makeIdent "\$[^({]"
syn match makeIdent "^ *\a\w*\s*[:+?!*]="me=e-2
syn match makeIdent "^ *\a\w*\s*="me=e-1
syn match makeIdent "^ *[^:#= \t]*\s*[:+?!*]="me=e-2
syn match makeIdent "^ *[^:#= \t]*\s*="me=e-1
syn match makeIdent "%"
" Makefile.in variables
@ -55,11 +55,11 @@ syn match makeConfig "@[A-Za-z0-9_]\+@"
syn match makeImplicit "^\.[A-Za-z0-9_./\t -]\+\s*:$"me=e-1 nextgroup=makeSource
syn match makeImplicit "^\.[A-Za-z0-9_./\t -]\+\s*:[^=]"me=e-2 nextgroup=makeSource
syn region makeTarget transparent matchgroup=makeTarget start="^[A-Za-z0-9_./$()%-][A-Za-z0-9_./\t $()%-]*:\{1,2}[^:=]"rs=e-1 end=";"re=e-1,me=e-1 end="[^\\]$" keepend contains=makeIdent,makeSpecTarget,makeNextLine skipnl nextGroup=makeCommands
syn match makeTarget "^[A-Za-z0-9_./$()%*@-][A-Za-z0-9_./\t $()%*@-]*::\=\s*$" contains=makeIdent,makeSpecTarget skipnl nextgroup=makeCommands,makeCommandError
syn region makeTarget transparent matchgroup=makeTarget start="^[~A-Za-z0-9_./$()%-][A-Za-z0-9_./\t $()%-]*:\{1,2}[^:=]"rs=e-1 end=";"re=e-1,me=e-1 end="[^\\]$" keepend contains=makeIdent,makeSpecTarget,makeNextLine,makeComment skipnl nextGroup=makeCommands
syn match makeTarget "^[~A-Za-z0-9_./$()%*@-][A-Za-z0-9_./\t $()%*@-]*::\=\s*$" contains=makeIdent,makeSpecTarget,makeComment skipnl nextgroup=makeCommands,makeCommandError
syn region makeSpecTarget transparent matchgroup=makeSpecTarget start="^\.\(SUFFIXES\|PHONY\|DEFAULT\|PRECIOUS\|IGNORE\|SILENT\|EXPORT_ALL_VARIABLES\|KEEP_STATE\|LIBPATTERNS\|NOTPARALLEL\|DELETE_ON_ERROR\|INTERMEDIATE\|POSIX\|SECONDARY\)\>\s*:\{1,2}[^:=]"rs=e-1 end="[^\\]$" keepend contains=makeIdent,makeSpecTarget,makeNextLine skipnl nextGroup=makeCommands
syn match makeSpecTarget "^\.\(SUFFIXES\|PHONY\|DEFAULT\|PRECIOUS\|IGNORE\|SILENT\|EXPORT_ALL_VARIABLES\|KEEP_STATE\|LIBPATTERNS\|NOTPARALLEL\|DELETE_ON_ERROR\|INTERMEDIATE\|POSIX\|SECONDARY\)\>\s*::\=\s*$" contains=makeIdent skipnl nextgroup=makeCommands,makeCommandError
syn region makeSpecTarget transparent matchgroup=makeSpecTarget start="^\.\(SUFFIXES\|PHONY\|DEFAULT\|PRECIOUS\|IGNORE\|SILENT\|EXPORT_ALL_VARIABLES\|KEEP_STATE\|LIBPATTERNS\|NOTPARALLEL\|DELETE_ON_ERROR\|INTERMEDIATE\|POSIX\|SECONDARY\)\>\s*:\{1,2}[^:=]"rs=e-1 end="[^\\]$" keepend contains=makeIdent,makeSpecTarget,makeNextLine,makeComment skipnl nextGroup=makeCommands
syn match makeSpecTarget "^\.\(SUFFIXES\|PHONY\|DEFAULT\|PRECIOUS\|IGNORE\|SILENT\|EXPORT_ALL_VARIABLES\|KEEP_STATE\|LIBPATTERNS\|NOTPARALLEL\|DELETE_ON_ERROR\|INTERMEDIATE\|POSIX\|SECONDARY\)\>\s*::\=\s*$" contains=makeIdent,makeComment skipnl nextgroup=makeCommands,makeCommandError
syn match makeCommandError "^\s\+\S.*" contained
syn region makeCommands start=";"hs=s+1 start="^\t" end="^[^\t#]"me=e-1,re=e-1 end="^$" contained contains=makeCmdNextLine,makeSpecial,makeComment,makeIdent,makePreCondit,makeDefine,makeDString,makeSString nextgroup=makeCommandError

Some files were not shown because too many files have changed in this diff Show More