Compare commits

..

168 Commits

Author SHA1 Message Date
52f8317926 updated for version 7.3.314
Problem:    Missing parenthesis.
Solution:   Add it. (Benjamin R. Haskell)
2011-09-14 19:01:42 +02:00
314ed4b21a updated for version 7.3.313
Problem:    One more warning when compiling with dynamic Python 3.
Solution:   Change PySliceObject to PyObject.
2011-09-14 18:59:39 +02:00
5302d9ebc1 Updated runtime files. 2011-09-14 17:55:08 +02:00
ddab33232a updated for version 7.3.312
Problem:    Can't compile with tiny features.
Solution:   Add #ifdef around win_valid().
2011-09-14 17:50:14 +02:00
821390843b updated for version 7.3.311
Problem:    Complete function isn't called when the leader changed.
Solution:   Allow the complete function to return a dictionary with a flag
            that indicates ins_compl_restart() is to be called when the leader
            changes. (Taro Muraoka)
2011-09-14 16:52:09 +02:00
15d6319b9d updated for version 7.3.310
Problem:    Code not following Vim style.
Solution:   Fix the style. (Elias Diem)
2011-09-14 16:05:15 +02:00
9e8edf6ee6 updated for version 7.3.309
Problem:    Warnings for pointer types.
Solution:   Change PySliceObject to PyObject.
2011-09-14 15:41:58 +02:00
b5b5b895f7 updated for version 7.3.308
Problem:    Writing to 'verbosefile' has problems, e.g. for :highlight.
Solution:   Do not use a separate verbose_write() function but write with the
            same code that does redirecting. (Yasuhiro Matsumoto)
2011-09-14 15:39:29 +02:00
ba4897e6e5 updated for version 7.3.307
Problem:    Python 3 doesn't support slice assignment.
Solution:   Implement slices. (Brett Overesch, Roland Puntaier)
2011-09-14 15:01:58 +02:00
a971b82b16 updated for version 7.3.306
Problem:    When closing a window there is a chance that deleting a scrollbar
            triggers a GUI resize, which uses the window while it is not in a
            valid state.
Solution:   Set the buffer pointer to NULL to be able to detect the invalid
            situation.  Fix a few places that used the buffer pointer
            incorrectly.
2011-09-14 14:43:25 +02:00
52af96527c updated for version 7.3.305
Problem:    Auto-loading a function while editing the command line causes
            scrolling up the display.
Solution:   Don't set msg_scroll when defining a function and the user is not
            typing. (Yasuhiro Matsumoto)
2011-09-14 14:33:51 +02:00
612af43cb6 updated for version 7.3.304
Problem:    Strawberry Perl doesn't work on MS-Windows.
Solution:   Use xsubpp if needed. (Yasuhiro Matsumoto)
2011-09-14 10:49:46 +02:00
9f1188152f updated for version 7.3.303
Problem:    Compilation error.
Solution:   Correct return type from int to pid_t. (Danek Duvall)
2011-09-08 23:24:14 +02:00
868272f58e updated for version 7.3.302
Problem:    Test 19 fails without 'smartindent' and +eval.
Solution:   Don't use ":exe". Source small.vim.
2011-09-08 23:22:40 +02:00
c42e7ed777 updated for version 7.3.301
Problem:    When 'smartindent' and 'copyindent' are set a Tab is used even
            though 'expandtab' is set.
Solution:   Do not insert Tabs. Add a test. (Christian Brabandt)
2011-09-07 19:58:09 +02:00
275648066d updated for version 7.3.300
Problem:    Python doesn't parse multi-byte argument correctly.
Solution:   Use "t" instead of "s". (lilydjwg)
2011-09-07 19:30:21 +02:00
0d55ff1594 updated for version 7.3.299
Problem:    Source code not in Vim style.
Solution:   Adjust the style. (Elias Diem)
2011-09-07 19:09:01 +02:00
092e3c874f updated for version 7.3.298
Problem:    Built-in colors are different from rgb.txt.
Solution:   Adjust the color values. (Benjamin Haskell)
2011-09-07 18:58:29 +02:00
6dfff547a7 updated for version 7.3.297
Problem:    Can't load Perl 5.14 dynamically.
Solution:   Add code in #ifdefs. (Charles Cooper)
2011-09-07 18:47:23 +02:00
205b886a41 updated for version 7.3.296
Problem:    When writing to an external command a zombie process may be left
            behind.
Solution:   Wait on the process. (James Vega)
2011-09-07 15:04:31 +02:00
493c7a8541 updated for version 7.3.295
Problem:    When filtering text with an external command Vim may not read all
            the output.
Solution:   When select() is interrupted loop and try again. (James Vega)
2011-09-07 14:06:47 +02:00
01a78342e0 updated for version 7.3.294
Problem:    Patch 289 causes more problems than it solves.
Solution:   Rever the patch untill a better solution is found.
2011-09-05 20:13:42 +02:00
d3184b57d2 updated for version 7.3.293
Problem:    MSVC compiler has a problem with non-ASCII characters.
Solution:   Avoid non-ASCII characters. (Hong Xu)
2011-09-02 14:18:20 +02:00
6c167c6451 updated for version 7.3.292
Problem:    Crash when using fold markers and selecting a visual block that
            includes a folded line and goes to end of line. (Sam Lidder)
Solution:   Check for the column to be MAXCOL. (James Vega)
2011-09-02 14:07:36 +02:00
6fabcbe260 updated for version 7.3.291
Problem:    Configure doesn't work properly with Python3.
Solution:   Put -ldl before $LDFLAGS. Add PY3_NO_RTLD_GLOBAL. (Roland
            Puntaier)
2011-09-02 12:27:25 +02:00
39fc42ef9d updated for version 7.3.290
Problem:    When a BufWriteCmd autocommand resets 'modified' this doesn't
            change older buffer states to be marked as 'modified' like
            ":write" does.  (Yukihiro Nakadaira)
Solution:   When the BufWriteCmd resets 'modified' then adjust the undo
            information like ":write" does.
2011-09-02 11:56:20 +02:00
03aa60826e updated for version 7.3.289
Problem:    Complete function isn't called when the leader changed.
Solution:   Call ins_compl_restart() when the leader changed.  (Taro Muraoka)
2011-08-28 16:02:28 +02:00
9dc93ae43e updated for version 7.3.288
Problem:    has('python') may give an error message for not being able to load
            the library after using python3.
Solution:   Only give the error when the verbose argument is true.
2011-08-28 16:00:19 +02:00
2eba18255e updated for version 7.3.287
Problem:    Can't compile with MSVC and tiny options.
Solution:   Move variables and #ifdefs. (Sergey Khorev)
2011-08-27 15:10:04 +02:00
c9927c136f updated for version 7.3.286
Problem:    Crash when using "zd" on a large number of folds. (Sam King)
Solution:   Recompute pointer after reallocating array.  Move fewer entries
            when making room.
2011-08-26 16:13:00 +02:00
792826c0c7 updated for version 7.3.285
Problem:    Mapping <Char-123> no longer works.
Solution:   Properly check for "char-".  Add a test for it.
2011-08-19 22:29:02 +02:00
b8bf541f89 updated for version 7.3.284
Problem:    The str2special() function doesn't handle multi-byte characters
            properly.
Solution:   Recognize multi-byte characters. (partly by Vladimir Vichniakov)
2011-08-17 20:33:22 +02:00
f6f4a01ab1 updated for version 7.3.283
Problem:    An expression mapping with a multi-byte character containing a
            0x80 byte gets messed up. (ZyX)
Solution:   Unescape the expression before evaluating it (Yukihiro Nakadaira)
2011-08-17 17:18:20 +02:00
1db1f77d4a updated for version 7.3.282
Problem:    When using input() and :echo in a loop the displayed text is
            incorrect. (Benjamin Fritz)
Solution:   Only restore the cursor position when there is a command line.
            (Ben Schmidt)
2011-08-17 16:25:48 +02:00
dc93555c0f updated for version 7.3.281
Problem:    After using "expand('%:8')" the buffer name is changed.
Solution:   Make a copy of the file name before shortening it.
2011-08-17 15:23:23 +02:00
c95e32635c updated for version 7.3.280
Problem:    ":lmake" does not update the quickfix window title.
Solution:   Update the title. (Lech Lorens)
2011-08-10 18:36:54 +02:00
12bc1b5c9f updated for version 7.3.279
Problem:    With GTK, when gvim is full-screen and a tab is opened and using a
            specific monitor configuration the window is too big.
Solution:   Adjust the window size like on MS-Windows. (Yukihiro Nakadaira)
2011-08-10 17:44:45 +02:00
17fb0e891a updated for version 7.3.278
Problem:    Passing the file name to open in VisVim doesn't work.
Solution:   Adjust the index and check for end of buffer. (Jiri Sedlak)
2011-08-10 17:25:51 +02:00
8c85fa3b26 updated for version 7.3.277
Problem:    MS-Windows: some characters do not show in dialogs.
Solution:   Use the wide methods when available. (Yanwei Jia)
2011-08-10 17:08:03 +02:00
cf83973211 updated for version 7.3.276
Problem:    GvimExt sets $LANG in the wrong way.
Solution:   Save the environment and use it for gvim. (Yasuhiro Matsumoto)
2011-08-10 16:31:23 +02:00
e78c206856 updated for version 7.3.275
Problem:    MS-Windows: When using a black background some screen updates
            cause the window to flicker.
Solution:   Add WS_CLIPCHILDREN to CreateWindow().  (René Aguirre)
2011-08-10 15:56:27 +02:00
8a20b0f25e updated for version 7.3.274
Problem:    With concealed characters tabs do not have the right size.
Solution:   Use VCOL_HLC instead of vcol. (Eiichi Sato)
2011-08-10 14:32:39 +02:00
836082d398 updated for version 7.3.273
Problem:    A BOM in an error file is seen as text. (Aleksey Baibarin)
Solution:   Remove the BOM from the text before evaluating. (idea by Christian
            Brabandt)
2011-08-10 13:21:46 +02:00
213b10a57e updated for version 7.3.272
Problem:    ":put =list" does not add an empty line for a trailing empty
            item.
Solution:   Add a trailing NL when turning a list into a string.
2011-08-10 12:38:08 +02:00
d0988c50f3 updated for version 7.3.271
Problem:    Code not following Vim coding style.
Solution:   Fix the style. (Elias Diem)
2011-08-10 12:19:04 +02:00
1cb7e0976d updated for version 7.3.270
Problem:    Illegal memory access.
Solution:   Swap conditions. (Dominique Pelle)
2011-08-10 12:11:01 +02:00
ea35ef6888 updated for version 7.3.269
Problem:    'shellcmdflag' only works with one flag.
Solution:   Split into multiple arguments. (Gary Johnson)
2011-08-04 22:59:28 +02:00
e70172e1fc updated for version 7.3.268
Problem:    Vim freezes when executing an external command with zsh.
Solution:   Use O_NOCTTY both in the master and slave. (Bjorn Winckler)
2011-08-04 19:36:52 +02:00
3f5f795f76 updated for version 7.3.267
Problem:    Ruby on Mac OS X 10.7 may crash.
Solution:   Avoid alloc(0). (Bjorn Winckler)
2011-08-04 19:34:59 +02:00
673214bb7d updated for version 7.3.266
Problem:    In Gvim with iBus typing space in Insert mode doesn't work.
Solution:   Clear xim_expected_char after checking it.
2011-07-27 18:25:44 +02:00
4c40223649 updated for version 7.3.265
Problem:    When storing a pattern in search history there is no proper check
            for the separator character.
Solution:   Pass the separator character to in_history(). (Muraoka Taro)
2011-07-27 17:58:46 +02:00
0b573a58e6 updated for version 7.3.264
Problem:    When the current directory name contains wildcard characters, such
            as "foo[with]bar", the tags file can't be found.  (Jeremy
            Erickson)
Solution:   When searching for matching files also match without expanding
            wildcards.  This is a bit of a hack.
2011-07-27 17:31:47 +02:00
a171162356 updated for version 7.3.263
Problem:    Perl and Tcl have a few code style problems.
Solution:   Clean it up.  (Elias Diem)
2011-07-27 14:15:46 +02:00
d2221131cf updated for version 7.3.262
Problem:    Photon code style doesn't match Vim style.
Solution:   Clean up some of it.  (Elias Diem)
2011-07-27 14:09:09 +02:00
d0c7ba57b1 updated for version 7.3.261
Problem:    G++ error message errornously recognized as error.
Solution:   Ignore "In file included from" line also when it ends in a colon.
            (Fernando Castillo)
2011-07-27 13:59:21 +02:00
0533443638 updated for version 7.3.260
Problem:    CursorHold triggers on an incomplete mapping. (Will Gray)
Solution:   Don't trigger CursorHold when there is typeahead.
2011-07-20 18:29:39 +02:00
522f9aebff updated for version 7.3.259
Problem:    Equivalence classes only work for latin characters.
Solution:   Add the Unicode equivalence characters. (Dominique Pelle)
2011-07-20 17:58:20 +02:00
ce35c88ade updated for version 7.3.258
Problem:    MS-Windows: The edit with existing vim context menu entries can be
            unwanted.
Solution:   Let a registry entry disable them. (Jerome Vuarand)
2011-07-20 17:27:25 +02:00
e9edd7fbdd updated for version 7.3.257
Problem:    Not all completions are available to user commands.
Solution:   Add "color", "compiler", "file_in_path" and "locale". (Dominique
            Pelle)
2011-07-20 16:37:24 +02:00
76f7fd3df3 updated for version 7.3.256
Problem:    Javascript indenting not sufficiently tested.
Solution:   Add more tests. (Luc Deschenaux)  Mark the lines that are indented
            wrong.
2011-07-20 15:09:43 +02:00
b560983d2f updated for version 7.3.255
Problem:    When editing a file such as "File[2010-08-15].vim" an E16 error is
            given. (Manuel Stol)
Solution:   Don't give an error for failing to compile the regexp.
2011-07-20 15:04:58 +02:00
9729301aa0 Updated runtime files.
Add missing test82 files.
2011-07-18 19:40:27 +02:00
0acc5618f6 updated for version 7.3.254
Problem:    The coladd field is not reset when setting the line number for a
            ":call" command.
Solution:   Reset it.
2011-07-15 21:24:11 +02:00
35ee452de0 updated for version 7.3.253
Problem:    "echo 'abc' > ''" returns 0 or 1, depending on 'ignorecase'.
            Checks in mb_strnicmp() for illegal and truncated bytes are
            wrong.  Should not assume that byte length is equal before case
            folding.
Solution:   Add utf_safe_read_char_adv() and utf_strnicmp(). Add a test for
            this. (Ivan Krasilnikov)
2011-07-15 21:16:59 +02:00
01b2a23b95 updated for version 7.3.252
Problem:    Tests fail. (David Northfield)
Solution:   Add missing update for .ok file.
2011-07-15 17:56:16 +02:00
44286ca3c4 updated for version 7.3.251
Problem:    "gH<Del>" deletes the current line, except when it's the last
            line.
Solution:   Set the "include" flag to indicate the last line is to be deleted.
2011-07-15 17:51:34 +02:00
3d64a3176c updated for version 7.3.250
Problem:    Python: Errors in Unicode characters not handled nicely.
Solution:   Add the surrogateescape error handler. (lilydjwg)
2011-07-15 15:54:44 +02:00
50f42cadb1 updated for version 7.3.249
Problem:    Wrong indenting for array initializer.
Solution:   Detect '}' in a better way. (Lech Lorens)
2011-07-15 14:12:30 +02:00
734d99804b updated for version 7.3.248
Problem:    PC Install instructions missing install instructions.
Solution:   Step-by-step explanation. (Michael Soyka)
2011-07-15 13:52:04 +02:00
37a02ca1c2 updated for version 7.3.247
Problem:    Running tests changes the users viminfo file.  Test for patch
            7.3.245 missing.
Solution:   Add "nviminfo" to the 'viminfo' option.  Include the test.
2011-07-15 13:33:21 +02:00
19fd09a78f updated for version 7.3.246
Problem:    Repeating "f4" in "4444" skips one 4.
Solution:   Check the t_cmd flag. (Christian Brabandt)
2011-07-15 13:21:30 +02:00
54ee2b8741 updated for version 7.3.245
Problem:    Python 3.2 libraries not correctly detected.
Solution:   Add the suffix to the library name. (Niclas Zeising)
2011-07-15 13:09:51 +02:00
4da95d377f updated for version 7.3.244
Problem:    MS-Windows: Build problem with old compiler. (John Beckett)
Solution:   Only use HandleToLong() when available. (Mike Williams)
2011-07-07 17:43:41 +02:00
f56a6de10b updated for version 7.3.243
Problem:    Illegal memory access in readline().
Solution:   Swap the conditions. (Dominique Pelle)
2011-07-07 17:36:56 +02:00
b5ce04dd28 updated for version 7.3.242
Problem:    Illegal memory access in after_pathsep().
Solution:   Check that the pointer is not at the start of the file name.
            (Dominique Pelle)
2011-07-07 17:15:33 +02:00
80ae7b2287 updated for version 7.3.241
Problem:    Using CTRL-R CTRL-W on the command line may insert only part of
            the word.
Solution:   Use the cursor position instead of assuming it is at the end of
            the command. (Tyru)
2011-07-07 16:44:37 +02:00
4b9669f1dc updated for version 7.3.240
Problem:    External commands can't use pipes on MS-Windows.
Solution:   Implement pipes and use them when 'shelltemp' isn't set. (Vincent
            Berthoux)
2011-07-07 16:20:52 +02:00
03a807aaf4 updated for version 7.3.239
Problem:    Python corrects the cursor column without taking 'virtualedit'
            into account. (lilydjwg)
Solution:   Call check_cursor_col_win().
2011-07-07 15:08:58 +02:00
5cfe2d760d updated for version 7.3.238
Problem:    Compiler warning for conversion.
Solution:   Add type cast. (Mike Williams)
2011-07-07 15:04:52 +02:00
0c7437a5d2 updated for version 7.3.237
Problem:    "filetype" completion doesn't work on Windows. (Yue Wu)
Solution:   Don't use a glob pattern for the directories, use a list of
            directories. (Dominique Pelle)
2011-06-26 19:40:23 +02:00
0baa7f1cd0 updated for version 7.3.236
Problem:    Python 3 doesn't compile without +multi_byte
Solution:   Use "latin1" when MULTI_BYTE is not defined. (lilydjwg)
2011-06-26 19:13:50 +02:00
8b3e0330ba updated for version 7.3.235
Problem:    ";" gets stuck on a "t" command, it's not useful.
Solution:   Add the ';' flag in 'cpo'. (Christian Brabandt)
2011-06-26 05:36:34 +02:00
20892c1e68 updated for version 7.3.234
Problem:    With GTK menu may be popping down.
Solution:   Use event time instead of GDK_CURRENT_TIME. (Hong Xu)
2011-06-26 04:49:00 +02:00
d58ea07227 updated for version 7.3.233
Problem:    ":scriptnames" and ":breaklist" show long file names.
Solution:   Shorten to use "~/" when possible. (Jean-Rene David)
2011-06-26 04:25:30 +02:00
91805fc0db updated for version 7.3.232
Problem:    Python doesn't compile without +multi_byte
Solution:   Use "latin1" when MULTI_BYTE is not defined.
2011-06-26 04:01:44 +02:00
6e948a652d updated for version 7.3.231
Problem:    Runtime file patches failed.
Solution:   Redo the patches made against the patched files instead of the
            files in the mercurial repository.
2011-06-26 03:18:52 +02:00
f9b4815918 updated for version 7.3.230
Problem:    ":wundo" and ":rundo" don't unescape their argument.  (Aaron
            Thoma)
Solution:   Use FILE1 instead of XFILE.
2011-06-20 05:02:58 +02:00
67d441ba36 updated for version 7.3.229
Problem:    Using fork() makes gvim crash on Mac when build with
            CoreFoundation.
Solution:   Disallow fork() when __APPLE__ is defined. (Hisashi T Fujinaka)
2011-06-20 00:53:15 +02:00
914968e66d updated for version 7.3.228
Problem:    "2gj" does not always move to the correct position.
Solution:   Get length of line after moving to a next line. (James Vega)
2011-06-20 00:45:58 +02:00
54b08a5e78 updated for version 7.3.227
Problem:    Mac OS doesn't have the linewise clipboard fix.
Solution:   Also change the Mac OS file. (Bjorn Winckler)
2011-06-20 00:25:44 +02:00
251e191271 Updated runtime files. 2011-06-19 05:09:16 +02:00
d6761c3cdf updated for version 7.3.226
Problem:    On a 64 bit system "syn sync fromstart" is very slow.  (Bjorn
            Steinbrink)
Solution:   Store the state when starting to parse from the first line.
2011-06-19 04:54:21 +02:00
978287b8f8 updated for version 7.3.225
Problem:    Using "\n" in a substitute inside ":s" does not result in a line
            break.
Solution:   Change behavior inside vim_regexec_nl().   Add tests.  (Motoya
            Kurotsu)
2011-06-19 04:32:15 +02:00
5f8949656a updated for version 7.3.224
Problem:    Can't pass dict to sort function.
Solution:   Add the optional {dict} argument to sort(). (ZyX)
2011-06-19 02:55:37 +02:00
c16756d829 updated for version 7.3.223
Problem:    MingW cross compilation doesn't work with tiny features.
Solution:   Move acp_to_enc(), enc_to_utf16() and utf16_to_enc() outside of
            "#ifdef CLIPBOARD".  Fix typo in makefile.
2011-06-19 01:30:07 +02:00
26f3c637fc updated for version 7.3.222
Problem:    Warning for building GvimExt.
Solution:   Comment-out the DESCRIPTION line. (Mike Williams)
2011-06-19 01:27:34 +02:00
d44347f1e7 updated for version 7.3.221
Problem:    Text from the clipboard is sometimes handled as linewise, but not
            consistently.
Solution:   Assume the text is linewise when it ends in a CR or NL.
2011-06-19 01:14:29 +02:00
19e6094378 updated for version 7.3.220
Problem:    Python 3: vim.error is a 'str' instead of an 'Exception' object,
            so 'except' or 'raise' it causes a 'SystemError' exception.
            Buffer objects do not support slice assignment.
            When exchanging text between Vim and Python, multibyte texts become
            gabage or cause Unicode Expceptions, etc.
            'py3file' tries to read in the file as Unicode, sometimes causes
            UnicodeDecodeException
Solution:   Fix the problems. (lilydjwg)
2011-06-19 00:27:51 +02:00
f85dae3c34 Add files added by recent patches. 2011-06-13 21:21:22 +02:00
9a4d7fd214 updated for version 7.3.219
Problem:    Can't compile with GTK on Mac.
Solution:   Add some #ifdef trickery. (Ben Schmidt)
2011-06-13 02:04:00 +02:00
015de43f70 updated for version 7.3.218
Problem:    Tiny configuration problem with Python 3.
Solution:   Add abiflags in one more place. (Andreas Behr)
2011-06-13 01:32:46 +02:00
12bde494a5 updated for version 7.3.217
Problem:    Inside an "if" a ":wincmd" causes problems.
Solution:   When skipping commands let ":wincmd" skip over its argument.
2011-06-13 01:19:56 +02:00
986a0039cb updated for version 7.3.216
Problem:    When recovering a file a range of lines is missing. (Charles Jie)
Solution:   Reset the index when advancing to the next pointer block.  Add a
            test to verify recovery works.
2011-06-13 01:07:27 +02:00
f7befa9f1d updated for version 7.3.215
Problem:    Wrong file names in previous patch. (Toothpik)
Solution:   Include the option changes.
2011-06-12 22:13:40 +02:00
d9758e37ee updated for version 7.3.214
Problem:    The text displayed by ":z-" isn't exactly like old Vi.
Solution:   Add one to the start line number. (ChangZhuo Chen)
2011-06-12 22:03:23 +02:00
6ec154b57d updated for version 7.3.213
Problem:    Javascript object literal is not indented correctly.
Solution:   Make a special case for when "J1" is in 'cino'. (Luc Deschenaux)
2011-06-12 21:51:08 +02:00
456f2bb24f updated for version 7.3.212
Problem:    With Python 3.2 ":py3" fails.
Solution:   Move PyEval_InitThreads() to after Py_Initialize(). (Roland
            Puntaier)  Check abiflags in configure. (Andreas Behr)
2011-06-12 21:37:13 +02:00
03227eeb79 updated for version 7.3.211
Problem:    Compiler warning.
Solution:   Add type cast.
2011-06-12 21:25:00 +02:00
2f982e4fab updated for version 7.3.210
Problem:    Can't always find the file when using cscope.
Solution:   Add the 'cscoperelative' option. (Raghavendra D Prabhu)
2011-06-12 20:42:22 +02:00
536d95f617 updated for version 7.3.209
Problem:    MSVC Install instructions point to wrong batch file.
Solution:   Add a batch file for use with MSVC 10.
2011-06-12 20:36:09 +02:00
d8644bd646 updated for version 7.3.208
Problem:    Early terminated if statement.
Solution:   Remove the semicolon. (Lech Lorens)
2011-06-12 20:33:38 +02:00
3ed16dc6b7 updated for version 7.3.207
Problem:    Can't compile with MSVC with pentium4 and 64 bit.
Solution:   Only use SSE2 for 32 bit. (Mike Williams)
2011-06-12 20:31:31 +02:00
7154b326d0 updated for version 7.3.206
Problem:    64bit MS-Windows compiler warning.
Solution:   Use HandleToLong() instead of type cast. (Mike Williams)
2011-05-25 21:18:06 +02:00
6fa46363ad updated for version 7.3.205
Problem:    Syntax "extend" doesn't work correctly.
Solution:   Avoid calling check_state_ends() recursively (Ben Schmidt)
2011-05-25 17:56:27 +02:00
9b83c2f979 updated for version 7.3.204
Problem:    Compiler warning.
Solution:   Add type cast. (Mike Williams)
2011-05-25 17:29:44 +02:00
bd8608d979 updated for version 7.3.203
Problem:    MS-Windows: Can't run an external command without a console window.
Solution:   Support ":!start /b cmd". (Xaizek)
2011-05-25 17:06:22 +02:00
ed38b0ac41 updated for version 7.3.202
Problem:    Cannot influence the indent inside a namespace.
Solution:   Add the "N" 'cino' parameter. (Konstantin Lepa)
2011-05-25 15:16:18 +02:00
334adf0ae5 updated for version 7.3.201
Problem:    "} else" still causes following lines to be indented too much.
Solution:   Better detection for the "else" block. (Lech Lorens)
2011-05-25 13:34:04 +02:00
a660dc8f30 updated for version 7.3.200
Problem:    CTRL-D doesn't complete :lang.
Solution:   Add the missing part of the change. (Dominique Pelle)
2011-05-25 12:51:22 +02:00
72952de239 updated for version 7.3.199
Problem:    MS-Windows: Compilation problem of OLE with MingW compiler.
Solution:   Put #ifdef around declarations. (Guopeng Wen)
2011-05-25 12:09:50 +02:00
9b486ca391 updated for version 7.3.198
Problem:    No completion for ":lang".
Solution:   Get locales to complete from. (Dominique Pelle)
2011-05-19 18:26:40 +02:00
efa8e80c0b updated for version 7.3.197
Problem:    When a QuickfixCmdPost event removes all errors, Vim still tries
            to jump to the first error, resulting in E42.
Solution:   Get the number of error after the autocmd event. (Mike Lundy)
2011-05-19 17:42:59 +02:00
e659c95b01 updated for version 7.3.196
Problem:    Can't intercept a character that is going to be inserted.
Solution:   Add the InsertCharPre autocommand event. (Jakson A. Aquino)
2011-05-19 17:25:41 +02:00
496f9517cb updated for version 7.3.195
Problem:    "} else" causes following lines to be indented too much. (Rouben
            Rostamian)
Solution:   Better detection for the "else". (Lech Lorens)
2011-05-19 16:35:09 +02:00
1385c3ee7f updated for version 7.3.194
Problem:    When "b" is a symlink to directory "a", resolve("b/") doesn't
            result in "a/".  (ZyX)
Solution:   Remove the trailing slash. (Jean-Rene David)
2011-05-19 14:59:10 +02:00
9bd1a7ea28 updated for version 7.3.193
Problem:    In the command line window ":close" doesn't work properly. (Tony
            Mechelynck)
Solution:   Use Ctrl_C instead of K_IGNORE for cmdwin_result. (Jean-Rene
            David)
2011-05-19 14:50:54 +02:00
0df1102698 updated for version 7.3.192
Problem:    Ex command ":s/ \?/ /g" splits multi-byte characters into bytes.
            (Dominique Pelle)
Solution:   Advance over whole character instead of one byte.
2011-05-19 14:30:16 +02:00
2d5204ff88 Updated message translations. 2011-05-19 13:44:07 +02:00
b07269a548 updated for version 7.3.191
Problem:    Still some RISC OS stuff to remove.
Solution:   Remove files and lines. (Hong Xu)
            Remove the 'osfiletype' option code.
2011-05-19 13:41:14 +02:00
20f90cf99a Updated runtime files. 2011-05-19 12:22:51 +02:00
3a7d8c3adb updated for version 7.3.190
Problem:    When there is a "containedin" syntax argument highlighting may be
            wrong. (Radek)
Solution:   Reset current_next_list. (Ben Schmidt)
2011-05-19 12:14:10 +02:00
e2bdce3f5c updated for version 7.3.189
Problem:    Can't build without +clipboard feature. (Christian Ebert)
Solution:   Add the missing #ifdef.
2011-05-10 17:29:33 +02:00
1bfb61e80b updated for version 7.3.188
Problem:    More RISC OS files to remove.
Solution:   Remove them.  Update the file list.
2011-05-10 17:21:56 +02:00
446beb48d9 Updated runtime files. 2011-05-10 17:18:44 +02:00
1c2b2c12bb Remove the deleted RISC OS files. 2011-05-10 16:42:00 +02:00
e60acc180b updated for version 7.3.187
Problem:    The RISC OS port has obvious errors and is not being maintained.
Solution:   Remove the RISC OS files and code.
2011-05-10 16:41:25 +02:00
536681be5d updated for version 7.3.186
Problem:    When 'clipboard' contains "unnamed" or "unnamedplus" the value of
            v:register is wrong for operators without a specific register.
Solution:   Adjust the register according to 'clipboard'. (Ingo Karkat)
2011-05-10 16:12:45 +02:00
bb99322ef9 updated for version 7.3.185
Problem:    ":windo g/pattern/q" closes windows and reports "N more lines".
            (Tim Chase)
Solution:   Remember what buffer ":global" started in. (Jean-Rene David)
2011-05-10 16:00:47 +02:00
18e0bfb07c updated for version 7.3.184
Problem:    Static code analysis errors in riscOS.
Solution:   Make buffer size bigger. (Dominique Pelle)
2011-05-10 15:52:15 +02:00
5897e0c470 updated for version 7.3.183
Problem:    When Exuberant ctags binary is exuberant-ctags it's not found.
Solution:   Add configure check for exuberant-ctags.
2011-05-10 15:42:03 +02:00
05da428462 updated for version 7.3.182
Problem:    Compiler warning for uninitialized variable.
Solution:   Add dummy initializer.
2011-05-10 14:44:11 +02:00
9c520cb544 updated for version 7.3.181
Problem:    When repeating the insert of CTRL-V or a digraph the display may
            not be updated correctly.
Solution:   Only call edit_unputchar() after edit_putchar(). (Lech Lorens)
2011-05-10 14:22:16 +02:00
a4271d598b updated for version 7.3.180
Problem:    When both a middle part of 'comments' matches and an end part, the
            middle part was used errornously.
Solution:   After finding the middle part match continue looking for a better
            end part match. (partly by Lech Lorens)
2011-05-10 13:38:27 +02:00
aede6ceba3 updated for version 7.3.179
Problem:    C-indent doesn't handle colon in string correctly.
Solution:   Skip the string. (Lech Lorens)
2011-05-10 11:56:30 +02:00
4ae06c1fa5 updated for version 7.3.178
Problem:    C-indent doesn't handle code right after { correctly.
Solution:   Fix detecting unterminated line. (Lech Lorens)
2011-05-10 11:39:19 +02:00
3c9c99cb2c updated for version 7.3.177
Problem:    MS-Windows: mkdir() doesn't work properly when 'encoding' is
            "utf-8".
Solution:   Convert to utf-16. (Yukihiro Nakadaira)
2011-05-05 18:31:59 +02:00
948733a874 updated for version 7.3.176
Problem:    Ruby linking doesn't work properly on Mac OS X.
Solution:   Fix the configure check for Ruby. (Bjorn Winckler)
2011-05-05 18:10:16 +02:00
1701e4069b updated for version 7.3.175
Problem:    When 'colorcolumn' is set locally to a window, ":new" opens a
            window with the same highlighting but 'colorcolumn' is empty.
            (Tyru)
Solution:   Call check_colorcolumn() after clearing and copying options.
            (Christian Brabandt)
2011-05-05 17:32:44 +02:00
8f4ba6942d updated for version 7.3.174
Problem:    When Exuberant ctags binary is exctags it's not found.
Solution:   Add configure check for exctags. (Hong Xu)
2011-05-05 17:24:27 +02:00
d236ac0d49 updated for version 7.3.173
Problem:    After using setqflist() to make the quickfix list empty ":cwindow"
            may open the window anyway.  Also after ":vimgrep".
Solution:   Correctly check whether the list is empty. (Ingo Karkat)
2011-05-05 17:14:14 +02:00
1c32dff7d6 updated for version 7.3.172
Problem:    MS-Windows: rename() might delete the file if the name differs but
            it's actually the same file.
Solution:   Use the file handle to check if it's the same file. (Yukihiro
            Nakadaira)
2011-05-05 16:41:24 +02:00
85de20665f updated for version 7.3.171
Problem:    When the clipboard isn't supported: ":yank*" gives a confusing
            error message.
Solution:   Specifically mention that the register name is invalid.
            (Jean-Rene David)
2011-05-05 14:26:41 +02:00
72bb0d6455 updated for version 7.3.170
Problem:    VMS Makefile for testing was not updated for test77.
Solution:   Add test77 to the Makefile.
2011-04-28 19:05:05 +02:00
8e5af3e531 Updated runtime files. 2011-04-28 19:02:44 +02:00
b453a53b59 updated for version 7.3.169
Problem:    Freeing memory already freed, warning from static code analyzer.
Solution:   Initialize pointers to NULL, correct use of "mustfree". (partly by
            Dominique Pelle)
2011-04-28 17:48:44 +02:00
877b97b953 updated for version 7.3.168
Problem:    When the second argument of input() contains a CR the text up to
            that is used without asking the user. (Yasuhiro Matsumoto)
Solution:   Change CR, NL and ESC in the text to a space.
2011-04-28 17:30:09 +02:00
d88e02def5 updated for version 7.3.167
Problem:    When using the internal grep QuickFixCmdPost is not triggered.
            (Yukihiro Nakadaira)
Solution:   Change the place where autocommands are triggered.
2011-04-28 17:27:09 +02:00
f844147747 updated for version 7.3.166
Problem:    Buffer on the stack may be too big
Solution:   Allocate the space.
2011-04-28 17:24:58 +02:00
cca92ec8cf updated for version 7.3.165
Problem:    ":find" completion does not escape spaces in a directory name.
            (Isz)
Solution:   Add backslashes for EXPAND_FILES_IN_PATH. (Carlo Teubner)
2011-04-28 17:21:53 +02:00
8d2d71d4bb updated for version 7.3.164
Problem:    C-indenting: a preprocessor statement confuses detection of a
            function delcaration.
Solution:   Ignore preprocessor lines. (Lech Lorens)  Also recognize the style
            to put a comma before the argument name.
2011-04-28 13:02:09 +02:00
f1fda2d6e5 updated for version 7.3.163
Problem:    For the default of 'shellpipe' "mksh" and "pdksh" are not
            recognized.
Solution:   Recognize these shell names.
2011-04-28 12:57:36 +02:00
e962388eac updated for version 7.3.162
Problem:    No error message when assigning to a list with an index out of
            range. (Yukihiro Nakadaira)
Solution:   Add the error message.
2011-04-21 14:27:28 +02:00
d9462e394a updated for version 7.3.161
Problem:    Items on the stack may be too big.
Solution:   Make items static or allocate them.
2011-04-11 21:35:11 +02:00
ef9d6aa70d updated for version 7.3.160
Problem:    Unsafe string copying.
Solution:   Use vim_strncpy() instead of strcpy().  Use vim_strcat() instead
            of strcat().
2011-04-11 16:56:35 +02:00
0d35e91abf updated for version 7.3.159
Problem:    Using uninitialized pointer when out of memory.
Solution:   Check for NULL return value.
2011-04-11 14:29:17 +02:00
4aa97427be updated for version 7.3.158
Problem:    Might use uninitialized memory in C indenting.
Solution:   Init arrays to empty.
2011-04-11 14:27:38 +02:00
367bec852e updated for version 7.3.157
Problem:    Superfluous assignment.
Solution:   Remove assignment.
2011-04-11 14:26:19 +02:00
639304ddb1 updated for version 7.3.156
Problem:    Tty names possibly left unterminated.
Solution:   Use vim_strncpy() instead of strncpy().
2011-04-11 14:24:37 +02:00
260 changed files with 9903 additions and 10024 deletions

View File

@ -262,6 +262,7 @@ SRC_DOS = \
src/bigvim.bat \ src/bigvim.bat \
src/msvcsetup.bat \ src/msvcsetup.bat \
src/msvc2008.bat \ src/msvc2008.bat \
src/msvc2010.bat \
src/dimm.idl \ src/dimm.idl \
src/dlldata.c \ src/dlldata.c \
src/dosinst.c \ src/dosinst.c \
@ -427,9 +428,6 @@ SRC_EXTRA = \
$(SRC_VMS) \ $(SRC_VMS) \
README_os390.txt \ README_os390.txt \
src/Make_mint.mak \ src/Make_mint.mak \
src/Make_ro.mak \
src/gui_riscos.c \
src/gui_riscos.h \
src/if_sniff.c \ src/if_sniff.c \
src/infplist.xml \ src/infplist.xml \
src/link.390 \ src/link.390 \
@ -437,10 +435,6 @@ SRC_EXTRA = \
src/os_beos.h \ src/os_beos.h \
src/os_beos.rsrc \ src/os_beos.rsrc \
src/os_mint.h \ src/os_mint.h \
src/os_riscos.c \
src/os_riscos.h \
src/proto/gui_riscos.pro \
src/proto/os_riscos.pro \
src/os_vms_fix.com \ src/os_vms_fix.com \
src/toolbar.phi \ src/toolbar.phi \

View File

@ -13,9 +13,6 @@ src/if_sniff.* Interface to SNiFF. If you don't know what SNiFF is,
src/os_amiga.* Files for the Amiga port. src/os_amiga.* Files for the Amiga port.
src/gui_riscos.*
src/os_riscos.* Files for the RISC OS port.
src/gui_beos.* src/gui_beos.*
src/os_beos.* Files for the BeOS port. src/os_beos.* Files for the BeOS port.

View File

@ -1,8 +1,8 @@
" --------------------------------------------------------------------- " ---------------------------------------------------------------------
" getscript.vim " getscript.vim
" Author: Charles E. Campbell, Jr. " Author: Charles E. Campbell, Jr.
" Date: Dec 28, 2009 " Date: May 31, 2011
" Version: 32 " Version: 33
" Installing: :help glvs-install " Installing: :help glvs-install
" Usage: :help glvs " Usage: :help glvs
" "
@ -15,7 +15,7 @@
if exists("g:loaded_getscript") if exists("g:loaded_getscript")
finish finish
endif endif
let g:loaded_getscript= "v32" let g:loaded_getscript= "v33"
if &cp if &cp
echoerr "GetLatestVimScripts is not vi-compatible; not loaded (you need to set nocp)" echoerr "GetLatestVimScripts is not vi-compatible; not loaded (you need to set nocp)"
finish finish
@ -519,6 +519,7 @@ fun! s:GetOneScript(...)
" -------------------------------------------------------------------------- " --------------------------------------------------------------------------
" AutoInstall: only if doautoinstall has been requested by the plugin itself " AutoInstall: only if doautoinstall has been requested by the plugin itself
" -------------------------------------------------------------------------- " --------------------------------------------------------------------------
" call Decho("checking if plugin requested autoinstall: doautoinstall=".doautoinstall)
if doautoinstall if doautoinstall
" call Decho(" ") " call Decho(" ")
" call Decho("Autoinstall: getcwd<".getcwd()."> filereadable(".sname.")=".filereadable(sname)) " call Decho("Autoinstall: getcwd<".getcwd()."> filereadable(".sname.")=".filereadable(sname))
@ -526,7 +527,7 @@ fun! s:GetOneScript(...)
" call Decho("<".sname."> is readable") " call Decho("<".sname."> is readable")
" call Decho("exe silent !".g:GetLatestVimScripts_mv." ".shellescape(sname)." ".shellescape(s:autoinstall)) " call Decho("exe silent !".g:GetLatestVimScripts_mv." ".shellescape(sname)." ".shellescape(s:autoinstall))
exe "silent !".g:GetLatestVimScripts_mv." ".shellescape(sname)." ".shellescape(s:autoinstall) exe "silent !".g:GetLatestVimScripts_mv." ".shellescape(sname)." ".shellescape(s:autoinstall)
let curdir = escape(substitute(getcwd(),'\','/','ge'),"|[]*'\" #") let curdir = fnameescape(substitute(getcwd(),'\','/','ge'))
let installdir= curdir."/Installed" let installdir= curdir."/Installed"
if !isdirectory(installdir) if !isdirectory(installdir)
call mkdir(installdir) call mkdir(installdir)
@ -557,6 +558,11 @@ fun! s:GetOneScript(...)
exe "silent !gunzip ".shellescape(sname) exe "silent !gunzip ".shellescape(sname)
let sname= substitute(sname,'\.gz$','','') let sname= substitute(sname,'\.gz$','','')
" call Decho("decompress: new sname<".sname."> after gunzip") " call Decho("decompress: new sname<".sname."> after gunzip")
elseif sname =~ '\.xz$'
" call Decho("decompress: attempt to unxz ".sname)
exe "silent !unxz ".shellescape(sname)
let sname= substitute(sname,'\.xz$','','')
" call Decho("decompress: new sname<".sname."> after unxz")
else else
" call Decho("no decompression needed") " call Decho("no decompression needed")
endif endif

View File

@ -1,7 +1,7 @@
" Vim completion script " Vim completion script
" Language: HTML and XHTML " Language: HTML and XHTML
" Maintainer: Mikolaj Machowski ( mikmach AT wp DOT pl ) " Maintainer: Mikolaj Machowski ( mikmach AT wp DOT pl )
" Last Change: 2006 Oct 19 " Last Change: 2011 Apr 28
function! htmlcomplete#CompleteTags(findstart, base) function! htmlcomplete#CompleteTags(findstart, base)
if a:findstart if a:findstart
@ -285,6 +285,7 @@ function! htmlcomplete#CompleteTags(findstart, base)
let cssfiles = styletable + secimportfiles let cssfiles = styletable + secimportfiles
let classes = [] let classes = []
for file in cssfiles for file in cssfiles
let classlines = []
if filereadable(file) if filereadable(file)
let stylesheet = readfile(file) let stylesheet = readfile(file)
let stylefile = join(stylesheet, ' ') let stylefile = join(stylesheet, ' ')

View File

@ -1,7 +1,7 @@
" netrw.vim: Handles file transfer and remote directory listing across " netrw.vim: Handles file transfer and remote directory listing across
" AUTOLOAD SECTION " AUTOLOAD SECTION
" Date: Apr 01, 2011 " Date: May 31, 2011
" Version: 141 " Version: 142
" Maintainer: Charles E Campbell, Jr <NdrOchip@ScampbellPfamily.AbizM-NOSPAM> " Maintainer: Charles E Campbell, Jr <NdrOchip@ScampbellPfamily.AbizM-NOSPAM>
" GetLatestVimScripts: 1075 1 :AutoInstall: netrw.vim " GetLatestVimScripts: 1075 1 :AutoInstall: netrw.vim
" Copyright: Copyright (C) 1999-2010 Charles E. Campbell, Jr. {{{1 " Copyright: Copyright (C) 1999-2010 Charles E. Campbell, Jr. {{{1
@ -22,7 +22,7 @@
if &cp || exists("g:loaded_netrw") if &cp || exists("g:loaded_netrw")
finish finish
endif endif
let g:loaded_netrw = "v141" let g:loaded_netrw = "v142"
if v:version < 702 if v:version < 702
echohl WarningMsg echohl WarningMsg
echo "***warning*** this version of netrw needs vim 7.2" echo "***warning*** this version of netrw needs vim 7.2"
@ -291,7 +291,7 @@ call s:NetrwInit("g:netrw_timefmt","%c")
call s:NetrwInit("g:netrw_xstrlen",0) call s:NetrwInit("g:netrw_xstrlen",0)
call s:NetrwInit("g:NetrwTopLvlMenu","Netrw.") call s:NetrwInit("g:NetrwTopLvlMenu","Netrw.")
call s:NetrwInit("g:netrw_win95ftp",1) call s:NetrwInit("g:netrw_win95ftp",1)
call s:NetrwInit("g:netrw_winsize",25) call s:NetrwInit("g:netrw_winsize",50)
" --------------------------------------------------------------------- " ---------------------------------------------------------------------
" Default values for netrw's script variables: {{{2 " Default values for netrw's script variables: {{{2
call s:NetrwInit("g:netrw_fname_escape",' ?&;%') call s:NetrwInit("g:netrw_fname_escape",' ?&;%')
@ -1518,6 +1518,14 @@ endfun
fun! s:NetrwMethod(choice) fun! s:NetrwMethod(choice)
" call Dfunc("NetrwMethod(a:choice<".a:choice.">)") " call Dfunc("NetrwMethod(a:choice<".a:choice.">)")
" sanity check: choice should have at least three slashes in it
if strlen(substitute(a:choice,'[^/]','','g')) < 3
call netrw#ErrorMsg(s:ERROR,"not a netrw-style url; netrw uses protocol://[user@]hostname[:port]/[path])",78)
let b:netrw_method = -1
" call Dret("NetrwMethod : incorrect url format<".a:choice.">")
return
endif
" record current g:netrw_machine, if any " record current g:netrw_machine, if any
" curmachine used if protocol == ftp and no .netrc " curmachine used if protocol == ftp and no .netrc
if exists("g:netrw_machine") if exists("g:netrw_machine")
@ -1813,6 +1821,25 @@ endfun
" s:NetrwMaps: {{{2 " s:NetrwMaps: {{{2
fun! s:NetrwMaps(islocal) fun! s:NetrwMaps(islocal)
" call Dfunc("s:NetrwMaps(islocal=".a:islocal.") b:netrw_curdir<".b:netrw_curdir.">") " call Dfunc("s:NetrwMaps(islocal=".a:islocal.") b:netrw_curdir<".b:netrw_curdir.">")
" set up Rexplore and [ 2-leftmouse-click -or- c-leftmouse ]
" call Decho("set up Rexplore command")
com! Rexplore call s:NetrwRexplore(w:netrw_rexlocal,exists("w:netrw_rexdir")? w:netrw_rexdir : ".")
if g:netrw_mousemaps && g:netrw_retmap
" call Decho("set up Rexplore 2-leftmouse")
if !hasmapto("<Plug>NetrwReturn")
if maparg("<2-leftmouse>","n") == "" || maparg("<2-leftmouse>","n") =~ '^-$'
" call Decho("making map for 2-leftmouse")
nmap <unique> <silent> <2-leftmouse> <Plug>NetrwReturn
elseif maparg("<c-leftmouse>","n") == ""
" call Decho("making map for c-leftmouse")
nmap <unique> <silent> <c-leftmouse> <Plug>NetrwReturn
endif
endif
nno <silent> <Plug>NetrwReturn :Rexplore<cr>
" call Decho("made <Plug>NetrwReturn map")
endif
if a:islocal if a:islocal
" call Decho("make local maps") " call Decho("make local maps")
inoremap <buffer> <silent> a <c-o>:call <SID>NetrwHide(1)<cr> inoremap <buffer> <silent> a <c-o>:call <SID>NetrwHide(1)<cr>
@ -1925,15 +1952,22 @@ fun! s:NetrwMaps(islocal)
endif endif
let mapsafecurdir = escape(b:netrw_curdir, s:netrw_map_escape) let mapsafecurdir = escape(b:netrw_curdir, s:netrw_map_escape)
if g:netrw_mousemaps == 1 if g:netrw_mousemaps == 1
nnoremap <buffer> <silent> <leftmouse> <leftmouse>:call <SID>NetrwLeftmouse(1)<cr> nmap <buffer> <leftmouse> <Plug>NetrwLeftmouse
nnoremap <buffer> <silent> <middlemouse> <leftmouse>:call <SID>NetrwPrevWinOpen(1)<cr> nno <buffer> <silent> <Plug>NetrwLeftmouse <leftmouse>:call <SID>NetrwLeftmouse(1)<cr>
nnoremap <buffer> <silent> <s-leftmouse> <leftmouse>:call <SID>NetrwMarkFile(1,<SID>NetrwGetWord())<cr> nmap <buffer> <middlemouse> <Plug>NetrwMiddlemouse
nmap <buffer> <silent> <2-leftmouse> - nno <buffer> <silent> <Plug>NetrwMiddlemouse <leftmouse>:call <SID>NetrwPrevWinOpen(1)<cr>
nmap <buffer> <s-leftmouse> <Plug>NetrwSLeftmouse
nno <buffer> <silent> <Plug>NetrwSLeftmouse <leftmouse>:call <SID>NetrwMarkFile(1,<SID>NetrwGetWord())<cr>
nmap <buffer> <2-leftmouse> <Plug>Netrw2Leftmouse
nmap <buffer> <silent> <Plug>Netrw2Leftmouse -
imap <buffer> <leftmouse> <Plug>ILeftmouse
ino <buffer> <silent> <Plug>ILeftmouse <c-o><leftmouse><c-o>:call <SID>NetrwLeftmouse(1)<cr>
imap <buffer> <middlemouse> <Plug>IMiddlemouse
ino <buffer> <silent> <Plug>IMiddlemouse <c-o><leftmouse><c-o>:call <SID>NetrwPrevWinOpen(1)<cr>
imap <buffer> <s-leftmouse> <Plug>ISLeftmouse
ino <buffer> <silent> <Plug>ISLeftmouse <c-o><leftmouse><c-o>:call <SID>NetrwMarkFile(1,<SID>NetrwGetWord())<cr>
exe 'nnoremap <buffer> <silent> <rightmouse> <leftmouse>:call <SID>NetrwLocalRm("'.mapsafecurdir.'")<cr>' exe 'nnoremap <buffer> <silent> <rightmouse> <leftmouse>:call <SID>NetrwLocalRm("'.mapsafecurdir.'")<cr>'
exe 'vnoremap <buffer> <silent> <rightmouse> <leftmouse>:call <SID>NetrwLocalRm("'.mapsafecurdir.'")<cr>' exe 'vnoremap <buffer> <silent> <rightmouse> <leftmouse>:call <SID>NetrwLocalRm("'.mapsafecurdir.'")<cr>'
inoremap <buffer> <silent> <leftmouse> <c-o><leftmouse><c-o>:call <SID>NetrwLeftmouse(1)<cr>
inoremap <buffer> <silent> <middlemouse> <c-o><leftmouse><c-o>:call <SID>NetrwPrevWinOpen(1)<cr>
inoremap <buffer> <silent> <s-leftmouse> <c-o><leftmouse><c-o>:call <SID>NetrwMarkFile(1,<SID>NetrwGetWord())<cr>
exe 'inoremap <buffer> <silent> <rightmouse> <c-o><leftmouse><c-o>:call <SID>NetrwLocalRm("'.mapsafecurdir.'")<cr>' exe 'inoremap <buffer> <silent> <rightmouse> <c-o><leftmouse><c-o>:call <SID>NetrwLocalRm("'.mapsafecurdir.'")<cr>'
endif endif
exe 'nnoremap <buffer> <silent> <del> :call <SID>NetrwLocalRm("'.mapsafecurdir.'")<cr>' exe 'nnoremap <buffer> <silent> <del> :call <SID>NetrwLocalRm("'.mapsafecurdir.'")<cr>'
@ -2053,17 +2087,24 @@ fun! s:NetrwMaps(islocal)
let mapsafepath = escape(s:path, s:netrw_map_escape) let mapsafepath = escape(s:path, s:netrw_map_escape)
let mapsafeusermach = escape(s:user.s:machine, s:netrw_map_escape) let mapsafeusermach = escape(s:user.s:machine, s:netrw_map_escape)
nnoremap <buffer> <silent> <Plug>NetrwRefresh :call <SID>NetrwRefresh(0,<SID>NetrwBrowseChgDir(0,'./'))<cr> nnoremap <buffer> <silent> <Plug>NetrwRefresh :call <SID>NetrwRefresh(0,<SID>NetrwBrowseChgDir(0,'./'))<cr>
if g:netrw_mousemaps == 1 if g:netrw_mousemaps == 1
nnoremap <buffer> <silent> <leftmouse> <leftmouse>:call <SID>NetrwLeftmouse(0)<cr> nmap <leftmouse> <Plug>NetrwLeftmouse
nnoremap <buffer> <silent> <middlemouse> <leftmouse>:call <SID>NetrwPrevWinOpen(0)<cr> nno <buffer> <silent> <Plug>NetrwLeftmouse <leftmouse>:call <SID>NetrwLeftmouse(0)<cr>
nnoremap <buffer> <silent> <s-leftmouse> <leftmouse>:call <SID>NetrwMarkFile(0,<SID>NetrwGetWord())<cr> nmap <middlemouse> <Plug>NetrwMiddlemouse
nmap <buffer> <silent> <2-leftmouse> - nno <buffer> <silent> <middlemouse> <Plug>NetrwMiddlemouse <leftmouse>:call <SID>NetrwPrevWinOpen(0)<cr>
nmap <buffer> <s-leftmouse> <Plug>NetrwSLeftmouse
nno <buffer> <silent> <Plug>NetrwSLeftmouse <leftmouse>:call <SID>NetrwMarkFile(0,<SID>NetrwGetWord())<cr>
nmap <buffer> <2-leftmouse> <Plug>Netrw2Leftmouse
nmap <buffer> <silent> <Plug>Netrw2Leftmouse -
imap <buffer> <leftmouse> <Plug>ILeftmouse
ino <buffer> <silent> <Plug>ILeftmouse <c-o><leftmouse><c-o>:call <SID>NetrwLeftmouse(0)<cr>
imap <buffer> <middlemouse> <Plug>IMiddlemouse
ino <buffer> <silent> <Plug>IMiddlemouse <c-o><leftmouse><c-o>:call <SID>NetrwPrevWinOpen(0)<cr>
imap <buffer> <s-leftmouse> <Plug>ISLeftmouse
ino <buffer> <silent> <Plug>ISLeftmouse <c-o><leftmouse><c-o>:call <SID>NetrwMarkFile(0,<SID>NetrwGetWord())<cr>
exe 'nnoremap <buffer> <silent> <rightmouse> <leftmouse>:call <SID>NetrwRemoteRm("'.mapsafeusermach.'","'.mapsafepath.'")<cr>' exe 'nnoremap <buffer> <silent> <rightmouse> <leftmouse>:call <SID>NetrwRemoteRm("'.mapsafeusermach.'","'.mapsafepath.'")<cr>'
exe 'vnoremap <buffer> <silent> <rightmouse> <leftmouse>:call <SID>NetrwRemoteRm("'.mapsafeusermach.'","'.mapsafepath.'")<cr>' exe 'vnoremap <buffer> <silent> <rightmouse> <leftmouse>:call <SID>NetrwRemoteRm("'.mapsafeusermach.'","'.mapsafepath.'")<cr>'
inoremap <buffer> <silent> <leftmouse> <c-o><leftmouse><c-o>:call <SID>NetrwLeftmouse(0)<cr>
inoremap <buffer> <silent> <middlemouse> <c-o><leftmouse><c-o>:call <SID>NetrwPrevWinOpen(0)<cr>
inoremap <buffer> <silent> <s-leftmouse> <c-o><leftmouse><c-o>:call <SID>NetrwMarkFile(0,<SID>NetrwGetWord())<cr>
exe 'inoremap <buffer> <silent> <rightmouse> <c-o><leftmouse><c-o>:call <SID>NetrwRemoteRm("'.mapsafeusermach.'","'.mapsafepath.'")<cr>' exe 'inoremap <buffer> <silent> <rightmouse> <c-o><leftmouse><c-o>:call <SID>NetrwRemoteRm("'.mapsafeusermach.'","'.mapsafepath.'")<cr>'
endif endif
exe 'nnoremap <buffer> <silent> <del> :call <SID>NetrwRemoteRm("'.mapsafeusermach.'","'.mapsafepath.'")<cr>' exe 'nnoremap <buffer> <silent> <del> :call <SID>NetrwRemoteRm("'.mapsafeusermach.'","'.mapsafepath.'")<cr>'
@ -2081,23 +2122,8 @@ fun! s:NetrwMaps(islocal)
inoremap <buffer> <F1> <c-o>:he netrw-quickhelp<cr> inoremap <buffer> <F1> <c-o>:he netrw-quickhelp<cr>
endif endif
" set up Rexplore and leftmouse-double-click
com! Rexplore call s:NetrwRexplore(w:netrw_rexlocal,exists("w:netrw_rexdir")? w:netrw_rexdir : ".")
if g:netrw_mousemaps && g:netrw_retmap
if !hasmapto("<Plug>NetrwReturn")
if maparg("<2-leftmouse>","n") == "" || maparg("<2-leftmouse>","n") =~ '^-$'
" call Decho("making map for 2-leftmouse")
nmap <unique> <silent> <2-leftmouse> <Plug>NetrwReturn
elseif maparg("<c-leftmouse>","n") == ""
" call Decho("making map for c-leftmouse")
nmap <unique> <silent> <c-leftmouse> <Plug>NetrwReturn
endif
endif
exe 'nnoremap <silent> <Plug>NetrwReturn :Rexplore<cr>'
" call Decho("made <Plug>NetrwReturn map")
endif
keepj call s:SetRexDir(a:islocal,b:netrw_curdir) keepj call s:SetRexDir(a:islocal,b:netrw_curdir)
" call Dret("s:NetrwMaps") " call Dret("s:NetrwMaps")
endfun endfun
@ -3647,34 +3673,40 @@ fun! netrw#Explore(indx,dosplit,style,...)
if a:dosplit || &modified || a:style == 6 if a:dosplit || &modified || a:style == 6
" call Decho("case dosplit=".a:dosplit." modified=".&modified." a:style=".a:style.": dosplit or file has been modified") " call Decho("case dosplit=".a:dosplit." modified=".&modified." a:style=".a:style.": dosplit or file has been modified")
call s:SaveWinVars() call s:SaveWinVars()
let winsize= g:netrw_winsize let winsz= g:netrw_winsize
if a:indx > 0 if a:indx > 0
let winsize= a:indx let winsz= a:indx
endif endif
if a:style == 0 " Explore, Sexplore if a:style == 0 " Explore, Sexplore
" call Decho("style=0: Explore or Sexplore") " call Decho("style=0: Explore or Sexplore")
exe winsize."wincmd s" let winsz= (winsz*winheight(0))/100
exe winsz."wincmd s"
elseif a:style == 1 "Explore!, Sexplore! elseif a:style == 1 "Explore!, Sexplore!
" call Decho("style=1: Explore! or Sexplore!") " call Decho("style=1: Explore! or Sexplore!")
exe winsize."wincmd v" let winsz= (winsz*winheight(0))/100
exe winsz."wincmd v"
elseif a:style == 2 " Hexplore elseif a:style == 2 " Hexplore
" call Decho("style=2: Hexplore") " call Decho("style=2: Hexplore")
exe "bel ".winsize."wincmd s" let winsz= (winsz*winheight(0))/100
exe "bel ".winsz."wincmd s"
elseif a:style == 3 " Hexplore! elseif a:style == 3 " Hexplore!
" call Decho("style=3: Hexplore!") " call Decho("style=3: Hexplore!")
exe "abo ".winsize."wincmd s" let winsz= (winsz*winheight(0))/100
exe "abo ".winsz."wincmd s"
elseif a:style == 4 " Vexplore elseif a:style == 4 " Vexplore
" call Decho("style=4: Vexplore") " call Decho("style=4: Vexplore")
exe "lefta ".winsize."wincmd v" let winsz= (winsz*winheight(0))/100
exe "lefta ".winsz."wincmd v"
elseif a:style == 5 " Vexplore! elseif a:style == 5 " Vexplore!
" call Decho("style=5: Vexplore!") " call Decho("style=5: Vexplore!")
exe "rightb ".winsize."wincmd v" let winsz= (winsz*winheight(0))/100
exe "rightb ".winsz."wincmd v"
elseif a:style == 6 " Texplore elseif a:style == 6 " Texplore
call s:SaveBufVars() call s:SaveBufVars()
@ -4618,13 +4650,13 @@ fun! s:NetrwMarkFileCopy(islocal)
" sanity checks " sanity checks
if !exists("s:netrwmarkfilelist_{bufnr('%')}") || empty(s:netrwmarkfilelist_{bufnr('%')}) if !exists("s:netrwmarkfilelist_{bufnr('%')}") || empty(s:netrwmarkfilelist_{bufnr('%')})
keepj call netrw#ErrorMsg(2,"there are no marked files in this window (:help netrw-mf)",66) keepj call netrw#ErrorMsg(s:ERROR,"there are no marked files in this window (:help netrw-mf)",66)
" call Dret("s:NetrwMarkFileCopy 0") " call Dret("s:NetrwMarkFileCopy 0")
return 0 return 0
endif endif
" call Decho("sanity chk passed: s:netrwmarkfilelist_".bufnr('%')."<".string(s:netrwmarkfilelist_{bufnr('%')})) " call Decho("sanity chk passed: s:netrwmarkfilelist_".bufnr('%')."<".string(s:netrwmarkfilelist_{bufnr('%')}))
if !exists("s:netrwmftgt") if !exists("s:netrwmftgt")
keepj call netrw#ErrorMsg(2,"your marked file target is empty! (:help netrw-mt)",67) keepj call netrw#ErrorMsg(s:ERROR,"your marked file target is empty! (:help netrw-mt)",67)
" call Dret("s:NetrwMarkFileCopy 0") " call Dret("s:NetrwMarkFileCopy 0")
return 0 return 0
endif endif
@ -6143,7 +6175,8 @@ fun! s:NetrwSplit(mode)
if a:mode == 0 if a:mode == 0
" remote and o " remote and o
" call Decho("exe ".(g:netrw_alto? "bel " : "abo ").g:netrw_winsize."wincmd s") " call Decho("exe ".(g:netrw_alto? "bel " : "abo ").g:netrw_winsize."wincmd s")
exe (g:netrw_alto? "bel " : "abo ").g:netrw_winsize."wincmd s" let winsz= (g:netrw_winsize*winheight(0))/100
exe (g:netrw_alto? "bel " : "abo ").winsz."wincmd s"
let s:didsplit= 1 let s:didsplit= 1
keepj call s:RestoreWinVars() keepj call s:RestoreWinVars()
keepj call s:NetrwBrowse(0,s:NetrwBrowseChgDir(0,s:NetrwGetWord())) keepj call s:NetrwBrowse(0,s:NetrwBrowseChgDir(0,s:NetrwGetWord()))
@ -6162,7 +6195,8 @@ fun! s:NetrwSplit(mode)
elseif a:mode == 2 elseif a:mode == 2
" remote and v " remote and v
" call Decho("exe ".(g:netrw_altv? "rightb " : "lefta ").g:netrw_winsize."wincmd v") " call Decho("exe ".(g:netrw_altv? "rightb " : "lefta ").g:netrw_winsize."wincmd v")
exe (g:netrw_altv? "rightb " : "lefta ").g:netrw_winsize."wincmd v" let winsz= (g:netrw_winsize*winwidth(0))/100
exe (g:netrw_altv? "rightb " : "lefta ").winsz."wincmd v"
let s:didsplit= 1 let s:didsplit= 1
keepj call s:RestoreWinVars() keepj call s:RestoreWinVars()
keepj call s:NetrwBrowse(0,s:NetrwBrowseChgDir(0,s:NetrwGetWord())) keepj call s:NetrwBrowse(0,s:NetrwBrowseChgDir(0,s:NetrwGetWord()))
@ -6171,7 +6205,8 @@ fun! s:NetrwSplit(mode)
elseif a:mode == 3 elseif a:mode == 3
" local and o " local and o
" call Decho("exe ".(g:netrw_alto? "bel " : "abo ").g:netrw_winsize."wincmd s") " call Decho("exe ".(g:netrw_alto? "bel " : "abo ").g:netrw_winsize."wincmd s")
exe (g:netrw_alto? "bel " : "abo ").g:netrw_winsize."wincmd s" let winsz= (g:netrw_winsize*winheight(0))/100
exe (g:netrw_alto? "bel " : "abo ").winsz."wincmd s"
let s:didsplit= 1 let s:didsplit= 1
keepj call s:RestoreWinVars() keepj call s:RestoreWinVars()
keepj call netrw#LocalBrowseCheck(s:NetrwBrowseChgDir(1,s:NetrwGetWord())) keepj call netrw#LocalBrowseCheck(s:NetrwBrowseChgDir(1,s:NetrwGetWord()))
@ -6192,7 +6227,8 @@ fun! s:NetrwSplit(mode)
elseif a:mode == 5 elseif a:mode == 5
" local and v " local and v
" call Decho("exe ".(g:netrw_altv? "rightb " : "lefta ").g:netrw_winsize."wincmd v") " call Decho("exe ".(g:netrw_altv? "rightb " : "lefta ").g:netrw_winsize."wincmd v")
exe (g:netrw_altv? "rightb " : "lefta ").g:netrw_winsize."wincmd v" let winsz= (g:netrw_winsize*winwidth(0))/100
exe (g:netrw_altv? "rightb " : "lefta ").winsz."wincmd v"
let s:didsplit= 1 let s:didsplit= 1
keepj call s:RestoreWinVars() keepj call s:RestoreWinVars()
keepj call netrw#LocalBrowseCheck(s:NetrwBrowseChgDir(1,s:NetrwGetWord())) keepj call netrw#LocalBrowseCheck(s:NetrwBrowseChgDir(1,s:NetrwGetWord()))
@ -6826,8 +6862,8 @@ fun! s:NetrwRemoteListing()
" call Decho("2: exe sil r! ".listcmd) " call Decho("2: exe sil r! ".listcmd)
exe "sil! keepalt r! ".listcmd exe "sil! keepalt r! ".listcmd
else else
" call Decho("3: exe sil r! ".listcmd.' '.shellescape(s:path,1)) " call Decho("3: exe sil r! ".listcmd.' '.shellescape(fnameescape(s:path),1))
exe "sil! keepalt r! ".listcmd.' '.shellescape(s:path,1) exe "sil! keepalt r! ".listcmd.' '.shellescape(fnameescape(s:path),1)
" call Decho("listcmd<".listcmd."> path<".s:path.">") " call Decho("listcmd<".listcmd."> path<".s:path.">")
endif endif
endif endif
@ -7278,12 +7314,12 @@ fun! s:LocalListing()
" get the list of files contained in the current directory " get the list of files contained in the current directory
let dirname = b:netrw_curdir let dirname = b:netrw_curdir
let dirnamelen = s:Strlen(b:netrw_curdir) let dirnamelen = s:Strlen(b:netrw_curdir)
let filelist = glob(s:ComposePath(dirname,"*")) let filelist = glob(s:ComposePath(fnameescape(dirname),"*"))
" call Decho("glob(dirname<".dirname."/*>)=".filelist) " call Decho("glob(dirname<".dirname."/*>)=".filelist)
if filelist != "" if filelist != ""
let filelist= filelist."\n" let filelist= filelist."\n"
endif endif
let filelist= filelist.glob(s:ComposePath(dirname,".*")) let filelist= filelist.glob(s:ComposePath(fnameescape(dirname),".*"))
" call Decho("glob(dirname<".dirname."/.*>)=".filelist) " call Decho("glob(dirname<".dirname."/.*>)=".filelist)
" Coding choice: either elide ./ if present " Coding choice: either elide ./ if present
@ -7797,7 +7833,7 @@ endfun
" 0=note = s:NOTE " 0=note = s:NOTE
" 1=warning = s:WARNING " 1=warning = s:WARNING
" 2=error = s:ERROR " 2=error = s:ERROR
" Dec 03, 2009 : max errnum currently is 77 " Apr 18, 2011 : max errnum currently is 78
fun! netrw#ErrorMsg(level,msg,errnum) fun! netrw#ErrorMsg(level,msg,errnum)
" call Dfunc("netrw#ErrorMsg(level=".a:level." msg<".a:msg."> errnum=".a:errnum.") g:netrw_use_errorwindow=".g:netrw_use_errorwindow) " call Dfunc("netrw#ErrorMsg(level=".a:level." msg<".a:msg."> errnum=".a:errnum.") g:netrw_use_errorwindow=".g:netrw_use_errorwindow)
@ -8326,7 +8362,7 @@ endfun
" --------------------------------------------------------------------- " ---------------------------------------------------------------------
" s:RemotePathAnalysis: {{{2 " s:RemotePathAnalysis: {{{2
fun! s:RemotePathAnalysis(dirname) fun! s:RemotePathAnalysis(dirname)
" call Dfunc("s:RemotePathAnalysis()") " call Dfunc("s:RemotePathAnalysis(a:dirname<".a:dirname.">)")
let dirpat = '^\(\w\{-}\)://\(\w\+@\)\=\([^/:#]\+\)\%([:#]\(\d\+\)\)\=/\(.*\)$' let dirpat = '^\(\w\{-}\)://\(\w\+@\)\=\([^/:#]\+\)\%([:#]\(\d\+\)\)\=/\(.*\)$'
let s:method = substitute(a:dirname,dirpat,'\1','') let s:method = substitute(a:dirname,dirpat,'\1','')

View File

@ -1,13 +1,13 @@
" tar.vim: Handles browsing tarfiles " tar.vim: Handles browsing tarfiles
" AUTOLOAD PORTION " AUTOLOAD PORTION
" Date: Aug 09, 2010 " Date: May 31, 2011
" Version: 26 " Version: 27
" Maintainer: Charles E Campbell, Jr <NdrOchip@ScampbellPfamily.AbizM-NOSPAM> " Maintainer: Charles E Campbell, Jr <NdrOchip@ScampbellPfamily.AbizM-NOSPAM>
" License: Vim License (see vim's :help license) " License: Vim License (see vim's :help license)
" "
" Contains many ideas from Michael Toren's <tar.vim> " Contains many ideas from Michael Toren's <tar.vim>
" "
" Copyright: Copyright (C) 2005-2009 Charles E. Campbell, Jr. {{{1 " Copyright: Copyright (C) 2005-2011 Charles E. Campbell, Jr. {{{1
" Permission is hereby granted to use and distribute this code, " Permission is hereby granted to use and distribute this code,
" with or without modifications, provided that this copyright " with or without modifications, provided that this copyright
" notice is copied with it. Like anything else that's free, " notice is copied with it. Like anything else that's free,
@ -22,7 +22,7 @@
if &cp || exists("g:loaded_tar") if &cp || exists("g:loaded_tar")
finish finish
endif endif
let g:loaded_tar= "v26" let g:loaded_tar= "v27"
if v:version < 702 if v:version < 702
echohl WarningMsg echohl WarningMsg
echo "***warning*** this version of tar needs vim 7.2" echo "***warning*** this version of tar needs vim 7.2"
@ -47,6 +47,17 @@ endif
if !exists("g:tar_writeoptions") if !exists("g:tar_writeoptions")
let g:tar_writeoptions= "uf" let g:tar_writeoptions= "uf"
endif endif
if !exists("g:netrw_cygwin")
if has("win32") || has("win95") || has("win64") || has("win16")
if &shell =~ '\%(\<bash\>\|\<zsh\>\)\%(\.exe\)\=$'
let g:netrw_cygwin= 1
else
let g:netrw_cygwin= 0
endif
else
let g:netrw_cygwin= 0
endif
endif
if !exists("g:tar_copycmd") if !exists("g:tar_copycmd")
if !exists("g:netrw_localcopycmd") if !exists("g:netrw_localcopycmd")
if has("win32") || has("win95") || has("win64") || has("win16") if has("win32") || has("win95") || has("win64") || has("win16")
@ -63,17 +74,6 @@ if !exists("g:tar_copycmd")
endif endif
let g:tar_copycmd= g:netrw_localcopycmd let g:tar_copycmd= g:netrw_localcopycmd
endif endif
if !exists("g:netrw_cygwin")
if has("win32") || has("win95") || has("win64") || has("win16")
if &shell =~ '\%(\<bash\>\|\<zsh\>\)\%(\.exe\)\=$'
let g:netrw_cygwin= 1
else
let g:netrw_cygwin= 0
endif
else
let g:netrw_cygwin= 0
endif
endif
if !exists("g:tar_extractcmd") if !exists("g:tar_extractcmd")
let g:tar_extractcmd= "tar -xf" let g:tar_extractcmd= "tar -xf"
endif endif
@ -142,9 +142,9 @@ fun! tar#Browse(tarfile)
call setline(lastline+1,'" tar.vim version '.g:loaded_tar) call setline(lastline+1,'" tar.vim version '.g:loaded_tar)
call setline(lastline+2,'" Browsing tarfile '.a:tarfile) call setline(lastline+2,'" Browsing tarfile '.a:tarfile)
call setline(lastline+3,'" Select a file with cursor and press ENTER') call setline(lastline+3,'" Select a file with cursor and press ENTER')
$put ='' keepj $put =''
0d keepj 0d
$ keepj $
let tarfile= a:tarfile let tarfile= a:tarfile
if has("win32") && executable("cygpath") if has("win32") && executable("cygpath")
@ -154,26 +154,26 @@ fun! tar#Browse(tarfile)
let curlast= line("$") let curlast= line("$")
if tarfile =~# '\.\(gz\|tgz\)$' if tarfile =~# '\.\(gz\|tgz\)$'
" call Decho("1: exe silent r! gzip -d -c -- ".shellescape(tarfile,1)." | ".g:tar_cmd." -".g:tar_browseoptions." - ") " call Decho("1: exe silent r! gzip -d -c -- ".shellescape(tarfile,1)." | ".g:tar_cmd." -".g:tar_browseoptions." - ")
exe "silent r! gzip -d -c -- ".shellescape(tarfile,1)." | ".g:tar_cmd." -".g:tar_browseoptions." - " exe "sil! r! gzip -d -c -- ".shellescape(tarfile,1)." | ".g:tar_cmd." -".g:tar_browseoptions." - "
elseif tarfile =~# '\.lrp' elseif tarfile =~# '\.lrp'
" call Decho("2: exe silent r! cat -- ".shellescape(tarfile,1)."|gzip -d -c -|".g:tar_cmd." -".g:tar_browseoptions." - ") " call Decho("2: exe silent r! cat -- ".shellescape(tarfile,1)."|gzip -d -c -|".g:tar_cmd." -".g:tar_browseoptions." - ")
exe "silent r! cat -- ".shellescape(tarfile,1)."|gzip -d -c -|".g:tar_cmd." -".g:tar_browseoptions." - " exe "sil! r! cat -- ".shellescape(tarfile,1)."|gzip -d -c -|".g:tar_cmd." -".g:tar_browseoptions." - "
elseif tarfile =~# '\.bz2$' elseif tarfile =~# '\.bz2$'
" call Decho("3: exe silent r! bzip2 -d -c -- ".shellescape(tarfile,1)." | ".g:tar_cmd." -".g:tar_browseoptions." - ") " call Decho("3: exe silent r! bzip2 -d -c -- ".shellescape(tarfile,1)." | ".g:tar_cmd." -".g:tar_browseoptions." - ")
exe "silent r! bzip2 -d -c -- ".shellescape(tarfile,1)." | ".g:tar_cmd." -".g:tar_browseoptions." - " exe "sil! r! bzip2 -d -c -- ".shellescape(tarfile,1)." | ".g:tar_cmd." -".g:tar_browseoptions." - "
elseif tarfile =~# '\.lzma$' elseif tarfile =~# '\.lzma$'
" call Decho("3: exe silent r! lzma -d -c -- ".shellescape(tarfile,1)." | ".g:tar_cmd." -".g:tar_browseoptions." - ") " call Decho("3: exe silent r! lzma -d -c -- ".shellescape(tarfile,1)." | ".g:tar_cmd." -".g:tar_browseoptions." - ")
exe "silent r! lzma -d -c -- ".shellescape(tarfile,1)." | ".g:tar_cmd." -".g:tar_browseoptions." - " exe "sil! r! lzma -d -c -- ".shellescape(tarfile,1)." | ".g:tar_cmd." -".g:tar_browseoptions." - "
elseif tarfile =~# '\.\(xz\|txz\)$' elseif tarfile =~# '\.\(xz\|txz\)$'
" call Decho("3: exe silent r! xz --decompress --stdout -- ".shellescape(tarfile,1)." | ".g:tar_cmd." -".g:tar_browseoptions." - ") " call Decho("3: exe silent r! xz --decompress --stdout -- ".shellescape(tarfile,1)." | ".g:tar_cmd." -".g:tar_browseoptions." - ")
exe "silent r! xz --decompress --stdout -- ".shellescape(tarfile,1)." | ".g:tar_cmd." -".g:tar_browseoptions." - " exe "sil! r! xz --decompress --stdout -- ".shellescape(tarfile,1)." | ".g:tar_cmd." -".g:tar_browseoptions." - "
else else
if tarfile =~ '^\s*-' if tarfile =~ '^\s*-'
" A file name starting with a dash is taken as an option. Prepend ./ to avoid that. " A file name starting with a dash is taken as an option. Prepend ./ to avoid that.
let tarfile = substitute(tarfile, '-', './-', '') let tarfile = substitute(tarfile, '-', './-', '')
endif endif
" call Decho("4: exe silent r! ".g:tar_cmd." -".g:tar_browseoptions." ".shellescape(tarfile,0)) " call Decho("4: exe silent r! ".g:tar_cmd." -".g:tar_browseoptions." ".shellescape(tarfile,0))
exe "silent r! ".g:tar_cmd." -".g:tar_browseoptions." ".shellescape(tarfile,1) exe "sil! r! ".g:tar_cmd." -".g:tar_browseoptions." ".shellescape(tarfile,1)
endif endif
if v:shell_error != 0 if v:shell_error != 0
redraw! redraw!
@ -184,12 +184,12 @@ fun! tar#Browse(tarfile)
if line("$") == curlast || ( line("$") == (curlast + 1) && getline("$") =~ '\c\%(warning\|error\|inappropriate\|unrecognized\)') if line("$") == curlast || ( line("$") == (curlast + 1) && getline("$") =~ '\c\%(warning\|error\|inappropriate\|unrecognized\)')
redraw! redraw!
echohl WarningMsg | echo "***warning*** (tar#Browse) ".a:tarfile." doesn't appear to be a tar file" | echohl None echohl WarningMsg | echo "***warning*** (tar#Browse) ".a:tarfile." doesn't appear to be a tar file" | echohl None
silent %d keepj sil! %d
let eikeep= &ei let eikeep= &ei
set ei=BufReadCmd,FileReadCmd set ei=BufReadCmd,FileReadCmd
exe "r ".fnameescape(a:tarfile) exe "r ".fnameescape(a:tarfile)
let &ei= eikeep let &ei= eikeep
1d keepj sil! 1d
" call Dret("tar#Browse : a:tarfile<".a:tarfile.">") " call Dret("tar#Browse : a:tarfile<".a:tarfile.">")
return return
endif endif
@ -286,19 +286,19 @@ fun! tar#Read(fname,mode)
endif endif
if tarfile =~# '\.bz2$' if tarfile =~# '\.bz2$'
" call Decho("7: exe silent r! bzip2 -d -c ".shellescape(tarfile,1)."| ".g:tar_cmd." -".g:tar_readoptions." - ".tar_secure.shellescape(fname,1).decmp) " call Decho("7: exe silent r! bzip2 -d -c ".shellescape(tarfile,1)."| ".g:tar_cmd." -".g:tar_readoptions." - ".tar_secure.shellescape(fname,1).decmp)
exe "silent r! bzip2 -d -c -- ".shellescape(tarfile,1)."| ".g:tar_cmd." -".g:tar_readoptions." - ".tar_secure.shellescape(fname,1).decmp exe "sil! r! bzip2 -d -c -- ".shellescape(tarfile,1)."| ".g:tar_cmd." -".g:tar_readoptions." - ".tar_secure.shellescape(fname,1).decmp
elseif tarfile =~# '\.\(gz\|tgz\)$' elseif tarfile =~# '\.\(gz\|tgz\)$'
" call Decho("5: exe silent r! gzip -d -c -- ".shellescape(tarfile,1)."| ".g:tar_cmd.' -'.g:tar_readoptions.' - '.tar_secure.shellescape(fname,1)) " call Decho("5: exe silent r! gzip -d -c -- ".shellescape(tarfile,1)."| ".g:tar_cmd.' -'.g:tar_readoptions.' - '.tar_secure.shellescape(fname,1))
exe "silent r! gzip -d -c -- ".shellescape(tarfile,1)."| ".g:tar_cmd." -".g:tar_readoptions." - ".tar_secure.shellescape(fname,1).decmp exe "sil! r! gzip -d -c -- ".shellescape(tarfile,1)."| ".g:tar_cmd." -".g:tar_readoptions." - ".tar_secure.shellescape(fname,1).decmp
elseif tarfile =~# '\.lrp$' elseif tarfile =~# '\.lrp$'
" call Decho("6: exe silent r! cat ".shellescape(tarfile,1)." | gzip -d -c - | ".g:tar_cmd." -".g:tar_readoptions." - ".tar_secure.shellescape(fname,1).decmp) " call Decho("6: exe silent r! cat ".shellescape(tarfile,1)." | gzip -d -c - | ".g:tar_cmd." -".g:tar_readoptions." - ".tar_secure.shellescape(fname,1).decmp)
exe "silent r! cat -- ".shellescape(tarfile,1)." | gzip -d -c - | ".g:tar_cmd." -".g:tar_readoptions." - ".tar_secure.shellescape(fname,1).decmp exe "sil! r! cat -- ".shellescape(tarfile,1)." | gzip -d -c - | ".g:tar_cmd." -".g:tar_readoptions." - ".tar_secure.shellescape(fname,1).decmp
elseif tarfile =~# '\.lzma$' elseif tarfile =~# '\.lzma$'
" call Decho("7: exe silent r! lzma -d -c ".shellescape(tarfile,1)."| ".g:tar_cmd." -".g:tar_readoptions." - ".tar_secure.shellescape(fname,1).decmp) " call Decho("7: exe silent r! lzma -d -c ".shellescape(tarfile,1)."| ".g:tar_cmd." -".g:tar_readoptions." - ".tar_secure.shellescape(fname,1).decmp)
exe "silent r! lzma -d -c -- ".shellescape(tarfile,1)."| ".g:tar_cmd." -".g:tar_readoptions." - ".tar_secure.shellescape(fname,1).decmp exe "sil! r! lzma -d -c -- ".shellescape(tarfile,1)."| ".g:tar_cmd." -".g:tar_readoptions." - ".tar_secure.shellescape(fname,1).decmp
elseif tarfile =~# '\.\(xz\|txz\)$' elseif tarfile =~# '\.\(xz\|txz\)$'
" call Decho("3: exe silent r! xz --decompress --stdout -- ".shellescape(tarfile,1)." | ".g:tar_cmd." -".g:tar_readoptions." - ".tar_secure.shellescape(fname,1).decmp) " call Decho("3: exe silent r! xz --decompress --stdout -- ".shellescape(tarfile,1)." | ".g:tar_cmd." -".g:tar_readoptions." - ".tar_secure.shellescape(fname,1).decmp)
exe "silent r! xz --decompress --stdout -- ".shellescape(tarfile,1)." | ".g:tar_cmd." -".g:tar_readoptions." - ".tar_secure.shellescape(fname,1).decmp exe "sil! r! xz --decompress --stdout -- ".shellescape(tarfile,1)." | ".g:tar_cmd." -".g:tar_readoptions." - ".tar_secure.shellescape(fname,1).decmp
else else
if tarfile =~ '^\s*-' if tarfile =~ '^\s*-'
" A file name starting with a dash is taken as an option. Prepend ./ to avoid that. " A file name starting with a dash is taken as an option. Prepend ./ to avoid that.
@ -317,7 +317,7 @@ fun! tar#Read(fname,mode)
exe "file tarfile::".fnameescape(fname) exe "file tarfile::".fnameescape(fname)
" cleanup " cleanup
0d keepj sil! 0d
set nomod set nomod
let &report= repkeep let &report= repkeep

View File

@ -1,6 +1,6 @@
" Vim autoload file for the tohtml plugin. " Vim autoload file for the tohtml plugin.
" Maintainer: Ben Fritz <fritzophrenic@gmail.com> " Maintainer: Ben Fritz <fritzophrenic@gmail.com>
" Last Change: 2011 Jan 05 " Last Change: 2011 Apr 05
" "
" Additional contributors: " Additional contributors:
" "
@ -16,7 +16,7 @@ set cpo-=C
" Automatically find charsets from all encodings supported natively by Vim. With " Automatically find charsets from all encodings supported natively by Vim. With
" the 8bit- and 2byte- prefixes, Vim can actually support more encodings than " the 8bit- and 2byte- prefixes, Vim can actually support more encodings than
" this. Let the user specify these however since they won't be supported on " this. Let the user specify these however since they won't be supported on
" every system. TODO: how? g:html_charsets and g:html_encodings? " every system.
" "
" Note, not all of Vim's supported encodings have a charset to use. " Note, not all of Vim's supported encodings have a charset to use.
" "
@ -312,8 +312,9 @@ func! tohtml#Convert2HTML(line1, line2) "{{{
" figure out whether current charset and encoding will work, if not " figure out whether current charset and encoding will work, if not
" default to UTF-8 " default to UTF-8
if !exists('g:html_use_encoding') && if !exists('g:html_use_encoding') &&
\ (&l:fileencoding!='' && &l:fileencoding!=s:settings.vim_encoding || \ (((&l:fileencoding=='' || (&l:buftype!='' && &l:buftype!=?'help'))
\ &l:fileencoding=='' && &encoding!=s:settings.vim_encoding) \ && &encoding!=?s:settings.vim_encoding)
\ || &l:fileencoding!='' && &l:fileencoding!=?s:settings.vim_encoding)
echohl WarningMsg echohl WarningMsg
echomsg "TOhtml: mismatched file encodings in Diff buffers, using UTF-8" echomsg "TOhtml: mismatched file encodings in Diff buffers, using UTF-8"
echohl None echohl None
@ -603,6 +604,7 @@ func! tohtml#GetUserSettings() "{{{
call tohtml#GetOption(user_settings, 'no_progress', !has("statusline") ) call tohtml#GetOption(user_settings, 'no_progress', !has("statusline") )
call tohtml#GetOption(user_settings, 'diff_one_file', 0 ) call tohtml#GetOption(user_settings, 'diff_one_file', 0 )
call tohtml#GetOption(user_settings, 'number_lines', &number ) call tohtml#GetOption(user_settings, 'number_lines', &number )
call tohtml#GetOption(user_settings, 'pre_wrap', &wrap )
call tohtml#GetOption(user_settings, 'use_css', 1 ) call tohtml#GetOption(user_settings, 'use_css', 1 )
call tohtml#GetOption(user_settings, 'ignore_conceal', 0 ) call tohtml#GetOption(user_settings, 'ignore_conceal', 0 )
call tohtml#GetOption(user_settings, 'ignore_folding', 0 ) call tohtml#GetOption(user_settings, 'ignore_folding', 0 )
@ -641,7 +643,13 @@ func! tohtml#GetUserSettings() "{{{
" aren't allowed inside a <pre> block " aren't allowed inside a <pre> block
if !user_settings.use_css if !user_settings.use_css
let user_settings.no_pre = 1 let user_settings.no_pre = 1
endif "}}} endif
" pre_wrap doesn't do anything if not using pre or not using CSS
if user_settings.no_pre || !user_settings.use_css
let user_settings.pre_wrap=0
endif
"}}}
" set up expand_tabs option after all the overrides so we know the " set up expand_tabs option after all the overrides so we know the
" appropriate defaults {{{ " appropriate defaults {{{
@ -669,9 +677,16 @@ func! tohtml#GetUserSettings() "{{{
endif endif
else else
" Figure out proper MIME charset from 'fileencoding' if possible " Figure out proper MIME charset from 'fileencoding' if possible
if &l:fileencoding != '' if &l:fileencoding != ''
let user_settings.vim_encoding = &l:fileencoding " If the buffer is not a "normal" type, the 'fileencoding' value may not
call tohtml#CharsetFromEncoding(user_settings) " be trusted; since the buffer should not be written the fileencoding is
" not intended to be used.
if &l:buftype=='' || &l:buftype==?'help'
let user_settings.vim_encoding = &l:fileencoding
call tohtml#CharsetFromEncoding(user_settings)
else
let user_settings.encoding = '' " trigger detection using &encoding
endif
endif endif
" else from 'encoding' if possible " else from 'encoding' if possible

View File

@ -1,9 +1,9 @@
" vimball.vim : construct a file containing both paths and files " vimball.vim : construct a file containing both paths and files
" Author: Charles E. Campbell, Jr. " Author: Charles E. Campbell, Jr.
" Date: Apr 12, 2010 " Date: Apr 02, 2011
" Version: 31 " Version: 33
" GetLatestVimScripts: 1502 1 :AutoInstall: vimball.vim " GetLatestVimScripts: 1502 1 :AutoInstall: vimball.vim
" Copyright: (c) 2004-2009 by Charles E. Campbell, Jr. " Copyright: (c) 2004-2011 by Charles E. Campbell, Jr.
" The VIM LICENSE applies to Vimball.vim, and Vimball.txt " The VIM LICENSE applies to Vimball.vim, and Vimball.txt
" (see |copyright|) except use "Vimball" instead of "Vim". " (see |copyright|) except use "Vimball" instead of "Vim".
" No warranty, express or implied. " No warranty, express or implied.
@ -14,7 +14,7 @@
if &cp || exists("g:loaded_vimball") if &cp || exists("g:loaded_vimball")
finish finish
endif endif
let g:loaded_vimball = "v31" let g:loaded_vimball = "v33"
if v:version < 702 if v:version < 702
echohl WarningMsg echohl WarningMsg
echo "***warning*** this version of vimball needs vim 7.2" echo "***warning*** this version of vimball needs vim 7.2"
@ -67,10 +67,10 @@ endif
" vimball#MkVimball: creates a vimball given a list of paths to files {{{2 " vimball#MkVimball: creates a vimball given a list of paths to files {{{2
" Input: " Input:
" line1,line2: a range of lines containing paths to files to be included in the vimball " line1,line2: a range of lines containing paths to files to be included in the vimball
" writelevel : if true, force a write to filename.vba, even if it exists " writelevel : if true, force a write to filename.vmb, even if it exists
" (usually accomplished with :MkVimball! ... " (usually accomplished with :MkVimball! ...
" filename : base name of file to be created (ie. filename.vba) " filename : base name of file to be created (ie. filename.vmb)
" Output: a filename.vba using vimball format: " Output: a filename.vmb using vimball format:
" path " path
" filesize " filesize
" [file] " [file]
@ -80,12 +80,12 @@ endif
fun! vimball#MkVimball(line1,line2,writelevel,...) range fun! vimball#MkVimball(line1,line2,writelevel,...) range
" call Dfunc("MkVimball(line1=".a:line1." line2=".a:line2." writelevel=".a:writelevel." vimballname<".a:1.">) a:0=".a:0) " call Dfunc("MkVimball(line1=".a:line1." line2=".a:line2." writelevel=".a:writelevel." vimballname<".a:1.">) a:0=".a:0)
if a:1 =~ '\.vim$' || a:1 =~ '\.txt$' if a:1 =~ '\.vim$' || a:1 =~ '\.txt$'
let vbname= substitute(a:1,'\.\a\{3}$','.vba','') let vbname= substitute(a:1,'\.\a\{3}$','.vmb','')
else else
let vbname= a:1 let vbname= a:1
endif endif
if vbname !~ '\.vba$' if vbname !~ '\.vmb$'
let vbname= vbname.'.vba' let vbname= vbname.'.vmb'
endif endif
" call Decho("vbname<".vbname.">") " call Decho("vbname<".vbname.">")
if !a:writelevel && a:1 =~ '[\/]' if !a:writelevel && a:1 =~ '[\/]'
@ -134,7 +134,7 @@ fun! vimball#MkVimball(line1,line2,writelevel,...) range
" create/switch to mkvimball tab " create/switch to mkvimball tab
if !exists("vbtabnr") if !exists("vbtabnr")
tabnew tabnew
silent! file Vimball sil! file Vimball
let vbtabnr= tabpagenr() let vbtabnr= tabpagenr()
else else
exe "tabn ".vbtabnr exe "tabn ".vbtabnr
@ -195,8 +195,8 @@ fun! vimball#Vimball(really,...)
" call Dfunc("vimball#Vimball(really=".a:really.") a:0=".a:0) " call Dfunc("vimball#Vimball(really=".a:really.") a:0=".a:0)
if v:version < 701 || (v:version == 701 && !exists('*fnameescape')) if v:version < 701 || (v:version == 701 && !exists('*fnameescape'))
echoerr "your vim is missing the fnameescape() function" echoerr "your vim is missing the fnameescape() function (pls upgrade to vim 7.2 or later)"
" call Dret("vimball#Vimball : needs 7.1 with patch 299") " call Dret("vimball#Vimball : needs 7.1 with patch 299 or later")
return return
endif endif
@ -214,7 +214,7 @@ fun! vimball#Vimball(really,...)
" set up vimball tab " set up vimball tab
" call Decho("setting up vimball tab") " call Decho("setting up vimball tab")
tabnew tabnew
silent! file Vimball sil! file Vimball
let vbtabnr= tabpagenr() let vbtabnr= tabpagenr()
let didhelp= "" let didhelp= ""
@ -254,11 +254,10 @@ fun! vimball#Vimball(really,...)
while 1 < linenr && linenr < line("$") while 1 < linenr && linenr < line("$")
let fname = substitute(getline(linenr),'\t\[\[\[1$','','') let fname = substitute(getline(linenr),'\t\[\[\[1$','','')
let fname = substitute(fname,'\\','/','g') let fname = substitute(fname,'\\','/','g')
" let fsize = getline(linenr+1)+0
let fsize = substitute(getline(linenr+1),'^\(\d\+\).\{-}$','\1','')+0 let fsize = substitute(getline(linenr+1),'^\(\d\+\).\{-}$','\1','')+0
let fenc = substitute(getline(linenr+1),'^\d\+\s*\(\S\+\)$','\1','') let fenc = substitute(getline(linenr+1),'^\d\+\s*\(\S\{-}\)$','\1','')
let filecnt = filecnt + 1 let filecnt = filecnt + 1
" call Decho("fname<".fname."> fsize=".fsize." filecnt=".filecnt) " call Decho("fname<".fname."> fsize=".fsize." filecnt=".filecnt. " fenc=".fenc)
if a:really if a:really
echomsg "extracted <".fname.">: ".fsize." lines" echomsg "extracted <".fname.">: ".fsize." lines"
@ -306,20 +305,22 @@ fun! vimball#Vimball(really,...)
let linenr = linenr + 2 let linenr = linenr + 2
let lastline = linenr + fsize - 1 let lastline = linenr + fsize - 1
" call Decho("exe ".linenr.",".lastline."yank a") " call Decho("exe ".linenr.",".lastline."yank a")
exe "silent ".linenr.",".lastline."yank a" " no point in handling a zero-length file
if lastline >= linenr
exe "silent ".linenr.",".lastline."yank a"
" copy "a" buffer into tab " copy "a" buffer into tab
" call Decho('copy "a buffer into tab#'.vbtabnr) " call Decho('copy "a buffer into tab#'.vbtabnr)
exe "tabn ".vbtabnr exe "tabn ".vbtabnr
setlocal ma setlocal ma
silent! %d sil! %d
silent put a silent put a
1 1
silent d sil! d
" write tab to file " write tab to file
if a:really if a:really
let fnamepath= home."/".fname let fnamepath= home."/".fname
" call Decho("exe w! ".fnameescape(fnamepath)) " call Decho("exe w! ".fnameescape(fnamepath))
if fenc != "" if fenc != ""
exe "silent w! ++enc=".fnameescape(fenc)." ".fnameescape(fnamepath) exe "silent w! ++enc=".fnameescape(fenc)." ".fnameescape(fnamepath)
@ -328,17 +329,18 @@ fun! vimball#Vimball(really,...)
endif endif
echo "wrote ".fnameescape(fnamepath) echo "wrote ".fnameescape(fnamepath)
call s:RecordInVar(home,"call delete('".fnamepath."')") call s:RecordInVar(home,"call delete('".fnamepath."')")
endif endif
" return to tab with vimball " return to tab with vimball
" call Decho("exe tabn ".curtabnr) " call Decho("exe tabn ".curtabnr)
exe "tabn ".curtabnr exe "tabn ".curtabnr
" set up help if its a doc/*.txt file " set up help if its a doc/*.txt file
" call Decho("didhelp<".didhelp."> fname<".fname.">") " call Decho("didhelp<".didhelp."> fname<".fname.">")
if a:really && didhelp == "" && fname =~ 'doc/[^/]\+\.\(txt\|..x\)$' if a:really && didhelp == "" && fname =~ 'doc/[^/]\+\.\(txt\|..x\)$'
let didhelp= substitute(fname,'^\(.*\<doc\)[/\\][^.]*\.\(txt\|..x\)$','\1','') let didhelp= substitute(fname,'^\(.*\<doc\)[/\\][^.]*\.\(txt\|..x\)$','\1','')
" call Decho("didhelp<".didhelp.">") " call Decho("didhelp<".didhelp.">")
endif
endif endif
" update for next file " update for next file
@ -400,7 +402,9 @@ fun! vimball#RmVimball(...)
let curfile= a:1 let curfile= a:1
" call Decho("case a:0=".a:0.": curfile<".curfile.">") " call Decho("case a:0=".a:0.": curfile<".curfile.">")
endif endif
if curfile =~ '\.vba$' if curfile =~ '\.vmb$'
let curfile= substitute(curfile,'\.vmb','','')
elseif curfile =~ '\.vba$'
let curfile= substitute(curfile,'\.vba','','') let curfile= substitute(curfile,'\.vba','','')
endif endif
if a:0 >= 2 if a:0 >= 2
@ -418,13 +422,17 @@ fun! vimball#RmVimball(...)
" call Decho(".VimballRecord is readable") " call Decho(".VimballRecord is readable")
" call Decho("curfile<".curfile.">") " call Decho("curfile<".curfile.">")
keepalt keepjumps 1split keepalt keepjumps 1split
silent! keepalt keepjumps e .VimballRecord sil! keepalt keepjumps e .VimballRecord
let keepsrch= @/ let keepsrch= @/
" call Decho('search for ^\M'.curfile.'.\m: ') " call Decho('search for ^\M'.curfile.'.\m: ')
" call Decho('search for ^\M'.curfile.'.\mvba: ') " call Decho('search for ^\M'.curfile.'.\m{vba|vmb}: ')
" call Decho('search for ^\M'.curfile.'\m[-0-9.]*\.vba: ') " call Decho('search for ^\M'.curfile.'\m[-0-9.]*\.{vba|vmb}: ')
if search('^\M'.curfile."\m: ".'cw') if search('^\M'.curfile."\m: ".'cw')
let foundit= 1 let foundit= 1
elseif search('^\M'.curfile.".\mvmb: ",'cw')
let foundit= 2
elseif search('^\M'.curfile.'\m[-0-9.]*\.vmb: ','cw')
let foundit= 2
elseif search('^\M'.curfile.".\mvba: ",'cw') elseif search('^\M'.curfile.".\mvba: ",'cw')
let foundit= 1 let foundit= 1
elseif search('^\M'.curfile.'\m[-0-9.]*\.vba: ','cw') elseif search('^\M'.curfile.'\m[-0-9.]*\.vba: ','cw')
@ -433,25 +441,29 @@ fun! vimball#RmVimball(...)
let foundit = 0 let foundit = 0
endif endif
if foundit if foundit
let exestring = substitute(getline("."),'^\M'.curfile.'\m\S\{-}\.vba: ','','') if foundit == 1
let exestring = substitute(getline("."),'^\M'.curfile.'\m\S\{-}\.vba: ','','')
else
let exestring = substitute(getline("."),'^\M'.curfile.'\m\S\{-}\.vmb: ','','')
endif
let s:VBRstring= substitute(exestring,'call delete(','','g') let s:VBRstring= substitute(exestring,'call delete(','','g')
let s:VBRstring= substitute(s:VBRstring,"[')]",'','g') let s:VBRstring= substitute(s:VBRstring,"[')]",'','g')
" call Decho("exe ".exestring) " call Decho("exe ".exestring)
silent! keepalt keepjumps exe exestring sil! keepalt keepjumps exe exestring
silent! keepalt keepjumps d sil! keepalt keepjumps d
let exestring= strlen(substitute(exestring,'call delete(.\{-})|\=',"D","g")) let exestring= strlen(substitute(exestring,'call delete(.\{-})|\=',"D","g"))
" call Decho("exestring<".exestring.">") " call Decho("exestring<".exestring.">")
echomsg "removed ".exestring." files" echomsg "removed ".exestring." files"
else else
let s:VBRstring= '' let s:VBRstring= ''
let curfile = substitute(curfile,'\.vba','','') let curfile = substitute(curfile,'\.vmb','','')
" call Decho("unable to find <".curfile."> in .VimballRecord") " call Decho("unable to find <".curfile."> in .VimballRecord")
if !exists("s:ok_unablefind") if !exists("s:ok_unablefind")
call vimball#ShowMesg(s:WARNING,"(RmVimball) unable to find <".curfile."> in .VimballRecord") call vimball#ShowMesg(s:WARNING,"(RmVimball) unable to find <".curfile."> in .VimballRecord")
endif endif
endif endif
silent! keepalt keepjumps g/^\s*$/d sil! keepalt keepjumps g/^\s*$/d
silent! keepalt keepjumps wq! sil! keepalt keepjumps wq!
let @/= keepsrch let @/= keepsrch
endif endif
call s:ChgDir(curdir) call s:ChgDir(curdir)
@ -599,7 +611,7 @@ fun! s:RecordInFile(home)
let cmd= expand("%:tr").": " let cmd= expand("%:tr").": "
" call Decho("cmd<".cmd.">") " call Decho("cmd<".cmd.">")
silent! keepalt keepjumps e .VimballRecord sil! keepalt keepjumps e .VimballRecord
setlocal ma setlocal ma
$ $
if exists("s:recordfile") && exists("s:recorddir") if exists("s:recordfile") && exists("s:recorddir")
@ -616,8 +628,8 @@ fun! s:RecordInFile(home)
" put command into buffer, write .VimballRecord `file " put command into buffer, write .VimballRecord `file
keepalt keepjumps put=cmd keepalt keepjumps put=cmd
silent! keepalt keepjumps g/^\s*$/d sil! keepalt keepjumps g/^\s*$/d
silent! keepalt keepjumps wq! sil! keepalt keepjumps wq!
call s:ChgDir(curdir) call s:ChgDir(curdir)
if exists("s:recorddir") if exists("s:recorddir")
@ -693,10 +705,11 @@ fun! vimball#SaveSettings()
let s:repkeep = &report let s:repkeep = &report
let s:vekeep = &ve let s:vekeep = &ve
let s:ffkeep = &l:ff let s:ffkeep = &l:ff
let s:swfkeep = &l:swf
if exists("&acd") if exists("&acd")
setlocal ei=all ve=all noacd nofen noic report=999 nohid bt= ma lz pm= ff=unix setlocal ei=all ve=all noacd nofen noic report=999 nohid bt= ma lz pm= ff=unix noswf
else else
setlocal ei=all ve=all nofen noic report=999 nohid bt= ma lz pm= ff=unix setlocal ei=all ve=all nofen noic report=999 nohid bt= ma lz pm= ff=unix noswf
endif endif
" vimballs should be in unix format " vimballs should be in unix format
setlocal ff=unix setlocal ff=unix

View File

@ -1,10 +1,10 @@
" zip.vim: Handles browsing zipfiles " zip.vim: Handles browsing zipfiles
" AUTOLOAD PORTION " AUTOLOAD PORTION
" Date: Apr 12, 2010 " Date: May 24, 2011
" Version: 23 " Version: 24
" Maintainer: Charles E Campbell, Jr <NdrOchip@ScampbellPfamily.AbizM-NOSPAM> " Maintainer: Charles E Campbell, Jr <NdrOchip@ScampbellPfamily.AbizM-NOSPAM>
" License: Vim License (see vim's :help license) " License: Vim License (see vim's :help license)
" Copyright: Copyright (C) 2005-2008 Charles E. Campbell, Jr. {{{1 " Copyright: Copyright (C) 2005-2011 Charles E. Campbell, Jr. {{{1
" Permission is hereby granted to use and distribute this code, " Permission is hereby granted to use and distribute this code,
" with or without modifications, provided that this copyright " with or without modifications, provided that this copyright
" notice is copied with it. Like anything else that's free, " notice is copied with it. Like anything else that's free,
@ -19,7 +19,7 @@
if &cp || exists("g:loaded_zip") if &cp || exists("g:loaded_zip")
finish finish
endif endif
let g:loaded_zip= "v23" let g:loaded_zip= "v24"
if v:version < 702 if v:version < 702
echohl WarningMsg echohl WarningMsg
echo "***warning*** this version of zip needs vim 7.2" echo "***warning*** this version of zip needs vim 7.2"
@ -103,38 +103,26 @@ fun! zip#Browse(zipfile)
set ft=tar set ft=tar
" give header " give header
let lastline= line("$") call append(0, ['" zip.vim version '.g:loaded_zip,
call setline(lastline+1,'" zip.vim version '.g:loaded_zip) \ '" Browsing zipfile '.a:zipfile,
call setline(lastline+2,'" Browsing zipfile '.a:zipfile) \ '" Select a file with cursor and press ENTER'])
call setline(lastline+3,'" Select a file with cursor and press ENTER') keepj $
$put =''
0d
$
" call Decho("exe silent r! ".g:zip_unzipcmd." -l -- ".s:Escape(a:zipfile,1)) " call Decho("exe silent r! ".g:zip_unzipcmd." -l -- ".s:Escape(a:zipfile,1))
exe "silent r! ".g:zip_unzipcmd." -l -- ".s:Escape(a:zipfile,1) exe "silent r! ".g:zip_unzipcmd." -Z -1 -- ".s:Escape(a:zipfile,1)
if v:shell_error != 0 if v:shell_error != 0
redraw! redraw!
echohl WarningMsg | echo "***warning*** (zip#Browse) ".fnameescape(a:zipfile)." is not a zip file" | echohl None echohl WarningMsg | echo "***warning*** (zip#Browse) ".fnameescape(a:zipfile)." is not a zip file" | echohl None
" call inputsave()|call input("Press <cr> to continue")|call inputrestore() " call inputsave()|call input("Press <cr> to continue")|call inputrestore()
silent %d keepj sil! %d
let eikeep= &ei let eikeep= &ei
set ei=BufReadCmd,FileReadCmd set ei=BufReadCmd,FileReadCmd
exe "r ".fnameescape(a:zipfile) exe "keepj r ".fnameescape(a:zipfile)
let &ei= eikeep let &ei= eikeep
1d keepj 1d
" call Dret("zip#Browse") " call Dret("zip#Browse")
return return
endif endif
" call Decho("line 6: ".getline(6))
let namecol= stridx(getline(6),'Name') + 1
" call Decho("namecol=".namecol)
4,$g/^\s*----/d
4,$g/^\s*\a/d
$d
if namecol > 0
exe 'silent 4,$s/^.*\%'.namecol.'c//'
endif
setlocal noma nomod ro setlocal noma nomod ro
noremap <silent> <buffer> <cr> :call <SID>ZipBrowseSelect()<cr> noremap <silent> <buffer> <cr> :call <SID>ZipBrowseSelect()<cr>
@ -205,11 +193,12 @@ fun! zip#Read(fname,mode)
" call Decho("zipfile<".zipfile.">") " call Decho("zipfile<".zipfile.">")
" call Decho("fname <".fname.">") " call Decho("fname <".fname.">")
" call Decho("exe r! ".g:zip_unzipcmd." -p -- ".s:Escape(zipfile,1)." ".s:Escape(fname,1)) " call Decho("exe r! ".g:zip_unzipcmd." -p -- ".s:Escape(zipfile,1)." ".s:Escape(fnameescape(fname),1))
exe "silent r! ".g:zip_unzipcmd." -p -- ".s:Escape(zipfile,1)." ".s:Escape(fname,1) exe "keepj sil! r! ".g:zip_unzipcmd." -p -- ".s:Escape(zipfile,1)." ".s:Escape(fnameescape(fname),1)
filetype detect
" cleanup " cleanup
0d keepj 0d
set nomod set nomod
let &report= repkeep let &report= repkeep

View File

@ -1,7 +1,8 @@
" Vim compiler file " Vim compiler file
" Compiler: ms C# " Compiler: Microsoft Visual Studio C#
" Maintainer: Joseph H. Yao (hyao@sina.com) " Maintainer: Zhou YiChao (broken.zhou@gmail.com)
" Last Change: 2004 Mar 27 " Previous Maintainer: Joseph H. Yao (hyao@sina.com)
" Last Change: 2011 Apr 21
if exists("current_compiler") if exists("current_compiler")
finish finish
@ -12,8 +13,9 @@ if exists(":CompilerSet") != 2 " older Vim always used :setlocal
command -nargs=* CompilerSet setlocal <args> command -nargs=* CompilerSet setlocal <args>
endif endif
" default errorformat
CompilerSet errorformat& CompilerSet errorformat&
CompilerSet errorformat+=%f(%l\\,%v):\ %t%*[^:]:\ %m,
\%trror%*[^:]:\ %m,
\%tarning%*[^:]:\ %m
" default make
CompilerSet makeprg=csc\ % CompilerSet makeprg=csc\ %

View File

@ -1,4 +1,4 @@
*autocmd.txt* For Vim version 7.3. Last change: 2010 Jul 22 *autocmd.txt* For Vim version 7.3. Last change: 2011 Aug 29
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -299,6 +299,8 @@ Name triggered by ~
|InsertEnter| starting Insert mode |InsertEnter| starting Insert mode
|InsertChange| when typing <Insert> while in Insert or Replace mode |InsertChange| when typing <Insert> while in Insert or Replace mode
|InsertLeave| when leaving Insert mode |InsertLeave| when leaving Insert mode
|InsertCharPre| when a character was typed in Insert mode, before
inserting it
|ColorScheme| after loading a color scheme |ColorScheme| after loading a color scheme
@ -446,6 +448,9 @@ BufWriteCmd Before writing the whole buffer to a file.
'modified' if successful, unless '+' is in 'modified' if successful, unless '+' is in
'cpo' and writing to another file |cpo-+|. 'cpo' and writing to another file |cpo-+|.
The buffer contents should not be changed. The buffer contents should not be changed.
When the command resets 'modified' the undo
information is adjusted to mark older undo
states as 'modified', like |:write| does.
|Cmd-event| |Cmd-event|
*BufWritePost* *BufWritePost*
BufWritePost After writing the whole buffer to a file BufWritePost After writing the whole buffer to a file
@ -506,6 +511,7 @@ CursorMoved After the cursor was moved in Normal mode.
not expect or that is slow. not expect or that is slow.
*CursorMovedI* *CursorMovedI*
CursorMovedI After the cursor was moved in Insert mode. CursorMovedI After the cursor was moved in Insert mode.
Not triggered when the popup menu is visible.
Otherwise the same as CursorMoved. Otherwise the same as CursorMoved.
*EncodingChanged* *EncodingChanged*
EncodingChanged Fires off after the 'encoding' option has been EncodingChanged Fires off after the 'encoding' option has been
@ -657,6 +663,17 @@ InsertChange When typing <Insert> while in Insert or
indicates the new mode. indicates the new mode.
Be careful not to move the cursor or do Be careful not to move the cursor or do
anything else that the user does not expect. anything else that the user does not expect.
*InsertCharPre*
InsertCharPre When a character is typed in Insert mode,
before inserting the char.
The |v:char| variable indicates the char typed
and can be changed during the event to insert
a different character. When |v:char| is set
to more than one character this text is
inserted literally.
It is not allowed to change the text |textlock|.
The event is not triggered when 'paste' is
set.
*InsertEnter* *InsertEnter*
InsertEnter Just before starting Insert mode. Also for InsertEnter Just before starting Insert mode. Also for
Replace mode and Virtual Replace mode. The Replace mode and Virtual Replace mode. The
@ -786,7 +803,10 @@ TermChanged After the value of 'term' has changed. Useful
TermResponse After the response to |t_RV| is received from TermResponse After the response to |t_RV| is received from
the terminal. The value of |v:termresponse| the terminal. The value of |v:termresponse|
can be used to do things depending on the can be used to do things depending on the
terminal version. terminal version. Note that this event may be
triggered halfway executing another event,
especially if file I/O, a shell command or
anything else that takes time is involved.
*User* *User*
User Never executed automatically. To be used for User Never executed automatically. To be used for
autocommands that are only executed with autocommands that are only executed with

View File

@ -1,4 +1,4 @@
*change.txt* For Vim version 7.3. Last change: 2011 Feb 25 *change.txt* For Vim version 7.3. Last change: 2011 Jun 19
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -522,11 +522,11 @@ comment (starting with '"') after the ":!" command.
={motion} Filter {motion} lines through the external program ={motion} Filter {motion} lines through the external program
given with the 'equalprg' option. When the 'equalprg' given with the 'equalprg' option. When the 'equalprg'
option is empty (this is the default), use the option is empty (this is the default), use the
internal formatting function |C-indenting|. But when internal formatting function |C-indenting| and
'indentexpr' is not empty, it will be used instead |'lisp'|. But when 'indentexpr' is not empty, it will
|indent-expression|. When Vim was compiled without be used instead |indent-expression|. When Vim was
internal formatting then the "indent" program is used compiled without internal formatting then the "indent"
as a last resort. program is used as a last resort.
*==* *==*
== Filter [count] lines like with ={motion}. == Filter [count] lines like with ={motion}.
@ -717,11 +717,13 @@ Otherwise it works on whole lines anyway.
*sub-replace-special* *:s\=* *sub-replace-special* *:s\=*
When the {string} starts with "\=" it is evaluated as an expression, see When the {string} starts with "\=" it is evaluated as an expression, see
|sub-replace-expression|. You can use that for any special characters. |sub-replace-expression|. You can use that for complex replacement or special
characters.
Otherwise these characters in {string} have a special meaning: Otherwise these characters in {string} have a special meaning:
*:s%* *:s%*
When {string} is equal to "%" and '/' is included with the 'cpoptions' option, When {string} is equal to "%" and '/' is included with the 'cpoptions' option,
then the {string} of the previous substitute command is used. |cpo-/| then the {string} of the previous substitute command is used, see |cpo-/|
magic nomagic action ~ magic nomagic action ~
& \& replaced with the whole matched pattern *s/\&* & \& replaced with the whole matched pattern *s/\&*
@ -756,6 +758,14 @@ magic nomagic action ~
\x where x is any character not mentioned above: \x where x is any character not mentioned above:
Reserved for future expansion Reserved for future expansion
The special meaning is also used inside the third argument {sub} of
the |substitute()| function with the following exceptions:
- A % inserts a percent literally without regard to 'cpoptions'.
- magic is always set without regard to 'magic'.
- A ~ inserts a tilde literally.
- <CR> and \r inserts a carriage-return (CTRL-M).
- \<CR> does not have a special meaning. it's just one of \x.
Examples: > Examples: >
:s/a\|b/xxx\0xxx/g modifies "a b" to "xxxaxxx xxxbxxx" :s/a\|b/xxx\0xxx/g modifies "a b" to "xxxaxxx xxxbxxx"
:s/\([abc]\)\([efg]\)/\2\1/g modifies "af fa bg" to "fa fa gb" :s/\([abc]\)\([efg]\)/\2\1/g modifies "af fa bg" to "fa fa gb"
@ -787,17 +797,19 @@ either the first or second pattern in parentheses did not match, so either
Substitute with an expression *sub-replace-expression* Substitute with an expression *sub-replace-expression*
*sub-replace-\=* *sub-replace-\=*
When the substitute string starts with "\=" the remainder is interpreted as an When the substitute string starts with "\=" the remainder is interpreted as an
expression. This does not work recursively: a substitute() function inside expression. This does not work recursively: a |substitute()| function inside
the expression cannot use "\=" for the substitute string. the expression cannot use "\=" for the substitute string.
The special meaning for characters as mentioned at |sub-replace-special| does The special meaning for characters as mentioned at |sub-replace-special| does
not apply except for "<CR>", "\<CR>" and "\\". Thus in the result of the not apply except for "<CR>". A <NL> character is used as a line break, you
expression you need to use two backslashes to get one, put a backslash before a can get one with a double-quote string: "\n". Prepend a backslash to get a
<CR> you want to insert, and use a <CR> without a backslash where you want to real <NL> character (which will be a NUL in the file).
break the line.
For convenience a <NL> character is also used as a line break. Prepend a The "\=" notation can also be used inside the third argument {sub} of
backslash to get a real <NL> character (which will be a NUL in the file). |substitute()| function. In this case, the special meaning for characters as
mentioned at |sub-replace-special| does not apply at all. Especially, <CR> and
<NL> are interpreted not as a line break but as a carriage-return and a
new-line respectively.
When the result is a |List| then the items are joined with separating line When the result is a |List| then the items are joined with separating line
breaks. Thus each item becomes a line, except that they can contain line breaks. Thus each item becomes a line, except that they can contain line
@ -917,8 +929,10 @@ inside of strings can change! Also see 'softtabstop' option. >
{Visual}["x]Y Yank the highlighted lines [into register x] (for {Visual}["x]Y Yank the highlighted lines [into register x] (for
{Visual} see |Visual-mode|). {not in Vi} {Visual} see |Visual-mode|). {not in Vi}
*:y* *:yank* *:y* *:yank* *E850*
:[range]y[ank] [x] Yank [range] lines [into register x]. :[range]y[ank] [x] Yank [range] lines [into register x]. Yanking to the
"* or "+ registers is possible only when the
|+clipboard| feature is included.
:[range]y[ank] [x] {count} :[range]y[ank] [x] {count}
Yank {count} lines, starting with last line number Yank {count} lines, starting with last line number
@ -1388,16 +1402,19 @@ before typing anything else on the new line. This will replace the
middle-comment leader with the end-comment leader and apply any specified 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
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 Here is an example of alignment flags at work to make a comment stand out
(kind of looks like a 1 too). Consider comment string > (kind of looks like a 1 too). Consider comment string: >
sr:/***,m:**,ex2:******/ :set comments=sr:/***,m:**,ex-2:******/
<
/*** /*** ~
**<--right aligned from "r" flag **<--right aligned from "r" flag ~
** ** ~
offset 2 spaces from the "2" flag--->** offset 2 spaces for the "-2" flag--->** ~
******/ ******/ ~
In this case, the first comment was typed, then return was pressed 4 times, In this case, the first comment was typed, then return was pressed 4 times,
then "/" was pressed to end the comment. then "/" was pressed to end the comment.
@ -1415,8 +1432,8 @@ Reindenting using a different method like |gq| or |=| will not consult
alignment flags either. The same behaviour can be defined in those other alignment flags either. The same behaviour can be defined in those other
formatting options. One consideration is that 'cindent' has additional options formatting options. One consideration is that 'cindent' has additional options
for context based indenting of comments but cannot replicate many three piece for context based indenting of comments but cannot replicate many three piece
indent alignments. However, 'indentexpr' is has the ability to work better indent alignments. However, 'indentexpr' has the ability to work better with
with three piece comments. three piece comments.
Other examples: > Other examples: >
"b:*" Includes lines starting with "*", but not if the "*" is "b:*" Includes lines starting with "*", but not if the "*" is

View File

@ -1,4 +1,4 @@
*diff.txt* For Vim version 7.3. Last change: 2010 Dec 08 *diff.txt* For Vim version 7.3. Last change: 2011 Apr 14
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -167,8 +167,8 @@ in diff mode in one window and "normal" in another window. It is also
possible to view the changes you have made to a buffer since the file was possible to view the changes you have made to a buffer since the file was
loaded. Since Vim doesn't allow having two buffers for the same file, you loaded. Since Vim doesn't allow having two buffers for the same file, you
need another buffer. This command is useful: > need another buffer. This command is useful: >
command DiffOrig vert new | set bt=nofile | r # | 0d_ | diffthis command DiffOrig vert new | set bt=nofile | r ++edit # | 0d_
\ | wincmd p | diffthis \ | diffthis | wincmd p | diffthis
(this is in |vimrc_example.vim|). Use ":DiffOrig" to see the differences (this is in |vimrc_example.vim|). Use ":DiffOrig" to see the differences
between the current buffer and the file it was loaded from. between the current buffer and the file it was loaded from.

View File

@ -1,4 +1,4 @@
*eval.txt* For Vim version 7.3. Last change: 2011 Mar 18 *eval.txt* For Vim version 7.3. Last change: 2011 Aug 29
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -39,7 +39,7 @@ done, the features in this document are not available. See |+eval| and
*E712* *E712*
There are six types of variables: There are six types of variables:
Number A 32 bit signed number. |expr-number| *Number* Number A 32 or 64 bit signed number. |expr-number| *Number*
Examples: -123 0x10 0177 Examples: -123 0x10 0177
Float A floating point number. |floating-point-format| *Float* Float A floating point number. |floating-point-format| *Float*
@ -721,7 +721,8 @@ if it evaluates to true.
*expr-<#* *expr-<=#* *expr-=~#* *expr-!~#* *expr-<#* *expr-<=#* *expr-=~#* *expr-!~#*
*expr-==?* *expr-!=?* *expr->?* *expr->=?* *expr-==?* *expr-!=?* *expr->?* *expr->=?*
*expr-<?* *expr-<=?* *expr-=~?* *expr-!~?* *expr-<?* *expr-<=?* *expr-=~?* *expr-!~?*
*expr-is* *expr-is* *expr-isnot* *expr-is#* *expr-isnot#*
*expr-is?* *expr-isnot?*
use 'ignorecase' match case ignore case ~ use 'ignorecase' match case ignore case ~
equal == ==# ==? equal == ==# ==?
not equal != !=# !=? not equal != !=# !=?
@ -731,8 +732,8 @@ smaller than < <# <?
smaller than or equal <= <=# <=? smaller than or equal <= <=# <=?
regexp matches =~ =~# =~? regexp matches =~ =~# =~?
regexp doesn't match !~ !~# !~? regexp doesn't match !~ !~# !~?
same instance is same instance is is# is?
different instance isnot different instance isnot isnot# isnot?
Examples: Examples:
"abc" ==# "Abc" evaluates to 0 "abc" ==# "Abc" evaluates to 0
@ -753,12 +754,14 @@ recursively. Ignoring case means case is ignored when comparing item values.
A |Funcref| can only be compared with a |Funcref| and only "equal" and "not A |Funcref| can only be compared with a |Funcref| and only "equal" and "not
equal" can be used. Case is never ignored. equal" can be used. Case is never ignored.
When using "is" or "isnot" with a |List| this checks if the expressions are When using "is" or "isnot" with a |List| or a |Dictionary| this checks if the
referring to the same |List| instance. A copy of a |List| is different from expressions are referring to the same |List| or |Dictionary| instance. A copy
the original |List|. When using "is" without a |List| it is equivalent to of a |List| is different from the original |List|. When using "is" without
using "equal", using "isnot" equivalent to using "not equal". Except that a a |List| or a |Dictionary| it is equivalent to using "equal", using "isnot"
different type means the values are different. "4 == '4'" is true, "4 is '4'" equivalent to using "not equal". Except that a different type means the
is false. values are different: "4 == '4'" is true, "4 is '4'" is false and "0 is []" is
false and not a error. "is#"/"isnot#" and "is?"/"isnot?" can be used to match
and ignore case.
When comparing a String with a Number, the String is converted to a Number, When comparing a String with a Number, the String is converted to a Number,
and the comparison is done on Numbers. This means that "0 == 'x'" is TRUE, and the comparison is done on Numbers. This means that "0 == 'x'" is TRUE,
@ -1293,6 +1296,7 @@ v:beval_winnr The number of the window, over which the mouse pointer is. Only
*v:char* *char-variable* *v:char* *char-variable*
v:char Argument for evaluating 'formatexpr' and used for the typed v:char Argument for evaluating 'formatexpr' and used for the typed
character when using <expr> in an abbreviation |:map-<expr>|. character when using <expr> in an abbreviation |:map-<expr>|.
It is also used by the |InsertCharPre| event.
*v:charconvert_from* *charconvert_from-variable* *v:charconvert_from* *charconvert_from-variable*
v:charconvert_from v:charconvert_from
@ -1545,7 +1549,9 @@ v:progname Contains the name (with path removed) with which Vim was
*v:register* *register-variable* *v:register* *register-variable*
v:register The name of the register in effect for the current normal mode v:register The name of the register in effect for the current normal mode
command. If none is supplied it is the default register. command. If none is supplied it is the default register '"',
unless 'clipboard' contains "unnamed" or "unnamedplus", then
it is '*' or '+'.
Also see |getreg()| and |setreg()| Also see |getreg()| and |setreg()|
*v:scrollstart* *scrollstart-variable* *v:scrollstart* *scrollstart-variable*
@ -1916,7 +1922,8 @@ shellescape( {string} [, {special}])
simplify( {filename}) String simplify filename as much as possible simplify( {filename}) String simplify filename as much as possible
sin( {expr}) Float sine of {expr} sin( {expr}) Float sine of {expr}
sinh( {expr}) Float hyperbolic sine of {expr} sinh( {expr}) Float hyperbolic sine of {expr}
sort( {list} [, {func}]) List sort {list}, using {func} to compare sort( {list} [, {func} [, {dict}]])
List sort {list}, using {func} to compare
soundfold( {word}) String sound-fold {word} soundfold( {word}) String sound-fold {word}
spellbadword() String badly spelled word at cursor spellbadword() String badly spelled word at cursor
spellsuggest( {word} [, {max} [, {capital}]]) spellsuggest( {word} [, {max} [, {capital}]])
@ -1939,7 +1946,7 @@ strridx( {haystack}, {needle} [, {start}])
Number last index of {needle} in {haystack} Number last index of {needle} in {haystack}
strtrans( {expr}) String translate string to make it printable strtrans( {expr}) String translate string to make it printable
strwidth( {expr}) Number display cell length of the String {expr} strwidth( {expr}) Number display cell length of the String {expr}
submatch( {nr}) String specific match in ":substitute" submatch( {nr}) String specific match in ":s" or substitute()
substitute( {expr}, {pat}, {sub}, {flags}) substitute( {expr}, {pat}, {sub}, {flags})
String all {pat} in {expr} replaced with {sub} String all {pat} in {expr} replaced with {sub}
synID( {lnum}, {col}, {trans}) Number syntax ID at {lnum} and {col} synID( {lnum}, {col}, {trans}) Number syntax ID at {lnum} and {col}
@ -2270,7 +2277,8 @@ char2nr({expr}) *char2nr()*
< The current 'encoding' is used. Example for "utf-8": > < The current 'encoding' is used. Example for "utf-8": >
char2nr("<22>") returns 225 char2nr("<22>") returns 225
char2nr("<22>"[0]) returns 195 char2nr("<22>"[0]) returns 195
< |nr2char()| does the opposite. < A combining character is a separate character.
|nr2char()| does the opposite.
cindent({lnum}) *cindent()* cindent({lnum}) *cindent()*
Get the amount of indent for line {lnum} according the C Get the amount of indent for line {lnum} according the C
@ -4074,6 +4082,7 @@ match({expr}, {pat}[, {start}[, {count}]]) *match()*
{pat} matches. {pat} matches.
A match at the first character or |List| item returns zero. A match at the first character or |List| item returns zero.
If there is no match -1 is returned. If there is no match -1 is returned.
For getting submatches see |matchlist()|.
Example: > Example: >
:echo match("testing", "ing") " results in 4 :echo match("testing", "ing") " results in 4
:echo match([1, 'x'], '\a') " results in 1 :echo match([1, 'x'], '\a') " results in 1
@ -5271,7 +5280,7 @@ sinh({expr}) *sinh()*
{only available when compiled with the |+float| feature} {only available when compiled with the |+float| feature}
sort({list} [, {func}]) *sort()* *E702* sort({list} [, {func} [, {dict}]]) *sort()* *E702*
Sort the items in {list} in-place. Returns {list}. If you Sort the items in {list} in-place. Returns {list}. If you
want a list to remain unmodified make a copy first: > want a list to remain unmodified make a copy first: >
:let sortedlist = sort(copy(mylist)) :let sortedlist = sort(copy(mylist))
@ -5279,6 +5288,8 @@ sort({list} [, {func}]) *sort()* *E702*
Numbers sort after Strings, |Lists| after Numbers. Numbers sort after Strings, |Lists| after Numbers.
For sorting text in the current buffer use |:sort|. For sorting text in the current buffer use |:sort|.
When {func} is given and it is one then case is ignored. When {func} is given and it is one then case is ignored.
{dict} is for functions with the "dict" attribute. It will be
used to set the local variable "self". |Dictionary-function|
When {func} is a |Funcref| or a function name, this function When {func} is a |Funcref| or a function name, this function
is called to compare items. The function is invoked with two is called to compare items. The function is invoked with two
items as argument and must return zero if they are equal, 1 or items as argument and must return zero if they are equal, 1 or
@ -5550,9 +5561,11 @@ strwidth({expr}) *strwidth()*
Also see |strlen()|, |strdisplaywidth()| and |strchars()|. Also see |strlen()|, |strdisplaywidth()| and |strchars()|.
submatch({nr}) *submatch()* submatch({nr}) *submatch()*
Only for an expression in a |:substitute| command. Returns Only for an expression in a |:substitute| command or
the {nr}'th submatch of the matched text. When {nr} is 0 substitute() function.
the whole matched text is returned. Returns the {nr}'th submatch of the matched text. When {nr}
is 0 the whole matched text is returned.
Also see |sub-replace-expression|.
Example: > Example: >
:s/\d\+/\=submatch(0) + 1/ :s/\d\+/\=submatch(0) + 1/
< This finds the first number in the line and adds one to it. < This finds the first number in the line and adds one to it.
@ -5560,26 +5573,35 @@ submatch({nr}) *submatch()*
substitute({expr}, {pat}, {sub}, {flags}) *substitute()* substitute({expr}, {pat}, {sub}, {flags}) *substitute()*
The result is a String, which is a copy of {expr}, in which The result is a String, which is a copy of {expr}, in which
the first match of {pat} is replaced with {sub}. This works the first match of {pat} is replaced with {sub}.
like the ":substitute" command (without any flags). But the When {flags} is "g", all matches of {pat} in {expr} are
matching with {pat} is always done like the 'magic' option is replaced. Otherwise {flags} should be "".
set and 'cpoptions' is empty (to make scripts portable).
'ignorecase' is still relevant. 'smartcase' is not used. This works like the ":substitute" command (without any flags).
See |string-match| for how {pat} is used. But the matching with {pat} is always done like the 'magic'
And a "~" in {sub} is not replaced with the previous {sub}. option is set and 'cpoptions' is empty (to make scripts
portable). 'ignorecase' is still relevant. 'smartcase' is
not used. See |string-match| for how {pat} is used.
A "~" in {sub} is not replaced with the previous {sub}.
Note that some codes in {sub} have a special meaning Note that some codes in {sub} have a special meaning
|sub-replace-special|. For example, to replace something with |sub-replace-special|. For example, to replace something with
"\n" (two characters), use "\\\\n" or '\\n'. "\n" (two characters), use "\\\\n" or '\\n'.
When {pat} does not match in {expr}, {expr} is returned When {pat} does not match in {expr}, {expr} is returned
unmodified. unmodified.
When {flags} is "g", all matches of {pat} in {expr} are
replaced. Otherwise {flags} should be "".
Example: > Example: >
:let &path = substitute(&path, ",\\=[^,]*$", "", "") :let &path = substitute(&path, ",\\=[^,]*$", "", "")
< This removes the last component of the 'path' option. > < This removes the last component of the 'path' option. >
:echo substitute("testing", ".*", "\\U\\0", "") :echo substitute("testing", ".*", "\\U\\0", "")
< results in "TESTING". < results in "TESTING".
When {sub} starts with "\=", the remainder is interpreted as
an expression. See |sub-replace-expression|. Example: >
:echo substitute(s, '%\(\x\x\)',
\ '\=nr2char("0x" . submatch(1))', 'g')
synID({lnum}, {col}, {trans}) *synID()* synID({lnum}, {col}, {trans}) *synID()*
The result is a Number, which is the syntax ID at the position The result is a Number, which is the syntax ID at the position
{lnum} and {col} in the current window. {lnum} and {col} in the current window.
@ -5947,7 +5969,7 @@ virtcol({expr}) *virtcol()*
When 'virtualedit' is used {expr} can be [lnum, col, off], where When 'virtualedit' is used {expr} can be [lnum, col, off], where
"off" is the offset in screen columns from the start of the "off" is the offset in screen columns from the start of the
character. E.g., a position within a <Tab> or after the last character. E.g., a position within a <Tab> or after the last
character. character. When "off" is omitted zero is used.
When Virtual editing is active in the current mode, a position When Virtual editing is active in the current mode, a position
beyond the end of the line can be returned. |'virtualedit'| beyond the end of the line can be returned. |'virtualedit'|
The accepted positions are: The accepted positions are:
@ -6215,14 +6237,14 @@ netbeans_enabled Compiled with support for |netbeans| and connected.
netbeans_intg Compiled with support for |netbeans|. netbeans_intg Compiled with support for |netbeans|.
ole Compiled with OLE automation support for Win32. ole Compiled with OLE automation support for Win32.
os2 OS/2 version of Vim. os2 OS/2 version of Vim.
osfiletype Compiled with support for osfiletypes |+osfiletype|
path_extra Compiled with up/downwards search in 'path' and 'tags' path_extra Compiled with up/downwards search in 'path' and 'tags'
perl Compiled with Perl interface. perl Compiled with Perl interface.
persistent_undo Compiled with support for persistent undo history. persistent_undo Compiled with support for persistent undo history.
postscript Compiled with PostScript file printing. postscript Compiled with PostScript file printing.
printer Compiled with |:hardcopy| support. printer Compiled with |:hardcopy| support.
profile Compiled with |:profile| support. profile Compiled with |:profile| support.
python Compiled with Python interface. python Compiled with Python 2.x interface. |has-python|
python3 Compiled with Python 3.x interface. |has-python|
qnx QNX version of Vim. qnx QNX version of Vim.
quickfix Compiled with |quickfix| support. quickfix Compiled with |quickfix| support.
reltime Compiled with |reltime()| support. reltime Compiled with |reltime()| support.

View File

@ -1,4 +1,4 @@
*filetype.txt* For Vim version 7.3. Last change: 2008 Jul 15 *filetype.txt* For Vim version 7.3. Last change: 2011 Jun 19
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -270,6 +270,9 @@ directories!
*autocmd-osfiletypes* *autocmd-osfiletypes*
NOTE: this code is currently disabled, as the RISC OS implementation was
removed. In the future this will use the 'filetype' option.
On operating systems which support storing a file type with the file, you can On operating systems which support storing a file type with the file, you can
specify that an autocommand should only be executed if the file is of a specify that an autocommand should only be executed if the file is of a
certain type. certain type.
@ -296,8 +299,6 @@ must both match): >
This will match files of type "&fff" whose names start with "diff". This will match files of type "&fff" whose names start with "diff".
Note that osfiletype checking is skipped if Vim is compiled without the
|+osfiletype| feature.
*plugin-details* *plugin-details*
The "plugin" directory can be in any of the directories in the 'runtimepath' The "plugin" directory can be in any of the directories in the 'runtimepath'

View File

@ -60,7 +60,7 @@ level form a fold, with the lines with a higher level forming a nested fold.
The nesting of folds is limited with 'foldnestmax'. The nesting of folds is limited with 'foldnestmax'.
Some lines are ignored and get the fold level of the line above or below it, Some lines are ignored and get the fold level of the line above or below it,
whatever is the lowest. These are empty or white lines and lines starting whichever is lower. These are empty or white lines and lines starting
with a character in 'foldignore'. White space is skipped before checking for with a character in 'foldignore'. White space is skipped before checking for
characters in 'foldignore'. For C use "#" to ignore preprocessor lines. characters in 'foldignore'. For C use "#" to ignore preprocessor lines.

View File

@ -1,4 +1,4 @@
*gui.txt* For Vim version 7.3. Last change: 2010 Nov 03 *gui.txt* For Vim version 7.3. Last change: 2011 Jul 22
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -147,6 +147,15 @@ task bar with the 'guiheadroom' option.
If you are running the X Window System, you can get information about the If you are running the X Window System, you can get information about the
window Vim is running in with this command: > window Vim is running in with this command: >
:!xwininfo -id $WINDOWID :!xwininfo -id $WINDOWID
<
*gui-IME* *iBus*
Input methods for international characters in X that rely on the XIM
framework, most notably iBus, have been known to produce undesirable results
in gVim. These may include an inability to enter spaces, or long delays
between typing a character and it being recognized by the application.
One workaround that has been successful, for unknown reasons, is to prevent
gvim from forking into the background by starting it with the |-f| argument.
============================================================================== ==============================================================================
2. Scrollbars *gui-scrollbars* 2. Scrollbars *gui-scrollbars*

View File

@ -1,4 +1,4 @@
*gui_w32.txt* For Vim version 7.3. Last change: 2010 Dec 19 *gui_w32.txt* For Vim version 7.3. Last change: 2011 Jul 23
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -137,6 +137,9 @@ options:
And if there already is a gvim running: And if there already is a gvim running:
"Edit with existing gvim" -- edit the file with the running gvim "Edit with existing gvim" -- edit the file with the running gvim
The "edit with existing Vim" entries can be disabled by adding an entry in the
registry under HKLM\Software\Vim\Gvim, named DisableEditWithExisting, and with
any value.
*install-registry* *install-registry*
You can add the "Edit with Vim" menu entry in an easy way by using the You can add the "Edit with Vim" menu entry in an easy way by using the
"install.exe" program. It will add several registry entries for you. "install.exe" program. It will add several registry entries for you.

View File

@ -1,4 +1,4 @@
*gui_x11.txt* For Vim version 7.3. Last change: 2010 Jul 20 *gui_x11.txt* For Vim version 7.3. Last change: 2011 Sep 14
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -53,6 +53,8 @@ When using "gvim -f" and then ":gui", Vim will run in the foreground. The
":gui -b". ":gui -b".
"gvim --nofork" does the same as "gvim -f". "gvim --nofork" does the same as "gvim -f".
*E851* *E852*
When starting the GUI fails Vim will try to continue running in the terminal.
If you want the GUI to run in the foreground always, include the 'f' If you want the GUI to run in the foreground always, include the 'f'
flag in 'guioptions'. |-f|. flag in 'guioptions'. |-f|.

View File

@ -1,4 +1,4 @@
*if_cscop.txt* For Vim version 7.3. Last change: 2010 Sep 29 *if_cscop.txt* For Vim version 7.3. Last change: 2011 Jun 12
VIM REFERENCE MANUAL by Andy Kahn VIM REFERENCE MANUAL by Andy Kahn
@ -264,12 +264,22 @@ seems to be useful: >
:set cscopequickfix=s-,c-,d-,i-,t-,e- :set cscopequickfix=s-,c-,d-,i-,t-,e-
< <
*cscopetag* *cst* *cscopetag* *cst*
If 'cscopetag' set, the commands ":tag" and CTRL-] as well as "vim -t" will If 'cscopetag' is set, the commands ":tag" and CTRL-] as well as "vim -t"
always use |:cstag| instead of the default :tag behavior. Effectively, by will always use |:cstag| instead of the default :tag behavior. Effectively,
setting 'cst', you will always search your cscope databases as well as your by setting 'cst', you will always search your cscope databases as well as
tag files. The default is off. Examples: > your tag files. The default is off. Examples: >
:set cst :set cst
:set nocst :set nocst
<
*cscoperelative* *csre*
If 'cscoperelative' is set, then in absence of a prefix given to cscope
(prefix is the argument of -P option of cscope), basename of cscope.out
location (usually the project root directory) will be used as the prefix
to construct an absolute path. The default is off. Note: This option is
only effective when cscope (cscopeprg) is initialized without a prefix
path (-P). Examples: >
:set csre
:set nocsre
< <
*cscopetagorder* *csto* *cscopetagorder* *csto*
The value of 'csto' determines the order in which |:cstag| performs a search. The value of 'csto' determines the order in which |:cstag| performs a search.

View File

@ -1,4 +1,4 @@
*if_pyth.txt* For Vim version 7.3. Last change: 2010 Oct 20 *if_pyth.txt* For Vim version 7.3. Last change: 2011 Aug 19
VIM REFERENCE MANUAL by Paul Moore VIM REFERENCE MANUAL by Paul Moore
@ -377,6 +377,18 @@ To work around such problems there are these options:
3. You undefine PY_NO_RTLD_GLOBAL in auto/config.h after configuration. This 3. You undefine PY_NO_RTLD_GLOBAL in auto/config.h after configuration. This
may crash Vim though. may crash Vim though.
*has-python*
You can test what Python version is available with: >
if has('python')
echo 'there is Python 2.x'
elseif has('python3')
echo 'there is Python 3.x'
endif
Note however, that when Python 2 and 3 are both available and loaded
dynamically, these has() calls will try to load them. If only one can be
loaded at a time, just checking if Python 2 or 3 are available will prevent
the other one from being available.
============================================================================== ==============================================================================
vim:tw=78:ts=8:ft=help:norl: vim:tw=78:ts=8:ft=help:norl:

View File

@ -1,4 +1,4 @@
*indent.txt* For Vim version 7.3. Last change: 2011 Mar 18 *indent.txt* For Vim version 7.3. Last change: 2011 Sep 02
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -128,13 +128,20 @@ have changed the indent by typing <BS>, <Tab>, or <Space> in the indent or
used CTRL-T or CTRL-D. used CTRL-T or CTRL-D.
*cinoptions-values* *cinoptions-values*
The 'cinoptions' option sets how Vim performs indentation. In the list below, The 'cinoptions' option sets how Vim performs indentation. The value after
the option character can be one of these (N is any number):
N indent N spaces
-N indent N spaces to the left
Ns N times 'shiftwidth' spaces
-Ns N times 'shiftwidth' spaces to the left
In the list below,
"N" represents a number of your choice (the number can be negative). When "N" represents a number of your choice (the number can be negative). When
there is an 's' after the number, Vim multiplies the number by 'shiftwidth': there is an 's' after the number, Vim multiplies the number by 'shiftwidth':
"1s" is 'shiftwidth', "2s" is two times 'shiftwidth', etc. You can use a "1s" is 'shiftwidth', "2s" is two times 'shiftwidth', etc. You can use a
decimal point, too: "-0.5s" is minus half a 'shiftwidth'. The examples below decimal point, too: "-0.5s" is minus half a 'shiftwidth'.
assume a 'shiftwidth' of 4. The examples below assume a 'shiftwidth' of 4.
*cino->*
>N Amount added for "normal" indent. Used after a line that should >N Amount added for "normal" indent. Used after a line that should
increase the indent (lines starting with "if", an opening brace, increase the indent (lines starting with "if", an opening brace,
etc.). (default 'shiftwidth'). etc.). (default 'shiftwidth').
@ -145,6 +152,7 @@ assume a 'shiftwidth' of 4.
foo; foo; foo; foo; foo; foo;
} } } } } }
< <
*cino-e*
eN Add N to the prevailing indent inside a set of braces if the eN Add N to the prevailing indent inside a set of braces if the
opening brace at the End of the line (more precise: is not the opening brace at the End of the line (more precise: is not the
first character in a line). This is useful if you want a first character in a line). This is useful if you want a
@ -160,6 +168,7 @@ assume a 'shiftwidth' of 4.
bar; bar; bar; bar; bar; bar;
} } } } } }
< <
*cino-n*
nN Add N to the prevailing indent for a statement after an "if", nN Add N to the prevailing indent for a statement after an "if",
"while", etc., if it is NOT inside a set of braces. This is "while", etc., if it is NOT inside a set of braces. This is
useful if you want a different indent when there is no '{' useful if you want a different indent when there is no '{'
@ -174,6 +183,7 @@ assume a 'shiftwidth' of 4.
bar; bar; bar; bar; bar; bar;
} } } } } }
< <
*cino-f*
fN Place the first opening brace of a function or other block in fN Place the first opening brace of a function or other block in
column N. This applies only for an opening brace that is not column N. This applies only for an opening brace that is not
inside other braces and is at the start of the line. What comes inside other braces and is at the start of the line. What comes
@ -184,6 +194,7 @@ assume a 'shiftwidth' of 4.
{ { { { { {
int foo; int foo; int foo; int foo; int foo; int foo;
< <
*cino-{*
{N Place opening braces N characters from the prevailing indent. {N Place opening braces N characters from the prevailing indent.
This applies only for opening braces that are inside other This applies only for opening braces that are inside other
braces. (default 0). braces. (default 0).
@ -193,6 +204,7 @@ assume a 'shiftwidth' of 4.
{ { { { { {
foo; foo; foo; foo; foo; foo;
< <
*cino-}*
}N Place closing braces N characters from the matching opening }N Place closing braces N characters from the matching opening
brace. (default 0). brace. (default 0).
@ -202,6 +214,7 @@ assume a 'shiftwidth' of 4.
foo; foo; foo; foo; foo; foo;
} } } } } }
< <
*cino-^*
^N Add N to the prevailing indent inside a set of braces if the ^N Add N to the prevailing indent inside a set of braces if the
opening brace is in column 0. This can specify a different opening brace is in column 0. This can specify a different
indent for whole of a function (some may like to set it to a indent for whole of a function (some may like to set it to a
@ -216,6 +229,7 @@ assume a 'shiftwidth' of 4.
} } } } } }
} } } } } }
< <
*cino-L*
LN Controls placement of jump labels. If N is negative, the label LN Controls placement of jump labels. If N is negative, the label
will be placed at column 1. If N is non-negative, the indent of will be placed at column 1. If N is non-negative, the indent of
the label will be the prevailing indent minus N. (default -1). the label will be the prevailing indent minus N. (default -1).
@ -229,6 +243,7 @@ assume a 'shiftwidth' of 4.
} } } } } }
} } } } } }
< <
*cino-:*
:N Place case labels N characters from the indent of the switch(). :N Place case labels N characters from the indent of the switch().
(default 'shiftwidth'). (default 'shiftwidth').
@ -240,6 +255,7 @@ assume a 'shiftwidth' of 4.
default: default: default: default:
} } } }
< <
*cino-=*
=N Place statements occurring after a case label N characters from =N Place statements occurring after a case label N characters from
the indent of the label. (default 'shiftwidth'). the indent of the label. (default 'shiftwidth').
@ -247,6 +263,7 @@ assume a 'shiftwidth' of 4.
case 11: case 11: a = a + 1; case 11: case 11: a = a + 1;
a = a + 1; b = b + 1; a = a + 1; b = b + 1;
< <
*cino-l*
lN If N != 0 Vim will align with a case label instead of the lN If N != 0 Vim will align with a case label instead of the
statement after it in the same line. statement after it in the same line.
@ -256,6 +273,7 @@ assume a 'shiftwidth' of 4.
break; break; break; break;
} } } }
< <
*cino-b*
bN If N != 0 Vim will align a final "break" with the case label, bN If N != 0 Vim will align a final "break" with the case label,
so that case..break looks like a sort of block. (default: 0). so that case..break looks like a sort of block. (default: 0).
When using 1, consider adding "0=break" to 'cinkeys'. When using 1, consider adding "0=break" to 'cinkeys'.
@ -272,6 +290,7 @@ assume a 'shiftwidth' of 4.
break; break; break; break;
} } } }
< <
*cino-g*
gN Place C++ scope declarations N characters from the indent of the gN Place C++ scope declarations N characters from the indent of the
block they are in. (default 'shiftwidth'). A scope declaration block they are in. (default 'shiftwidth'). A scope declaration
can be "public:", "protected:" or "private:". can be "public:", "protected:" or "private:".
@ -283,6 +302,7 @@ assume a 'shiftwidth' of 4.
private: private: private: private:
} } } }
< <
*cino-h*
hN Place statements occurring after a C++ scope declaration N hN Place statements occurring after a C++ scope declaration N
characters from the indent of the label. (default characters from the indent of the label. (default
'shiftwidth'). 'shiftwidth').
@ -291,6 +311,21 @@ assume a 'shiftwidth' of 4.
public: public: a = a + 1; public: public: a = a + 1;
a = a + 1; b = b + 1; a = a + 1; b = b + 1;
< <
*cino-N*
NN Indent inside C++ namespace N characters extra compared to a
normal block. (default 0).
cino= cino=N-s >
namespace { namespace {
void function(); void function();
} }
namespace my namespace my
{ {
void function(); void function();
} }
<
*cino-p*
pN Parameter declarations for K&R-style function declarations will pN Parameter declarations for K&R-style function declarations will
be indented N characters from the margin. (default be indented N characters from the margin. (default
'shiftwidth'). 'shiftwidth').
@ -300,6 +335,7 @@ assume a 'shiftwidth' of 4.
int a; int a; int a; int a; int a; int a;
char b; char b; char b; char b; char b; char b;
< <
*cino-t*
tN Indent a function return type declaration N characters from the tN Indent a function return type declaration N characters from the
margin. (default 'shiftwidth'). margin. (default 'shiftwidth').
@ -307,6 +343,7 @@ assume a 'shiftwidth' of 4.
int int int int int int
func() func() func() func() func() func()
< <
*cino-i*
iN Indent C++ base class declarations and constructor iN Indent C++ base class declarations and constructor
initializations, if they start in a new line (otherwise they initializations, if they start in a new line (otherwise they
are aligned at the right side of the ':'). are aligned at the right side of the ':').
@ -320,6 +357,7 @@ assume a 'shiftwidth' of 4.
BaseClass(3) BaseClass(3) BaseClass(3) BaseClass(3)
{} {} {} {}
< <
*cino-+*
+N Indent a continuation line (a line that spills onto the next) +N Indent a continuation line (a line that spills onto the next)
inside a function N additional characters. (default inside a function N additional characters. (default
'shiftwidth'). 'shiftwidth').
@ -330,6 +368,7 @@ assume a 'shiftwidth' of 4.
a = b + 9 * a = b + 9 * a = b + 9 * a = b + 9 *
c; c; c; c;
< <
*cino-c*
cN Indent comment lines after the comment opener, when there is no cN Indent comment lines after the comment opener, when there is no
other text with which to align, N characters from the comment other text with which to align, N characters from the comment
opener. (default 3). See also |format-comments|. opener. (default 3). See also |format-comments|.
@ -339,6 +378,7 @@ assume a 'shiftwidth' of 4.
text. text. text. text.
*/ */ */ */
< <
*cino-C*
CN When N is non-zero, indent comment lines by the amount specified CN When N is non-zero, indent comment lines by the amount specified
with the c flag above even if there is other text behind the with the c flag above even if there is other text behind the
comment opener. (default 0). comment opener. (default 0).
@ -349,12 +389,14 @@ assume a 'shiftwidth' of 4.
********/ ********/ ********/ ********/
< (Example uses ":set comments& comments-=s1:/* comments^=s0:/*") < (Example uses ":set comments& comments-=s1:/* comments^=s0:/*")
*cino-/*
/N Indent comment lines N characters extra. (default 0). /N Indent comment lines N characters extra. (default 0).
cino= cino=/4 > cino= cino=/4 >
a = b; a = b; a = b; a = b;
/* comment */ /* comment */ /* comment */ /* comment */
c = d; c = d; c = d; c = d;
< <
*cino-(*
(N When in unclosed parentheses, indent N characters from the line (N When in unclosed parentheses, indent N characters from the line
with the unclosed parentheses. Add a 'shiftwidth' for every with the unclosed parentheses. Add a 'shiftwidth' for every
unclosed parentheses. When N is 0 or the unclosed parentheses unclosed parentheses. When N is 0 or the unclosed parentheses
@ -370,6 +412,7 @@ assume a 'shiftwidth' of 4.
(c2 || c3)) (c2 || c3)) (c2 || c3)) (c2 || c3))
{ { { {
< <
*cino-u*
uN Same as (N, but for one level deeper. (default 'shiftwidth'). uN Same as (N, but for one level deeper. (default 'shiftwidth').
cino= cino=u2 > cino= cino=u2 >
@ -377,6 +420,7 @@ assume a 'shiftwidth' of 4.
&& (c22345 && (c22345 && (c22345 && (c22345
|| c3)) || c3)) || c3)) || c3))
< <
*cino-U*
UN When N is non-zero, do not ignore the indenting specified by UN When N is non-zero, do not ignore the indenting specified by
( or u in case that the unclosed parentheses is the first ( or u in case that the unclosed parentheses is the first
non-white character in its line. (default 0). non-white character in its line. (default 0).
@ -388,6 +432,7 @@ assume a 'shiftwidth' of 4.
c3 c3 c3 c3
) && c4; ) && c4; ) && c4; ) && c4;
< <
*cino-w*
wN When in unclosed parentheses and N is non-zero and either wN When in unclosed parentheses and N is non-zero and either
using "(0" or "u0", respectively, or using "U0" and the unclosed using "(0" or "u0", respectively, or using "U0" and the unclosed
parentheses is the first non-white character in its line, line parentheses is the first non-white character in its line, line
@ -400,6 +445,7 @@ assume a 'shiftwidth' of 4.
|| c3)) || c3)) || c3)) || c3))
foo; foo; foo; foo;
< <
*cino-W*
WN When in unclosed parentheses and N is non-zero and either WN When in unclosed parentheses and N is non-zero and either
using "(0" or "u0", respectively and the unclosed parentheses is using "(0" or "u0", respectively and the unclosed parentheses is
the last non-white character in its line and it is not the the last non-white character in its line and it is not the
@ -414,6 +460,7 @@ assume a 'shiftwidth' of 4.
a_short_line(argument, a_short_line(argument, a_short_line(argument, a_short_line(argument,
argument); argument); argument); argument);
< <
*cino-m*
mN When N is non-zero, line up a line starting with a closing mN When N is non-zero, line up a line starting with a closing
parentheses with the first character of the line with the parentheses with the first character of the line with the
matching opening parentheses. (default 0). matching opening parentheses. (default 0).
@ -428,6 +475,7 @@ assume a 'shiftwidth' of 4.
) ) ) )
foo; foo; foo; foo;
< <
*cino-M*
MN When N is non-zero, line up a line starting with a closing MN When N is non-zero, line up a line starting with a closing
parentheses with the first character of the previous line. parentheses with the first character of the previous line.
(default 0). (default 0).
@ -437,10 +485,11 @@ assume a 'shiftwidth' of 4.
cond2 cond2 cond2 cond2
) ) ) )
< <
*java-cinoptions* *java-indenting* *java-cinoptions* *java-indenting* *cino-j*
jN Indent java anonymous classes correctly. The value 'N' is jN Indent Java anonymous classes correctly. Also works well for
currently unused but must be non-zero (e.g. 'j1'). 'j1' will Javascript. The value 'N' is currently unused but must be
indent for example the following code snippet correctly: > non-zero (e.g. 'j1'). 'j1' will indent for example the
following code snippet correctly: >
object.add(new ChangeListener() { object.add(new ChangeListener() {
public void stateChanged(ChangeEvent e) { public void stateChanged(ChangeEvent e) {
@ -448,10 +497,11 @@ assume a 'shiftwidth' of 4.
} }
}); });
< <
*javascript-cinoptions* *javascript-indenting* *javascript-cinoptions* *javascript-indenting* *cino-J*
JN Indent JavaScript object declarations correctly by not confusing JN Indent JavaScript object declarations correctly by not confusing
them with labels. The value 'N' is currently unused but must be them with labels. The value 'N' is currently unused but must be
non-zero (e.g. 'J1'). > non-zero (e.g. 'J1'). If you enable this you probably also want
to set |cino-j|. >
var bar = { var bar = {
foo: { foo: {
@ -466,14 +516,19 @@ assume a 'shiftwidth' of 4.
} }
} }
< <
*cino-)*
)N Vim searches for unclosed parentheses at most N lines away. )N Vim searches for unclosed parentheses at most N lines away.
This limits the time needed to search for parentheses. (default This limits the time needed to search for parentheses. (default
20 lines). 20 lines).
*cino-star*
*N Vim searches for unclosed comments at most N lines away. This *N Vim searches for unclosed comments at most N lines away. This
limits the time needed to search for the start of a comment. limits the time needed to search for the start of a comment.
If your /* */ comments stop indenting afer N lines this is the
value you will want to change.
(default 70 lines). (default 70 lines).
*cino-#*
#N When N is non-zero recognize shell/Perl comments, starting with #N When N is non-zero recognize shell/Perl comments, starting with
'#'. Default N is zero: don't recognizes '#' comments. Note '#'. Default N is zero: don't recognizes '#' comments. Note
that lines starting with # will still be seen as preprocessor that lines starting with # will still be seen as preprocessor
@ -481,7 +536,7 @@ assume a 'shiftwidth' of 4.
The defaults, spelled out in full, are: The defaults, spelled out in full, are:
cinoptions=>s,e0,n0,f0,{0,}0,^0,L-1,:s,=s,l0,b0,gs,hs,ps,ts,is,+s, cinoptions=>s,e0,n0,f0,{0,}0,^0,L-1,:s,=s,l0,b0,gs,hs,N0,ps,ts,is,+s,
c3,C0,/0,(2s,us,U0,w0,W0,m0,j0,J0,)20,*70,#0 c3,C0,/0,(2s,us,U0,w0,W0,m0,j0,J0,)20,*70,#0
Vim puts a line in column 1 if: Vim puts a line in column 1 if:
@ -508,13 +563,15 @@ REMARKS ABOUT SPECIFIC INDENT FILES ~
FORTRAN *ft-fortran-indent* FORTRAN *ft-fortran-indent*
Block if, select case, and where constructs are indented. Comments, labelled Block if, select case, where, and forall constructs are indented. So are
statements and continuation lines are indented if the Fortran is in free type, interface, associate, block, and enum constructs. The indenting of
source form, whereas they are not indented if the Fortran is in fixed source subroutines, functions, modules, and program blocks is optional. Comments,
form because of the left margin requirements. Hence manual indent corrections labelled statements and continuation lines are indented if the Fortran is in
will be necessary for labelled statements and continuation lines when fixed free source form, whereas they are not indented if the Fortran is in fixed
source form is being used. For further discussion of the method used for the source form because of the left margin requirements. Hence manual indent
detection of source format see |ft-fortran-syntax|. corrections will be necessary for labelled statements and continuation lines
when fixed source form is being used. For further discussion of the method
used for the detection of source format see |ft-fortran-syntax|.
Do loops ~ Do loops ~
All do loops are left unindented by default. Do loops can be unstructured in All do loops are left unindented by default. Do loops can be unstructured in
@ -541,6 +598,20 @@ autocommand such as >
to get do loops indented in .f90 files and left alone in Fortran files with to get do loops indented in .f90 files and left alone in Fortran files with
other extensions such as .for. other extensions such as .for.
Program units ~
The indenting of program units (subroutines, functions, modules, and program
blocks) is enabled by default but can be suppressed if a lighter, screen-width
preserving indent style is desired. To suppress the indenting of program
units for all fortran files set the global fortran_indent_less variable in
your .vimrc as follows >
let fortran_indent_less=1
A finer level of suppression can be achieved by setting the corresponding
buffer-local variable as follows >
let b:fortran_indent_less=1
PHP *ft-php-indent* *php-indent* *php-indenting* PHP *ft-php-indent* *php-indent* *php-indenting*
@ -635,6 +706,43 @@ Indent for a continuation line: >
let g:pyindent_continue = '&sw * 2' let g:pyindent_continue = '&sw * 2'
R *ft-r-indent*
Function arguments are aligned if they span for multiple lines. If you prefer
do not have the arguments of functions aligned, put in your |vimrc|:
>
let r_indent_align_args = 0
<
All lines beginning with a comment character, #, get the same indentation
level of the normal R code. Users of Emacs/ESS may be used to have lines
beginning with a single # indented in the 40th column, ## indented as R code,
and ### not indented. If you prefer that lines beginning with comment
characters are aligned as they are by Emacs/ESS, put in your |vimrc|:
>
let r_indent_ess_comments = 1
<
If you prefer that lines beginning with a single # are aligned at a column
different from the 40th one, you should set a new value to the variable
r_indent_comment_column, as in the example below:
>
let r_indent_comment_column = 30
<
Any code after a line that ends with "<-" is indented. Emacs/ESS does not
indent the code if it is a top level function. If you prefer that the
Vim-R-plugin behaves like Emacs/ESS in this regard, put in your |vimrc|:
>
let r_indent_ess_compatible = 1
<
Below is an example of indentation with and without this option enabled:
>
### r_indent_ess_compatible = 1 ### r_indent_ess_compatible = 0
foo <- foo <-
function(x) function(x)
{ {
paste(x) paste(x)
} }
<
SHELL *ft-sh-indent* SHELL *ft-sh-indent*
The amount of indent applied under various circumstances in a shell file can The amount of indent applied under various circumstances in a shell file can

View File

@ -1,4 +1,4 @@
*index.txt* For Vim version 7.3. Last change: 2011 Jan 04 *index.txt* For Vim version 7.3. Last change: 2011 Aug 06
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -1261,7 +1261,7 @@ tag command action ~
|:k| :k set a mark |:k| :k set a mark
|:keepalt| :keepa[lt] following command keeps the alternate file |:keepalt| :keepa[lt] following command keeps the alternate file
|:keepmarks| :kee[pmarks] following command keeps marks where they are |:keepmarks| :kee[pmarks] following command keeps marks where they are
|:keepjumps| :keepj[jumps] following command keeps jumplist and marks |:keepjumps| :keepj[umps] following command keeps jumplist and marks
|:lNext| :lN[ext] go to previous entry in location list |:lNext| :lN[ext] go to previous entry in location list
|:lNfile| :lNf[ile] go to last entry in previous file |:lNfile| :lNf[ile] go to last entry in previous file
|:list| :l[ist] print lines |:list| :l[ist] print lines

View File

@ -1,4 +1,4 @@
*insert.txt* For Vim version 7.3. Last change: 2010 Nov 10 *insert.txt* For Vim version 7.3. Last change: 2011 Sep 14
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -1020,6 +1020,21 @@ On the second invocation the arguments are:
The function must return a List with the matching words. These matches The function must return a List with the matching words. These matches
usually include the "a:base" text. When there are no matches return an empty usually include the "a:base" text. When there are no matches return an empty
List. List.
In order to return more information than the matching words, return a Dict
that contains the List. The Dict can have these items:
words The List of matching words (mandatory).
refresh A string to control re-invocation of the function
(optional).
The only value currently recognized is "always", the
effect is that the function is called whenever the
leading text is changed.
Other items are ignored.
For example, the function can contain this: >
let matches = ... list of words ...
return {'words': matches, 'refresh': 'always'}
<
*complete-items* *complete-items*
Each list item can either be a string or a Dictionary. When it is a string it Each list item can either be a string or a Dictionary. When it is a string it
is used as the completion. When it is a Dictionary it can contain these is used as the completion. When it is a Dictionary it can contain these
@ -1040,9 +1055,10 @@ items:
empty when non-zero this match will be added even when it is empty when non-zero this match will be added even when it is
an empty string an empty string
All of these except 'icase' must be a string. If an item does not meet these All of these except 'icase', 'dup' and 'empty' must be a string. If an item
requirements then an error message is given and further items in the list are does not meet these requirements then an error message is given and further
not used. You can mix string and Dictionary items in the returned list. items in the list are not used. You can mix string and Dictionary items in
the returned list.
The "menu" item is used in the popup menu and may be truncated, thus it should The "menu" item is used in the popup menu and may be truncated, thus it should
be relatively short. The "info" item can be longer, it will be displayed in be relatively short. The "info" item can be longer, it will be displayed in

View File

@ -1,4 +1,4 @@
*intro.txt* For Vim version 7.3. Last change: 2010 Dec 08 *intro.txt* For Vim version 7.3. Last change: 2011 May 15
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -135,8 +135,10 @@ http://www.vim.org/maillist.php
Bug reports: *bugs* *bug-reports* *bugreport.vim* Bug reports: *bugs* *bug-reports* *bugreport.vim*
Send bug reports to: Vim bugs <bugs@vim.org> Send bug reports to: Vim Developers <vim_dev@vim.org>
This is not a maillist but the message is redirected to the Vim maintainer. This is a maillist, 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).
Please be brief; all the time that is spent on answering mail is subtracted Please be brief; all the time that is spent on answering mail is subtracted
from the time that is spent on improving Vim! Always give a reproducible from the time that is spent on improving Vim! Always give a reproducible
example and try to find out which settings or other things influence the example and try to find out which settings or other things influence the

View File

@ -1,4 +1,4 @@
*map.txt* For Vim version 7.3. Last change: 2010 Nov 10 *map.txt* For Vim version 7.3. Last change: 2011 Aug 19
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -107,6 +107,8 @@ modes.
:cmapc[lear] |mapmode-c| *:cmapc* *:cmapclear* :cmapc[lear] |mapmode-c| *:cmapc* *:cmapclear*
Remove ALL mappings for the modes where the map Remove ALL mappings for the modes where the map
command applies. {not in Vi} command applies. {not in Vi}
Use the <buffer> argument to remove buffer-local
mappings |:map-<buffer>|
Warning: This also removes the default mappings. Warning: This also removes the default mappings.
:map |mapmode-nvo| :map |mapmode-nvo|
@ -226,7 +228,7 @@ text before the cursor and start omni completion when some condition is met.
For abbreviations |v:char| is set to the character that was typed to trigger For abbreviations |v:char| is set to the character that was typed to trigger
the abbreviation. You can use this to decide how to expand the {lhs}. You the abbreviation. You can use this to decide how to expand the {lhs}. You
can't change v:char and you should not insert it. should not either insert or change the v:char.
Be very careful about side effects! The expression is evaluated while Be very careful about side effects! The expression is evaluated while
obtaining characters, you may very well make the command dysfunctional. obtaining characters, you may very well make the command dysfunctional.
@ -480,9 +482,9 @@ You can create an empty {rhs} by typing nothing after a single CTRL-V (you
have to type CTRL-V two times). Unfortunately, you cannot do this in a vimrc have to type CTRL-V two times). Unfortunately, you cannot do this in a vimrc
file. file.
*<Nop>* *<Nop>*
A easier way to get a mapping that doesn't produce anything, is to use "<Nop>" An easier way to get a mapping that doesn't produce anything, is to use
for the {rhs}. This only works when the |<>| notation is enabled. For "<Nop>" for the {rhs}. This only works when the |<>| notation is enabled.
example, to make sure that function key 8 does nothing at all: > For example, to make sure that function key 8 does nothing at all: >
:map <F8> <Nop> :map <F8> <Nop>
:map! <F8> <Nop> :map! <F8> <Nop>
< <
@ -495,7 +497,7 @@ scenario: >
:set encoding=utf-8 :set encoding=utf-8
The mapping for <M-C> is defined with the latin1 encoding, resulting in a 0xc3 The mapping for <M-C> is defined with the latin1 encoding, resulting in a 0xc3
byte. If you type the character <20> (0xe1 <M-a>) in UTF-8 encoding this is the byte. If you type the character <20> (0xe1 <M-a>) in UTF-8 encoding this is the
two bytes 0xc3 0xa1. You don't want the 0xc3 byte to be mapped then, two bytes 0xc3 0xa1. You don't want the 0xc3 byte to be mapped then or
otherwise it would be impossible to type the <20> character. otherwise it would be impossible to type the <20> character.
*<Leader>* *mapleader* *<Leader>* *mapleader*
@ -542,6 +544,7 @@ construct can be used:
<Char-123> character 123 <Char-123> character 123
<Char-033> character 27 <Char-033> character 27
<Char-0x7f> character 127 <Char-0x7f> character 127
<S-Char-114> character 114 ('r') shifted ('R')
This is useful to specify a (multi-byte) character in a 'keymap' file. This is useful to specify a (multi-byte) character in a 'keymap' file.
Upper and lowercase differences are ignored. Upper and lowercase differences are ignored.
@ -934,11 +937,12 @@ See |:verbose-cmd| for more information.
avoid that a typed {lhs} is expanded, since avoid that a typed {lhs} is expanded, since
command-line abbreviations apply here. command-line abbreviations apply here.
:ab[breviate] [<expr>] {lhs} {rhs} :ab[breviate] [<expr>] [<buffer>] {lhs} {rhs}
add abbreviation for {lhs} to {rhs}. If {lhs} already add abbreviation for {lhs} to {rhs}. If {lhs} already
existed it is replaced with the new {rhs}. {rhs} may existed it is replaced with the new {rhs}. {rhs} may
contain spaces. contain spaces.
See |:map-<expr>| for the optional <expr> argument. See |:map-<expr>| for the optional <expr> argument.
See |:map-<buffer>| for the optional <buffer> argument.
*:una* *:unabbreviate* *:una* *:unabbreviate*
:una[bbreviate] {lhs} Remove abbreviation for {lhs} from the list. If none :una[bbreviate] {lhs} Remove abbreviation for {lhs} from the list. If none
@ -948,12 +952,12 @@ See |:verbose-cmd| for more information.
expansion insert a CTRL-V (type it twice). expansion insert a CTRL-V (type it twice).
*:norea* *:noreabbrev* *:norea* *:noreabbrev*
:norea[bbrev] [<expr>] [lhs] [rhs] :norea[bbrev] [<expr>] [<buffer>] [lhs] [rhs]
same as ":ab", but no remapping for this {rhs} {not same as ":ab", but no remapping for this {rhs} {not
in Vi} in Vi}
*:ca* *:cabbrev* *:ca* *:cabbrev*
:ca[bbrev] [<expr>] [lhs] [rhs] :ca[bbrev] [<expr>] [<buffer>] [lhs] [rhs]
same as ":ab", but for Command-line mode only. {not same as ":ab", but for Command-line mode only. {not
in Vi} in Vi}
@ -962,12 +966,12 @@ See |:verbose-cmd| for more information.
in Vi} in Vi}
*:cnorea* *:cnoreabbrev* *:cnorea* *:cnoreabbrev*
:cnorea[bbrev] [<expr>] [lhs] [rhs] :cnorea[bbrev] [<expr>] [<buffer>] [lhs] [rhs]
same as ":ab", but for Command-line mode only and no same as ":ab", but for Command-line mode only and no
remapping for this {rhs} {not in Vi} remapping for this {rhs} {not in Vi}
*:ia* *:iabbrev* *:ia* *:iabbrev*
:ia[bbrev] [<expr>] [lhs] [rhs] :ia[bbrev] [<expr>] [<buffer>] [lhs] [rhs]
same as ":ab", but for Insert mode only. {not in Vi} same as ":ab", but for Insert mode only. {not in Vi}
*:iuna* *:iunabbrev* *:iuna* *:iunabbrev*
@ -975,18 +979,18 @@ See |:verbose-cmd| for more information.
Vi} Vi}
*:inorea* *:inoreabbrev* *:inorea* *:inoreabbrev*
:inorea[bbrev] [<expr>] [lhs] [rhs] :inorea[bbrev] [<expr>] [<buffer>] [lhs] [rhs]
same as ":ab", but for Insert mode only and no same as ":ab", but for Insert mode only and no
remapping for this {rhs} {not in Vi} remapping for this {rhs} {not in Vi}
*:abc* *:abclear* *:abc* *:abclear*
:abc[lear] Remove all abbreviations. {not in Vi} :abc[lear] [<buffer>] Remove all abbreviations. {not in Vi}
*:iabc* *:iabclear* *:iabc* *:iabclear*
:iabc[lear] Remove all abbreviations for Insert mode. {not in Vi} :iabc[lear] [<buffer>] Remove all abbreviations for Insert mode. {not in Vi}
*:cabc* *:cabclear* *:cabc* *:cabclear*
:cabc[lear] Remove all abbreviations for Command-line mode. {not :cabc[lear] [<buffer>] Remove all abbreviations for Command-line mode. {not
in Vi} in Vi}
*using_CTRL-V* *using_CTRL-V*
@ -1177,13 +1181,15 @@ reported if any are supplied). However, it is possible to specify that the
command can take arguments, using the -nargs attribute. Valid cases are: command can take arguments, using the -nargs attribute. Valid cases are:
-nargs=0 No arguments are allowed (the default) -nargs=0 No arguments are allowed (the default)
-nargs=1 Exactly one argument is required -nargs=1 Exactly one argument is require, it includes spaces
-nargs=* Any number of arguments are allowed (0, 1, or many) -nargs=* Any number of arguments are allowed (0, 1, or many),
separated by white space
-nargs=? 0 or 1 arguments are allowed -nargs=? 0 or 1 arguments are allowed
-nargs=+ Arguments must be supplied, but any number are allowed -nargs=+ Arguments must be supplied, but any number are allowed
Arguments are considered to be separated by (unescaped) spaces or tabs in this Arguments are considered to be separated by (unescaped) spaces or tabs in this
context. context, except when there is one argument, then the white space is part of
the argument.
Note that arguments are used as text, not as expressions. Specifically, Note that arguments are used as text, not as expressions. Specifically,
"s:var" will use the script-local variable in the script where the command was "s:var" will use the script-local variable in the script where the command was
@ -1206,17 +1212,21 @@ completion can be enabled:
-complete=augroup autocmd groups -complete=augroup autocmd groups
-complete=buffer buffer names -complete=buffer buffer names
-complete=color color schemes
-complete=command Ex command (and arguments) -complete=command Ex command (and arguments)
-complete=compiler compilers
-complete=cscope |:cscope| suboptions -complete=cscope |:cscope| suboptions
-complete=dir directory names -complete=dir directory names
-complete=environment environment variable names -complete=environment environment variable names
-complete=event autocommand events -complete=event autocommand events
-complete=expression Vim expression -complete=expression Vim expression
-complete=file file and directory names -complete=file file and directory names
-complete=file_in_path file and directory names in |'path'|
-complete=filetype filetype names |'filetype'| -complete=filetype filetype names |'filetype'|
-complete=function function name -complete=function function name
-complete=help help subjects -complete=help help subjects
-complete=highlight highlight groups -complete=highlight highlight groups
-complete=locale locale names (as output of locale -a)
-complete=mapping mapping name -complete=mapping mapping name
-complete=menu menus -complete=menu menus
-complete=option options -complete=option options
@ -1291,7 +1301,8 @@ Possible attributes are:
-range Range allowed, default is current line -range Range allowed, default is current line
-range=% Range allowed, default is whole file (1,$) -range=% Range allowed, default is whole file (1,$)
-range=N A count (default N) which is specified in the line -range=N A count (default N) which is specified in the line
number position (like |:split|) number position (like |:split|); allows for zero line
number.
-count=N A count (default N) which is specified either in the line -count=N A count (default N) which is specified either in the line
number position, or as an initial argument (like |:Next|). number position, or as an initial argument (like |:Next|).
Specifying -count (without a default) acts like -count=0 Specifying -count (without a default) acts like -count=0

View File

@ -1,4 +1,4 @@
*mbyte.txt* For Vim version 7.3. Last change: 2011 Feb 01 *mbyte.txt* For Vim version 7.3. Last change: 2011 Jul 18
VIM REFERENCE MANUAL by Bram Moolenaar et al. VIM REFERENCE MANUAL by Bram Moolenaar et al.
@ -1306,8 +1306,8 @@ character. However, search patterns may not match on an overlong sequence.
character.) An exception is NUL (zero) which is displayed as "<00>". character.) An exception is NUL (zero) which is displayed as "<00>".
In the file and buffer the full range of Unicode characters can be used (31 In the file and buffer the full range of Unicode characters can be used (31
bits). However, displaying only works for 16 bit characters, and only for the bits). However, displaying only works for the characters present in the
characters present in the selected font. selected font.
Useful commands: Useful commands:
- "ga" shows the decimal, hexadecimal and octal value of the character under - "ga" shows the decimal, hexadecimal and octal value of the character under

View File

@ -1,4 +1,4 @@
*message.txt* For Vim version 7.3. Last change: 2011 Jan 30 *message.txt* For Vim version 7.3. Last change: 2011 May 10
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -27,8 +27,8 @@ The "g<" command can be used to see the last page of previous command output.
This is especially useful if you accidentally typed <Space> at the hit-enter This is especially useful if you accidentally typed <Space> at the hit-enter
prompt. You are then back at the hit-enter prompt and can then scroll further prompt. You are then back at the hit-enter prompt and can then scroll further
back. back.
Note: when you stopped the output with "q" at the more prompt only up to that Note: If the output has been stopped with "q" at the more prompt, it will only
point will be displayed. be displayed up to this point.
The previous command output is cleared when another command produces output. The previous command output is cleared when another command produces output.
If you are using translated messages, the first printed line tells who If you are using translated messages, the first printed line tells who

View File

@ -1,4 +1,4 @@
*motion.txt* For Vim version 7.3. Last change: 2010 May 14 *motion.txt* For Vim version 7.3. Last change: 2011 Jul 19
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -269,11 +269,11 @@ T{char} Till after [count]'th occurrence of {char} to the
{char} can be entered like with the |f| command. {char} can be entered like with the |f| command.
*;* *;*
; Repeat latest f, t, F or T [count] times. ; Repeat latest f, t, F or T [count] times. See |cpo-;|
*,* *,*
, Repeat latest f, t, F or T in opposite direction , Repeat latest f, t, F or T in opposite direction
[count] times. [count] times. See also |cpo-;|
============================================================================== ==============================================================================
3. Up-down motions *up-down-motions* 3. Up-down motions *up-down-motions*
@ -344,6 +344,8 @@ gg Goto line [count], default first line, on the first
last number in it used as the byte count. End-of-line last number in it used as the byte count. End-of-line
characters are counted depending on the current characters are counted depending on the current
'fileformat' setting. 'fileformat' setting.
Also see the |line2byte()| function, and the 'o'
option in 'statusline'.
{not in Vi} {not in Vi}
{not available when compiled without the {not available when compiled without the
|+byte_offset| feature} |+byte_offset| feature}
@ -1015,8 +1017,6 @@ CTRL-O Go to [count] Older cursor position in jump list
<Tab> or *CTRL-I* *<Tab>* <Tab> or *CTRL-I* *<Tab>*
CTRL-I Go to [count] newer cursor position in jump list CTRL-I Go to [count] newer cursor position in jump list
(not a motion command). (not a motion command).
In a |quickfix-window| it takes you to the position of
the error under the cursor.
{not in Vi} {not in Vi}
{not available without the |+jumplist| feature} {not available without the |+jumplist| feature}

View File

@ -1,4 +1,4 @@
*options.txt* For Vim version 7.3. Last change: 2011 Mar 22 *options.txt* For Vim version 7.3. Last change: 2011 Sep 09
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -815,7 +815,7 @@ A jump table for the options with a short description can be found at |Q_op|.
been set. been set.
*'background'* *'bg'* *'background'* *'bg'*
'background' 'bg' string (default "dark" or "light") 'background' 'bg' string (default "dark" or "light", see below)
global global
{not in Vi} {not in Vi}
When set to "dark", Vim will try to use colors that look good on a When set to "dark", Vim will try to use colors that look good on a
@ -849,6 +849,12 @@ A jump table for the options with a short description can be found at |Q_op|.
color). To get around this, force the GUI window to be opened by color). To get around this, force the GUI window to be opened by
putting a ":gui" command in the .gvimrc file, before where the value putting a ":gui" command in the .gvimrc file, before where the value
of 'background' is used (e.g., before ":syntax on"). of 'background' is used (e.g., before ":syntax on").
For MS-DOS, Windows and OS/2 the default is "dark".
For other systems "dark" is used when 'term' is "linux",
"screen.linux", "cygwin" or "putty", or $COLORFGBG suggests a dark
background. Otherwise the default is "light".
Normally this option would be set in the .vimrc file. Possibly Normally this option would be set in the .vimrc file. Possibly
depending on the terminal name. Example: > depending on the terminal name. Example: >
:if &term == "pcterm" :if &term == "pcterm"
@ -2111,6 +2117,12 @@ A jump table for the options with a short description can be found at |Q_op|.
*cpo->* *cpo->*
> When appending to a register, put a line break before > When appending to a register, put a line break before
the appended text. the appended text.
*cpo-;*
; When using |,| or |;| to repeat the last |t| search
and the cursor is right in front of the searched
character, the cursor won't move. When not included,
the cursor would skip over it and jump to the
following occurence.
POSIX flags. These are not included in the Vi default value, except POSIX flags. These are not included in the Vi default value, except
when $VIM_POSIX was set on startup. |posix| when $VIM_POSIX was set on startup. |posix|
@ -2203,6 +2215,16 @@ A jump table for the options with a short description can be found at |Q_op|.
Specifies whether to use quickfix window to show cscope results. Specifies whether to use quickfix window to show cscope results.
See |cscopequickfix|. See |cscopequickfix|.
*'cscoperelative'* *'csre'*
'cscoperelative' 'csre' boolean (default off)
global
{not available when compiled without the |+cscope|
feature}
{not in Vi}
In the absence of a prefix (-P) for cscope. setting this option enables
to use the basename of cscope.out path as the prefix.
See |cscoperelative|.
*'cscopetag'* *'cst'* *'nocscopetag'* *'nocst'* *'cscopetag'* *'cst'* *'nocscopetag'* *'nocst'*
'cscopetag' 'cst' boolean (default off) 'cscopetag' 'cst' boolean (default off)
global global
@ -2917,8 +2939,6 @@ A jump table for the options with a short description can be found at |Q_op|.
This will use the "c" filetype first, then the "doxygen" filetype. This will use the "c" filetype first, then the "doxygen" filetype.
This works both for filetype plugins and for syntax files. More than This works both for filetype plugins and for syntax files. More than
one dot may appear. one dot may appear.
Do not confuse this option with 'osfiletype', which is for the file
type that is actually stored with the file.
This option is not copied to another buffer, independent of the 's' or This option is not copied to another buffer, independent of the 's' or
'S' flag in 'cpoptions'. 'S' flag in 'cpoptions'.
Only normal file name characters can be used, "/\*?[|<>" are illegal. Only normal file name characters can be used, "/\*?[|<>" are illegal.
@ -3094,7 +3114,7 @@ A jump table for the options with a short description can be found at |Q_op|.
closed. Also for manually closed folds. With the default value of closed. Also for manually closed folds. With the default value of
one a fold can only be closed if it takes up two or more screen lines. one a fold can only be closed if it takes up two or more screen lines.
Set to zero to be able to close folds of just one screen line. Set to zero to be able to close folds of just one screen line.
Note that this only has an effect of what is displayed. After using Note that this only has an effect on what is displayed. After using
"zc" to close a fold, which is displayed open because it's smaller "zc" to close a fold, which is displayed open because it's smaller
than 'foldminlines', a following "zc" may close a containing fold. than 'foldminlines', a following "zc" may close a containing fold.
@ -3389,7 +3409,7 @@ A jump table for the options with a short description can be found at |Q_op|.
:highlight Cursor gui=NONE guifg=bg guibg=fg :highlight Cursor gui=NONE guifg=bg guibg=fg
< <
*'guifont'* *'gfn'* *'guifont'* *'gfn'*
*E235* *E596* *E610* *E611* *E235* *E596*
'guifont' 'gfn' string (default "") 'guifont' 'gfn' string (default "")
global global
{not in Vi} {not in Vi}
@ -4098,7 +4118,8 @@ A jump table for the options with a short description can be found at |Q_op|.
It is used when a new line is created, for the |=| operator and It is used when a new line is created, for the |=| operator and
in Insert mode as specified with the 'indentkeys' option. in Insert mode as specified with the 'indentkeys' option.
When this option is not empty, it overrules the 'cindent' and When this option is not empty, it overrules the 'cindent' and
'smartindent' indenting. 'smartindent' indenting. When 'lisp' is set, this option is
overridden by the Lisp indentation algorithm.
When 'paste' is set this option is not used for indenting. When 'paste' is set this option is not used for indenting.
The expression is evaluated with |v:lnum| set to the line number for The expression is evaluated with |v:lnum| set to the line number for
which the indent is to be computed. The cursor is also in this line which the indent is to be computed. The cursor is also in this line
@ -4840,6 +4861,10 @@ A jump table for the options with a short description can be found at |Q_op|.
written. A ":set nomodified" command also resets the original written. A ":set nomodified" command also resets the original
values to the current values and the 'modified' option will be values to the current values and the 'modified' option will be
reset. reset.
This option is not set when a change is made to the buffer as the
result of a BufNewFile, BufRead/BufReadPost, BufWritePost,
FileAppendPost or VimLeave autocommand event. See |gzip-example| for
an explanation.
When 'buftype' is "nowrite" or "nofile" this option may be set, but When 'buftype' is "nowrite" or "nofile" this option may be set, but
will be ignored. will be ignored.
@ -5106,20 +5131,12 @@ A jump table for the options with a short description can be found at |Q_op|.
security reasons. security reasons.
*'osfiletype'* *'oft'* *E366* *'osfiletype'* *'oft'*
'osfiletype' 'oft' string (RISC-OS default: "Text", 'osfiletype' 'oft' string (default: "")
others default: "")
local to buffer local to buffer
{not in Vi} {not in Vi}
{only available when compiled with the |+osfiletype| This option was supported on RISC OS, which has been removed.
feature}
Some operating systems store extra information about files besides
name, datestamp and permissions. This option contains the extra
information, the nature of which will vary between systems.
The value of this option is usually set when the file is loaded, and
is used to set the operating system file type when file is written.
It can affect the pattern matching of the automatic commands.
|autocmd-osfiletypes|
*'paragraphs'* *'para'* *'paragraphs'* *'para'*
'paragraphs' 'para' string (default "IPLPPPQPP TPHPLIPpLpItpplpipbp") 'paragraphs' 'para' string (default "IPLPPPQPP TPHPLIPpLpItpplpipbp")
@ -5885,8 +5902,11 @@ A jump table for the options with a short description can be found at |Q_op|.
"bash.exe -c ls" or "command.com /c dir". For the MS-DOS-like "bash.exe -c ls" or "command.com /c dir". For the MS-DOS-like
systems, the default is set according to the value of 'shell', to systems, the default is set according to the value of 'shell', to
reduce the need to set this option by the user. It's not used for reduce the need to set this option by the user. It's not used for
OS/2 (EMX figures this out itself). See |option-backslash| about OS/2 (EMX figures this out itself).
including spaces and backslashes. See |dos-shell|. On Unix it can have more than one flag. Each white space separated
part is passed as an argument to the shell command.
See |option-backslash| about including spaces and backslashes.
Also see |dos-shell| for MS-DOS and MS-Windows.
This option cannot be set from a |modeline| or in the |sandbox|, for This option cannot be set from a |modeline| or in the |sandbox|, for
security reasons. security reasons.
@ -5907,9 +5927,10 @@ A jump table for the options with a short description can be found at |Q_op|.
For Unix the default it "| tee". The stdout of the compiler is saved For Unix the default it "| tee". The stdout of the compiler is saved
in a file and echoed to the screen. If the 'shell' option is "csh" or in a file and echoed to the screen. If the 'shell' option is "csh" or
"tcsh" after initializations, the default becomes "|& tee". If the "tcsh" after initializations, the default becomes "|& tee". If the
'shell' option is "sh", "ksh", "zsh" or "bash" the default becomes 'shell' option is "sh", "ksh", "mksh", "pdksh", "zsh" or "bash" the
"2>&1| tee". This means that stderr is also included. Before using default becomes "2>&1| tee". This means that stderr is also included.
the 'shell' option a path is removed, thus "/bin/sh" uses "sh". Before using the 'shell' option a path is removed, thus "/bin/sh" uses
"sh".
The initialization of this option is done after reading the ".vimrc" The initialization of this option is done after reading the ".vimrc"
and the other initializations, so that when the 'shell' option is set and the other initializations, so that when the 'shell' option is set
there, the 'shellpipe' option changes automatically, unless it was there, the 'shellpipe' option changes automatically, unless it was
@ -5988,7 +6009,8 @@ A jump table for the options with a short description can be found at |Q_op|.
{not in Vi} {not in Vi}
When on, use temp files for shell commands. When off use a pipe. When on, use temp files for shell commands. When off use a pipe.
When using a pipe is not possible temp files are used anyway. When using a pipe is not possible temp files are used anyway.
Currently a pipe is only supported on Unix. You can check it with: > Currently a pipe is only supported on Unix and MS-Windows 2K and
later. You can check it with: >
:if has("filterpipe") :if has("filterpipe")
< The advantage of using a pipe is that nobody can read the temp file < The advantage of using a pipe is that nobody can read the temp file
and the 'shell' command does not need to support redirection. and the 'shell' command does not need to support redirection.

View File

@ -1,322 +1,12 @@
*os_risc.txt* For Vim version 7.3. Last change: 2010 Aug 07 *os_risc.txt* For Vim version 7.3. Last change: 2011 May 10
VIM REFERENCE MANUAL by Thomas Leonard VIM REFERENCE MANUAL by Thomas Leonard
*riscos* *RISCOS* *RISC-OS* *riscos* *RISCOS* *RISC-OS*
This file contains the particularities for the RISC OS version of Vim. The RISC OS support has been removed from Vim with patch 7.3.187.
If you would like to use Vim on RISC OS get the files from before that patch.
The RISC OS port is a completely new port and is not based on the old "archi"
port.
1. File locations |riscos-locations|
2. Filename munging |riscos-munging|
3. Command-line use |riscos-commandline|
4. Desktop (GUI) use |riscos-gui|
5. Remote use (telnet) |riscos-remote|
6. Temporary files |riscos-temp-files|
7. Interrupting |riscos-interrupt|
8. Memory usage |riscos-memory|
9. Filetypes |riscos-filetypes|
10. The shell |riscos-shell|
11. Porting new releases |riscos-porting|
If I've missed anything, email me and I'll try to fix it. In fact, even if I
haven't missed anything then email me anyway to give me some confidence that it
actually works!
Thomas Leonard <tal197@ecs.soton.ac.uk>
[these URLs no longer work...]
Port homepage: http://www.ecs.soton.ac.uk/~tal197/
or try: http://www.soton.ac.uk/~tal197/
==============================================================================
*riscos-locations*
1. File locations
The Vim executable and shared resource files are all stored inside the !Vim
application directory.
When !Vim is first seen by the filer, it aliases the *vi and *ex commands to
run the command-line versions of Vim (see |riscos-commandline|).
!Vim.Resources and !Vim.Resources2 contain the files from the standard Vim
distribution, but modified slightly to work within the limits of ADFS, plus
some extra files such as the window templates.
User choices are read from "Choices:*" and are saved to "<Choices$Write>.*".
If you have the new !Boot structure then these should be set up already. If
not, set Choices$Path to a list of directories to search when looking for
user configuration files. Set Choices$Write to the directory you want files
to be saved into (so your search patterns and marks can be remembered between
sessions).
==============================================================================
*riscos-munging*
2. Filename munging
All pathname munging is disabled by default, so Vim should behave like a
normal RISC OS application now. So, if you want to edit "doc/html" then you
actually type "*vi doc/html".
The only times munging is done is when:
- Searching included files from C programs, since these are always munged.
See |[I|.
Note: make sure you are in the right directory when you use this
command (i.e. the one with subdirectories "c" and "h").
- Sourcing files using |:so|.
Paths starting "$VIM/" are munged like this:
$VIM/syntax/help.vim -> Vim:syntax.help
Also, files ending in ".vim" have their extensions removed, and slashes
replaced with dots.
Some tag files and script files may have to be edited to work under this port.
==============================================================================
*riscos-commandline*
3. Command-line use
To use Vim from the command-line use the "*vi" command (or "*ex" for
|Ex-mode|).
Type "*vi -h" for a list of options.
Running the command-line version of Vim in a large high-color mode may cause
the scrolling to be very slow. Either change to a mode with fewer colors or
use the GUI version.
Also, holding down Ctrl will slow it down even more, and Ctrl-Shift will
freeze it, as usual for text programs.
==============================================================================
*riscos-gui*
4. Desktop use
Limitations:
- Left scrollbars don't work properly (right and bottom are fine).
- Doesn't increase scroll speed if it gets behind.
You can resize the window by dragging the lower-right corner, even though
there is no icon shown there.
You can use the --rows and --columns arguments to specify the initial size of
the Vim window, like this: >
*Vi -g --rows 20 --columns 80
The global clipboard is supported, so you can select some text and then
paste it directly into another application (provided it supports the
clipboard too).
Clicking Menu now opens a menu like a normal RISC OS program. Hold down Shift
when clicking Menu to paste (from the global clipboard).
Dragging a file to the window replaces the CURRENT buffer (the one with the
cursor, NOT the one you dragged to) with the file.
Dragging with Ctrl held down causes a new Vim window to be opened for the
file (see |:sp|).
Dragging a file in with Shift held down in insert mode inserts the pathname of
the file.
:browse :w opens a standard RISC OS save box.
:browse :e opens a directory viewer.
For fonts, you have the choice of the system font, an outline font, the system
font via ZapRedraw and any of the Zap fonts via ZapRedraw: >
:set guifont=
< To use the system font via the VDU drivers. Supports
bold and underline.
>
:set guifont=Corpus.Medium
< Use the named outline font. You can use any font, but
only monospaced ones like Corpus look right.
>
:set guifont=Corpus.Medium:w8:h12:b:i
< As before, but with size of 8 point by 12 point, and
in bold italic.
If only one of width and height is given then that
value is used for both. If neither is given then 10
point is used.
Thanks to John Kortink, Vim can use the ZapRedraw module. Start the font name
with "!" (or "!!" for double height), like this: >
:set guifont=!!
< Use the system font, but via ZapRedraw. This gives a
faster redraw on StrongARM processors, but you can't
get bold or italic text. Double height.
>
:set guifont=!script
< Uses the named Zap font (a directory in VimFont$Path).
The redraw is the same speed as for "!!", but you get
a nicer looking font.
Only the "man+" and "script" fonts are supplied
currently, but you can use any of the Zap fonts if
they are in VimFont$Path.
Vim will try to load font files "0", "B", "I" and "IB"
from the named directory. Only "0" (normal style) MUST
be present. Link files are not currently supported.
Note that when using ZapRedraw the edit bar is drawn in front of the character
you are on rather than behind it. Also redraw is incorrect for screen modes
with eigen values of 0. If the font includes control characters then you can
get Vim to display them by changing the 'isprint' option.
If you find the scrolling is too slow on your machine, try experimenting
with the 'scrolljump' and 'ttyscroll' options.
In particular, StrongARM users may find that: >
:set ttyscroll=0
makes scrolling faster in high-color modes.
=============================================================================
*riscos-remote*
5. Remote use (telnet)
I have included a built-in termcap entry, but you can edit the termcap file to
allow other codes to be used if you want to use Vim from a remote terminal.
Although I do not have an internet connection to my Acorn, I have managed to
run Vim in a FreeTerm window using the loopback connection.
It seems to work pretty well now, using "*vi -T ansi".
==============================================================================
*riscos-temp-files*
6. Temporary files
If Vim crashes then the swap and backup files (if any) will be in the
directories set with the 'directory' and 'bdir' options. By default the swap
files are in <Wimp$ScrapDir> (i.e. inside !Scrap) and backups are in the
directory you were saving to. Vim will allow you to try and recover the file
when you next try to edit it.
To see a list of swap files, press <F12> and type "*vi -r".
Vim no longer brings up ATTENTION warnings if you try to edit two files with
the same name in different directories.
However, it also no longer warns if you try to edit the same file twice (with
two copies of Vim), though you will still be warned when you save that the
datestamp has changed.
==============================================================================
*riscos-interrupt*
7. Interrupting
To break out of a looping macro, or similar, hold down Escape in the
command-line version, or press CTRL-C in the GUI version.
==============================================================================
*riscos-memory*
8. Memory usage
Vim will use dynamic areas on RISC OS 3.5 or later. If you can use them on
older machines then edit the !RunTxt and GVim files. I don't know what UnixLib
does by default on these machines so I'm playing safe.
It doesn't work at all well without dynamic areas, since it can't change its
memory allocation once running. Hence you should edit "!Vim.GVim" and
"!Vim.!RunTxt" to choose the best size for you. You probably need at least
about 1400K.
==============================================================================
*riscos-filetypes*
9. Filetypes
You can now specify that autocommands are only executed for files of certain
types. The filetype is given in the form &xxx, when xxx is the filetype.
Filetypes must be specified by number (e.g. &fff for Text).
The system has changed from version 5.3. The new sequence of events is:
- A file is loaded. |'osfiletype'| is set to the RISC OS filetype.
- Based on the filetype and pathname, Vim will try to set |'filetype'| to the
Vim-type of the file.
- Setting this option may load syntax files and perform other actions.
- Saving the file will give it a filetype of |'osfiletype'|.
Some examples may make this clearer:
Kind of file loaded osfiletype filetype ~
C code "c.hellow" Text (&fff) C
LaTeX document LaTeX (&2a8) TeX
Draw document DrawFile (&aff) (not changed)
==============================================================================
*riscos-shell*
10. The shell
- Bangs (!s) are only replaced if they are followed by a space or end-of-line,
since many pathnames contain them.
- You can prefix the command with "~", which stops any output from being
displayed. This also means that you don't have to press <Enter> afterwards,
and stops the screen from being redrawn. {only in the GUI version}
==============================================================================
*riscos-porting*
11. Porting new releases to RISC OS
Downloading everything you need:
- Get the latest source distribution (see www.vim.org)
- Get the runtime environment files (e.g. these help files)
- Get the RISC OS binary distribution (if possible)
Unarchiving:
- Create a raFS disk and put the archives on it
- Un-gzip them
- Un-tar them (*tar xELf 50 archive/tar)
Recompiling the sources:
- Create c, s, and h directories.
- Put all the header files in "h". \
- Put all the C files in "c". | And lose the extensions
- Put the assembler file ("swis/s") in "s". /
- Rename all the files in "proto" to "h", like this:
raFS::VimSrc.source.proto.file/pro
becomes
raFS::VimSrc.source.h.file_pro
- In the files "h.proto" and "c.termlib", search and replace
.pro"
with
_pro.h"
- Create a simple Makefile if desired and do "*make -k".
Use "CC = gcc -DRISCOS -DUSE_GUI -O2 -x c" in the Makefile.
- Save the binary as !Vim.Vim in the binary distribution.
Updating the run-time environment:
- Replace old or missing files inside !Vim.Resources with the
new files.
- Remove files in "doc" not ending in "/txt", except for "tags".
- Lose the extensions from the files in "doc".
- Edit the "doc.tags" file. Remove extensions from the second column: >
:%s/^\(.[^\t]*\t.*\)\.txt\t/\1\t/
- Remove extensions from the syntax files. Split them into two directories
to avoid the 77 entry limit on old ADFS filesystems.
- Edit "Vim:FileType" to match "*.c.*" as well as "*/c" and so on.
Add filetype checking too.
- Edit "Vim:Menu" and remove all the keys from the menus: >
:%s/<Tab>[^ \t]*//
<
vim:tw=78:ts=8:ft=help:norl: vim:tw=78:ts=8:ft=help:norl:

View File

@ -1,4 +1,4 @@
*os_vms.txt* For Vim version 7.3. Last change: 2010 Aug 16 *os_vms.txt* For Vim version 7.3. Last change: 2011 Aug 14
VIM REFERENCE MANUAL VIM REFERENCE MANUAL
@ -38,9 +38,6 @@ You can download the Vim source code by ftp from the official Vim site:
Or use one of the mirrors: Or use one of the mirrors:
ftp://ftp.vim.org/pub/vim/MIRRORS ftp://ftp.vim.org/pub/vim/MIRRORS
You will need both the Unix and Extra archives to build vim.exe for VMS.
For using Vim's full power you will need the runtime files as well.
You can download precompiled executables from: You can download precompiled executables from:
http://www.polarhome.com/vim/ http://www.polarhome.com/vim/
ftp://ftp.polarhome.com/pub/vim/ ftp://ftp.polarhome.com/pub/vim/
@ -75,7 +72,7 @@ See the file [.SRC]INSTALLVMS.TXT.
4. Problems *vms-problems* 4. Problems *vms-problems*
The code has been tested under Open VMS 6.2 - 8.2 on Alpha, VAX and IA64 The code has been tested under Open VMS 6.2 - 8.2 on Alpha, VAX and IA64
platforms with the DEC C compiler. It should work without bigger problems. platforms with the DEC C compiler. It should work without big problems.
If your system does not have some include libraries you can tune up in If your system does not have some include libraries you can tune up in
OS_VMS_CONF.H file. OS_VMS_CONF.H file.
@ -88,11 +85,11 @@ Also GTK, XPM library paths should be configured in MAKE_VMS.MMS
Note: Under VAX it should work with the DEC C compiler without problems. The Note: Under VAX it should work with the DEC C compiler without problems. The
VAX C compiler is not fully ANSI C compatible in pre-processor directives VAX C compiler is not fully ANSI C compatible in pre-processor directives
semantics, therefore you have to use a converter program what will do the lion semantics, therefore you have to use a converter program that will do the lion
part of the job. For detailed instructions read file INSTALLvms.txt part of the job. For detailed instructions read file INSTALLvms.txt
MMS_VIM.EXE is build together with VIM.EXE, but for XD.EXE you should MMS_VIM.EXE is build together with VIM.EXE, but for XXD.EXE you should
change to subdirectory and build it separately. change to a subdirectory and build it separately.
CTAGS is not part of the Vim source distribution anymore, however the OpenVMS CTAGS is not part of the Vim source distribution anymore, however the OpenVMS
specific source might contain CTAGS source files as described above. specific source might contain CTAGS source files as described above.
@ -184,9 +181,9 @@ You may want to create .vimrc and .gvimrc files in your home directory
The easiest way is just rename example files. You may leave the menu file The easiest way is just rename example files. You may leave the menu file
(MENU.VIM) and files vimrc and gvimrc in the original $VIM directory. It will (MENU.VIM) and files vimrc and gvimrc in the original $VIM directory. It will
be default setup for all users, and for users it is enough just to have their be the default setup for all users, and for users it is enough to just have
own additions or resetting in their home directory in files .vimrc and .gvimrc. their own additions or resetting in their home directory in files .vimrc and
It should work without problems. .gvimrc. It should work without problems.
Note: Remember, system rc files (default for all users) don't have a leading Note: Remember, system rc files (default for all users) don't have a leading
".". So, system rc files are: > ".". So, system rc files are: >
@ -200,7 +197,7 @@ and user customized rc files are: >
sys$login:.vimrc sys$login:.vimrc
sys$login:.gvimrc sys$login:.gvimrc
You can check that everything is on the right place with the :version command. You can check that everything is at the right place with the :version command.
Example LOGIN.COM: > Example LOGIN.COM: >
@ -209,15 +206,15 @@ Example LOGIN.COM: >
$ gv*im:== spawn/nowait/input=NLA0 mcr VIM:VIM.EXE -g -GEOMETRY 80x40 $ gv*im:== spawn/nowait/input=NLA0 mcr VIM:VIM.EXE -g -GEOMETRY 80x40
$ set disp/create/node=192.168.5.223/trans=tcpip $ set disp/create/node=192.168.5.223/trans=tcpip
Note: This set-up should be enough, if you are working on standalone server or Note: This set-up should be enough, if you are working on a standalone server or
clustered environment, but if you want to use Vim as internode editor in clustered environment, but if you want to use Vim as an internode editor in
DECNET environment, it will satisfy as well. DECNET environment, it will satisfy as well.
You just have to define the "whole" path: > You just have to define the "whole" path: >
$ define VIM "<server_name>[""user password""]::device:<path>" $ define VIM "<server_name>[""user password""]::device:<path>"
$ vi*m :== "mcr VIM:VIM.EXE" $ vi*m :== "mcr VIM:VIM.EXE"
As for example: > For example: >
$ define VIM "PLUTO::RF10:[UTIL.VIM]" $ define VIM "PLUTO::RF10:[UTIL.VIM]"
$ define VIM "PLUTO""ZAY mypass""::RF10:[UTIL.VIM]" ! if passwd required $ define VIM "PLUTO""ZAY mypass""::RF10:[UTIL.VIM]" ! if passwd required
@ -300,12 +297,12 @@ For more information type $help set disp in VMS prompt.
4) If you are working on MS-Windows or some other non X/Window environment 4) If you are working on MS-Windows or some other non X/Window environment
you need to set up one X server and run Vim as in point 2. you need to set up one X server and run Vim as in point 2.
For MS-Windows there are available free X servers as MIX , Omni X etc., For MS-Windows there are available free X servers as MIX, Omni X etc.,
as well as excellent commercial products as eXcursion or ReflectionX with as well as excellent commercial products as eXcursion or ReflectionX with
built-in DEC support. built-in DEC support.
Please note, that executables without GUI are slightly faster during startup Please note, that executables without GUI are slightly faster during startup
then with enabled GUI in character mode. Therefore, if you do not use GUI than with enabled GUI in character mode. Therefore, if you do not use GUI
features, it is worth to choose non GUI executables. features, it is worth to choose non GUI executables.
============================================================================== ==============================================================================
@ -326,8 +323,8 @@ features, it is worth to choose non GUI executables.
8.12 diff-mode 8.12 diff-mode
8.13 Allow '$' in C keywords 8.13 Allow '$' in C keywords
8.14 VIMTUTOR for beginners 8.14 VIMTUTOR for beginners
8.15 Slow start in console mode issue 8.15 Slow start in console mode issue
8.16 Common VIM directory - different architectures 8.16 Common VIM directory - different architectures
8.1 Backspace/delete 8.1 Backspace/delete
@ -360,7 +357,7 @@ number, try these settings. >
:set nowritebackup " does not have any purpose on VMS. It's the :set nowritebackup " does not have any purpose on VMS. It's the
" default. " default.
Recovery is working perfect as well from the default swap file. Recovery is working perfectly as well from the default swap file.
Read more with :help swapfile Read more with :help swapfile
(Claude Marinier <ClaudeMarinier@xwavesolutions.com> Vim 5.5, Zoltan Arpadffy (Claude Marinier <ClaudeMarinier@xwavesolutions.com> Vim 5.5, Zoltan Arpadffy
@ -386,7 +383,7 @@ Note: You may use <,> brackets as well (device:<path>file.ext;version) as
rf10:<user.zay.work>test.c;1 rf10:<user.zay.work>test.c;1
(David Elins <delins@foliage.com>, Jerome Lauret (David Elins <delins@foliage.com>, Jerome Lauret
<JLAURET@mail.chem.sunysb.edu> Vim 5.6 ) <JLAURET@mail.chem.sunysb.edu> Vim 5.6)
8.5 Remote host invocation 8.5 Remote host invocation
@ -445,14 +442,14 @@ Terminal entry not found in termcap
builtin_dumb builtin_dumb
defaulting to 'vt320' defaulting to 'vt320'
--- ---
The solution is to define default terminal name: > The solution is to define the default terminal name: >
$ ! unknown terminal name. Let us use vt320 or ansi instead. $ ! unknown terminal name. Let us use vt320 or ansi instead.
$ ! Note: it's case sensitive $ ! Note: it's case sensitive
$ define term "vt320" $ define term "vt320"
Terminals from VT100 to VT320 (as V300, VT220, VT200 ) do not need any extra Terminals from VT100 to VT320 (as V300, VT220, VT200) do not need any extra
keyboard mappings. They should work perfect as they are, including arrows, keyboard mappings. They should work perfectly as they are, including arrows,
Ins, Del buttons etc., except Backspace in GUI mode. To solve it, add to Ins, Del buttons etc., except Backspace in GUI mode. To solve it, add to
.gvimrc: > .gvimrc: >
@ -465,8 +462,8 @@ your .vimrc file: >
set ttyfast " set fast terminal set ttyfast " set fast terminal
Note: if you're using Vim on remote host or through very slow connection, it's Note: if you're using Vim on remote host or through a very slow connection, it's
recommended to avoid fast terminal option with: > recommended to avoid the fast terminal option with: >
set nottyfast " set terminal to slow mode set nottyfast " set terminal to slow mode
@ -483,8 +480,8 @@ special commands to execute executables: >
OpenVMS users always have to be aware that the Vim command :! "just" drop them OpenVMS users always have to be aware that the Vim command :! "just" drop them
to DCL prompt. This feature is possible to use without any problem with all to DCL prompt. This feature is possible to use without any problem with all
DCL commands, but if we want to execute some program as XXD, CTAGS, JTAGS etc. DCL commands, but if we want to execute some programs such as XXD, CTAGS, JTAGS,
we're running into trouble if we follow the Vim documentation (see: help etc. we're running into trouble if we follow the Vim documentation (see: help
xxd). xxd).
Solution: Execute with the MC command and add the full path to the executable. Solution: Execute with the MC command and add the full path to the executable.
@ -534,7 +531,7 @@ Example: >
$define SYS$PRINT HP5ANSI $define SYS$PRINT HP5ANSI
You can print out whole buffer or just the marked area. You can print out the whole buffer or just the marked area.
More info under :help hardcopy More info under :help hardcopy
(Zoltan Arpadffy, Vim 6.0c) (Zoltan Arpadffy, Vim 6.0c)
@ -561,16 +558,16 @@ will be confused after a window-resize.
From 6.0 diff functionality has been implemented, but OpenVMS does not use From 6.0 diff functionality has been implemented, but OpenVMS does not use
GNU/Unix like diff therefore built in diff does not work. GNU/Unix like diff therefore built in diff does not work.
There is a simple solution to solve this anomaly. Install a Unix like diff There is a simple solution to solve this anomaly. Install a Unix like diff
and Vim will work perfect in diff mode too. You just have to redefine your and Vim will work perfectly in diff mode too. You just have to redefine your
diff program as: > diff program as: >
define /nolog diff <GNU_PATH>diff.exe define /nolog diff <GNU_PATH>diff.exe
Another, more sophisticated solution is described below (8.12 diff-mode) Another, more sophisticated solution is described below (8.12 diff-mode)
There are some other programs as patch, make etc that may cause same problems. There are other programs such as patch, make etc that may cause the same
At www.polarhome.com is possible to download an GNU package for Alpha and VAX problems. At www.polarhome.com is possible to download an GNU package for
boxes that is meant to solve GNU problems on OpenVMS. Alpha and VAX boxes that is meant to solve GNU problems on OpenVMS.
( Zoltan Arpadffy, Vim 6.1) (Zoltan Arpadffy, Vim 6.1)
8.12 diff-mode 8.12 diff-mode
@ -632,7 +629,7 @@ You can now compare files in 4 ways: >
3. VIM diff: $ VIMDIFF <FILE1> <FILE2> 3. VIM diff: $ VIMDIFF <FILE1> <FILE2>
4. GVIM diff: $ GVIMDIFF <FILE1> <FILE2> 4. GVIM diff: $ GVIMDIFF <FILE1> <FILE2>
( Coen Engelbarts, Vim 6.1) (Coen Engelbarts, Vim 6.1)
8.13 Allow '$' in C keywords 8.13 Allow '$' in C keywords
@ -653,35 +650,36 @@ Now word-based commands, e.g. the '*'-search-command and the CTRL-]
tag-lookup, work on the whole identifier. (Ctags on VMS also supports '$' in tag-lookup, work on the whole identifier. (Ctags on VMS also supports '$' in
C keywords since ctags version 5.1.) C keywords since ctags version 5.1.)
( Coen Engelbarts, Vim 6.1) (Coen Engelbarts, Vim 6.1)
8.14 VIMTUTOR for beginners 8.14 VIMTUTOR for beginners
It exits VIMTUTOR.COM DCL script that can help Vim beginners to learn/make The VIMTUTOR.COM DCL script can help Vim beginners to learn/make their first
first steps with Vim on OpenVMS. Depending of binary distribution you may steps with Vim on OpenVMS. Depending of binary distribution you may start it
start it with: > with: >
@vim:vimtutor @vim:vimtutor
(Thomas.R.Wyant III, Vim 6.1) (Thomas.R.Wyant III, Vim 6.1)
8.14 Slow start in console mode issue 8.16 Slow start in console mode issue
As GUI/GTK Vim works equally well in console mode, many administrators As GUI/GTK Vim works equally well in console mode, many administrators
deploy those executables system wide. deploy those executables system wide.
Unfortunately, on a remote slow connections GUI/GTK executables behave rather Unfortunately, on a remote slow connections GUI/GTK executables behave rather
slow when user wants to run Vim just in the console mode - because of X environment detection timeout. slow when user wants to run Vim just in the console mode - because of X
environment detection timeout.
Luckily, there is a simple solution for that. Administrators need to deploy Luckily, there is a simple solution for that. Administrators need to deploy
both GUI/GTK build and just console build executables, like below: > both GUI/GTK build and just console build executables, like below: >
|- vim73 |- vim73
|----- doc |----- doc
|----- syntax |----- syntax
vimrc (system rc files) vimrc (system rc files)
gvimrc gvimrc
gvim.exe (the renamed GUI or GTK built vim.exe) gvim.exe (the renamed GUI or GTK built vim.exe)
vim.exe (the console only executable) vim.exe (the console only executable)
Define system symbols like below in for ex in LOGIN.COM or SYLOGIN.COM: > Define system symbols like below in for ex in LOGIN.COM or SYLOGIN.COM: >
@ -692,7 +690,7 @@ Define system symbols like below in for ex in LOGIN.COM or SYLOGIN.COM: >
$ gv*im :== spawn/nowait/input=NLA0 mcr VIM:GVIM.EXE -g -GEOMETRY 80x40 $ gv*im :== spawn/nowait/input=NLA0 mcr VIM:GVIM.EXE -g -GEOMETRY 80x40
Like this, users that do not have X environment and want to use Vim just in Like this, users that do not have X environment and want to use Vim just in
console mode can avoid performance problems. console mode can avoid performance problems.
(Zoltan Arpadffy, Vim 7.2) (Zoltan Arpadffy, Vim 7.2)
@ -714,8 +712,8 @@ View of Cluster from system ID 11655 node: TOR
+---------------------------------+ +---------------------------------+
It is convenient to have a common VIM directory but execute different It is convenient to have a common VIM directory but execute different
executables. executables.
There are more solutions for this problem: There are several solutions for this problem:
Solution 1. All executables in the same directory with different names Solution 1. All executables in the same directory with different names
This is easily done with the following script that can be added This is easily done with the following script that can be added
@ -769,7 +767,7 @@ GNU_TOOLS.ZIP package downloadable from http://www.polarhome.com/vim/
Version 7.3 Version 7.3
- CTAGS 5.8 included - CTAGS 5.8 included
- VMS compile warnings fixed - floating-point overflow warning corrected on VAX - VMS compile warnings fixed - floating-point overflow warning corrected on VAX
- filepath completition corrected - too many chars were escaped in filename - filepath completion corrected - too many chars were escaped in filename
and shell commands and shell commands
- the following plugins are included into VMS runtime: - the following plugins are included into VMS runtime:
genutils 2.4, multiselect 2.2, multvals 3.1, selectbuf 4.3, genutils 2.4, multiselect 2.2, multvals 3.1, selectbuf 4.3,
@ -784,10 +782,10 @@ Version 7.3
Version 7.2 (2008 Aug 9) Version 7.2 (2008 Aug 9)
- VCF files write corrected - VCF files write corrected
- CTAGS 5.7 included - CTAGS 5.7 included
- corrected make_vms.mms (on VAX gave syntax error) - corrected make_vms.mms (on VAX gave syntax error)
Version 7.1 (2007 Jun 15) Version 7.1 (2007 Jun 15)
- create TAGS file from menu - create TAGS file from menu
Version 7 (2006 May 8) Version 7 (2006 May 8)
- Improved low level char input (affects just console mode) - Improved low level char input (affects just console mode)

View File

@ -1,4 +1,4 @@
*os_win32.txt* For Vim version 7.3. Last change: 2010 Dec 19 *os_win32.txt* For Vim version 7.3. Last change: 2011 Aug 14
VIM REFERENCE MANUAL by George Reilly VIM REFERENCE MANUAL by George Reilly
@ -313,7 +313,37 @@ A. When using :! to run an external command, you can run it with "start": >
with :!start do not get passed Vim's open file handles, which means they do with :!start do not get passed Vim's open file handles, which means they do
not have to be closed before Vim. not have to be closed before Vim.
To avoid this special treatment, use ":! start". To avoid this special treatment, use ":! start".
The optional "/min" argument causes the window to be minimized. There are two optional arguments (see the next Q):
/min the window will be minimized.
/b" no console window will be opened
You can use only one of these flags at a time. A second one will be
treated as the start of the command.
Q. How do I avoid getting a window for programs that I run asynchronously?
A. You have two possible solutions depending on what you want:
1) You may use the /min flag in order to run program in a minimized state
with no other changes. It will work equally for console and GUI
applications.
2) You can use the /b flag to run console applications without creating a
console window for them (GUI applications are not affected). But you
should use this flag only if the application you run doesn't require any
input. Otherwise it will get an EOF error because its input stream
(stdin) would be redirected to \\.\NUL (stdout and stderr too).
Example for a console application, run Exuberant ctags: >
:!start /min ctags -R .
< When it has finished you should see file named "tags" in your current
directory. You should notice the window title blinking on your taskbar.
This is more noticable for commands that take longer.
Now delete the "tags" file and run this command: >
:!start /b ctags -R .
< You should have the same "tags" file, but this time there will be no
blinking on the taskbar.
Example for a GUI application: >
:!start /min notepad
:!start /b notepad
< The first command runs notepad minimized and the second one runs it
normally.
Q. I'm using Win32s, and when I try to run an external command like "make", Q. I'm using Win32s, and when I try to run an external command like "make",
Vim doesn't wait for it to finish! Help! Vim doesn't wait for it to finish! Help!

View File

@ -1,4 +1,4 @@
*pattern.txt* For Vim version 7.3. Last change: 2011 Feb 25 *pattern.txt* For Vim version 7.3. Last change: 2011 Jul 20
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -635,7 +635,8 @@ overview.
Like '(?!pattern)" in Perl. Like '(?!pattern)" in Perl.
Example matches ~ Example matches ~
foo\(bar\)\@! any "foo" not followed by "bar" foo\(bar\)\@! any "foo" not followed by "bar"
a.\{-}p\@! "a", "ap", "app", etc. not followed by a "p" a.\{-}p\@! "a", "ap", "aap", "app", etc. not immediately
followed by a "p"
if \(\(then\)\@!.\)*$ "if " not followed by "then" if \(\(then\)\@!.\)*$ "if " not followed by "then"
Using "\@!" is tricky, because there are many places where a pattern Using "\@!" is tricky, because there are many places where a pattern
@ -651,6 +652,13 @@ overview.
"foobar" you could use "\(foo\)\@!...bar", but that doesn't match a "foobar" you could use "\(foo\)\@!...bar", but that doesn't match a
bar at the start of a line. Use "\(foo\)\@<!bar". bar at the start of a line. Use "\(foo\)\@<!bar".
Useful example: to find "foo" in a line that does not contain "bar": >
/^\%(.*bar\)\@!.*\zsfoo
< This pattern first checks that there is not a single position in the
line where "bar" matches. If ".*bar" matches somewhere the \@! will
reject the pattern. When there is no match any "foo" will be found.
The "\zs" is to have the match start just before "foo".
*/\@<=* */\@<=*
\@<= Matches with zero width if the preceding atom matches just before what \@<= Matches with zero width if the preceding atom matches just before what
follows. |/zero-width| {not in Vi} follows. |/zero-width| {not in Vi}
@ -1028,11 +1036,9 @@ x A single character, with no special meaning, matches itself
These items only work for 8-bit characters. These items only work for 8-bit characters.
*/[[=* *[==]* */[[=* *[==]*
- An equivalence class. This means that characters are matched that - An equivalence class. This means that characters are matched that
have almost the same meaning, e.g., when ignoring accents. The form have almost the same meaning, e.g., when ignoring accents. This
is: only works for Unicode, latin1 and latin9. The form is:
[=a=] [=a=]
Currently this is only implemented for latin1. Also works for the
latin1 characters in utf-8 and latin9.
*/[[.* *[..]* */[[.* *[..]*
- A collation element. This currently simply accepts a single - A collation element. This currently simply accepts a single
character in the form: character in the form:

View File

@ -1,11 +1,11 @@
*pi_getscript.txt* For Vim version 7.3. Last change: 2009 Oct 14 *pi_getscript.txt* For Vim version 7.0. Last change: 2011 May 31
> >
GETSCRIPT REFERENCE MANUAL by Charles E. Campbell, Jr. GETSCRIPT REFERENCE MANUAL by Charles E. Campbell, Jr.
< <
Authors: Charles E. Campbell, Jr. <NdrOchip@ScampbellPfamilyA.Mbiz> Authors: Charles E. Campbell, Jr. <NdrOchip@ScampbellPfamilyA.Mbiz>
(remove NOSPAM from the email address) (remove NOSPAM from the email address)
*GetLatestVimScripts-copyright* *GetLatestVimScripts-copyright*
Copyright: (c) 2004-2009 by Charles E. Campbell, Jr. *glvs-copyright* Copyright: (c) 2004-2010 by Charles E. Campbell, Jr. *glvs-copyright*
The VIM LICENSE applies to getscript.vim and The VIM LICENSE applies to getscript.vim and
pi_getscript.txt (see |copyright|) except use pi_getscript.txt (see |copyright|) except use
"getscript" instead of "Vim". No warranty, express or implied. "getscript" instead of "Vim". No warranty, express or implied.
@ -77,7 +77,9 @@ Your computer needs to have wget or curl for GetLatestVimScripts to do its work.
3. GetLatestVimScripts Usage *glvs-usage* *:GLVS* 3. GetLatestVimScripts Usage *glvs-usage* *:GLVS*
Unless it has been defined elsewhere, > Unless it has been defined elsewhere, >
:GLVS :GLVS
will invoke GetLatestVimScripts(). If some other plugin has defined that will invoke GetLatestVimScripts(). If some other plugin has defined that
command, then you may type command, then you may type
> >
@ -127,7 +129,8 @@ click on the script's link, you'll see a line resembling
http://vim.sourceforge.net/scripts/script.php?script_id=40 http://vim.sourceforge.net/scripts/script.php?script_id=40
The "40" happens to be a ScriptID that GetLatestVimScripts needs to The "40" happens to be a ScriptID that GetLatestVimScripts needs to
download the associated page. download the associated page, and is assigned by vim.sf.net itself
during initial uploading of the plugin.
The second number on each line gives the script's SourceID. The SourceID The second number on each line gives the script's SourceID. The SourceID
records the count of uploaded scripts as determined by vim.sf.net; hence it records the count of uploaded scripts as determined by vim.sf.net; hence it
@ -151,19 +154,39 @@ This comment line tells getscript.vim to check vimscript #884 and that the
script is automatically installable. Getscript will also use this line to script is automatically installable. Getscript will also use this line to
help build the GetLatestVimScripts.dat file, by including a line such as: > help build the GetLatestVimScripts.dat file, by including a line such as: >
884 1 AutoAlign.vim 884 1 :AutoInstall: AutoAlign.vim
< <
in it an AutoAlign.vim line isn't already in GetLatestVimScripts.dat file. assuming that such a line isn't already in GetLatestVimScripts.dat file.
See |glvs-plugins| for more. Thus, GetLatestVimScripts thus provides a See |glvs-plugins| for more. Thus, GetLatestVimScripts thus provides a
comprehensive ability to keep your plugins up-to-date! comprehensive ability to keep your plugins up-to-date!
In summary:
* Optionally tell getscript that it is allowed to build/append a
GetLatestVimScripts.dat file based upon already installed plugins: >
let g:GetLatestVimScripts_allowautoinstall=1
<
* A line such as >
" GetLatestVimScripts: 884 1 :AutoInstall: AutoAlign.vim
< in an already-downloaded plugin constitutes the concurrence of the
plugin author that getscript may do AutoInstall. Not all plugins
may be AutoInstall-able, and the plugin's author is best situated
to know whether or not his/her plugin will AutoInstall properly.
* A line such as >
884 1 :AutoInstall: AutoAlign.vim
< in your GetLatestVimScripts.dat file constitutes your permission
to getscript to do AutoInstall. AutoInstall requires both your
and the plugin author's permission. See |GetLatestVimScripts_dat|.
*GetLatestVimScripts_dat* *GetLatestVimScripts_dat*
As an example of a <GetLatestVimScripts.dat> file: As an example of a <GetLatestVimScripts.dat> file:
> >
ScriptID SourceID Filename ScriptID SourceID Filename
-------------------------- --------------------------
294 1 Align.vim 294 1 :AutoInstall: Align.vim
120 2 decho.vim 120 2 Decho.vim
40 3 DrawIt.tar.gz 40 3 DrawIt.tar.gz
451 4 EasyAccents.vim 451 4 EasyAccents.vim
195 5 engspchk.vim 195 5 engspchk.vim
@ -201,8 +224,8 @@ are, then you may include :AutoInstall: just before "yourscriptname":
^ ^
scriptid scriptid
< <
NOTE: :AutoInstall: is a plugin-author option, not a GetLatestVimScripts.dat~ NOTE: The :AutoInstall: feature requires both the plugin author's and~
entry!~ the user's permission to operate!~
GetLatestVimScripts commands for those scripts are then appended, if not GetLatestVimScripts commands for those scripts are then appended, if not
already present, to the user's GetLatest/GetLatestVimScripts.dat file. It is already present, to the user's GetLatest/GetLatestVimScripts.dat file. It is
@ -210,7 +233,7 @@ a relatively painless way to automate the acquisition of any scripts your
plugins depend upon. plugins depend upon.
Now, as an author, you probably don't want GetLatestVimScripts to download Now, as an author, you probably don't want GetLatestVimScripts to download
your own scripts for you yourself, thereby overwriting your not-yet-released your own scripts atop your own copy, thereby overwriting your not-yet-released
hard work. GetLatestVimScripts provides a solution for this: put hard work. GetLatestVimScripts provides a solution for this: put
> >
0 0 yourscriptname 0 0 yourscriptname
@ -351,6 +374,9 @@ The AutoInstall process will:
============================================================================== ==============================================================================
9. GetLatestVimScripts History *getscript-history* *glvs-hist* {{{1 9. GetLatestVimScripts History *getscript-history* *glvs-hist* {{{1
v33 May 31, 2011 : * using fnameescape() instead of escape()
* *.xz support
v32 Jun 19, 2010 : * (Jan Steffens) added support for xz compression
v31 Jun 29, 2008 : * (Bill McCarthy) fixed having hls enabled with getscript v31 Jun 29, 2008 : * (Bill McCarthy) fixed having hls enabled with getscript
* (David Schaefer) the acd option interferes with vimballs * (David Schaefer) the acd option interferes with vimballs
Solution: bypass the acd option Solution: bypass the acd option

View File

@ -1,4 +1,4 @@
*pi_netrw.txt* For Vim version 7.3. Last change: 2011 Apr 01 *pi_netrw.txt* For Vim version 7.3. Last change: 2011 May 31
----------------------------------------------------- -----------------------------------------------------
NETRW REFERENCE MANUAL by Charles E. Campbell, Jr. NETRW REFERENCE MANUAL by Charles E. Campbell, Jr.
@ -273,7 +273,7 @@ SOURCING *netrw-source* {{{2
:Nsource "scp://[user@]machine[[:#]port]/path" uses scp :Nsource "scp://[user@]machine[[:#]port]/path" uses scp
:Nsource "sftp://[user@]machine/path" uses sftp :Nsource "sftp://[user@]machine/path" uses sftp
DIRECTORY LISTING *netrw-dirlist* {{{2 DIRECTORY LISTING *netrw-trailingslash* *netrw-dirlist* {{{2
One may browse a directory to get a listing by simply attempting to One may browse a directory to get a listing by simply attempting to
edit the directory: > edit the directory: >
@ -281,14 +281,15 @@ DIRECTORY LISTING *netrw-dirlist* {{{2
:e scp://[user]@hostname/path/ :e scp://[user]@hostname/path/
:e ftp://[user]@hostname/path/ :e ftp://[user]@hostname/path/
< <
For remote directories (ie. those using scp or ftp), that trailing For remote directory listings (ie. those using scp or ftp), that
"/" is necessary (the slash tells netrw to treat the argument as a trailing "/" is necessary (the slash tells netrw to treat the argument
directory to browse instead of a file to download). as a directory to browse instead of as a file to download).
However, the Nread command can also be used to accomplish this: The Nread command may also be used to accomplish this (again, that
trailing slash is necessary): >
:Nread [protocol]://[user]@hostname/path/
:Nread [protocol]://[user]@hostname/path/
<
*netrw-login* *netrw-password* *netrw-login* *netrw-password*
CHANGING USERID AND PASSWORD *netrw-chgup* *netrw-userpass* {{{2 CHANGING USERID AND PASSWORD *netrw-chgup* *netrw-userpass* {{{2
@ -2158,8 +2159,8 @@ your browsing preferences. (see also: |netrw-settings|)
*g:netrw_mkdir_cmd* command for making a remote directory *g:netrw_mkdir_cmd* command for making a remote directory
default: "ssh USEPORT HOSTNAME mkdir" default: "ssh USEPORT HOSTNAME mkdir"
*g:netrw_mousemaps* =1 (default) enables the mouse buttons *g:netrw_mousemaps* =1 (default) enables mouse buttons while
while browsing: browsing to:
leftmouse : open file/directory leftmouse : open file/directory
shift-leftmouse : mark file shift-leftmouse : mark file
middlemouse : same as P middlemouse : same as P
@ -2274,8 +2275,11 @@ your browsing preferences. (see also: |netrw-settings|)
*g:netrw_winsize* specify initial size of new windows made with *g:netrw_winsize* specify initial size of new windows made with
"o" (see |netrw-o|), "v" (see |netrw-v|), "o" (see |netrw-o|), "v" (see |netrw-v|),
|:Hexplore| or |:Vexplore|. |:Hexplore| or |:Vexplore|. The g:netrw_winsize
default: "" is an integer describing the percentage of the
current netrw buffer's window to be used for
the new window.
default: 50 (for 50%)
*g:netrw_xstrlen* Controls how netrw computes string lengths, *g:netrw_xstrlen* Controls how netrw computes string lengths,
including multi-byte characters' string including multi-byte characters' string
@ -2660,7 +2664,7 @@ Associated setting variables: |g:netrw_chgwin|
*netrw-p11* *netrw-p11*
P11. I want to have two windows; a thin one on the left and my editing P11. I want to have two windows; a thin one on the left and my editing
window on the right. How can I do this? window on the right. How may I accomplish this?
* Put the following line in your <.vimrc>: * Put the following line in your <.vimrc>:
let g:netrw_altv = 1 let g:netrw_altv = 1
@ -2706,7 +2710,45 @@ Associated setting variables: |g:netrw_chgwin|
"let g:netrw_sftp_cmd = "d:\\dev\\putty\\PSFTP.exe" "let g:netrw_sftp_cmd = "d:\\dev\\putty\\PSFTP.exe"
"let g:netrw_scp_cmd = "d:\\dev\\putty\\PSCP.exe" "let g:netrw_scp_cmd = "d:\\dev\\putty\\PSCP.exe"
< <
*netrw-p14*
P14. I'd would like to speed up writes using Nwrite and scp/ssh
style connections. How? (Thomer M. Gil)
Try using ssh's ControlMaster and ControlPath (see the ssh_config
man page) to share multiple ssh connections over a single network
connection. That cuts out the cryptographic handshake on each
file write, sometimes speeding it up by an order of magnitude.
(see http://thomer.com/howtos/netrw_ssh.html)
(included by permission)
Add the following to your ~/.ssh/config: >
# you change "*" to the hostname you care about
Host *
ControlMaster auto
ControlPath /tmp/%r@%h:%p
< Then create an ssh connection to the host and leave it running: >
ssh -N host.domain.com
< Now remotely open a file with Vim's Netrw and enjoy the
zippiness: >
vim scp://host.domain.com//home/user/.bashrc
<
*netrw-p15*
P15. How may I use a double-click instead of netrw's usual single click
to open a file or directory? (Ben Fritz)
First, disable netrw's mapping with >
let g:netrw_mousemaps= 0
< and then create a netrw buffer only mapping in
$HOME/.vim/after/ftplugin/netrw.vim: >
nmap <buffer> <2-leftmouse> <CR>
< Note that setting g:netrw_mousemaps to zero will turn off
all netrw's mouse mappings, not just the <leftmouse> one.
(see |g:netrw_mousemaps|)
============================================================================== ==============================================================================
11. Debugging Netrw Itself *netrw-debug* {{{1 11. Debugging Netrw Itself *netrw-debug* {{{1
@ -2762,6 +2804,15 @@ which is loaded automatically at startup (assuming :set nocp).
============================================================================== ==============================================================================
12. History *netrw-history* {{{1 12. History *netrw-history* {{{1
v142: Apr 06, 2011 * I modified NetrwRemoteListing() to use
shellescape(fnameescape(s:path),1) for
the benefit of those using scp://.../
with subdirectories having spaces.
Problem reported by: Gilles Charron
Apr 18, 2011 * s:NetrwMethod() attempts to issue an
error message when given a malformed url
Apr 29, 2011 * converted most mousemaps to use <Plug>s
* |g:netrw_winsize|'s meaning changed
v141: Aug 28, 2010 * added -s:... support for Windows ftp v141: Aug 28, 2010 * added -s:... support for Windows ftp
* restored 2-leftmouse for :Rex-like return * restored 2-leftmouse for :Rex-like return
* added balloon help for banner * added balloon help for banner
@ -2772,6 +2823,9 @@ which is loaded automatically at startup (assuming :set nocp).
Avoids "... is a directory" message, works Avoids "... is a directory" message, works
inside a try-catch-endtry clause. inside a try-catch-endtry clause.
Feb 22, 2011 * for menus, &go =~# used to insure correct case Feb 22, 2011 * for menus, &go =~# used to insure correct case
Apr 01, 2011 * changed g:netrw_cursorcolumn to g:netrw_cursor
In addition, there's more supported settings for
it.
v140: Jul 27, 2010 * (Lech Lorens) unexpected change of window v140: Jul 27, 2010 * (Lech Lorens) unexpected change of window
v139: May 14, 2010 * when viewing remote directory listings and v139: May 14, 2010 * when viewing remote directory listings and
changing listing style, going to tree listing changing listing style, going to tree listing

View File

@ -1,4 +1,4 @@
*pi_tar.txt* For Vim version 7.3. Last change: 2010 Nov 03 *pi_tar.txt* For Vim version 7.3. Last change: 2011 May 31
+====================+ +====================+
| Tar File Interface | | Tar File Interface |
@ -60,11 +60,11 @@ Copyright 2005-2010: The GPL (gnu public license) applies to *tar-copyright*
<.vimrc> file. <.vimrc> file.
Default Default
Variable Value Explanation Variable Value Explanation
*g:tar_browseoptions* "Ptf" used to get a list of contents *g:tar_browseoptions* "Ptf" used to get a list of contents
*g:tar_readoptions* "OPxf" used to extract a file from a tarball *g:tar_readoptions* "OPxf" used to extract a file from a tarball
*g:tar_cmd* "tar" the name of the tar program *g:tar_cmd* "tar" the name of the tar program
*g:tar_nomax* 0 if true, file window will not be maximized *g:tar_nomax* 0 if true, file window will not be maximized
*g:tar_secure* undef if exists: *g:tar_secure* undef if exists:
"--"s will be used to prevent unwanted "--"s will be used to prevent unwanted
option expansion in tar commands. option expansion in tar commands.
Please be sure that your tar command Please be sure that your tar command
@ -76,15 +76,19 @@ Copyright 2005-2010: The GPL (gnu public license) applies to *tar-copyright*
"-" "-"
Not all tar's support the "--" which is why Not all tar's support the "--" which is why
it isn't default. it isn't default.
*g:tar_writeoptions* "uf" used to update/replace a file *g:tar_writeoptions* "uf" used to update/replace a file
============================================================================== ==============================================================================
4. History *tar-history* 4. History *tar-history*
v27 May 31, 2011 * moved cygwin detection before g:tar_copycmd handling
* inserted additional |:keepj| modifiers
* changed silent to sil! (|:silent|)
v26 Aug 09, 2010 * uses buffer-local instead of window variables to hold v26 Aug 09, 2010 * uses buffer-local instead of window variables to hold
tarfile name tarfile name
* inserted keepj before 0d to protect jump list
v25 Jun 19, 2010 * (Jan Steffens) added support for xz compression v25 Jun 19, 2010 * (Jan Steffens) added support for xz compression
v24 Apr 07, 2009 * :Untarvim command implemented v24 Apr 07, 2009 * :Untarvim command implemented
Sep 28, 2009 * Added lzma support Sep 28, 2009 * Added lzma support

View File

@ -1,4 +1,4 @@
*pi_vimball.txt* For Vim version 7.3. Last change: 2010 Apr 12 *pi_vimball.txt* For Vim version 7.3. Last change: 2011 Aug 14
---------------- ----------------
Vimball Archiver Vimball Archiver
@ -6,7 +6,7 @@
Author: Charles E. Campbell, Jr. <NdrOchip@ScampbellPfamily.AbizM> Author: Charles E. Campbell, Jr. <NdrOchip@ScampbellPfamily.AbizM>
(remove NOSPAM from Campbell's email first) (remove NOSPAM from Campbell's email first)
Copyright: (c) 2004-2009 by Charles E. Campbell, Jr. *Vimball-copyright* Copyright: (c) 2004-2011 by Charles E. Campbell, Jr. *Vimball-copyright*
The VIM LICENSE applies to Vimball.vim, and Vimball.txt The VIM LICENSE applies to Vimball.vim, and Vimball.txt
(see |copyright|) except use "Vimball" instead of "Vim". (see |copyright|) except use "Vimball" instead of "Vim".
No warranty, express or implied. No warranty, express or implied.
@ -16,6 +16,7 @@ Copyright: (c) 2004-2009 by Charles E. Campbell, Jr. *Vimball-copyright*
1. Contents *vba* *vimball* *vimball-contents* 1. Contents *vba* *vimball* *vimball-contents*
1. Contents......................................: |vimball-contents| 1. Contents......................................: |vimball-contents|
2. Vimball Introduction..........................: |vimball-intro|
3. Vimball Manual................................: |vimball-manual| 3. Vimball Manual................................: |vimball-manual|
MkVimball.....................................: |:MkVimball| MkVimball.....................................: |:MkVimball|
UseVimball....................................: |:UseVimball| UseVimball....................................: |:UseVimball|
@ -176,6 +177,22 @@ WINDOWS *vimball-windows*
============================================================================== ==============================================================================
4. Vimball History *vimball-history* {{{1 4. Vimball History *vimball-history* {{{1
33 : Apr 02, 2011 * Gave priority to *.vmb over *.vba
* Changed silent! to sil! (shorter)
* Safed |'swf'| setting (during vimball extraction,
its now turned off)
32 : May 19, 2010 * (Christian Brabrandt) :so someplugin.vba and
:so someplugin.vba.gz (and the other supported
compression types) now works
* (Jan Steffens) added support for xz compression
* fenc extraction was erroneously picking up the
end of the line number when no file encoding
was present. Fixed.
* By request, beginning the switchover from the vba
extension to vmb. Currently both are supported;
MkVimball, however, now will create *.vmb files.
Feb 11, 2011 * motoyakurotsu reported an error with vimball's
handling of zero-length files
30 : Dec 08, 2008 * fnameescape() inserted to protect error 30 : Dec 08, 2008 * fnameescape() inserted to protect error
messaging using corrupted filenames from messaging using corrupted filenames from
causing problems causing problems
@ -199,6 +216,8 @@ WINDOWS *vimball-windows*
causing problems as reported by Zhang Shuhan causing problems as reported by Zhang Shuhan
24 : Nov 15, 2007 * g:vimball_path_escape used by s:Path() to 24 : Nov 15, 2007 * g:vimball_path_escape used by s:Path() to
prevent certain characters from causing trouble prevent certain characters from causing trouble
(defunct: |fnameescape()| and |shellescape()|
now used instead)
22 : Mar 21, 2007 * uses setlocal instead of set during BufEnter 22 : Mar 21, 2007 * uses setlocal instead of set during BufEnter
21 : Nov 27, 2006 * (tnx to Bill McCarthy) vimball had a header 21 : Nov 27, 2006 * (tnx to Bill McCarthy) vimball had a header
handling problem and it now changes \s to /s handling problem and it now changes \s to /s

View File

@ -1,4 +1,4 @@
*pi_zip.txt* For Vim version 7.3. Last change: 2010 Sep 14 *pi_zip.txt* For Vim version 7.3. Last change: 2011 Aug 14
+====================+ +====================+
| Zip File Interface | | Zip File Interface |
@ -6,7 +6,7 @@
Author: Charles E. Campbell, Jr. <NdrOchip@ScampbellPfamily.AbizM> Author: Charles E. Campbell, Jr. <NdrOchip@ScampbellPfamily.AbizM>
(remove NOSPAM from Campbell's email first) (remove NOSPAM from Campbell's email first)
Copyright: Copyright (C) 2005-2009 Charles E Campbell, Jr *zip-copyright* Copyright: Copyright (C) 2005-2011 Charles E Campbell, Jr *zip-copyright*
Permission is hereby granted to use and distribute this code, Permission is hereby granted to use and distribute this code,
with or without modifications, provided that this copyright with or without modifications, provided that this copyright
notice is copied with it. Like anything else that's free, notice is copied with it. Like anything else that's free,
@ -17,14 +17,14 @@ Copyright: Copyright (C) 2005-2009 Charles E Campbell, Jr *zip-copyright*
the use of this software. the use of this software.
============================================================================== ==============================================================================
1. Contents *zip* *zip-contents* 1. Contents *zip* *zip-contents*
1. Contents................................................|zip-contents| 1. Contents................................................|zip-contents|
2. Usage...................................................|zip-usage| 2. Usage...................................................|zip-usage|
3. Additional Extensions...................................|zip-extension| 3. Additional Extensions...................................|zip-extension|
4. History.................................................|zip-history| 4. History.................................................|zip-history|
============================================================================== ==============================================================================
2. Usage *zip-usage* *zip-manual* 2. Usage *zip-usage* *zip-manual*
When one edits a *.zip file, this plugin will handle displaying a When one edits a *.zip file, this plugin will handle displaying a
contents page. Select a file to edit by moving the cursor atop contents page. Select a file to edit by moving the cursor atop
@ -83,7 +83,11 @@ Copyright: Copyright (C) 2005-2009 Charles E Campbell, Jr *zip-copyright*
should be treated as zip files. should be treated as zip files.
============================================================================== ==============================================================================
4. History *zip-history* {{{1 4. History *zip-history* {{{1
v24 Jun 21, 2010 * (Cédric Bosdonnat) unzip seems to need its filenames
fnameescape'd as well as shellquote'd
* (Motoya Kurotsu) inserted keepj before 0d to protect
jump list
v17 May 09, 2008 * arno caught a security bug v17 May 09, 2008 * arno caught a security bug
v15 Sep 07, 2007 * &shq now used if not the empty string for g:zip_shq v15 Sep 07, 2007 * &shq now used if not the empty string for g:zip_shq
v14 May 07, 2007 * using b:zipfile instead of w:zipfile to avoid problem v14 May 07, 2007 * using b:zipfile instead of w:zipfile to avoid problem

View File

@ -1,4 +1,4 @@
*quickfix.txt* For Vim version 7.3. Last change: 2011 Feb 01 *quickfix.txt* For Vim version 7.3. Last change: 2011 May 10
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -215,28 +215,29 @@ command with 'l'.
*:cex* *:cexpr* *E777* *:cex* *:cexpr* *E777*
:cex[pr][!] {expr} Create a quickfix list using the result of {expr} and :cex[pr][!] {expr} Create a quickfix list using the result of {expr} and
jump to the first error. If {expr} is a String, then jump to the first error.
each new-line terminated line in the String is If {expr} is a String, then each new-line terminated
processed using 'errorformat' and the result is added line in the String is processed using the global value
to the quickfix list. If {expr} is a List, then each of 'errorformat' and the result is added to the
String item in the list is processed and added to the quickfix list.
quickfix list. Non String items in the List are If {expr} is a List, then each String item in the list
ignored. See |:cc| is processed and added to the quickfix list. Non
for [!]. String items in the List are ignored.
See |:cc| for [!].
Examples: > Examples: >
:cexpr system('grep -n xyz *') :cexpr system('grep -n xyz *')
:cexpr getline(1, '$') :cexpr getline(1, '$')
< <
*:lex* *:lexpr* *:lex* *:lexpr*
:lex[pr][!] {expr} Same as ":cexpr", except the location list for the :lex[pr][!] {expr} Same as |:cexpr|, except the location list for the
current window is used instead of the quickfix list. current window is used instead of the quickfix list.
*:cgete* *:cgetexpr* *:cgete* *:cgetexpr*
:cgete[xpr] {expr} Create a quickfix list using the result of {expr}. :cgete[xpr] {expr} Create a quickfix list using the result of {expr}.
Just like ":cexpr", but don't jump to the first error. Just like |:cexpr|, but don't jump to the first error.
*:lgete* *:lgetexpr* *:lgete* *:lgetexpr*
:lgete[xpr] {expr} Same as ":cgetexpr", except the location list for the :lgete[xpr] {expr} Same as |:cgetexpr|, except the location list for the
current window is used instead of the quickfix list. current window is used instead of the quickfix list.
*:cad* *:caddexpr* *:cad* *:caddexpr*

View File

@ -1,4 +1,4 @@
*quickref.txt* For Vim version 7.3. Last change: 2010 Dec 02 *quickref.txt* For Vim version 7.3. Last change: 2011 Jun 12
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -657,6 +657,7 @@ Short explanation of each option: *option-list*
'cscopepathcomp' 'cspc' how many components of the path to show 'cscopepathcomp' 'cspc' how many components of the path to show
'cscopeprg' 'csprg' command to execute cscope 'cscopeprg' 'csprg' command to execute cscope
'cscopequickfix' 'csqf' use quickfix window for cscope results 'cscopequickfix' 'csqf' use quickfix window for cscope results
'cscoperelative' 'csre' Use cscope.out path basename as prefix
'cscopetag' 'cst' use cscope for tag commands 'cscopetag' 'cst' use cscope for tag commands
'cscopetagorder' 'csto' determines ":cstag" search order 'cscopetagorder' 'csto' determines ":cstag" search order
'cscopeverbose' 'csverb' give messages when adding a cscope database 'cscopeverbose' 'csverb' give messages when adding a cscope database
@ -800,7 +801,7 @@ Short explanation of each option: *option-list*
'omnifunc' 'ofu' function for filetype-specific completion 'omnifunc' 'ofu' function for filetype-specific completion
'opendevice' 'odev' allow reading/writing devices on MS-Windows 'opendevice' 'odev' allow reading/writing devices on MS-Windows
'operatorfunc' 'opfunc' function to be called for |g@| operator 'operatorfunc' 'opfunc' function to be called for |g@| operator
'osfiletype' 'oft' operating system-specific filetype information 'osfiletype' 'oft' no longer supported
'paragraphs' 'para' nroff macros that separate paragraphs 'paragraphs' 'para' nroff macros that separate paragraphs
'paste' allow pasting text 'paste' allow pasting text
'pastetoggle' 'pt' key code that causes 'paste' to toggle 'pastetoggle' 'pt' key code that causes 'paste' to toggle

View File

@ -1,4 +1,4 @@
*spell.txt* For Vim version 7.3. Last change: 2011 Feb 01 *spell.txt* For Vim version 7.3. Last change: 2011 May 25
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -1244,6 +1244,7 @@ one or more groups, where each group can be:
Optionally this may be followed by: Optionally this may be followed by:
* the group appears zero or more times, e.g., sm*e * the group appears zero or more times, e.g., sm*e
+ the group appears one or more times, e.g., c+ + the group appears one or more times, e.g., c+
? the group appears zero times or once, e.g., x?
This is similar to the regexp pattern syntax (but not the same!). A few This is similar to the regexp pattern syntax (but not the same!). A few
examples with the sequence of word flags they require: examples with the sequence of word flags they require:
@ -1251,6 +1252,7 @@ examples with the sequence of word flags they require:
COMPOUNDRULE yz yz COMPOUNDRULE yz yz
COMPOUNDRULE x+z xz xxz xxxz etc. COMPOUNDRULE x+z xz xxz xxxz etc.
COMPOUNDRULE yx+ yx yxx yxxx etc. COMPOUNDRULE yx+ yx yxx yxxx etc.
COMPOUNDRULE xy?z xz xyz
COMPOUNDRULE [abc]z az bz cz COMPOUNDRULE [abc]z az bz cz
COMPOUNDRULE [abc]+z az aaz abaz bz baz bcbz cz caz cbaz etc. COMPOUNDRULE [abc]+z az aaz abaz bz baz bcbz cz caz cbaz etc.

View File

@ -1,4 +1,4 @@
*starting.txt* For Vim version 7.3. Last change: 2010 Sep 18 *starting.txt* For Vim version 7.3. Last change: 2011 Jul 22
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -424,12 +424,7 @@ a slash. Thus "-R" means recovery and "-/R" readonly.
"-d con:30/10/600/150". But you can also use it to start "-d con:30/10/600/150". But you can also use it to start
editing on another device, e.g., AUX:. {not in Vi} editing on another device, e.g., AUX:. {not in Vi}
*-f* *-f*
-f Amiga: Do not restart Vim to open a new window. This -f GUI: Do not disconnect from the program that started Vim.
option should be used when Vim is started by a program that
will wait for the edit session to finish (e.g., mail or
readnews). See |amiga-window|.
GUI: Do not disconnect from the program that started Vim.
'f' stands for "foreground". If omitted, the GUI forks a new 'f' stands for "foreground". If omitted, the GUI forks a new
process and exits the current one. "-f" should be used when process and exits the current one. "-f" should be used when
gvim is started by a program that will wait for the edit gvim is started by a program that will wait for the edit
@ -437,8 +432,14 @@ a slash. Thus "-R" means recovery and "-/R" readonly.
never to fork, include 'f' in 'guioptions' in your |gvimrc|. never to fork, include 'f' in 'guioptions' in your |gvimrc|.
Careful: You can use "-gf" to start the GUI in the foreground, Careful: You can use "-gf" to start the GUI in the foreground,
but "-fg" is used to specify the foreground color. |gui-fork| but "-fg" is used to specify the foreground color. |gui-fork|
Amiga: Do not restart Vim to open a new window. This
option should be used when Vim is started by a program that
will wait for the edit session to finish (e.g., mail or
readnews). See |amiga-window|.
{not in Vi} {not in Vi}
*--nofork* *--nofork*
--nofork GUI: Do not fork. Same as |-f|. --nofork GUI: Do not fork. Same as |-f|.
*-u* *E282* *-u* *E282*

View File

@ -1,4 +1,4 @@
*syntax.txt* For Vim version 7.3. Last change: 2011 Apr 01 *syntax.txt* For Vim version 7.3. Last change: 2011 Jul 18
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -468,18 +468,28 @@ disabled javascript to view closed folds. To use this option, use: >
Setting html_no_foldcolumn with html_dynamic_folds will automatically set Setting html_no_foldcolumn with html_dynamic_folds will automatically set
html_hover_unfold, because otherwise the folds wouldn't be dynamic. html_hover_unfold, because otherwise the folds wouldn't be dynamic.
By default "<pre>" and "</pre>" is used around the text. This makes it show By default "<pre>" and "</pre>" are used around the text. When 'wrap' is set
up as you see it in Vim, but without wrapping. If you prefer wrapping, at the in the window being converted, the CSS 2.0 "white-space:pre-wrap" value is
risk of making some things look a bit different, use: > used to wrap the text. You can explicitly enable the wrapping with: >
:let g:html_pre_wrap = 1
or disable with >
:let g:html_pre_wrap = 0
This generates HTML that looks very close to the Vim window, but unfortunately
there can be minor differences such as the lack of a 'showbreak' option in in
the HTML, or where line breaks can occur.
Another way to obtain text wrapping in the HTML, at the risk of making some
things look even more different, is to use: >
:let g:html_no_pre = 1 :let g:html_no_pre = 1
This will use <br> at the end of each line and use "&nbsp;" for repeated This will use <br> at the end of each line and use "&nbsp;" for repeated
spaces. spaces. Doing it this way is more compatible with old browsers, but modern
browsers support the "white-space" method.
If you do use the "<pre>" tags, <Tab> characters in the text are included in If you do stick with the default "<pre>" tags, <Tab> characters in the text
the generated output if they will have no effect on the appearance of the are included in the generated output if they will have no effect on the
text and it looks like they are in the document intentionally. This allows for appearance of the text and it looks like they are in the document
the HTML output to be copied and pasted from a browser without losing the intentionally. This allows for the HTML output to be copied and pasted from a
actual whitespace used in the document. browser without losing the actual whitespace used in the document.
Specifically, <Tab> characters will be included if the 'tabstop' option is set Specifically, <Tab> characters will be included if the 'tabstop' option is set
to the default of 8, 'expandtab' is not set, and if neither the foldcolumn nor to the default of 8, 'expandtab' is not set, and if neither the foldcolumn nor
@ -502,13 +512,14 @@ inserted lines as with the side-by-side diff, use: >
:let g:html_whole_filler = 1 :let g:html_whole_filler = 1
And to go back to displaying up to three lines again: > And to go back to displaying up to three lines again: >
:unlet g:html_whole_filler :unlet g:html_whole_filler
<
TOhtml uses the current value of 'fileencoding' if set, or 'encoding' if not, For most buffers, TOhtml uses the current value of 'fileencoding' if set, or
to determine the charset and 'fileencoding' of the HTML file. In general, this 'encoding' if not, to determine the charset and 'fileencoding' of the HTML
works for the encodings mentioned specifically by name in |encoding-names|, but file. 'encoding' is always used for certain 'buftype' values. In general, this
TOhtml will only automatically use those encodings which are widely supported. works for the encodings mentioned specifically by name in |encoding-names|,
However, you can override this to support specific encodings that may not be but TOhtml will only automatically use those encodings which are widely
automatically detected by default. supported. However, you can override this to support specific encodings that
may not be automatically detected by default.
To overrule all automatic charset detection, set g:html_use_encoding to the To overrule all automatic charset detection, set g:html_use_encoding to the
name of the charset to be used. TOhtml will try to determine the appropriate name of the charset to be used. TOhtml will try to determine the appropriate
@ -855,13 +866,13 @@ used.
Detecting whether a file is csh or tcsh is notoriously hard. Some systems Detecting whether a file is csh or tcsh is notoriously hard. Some systems
symlink /bin/csh to /bin/tcsh, making it almost impossible to distinguish symlink /bin/csh to /bin/tcsh, making it almost impossible to distinguish
between csh and tcsh. In case VIM guesses wrong you can set the between csh and tcsh. In case VIM guesses wrong you can set the
"filetype_csh" variable. For using csh: > "filetype_csh" variable. For using csh: *g:filetype_csh*
>
:let filetype_csh = "csh" :let g:filetype_csh = "csh"
For using tcsh: > For using tcsh: >
:let filetype_csh = "tcsh" :let g:filetype_csh = "tcsh"
Any script with a tcsh extension or a standard tcsh filename (.tcshrc, Any script with a tcsh extension or a standard tcsh filename (.tcshrc,
tcsh.tcshrc, tcsh.login) will have filetype tcsh. All other tcsh/csh scripts tcsh.tcshrc, tcsh.login) will have filetype tcsh. All other tcsh/csh scripts
@ -1091,6 +1102,8 @@ your .vimrc: >
FLEXWIKI *flexwiki.vim* *ft-flexwiki-syntax* FLEXWIKI *flexwiki.vim* *ft-flexwiki-syntax*
FlexWiki is an ASP.NET-based wiki package available at http://www.flexwiki.com FlexWiki is an ASP.NET-based wiki package available at http://www.flexwiki.com
NOTE: this site currently doesn't work, on Wikipedia is mentioned that
development stopped in 2009.
Syntax highlighting is available for the most common elements of FlexWiki Syntax highlighting is available for the most common elements of FlexWiki
syntax. The associated ftplugin script sets some buffer-local options to make syntax. The associated ftplugin script sets some buffer-local options to make
@ -2359,6 +2372,12 @@ This will make the syntax synchronization start 50 lines before the first
displayed line. The default value is 10. The disadvantage of using a larger displayed line. The default value is 10. The disadvantage of using a larger
number is that redrawing can become slow. number is that redrawing can become slow.
Vim tries to guess what type a ".r" file is. If it can't be detected (from
comment lines), the default is "r". To make the default rexx add this line to
your .vimrc: *g:filetype_r*
>
:let g:filetype_r = "r"
RUBY *ruby.vim* *ft-ruby-syntax* RUBY *ruby.vim* *ft-ruby-syntax*

View File

@ -154,12 +154,14 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
'cscopepathcomp' options.txt /*'cscopepathcomp'* 'cscopepathcomp' options.txt /*'cscopepathcomp'*
'cscopeprg' options.txt /*'cscopeprg'* 'cscopeprg' options.txt /*'cscopeprg'*
'cscopequickfix' options.txt /*'cscopequickfix'* 'cscopequickfix' options.txt /*'cscopequickfix'*
'cscoperelative' options.txt /*'cscoperelative'*
'cscopetag' options.txt /*'cscopetag'* 'cscopetag' options.txt /*'cscopetag'*
'cscopetagorder' options.txt /*'cscopetagorder'* 'cscopetagorder' options.txt /*'cscopetagorder'*
'cscopeverbose' options.txt /*'cscopeverbose'* 'cscopeverbose' options.txt /*'cscopeverbose'*
'cspc' options.txt /*'cspc'* 'cspc' options.txt /*'cspc'*
'csprg' options.txt /*'csprg'* 'csprg' options.txt /*'csprg'*
'csqf' options.txt /*'csqf'* 'csqf' options.txt /*'csqf'*
'csre' options.txt /*'csre'*
'cst' options.txt /*'cst'* 'cst' options.txt /*'cst'*
'csto' options.txt /*'csto'* 'csto' options.txt /*'csto'*
'csverb' options.txt /*'csverb'* 'csverb' options.txt /*'csverb'*
@ -1191,7 +1193,6 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
+mzscheme/dyn various.txt /*+mzscheme\/dyn* +mzscheme/dyn various.txt /*+mzscheme\/dyn*
+netbeans_intg various.txt /*+netbeans_intg* +netbeans_intg various.txt /*+netbeans_intg*
+ole various.txt /*+ole* +ole various.txt /*+ole*
+osfiletype various.txt /*+osfiletype*
+path_extra various.txt /*+path_extra* +path_extra various.txt /*+path_extra*
+perl various.txt /*+perl* +perl various.txt /*+perl*
+perl/dyn various.txt /*+perl\/dyn* +perl/dyn various.txt /*+perl\/dyn*
@ -3705,7 +3706,6 @@ E362 term.txt /*E362*
E363 options.txt /*E363* E363 options.txt /*E363*
E364 eval.txt /*E364* E364 eval.txt /*E364*
E365 print.txt /*E365* E365 print.txt /*E365*
E366 options.txt /*E366*
E367 autocmd.txt /*E367* E367 autocmd.txt /*E367*
E368 eval.txt /*E368* E368 eval.txt /*E368*
E369 pattern.txt /*E369* E369 pattern.txt /*E369*
@ -3970,8 +3970,6 @@ E607 eval.txt /*E607*
E608 eval.txt /*E608* E608 eval.txt /*E608*
E609 if_cscop.txt /*E609* E609 if_cscop.txt /*E609*
E61 pattern.txt /*E61* E61 pattern.txt /*E61*
E610 options.txt /*E610*
E611 options.txt /*E611*
E612 sign.txt /*E612* E612 sign.txt /*E612*
E613 print.txt /*E613* E613 print.txt /*E613*
E614 editing.txt /*E614* E614 editing.txt /*E614*
@ -4234,6 +4232,9 @@ E847 syntax.txt /*E847*
E848 syntax.txt /*E848* E848 syntax.txt /*E848*
E849 syntax.txt /*E849* E849 syntax.txt /*E849*
E85 options.txt /*E85* E85 options.txt /*E85*
E850 change.txt /*E850*
E851 gui_x11.txt /*E851*
E852 gui_x11.txt /*E852*
E86 windows.txt /*E86* E86 windows.txt /*E86*
E87 windows.txt /*E87* E87 windows.txt /*E87*
E88 windows.txt /*E88* E88 windows.txt /*E88*
@ -4303,6 +4304,7 @@ IME mbyte.txt /*IME*
Insert insert.txt /*Insert* Insert insert.txt /*Insert*
Insert-mode insert.txt /*Insert-mode* Insert-mode insert.txt /*Insert-mode*
InsertChange autocmd.txt /*InsertChange* InsertChange autocmd.txt /*InsertChange*
InsertCharPre autocmd.txt /*InsertCharPre*
InsertEnter autocmd.txt /*InsertEnter* InsertEnter autocmd.txt /*InsertEnter*
InsertLeave autocmd.txt /*InsertLeave* InsertLeave autocmd.txt /*InsertLeave*
J change.txt /*J* J change.txt /*J*
@ -4958,6 +4960,40 @@ charset-conversion mbyte.txt /*charset-conversion*
chill.vim syntax.txt /*chill.vim* chill.vim syntax.txt /*chill.vim*
cindent() eval.txt /*cindent()* cindent() eval.txt /*cindent()*
cinkeys-format indent.txt /*cinkeys-format* cinkeys-format indent.txt /*cinkeys-format*
cino-# indent.txt /*cino-#*
cino-( indent.txt /*cino-(*
cino-) indent.txt /*cino-)*
cino-+ indent.txt /*cino-+*
cino-/ indent.txt /*cino-\/*
cino-: indent.txt /*cino-:*
cino-= indent.txt /*cino-=*
cino-> indent.txt /*cino->*
cino-C indent.txt /*cino-C*
cino-J indent.txt /*cino-J*
cino-L indent.txt /*cino-L*
cino-M indent.txt /*cino-M*
cino-N indent.txt /*cino-N*
cino-U indent.txt /*cino-U*
cino-W indent.txt /*cino-W*
cino-^ indent.txt /*cino-^*
cino-b indent.txt /*cino-b*
cino-c indent.txt /*cino-c*
cino-e indent.txt /*cino-e*
cino-f indent.txt /*cino-f*
cino-g indent.txt /*cino-g*
cino-h indent.txt /*cino-h*
cino-i indent.txt /*cino-i*
cino-j indent.txt /*cino-j*
cino-l indent.txt /*cino-l*
cino-m indent.txt /*cino-m*
cino-n indent.txt /*cino-n*
cino-p indent.txt /*cino-p*
cino-star indent.txt /*cino-star*
cino-t indent.txt /*cino-t*
cino-u indent.txt /*cino-u*
cino-w indent.txt /*cino-w*
cino-{ indent.txt /*cino-{*
cino-} indent.txt /*cino-}*
cinoptions-values indent.txt /*cinoptions-values* cinoptions-values indent.txt /*cinoptions-values*
clear-undo undo.txt /*clear-undo* clear-undo undo.txt /*clear-undo*
clearmatches() eval.txt /*clearmatches()* clearmatches() eval.txt /*clearmatches()*
@ -5062,6 +5098,7 @@ cpo-+ options.txt /*cpo-+*
cpo-- options.txt /*cpo--* cpo-- options.txt /*cpo--*
cpo-. options.txt /*cpo-.* cpo-. options.txt /*cpo-.*
cpo-/ options.txt /*cpo-\/* cpo-/ options.txt /*cpo-\/*
cpo-; options.txt /*cpo-;*
cpo-< options.txt /*cpo-<* cpo-< options.txt /*cpo-<*
cpo-> options.txt /*cpo->* cpo-> options.txt /*cpo->*
cpo-A options.txt /*cpo-A* cpo-A options.txt /*cpo-A*
@ -5131,6 +5168,7 @@ cscope_connection() eval.txt /*cscope_connection()*
cscopepathcomp if_cscop.txt /*cscopepathcomp* cscopepathcomp if_cscop.txt /*cscopepathcomp*
cscopeprg if_cscop.txt /*cscopeprg* cscopeprg if_cscop.txt /*cscopeprg*
cscopequickfix if_cscop.txt /*cscopequickfix* cscopequickfix if_cscop.txt /*cscopequickfix*
cscoperelative if_cscop.txt /*cscoperelative*
cscopetag if_cscop.txt /*cscopetag* cscopetag if_cscop.txt /*cscopetag*
cscopetagorder if_cscop.txt /*cscopetagorder* cscopetagorder if_cscop.txt /*cscopetagorder*
cscopeverbose if_cscop.txt /*cscopeverbose* cscopeverbose if_cscop.txt /*cscopeverbose*
@ -5138,6 +5176,7 @@ csh.vim syntax.txt /*csh.vim*
cspc if_cscop.txt /*cspc* cspc if_cscop.txt /*cspc*
csprg if_cscop.txt /*csprg* csprg if_cscop.txt /*csprg*
csqf if_cscop.txt /*csqf* csqf if_cscop.txt /*csqf*
csre if_cscop.txt /*csre*
cst if_cscop.txt /*cst* cst if_cscop.txt /*cst*
csto if_cscop.txt /*csto* csto if_cscop.txt /*csto*
csverb if_cscop.txt /*csverb* csverb if_cscop.txt /*csverb*
@ -5415,6 +5454,11 @@ expr-env eval.txt /*expr-env*
expr-env-expand eval.txt /*expr-env-expand* expr-env-expand eval.txt /*expr-env-expand*
expr-function eval.txt /*expr-function* expr-function eval.txt /*expr-function*
expr-is eval.txt /*expr-is* expr-is eval.txt /*expr-is*
expr-is# eval.txt /*expr-is#*
expr-is? eval.txt /*expr-is?*
expr-isnot eval.txt /*expr-isnot*
expr-isnot# eval.txt /*expr-isnot#*
expr-isnot? eval.txt /*expr-isnot?*
expr-nesting eval.txt /*expr-nesting* expr-nesting eval.txt /*expr-nesting*
expr-number eval.txt /*expr-number* expr-number eval.txt /*expr-number*
expr-option eval.txt /*expr-option* expr-option eval.txt /*expr-option*
@ -5648,6 +5692,7 @@ ft-ptcap-syntax syntax.txt /*ft-ptcap-syntax*
ft-python-indent indent.txt /*ft-python-indent* ft-python-indent indent.txt /*ft-python-indent*
ft-python-syntax syntax.txt /*ft-python-syntax* ft-python-syntax syntax.txt /*ft-python-syntax*
ft-quake-syntax syntax.txt /*ft-quake-syntax* ft-quake-syntax syntax.txt /*ft-quake-syntax*
ft-r-indent indent.txt /*ft-r-indent*
ft-readline-syntax syntax.txt /*ft-readline-syntax* ft-readline-syntax syntax.txt /*ft-readline-syntax*
ft-rexx-syntax syntax.txt /*ft-rexx-syntax* ft-rexx-syntax syntax.txt /*ft-rexx-syntax*
ft-ruby-omni insert.txt /*ft-ruby-omni* ft-ruby-omni insert.txt /*ft-ruby-omni*
@ -5743,6 +5788,8 @@ g:decada.Error_Format ft_ada.txt /*g:decada.Error_Format*
g:decada.Make() ft_ada.txt /*g:decada.Make()* g:decada.Make() ft_ada.txt /*g:decada.Make()*
g:decada.Make_Command ft_ada.txt /*g:decada.Make_Command* g:decada.Make_Command ft_ada.txt /*g:decada.Make_Command*
g:decada.Unit_Name() ft_ada.txt /*g:decada.Unit_Name()* g:decada.Unit_Name() ft_ada.txt /*g:decada.Unit_Name()*
g:filetype_csh syntax.txt /*g:filetype_csh*
g:filetype_r syntax.txt /*g:filetype_r*
g:gnat ft_ada.txt /*g:gnat* g:gnat ft_ada.txt /*g:gnat*
g:gnat.Error_Format ft_ada.txt /*g:gnat.Error_Format* g:gnat.Error_Format ft_ada.txt /*g:gnat.Error_Format*
g:gnat.Find() ft_ada.txt /*g:gnat.Find()* g:gnat.Find() ft_ada.txt /*g:gnat.Find()*
@ -5978,6 +6025,7 @@ gtk-tooltip-colors gui_x11.txt /*gtk-tooltip-colors*
gu change.txt /*gu* gu change.txt /*gu*
gugu change.txt /*gugu* gugu change.txt /*gugu*
gui gui.txt /*gui* gui gui.txt /*gui*
gui-IME gui.txt /*gui-IME*
gui-clipboard gui_w32.txt /*gui-clipboard* gui-clipboard gui_w32.txt /*gui-clipboard*
gui-colors syntax.txt /*gui-colors* gui-colors syntax.txt /*gui-colors*
gui-extras gui.txt /*gui-extras* gui-extras gui.txt /*gui-extras*
@ -6057,6 +6105,7 @@ hangul hangulin.txt /*hangul*
hangulin.txt hangulin.txt /*hangulin.txt* hangulin.txt hangulin.txt /*hangulin.txt*
has() eval.txt /*has()* has() eval.txt /*has()*
has-patch eval.txt /*has-patch* has-patch eval.txt /*has-patch*
has-python if_pyth.txt /*has-python*
has_key() eval.txt /*has_key()* has_key() eval.txt /*has_key()*
haskell.vim syntax.txt /*haskell.vim* haskell.vim syntax.txt /*haskell.vim*
haslocaldir() eval.txt /*haslocaldir()* haslocaldir() eval.txt /*haslocaldir()*
@ -6185,6 +6234,7 @@ i) motion.txt /*i)*
i< motion.txt /*i<* i< motion.txt /*i<*
i> motion.txt /*i>* i> motion.txt /*i>*
iB motion.txt /*iB* iB motion.txt /*iB*
iBus gui.txt /*iBus*
iW motion.txt /*iW* iW motion.txt /*iW*
i[ motion.txt /*i[* i[ motion.txt /*i[*
i] motion.txt /*i]* i] motion.txt /*i]*
@ -6805,6 +6855,8 @@ netrw-p10 pi_netrw.txt /*netrw-p10*
netrw-p11 pi_netrw.txt /*netrw-p11* netrw-p11 pi_netrw.txt /*netrw-p11*
netrw-p12 pi_netrw.txt /*netrw-p12* netrw-p12 pi_netrw.txt /*netrw-p12*
netrw-p13 pi_netrw.txt /*netrw-p13* netrw-p13 pi_netrw.txt /*netrw-p13*
netrw-p14 pi_netrw.txt /*netrw-p14*
netrw-p15 pi_netrw.txt /*netrw-p15*
netrw-p2 pi_netrw.txt /*netrw-p2* netrw-p2 pi_netrw.txt /*netrw-p2*
netrw-p3 pi_netrw.txt /*netrw-p3* netrw-p3 pi_netrw.txt /*netrw-p3*
netrw-p4 pi_netrw.txt /*netrw-p4* netrw-p4 pi_netrw.txt /*netrw-p4*
@ -6853,6 +6905,7 @@ netrw-start pi_netrw.txt /*netrw-start*
netrw-t pi_netrw.txt /*netrw-t* netrw-t pi_netrw.txt /*netrw-t*
netrw-texplore pi_netrw.txt /*netrw-texplore* netrw-texplore pi_netrw.txt /*netrw-texplore*
netrw-todo pi_netrw.txt /*netrw-todo* netrw-todo pi_netrw.txt /*netrw-todo*
netrw-trailingslash pi_netrw.txt /*netrw-trailingslash*
netrw-transparent pi_netrw.txt /*netrw-transparent* netrw-transparent pi_netrw.txt /*netrw-transparent*
netrw-u pi_netrw.txt /*netrw-u* netrw-u pi_netrw.txt /*netrw-u*
netrw-updir pi_netrw.txt /*netrw-updir* netrw-updir pi_netrw.txt /*netrw-updir*
@ -7277,17 +7330,6 @@ right-justify change.txt /*right-justify*
rileft rileft.txt /*rileft* rileft rileft.txt /*rileft*
rileft.txt rileft.txt /*rileft.txt* rileft.txt rileft.txt /*rileft.txt*
riscos os_risc.txt /*riscos* riscos os_risc.txt /*riscos*
riscos-commandline os_risc.txt /*riscos-commandline*
riscos-filetypes os_risc.txt /*riscos-filetypes*
riscos-gui os_risc.txt /*riscos-gui*
riscos-interrupt os_risc.txt /*riscos-interrupt*
riscos-locations os_risc.txt /*riscos-locations*
riscos-memory os_risc.txt /*riscos-memory*
riscos-munging os_risc.txt /*riscos-munging*
riscos-porting os_risc.txt /*riscos-porting*
riscos-remote os_risc.txt /*riscos-remote*
riscos-shell os_risc.txt /*riscos-shell*
riscos-temp-files os_risc.txt /*riscos-temp-files*
rot13 change.txt /*rot13* rot13 change.txt /*rot13*
round() eval.txt /*round()* round() eval.txt /*round()*
rsync pi_netrw.txt /*rsync* rsync pi_netrw.txt /*rsync*

View File

@ -1,4 +1,4 @@
*todo.txt* For Vim version 7.3. Last change: 2011 Apr 01 *todo.txt* For Vim version 7.3. Last change: 2011 Sep 14
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -27,100 +27,85 @@ Priority classification:
See |develop.txt| for development plans. You can vote for which items should See |develop.txt| for development plans. You can vote for which items should
be worked on, but only if you sponsor Vim development. See |sponsor|. be worked on, but only if you sponsor Vim development. See |sponsor|.
Issues can also be entered online: http://code.google.com/p/vim/issues/list
Updates will be forwarded to the vim_dev maillist. Issues entered there will
not be repeated below, unless there is extra information.
*known-bugs* *known-bugs*
-------------------- Known bugs and current work ----------------------- -------------------- Known bugs and current work -----------------------
Improvement patch for filetype.vim. (Thilo Six, 2011 Mar 19) Patch to start GTK only after forking. (Tim Starling, 2011 Sep 12)
Patch to recognize more files as log files. (Mathieu Parent, 2011 Jan 14) Patch for Lua debug(). (Rob Hoelz, 2011 Sep 12)
Two patches for xxd. (Florian Zumbiehl, 2011 Jan 11) Go through more coverity reports.
Two updates for second one Jan 12.
Go through new coverity reports. Using "." to repeat a Visual delete counts bytes, not characters. Can this be
fixed? (Connor Lane Smith, 2011 Sep 1)
When 'colorcolumn' is set locally to a window, ":new" opens a window with the Patch to allow getchar() in expression mapping.
same highlighting but 'colorcolumn' is empty. (Tyru, 2010 Nov 15) Why was typeahead saved and restored? (James Vega, 2011 Aug 31)
Patch by Christian Brabandt, 2011 Feb 13 (but move further down).
Patch for configure related to Ruby on Mac OS X. (Bjorn Winckler, 2011 Jan 14) Crash in autocomplete, valgrind log. (Greg Weber, 2011 Apr 22)
Patch to set v:register on startup. (Ingo Karkat, 2011 Jan 16) Discussion about canonicalization of Hebrew. (Ron Aaron, 2011 April 10)
Patch to set v:register default depending on "unnamed" in 'clipboard'. (Ingo Patch to fail if configure can't find an interface, such as Python.
Karkat, 2011 Jan 16) (Shlomi Fish, 2011 Jul 11)
Patch for: Patch to support UTF-8 for Hangul. (Shawn Y.H. Kim, 2011 May 1)
InsertCharPre - user typed character Insert mode, before inserting the Needs more work.
char. Pattern is matched with text before the cursor.
Set v:char to the character, can be changed.
(not triggered when 'paste' is set).
(Jakson A. Aquino, 2011 Jan 29)
Patch for "No errors" showing up after QuickfixCmdPost. (Mike Lundy, 2011 Feb Patch for glob() returning a list. (Christian Brabandt, 2011 Aug 24, second
3) one)
Patch for cmdline completion of ":lang". (Dominique Pelle, 2011 Feb 5) Patch for: (Christian Brabandt, 2011 Aug 22)
- Make it possible to enter "r<C-E>" and "r<C-Y>" (get character from line
below/above).
Patch for adding 's' option to 'cino', C++ namespace indenting. (Konstantin Patch for: (Christian Brabandt, 2011 Aug 24, updated patch)
Lepa, 2011 Jan 18) 8 ":sign unplace * file={filename}" should work. Also: ":sign unplace *
buffer={bufnr}". So one can remove all signs for one file/buffer.
Patch to support ":!start /b cmd". (Xaizek, 2010 Dec 22) Problem with l: dictionary being locked in a function. (ZyX, 2011 Jul 21)
Patch to build with GTK on Mac. (Ben Schmidt, 2011 Jan 18)
Use another name instead of FEAT_GUI_ELSEWHERE.
Patch for xxd makefile to avoid generating .dSYM files. (Ben Schmidt, 2011 Jan
18)
Patch to show sign for folded text. (Christian Brabandt, 2011 Jan 12)
Method to reproduce it: Jan 16.
Patch to improve optwin.vim. (ZyX, 2011 Jan 29)
Patch for Python 3 support. (lilydjwg, 2011 Feb 24)
Building the MingW version without clipboard but with multi-byte doesn't
work. (Bill Lam, 2010 Sep 18)
Patch for handling of NL in substitute() with \= expression. (Motoya Kurotsu,
2011 Mar 16) Update Mar 24.
Patch to disallow fork() when __APPLE__ is defined. (Hisashi T Fujinaka, 2010
Nov 25)
GTK: Patch to fix menu popping down. (Hong Xu, 2010 Dec 4, Dec 5)
Update 2011 Feb 3.
Patch to use pipes on Win32. (Vincent Berthoux, 2011 Feb 28)
Update Mar 1 using 'shelltemp'.
"gh<Del>" deletes the current line, except when it's the last line.
Hint by Christian Brabandt, 2011 Mar 22
The :z command doesn't work exactly as it should. (ChangZhuo Chen, 2011 Mar 2)
Compare with how old Vi works and with posix spec. terminal is 80 x 24,
'scroll' option set to 11.
'cursorline' is displayed too short when there are concealed characters and 'cursorline' is displayed too short when there are concealed characters and
'list' is set. (Dennis Preiser) 'list' is set. (Dennis Preiser)
Patch 7.3.116 was the wrong solution. Patch 7.3.116 was the wrong solution.
Christian Brabandt has another incomplete patch. (2011 Jul 13)
When opening file from windows explorer, characters inside [] cause With concealed text mouse click doesn't put the cursor in the right position.
problems, even though double quotes are used. (Manuel Stol, 2011 Mar 9) (Herb Sitz) Fix by Christian Brabandt, 2011 Jun 16. Doesn't work properly,
need to make the change in where RET_WIN_BUF_CHARTABSIZE() is called.
Patch to change the meaning of \n in substitute(). (motoya kurotsu, 2011 Mar 8)
Help file foldexpr (ZyX)
Syntax region with 'concealends' and a 'cchar' value, 'conceallevel' set to 2, Syntax region with 'concealends' and a 'cchar' value, 'conceallevel' set to 2,
only one of the two ends gets the cchar displayed. (Brett Stahlman, 2010 Aug only one of the two ends gets the cchar displayed. (Brett Stahlman, 2010 Aug
21, Ben Fritz, 2010 Sep 14) 21, Ben Fritz, 2010 Sep 14)
Need to escape $HOME on Windows? (ZyX, 2011 Jul 21)
Bug in repeating Visual "u". (Lawrence Kesteloot, 2010 Dec 20) Bug in repeating Visual "u". (Lawrence Kesteloot, 2010 Dec 20)
CursorHold repeats typed key when it's the start of a mapping. With "unamedplus" in 'clipboard' pasting in Visual mode causes error for empty
(Will Gray, 2011 Mar 23) register. (Michael Seiwald, 2011 Jun 28) I can't reproduce it.
In GTK Gvim, setting 'lines' and 'columns' to 99999 causes a crash (Tony
Mechelynck, 2011 Apr 25). Can reproduce the crash sometimes:
gvim -N -u NONE --cmd 'set lines=99999 columns=99999'
(gvim:25968): Gdk-WARNING **: Native Windows wider or taller than 65535 pixels are not supported
The program 'gvim' received an X Window System error.
This probably reflects a bug in the program.
The error was 'RenderBadPicture (invalid Picture parameter)'.
(Details: serial 313 error_code 161 request_code 149 minor_code 8)
(Note to programmers: normally, X errors are reported asynchronously;
that is, you will receive the error a while after causing it.
To debug your program, run it with the --sync command line
option to change this behavior. You can then get a meaningful
backtrace from your debugger if you break on the gdk_x_error() function.)
Check that number of pixels doesn't go above 65535?
popup completion menu closes quickly when there is a fold in the buffer. (Jan
Christoph Ebersbach, 2011 Jul 3)
Windows keys not set properly on Windows 7? (cncyber, 2010 Aug 26) Windows keys not set properly on Windows 7? (cncyber, 2010 Aug 26)
@ -132,12 +117,18 @@ When using a Vim server, a # in the path causes an error message.
Bug: E685 error for func_unref(). (ZyX, 2010 Aug 5) Bug: E685 error for func_unref(). (ZyX, 2010 Aug 5)
Bug: Windows 7 64 bit system freezes when 'clipboard' set to "unnamed" and
doing ":g/test/d". Putting every delete on the clipboard? (Robert Chan, 2011
Jun 17)
Using ":break" or something else that stops executing commands inside a Using ":break" or something else that stops executing commands inside a
":finally" does not rethrow a previously uncaught exception. (ZyX, 2010 Oct ":finally" does not rethrow a previously uncaught exception. (ZyX, 2010 Oct
15) 15)
Vim using lots of memory when joining lines. (John Little, 2010 Dec 3) Vim using lots of memory when joining lines. (John Little, 2010 Dec 3)
Changes to manpage plugin. (Elias Toivanen, 2011 Jul 25)
On 64 bit MS-Windows "long" is only 32 bits, but we sometimes need to store a On 64 bit MS-Windows "long" is only 32 bits, but we sometimes need to store a
64 bits value. Change all number options to use nropt_T and define it to the 64 bits value. Change all number options to use nropt_T and define it to the
right type. right type.
@ -145,24 +136,27 @@ right type.
string() can't parse back "inf" and "nan". Fix documentation or fix code? string() can't parse back "inf" and "nan". Fix documentation or fix code?
(ZyX, 2010 Aug 23) (ZyX, 2010 Aug 23)
Make 'formatprg' global-local. (Sung Pae)
When doing "redir => s:foo" in a script and then "redir END" somewhere else When doing "redir => s:foo" in a script and then "redir END" somewhere else
(e.g. in a function) it can't find s:foo. (e.g. in a function) it can't find s:foo.
7 Make "ga" show the digraph for a character, if it exists.
Patch from Christian Brabandt, 2011 Aug 19.
maparg() does not show the <script> flag. When temporarily changing a maparg() does not show the <script> flag. When temporarily changing a
mapping, how to restore the script ID? mapping, how to restore the script ID?
Patch to fix \%V item in regexp. (Christian Brabandt, 2010 Nov 8)
Update Nov 19. James Vega: still not right. Christian: it's difficult.
Patch to add up to 99 match groups. (Christian Brabandt, 2010 Dec 22)
Also add named groups: \%{name}(re) and \%{name}g
Bug in try/catch: return with invalid compare throws error that isn't caught. Bug in try/catch: return with invalid compare throws error that isn't caught.
(ZyX, 2011 Jan 26) (ZyX, 2011 Jan 26)
Highlighting stops working after changing it many times. Script to reproduce Highlighting stops working after changing it many times. Script to reproduce
it: Pablo Contreras, 2010 Oct 12 Windows XP and 7. Font is never freed? it: Pablo Contreras, 2010 Oct 12 Windows XP and 7. Font is never freed?
When setting a local option value from the global value, add a script ID that
indicates this, so that ":verbose set" can give a hint. Check with options in
the help file.
After patch 7.3.097 still get E15. (Yukihiro Nakadaira, 2011 Jan 18) After patch 7.3.097 still get E15. (Yukihiro Nakadaira, 2011 Jan 18)
Also for another example (ZyX, 2011 Jan 24) Also for another example (ZyX, 2011 Jan 24)
@ -170,13 +164,12 @@ Build problem with small features on Mac OS X 10.6. (Rainer, 2011 Jan 24)
"0g@$" puts '] on last byte of multi-byte. (ZyX, 2011 Jan 22) "0g@$" puts '] on last byte of multi-byte. (ZyX, 2011 Jan 22)
Deleting a linewise selection that includes the last line of the file leaves
an empty line. (Ben Schmidt, 2011 Mar 17)
Patch by Christian Brabandt, 2011 Mar 19.
Patch to support sorting on floating point number. (Alex Jakushev, 2010 Oct Patch to support sorting on floating point number. (Alex Jakushev, 2010 Oct
30) 30)
Patch to addd TextDeletePost and TextYankPost events. (Philippe Vaucher, 2011
May 24) Update May 26.
When a script contains "redir => s:foo" but doesn't end redirection, a When a script contains "redir => s:foo" but doesn't end redirection, a
following "redir" command gives an error for not being able to access s:foo. following "redir" command gives an error for not being able to access s:foo.
(ZyX, 2011 Mar 27) (ZyX, 2011 Mar 27)
@ -186,6 +179,33 @@ Problem with "syn sync gouphere". (Gustavo Niemeyer, 2011 Jan 27)
Loading autoload script even when usage is inside "if 0". (Christian Brabandt, Loading autoload script even when usage is inside "if 0". (Christian Brabandt,
2010 Dec 18) 2010 Dec 18)
With a filler line in diff mode, it isn't displayed in the column with line
number, but it is in the sign column. Doesn't look right. (ZyX 2011 Jun 5)
Patch by Christian Brabandt, 2011 Jun 5. Introduces new problems.
8 Add a command to jump to the next character highlighted with "Error".
Patch by Christian Brabandt, uses ]e [e ]t and [t. 2011 Aug 9.
8 Add an event like CursorHold that is triggered repeatedly, not just once
after typing something.
Need for CursorHold that retriggers. Use a key that doesn't do anything, or a
function that resets did_cursorhold.
Patch by Christian Brabandt, 2011 May 6.
7 Use "++--", "+++--" for different levels instead of "+---" "+----".
Patch by Christian Brabandt, 2011 Jul 27.
Update by Ben Fritz, with fix for TOhtml. (2011 Jul 30)
9 Add %F to 'errorformat': file name without spaces. Useful on Unix to
avoid matching something up to a time 11:22:33.
Patch by Christian Brabandt, 2011 Jul 27.
Patch to fix \%V item in regexp. (Christian Brabandt, 2010 Nov 8)
Update Nov 19. James Vega: still not right. Christian: it's difficult.
Patch to add up to 99 match groups. (Christian Brabandt, 2010 Dec 22)
Also add named groups: \%{name}(re) and \%{name}g
In the sandbox it's not allowed to do many things, but it's possible to change In the sandbox it's not allowed to do many things, but it's possible to change
or set variables. Add a way to prevent variables from being changed in the or set variables. Add a way to prevent variables from being changed in the
sandbox? E.g.: ":protect g:restore_settings". sandbox? E.g.: ":protect g:restore_settings".
@ -204,8 +224,6 @@ Version of netbeans.c for use with MacVim. (Kazuki Sakamoto, 2010 Nov 18)
there is one backslash. (Ray Frush, 2010 Nov 18) What does the original ex there is one backslash. (Ray Frush, 2010 Nov 18) What does the original ex
do? do?
":find" completion does not escape space in directory name. (Isz, 2010 Nov 2)
Searching mixed with Visual mode doesn't redraw properly. (James Vega, 2010 Nov Searching mixed with Visual mode doesn't redraw properly. (James Vega, 2010 Nov
22) 22)
@ -283,9 +301,6 @@ mkdir().
When 'paste' is changed with 'pastetoggle', the ruler doesn't reflect this When 'paste' is changed with 'pastetoggle', the ruler doesn't reflect this
right away. (Samuel Ferencik, 2010 Dec 7) right away. (Samuel Ferencik, 2010 Dec 7)
Windows installer: licence text should not use indent, causes bad word wrap.
(Benjamin Fritz, 2010 Aug 16)
Mac with X11: clipboard doesn't work properly. (Raf, 2010 Aug 16) Mac with X11: clipboard doesn't work properly. (Raf, 2010 Aug 16)
Using CompilerSet doesn't record where an option was set from. E.g., in the Using CompilerSet doesn't record where an option was set from. E.g., in the
@ -307,19 +322,16 @@ When writing a file > 2Gbyte, the reported number of bytes is negative.
(Antonio Colombo, 2010 Dec 18) (Antonio Colombo, 2010 Dec 18)
Patch: Let rare word highlighting overrule good word highlighting. Patch: Let rare word highlighting overrule good word highlighting.
(Jakson A. Aquino, 2010 Jul 30) (Jakson A. Aquino, 2010 Jul 30, again 2011 Jul 2)
Patch to make more characters work in dialogs. (Yankwei Jia, 2010 Aug 4)
Patch for VisVim, pass file name to VimOpenFile. (Jiri Sedlak, 2010 Nov 12)
When 'lines' is 25 and 'scrolloff' is 12, "j" scrolls zero or two lines When 'lines' is 25 and 'scrolloff' is 12, "j" scrolls zero or two lines
instead of one. (Constantin Pan, 2010 Sep 10) instead of one. (Constantin Pan, 2010 Sep 10)
Crash in setqflist(). (Benoit Mortgat, 2010 Nov 18) Crash in setqflist(). (Benoit Mortgat, 2010 Nov 18)
Patch to handle resizing when tab is opened, when at full size. (Yukihiro Gui menu edit/paste in block mode insert only inserts in one line (Bjorn
Nakadaira, 2010 Jan 6) Winckler, 2011 May 11)
Requires a map mode for Insert mode started from blockwise Visual mode.
Writing nested List and Dict in viminfo gives error message and can't be read Writing nested List and Dict in viminfo gives error message and can't be read
back. (Yukihiro Nakadaira, 2010 Nov 13) back. (Yukihiro Nakadaira, 2010 Nov 13)
@ -328,11 +340,6 @@ Can 'undolevels' be a buffer-local option? Helps for making big changes in
one file only, set 'ul' to -1 only for that buffer. one file only, set 'ul' to -1 only for that buffer.
Patch by Christian Brabandt, 2010 Dec 17. Needs test. Patch by Christian Brabandt, 2010 Dec 17. Needs test.
Dos uninstal may delete vim.bat from the wrong directory (e.g., when someone
makes his own wrapper). Add a magic string with the version number to the
.bat file and check for it in the uninstaller. E.g.
# uninstall key: vim7.3*
Problem with cursor in the wrong column. (SungHyun Nam, 2010 Mar 11) Problem with cursor in the wrong column. (SungHyun Nam, 2010 Mar 11)
Additional info by Dominique Pelle. (also on 2010 Apr 10) Additional info by Dominique Pelle. (also on 2010 Apr 10)
@ -343,11 +350,6 @@ FILE_SHARE_WRITE in mch_access()? (Phillippe Vaucher, 2010 Nov 2)
Is ~/bin (literally) in $PATH supposed to work? (Paul, 2010 March 29) Is ~/bin (literally) in $PATH supposed to work? (Paul, 2010 March 29)
Looks like only bash can do it. (Yakov Lerner) Looks like only bash can do it. (Yakov Lerner)
8 Add an event like CursorHold that is triggered repeatedly, not just once
after typing something.
Need for CursorHold that retriggers. Use a key that doesn't do anything, or a
function that resets did_cursorhold.
Cscope "cs add" stopped working somewhat before 7.2.438. (Gary Johnson, 2010 Cscope "cs add" stopped working somewhat before 7.2.438. (Gary Johnson, 2010
Jun 29) Caused by 7.2.433? Jun 29) Caused by 7.2.433?
@ -372,8 +374,6 @@ Shell not recognized properly if it ends in "csh -f". (James Vega, 2009 Nov 3)
Find tail? Might have a / in argument. Find space? Might have space in Find tail? Might have a / in argument. Find space? Might have space in
path. path.
":sort n" treats empty line as higher than zero. (Beeyawned, 2010 Oct 13)
Test 51 fails when language set to German. (Marco, 2011 Jan 9) Test 51 fails when language set to German. (Marco, 2011 Jan 9)
Dominique can't reproduc it. Dominique can't reproduc it.
@ -407,19 +407,13 @@ characters. (2010 Aug 14, bootleq)
Problem with stop directory in findfile(). (Adam Simpkins, 2009 Aug 26) Problem with stop directory in findfile(). (Adam Simpkins, 2009 Aug 26)
Using ']' as the end of a range in a pattern requires double escaping:
/[@-\\]] (Andy Wokula, 2011 Jun 28)
Undo problem: line not removed as expected when using setline() from Insert Undo problem: line not removed as expected when using setline() from Insert
mode. (Israel Chauca, 2010 May 13, more in second msg) mode. (Israel Chauca, 2010 May 13, more in second msg)
Break undo when CTRL-R = changes the text? Or save more lines? Break undo when CTRL-R = changes the text? Or save more lines?
Patch for static code analysis errors in riscOS. (Dominique Pelle, 2010 Dec 3)
Patch for better #if 0 syntax highlighting for C code. (Ben Schmidt, 2011 Jan
20)
Change to C syntax folding to make it work much faster, but a bit less
reliable. (Lech Lorens, 2009 Nov 9) Enable with an option?
Most time is spent in in_id_list().
Slow combination of folding and PHP syntax highlighting. Script to reproduce Slow combination of folding and PHP syntax highlighting. Script to reproduce
it. Caused by "syntax sync fromstart" in combination with patch 7.2.274. it. Caused by "syntax sync fromstart" in combination with patch 7.2.274.
(Christian Brabandt, 2010 May 27) (Christian Brabandt, 2010 May 27)
@ -432,16 +426,9 @@ Disable updating folds while completion is active? (Peter Odding, 2010 Jun 9)
Using ":call foo#d.f()" doesn't autoload the "foo.vim" file. Works OK for Using ":call foo#d.f()" doesn't autoload the "foo.vim" file. Works OK for
echo, just not for ":call" and ":call call()". (Ted, 2011 Mar 17) echo, just not for ":call" and ":call call()". (Ted, 2011 Mar 17)
In command line window ":close" doesn't work properly. (Tony Mechelynck, 2009
Jun 1)
Cannot use getchar() inside :normal and using an expression mapping. Is this Cannot use getchar() inside :normal and using an expression mapping. Is this
supposed to work? (XyX, 2010 Sep 22) supposed to work? (XyX, 2010 Sep 22)
When using an expression mapping with a multi-byte character each byte is
converted to a utf-8 character. (ZyX, 2011 Jan 4)
Patch for possible solution. (Yukihiro Nakadaira, 2011 Jan 5)
When a:base in 'completefunc' starts with a number it's passed as a number, When a:base in 'completefunc' starts with a number it's passed as a number,
not a string. (Sean Ma) Need to add flag to call_func_retlist() to force a not a string. (Sean Ma) Need to add flag to call_func_retlist() to force a
string value. string value.
@ -558,9 +545,6 @@ Ignore window options when not in the right window?
Perhaps we need to use a hidden window for applying autocommands to a buffer Perhaps we need to use a hidden window for applying autocommands to a buffer
that doesn't have a window. that doesn't have a window.
When "b" is a symlink to directory "a", resolve("b/") doesn't result in "a/".
(ZyX, 2011 Feb 12)
When using "ab foo bar" and mapping <Tab> to <Esc>, pressing <Tab> after foo When using "ab foo bar" and mapping <Tab> to <Esc>, pressing <Tab> after foo
doesn't trigger the abbreviation like <Esc> would. (Ramana Kumar, 2009 Sep 6) doesn't trigger the abbreviation like <Esc> would. (Ramana Kumar, 2009 Sep 6)
@ -771,11 +755,6 @@ an alternate solution, also for src/ex_getln.c.
This also fails when the file or directory name contains "%". (Thoml, 2008 This also fails when the file or directory name contains "%". (Thoml, 2008
July 7) July 7)
The str2special() function doesn't handle multi-byte characters properly.
Patch from Vladimir Vichniakov, 2007 Apr 24.
Should clean up the whole function. Also allow modifiers like <S-Char-32>?
find_special_key() also has this problem.
Problem with 'langmap' being used on the rhs of a mapping. (Nikolai Weibull, Problem with 'langmap' being used on the rhs of a mapping. (Nikolai Weibull,
2008 May 14) 2008 May 14)
@ -851,8 +830,6 @@ try/catch not working for argument of return. (Matt Wozniski, 2008 Sep 15)
try/catch not working when inside a for loop. (ZyX, 2011 Jan 25) try/catch not working when inside a for loop. (ZyX, 2011 Jan 25)
Recognize and ignore BOM in error file. (Aleksey Baibarin)
":tab help" always opens a new tab, while ":help" re-uses an existing window. ":tab help" always opens a new tab, while ":help" re-uses an existing window.
Would be more consistent when an existing tab is re-used. (Tony Mechelynck) Would be more consistent when an existing tab is re-used. (Tony Mechelynck)
@ -886,9 +863,6 @@ Can't easily close the help window, like ":pc" closes the preview window and
":ccl" closes the quickfix window. Add ":hclose". (Chris Gaal) ":ccl" closes the quickfix window. Add ":hclose". (Chris Gaal)
Patch for :helpclose, Christian Brabandt, 2010 Sep 6. Patch for :helpclose, Christian Brabandt, 2010 Sep 6.
Patch for :lmake not updating the quickfix window title. (Lech Lorens, 2011
Mar 26)
When 'diffopt' has "context:0" a single deleted line causes two folds to merge When 'diffopt' has "context:0" a single deleted line causes two folds to merge
and mess up syncing. (Austin Jennings, 2008 Jan 31) and mess up syncing. (Austin Jennings, 2008 Jan 31)
@ -897,6 +871,9 @@ Gnome improvements: Edward Catmur, 2007 Jan 7
New PHP syntax file, use it? (Peter Hodge) New PHP syntax file, use it? (Peter Hodge)
":echoe" in catch block stops processing, while this doesn't happen outside of
a catch block. (ZyX, 2011 Jun 2)
'foldcolumn' in modeline applied to wrong window when using a session. (Teemu 'foldcolumn' in modeline applied to wrong window when using a session. (Teemu
Likonen, March 19) Likonen, March 19)
@ -946,9 +923,6 @@ popup menu over it, first draw the new popup menu, remember its position and
size and then redraw the text, skipping the characters under the popup menu. size and then redraw the text, skipping the characters under the popup menu.
This should avoid flicker. Other solution by A.Politz, 2007 Aug 22. This should avoid flicker. Other solution by A.Politz, 2007 Aug 22.
When the popup menu is close to the edge of the window it is truncated. Patch
to anchor the popup menu in a different way. (James Vega, 2008 Jul 30)
Windows 98: pasting from the clipboard with text from another application has Windows 98: pasting from the clipboard with text from another application has
a trailing NUL. (Joachim Hofmann) Perhaps the length specified for CF_TEXT a trailing NUL. (Joachim Hofmann) Perhaps the length specified for CF_TEXT
isn't right? isn't right?
@ -974,6 +948,9 @@ Jun 3)
However, for backwards compatibility escaping might be necessary. Check if However, for backwards compatibility escaping might be necessary. Check if
the user put quotes around the expanded item? the user put quotes around the expanded item?
A throw in a function causes missing an endif below the call. (Spiros
Bousbouras, 2011 May 16)
Error E324 can be given when a cron script has wiped out our temp directory. Error E324 can be given when a cron script has wiped out our temp directory.
Give a clear error message about this (and tell them not to wipe out /tmp). Give a clear error message about this (and tell them not to wipe out /tmp).
@ -993,10 +970,19 @@ go to Insert mode and add a few lines. Then backspacing every other time
moves the cursor instead of deleting. (Chris Kaiser, 2007 Sep 25) moves the cursor instead of deleting. (Chris Kaiser, 2007 Sep 25)
Patch to use Modern UI 2.0 for the Nsis installer. (Guopeng Wen, 2010 Jul 30) Patch to use Modern UI 2.0 for the Nsis installer. (Guopeng Wen, 2010 Jul 30)
Latest version: 2011 May 18
8 Windows install with NSIS: make it possible to do a silent install, see 8 Windows install with NSIS: make it possible to do a silent install, see
http://nsis.sourceforge.net/Docs/Chapter4.html#4.12 http://nsis.sourceforge.net/Docs/Chapter4.html#4.12
Version from Guopeng Wen that does this (2010 Dec 27) Version from Guopeng Wen that does this (2010 Dec 27)
Windows installer: licence text should not use indent, causes bad word wrap.
(Benjamin Fritz, 2010 Aug 16)
Dos uninstal may delete vim.bat from the wrong directory (e.g., when someone
makes his own wrapper). Add a magic string with the version number to the
.bat file and check for it in the uninstaller. E.g.
# uninstall key: vim7.3*
Changes for Win32 makefile. (Mike Williams, 2007 Jan 22, Alexei Alexandrov, Changes for Win32 makefile. (Mike Williams, 2007 Jan 22, Alexei Alexandrov,
2007 Feb 8) 2007 Feb 8)
@ -1075,9 +1061,6 @@ If the variable "g:x#y#z" exists completion after ":echo g:x#" doesn't work.
Feature request: Command to go to previous tab, like what CTRL-W p does for Feature request: Command to go to previous tab, like what CTRL-W p does for
windows. (Adam George) windows. (Adam George)
When using input() in a loop and then ":echo" the display column isn't right.
(Benjamin Fritz, 2008 Aug 28) Patch by Ben Schmidt, 2008 Sep 2.
F1 - F4 in an xterm produce a different escape sequence when used with a F1 - F4 in an xterm produce a different escape sequence when used with a
modifier key. Need to catch three different sequences. Use K_ZF1, like modifier key. Need to catch three different sequences. Use K_ZF1, like
K_ZHOME? (Dickey, 2007 Dec 2) K_ZHOME? (Dickey, 2007 Dec 2)
@ -1106,8 +1089,6 @@ if_ruby.c.
Patch to dynamically load Python on Solaris. (Danek Duvall, 2009 Feb 16) Patch to dynamically load Python on Solaris. (Danek Duvall, 2009 Feb 16)
Needs more work. Needs more work.
Python3 interface doesn't handle utf-8 correctly? (Nov 2010, lilydjwg)
The need_fileinfo flag is messy. Instead make the message right away and put The need_fileinfo flag is messy. Instead make the message right away and put
it in keep_msg? it in keep_msg?
@ -1332,6 +1313,9 @@ resulting in highlighted "{" in that window, not in the other.
In mswin.vim: Instead of mapping <C-V> for Insert mode in a complicated way, In mswin.vim: Instead of mapping <C-V> for Insert mode in a complicated way,
can it be done like ":imap <C-V> <MiddleMouse>" without negative side effects? can it be done like ":imap <C-V> <MiddleMouse>" without negative side effects?
Completion menu disappears when using 'cursorcolumn'. (Sven-Hendrik Haase,
2011 May 23)
GTK: when the Tab pages bar appears or disappears while the window is GTK: when the Tab pages bar appears or disappears while the window is
maximized the window is no longer maximized. Patch that has some idea but maximized the window is no longer maximized. Patch that has some idea but
doesn't work from Geoffrey Antos, 2008 May 5. doesn't work from Geoffrey Antos, 2008 May 5.
@ -1402,9 +1386,6 @@ In gvim the backspace key produces a backspace character, but on Linux the
VERASE key is Delete. Set VERASE to Backspace? (patch by Stephane Chazelas, VERASE key is Delete. Set VERASE to Backspace? (patch by Stephane Chazelas,
2007 Oct 16) 2007 Oct 16)
When entering a C /* comment, after typing <Enter> for 70 times the indent
disappears. (Vincent Beffara, 2008 Jul 3)
TermResponse autocommand isn't always triggered when using vimdiff. (Aron TermResponse autocommand isn't always triggered when using vimdiff. (Aron
Griffis, 2007 Sep 19) Griffis, 2007 Sep 19)
@ -1505,6 +1486,7 @@ Awaiting updated patches:
- Patch for 'breakindent' option: repeat indent for wrapped line. (Vaclav - Patch for 'breakindent' option: repeat indent for wrapped line. (Vaclav
Smilauer, 2004 Sep 13, fix Oct 31, update 2007 May 30) Smilauer, 2004 Sep 13, fix Oct 31, update 2007 May 30)
Version for latest MacVim: Tobia Conforto, 2009 Nov 23 Version for latest MacVim: Tobia Conforto, 2009 Nov 23
More recent version: https://retracile.net/wiki/VimBreakIndent
8 Add a few more command names to the menus. Patch from Jiri Brezina 8 Add a few more command names to the menus. Patch from Jiri Brezina
(28 feb 2002). Will mess the translations... (28 feb 2002). Will mess the translations...
7 ATTENTION dialog choices are more logical when "Delete it' appears 7 ATTENTION dialog choices are more logical when "Delete it' appears
@ -1833,7 +1815,7 @@ GUI:
8 When translating menus ignore the part after the Tab, the shortcut. So 8 When translating menus ignore the part after the Tab, the shortcut. So
that the same menu item with a different shortcut (e.g., for the Mac) are that the same menu item with a different shortcut (e.g., for the Mac) are
still translated. still translated.
8 Add menu separators for Amiga, RISCOS. 8 Add menu separators for Amiga.
8 Add way to specify the file filter for the browse dialog. At least for 8 Add way to specify the file filter for the browse dialog. At least for
browse(). browse().
8 Add dialog for search/replace to other GUIs? Tk has something for this, 8 Add dialog for search/replace to other GUIs? Tk has something for this,
@ -2078,8 +2060,6 @@ Macintosh:
6 Python: ":py raw_input('prompt')" doesn't work. (Manu Hack) 6 Python: ":py raw_input('prompt')" doesn't work. (Manu Hack)
8 Command line completion: buffers "foo.txt" and "../b/foo.txt", completing 8 Command line completion: buffers "foo.txt" and "../b/foo.txt", completing
":buf foo<Tab>" doesn't find the second one. (George V. Reilly) ":buf foo<Tab>" doesn't find the second one. (George V. Reilly)
7 Output for ":scriptnames" and ":breaklist" should shorten the file names:
use "~/" when possible.
7 mb_off2cells() doesn't work correctly on the tail byte of a double-byte 7 mb_off2cells() doesn't work correctly on the tail byte of a double-byte
character. (Yasuhiro Matsumoto) It should return 1 when used on a tail character. (Yasuhiro Matsumoto) It should return 1 when used on a tail
byte, like for utf-8. Store second byte of double-byte in ScreenLines2[] byte, like for utf-8. Store second byte of double-byte in ScreenLines2[]
@ -2106,8 +2086,6 @@ Macintosh:
works. works.
8 A very long message in confirm() can't be quit. Make this possible with 8 A very long message in confirm() can't be quit. Make this possible with
CTRL-C. CTRL-C.
8 When the clipboard isn't supported: ":yank*" gives a confusing error
message. Specifically mention that the register name is invalid.
8 "gf" always excludes trailing punctuation characters. file_name_in_line() 8 "gf" always excludes trailing punctuation characters. file_name_in_line()
is currently fixed to use ".,:;!". Add an option to make this is currently fixed to use ".,:;!". Add an option to make this
configurable? configurable?
@ -2121,8 +2099,6 @@ Macintosh:
is a multi-byte character. is a multi-byte character.
8 When appending to a file and 'patchmode' isn't empty, a backup file is 8 When appending to a file and 'patchmode' isn't empty, a backup file is
always written, even when the original file already exists. always written, even when the original file already exists.
7 When using "daw" on the last word in a file and this is a single letter,
nothing is deleted. Should delete the letter and preceding white space.
9 When getting focus while writing a large file, could warn for this file 9 When getting focus while writing a large file, could warn for this file
being changed outside of Vim. Avoid checking this while the file is being being changed outside of Vim. Avoid checking this while the file is being
written. written.
@ -2669,7 +2645,6 @@ Folding:
8 Add "z/" and "z?" for searching in not folded text only. 8 Add "z/" and "z?" for searching in not folded text only.
9 Add search pattern item to only match in closed or open fold and/or fold 9 Add search pattern item to only match in closed or open fold and/or fold
with certain level. Allows doing ":g/pat/cmd" to work on closed folds. with certain level. Allows doing ":g/pat/cmd" to work on closed folds.
7 Use "++--", "+++--" for different levels instead of "+---" "+----".
8 When a closed fold is displayed open because of 'foldminlines', the 8 When a closed fold is displayed open because of 'foldminlines', the
behavior of commands is still like the fold is closed. How to make the behavior of commands is still like the fold is closed. How to make the
user aware of this? user aware of this?
@ -2773,7 +2748,7 @@ Multi-byte characters:
For Windows, the charset_pairs[] table could be used. But how do we know For Windows, the charset_pairs[] table could be used. But how do we know
if a font exists? if a font exists?
- Do keyboard conversion from 'termencoding' to 'encoding' with - Do keyboard conversion from 'termencoding' to 'encoding' with
convert_input() for Mac GUI and RiscOS GUI. convert_input() for Mac GUI.
- Add mnemonics from RFC1345 longer than two characters. - Add mnemonics from RFC1345 longer than two characters.
Support CTRL-K _{mnemonic}_ Support CTRL-K _{mnemonic}_
7 In "-- INSERT (lang) --" show the name of the keymap used instead of 7 In "-- INSERT (lang) --" show the name of the keymap used instead of
@ -2849,7 +2824,6 @@ Syntax highlighting:
8 Highlight the text between two matching parens (e.g., with a grey 8 Highlight the text between two matching parens (e.g., with a grey
background) when on one of the parens or in between them. background) when on one of the parens or in between them.
Option for the matchparen plugin? Option for the matchparen plugin?
8 Add a command to jump to the next character highlighted with "Error".
8 When using a cterm, and no ctermfg or ctermbg are defined, use start/stop 8 When using a cterm, and no ctermfg or ctermbg are defined, use start/stop
sequences. Add remark in docs that :if 'term' == "term-name" should be sequences. Add remark in docs that :if 'term' == "term-name" should be
used. used.
@ -3036,6 +3010,10 @@ Built-in script language:
Patch by Ilya Sher, 2004 Mar 4. Patch by Ilya Sher, 2004 Mar 4.
Return a list instead. Return a list instead.
char2hex() convert char string to hex string. char2hex() convert char string to hex string.
crypt() encrypt string
decrypt() decrypt string
base64enc() base 64 encoding
base64dec() base 64 decoding
attributes() return file protection flags "drwxrwxrwx" attributes() return file protection flags "drwxrwxrwx"
filecopy(from, to) Copy a file filecopy(from, to) Copy a file
shorten(fname) shorten a file name, like home_replace() shorten(fname) shorten a file name, like home_replace()
@ -3417,7 +3395,7 @@ Win32 GUI:
GUI: GUI:
8 Make inputdialog() work for Photon, Amiga, RiscOS. 8 Make inputdialog() work for Photon, Amiga.
- <C--> cannot be mapped. Should be possible to recognize this as a - <C--> cannot be mapped. Should be possible to recognize this as a
normal "-" with the Ctrl modifier. normal "-" with the Ctrl modifier.
7 Implement ":popup" for other systems than Windows. 7 Implement ":popup" for other systems than Windows.
@ -3496,6 +3474,8 @@ GUI:
Autocommands: Autocommands:
9 Rework the code from FEAT_OSFILETYPE for autocmd-osfiletypes to use
'filetype'. Only for when the current buffer is known.
- Put autocommand event names in a hashtable for faster lookup? - Put autocommand event names in a hashtable for faster lookup?
8 When the SwapExists event is triggered, provide information about the 8 When the SwapExists event is triggered, provide information about the
swap file, e.g., whether the process is running, file was modified, etc. swap file, e.g., whether the process is running, file was modified, etc.
@ -3528,9 +3508,9 @@ Autocommands:
handled (e.g., other font) (Ron Aaron) handled (e.g., other font) (Ron Aaron)
7 When trying to open a directory, trigger an OpenDirectory event. 7 When trying to open a directory, trigger an OpenDirectory event.
7 Add file type in front of file pattern: <d> for directory, <l> for link, 7 Add file type in front of file pattern: <d> for directory, <l> for link,
<x> for executable, etc. <&xxx> for Risc OS. With commas to separate <x> for executable, etc. With commas to separate alternatives. The
alternatives. The autocommand is only executed when both the file type autocommand is only executed when both the file type AND the file pattern
AND the file pattern match. (Leonard) match. (Leonard)
5 Add option that specifies extensions which are to be discarded from the 5 Add option that specifies extensions which are to be discarded from the
file name. E.g. 'ausuffix', with ".gz,.orig". Such that file.c.gz will file name. E.g. 'ausuffix', with ".gz,.orig". Such that file.c.gz will
trigger the "*.c" autocommands. (Belabas) trigger the "*.c" autocommands. (Belabas)
@ -3768,6 +3748,7 @@ Insert mode:
7 Use CTRL-G <count> to repeat what follows. Useful for inserting a 7 Use CTRL-G <count> to repeat what follows. Useful for inserting a
character multiple times or repeating CTRL-Y. character multiple times or repeating CTRL-Y.
- Make 'revins' work in Replace mode. - Make 'revins' work in Replace mode.
9 Can't use multi-byte characters for 'matchpairs'.
7 Use 'matchpairs' for 'showmatch': When inserting a character check if it 7 Use 'matchpairs' for 'showmatch': When inserting a character check if it
appears in the rhs of 'matchpairs'. appears in the rhs of 'matchpairs'.
- In Insert mode (and command line editing?): Allow undo of the last typed - In Insert mode (and command line editing?): Allow undo of the last typed
@ -3787,12 +3768,6 @@ Insert mode:
'cindent', 'smartindent': 'cindent', 'smartindent':
9 ") :" confuses continuation line: (Colin Bennett, 2007 Dec 14)
cout << "a"
<< ") :"
<< "y";
9 "} else" causes following lines to be indented too much. (Rouben
Rostamian, 2008 Aug 30)
9 Wrapping a variable initialization should have extra indent: 9 Wrapping a variable initialization should have extra indent:
char * veryLongName = char * veryLongName =
"very long string" "very long string"
@ -4485,11 +4460,8 @@ Marks:
Digraphs: Digraphs:
7 Make "ga" show the digraph for a character, if it exists. 7 Make "ga" show the keymap for a character, if it exists.
Also the keymap?
Also show the code of the character after conversion to 'filenecoding'. Also show the code of the character after conversion to 'filenecoding'.
- Make it possible to enter "r<C-E>" and "r<C-Y>" (get character from line
below/above).
- Use digraph table to tell Vim about the collating sequence of special - Use digraph table to tell Vim about the collating sequence of special
characters? characters?
8 Add command to remove one or more (all) digraphs. (Brown) 8 Add command to remove one or more (all) digraphs. (Brown)
@ -4607,8 +4579,6 @@ Debug mode:
Various improvements: Various improvements:
9 Python: be able to define a Python function that can be called directly 9 Python: be able to define a Python function that can be called directly
from Vim script. Requires converting the arguments and return value. from Vim script. Requires converting the arguments and return value.
8 ":sign unplace * file={filename}" should work. Also: ":sign unplace *
buffer={bufnr}". So one can remove all signs for one file/buffer.
7 Add plugins for formatting? Should be able to make a choice depending on 7 Add plugins for formatting? Should be able to make a choice depending on
the language of a file (English/Korean/Japanese/etc.). the language of a file (English/Korean/Japanese/etc.).
Setting the 'langformat' option to "chinese" would load the Setting the 'langformat' option to "chinese" would load the
@ -4626,8 +4596,6 @@ Various improvements:
7 Instead of filtering errors with a shell script it should be possible to 7 Instead of filtering errors with a shell script it should be possible to
do this with Vim script. A function that filters the raw text that comes do this with Vim script. A function that filters the raw text that comes
from the 'makeprg'? from the 'makeprg'?
9 Add %F to 'errorformat': file name without spaces. Useful on Unix to
avoid matching something up to a time 11:22:33.
- Add %b to 'errorformat': buffer number. (Yegappan Lakshmanan / Suresh - Add %b to 'errorformat': buffer number. (Yegappan Lakshmanan / Suresh
Govindachar) Govindachar)
7 Add a command that goes back to the position from before jumping to the 7 Add a command that goes back to the position from before jumping to the

View File

@ -1,4 +1,4 @@
*undo.txt* For Vim version 7.3. Last change: 2010 Dec 19 *undo.txt* For Vim version 7.3. Last change: 2011 Aug 02
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -35,8 +35,10 @@ CTRL-R Redo [count] changes which were undone. {Vi: redraw
:red[o] Redo one change which was undone. {Vi: no redo} :red[o] Redo one change which was undone. {Vi: no redo}
*U* *U*
U Undo all latest changes on one line. {Vi: while not U Undo all latest changes on one line, the line where
moved off of it} the latest change was made. |U| itself also counts as
a change, and thus |U| undoes a previous |U|.
{Vi: while not moved off of the last modified line}
The last changes are remembered. You can use the undo and redo commands above The last changes are remembered. You can use the undo and redo commands above
to revert the text to how it was before each change. You can also apply the to revert the text to how it was before each change. You can also apply the

View File

@ -1,4 +1,4 @@
*usr_41.txt* For Vim version 7.3. Last change: 2011 Feb 15 *usr_41.txt* For Vim version 7.3. Last change: 2011 Jun 19
VIM USER MANUAL - by Bram Moolenaar VIM USER MANUAL - by Bram Moolenaar
@ -597,7 +597,7 @@ String manipulation: *string-functions*
strridx() last index of a short string in a long string strridx() last index of a short string in a long string
strlen() length of a string strlen() length of a string
substitute() substitute a pattern match with a string substitute() substitute a pattern match with a string
submatch() get a specific match in a ":substitute" submatch() get a specific match in ":s" and substitute()
strpart() get part of a string strpart() get part of a string
expand() expand special keywords expand() expand special keywords
iconv() convert text from one encoding to another iconv() convert text from one encoding to another

View File

@ -1,4 +1,4 @@
*various.txt* For Vim version 7.3. Last change: 2011 Mar 03 *various.txt* For Vim version 7.3. Last change: 2011 May 19
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -360,8 +360,6 @@ m *+mzscheme* Mzscheme interface |mzscheme|
m *+mzscheme/dyn* Mzscheme interface |mzscheme-dynamic| |/dyn| m *+mzscheme/dyn* Mzscheme interface |mzscheme-dynamic| |/dyn|
m *+netbeans_intg* |netbeans| m *+netbeans_intg* |netbeans|
m *+ole* Win32 GUI only: |ole-interface| m *+ole* Win32 GUI only: |ole-interface|
*+osfiletype* Support for the 'osfiletype' option and filetype
checking in automatic commands. |autocmd-osfiletypes|
N *+path_extra* Up/downwards search in 'path' and 'tags' N *+path_extra* Up/downwards search in 'path' and 'tags'
m *+perl* Perl interface |perl| m *+perl* Perl interface |perl|
m *+perl/dyn* Perl interface |perl-dynamic| |/dyn| m *+perl/dyn* Perl interface |perl-dynamic| |/dyn|

View File

@ -1,4 +1,4 @@
*vi_diff.txt* For Vim version 7.3. Last change: 2010 Oct 11 *vi_diff.txt* For Vim version 7.3. Last change: 2011 Aug 29
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -88,8 +88,8 @@ Maximum display width Unix and Win32: 1024 characters, otherwise 255
characters characters
Maximum lhs of a mapping 50 characters. Maximum lhs of a mapping 50 characters.
Number of different highlighting types: over 30000 Number of different highlighting types: over 30000
Range of a Number variable: -2147483648 to 2147483647 (more on 64 bit Range of a Number variable: -2147483648 to 2147483647 (might be more on 64
systems) bit systems)
Maximum length of a line in a tags file: 512 bytes. Maximum length of a line in a tags file: 512 bytes.
Information for undo and text in registers is kept in memory, thus when making Information for undo and text in registers is kept in memory, thus when making

View File

@ -1,4 +1,4 @@
*windows.txt* For Vim version 7.3. Last change: 2010 Aug 15 *windows.txt* For Vim version 7.3. Last change: 2011 Aug 14
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -246,7 +246,7 @@ window will appear.
These command modifiers can be combined to make a vertically split window These command modifiers can be combined to make a vertically split window
occupy the full height. Example: > occupy the full height. Example: >
:vertical topleft edit tags :vertical topleft split tags
Opens a vertically split, full-height window on the "tags" file at the far Opens a vertically split, full-height window on the "tags" file at the far
left of the Vim window. left of the Vim window.

View File

@ -1,7 +1,7 @@
" Vim support file to detect file types " Vim support file to detect file types
" "
" Maintainer: Bram Moolenaar <Bram@vim.org> " Maintainer: Bram Moolenaar <Bram@vim.org>
" Last Change: 2011 Apr 01 " Last Change: 2011 Sep 07
" Listen very carefully, I will say this only once " Listen very carefully, I will say this only once
if exists("did_load_filetypes") if exists("did_load_filetypes")
@ -123,7 +123,7 @@ au BufNewFile,BufRead *.am
\ if expand("<afile>") !~? 'Makefile.am\>' | setf elf | endif \ if expand("<afile>") !~? 'Makefile.am\>' | setf elf | endif
" ALSA configuration " ALSA configuration
au BufNewFile,BufRead ~/.asoundrc,/usr/share/alsa/alsa.conf,*/etc/asound.conf setf alsaconf au BufNewFile,BufRead .asoundrc,*/usr/share/alsa/alsa.conf,*/etc/asound.conf setf alsaconf
" Arc Macro Language " Arc Macro Language
au BufNewFile,BufRead *.aml setf aml au BufNewFile,BufRead *.aml setf aml
@ -156,7 +156,7 @@ au BufNewFile,BufRead *.asp
\ endif \ endif
" Grub (must be before catch *.lst) " Grub (must be before catch *.lst)
au BufNewFile,BufRead /boot/grub/menu.lst,/boot/grub/grub.conf,*/etc/grub.conf setf grub au BufNewFile,BufRead */boot/grub/menu.lst,*/boot/grub/grub.conf,*/etc/grub.conf setf grub
" Assembly (all kinds) " Assembly (all kinds)
" *.lst is not pure assembly, it has two extra columns (address, byte codes) " *.lst is not pure assembly, it has two extra columns (address, byte codes)
@ -316,9 +316,6 @@ endfunc
" Calendar " Calendar
au BufNewFile,BufRead calendar setf calendar au BufNewFile,BufRead calendar setf calendar
au BufNewFile,BufRead */.calendar/*,
\*/share/calendar/*/calendar.*,*/share/calendar/calendar.*
\ call s:StarSetf('calendar')
" C# " C#
au BufNewFile,BufRead *.cs setf cs au BufNewFile,BufRead *.cs setf cs
@ -330,7 +327,7 @@ au BufNewFile,BufRead *.cabal setf cabal
au BufNewFile,BufRead *.toc setf cdrtoc au BufNewFile,BufRead *.toc setf cdrtoc
" Cdrdao config " Cdrdao config
au BufNewFile,BufRead */etc/cdrdao.conf,*/etc/defaults/cdrdao,*/etc/default/cdrdao,~/.cdrdao setf cdrdaoconf au BufNewFile,BufRead */etc/cdrdao.conf,*/etc/defaults/cdrdao,*/etc/default/cdrdao,.cdrdao setf cdrdaoconf
" Cfengine " Cfengine
au BufNewFile,BufRead cfengine.conf setf cfengine au BufNewFile,BufRead cfengine.conf setf cfengine
@ -487,7 +484,7 @@ au BufNewFile,BufRead *.prg
au BufNewFile,BufRead CMakeLists.txt,*.cmake,*.cmake.in setf cmake au BufNewFile,BufRead CMakeLists.txt,*.cmake,*.cmake.in setf cmake
" Cmusrc " Cmusrc
au BufNewFile,BufRead ~/.cmus/{autosave,rc,command-history,*.theme} setf cmusrc au BufNewFile,BufRead */.cmus/{autosave,rc,command-history,*.theme} setf cmusrc
au BufNewFile,BufRead */cmus/{rc,*.theme} setf cmusrc au BufNewFile,BufRead */cmus/{rc,*.theme} setf cmusrc
" Cobol " Cobol
@ -558,6 +555,9 @@ au BufNewFile,BufRead */etc/apt/sources.list.d/*.list setf debsources
" Deny hosts " Deny hosts
au BufNewFile,BufRead denyhosts.conf setf denyhosts au BufNewFile,BufRead denyhosts.conf setf denyhosts
" dnsmasq(8) configuration files
au BufNewFile,BufRead */etc/dnsmasq.conf setf dnsmasq
" ROCKLinux package description " ROCKLinux package description
au BufNewFile,BufRead *.desc setf desc au BufNewFile,BufRead *.desc setf desc
@ -728,14 +728,14 @@ au BufNewFile,BufRead *.mo,*.gdmo setf gdmo
au BufNewFile,BufRead *.ged,lltxxxxx.txt setf gedcom au BufNewFile,BufRead *.ged,lltxxxxx.txt setf gedcom
" Git " Git
autocmd BufNewFile,BufRead *.git/COMMIT_EDITMSG setf gitcommit au BufNewFile,BufRead *.git/COMMIT_EDITMSG setf gitcommit
autocmd BufNewFile,BufRead *.git/config,.gitconfig,.gitmodules setf gitconfig au BufNewFile,BufRead *.git/config,.gitconfig,.gitmodules setf gitconfig
autocmd BufNewFile,BufRead git-rebase-todo setf gitrebase au BufNewFile,BufRead git-rebase-todo setf gitrebase
autocmd BufNewFile,BufRead .msg.[0-9]* au BufNewFile,BufRead .msg.[0-9]*
\ if getline(1) =~ '^From.*# This line is ignored.$' | \ if getline(1) =~ '^From.*# This line is ignored.$' |
\ setf gitsendemail | \ setf gitsendemail |
\ endif \ endif
autocmd BufNewFile,BufRead *.git/** au BufNewFile,BufRead *.git/**
\ if getline(1) =~ '^\x\{40\}\>\|^ref: ' | \ if getline(1) =~ '^\x\{40\}\>\|^ref: ' |
\ setf git | \ setf git |
\ endif \ endif
@ -749,7 +749,10 @@ au BufNewFile,BufRead *.gp,.gprc setf gp
" GPG " GPG
au BufNewFile,BufRead */.gnupg/options setf gpg au BufNewFile,BufRead */.gnupg/options setf gpg
au BufNewFile,BufRead */.gnupg/gpg.conf setf gpg au BufNewFile,BufRead */.gnupg/gpg.conf setf gpg
au BufNewFile,BufRead /usr/**/gnupg/options.skel setf gpg au BufNewFile,BufRead */usr/**/gnupg/options.skel setf gpg
" gnash(1) configuration files
au BufNewFile,BufRead gnashrc,.gnashrc,gnashpluginrc,.gnashpluginrc setf gnash
" Gnuplot scripts " Gnuplot scripts
au BufNewFile,BufRead *.gpi setf gnuplot au BufNewFile,BufRead *.gpi setf gnuplot
@ -919,7 +922,7 @@ au BufNewFile,BufRead *.java,*.jav setf java
au BufNewFile,BufRead *.jj,*.jjt setf javacc au BufNewFile,BufRead *.jj,*.jjt setf javacc
" JavaScript, ECMAScript " JavaScript, ECMAScript
au BufNewFile,BufRead *.js,*.javascript,*.es,*.jsx setf javascript au BufNewFile,BufRead *.js,*.javascript,*.es,*.jsx,*.json setf javascript
" Java Server Pages " Java Server Pages
au BufNewFile,BufRead *.jsp setf jsp au BufNewFile,BufRead *.jsp setf jsp
@ -934,6 +937,9 @@ au BufNewFile,BufRead *.clp setf jess
" Jgraph " Jgraph
au BufNewFile,BufRead *.jgr setf jgraph au BufNewFile,BufRead *.jgr setf jgraph
" Jovial
au BufNewFile,BufRead *.jov,*.j73,*.jovial setf jovial
" Kixtart " Kixtart
au BufNewFile,BufRead *.kix setf kix au BufNewFile,BufRead *.kix setf kix
@ -980,7 +986,7 @@ au BufNewFile,BufRead lftp.conf,.lftprc,*lftp/rc setf lftp
au BufNewFile,BufRead *.ll setf lifelines au BufNewFile,BufRead *.ll setf lifelines
" Lilo: Linux loader " Lilo: Linux loader
au BufNewFile,BufRead lilo.conf* call s:StarSetf('lilo') au BufNewFile,BufRead lilo.conf setf lilo
" Lisp (*.el = ELisp, *.cl = Common Lisp, *.jl = librep Lisp) " Lisp (*.el = ELisp, *.cl = Common Lisp, *.jl = librep Lisp)
if has("fname_case") if has("fname_case")
@ -1103,7 +1109,7 @@ au BufNewFile,BufRead *.mel setf mel
au BufNewFile,BufRead *.hgrc,*hgrc setf cfg au BufNewFile,BufRead *.hgrc,*hgrc setf cfg
" Messages (logs mostly) " Messages (logs mostly)
autocmd BufNewFile,BufRead */log/{auth,cron,daemon,debug,kern,lpr,mail,messages,news/news,syslog,user}{,.log,.err,.info,.warn,.crit,.notice}{,.*[0-9]*} setf messages au BufNewFile,BufRead */log/{auth,cron,daemon,debug,kern,lpr,mail,messages,news/news,syslog,user}{,.log,.err,.info,.warn,.crit,.notice}{,.[0-9]*,-[0-9]*} setf messages
" Metafont " Metafont
au BufNewFile,BufRead *.mf setf mf au BufNewFile,BufRead *.mf setf mf
@ -1159,11 +1165,7 @@ au BufNewFile,BufRead *.isc,*.monk,*.ssc,*.tsc setf monk
au BufNewFile,BufRead *.moo setf moo au BufNewFile,BufRead *.moo setf moo
" Modconf " Modconf
au BufNewFile,BufRead */etc/modules.conf,*/etc/modules,*/etc/conf.modules setf modconf au BufNewFile,BufRead */etc/modules.conf,*/etc/modules,*/etc/conf.modules setf modconf
au BufNewFile,BufRead */etc/modutils/*
\ if executable(expand("<afile>")) != 1
\| call s:StarSetf('modconf')
\|endif
" Mplayer config " Mplayer config
au BufNewFile,BufRead mplayer.conf,*/.mplayer/config setf mplayerconf au BufNewFile,BufRead mplayer.conf,*/.mplayer/config setf mplayerconf
@ -1180,6 +1182,9 @@ au BufNewFile,BufRead *.msql setf msql
" Mysql " Mysql
au BufNewFile,BufRead *.mysql setf mysql au BufNewFile,BufRead *.mysql setf mysql
" Mutt setup files (must be before catch *.rc)
au BufNewFile,BufRead */etc/Muttrc.d/* call s:StarSetf('muttrc')
" M$ Resource files " M$ Resource files
au BufNewFile,BufRead *.rc setf rc au BufNewFile,BufRead *.rc setf rc
@ -1583,13 +1588,17 @@ func! s:FTr()
endif endif
endfor endfor
" Nothing recognized, assume Rexx " Nothing recognized, use user default or assume Rexx
setf rexx if exists("g:filetype_r")
exe "setf " . g:filetype_r
else
" Rexx used to be the default, but R appears to be much more popular.
setf r
endif
endfunc endfunc
" Remind " Remind
au BufNewFile,BufRead .reminders* call s:StarSetf('remind') au BufNewFile,BufRead .reminders,*.remind,*.rem setf remind
au BufNewFile,BufRead *.remind,*.rem setf remind
" Resolv.conf " Resolv.conf
au BufNewFile,BufRead resolv.conf setf resolv au BufNewFile,BufRead resolv.conf setf resolv
@ -2230,7 +2239,7 @@ au BufEnter *.xpm2 setf xpm2
" XFree86 config " XFree86 config
au BufNewFile,BufRead XF86Config au BufNewFile,BufRead XF86Config
\ if getline(1) =~ '\<XConfigurator\>' | \ if getline(1) =~ '\<XConfigurator\>' |
\ let b:xf86c_xfree86_version = 3 | \ let b:xf86conf_xfree86_version = 3 |
\ endif | \ endif |
\ setf xf86conf \ setf xf86conf
au BufNewFile,BufRead */xorg.conf.d/*.conf au BufNewFile,BufRead */xorg.conf.d/*.conf
@ -2336,6 +2345,9 @@ endfunc
" Yaml " Yaml
au BufNewFile,BufRead *.yaml,*.yml setf yaml au BufNewFile,BufRead *.yaml,*.yml setf yaml
" yum conf (close enough to dosini)
au BufNewFile,BufRead */etc/yum.conf setf dosini
" Zope " Zope
" dtml (zope dynamic template markup language), pt (zope page template), " dtml (zope dynamic template markup language), pt (zope page template),
" cpt (zope form controller page template) " cpt (zope form controller page template)
@ -2386,6 +2398,11 @@ au BufNewFile,BufRead bzr_log.* setf bzr
" BIND zone " BIND zone
au BufNewFile,BufRead */named/db.*,*/bind/db.* call s:StarSetf('bindzone') au BufNewFile,BufRead */named/db.*,*/bind/db.* call s:StarSetf('bindzone')
" Calendar
au BufNewFile,BufRead */.calendar/*,
\*/share/calendar/*/calendar.*,*/share/calendar/calendar.*
\ call s:StarSetf('calendar')
" Changelog " Changelog
au BufNewFile,BufRead [cC]hange[lL]og* au BufNewFile,BufRead [cC]hange[lL]og*
\ if getline(1) =~ '; urgency=' \ if getline(1) =~ '; urgency='
@ -2397,6 +2414,9 @@ au BufNewFile,BufRead [cC]hange[lL]og*
" Crontab " Crontab
au BufNewFile,BufRead crontab,crontab.*,*/etc/cron.d/* call s:StarSetf('crontab') au BufNewFile,BufRead crontab,crontab.*,*/etc/cron.d/* call s:StarSetf('crontab')
" dnsmasq(8) configuration
au BufNewFile,BufRead */etc/dnsmasq.d/* call s:StarSetf('dnsmasq')
" Dracula " Dracula
au BufNewFile,BufRead drac.* call s:StarSetf('dracula') au BufNewFile,BufRead drac.* call s:StarSetf('dracula')
@ -2412,7 +2432,7 @@ au BufNewFile,BufRead *fvwm2rc*
\|endif \|endif
" Gedcom " Gedcom
au BufNewFile,BufRead /tmp/lltmp* call s:StarSetf('gedcom') au BufNewFile,BufRead */tmp/lltmp* call s:StarSetf('gedcom')
" GTK RC " GTK RC
au BufNewFile,BufRead .gtkrc*,gtkrc* call s:StarSetf('gtkrc') au BufNewFile,BufRead .gtkrc*,gtkrc* call s:StarSetf('gtkrc')
@ -2429,6 +2449,9 @@ au! BufNewFile,BufRead *jarg*
" Kconfig " Kconfig
au BufNewFile,BufRead Kconfig.* call s:StarSetf('kconfig') au BufNewFile,BufRead Kconfig.* call s:StarSetf('kconfig')
" Lilo: Linux loader
au BufNewFile,BufRead lilo.conf* call s:StarSetf('lilo')
" Logcheck " Logcheck
au BufNewFile,BufRead */etc/logcheck/*.d*/* call s:StarSetf('logcheck') au BufNewFile,BufRead */etc/logcheck/*.d*/* call s:StarSetf('logcheck')
@ -2442,6 +2465,10 @@ au BufNewFile,BufRead [rR]akefile* call s:StarSetf('ruby')
au BufNewFile,BufRead mutt[[:alnum:]._-]\{6\} setf mail au BufNewFile,BufRead mutt[[:alnum:]._-]\{6\} setf mail
" Modconf " Modconf
au BufNewFile,BufRead */etc/modutils/*
\ if executable(expand("<afile>")) != 1
\| call s:StarSetf('modconf')
\|endif
au BufNewFile,BufRead */etc/modprobe.* call s:StarSetf('modconf') au BufNewFile,BufRead */etc/modprobe.* call s:StarSetf('modconf')
" Mutt setup file " Mutt setup file
@ -2464,6 +2491,9 @@ au BufNewFile,BufRead *termcap*
\| let b:ptcap_type = "term" | call s:StarSetf('ptcap') \| let b:ptcap_type = "term" | call s:StarSetf('ptcap')
\|endif \|endif
" Remind
au BufNewFile,BufRead .reminders* call s:StarSetf('remind')
" Vim script " Vim script
au BufNewFile,BufRead *vimrc* call s:StarSetf('vim') au BufNewFile,BufRead *vimrc* call s:StarSetf('vim')
@ -2488,6 +2518,9 @@ au BufNewFile,BufRead *xmodmap* call s:StarSetf('xmodmap')
" Xinetd conf " Xinetd conf
au BufNewFile,BufRead */etc/xinetd.d/* call s:StarSetf('xinetd') au BufNewFile,BufRead */etc/xinetd.d/* call s:StarSetf('xinetd')
" yum conf (close enough to dosini)
au BufNewFile,BufRead */etc/yum.repos.d/* call s:StarSetf('dosini')
" Z-Shell script " Z-Shell script
au BufNewFile,BufRead zsh*,zlog* call s:StarSetf('zsh') au BufNewFile,BufRead zsh*,zlog* call s:StarSetf('zsh')

View File

@ -1,7 +1,7 @@
" Vim filetype plugin file " Vim filetype plugin file
" Language: C " Language: C
" Maintainer: Bram Moolenaar <Bram@vim.org> " Maintainer: Bram Moolenaar <Bram@vim.org>
" Last Change: 2007 Sep 25 " Last Change: 2011 Aug 04
" Only do this when not done yet for this buffer " Only do this when not done yet for this buffer
if exists("b:did_ftplugin") if exists("b:did_ftplugin")
@ -36,7 +36,7 @@ endif
" When the matchit plugin is loaded, this makes the % command skip parens and " When the matchit plugin is loaded, this makes the % command skip parens and
" braces in comments. " braces in comments.
let b:match_words = &matchpairs let b:match_words = &matchpairs . ',^\s*#\s*if\(\|def\|ndef\)\>:^\s*#\s*elif\>:^\s*#\s*else\>:^\s*#\s*endif\>'
let b:match_skip = 's:comment\|string\|character' let b:match_skip = 's:comment\|string\|character'
" Win32 can filter files in the browse dialog " Win32 can filter files in the browse dialog

View File

@ -1,7 +1,7 @@
" Vim filetype plugin file " Vim filetype plugin file
" Language: generic Changelog file " Language: generic Changelog file
" Maintainer: Nikolai Weibull <now@bitwi.se> " Maintainer: Nikolai Weibull <now@bitwi.se>
" Latest Revision: 2010-08-17 " Latest Revision: 2011-05-02
" Variables: " Variables:
" g:changelog_timeformat (deprecated: use g:changelog_dateformat instead) - " g:changelog_timeformat (deprecated: use g:changelog_dateformat instead) -
" description: the timeformat used in ChangeLog entries. " description: the timeformat used in ChangeLog entries.
@ -99,8 +99,9 @@ if &filetype == 'changelog'
function! s:try_reading_file(path) function! s:try_reading_file(path)
try try
return readfile(a:path) return readfile(a:path)
catch
return []
endtry endtry
return []
endfunction endfunction
function! s:passwd_field(line, field) function! s:passwd_field(line, field)
@ -170,7 +171,7 @@ if &filetype == 'changelog'
endfunction endfunction
" Internal function to create a new entry in the ChangeLog. " Internal function to create a new entry in the ChangeLog.
function! s:new_changelog_entry(...) function! s:new_changelog_entry()
" Deal with 'paste' option. " Deal with 'paste' option.
let save_paste = &paste let save_paste = &paste
let &paste = 1 let &paste = 1
@ -178,7 +179,7 @@ if &filetype == 'changelog'
" Look for an entry for today by our user. " Look for an entry for today by our user.
let date = strftime(g:changelog_dateformat) let date = strftime(g:changelog_dateformat)
let search = s:substitute_items(g:changelog_date_entry_search, date, let search = s:substitute_items(g:changelog_date_entry_search, date,
\ g:changelog_username) \ s:username())
if search(search) > 0 if search(search) > 0
" Ok, now we look for the end of the date entry, and add an entry. " Ok, now we look for the end of the date entry, and add an entry.
call cursor(nextnonblank(line('.') + 1), 1) call cursor(nextnonblank(line('.') + 1), 1)
@ -197,7 +198,7 @@ if &filetype == 'changelog'
" No entry today, so create a date-user header and insert an entry. " No entry today, so create a date-user header and insert an entry.
let todays_entry = s:substitute_items(g:changelog_new_date_format, let todays_entry = s:substitute_items(g:changelog_new_date_format,
\ date, g:changelog_username) \ date, s:username())
" Make sure we have a cursor positioning. " Make sure we have a cursor positioning.
if stridx(todays_entry, '{cursor}') == -1 if stridx(todays_entry, '{cursor}') == -1
let todays_entry = todays_entry . '{cursor}' let todays_entry = todays_entry . '{cursor}'

View File

@ -13,7 +13,10 @@ set cpo&vim
let b:undo_ftplugin = "setl fo< tw< cole< cocu<" let b:undo_ftplugin = "setl fo< tw< cole< cocu<"
setlocal formatoptions+=tcroql textwidth=78 cole=2 cocu=nc setlocal formatoptions+=tcroql textwidth=78
if has("conceal")
setlocal cole=2 cocu=nc
endif
let &cpo = s:cpo_save let &cpo = s:cpo_save
unlet s:cpo_save unlet s:cpo_save

View File

@ -1,7 +1,7 @@
" Vim filetype plugin file " Vim filetype plugin file
" Language: man " Language: man
" Maintainer: SungHyun Nam <goweol@gmail.com> " Maintainer: SungHyun Nam <goweol@gmail.com>
" Last Change: 2010 Nov 29 " Last Change: 2011 Jul 25
" To make the ":Man" command available before editing a manual page, source " To make the ":Man" command available before editing a manual page, source
" this script from your startup vimrc file. " this script from your startup vimrc file.
@ -17,7 +17,9 @@ if &filetype == "man"
" Ensure Vim is not recursively invoked (man-db does this) " Ensure Vim is not recursively invoked (man-db does this)
" when doing ctrl-[ on a man page reference. " when doing ctrl-[ on a man page reference.
let $MANPAGER = "" if exists("$MANPAGER")
let $MANPAGER = ""
endif
" allow dot and dash in manual page name. " allow dot and dash in manual page name.
setlocal iskeyword+=\.,- setlocal iskeyword+=\.,-

View File

@ -1,14 +1,19 @@
" Vim filetype plugin file " Vim filetype plugin file
" Language: pascal " Language: pascal
" Maintainer: Dan Sharp <dwsharp at users dot sourceforge dot net> " Maintainer: Dan Sharp <dwsharp at users dot sourceforge dot net>
" Last Changed: 20 Jan 2009 " Last Changed: 11 Apr 2011
" URL: http://dwsharp.users.sourceforge.net/vim/ftplugin " URL: http://dwsharp.users.sourceforge.net/vim/ftplugin
if exists("b:did_ftplugin") | finish | endif if exists("b:did_ftplugin") | finish | endif
let b:did_ftplugin = 1 let b:did_ftplugin = 1
if exists("loaded_matchit") if exists("loaded_matchit")
let b:match_words='\<\%(begin\|case\|try\)\>:\<end\>' let b:match_ignorecase = 1 " (pascal is case-insensitive)
let b:match_words = '\<\%(begin\|case\|record\|object\|try\)\>'
let b:match_words .= ':\<^\s*\%(except\|finally\)\>:\<end\>'
let b:match_words .= ',\<repeat\>:\<until\>'
let b:match_words .= ',\<if\>:\<else\>'
endif endif
" Undo the stuff we changed. " Undo the stuff we changed.

View File

@ -23,6 +23,7 @@
" 26-04-2002 Got initial version working reasonably well " 26-04-2002 Got initial version working reasonably well
" 29-04-2002 Fixed problems in function headers and max line width " 29-04-2002 Fixed problems in function headers and max line width
" Added support for two-line if's without curly braces " Added support for two-line if's without curly braces
" Fixed hang: 2011 Aug 31
" Only load this indent file when no other was loaded. " Only load this indent file when no other was loaded.
if exists("b:did_indent") if exists("b:did_indent")
@ -118,7 +119,7 @@ function! GetAwkIndent()
" Case 1 " Case 1
if prev_data =~ ')' && brace_balance < 0 if prev_data =~ ')' && brace_balance < 0
while brace_balance != 0 while brace_balance != 0 && prev_lineno > 0
let prev_lineno = s:Get_prev_line( prev_lineno ) let prev_lineno = s:Get_prev_line( prev_lineno )
let prev_data = getline( prev_lineno ) let prev_data = getline( prev_lineno )
let brace_balance=brace_balance+s:Get_brace_balance(prev_data,'(',')' ) let brace_balance=brace_balance+s:Get_brace_balance(prev_data,'(',')' )

View File

@ -1,7 +1,7 @@
" Vim indent file " Vim indent file
" Language: DTD (Document Type Definition for XML) " Language: DTD (Document Type Definition for XML)
" Maintainer: Nikolai Weibull <now@bitwi.se> " Maintainer: Nikolai Weibull <now@bitwi.se>
" Latest Revision: 2010-09-21 " Latest Revision: 2011-07-08
let s:cpo_save = &cpo let s:cpo_save = &cpo
set cpo&vim set cpo&vim
@ -52,7 +52,7 @@ function s:indent_to_innermost_parentheses(line, end)
let end = a:end let end = a:end
let parentheses = [end - 1] let parentheses = [end - 1]
while token != "" while token != ""
let [token, end] = s:lex(a:line, end, '^\%([(),|]\|[A-Za-z0-9_-]\+\|#PCDATA\|%[A-Za-z0-9_-]\+;\)[?*+]\=') let [token, end] = s:lex(a:line, end, '^\%([(),|]\|[A-Za-z0-9_-]\+\|#P\=CDATA\|%[A-Za-z0-9_-]\+;\)[?*+]\=')
if token[0] == '(' if token[0] == '('
call add(parentheses, end - 1) call add(parentheses, end - 1)
elseif token[0] == ')' elseif token[0] == ')'

View File

@ -1,7 +1,7 @@
" Vim indent file " Vim indent file
" Language: Fortran95 (and Fortran90, Fortran77, F and elf90) " Language: Fortran95 (and Fortran90, Fortran77, F and elf90)
" Version: 0.38 " Version: 0.39
" Last Change: 2010 July 21 " Last Change: 2011 May 30
" Maintainer: Ajit J. Thakkar <ajit@unb.ca>; <http://www.unb.ca/chem/ajit/> " Maintainer: Ajit J. Thakkar <ajit@unb.ca>; <http://www.unb.ca/chem/ajit/>
" Usage: Do :help fortran-indent from Vim " Usage: Do :help fortran-indent from Vim
@ -12,8 +12,14 @@ endif
let b:did_indent = 1 let b:did_indent = 1
setlocal indentkeys+==~end,=~case,=~if,=~else,=~do,=~where,=~elsewhere,=~select setlocal indentkeys+==~end,=~case,=~if,=~else,=~do,=~where,=~elsewhere,=~select
setlocal indentkeys+==~endif,=~enddo,=~endwhere,=~endselect setlocal indentkeys+==~endif,=~enddo,=~endwhere,=~endselect,=~elseif
setlocal indentkeys+==~type,=~interface setlocal indentkeys+==~type,=~interface,=~forall,=~associate,=~block,=~enum
setlocal indentkeys+==~endforall,=~endassociate,=~endblock,=~endenum
if exists("b:fortran_indent_more") || exists("g:fortran_indent_more")
setlocal indentkeys+==~function,=~subroutine,=~module,=~contains,=~program
setlocal indentkeys+==~endfunction,=~endsubroutine,=~endmodule
setlocal indentkeys+==~endprogram
endif
" Determine whether this is a fixed or free format source file " Determine whether this is a fixed or free format source file
" if this hasn't been done yet " if this hasn't been done yet
@ -69,6 +75,8 @@ function FortranGetIndent(lnum)
let prevline=getline(a:lnum) let prevline=getline(a:lnum)
" Strip tail comment " Strip tail comment
let prevstat=substitute(prevline, '!.*$', '', '') let prevstat=substitute(prevline, '!.*$', '', '')
let prev2line=getline(a:lnum-1)
let prev2stat=substitute(prev2line, '!.*$', '', '')
"Indent do loops only if they are all guaranteed to be of do/end do type "Indent do loops only if they are all guaranteed to be of do/end do type
if exists("b:fortran_do_enddo") || exists("g:fortran_do_enddo") if exists("b:fortran_do_enddo") || exists("g:fortran_do_enddo")
@ -80,31 +88,62 @@ function FortranGetIndent(lnum)
endif endif
endif endif
"Add a shiftwidth to statements following if, else, case, "Add a shiftwidth to statements following if, else, else if, case,
"where, elsewhere, type and interface statements "where, else where, forall, type, interface and associate statements
if prevstat =~? '^\s*\(\d\+\s\)\=\s*\(else\|case\|where\|elsewhere\)\>' if prevstat =~? '^\s*\(case\|else\|else\s*if\|else\s*where\)\>'
\ ||prevstat =~? '^\s*\(\d\+\s\)\=\s*\(type\|interface\)\>' \ ||prevstat=~? '^\s*\(type\|interface\|associate\|enum\)\>'
\ || prevstat =~? '^\s*\(\d\+\s\)\=\s*\(\a\w*\s*:\)\=\s*if\>' \ ||prevstat=~?'^\s*\(\d\+\s\)\=\s*\(\a\w*\s*:\)\=\s*\(forall\|where\|block\)\>'
\ ||prevstat=~? '^\s*\(\d\+\s\)\=\s*\(\a\w*\s*:\)\=\s*if\>'
let ind = ind + &sw let ind = ind + &sw
" Remove unwanted indent after logical and arithmetic ifs " Remove unwanted indent after logical and arithmetic ifs
if prevstat =~? '\<if\>' && prevstat !~? '\<then\>' if prevstat =~? '\<if\>' && prevstat !~? '\<then\>'
let ind = ind - &sw let ind = ind - &sw
endif endif
" Remove unwanted indent after type( statements " Remove unwanted indent after type( statements
if prevstat =~? '\<type\s*(' if prevstat =~? '^\s*type\s*('
let ind = ind - &sw let ind = ind - &sw
endif endif
endif endif
"Subtract a shiftwidth from else, elsewhere, case, end if, "Indent program units unless instructed otherwise
" end where, end select, end interface and end type statements if !exists("b:fortran_indent_less") && !exists("g:fortran_indent_less")
if getline(v:lnum) =~? '^\s*\(\d\+\s\)\=\s*' let prefix='\(\(pure\|impure\|elemental\|recursive\)\s\+\)\{,2}'
\. '\(else\|elsewhere\|case\|end\s*\(if\|where\|select\|interface\|type\)\)\>' let type='\(\(integer\|real\|double\s\+precision\|complex\|logical'
let ind = ind - &sw \.'\|character\|type\|class\)\s*\S*\s\+\)\='
" Fix indent for case statement immediately after select if prevstat =~? '^\s*\(module\|contains\|program\)\>'
if prevstat =~? '\<select\>' \ ||prevstat =~? '^\s*'.prefix.'subroutine\>'
\ ||prevstat =~? '^\s*'.prefix.type.'function\>'
\ ||prevstat =~? '^\s*'.type.prefix.'function\>'
let ind = ind + &sw let ind = ind + &sw
endif endif
if getline(v:lnum) =~? '^\s*contains\>'
\ ||getline(v:lnum)=~? '^\s*end\s*'
\ .'\(function\|subroutine\|module\|program\)\>'
let ind = ind - &sw
endif
endif
"Subtract a shiftwidth from else, else if, elsewhere, case, end if,
" end where, end select, end forall, end interface, end associate,
" end enum, and end type statements
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\)\)\>'
let ind = ind - &sw
" Fix indent for case statement immediately after select
if prevstat =~? '\<select\s\+\(case\|type\)\>'
let ind = ind + &sw
endif
endif
"First continuation line
if prevstat =~ '&\s*$' && prev2stat !~ '&\s*$'
let ind = ind + &sw
endif
"Line after last continuation line
if prevstat !~ '&\s*$' && prev2stat =~ '&\s*$'
let ind = ind - &sw
endif endif
return ind return ind

482
runtime/indent/r.vim Normal file
View File

@ -0,0 +1,482 @@
" Vim indent file
" Language: R
" Author: Jakson Alves de Aquino <jalvesaq@gmail.com>
" Last Change: Wed Aug 31, 2011 12:24AM
" Only load this indent file when no other was loaded.
if exists("b:did_r_indent")
finish
endif
let b:did_r_indent = 1
setlocal indentkeys=0{,0},:,!^F,o,O,e
setlocal indentexpr=GetRIndent()
" Only define the function once.
if exists("*GetRIndent")
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
endif
if !exists("g:r_indent_ess_comments")
let g:r_indent_ess_comments = 0
endif
if !exists("g:r_indent_comment_column")
let g:r_indent_comment_column = 40
endif
if ! exists("g:r_indent_ess_compatible")
let g:r_indent_ess_compatible = 0
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 += 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
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
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
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
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
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 data = getline( lnum )
while lnum > 0 && (data =~ '^\s*#' || data =~ '^\s*$')
let lnum = lnum - 1
let data = getline( 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
endfunction
function GetRIndent()
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
return 0
endif
let line = SanitizeRLine(getline(lnum))
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
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
endif
" 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 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
endif
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
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
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 ind == pind || (ind == (pind + &sw) && pline =~ '{$' && ppost_else == 0)
return ind
endif
while pind < ind && plnum > 0 && ppb == 0
let ind = pind
let plnum = s:Get_prev_line(plnum)
let pline = getline(plnum)
let ppb = 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, '(', ')')
endwhile
let pind = indent(plnum)
if ind == (pind + &sw) && pline =~ '{$'
return ind
endif
endwhile
return ind
endfunction
" vim: sw=4

View File

@ -1,7 +1,7 @@
" Vim indent file " Vim indent file
" Language: reStructuredText Documentation Format " Language: reStructuredText Documentation Format
" Maintainer: Nikolai Weibull <now@bitwi.se> " Maintainer: Nikolai Weibull <now@bitwi.se>
" Latest Revision: 2006-12-20 " Latest Revision: 2011-08-03
if exists("b:did_indent") if exists("b:did_indent")
finish finish
@ -16,6 +16,9 @@ if exists("*GetRSTIndent")
finish finish
endif endif
let s:itemization_pattern = '^\s*[-*+]\s'
let s:enumeration_pattern = '^\s*\%(\d\+\|#\)\.\s\+'
function GetRSTIndent() function GetRSTIndent()
let lnum = prevnonblank(v:lnum - 1) let lnum = prevnonblank(v:lnum - 1)
if lnum == 0 if lnum == 0
@ -25,27 +28,30 @@ function GetRSTIndent()
let ind = indent(lnum) let ind = indent(lnum)
let line = getline(lnum) let line = getline(lnum)
if line =~ '^\s*[-*+]\s' if line =~ s:itemization_pattern
let ind = ind + 2 let ind += 2
elseif line =~ '^\s*\d\+.\s' elseif line =~ s:enumeration_pattern
let ind = ind + matchend(substitute(line, '^\s*', '', ''), '\d\+.\s\+') let ind += matchend(line, s:enumeration_pattern)
endif endif
let line = getline(v:lnum - 1) let line = getline(v:lnum - 1)
" Indent :FIELD: lines. Dont match if there is no text after the field or
" if the text ends with a sent-ender.
if line =~ '^:.\+:\s\{-1,\}\S.\+[^.!?:]$'
return matchend(line, '^:.\{-1,}:\s\+')
endif
if line =~ '^\s*$' if line =~ '^\s*$'
execute lnum execute lnum
call search('^\s*\%([-*+]\s\|\d\+.\s\|\.\.\|$\)', 'bW') call search('^\s*\%([-*+]\s\|\%(\d\+\|#\)\.\s\|\.\.\|$\)', 'bW')
let line = getline('.') let line = getline('.')
if line =~ '^\s*[-*+]' if line =~ s:itemization_pattern
let ind = ind - 2 let ind -= 2
elseif line =~ '^\s*\d\+\.\s' elseif line =~ s:enumeration_pattern
let ind = ind - matchend(substitute(line, '^\s*', '', ''), let ind -= matchend(line, s:enumeration_pattern)
\ '\d\+\.\s\+')
elseif line =~ '^\s*\.\.' elseif line =~ '^\s*\.\.'
let ind = ind - 3 let ind -= 3
else
let ind = ind
endif endif
endif endif

View File

@ -1,7 +1,7 @@
" These commands create the option window. " These commands create the option window.
" "
" Maintainer: Bram Moolenaar <Bram@vim.org> " Maintainer: Bram Moolenaar <Bram@vim.org>
" Last Change: 2010 Dec 02 " Last Change: 2011 Jun 13
" If there already is an option window, jump to that one. " If there already is an option window, jump to that one.
if bufwinnr("option-window") > 0 if bufwinnr("option-window") > 0
@ -10,7 +10,7 @@ if bufwinnr("option-window") > 0
if @% == "option-window" if @% == "option-window"
finish finish
endif endif
exe "norm! \<C-W>w" wincmd w
if s:thiswin == winnr() if s:thiswin == winnr()
break break
endif endif
@ -26,12 +26,8 @@ set cpo&vim
fun! <SID>CR() fun! <SID>CR()
" If on a continued comment line, go back to the first comment line " If on a continued comment line, go back to the first comment line
let lnum = line(".") let lnum = search("^[^\t]", 'bWcn')
let line = getline(lnum) let line = getline(lnum)
while line[0] == "\t"
let lnum = lnum - 1
let line = getline(lnum)
endwhile
" <CR> on a "set" line executes the option line " <CR> on a "set" line executes the option line
if match(line, "^ \tset ") >= 0 if match(line, "^ \tset ") >= 0
@ -82,11 +78,11 @@ fun! <SID>Find(lnum)
if getline(a:lnum - 1) =~ "(local to" if getline(a:lnum - 1) =~ "(local to"
let local = 1 let local = 1
let thiswin = winnr() let thiswin = winnr()
exe "norm! \<C-W>p" wincmd p
if exists("b:current_syntax") && b:current_syntax == "help" if exists("b:current_syntax") && b:current_syntax == "help"
exe "norm! \<C-W>j" wincmd j
if winnr() == thiswin if winnr() == thiswin
exe "norm! \<C-W>j" wincmd j
endif endif
endif endif
else else
@ -111,10 +107,10 @@ fun! <SID>Update(lnum, line, local, thiswin)
if name == "pt" && &pt =~ "\x80" if name == "pt" && &pt =~ "\x80"
let val = <SID>PTvalue() let val = <SID>PTvalue()
else else
exe "let val = substitute(&" . name . ', "[ \\t\\\\\"|]", "\\\\\\0", "g")' let val = escape(eval('&' . name), " \t\\\"|")
endif endif
if a:local if a:local
exe "norm! " . a:thiswin . "\<C-W>w" exe a:thiswin . "wincmd w"
endif endif
if match(a:line, "=") >= 0 || (val != "0" && val != "1") if match(a:line, "=") >= 0 || (val != "0" && val != "1")
call setline(a:lnum, " \tset " . name . "=" . val) call setline(a:lnum, " \tset " . name . "=" . val)
@ -139,7 +135,7 @@ set notitle noicon nosc noru
" Relies on syntax highlighting to be switched on. " Relies on syntax highlighting to be switched on.
let s:thiswin = winnr() let s:thiswin = winnr()
while exists("b:current_syntax") && b:current_syntax == "help" while exists("b:current_syntax") && b:current_syntax == "help"
exe "norm! \<C-W>w" wincmd w
if s:thiswin == winnr() if s:thiswin == winnr()
break break
endif endif
@ -147,7 +143,7 @@ endwhile
" Open the window " Open the window
new option-window new option-window
setlocal ts=15 tw=0 noro setlocal ts=15 tw=0 noro buftype=nofile
" Insert help and a "set" command for each option. " Insert help and a "set" command for each option.
call append(0, '" Each "set" line shows the current value of an option (on the left).') call append(0, '" Each "set" line shows the current value of an option (on the left).')
@ -162,9 +158,7 @@ call append(6, '" Hit <Space> on a "set" line to refresh it.')
" Init a local binary option " Init a local binary option
fun! <SID>BinOptionL(name) fun! <SID>BinOptionL(name)
exe "norm! \<C-W>p" let val = getwinvar(winnr('#'), '&' . a:name)
exe "let val = &" . a:name
exe "norm! \<C-W>p"
call append("$", substitute(substitute(" \tset " . val . a:name . "\t" . call append("$", substitute(substitute(" \tset " . val . a:name . "\t" .
\!val . a:name, "0", "no", ""), "1", "", "")) \!val . a:name, "0", "no", ""), "1", "", ""))
endfun endfun
@ -177,16 +171,13 @@ endfun
" Init a local string option " Init a local string option
fun! <SID>OptionL(name) fun! <SID>OptionL(name)
exe "norm! \<C-W>p" let val = escape(getwinvar(winnr('#'), '&' . a:name), " \t\\\"|")
exe "let val = substitute(&" . a:name . ', "[ \\t\\\\\"|]", "\\\\\\0", "g")'
exe "norm! \<C-W>p"
call append("$", " \tset " . a:name . "=" . val) call append("$", " \tset " . a:name . "=" . val)
endfun endfun
" Init a global string option " Init a global string option
fun! <SID>OptionG(name, val) fun! <SID>OptionG(name, val)
call append("$", " \tset " . a:name . "=" . substitute(a:val, '[ \t\\"|]', call append("$", " \tset " . a:name . "=" . escape(a:val, " \t\\\"|"))
\ '\\\0', "g"))
endfun endfun
let s:idx = 1 let s:idx = 1
@ -315,6 +306,8 @@ if has("cscope")
call append("$", " \tset cspc=" . &cspc) call append("$", " \tset cspc=" . &cspc)
call append("$", "cscopequickfix\twhen to open a quickfix window for cscope") call append("$", "cscopequickfix\twhen to open a quickfix window for cscope")
call <SID>OptionG("csqf", &csqf) call <SID>OptionG("csqf", &csqf)
call append("$", "cscoperelative\tfile names in a cscope file are relative to that file")
call <SID>BinOptionG("csre", &csre)
endif endif
@ -1342,3 +1335,5 @@ let &ru = s:old_ru
let &sc = s:old_sc let &sc = s:old_sc
let &cpo = s:cpo_save let &cpo = s:cpo_save
unlet s:old_title s:old_icon s:old_ru s:old_sc s:cpo_save s:idx s:lnum unlet s:old_title s:old_icon s:old_ru s:old_sc s:cpo_save s:idx s:lnum
" vim: ts=8 sw=2 sts=2

View File

@ -19,7 +19,7 @@ if &cp || exists("g:loaded_getscriptPlugin")
endif endif
finish finish
endif endif
let g:loaded_getscriptPlugin = "v32" let g:loaded_getscriptPlugin = "v33"
let s:keepcpo = &cpo let s:keepcpo = &cpo
set cpo&vim set cpo&vim

View File

@ -1,6 +1,6 @@
" Vim plugin for showing matching parens " Vim plugin for showing matching parens
" Maintainer: Bram Moolenaar <Bram@vim.org> " Maintainer: Bram Moolenaar <Bram@vim.org>
" Last Change: 2010 Nov 16 " Last Change: 2011 Aug 27
" Exit quickly when: " Exit quickly when:
" - this plugin was already loaded (or disabled) " - this plugin was already loaded (or disabled)
@ -82,7 +82,7 @@ function! s:Highlight_Matching_Pair()
endif endif
" When not in a string or comment ignore matches inside them. " When not in a string or comment ignore matches inside them.
" We match "escape" for special items, such as listpEscapeSpecial. " We match "escape" for special items, such as lispEscapeSpecial.
let s_skip ='synIDattr(synID(line("."), col("."), 0), "name") ' . let s_skip ='synIDattr(synID(line("."), col("."), 0), "name") ' .
\ '=~? "string\\|character\\|singlequote\\|escape\\|comment"' \ '=~? "string\\|character\\|singlequote\\|escape\\|comment"'
execute 'if' s_skip '| let s_skip = 0 | endif' execute 'if' s_skip '| let s_skip = 0 | endif'

View File

@ -20,7 +20,7 @@
if &cp || exists("g:loaded_netrwPlugin") if &cp || exists("g:loaded_netrwPlugin")
finish finish
endif endif
let g:loaded_netrwPlugin = "v141" let g:loaded_netrwPlugin = "v142"
if v:version < 702 if v:version < 702
echohl WarningMsg | echo "***netrw*** you need vim version 7.2 for this version of netrw" | echohl None echohl WarningMsg | echo "***netrw*** you need vim version 7.2 for this version of netrw" | echohl None
finish finish

View File

@ -14,7 +14,7 @@
if &cp || exists("g:loaded_tarPlugin") if &cp || exists("g:loaded_tarPlugin")
finish finish
endif endif
let g:loaded_tarPlugin = "v26" let g:loaded_tarPlugin = "v27"
let s:keepcpo = &cpo let s:keepcpo = &cpo
set cpo&vim set cpo&vim

View File

@ -1,11 +1,20 @@
" Vim plugin for converting a syntax highlighted file to HTML. " Vim plugin for converting a syntax highlighted file to HTML.
" Maintainer: Ben Fritz <fritzophrenic@gmail.com> " Maintainer: Ben Fritz <fritzophrenic@gmail.com>
" Last Change: 2011 Jan 06 " Last Change: 2011 May 26
" "
" The core of the code is in $VIMRUNTIME/autoload/tohtml.vim and " The core of the code is in $VIMRUNTIME/autoload/tohtml.vim and
" $VIMRUNTIME/syntax/2html.vim " $VIMRUNTIME/syntax/2html.vim
" "
" TODO: " TODO:
" * Options for generating the CSS in external style sheets. New :TOcss
" command to convert the current color scheme into a (mostly) generic CSS
" stylesheet which can be re-used. Alternate stylesheet support?
" * Pull in code from http://www.vim.org/scripts/script.php?script_id=3113 :
" - listchars support
" - full-line background highlight
" - other?
" * Font auto-detection similar to
" http://www.vim.org/scripts/script.php?script_id=2384
" * Explicitly trigger IE8+ Standards Mode? " * Explicitly trigger IE8+ Standards Mode?
" * Make it so deleted lines in a diff don't create side-scrolling " * Make it so deleted lines in a diff don't create side-scrolling
" * Restore open/closed folds and cursor position after processing each file " * Restore open/closed folds and cursor position after processing each file
@ -17,51 +26,61 @@
" buffer before we're done (5000 or so lines should do it) " buffer before we're done (5000 or so lines should do it)
" * TODO comments for code cleanup scattered throughout " * TODO comments for code cleanup scattered throughout
" "
"
" Changelog:
" 7.3_v8 (this version): Add html_expand_tabs option to allow leaving tab
" characters in generated output (Andy Spencer). Escape
" text that looks like a modeline so Vim doesn't use
" anything in the converted HTML as a modeline.
" Bugfixes: Fix folding when a fold starts before the
" conversion range. Remove fold column when there are
" no folds.
" 7.3_v7 (840c3cadb842): see betas released on vim_dev below:
" 7.3_v7b3: Fixed bug, convert Unicode to UTF-8 all the way.
" 7.3_v7b2: Remove automatic detection of encodings that are not
" supported by all major browsers according to
" http://wiki.whatwg.org/wiki/Web_Encodings and convert
" to UTF-8 for all Unicode encodings. Make HTML
" encoding to Vim encoding detection be
" case-insensitive for built-in pairs.
" 7.3_v7b1: Remove use of setwinvar() function which cannot be
" called in restricted mode (Andy Spencer). Use
" 'fencoding' instead of 'encoding' to determine by
" charset, and make sure the 'fenc' of the generated
" file matches its indicated charset. Add charsets for
" all of Vim's natively supported encodings.
" 7.3_v6 (0d3f0e3d289b): Really fix bug with 'nowrapscan', 'magic' and other
" user settings interfering with diff mode generation,
" trailing whitespace (e.g. line number column) when
" using html_no_pre, and bugs when using
" html_hover_unfold.
" 7.3_v5 ( unreleased ): Fix bug with 'nowrapscan' and also with out-of-sync
" folds in diff mode when first line was folded.
" 7.3_v4 (7e008c174cc3): Bugfixes, especially for xhtml markup, and diff mode.
" 7.3_v3 (a29075150aee): Refactor option handling and make html_use_css
" default to true when not set to anything. Use strict
" doctypes where possible. Rename use_xhtml option to
" html_use_xhtml for consistency. Use .xhtml extension
" when using this option. Add meta tag for settings.
" 7.3_v2 (80229a724a11): Fix syntax highlighting in diff mode to use both the
" diff colors and the normal syntax colors
" 7.3_v1 (e7751177126b): Add conceal support and meta tags in output
" Pre-v1 baseline: Mercurial changeset 3c9324c0800e
if exists('g:loaded_2html_plugin') if exists('g:loaded_2html_plugin')
finish finish
endif endif
let g:loaded_2html_plugin = 'vim7.3_v8' let g:loaded_2html_plugin = 'vim7.3_v10'
"
" Changelog:
" 7.3_v10 (this version): Fix error E684 when converting a range wholly inside
" multiple nested folds with dynamic folding on.
" Also fix problem with foldtext in this situation.
" 7.3_v9 (0877b8d6370e): Add html_pre_wrap option active with html_use_css
" and without html_no_pre, default value same as
" 'wrap' option, (Andy Spencer). Don't use
" 'fileencoding' for converted document encoding if
" 'buftype' indicates a special buffer which isn't
" written.
" 7.3_v8 (85c5a72551e2): Add html_expand_tabs option to allow leaving tab
" characters in generated output (Andy Spencer).
" Escape text that looks like a modeline so Vim
" doesn't use anything in the converted HTML as a
" modeline. Bugfixes: Fix folding when a fold starts
" before the conversion range. Remove fold column when
" there are no folds.
" 7.3_v7 (840c3cadb842): see betas released on vim_dev below:
" 7.3_v7b3: Fixed bug, convert Unicode to UTF-8 all the way.
" 7.3_v7b2: Remove automatic detection of encodings that are not
" supported by all major browsers according to
" http://wiki.whatwg.org/wiki/Web_Encodings and
" convert to UTF-8 for all Unicode encodings. Make
" HTML encoding to Vim encoding detection be
" case-insensitive for built-in pairs.
" 7.3_v7b1: Remove use of setwinvar() function which cannot be
" called in restricted mode (Andy Spencer). Use
" 'fencoding' instead of 'encoding' to determine by
" charset, and make sure the 'fenc' of the generated
" file matches its indicated charset. Add charsets for
" all of Vim's natively supported encodings.
" 7.3_v6 (0d3f0e3d289b): Really fix bug with 'nowrapscan', 'magic' and other
" user settings interfering with diff mode generation,
" trailing whitespace (e.g. line number column) when
" using html_no_pre, and bugs when using
" html_hover_unfold.
" 7.3_v5 ( unreleased ): Fix bug with 'nowrapscan' and also with out-of-sync
" folds in diff mode when first line was folded.
" 7.3_v4 (7e008c174cc3): Bugfixes, especially for xhtml markup, and diff mode
" 7.3_v3 (a29075150aee): Refactor option handling and make html_use_css
" default to true when not set to anything. Use strict
" doctypes where possible. Rename use_xhtml option to
" html_use_xhtml for consistency. Use .xhtml extension
" when using this option. Add meta tag for settings.
" 7.3_v2 (80229a724a11): Fix syntax highlighting in diff mode to use both the
" diff colors and the normal syntax colors
" 7.3_v1 (e7751177126b): Add conceal support and meta tags in output
" Pre-v1 baseline: Mercurial changeset 3c9324c0800e
" Define the :TOhtml command when: " Define the :TOhtml command when:
" - 'compatible' is not set " - 'compatible' is not set

View File

@ -16,18 +16,22 @@
if &cp || exists("g:loaded_vimballPlugin") if &cp || exists("g:loaded_vimballPlugin")
finish finish
endif endif
let g:loaded_vimballPlugin = "v31" let g:loaded_vimballPlugin = "v33"
let s:keepcpo = &cpo let s:keepcpo = &cpo
set cpo&vim set cpo&vim
" ------------------------------------------------------------------------------ " ------------------------------------------------------------------------------
" Public Interface: {{{1 " Public Interface: {{{1
com! -ra -complete=file -na=+ -bang MkVimball call vimball#MkVimball(<line1>,<line2>,<bang>0,<f-args>) com! -ra -complete=file -na=+ -bang MkVimball call vimball#MkVimball(<line1>,<line2>,<bang>0,<f-args>)
com! -na=? -complete=dir UseVimball call vimball#Vimball(1,<f-args>) com! -na=? -complete=dir UseVimball call vimball#Vimball(1,<f-args>)
com! -na=0 VimballList call vimball#Vimball(0) com! -na=0 VimballList call vimball#Vimball(0)
com! -na=* -complete=dir RmVimball call vimball#SaveSettings()|call vimball#RmVimball(<f-args>)|call vimball#RestoreSettings() com! -na=* -complete=dir RmVimball call vimball#SaveSettings()|call vimball#RmVimball(<f-args>)|call vimball#RestoreSettings()
au SourceCmd *.vba.gz,*.vba.bz2,*.vba.zip call vimball#Decompress(expand("<amatch>"))|call vimball#Vimball(1) au BufEnter *.vba,*.vba.gz,*.vba.bz2,*.vba.zip,*.vba.xz setlocal bt=nofile fmr=[[[,]]] fdm=marker|if &ff != 'unix'|setlocal ma ff=unix noma|endif|call vimball#ShowMesg(0,"Source this file to extract it! (:so %)")
au BufEnter *.vba,*.vba.gz,*.vba.bz2,*.vba.zip setlocal bt=nofile fmr=[[[,]]] fdm=marker|if &ff != 'unix'| setlocal ma ff=unix noma |endif|call vimball#ShowMesg(0,"Source this file to extract it! (:so %)") au SourceCmd *.vba.gz,*.vba.bz2,*.vba.zip,*.vba.xz if expand("%")!=expand("<afile>") | exe "1sp" fnameescape(expand("<afile>"))|endif|call vimball#Decompress(expand("<amatch>"))|so %|if expand("%")!=expand("<afile>")|close|endif
au SourceCmd *.vba if expand("%")!=expand("<afile>") | exe "1sp" fnameescape(expand("<afile>"))|call vimball#Vimball(1)|close|else|call vimball#Vimball(1)|endif
au BufEnter *.vmb,*.vmb.gz,*.vmb.bz2,*.vmb.zip,*.vmb.xz setlocal bt=nofile fmr=[[[,]]] fdm=marker|if &ff != 'unix'|setlocal ma ff=unix noma|endif|call vimball#ShowMesg(0,"Source this file to extract it! (:so %)")
au SourceCmd *.vmb.gz,*.vmb.bz2,*.vmb.zip,*.vmb.xz if expand("%")!=expand("<afile>") | exe "1sp" fnameescape(expand("<afile>"))|endif|call vimball#Decompress(expand("<amatch>"))|so %|if expand("%")!=expand("<afile>")|close|endif
au SourceCmd *.vmb if expand("%")!=expand("<afile>") | exe "1sp" fnameescape(expand("<afile>"))|call vimball#Vimball(1)|close|else|call vimball#Vimball(1)|endif
" ===================================================================== " =====================================================================
" Restoration And Modelines: {{{1 " Restoration And Modelines: {{{1

View File

@ -20,7 +20,7 @@
if &cp || exists("g:loaded_zipPlugin") if &cp || exists("g:loaded_zipPlugin")
finish finish
endif endif
let g:loaded_zipPlugin = "v23" let g:loaded_zipPlugin = "v24"
let s:keepcpo = &cpo let s:keepcpo = &cpo
set cpo&vim set cpo&vim
@ -40,7 +40,7 @@ augroup zip
au FileWriteCmd zipfile:*/* call zip#Write(expand("<amatch>")) au FileWriteCmd zipfile:*/* call zip#Write(expand("<amatch>"))
endif endif
au BufReadCmd *.zip,*.jar,*.xpi,*.war,*.ear call zip#Browse(expand("<amatch>")) au BufReadCmd *.zip,*.jar,*.xpi,*.war,*.ear,*.celzip call zip#Browse(expand("<amatch>"))
augroup END augroup END
" --------------------------------------------------------------------- " ---------------------------------------------------------------------

View File

@ -1,6 +1,6 @@
" Vim syntax support file " Vim syntax support file
" Maintainer: Ben Fritz <fritzophrenic@gmail.com> " Maintainer: Ben Fritz <fritzophrenic@gmail.com>
" Last Change: 2011 Jan 06 " Last Change: 2011 May 27
" "
" Additional contributors: " Additional contributors:
" "
@ -33,6 +33,13 @@ endif
let s:settings = tohtml#GetUserSettings() let s:settings = tohtml#GetUserSettings()
" Whitespace
if s:settings.pre_wrap
let s:whitespace = "white-space: pre-wrap; "
else
let s:whitespace = ""
endif
" When not in gui we can only guess the colors. " When not in gui we can only guess the colors.
if has("gui_running") if has("gui_running")
let s:whatterm = "gui" let s:whatterm = "gui"
@ -628,11 +635,22 @@ if s:settings.dynamic_folds
" close all folds again so we can get the fold text as we go " close all folds again so we can get the fold text as we go
silent! %foldclose! silent! %foldclose!
" Go through and remove folds we don't need to (or cannot) process in the
" current conversion range
"
" If a fold is removed which contains other folds, which are included, we need
" to adjust the level of the included folds as used by the conversion logic
" (avoiding special cases is good)
"
" Note any time we remove a fold, either all of the included folds are in it,
" or none of them, because we only remove a fold if neither its start nor its
" end are within the conversion range.
let leveladjust = 0
for afold in s:allfolds for afold in s:allfolds
let removed = 0 let removed = 0
if exists("g:html_start_line") && exists("g:html_end_line") if exists("g:html_start_line") && exists("g:html_end_line")
if afold.firstline < g:html_start_line if afold.firstline < g:html_start_line
if afold.lastline < g:html_end_line && afold.lastline > g:html_start_line if afold.lastline <= g:html_end_line && afold.lastline >= g:html_start_line
" if a fold starts before the range to convert but stops within the " if a fold starts before the range to convert but stops within the
" range, we need to include it. Make it start on the first converted " range, we need to include it. Make it start on the first converted
" line. " line.
@ -642,6 +660,9 @@ if s:settings.dynamic_folds
" the entire range, don't bother parsing it " the entire range, don't bother parsing it
call remove(s:allfolds, index(s:allfolds, afold)) call remove(s:allfolds, index(s:allfolds, afold))
let removed = 1 let removed = 1
if afold.lastline > g:html_end_line
let leveladjust += 1
endif
endif endif
elseif afold.firstline > g:html_end_line elseif afold.firstline > g:html_end_line
" If the entire fold lies outside the range we need to remove it. " If the entire fold lies outside the range we need to remove it.
@ -664,11 +685,23 @@ if s:settings.dynamic_folds
endif endif
endif endif
if !removed if !removed
let afold.level -= leveladjust
if afold.level+1 > s:foldcolumn if afold.level+1 > s:foldcolumn
let s:foldcolumn = afold.level+1 let s:foldcolumn = afold.level+1
endif endif
endif endif
endfor endfor
" if we've removed folds containing the conversion range from processing,
" getting foldtext as we go won't know to open the removed folds, so the
" foldtext would be wrong; open them now.
"
" Note that only when a start and an end line is specified will a fold
" containing the current range ever be removed.
while leveladjust > 0
exe g:html_start_line."foldopen"
let leveladjust -= 1
endwhile
endif endif
" Now loop over all lines in the original text to convert to html. " Now loop over all lines in the original text to convert to html.
@ -1048,10 +1081,14 @@ if s:settings.use_css
if s:settings.no_pre if s:settings.no_pre
execute "normal! A\nbody { color: " . s:fgc . "; background-color: " . s:bgc . "; font-family: ". s:htmlfont ."; }\e" execute "normal! A\nbody { color: " . s:fgc . "; background-color: " . s:bgc . "; font-family: ". s:htmlfont ."; }\e"
else else
execute "normal! A\npre { font-family: ". s:htmlfont ."; color: " . s:fgc . "; background-color: " . s:bgc . "; }\e" execute "normal! A\npre { " . s:whitespace . "font-family: ". s:htmlfont ."; color: " . s:fgc . "; background-color: " . s:bgc . "; }\e"
yank yank
put put
execute "normal! ^cwbody\e" execute "normal! ^cwbody\e"
" body should not have the wrap formatting, only the pre section
if s:whitespace != ''
exec 's#'.s:whitespace
endif
endif endif
else else
execute '%s:<body>:<body bgcolor="' . s:bgc . '" text="' . s:fgc . '">\r<font face="'. s:htmlfont .'">' execute '%s:<body>:<body bgcolor="' . s:bgc . '" text="' . s:fgc . '">\r<font face="'. s:htmlfont .'">'
@ -1160,7 +1197,7 @@ let &l:winfixheight = s:old_winfixheight
let &ls=s:ls let &ls=s:ls
" Save a little bit of memory (worth doing?) " Save a little bit of memory (worth doing?)
unlet s:htmlfont unlet s:htmlfont s:whitespace
unlet s:old_et s:old_paste s:old_icon s:old_report s:old_title s:old_search unlet s:old_et s:old_paste s:old_icon s:old_report s:old_title s:old_search
unlet s:old_magic s:old_more s:old_fdm s:old_fen s:old_winheight unlet s:old_magic s:old_more s:old_fdm s:old_fen s:old_winheight
unlet! s:old_isprint unlet! s:old_isprint

View File

@ -2,8 +2,8 @@
" Language: automake Makefile.am " Language: automake Makefile.am
" Maintainer: Debian VIM Maintainers <pkg-vim-maintainers@lists.alioth.debian.org> " Maintainer: Debian VIM Maintainers <pkg-vim-maintainers@lists.alioth.debian.org>
" Former Maintainer: John Williams <jrw@pobox.com> " Former Maintainer: John Williams <jrw@pobox.com>
" Last Change: 2007-10-14 " Last Change: 2011-06-13
" URL: http://git.debian.org/?p=pkg-vim/vim.git;a=blob_plain;f=runtime/syntax/automake.vim;hb=debian " URL: http://anonscm.debian.org/hg/pkg-vim/vim/raw-file/unstable/runtime/syntax/automake.vim
" "
" XXX This file is in need of a new maintainer, Debian VIM Maintainers maintain " XXX This file is in need of a new maintainer, Debian VIM Maintainers maintain
" it only because patches have been submitted for it by Debian users and the " it only because patches have been submitted for it by Debian users and the
@ -17,6 +17,12 @@
" when they are used in an inappropriate place, such as in defining " when they are used in an inappropriate place, such as in defining
" EXTRA_SOURCES. " EXTRA_SOURCES.
" Standard syntax initialization
if version < 600
syntax clear
elseif exists("b:current_syntax")
finish
endif
" Read the Makefile syntax to start with " Read the Makefile syntax to start with
if version < 600 if version < 600
@ -25,27 +31,28 @@ else
runtime! syntax/make.vim runtime! syntax/make.vim
endif endif
syn match automakePrimary "^[A-Za-z0-9_]\+\(_PROGRAMS\|LIBRARIES\|_LIST\|_SCRIPTS\|_DATA\|_HEADERS\|_MANS\|_TEXINFOS\|_JAVA\|_LTLIBRARIES\)\s*="me=e-1 syn match automakePrimary "^\w\+\(_PROGRAMS\|_LIBRARIES\|_LISP\|_PYTHON\|_JAVA\|_SCRIPTS\|_DATA\|_HEADERS\|_MANS\|_TEXINFOS\|_LTLIBRARIES\)\s*\ze+\=="
syn match automakePrimary "^TESTS\s*="me=e-1 syn match automakePrimary "^TESTS\s*\ze+\=="me=e-1
syn match automakeSecondary "^[A-Za-z0-9_]\+\(_SOURCES\|_LDADD\|_LIBADD\|_LDFLAGS\|_DEPENDENCIES\|_CPPFLAGS\)\s*="me=e-1 syn match automakeSecondary "^\w\+\(_SOURCES\|_LIBADD\|_LDADD\|_LDFLAGS\|_DEPENDENCIES\|_AR\|_CCASFLAGS\|_CFLAGS\|_CPPFLAGS\|_CXXFLAGS\|_FCFLAGS\|_FFLAGS\|_GCJFLAGS\|_LFLAGS\|_LIBTOOLFLAGS\|OBJCFLAGS\|RFLAGS\|UPCFLAGS\|YFLAGS\)\s*\ze+\=="
syn match automakeSecondary "^OMIT_DEPENDENCIES\s*="me=e-1 syn match automakeSecondary "^\(LDADD\|ARFLAGS\|OMIT_DEPENDENCIES\|AM_MAKEFLAGS\|\(AM_\)\=\(MAKEINFOFLAGS\|RUNTESTDEFAULTFLAGS\|ETAGSFLAGS\|CTAGSFLAGS\|JAVACFLAGS\)\)\s*\ze+\=="
syn match automakeExtra "^EXTRA_[A-Za-z0-9_]\+\s*="me=e-1 syn match automakeExtra "^EXTRA_\w\+\s*\ze+\=="
syn match automakeOptions "^\(AUTOMAKE_OPTIONS\|ETAGS_ARGS\|TAGS_DEPENDENCIES\)\s*="me=e-1 syn match automakeOptions "^\(ACLOCAL_AMFLAGS\|AUTOMAKE_OPTIONS\|DISTCHECK_CONFIGURE_FLAGS\|ETAGS_ARGS\|TAGS_DEPENDENCIES\)\s*\ze+\=="
syn match automakeClean "^\(MOSTLY\|DIST\|MAINTAINER\)\=CLEANFILES\s*="me=e-1 syn match automakeClean "^\(MOSTLY\|DIST\|MAINTAINER\)\=CLEANFILES\s*\ze+\=="
syn match automakeSubdirs "^\(DIST_\)\=SUBDIRS\s*="me=e-1 syn match automakeSubdirs "^\(DIST_\)\=SUBDIRS\s*\ze+\=="
syn match automakeConditional "^\(if\s*[a-zA-Z0-9_]\+\|else\|endif\)\s*$" syn match automakeConditional "^\(if\s*!\=\w\+\|else\|endif\)\s*$"
syn match automakeSubst "@[a-zA-Z0-9_]\+@" syn match automakeSubst "@\w\+@"
syn match automakeSubst "^\s*@[a-zA-Z0-9_]\+@" syn match automakeSubst "^\s*@\w\+@"
syn match automakeComment1 "#.*$" contains=automakeSubst syn match automakeComment1 "#.*$" contains=automakeSubst
syn match automakeComment2 "##.*$" syn match automakeComment2 "##.*$"
syn match automakeMakeError "$[{(][^})]*[^a-zA-Z0-9_})][^})]*[})]" " GNU make function call syn match automakeMakeError "$[{(][^})]*[^a-zA-Z0-9_})][^})]*[})]" " GNU make function call
syn match automakeMakeError "^AM_LDADD\s*\ze+\==" " Common mistake
syn region automakeNoSubst start="^EXTRA_[a-zA-Z0-9_]*\s*=" end="$" contains=ALLBUT,automakeNoSubst transparent syn region automakeNoSubst start="^EXTRA_\w*\s*+\==" end="$" contains=ALLBUT,automakeNoSubst transparent
syn region automakeNoSubst start="^DIST_SUBDIRS\s*=" end="$" contains=ALLBUT,automakeNoSubst transparent syn region automakeNoSubst start="^DIST_SUBDIRS\s*+\==" end="$" contains=ALLBUT,automakeNoSubst transparent
syn region automakeNoSubst start="^[a-zA-Z0-9_]*_SOURCES\s*=" end="$" contains=ALLBUT,automakeNoSubst transparent syn region automakeNoSubst start="^\w*_SOURCES\s*+\==" end="$" contains=ALLBUT,automakeNoSubst transparent
syn match automakeBadSubst "@\([a-zA-Z0-9_]*@\=\)\=" contained syn match automakeBadSubst "@\(\w*@\=\)\=" contained
syn region automakeMakeDString start=+"+ skip=+\\"+ end=+"+ contains=makeIdent,automakeSubstitution syn region automakeMakeDString start=+"+ skip=+\\"+ end=+"+ contains=makeIdent,automakeSubstitution
syn region automakeMakeSString start=+'+ skip=+\\'+ end=+'+ contains=makeIdent,automakeSubstitution syn region automakeMakeSString start=+'+ skip=+\\'+ end=+'+ contains=makeIdent,automakeSubstitution

View File

@ -2,7 +2,7 @@
" Language: BibTeX (bibliographic database format for (La)TeX) " Language: BibTeX (bibliographic database format for (La)TeX)
" Maintainer: Bernd Feige <Bernd.Feige@gmx.net> " Maintainer: Bernd Feige <Bernd.Feige@gmx.net>
" Filenames: *.bib " Filenames: *.bib
" Last Change: Aug 02, 2005 " Last Change: Mar 23, 2011
" Thanks to those who pointed out problems with this file or supplied fixes! " Thanks to those who pointed out problems with this file or supplied fixes!
@ -34,6 +34,8 @@ syn keyword bibEntryKw contained number organization pages publisher
syn keyword bibEntryKw contained school series title type volume year syn keyword bibEntryKw contained school series title type volume year
" Non-standard: " Non-standard:
syn keyword bibNSEntryKw contained abstract isbn issn keywords url syn keyword bibNSEntryKw contained abstract isbn issn keywords url
" AMS mref http://www.ams.org/mref
syn keyword bibNSEntryKw contained mrclass mrnumber mrreviewer fjournal coden
" Clusters " Clusters
" ======== " ========
@ -55,11 +57,11 @@ syn region bibEntryData contained start=/[{(]/ms=e+1 end=/[})]/me=e-1 contains=b
" Actually, 5.8 <= Vim < 6.0 would ignore the `fold' keyword anyway, but Vim<5.8 would produce " Actually, 5.8 <= Vim < 6.0 would ignore the `fold' keyword anyway, but Vim<5.8 would produce
" an error, so we explicitly distinguish versions with and without folding functionality: " an error, so we explicitly distinguish versions with and without folding functionality:
if version < 600 if version < 600
syn region bibEntry start=/@\S\+[{(]/ end=/^\s*[})]/ transparent contains=bibType,bibEntryData nextgroup=bibComment syn region bibEntry start=/@\S\+\s*[{(]/ end=/^\s*[})]/ transparent contains=bibType,bibEntryData nextgroup=bibComment
else else
syn region bibEntry start=/@\S\+[{(]/ end=/^\s*[})]/ transparent fold contains=bibType,bibEntryData nextgroup=bibComment syn region bibEntry start=/@\S\+\s*[{(]/ end=/^\s*[})]/ transparent fold contains=bibType,bibEntryData nextgroup=bibComment
endif endif
syn region bibComment2 start=/@Comment[{(]/ end=/^\s*@/me=e-1 contains=@bibCommentContents nextgroup=bibEntry syn region bibComment2 start=/@Comment\s*[{(]/ end=/^\s*[})]/me=e-1 contains=@bibCommentContents nextgroup=bibEntry
" Synchronization " Synchronization
" =============== " ===============

View File

@ -1,13 +1,13 @@
" Vim syntax file " Vim syntax file
" Language: BIND zone files (RFC1035) " Language: BIND zone files (RFC 1035)
" Maintainer: Julian Mehnle <julian@mehnle.net> " Maintainer: Julian Mehnle <julian@mehnle.net>
" URL: http://www.mehnle.net/source/odds+ends/vim/syntax/ " URL: http://www.mehnle.net/source/odds+ends/vim/syntax/
" Last Change: Thu 2006-04-20 12:30:45 UTC " Last Change: Thu 2011-07-16 20:42:00 UTC
" "
" Based on an earlier version by Вячеслав Горбанев (Slava Gorbanev), with " Based on an earlier version by Вячеслав Горбанев (Slava Gorbanev), with
" heavy modifications. " heavy modifications.
" "
" $Id: bindzone.vim,v 1.2 2006/04/20 22:06:21 vimboss Exp $ " $Id: bindzone.vim 12 2011-07-16 21:09:57Z julian $
" For version 5.x: Clear all syntax items " For version 5.x: Clear all syntax items
" For version 6.x: Quit when a syntax file was already loaded " For version 6.x: Quit when a syntax file was already loaded
@ -23,7 +23,7 @@ syn case match
syn region zoneRRecord start=/^/ end=/$/ contains=zoneOwnerName,zoneSpecial,zoneTTL,zoneClass,zoneRRType,zoneComment,zoneUnknown syn region zoneRRecord start=/^/ end=/$/ contains=zoneOwnerName,zoneSpecial,zoneTTL,zoneClass,zoneRRType,zoneComment,zoneUnknown
syn match zoneDirective /^\$ORIGIN\s\+/ nextgroup=zoneOrigin,zoneUnknown syn match zoneDirective /^\$ORIGIN\s\+/ nextgroup=zoneOrigin,zoneUnknown
syn match zoneDirective /^\$TTL\s\+/ nextgroup=zoneNumber,zoneUnknown syn match zoneDirective /^\$TTL\s\+/ nextgroup=zoneTTL,zoneUnknown
syn match zoneDirective /^\$INCLUDE\s\+/ nextgroup=zoneText,zoneUnknown syn match zoneDirective /^\$INCLUDE\s\+/ nextgroup=zoneText,zoneUnknown
syn match zoneDirective /^\$GENERATE\s/ syn match zoneDirective /^\$GENERATE\s/
@ -34,9 +34,9 @@ syn match zoneOrigin contained /[^[:space:]!"#$%&'()*+,\/:;<=>?@[\]\
syn match zoneDomain contained /[^[:space:]!"#$%&'()*+,\/:;<=>?@[\]\^`{|}~]\+\(\s\|;\|$\)\@=/ syn match zoneDomain contained /[^[:space:]!"#$%&'()*+,\/:;<=>?@[\]\^`{|}~]\+\(\s\|;\|$\)\@=/
syn match zoneSpecial contained /^[@*.]\s/ syn match zoneSpecial contained /^[@*.]\s/
syn match zoneTTL contained /\<\d[0-9HhWwDd]*\>/ nextgroup=zoneClass,zoneRRType skipwhite syn match zoneTTL contained /\s\@<=\d[0-9WwDdHhMmSs]*\(\s\|$\)\@=/ nextgroup=zoneClass,zoneRRType skipwhite
syn keyword zoneClass contained IN CHAOS nextgroup=zoneRRType,zoneTTL skipwhite syn keyword zoneClass contained IN CHAOS nextgroup=zoneRRType,zoneTTL skipwhite
syn keyword zoneRRType contained A AAAA CNAME HINFO MX NS PTR SOA SRV TXT nextgroup=zoneRData skipwhite syn keyword zoneRRType contained A AAAA CNAME DNAME HINFO MX NS PTR SOA SRV TXT SPF nextgroup=zoneRData skipwhite
syn match zoneRData contained /[^;]*/ contains=zoneDomain,zoneIPAddr,zoneIP6Addr,zoneText,zoneNumber,zoneParen,zoneUnknown syn match zoneRData contained /[^;]*/ contains=zoneDomain,zoneIPAddr,zoneIP6Addr,zoneText,zoneNumber,zoneParen,zoneUnknown
syn match zoneIPAddr contained /\<[0-9]\{1,3}\(\.[0-9]\{1,3}\)\{,3}\>/ syn match zoneIPAddr contained /\<[0-9]\{1,3}\(\.[0-9]\{1,3}\)\{,3}\>/
@ -66,7 +66,7 @@ syn match zoneNumber contained /\<[0-9]\+\(\s\|;\|$\)\@=/
syn match zoneSerial contained /\<[0-9]\{9,10}\(\s\|;\|$\)\@=/ syn match zoneSerial contained /\<[0-9]\{9,10}\(\s\|;\|$\)\@=/
syn match zoneErrParen /)/ syn match zoneErrParen /)/
syn region zoneParen contained start="(" end=")" contains=zoneSerial,zoneNumber,zoneComment syn region zoneParen contained start="(" end=")" contains=zoneSerial,zoneTTL,zoneNumber,zoneComment
syn match zoneComment /;.*/ syn match zoneComment /;.*/
" Define the default highlighting. " Define the default highlighting.

View File

@ -1,7 +1,7 @@
" Vim syntax file " Vim syntax file
" Language: C " Language: C
" Maintainer: Bram Moolenaar <Bram@vim.org> " Maintainer: Bram Moolenaar <Bram@vim.org>
" Last Change: 2009 Nov 17 " Last Change: 2011 Sep 07
" Quit when a (custom) syntax file was already loaded " Quit when a (custom) syntax file was already loaded
if exists("b:current_syntax") if exists("b:current_syntax")
@ -72,7 +72,7 @@ endif
" This should be before cErrInParen to avoid problems with #define ({ xxx }) " This should be before cErrInParen to avoid problems with #define ({ xxx })
if exists("c_curly_error") if exists("c_curly_error")
syntax match cCurlyError "}" syntax match cCurlyError "}"
syntax region cBlock start="{" end="}" contains=ALLBUT,cCurlyError,@cParenGroup,cErrInParen,cCppParen,cErrInBracket,cCppBracket,cCppString,@Spell fold syntax region cBlock start="{" end="}" contains=ALLBUT,cBadBlock,cCurlyError,@cParenGroup,cErrInParen,cCppParen,cErrInBracket,cCppBracket,cCppString,@Spell fold
else else
syntax region cBlock start="{" end="}" transparent fold syntax region cBlock start="{" end="}" transparent fold
endif endif
@ -80,31 +80,33 @@ endif
"catch errors caused by wrong parenthesis and brackets "catch errors caused by wrong parenthesis and brackets
" also accept <% for {, %> for }, <: for [ and :> for ] (C99) " also accept <% for {, %> for }, <: for [ and :> for ] (C99)
" But avoid matching <::. " But avoid matching <::.
syn cluster cParenGroup contains=cParenError,cIncluded,cSpecial,cCommentSkip,cCommentString,cComment2String,@cCommentGroup,cCommentStartError,cUserCont,cUserLabel,cBitField,cOctalZero,cCppOut,cCppOut2,cCppSkip,cFormat,cNumber,cFloat,cOctal,cOctalError,cNumbersCom syn cluster cParenGroup contains=cParenError,cIncluded,cSpecial,cCommentSkip,cCommentString,cComment2String,@cCommentGroup,cCommentStartError,cUserCont,cUserLabel,cBitField,cOctalZero,@cCppOutInGroup,cFormat,cNumber,cFloat,cOctal,cOctalError,cNumbersCom
if exists("c_no_curly_error") if exists("c_no_curly_error")
syn region cParen transparent start='(' end=')' contains=ALLBUT,@cParenGroup,cCppParen,cCppString,@Spell syn region cParen transparent start='(' end=')' end='}'me=s-1 contains=ALLBUT,cBlock,@cParenGroup,cCppParen,cCppString,@Spell
" cCppParen: same as cParen but ends at end-of-line; used in cDefine " cCppParen: same as cParen but ends at end-of-line; used in cDefine
syn region cCppParen transparent start='(' skip='\\$' excludenl end=')' end='$' contained contains=ALLBUT,@cParenGroup,cParen,cString,@Spell syn region cCppParen transparent start='(' skip='\\$' excludenl end=')' end='$' contained contains=ALLBUT,@cParenGroup,cParen,cString,@Spell
syn match cParenError display ")" syn match cParenError display ")"
syn match cErrInParen display contained "^[{}]\|^<%\|^%>" syn match cErrInParen display contained "^[{}]\|^<%\|^%>"
elseif exists("c_no_bracket_error") elseif exists("c_no_bracket_error")
syn region cParen transparent start='(' end=')' contains=ALLBUT,@cParenGroup,cCppParen,cCppString,@Spell syn region cParen transparent start='(' end=')' end='}'me=s-1 contains=ALLBUT,cBlock,@cParenGroup,cCppParen,cCppString,@Spell
" cCppParen: same as cParen but ends at end-of-line; used in cDefine " cCppParen: same as cParen but ends at end-of-line; used in cDefine
syn region cCppParen transparent start='(' skip='\\$' excludenl end=')' end='$' contained contains=ALLBUT,@cParenGroup,cParen,cString,@Spell syn region cCppParen transparent start='(' skip='\\$' excludenl end=')' end='$' contained contains=ALLBUT,@cParenGroup,cParen,cString,@Spell
syn match cParenError display ")" syn match cParenError display ")"
syn match cErrInParen display contained "[{}]\|<%\|%>" syn match cErrInParen display contained "[{}]\|<%\|%>"
else else
syn region cParen transparent start='(' end=')' contains=ALLBUT,@cParenGroup,cCppParen,cErrInBracket,cCppBracket,cCppString,@Spell syn region cParen transparent start='(' end=')' end='}'me=s-1 contains=ALLBUT,cBlock,@cParenGroup,cCppParen,cErrInBracket,cCppBracket,cCppString,@Spell
" cCppParen: same as cParen but ends at end-of-line; used in cDefine " cCppParen: same as cParen but ends at end-of-line; used in cDefine
syn region cCppParen transparent start='(' skip='\\$' excludenl end=')' end='$' contained contains=ALLBUT,@cParenGroup,cErrInBracket,cParen,cBracket,cString,@Spell syn region cCppParen transparent start='(' skip='\\$' excludenl end=')' end='$' contained contains=ALLBUT,@cParenGroup,cErrInBracket,cParen,cBracket,cString,@Spell
syn match cParenError display "[\])]" syn match cParenError display "[\])]"
syn match cErrInParen display contained "[\]{}]\|<%\|%>" syn match cErrInParen display contained "[\]{}]\|<%\|%>"
syn region cBracket transparent start='\[\|<::\@!' end=']\|:>' contains=ALLBUT,@cParenGroup,cErrInParen,cCppParen,cCppBracket,cCppString,@Spell syn region cBracket transparent start='\[\|<::\@!' end=']\|:>' end='}'me=s-1 contains=ALLBUT,cBlock,@cParenGroup,cErrInParen,cCppParen,cCppBracket,cCppString,@Spell
" cCppBracket: same as cParen but ends at end-of-line; used in cDefine " cCppBracket: same as cParen but ends at end-of-line; used in cDefine
syn region cCppBracket transparent start='\[\|<::\@!' skip='\\$' excludenl end=']\|:>' end='$' contained contains=ALLBUT,@cParenGroup,cErrInParen,cParen,cBracket,cString,@Spell syn region cCppBracket transparent start='\[\|<::\@!' skip='\\$' excludenl end=']\|:>' end='$' contained contains=ALLBUT,@cParenGroup,cErrInParen,cParen,cBracket,cString,@Spell
syn match cErrInBracket display contained "[);{}]\|<%\|%>" syn match cErrInBracket display contained "[);{}]\|<%\|%>"
endif endif
syntax region cBadBlock keepend extend start="{" end="}" contained containedin=cParen,cBracket,cBadBlock transparent fold
"integer number, or floating point number without a dot and with "f". "integer number, or floating point number without a dot and with "f".
syn case ignore syn case ignore
syn match cNumbers display transparent "\<\d\|\.\d" contains=cNumber,cFloat,cOctalError,cOctal syn match cNumbers display transparent "\<\d\|\.\d" contains=cNumber,cFloat,cOctalError,cOctal
@ -270,27 +272,39 @@ if !exists("c_no_c99") " ISO C99
endif endif
" Accept %: for # (C99) " Accept %: for # (C99)
syn region cPreCondit start="^\s*\(%:\|#\)\s*\(if\|ifdef\|ifndef\|elif\)\>" skip="\\$" end="$" keepend contains=cComment,cCommentL,cCppString,cCharacter,cCppParen,cParenError,cNumbers,cCommentError,cSpaceError syn region cPreCondit start="^\s*\(%:\|#\)\s*\(if\|ifdef\|ifndef\|elif\)\>" skip="\\$" end="$" keepend contains=cComment,cCommentL,cCppString,cCharacter,cCppParen,cParenError,cNumbers,cCommentError,cSpaceError
syn match cPreCondit display "^\s*\(%:\|#\)\s*\(else\|endif\)\>" syn match cPreConditMatch display "^\s*\(%:\|#\)\s*\(else\|endif\)\>"
if !exists("c_no_if0") if !exists("c_no_if0")
syn cluster cCppOutInGroup contains=cCppInIf,cCppInElse,cCppInElse2,cCppOutIf,cCppOutIf2,cCppOutElse,cCppInSkip,cCppOutSkip
syn region cCppOutWrapper start="^\s*\(%:\|#\)\s*if\s\+0\+\s*\($\|//\|/\*\|&\)" end=".\@=\|$" contains=cCppOutIf,cCppOutElse fold
syn region cCppOutIf contained start="0\+" matchgroup=cCppOutWrapper end="^\s*\(%:\|#\)\s*endif\>" contains=cCppOutIf2,cCppOutElse
if !exists("c_no_if0_fold") if !exists("c_no_if0_fold")
syn region cCppOut start="^\s*\(%:\|#\)\s*if\s\+0\+\>" end=".\@=\|$" contains=cCppOut2 fold syn region cCppOutIf2 contained matchgroup=cCppOutWrapper start="0\+" end="^\s*\(%:\|#\)\s*\(else\>\|elif\s\+\(0\+\s*\($\|//\|/\*\|&\)\)\@!\|endif\>\)"me=s-1 contains=cSpaceError,cCppOutSkip fold
else else
syn region cCppOut start="^\s*\(%:\|#\)\s*if\s\+0\+\>" end=".\@=\|$" contains=cCppOut2 syn region cCppOutIf2 contained matchgroup=cCppOutWrapper start="0\+" end="^\s*\(%:\|#\)\s*\(else\>\|elif\s\+\(0\+\s*\($\|//\|/\*\|&\)\)\@!\|endif\>\)"me=s-1 contains=cSpaceError,cCppOutSkip
endif endif
syn region cCppOut2 contained start="0" end="^\s*\(%:\|#\)\s*\(endif\>\|else\>\|elif\>\)" contains=cSpaceError,cCppSkip syn region cCppOutElse contained matchgroup=cCppOutWrapper start="^\s*\(%:\|#\)\s*\(else\|elif\)" end="^\s*\(%:\|#\)\s*endif\>"me=s-1 contains=TOP,cPreCondit
syn region cCppSkip contained start="^\s*\(%:\|#\)\s*\(if\>\|ifdef\>\|ifndef\>\)" skip="\\$" end="^\s*\(%:\|#\)\s*endif\>" contains=cSpaceError,cCppSkip syn region cCppInWrapper start="^\s*\(%:\|#\)\s*if\s\+0*[1-9]\d*\s*\($\|//\|/\*\||\)" end=".\@=\|$" contains=cCppInIf,cCppInElse fold
syn region cCppInIf contained matchgroup=cCppInWrapper start="\d\+" end="^\s*\(%:\|#\)\s*endif\>" contains=TOP,cPreCondit
if !exists("c_no_if0_fold")
syn region cCppInElse contained start="^\s*\(%:\|#\)\s*\(else\>\|elif\s\+\(0*[1-9]\d*\s*\($\|//\|/\*\||\)\)\@!\)" end=".\@=\|$" containedin=cCppInIf contains=cCppInElse2 fold
else
syn region cCppInElse contained start="^\s*\(%:\|#\)\s*\(else\>\|elif\s\+\(0*[1-9]\d*\s*\($\|//\|/\*\||\)\)\@!\)" end=".\@=\|$" containedin=cCppInIf contains=cCppInElse2
endif
syn region cCppInElse2 contained matchgroup=cCppInWrapper start="^\s*\(%:\|#\)\s*\(else\|elif\)\([^/]\|/[^/*]\)*" end="^\s*\(%:\|#\)\s*endif\>"me=s-1 contains=cSpaceError,cCppOutSkip
syn region cCppOutSkip contained start="^\s*\(%:\|#\)\s*\(if\>\|ifdef\>\|ifndef\>\)" skip="\\$" end="^\s*\(%:\|#\)\s*endif\>" contains=cSpaceError,cCppOutSkip
syn region cCppInSkip contained matchgroup=cCppInWrapper start="^\s*\(%:\|#\)\s*\(if\s\+\(\d\+\s*\($\|//\|/\*\||\|&\)\)\@!\|ifdef\>\|ifndef\>\)" skip="\\$" end="^\s*\(%:\|#\)\s*endif\>" containedin=cCppOutElse,cCppInIf,cCppInSkip contains=TOP,cPreProc
endif endif
syn region cIncluded display contained start=+"+ skip=+\\\\\|\\"+ end=+"+ syn region cIncluded display contained start=+"+ skip=+\\\\\|\\"+ end=+"+
syn match cIncluded display contained "<[^>]*>" syn match cIncluded display contained "<[^>]*>"
syn match cInclude display "^\s*\(%:\|#\)\s*include\>\s*["<]" contains=cIncluded syn match cInclude display "^\s*\(%:\|#\)\s*include\>\s*["<]" contains=cIncluded
"syn match cLineSkip "\\$" "syn match cLineSkip "\\$"
syn cluster cPreProcGroup contains=cPreCondit,cIncluded,cInclude,cDefine,cErrInParen,cErrInBracket,cUserLabel,cSpecial,cOctalZero,cCppOut,cCppOut2,cCppSkip,cFormat,cNumber,cFloat,cOctal,cOctalError,cNumbersCom,cString,cCommentSkip,cCommentString,cComment2String,@cCommentGroup,cCommentStartError,cParen,cBracket,cMulti syn cluster cPreProcGroup contains=cPreCondit,cIncluded,cInclude,cDefine,cErrInParen,cErrInBracket,cUserLabel,cSpecial,cOctalZero,cCppOutWrapper,cCppInWrapper,@cCppOutInGroup,cFormat,cNumber,cFloat,cOctal,cOctalError,cNumbersCom,cString,cCommentSkip,cCommentString,cComment2String,@cCommentGroup,cCommentStartError,cParen,cBracket,cMulti
syn region cDefine start="^\s*\(%:\|#\)\s*\(define\|undef\)\>" skip="\\$" end="$" keepend contains=ALLBUT,@cPreProcGroup,@Spell syn region cDefine start="^\s*\(%:\|#\)\s*\(define\|undef\)\>" skip="\\$" end="$" keepend contains=ALLBUT,@cPreProcGroup,@Spell
syn region cPreProc start="^\s*\(%:\|#\)\s*\(pragma\>\|line\>\|warning\>\|warn\>\|error\>\)" skip="\\$" end="$" keepend contains=ALLBUT,@cPreProcGroup,@Spell syn region cPreProc start="^\s*\(%:\|#\)\s*\(pragma\>\|line\>\|warning\>\|warn\>\|error\>\)" skip="\\$" end="$" keepend contains=ALLBUT,@cPreProcGroup,@Spell
" Highlight User Labels " Highlight User Labels
syn cluster cMultiGroup contains=cIncluded,cSpecial,cCommentSkip,cCommentString,cComment2String,@cCommentGroup,cCommentStartError,cUserCont,cUserLabel,cBitField,cOctalZero,cCppOut,cCppOut2,cCppSkip,cFormat,cNumber,cFloat,cOctal,cOctalError,cNumbersCom,cCppParen,cCppBracket,cCppString syn cluster cMultiGroup contains=cIncluded,cSpecial,cCommentSkip,cCommentString,cComment2String,@cCommentGroup,cCommentStartError,cUserCont,cUserLabel,cBitField,cOctalZero,cCppOutWrapper,cCppInWrapper,@cCppOutInGroup,cFormat,cNumber,cFloat,cOctal,cOctalError,cNumbersCom,cCppParen,cCppBracket,cCppString
syn region cMulti transparent start='?' skip='::' end=':' contains=ALLBUT,@cMultiGroup,@Spell syn region cMulti transparent start='?' skip='::' end=':' contains=ALLBUT,@cMultiGroup,@Spell
" Avoid matching foo::bar() in C++ by requiring that the next char is not ':' " Avoid matching foo::bar() in C++ by requiring that the next char is not ':'
syn cluster cLabelGroup contains=cUserLabel syn cluster cLabelGroup contains=cUserLabel
@ -354,6 +368,9 @@ hi def link cDefine Macro
hi def link cIncluded cString hi def link cIncluded cString
hi def link cError Error hi def link cError Error
hi def link cStatement Statement hi def link cStatement Statement
hi def link cCppInWrapper cCppOutWrapper
hi def link cCppOutWrapper cPreCondit
hi def link cPreConditMatch cPreCondit
hi def link cPreCondit PreCondit hi def link cPreCondit PreCondit
hi def link cType Type hi def link cType Type
hi def link cConstant Constant hi def link cConstant Constant
@ -365,8 +382,10 @@ hi def link cComment Comment
hi def link cSpecial SpecialChar hi def link cSpecial SpecialChar
hi def link cTodo Todo hi def link cTodo Todo
hi def link cBadContinuation Error hi def link cBadContinuation Error
hi def link cCppSkip cCppOut hi def link cCppOutSkip cCppOutIf2
hi def link cCppOut2 cCppOut hi def link cCppInElse2 cCppOutIf2
hi def link cCppOutIf2 cCppOut2 " Old syntax group for #if 0 body
hi def link cCppOut2 cCppOut " Old syntax group for #if of #if 0
hi def link cCppOut Comment hi def link cCppOut Comment
let b:current_syntax = "c" let b:current_syntax = "c"

View File

@ -5,8 +5,7 @@
" License: This file can be redistribued and/or modified under the same terms " License: This file can be redistribued and/or modified under the same terms
" as Vim itself. " as Vim itself.
" Filenames: /tmp/crontab.* used by "crontab -e" " Filenames: /tmp/crontab.* used by "crontab -e"
" URL: http://trific.ath.cx/Ftp/vim/syntax/crontab.vim " Last Change: 2011-04-21
" Last Change: 2006-04-20
" "
" crontab line format: " crontab line format:
" Minutes Hours Days Months Days_of_Week Commands # comments " Minutes Hours Days Months Days_of_Week Commands # comments
@ -23,12 +22,14 @@ syntax match crontabMin "^\s*[-0-9/,.*]\+" nextgroup=crontabHr skipwhite
syntax match crontabHr "\s[-0-9/,.*]\+" nextgroup=crontabDay skipwhite contained syntax match crontabHr "\s[-0-9/,.*]\+" nextgroup=crontabDay skipwhite contained
syntax match crontabDay "\s[-0-9/,.*]\+" nextgroup=crontabMnth skipwhite contained syntax match crontabDay "\s[-0-9/,.*]\+" nextgroup=crontabMnth skipwhite contained
syntax case ignore
syntax match crontabMnth "\s[-a-z0-9/,.*]\+" nextgroup=crontabDow skipwhite contained syntax match crontabMnth "\s[-a-z0-9/,.*]\+" nextgroup=crontabDow skipwhite contained
syntax keyword crontabMnth12 contained jan feb mar apr may jun jul aug sep oct nov dec syntax keyword crontabMnth12 contained jan feb mar apr may jun jul aug sep oct nov dec
syntax match crontabDow "\s[-a-z0-9/,.*]\+" nextgroup=crontabCmd skipwhite contained syntax match crontabDow "\s[-a-z0-9/,.*]\+" nextgroup=crontabCmd skipwhite contained
syntax keyword crontabDow7 contained sun mon tue wed thu fri sat syntax keyword crontabDow7 contained sun mon tue wed thu fri sat
syntax case match
syntax region crontabCmd start="\S" end="$" skipwhite contained keepend contains=crontabPercent syntax region crontabCmd start="\S" end="$" skipwhite contained keepend contains=crontabPercent
syntax match crontabCmnt "^\s*#.*" syntax match crontabCmnt "^\s*#.*"
syntax match crontabPercent "[^\\]%.*"lc=1 contained syntax match crontabPercent "[^\\]%.*"lc=1 contained

View File

@ -3,8 +3,8 @@
" Maintainer: Debian Vim Maintainers <pkg-vim-maintainers@lists.alioth.debian.org> " Maintainer: Debian Vim Maintainers <pkg-vim-maintainers@lists.alioth.debian.org>
" Former Maintainers: Gerfried Fuchs <alfie@ist.org> " Former Maintainers: Gerfried Fuchs <alfie@ist.org>
" Wichert Akkerman <wakkerma@debian.org> " Wichert Akkerman <wakkerma@debian.org>
" Last Change: 2010 Oct 21 " Last Change: 2011 June 01
" URL: http://hg.debian.org/hg/pkg-vim/vim/raw-file/unstable/runtime/syntax/debchangelog.vim " URL: http://anonscm.debian.org/hg/pkg-vim/vim/raw-file/unstable/runtime/syntax/debchangelog.vim
" Standard syntax initialization " Standard syntax initialization
if version < 600 if version < 600
@ -19,7 +19,7 @@ syn case ignore
" Define some common expressions we can use later on " Define some common expressions we can use later on
syn match debchangelogName contained "^[[:alnum:]][[:alnum:].+-]\+ " syn match debchangelogName contained "^[[:alnum:]][[:alnum:].+-]\+ "
syn match debchangelogUrgency contained "; urgency=\(low\|medium\|high\|critical\|emergency\)\( \S.*\)\=" 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|%(lenny|squeeze)-%(backports%(-sloppy)=|volatile)|%(dapper|hardy|jaunty|karmic|lucid|maverick|natty)%(-%(security|proposed|updates|backports|commercial|partner))=)+" syn match debchangelogTarget contained "\v %(frozen|unstable|%(testing|%(old)=stable)%(-proposed-updates|-security)=|experimental|%(lenny|squeeze)-%(backports%(-sloppy)=|volatile)|%(hardy|lucid|maverick|natty|oneiric)%(-%(security|proposed|updates|backports|commercial|partner))=)+"
syn match debchangelogVersion contained "(.\{-})" syn match debchangelogVersion contained "(.\{-})"
syn match debchangelogCloses contained "closes:\_s*\(bug\)\=#\=\_s\=\d\+\(,\_s*\(bug\)\=#\=\_s\=\d\+\)*" syn match debchangelogCloses contained "closes:\_s*\(bug\)\=#\=\_s\=\d\+\(,\_s*\(bug\)\=#\=\_s\=\d\+\)*"
syn match debchangelogLP contained "\clp:\s\+#\d\+\(,\s*#\d\+\)*" syn match debchangelogLP contained "\clp:\s\+#\d\+\(,\s*#\d\+\)*"

View File

@ -3,8 +3,8 @@
" Maintainer: Debian Vim Maintainers <pkg-vim-maintainers@lists.alioth.debian.org> " Maintainer: Debian Vim Maintainers <pkg-vim-maintainers@lists.alioth.debian.org>
" Former Maintainers: Gerfried Fuchs <alfie@ist.org> " Former Maintainers: Gerfried Fuchs <alfie@ist.org>
" Wichert Akkerman <wakkerma@debian.org> " Wichert Akkerman <wakkerma@debian.org>
" Last Change: 2010 Oct 21 " Last Change: 2011 June 01
" URL: http://hg.debian.org/hg/pkg-vim/vim/raw-file/unstable/runtime/syntax/debcontrol.vim " URL: http://anonscm.debian.org/hg/pkg-vim/vim/raw-file/unstable/runtime/syntax/debcontrol.vim
" Standard syntax initialization " Standard syntax initialization
if version < 600 if version < 600
@ -24,7 +24,8 @@ syn match debControlComma ", *"
syn match debControlSpace " " syn match debControlSpace " "
" Define some common expressions we can use later on " Define some common expressions we can use later on
syn match debcontrolArchitecture contained "\%(all\|any\|alpha\|amd64\|arm\%(e[bl]\)\=\|avr32\|hppa\|i386\|ia64\|lpia\|m32r\|m68k\|mips\%(el\)\=\|powerpc\|ppc64\|s390x\=\|sh[34]\(eb\)\=\|sh\|sparc\%(64\)\=\|hurd-i386\|kfreebsd-\%(i386\|amd64\|gnu\)\|knetbsd-i386\|kopensolaris-i386\|netbsd-\%(alpha\|i386\)\)" syn match debcontrolArchitecture contained "\%(all\|any\|linux-any\|\%(any-\)\=\%(alpha\|amd64\|arm\%(e[bl]\)\=\|avr32\|hppa\|i386\|ia64\|lpia\|m32r\|m68k\|mips\%(el\)\=\|powerpc\|ppc64\|s390x\=\|sh[34]\(eb\)\=\|sh\|sparc\%(64\)\=\)\|hurd-\%(i386\|any\)\|kfreebsd-\%(i386\|amd64\|any\)\|knetbsd-\%(i386\|any\)\|kopensolaris-\%(i386\|any\)\|netbsd-\%(alpha\|i386\|any\)\)"
syn match debcontrolMultiArch contained "\%(no\|foreign\|allowed\|same\)"
syn match debcontrolName contained "[a-z0-9][a-z0-9+.-]\+" syn match debcontrolName contained "[a-z0-9][a-z0-9+.-]\+"
syn match debcontrolPriority contained "\(extra\|important\|optional\|required\|standard\)" syn match debcontrolPriority contained "\(extra\|important\|optional\|required\|standard\)"
syn match debcontrolSection contained "\v((contrib|non-free|non-US/main|non-US/contrib|non-US/non-free|restricted|universe|multiverse)/)?(admin|cli-mono|comm|database|debian-installer|debug|devel|doc|editors|electronics|embedded|fonts|games|gnome|gnustep|gnu-r|graphics|hamradio|haskell|httpd|interpreters|java|kde|kernel|libs|libdevel|lisp|localization|mail|math|metapackages|misc|net|news|ocaml|oldlibs|otherosfs|perl|php|python|ruby|science|shells|sound|text|tex|utils|vcs|video|web|x11|xfce|zope)" syn match debcontrolSection contained "\v((contrib|non-free|non-US/main|non-US/contrib|non-US/non-free|restricted|universe|multiverse)/)?(admin|cli-mono|comm|database|debian-installer|debug|devel|doc|editors|electronics|embedded|fonts|games|gnome|gnustep|gnu-r|graphics|hamradio|haskell|httpd|interpreters|java|kde|kernel|libs|libdevel|lisp|localization|mail|math|metapackages|misc|net|news|ocaml|oldlibs|otherosfs|perl|php|python|ruby|science|shells|sound|text|tex|utils|vcs|video|web|x11|xfce|zope)"
@ -49,14 +50,15 @@ syn match debcontrolComment "^#.*$"
syn case ignore syn case ignore
" List of all legal keys " List of all legal keys
syn match debcontrolKey contained "^\%(Source\|Package\|Section\|Priority\|\%(XSBC-Original-\)\=Maintainer\|Uploaders\|Build-\%(Conflicts\|Depends\)\%(-Indep\)\=\|Standards-Version\|\%(Pre-\)\=Depends\|Recommends\|Suggests\|Provides\|Replaces\|Conflicts\|Enhances\|Breaks\|Essential\|Architecture\|Description\|Bugs\|Origin\|X[SB]-Python-Version\|Homepage\|\(XS-\)\=Vcs-\(Browser\|Arch\|Bzr\|Cvs\|Darcs\|Git\|Hg\|Mtn\|Svn\)\|XC-Package-Type\|\%(XS-\)\=DM-Upload-Allowed\): *" syn match debcontrolKey contained "^\%(Source\|Package\|Section\|Priority\|\%(XSBC-Original-\)\=Maintainer\|Uploaders\|Build-\%(Conflicts\|Depends\)\%(-Indep\)\=\|Standards-Version\|\%(Pre-\)\=Depends\|Recommends\|Suggests\|Provides\|Replaces\|Conflicts\|Enhances\|Breaks\|Essential\|Architecture\|Multi-Arch\|Description\|Bugs\|Origin\|X[SB]-Python-Version\|Homepage\|\(XS-\)\=Vcs-\(Browser\|Arch\|Bzr\|Cvs\|Darcs\|Git\|Hg\|Mtn\|Svn\)\|\%(XC-\)\=Package-Type\|\%(XS-\)\=DM-Upload-Allowed\): *"
" Fields for which we do strict syntax checking " Fields for which we do strict syntax checking
syn region debcontrolStrictField start="^Architecture" end="$" contains=debcontrolKey,debcontrolArchitecture,debcontrolSpace oneline syn region debcontrolStrictField start="^Architecture" end="$" contains=debcontrolKey,debcontrolArchitecture,debcontrolSpace oneline
syn region debcontrolStrictField start="^Multi-Arch" end="$" contains=debcontrolKey,debcontrolMultiArch oneline
syn region debcontrolStrictField start="^\(Package\|Source\)" end="$" contains=debcontrolKey,debcontrolName oneline syn region debcontrolStrictField start="^\(Package\|Source\)" end="$" contains=debcontrolKey,debcontrolName oneline
syn region debcontrolStrictField start="^Priority" end="$" contains=debcontrolKey,debcontrolPriority oneline syn region debcontrolStrictField start="^Priority" end="$" contains=debcontrolKey,debcontrolPriority oneline
syn region debcontrolStrictField start="^Section" end="$" contains=debcontrolKey,debcontrolSection oneline syn region debcontrolStrictField start="^Section" end="$" contains=debcontrolKey,debcontrolSection oneline
syn region debcontrolStrictField start="^XC-Package-Type" end="$" contains=debcontrolKey,debcontrolPackageType oneline syn region debcontrolStrictField start="^\%(XC-\)\=Package-Type" end="$" contains=debcontrolKey,debcontrolPackageType oneline
syn region debcontrolStrictField start="^Homepage" end="$" contains=debcontrolKey,debcontrolHTTPUrl oneline keepend syn region debcontrolStrictField start="^Homepage" end="$" contains=debcontrolKey,debcontrolHTTPUrl oneline keepend
syn region debcontrolStrictField start="^\%(XS-\)\=Vcs-\%(Browser\|Arch\|Bzr\|Darcs\|Hg\)" end="$" contains=debcontrolKey,debcontrolHTTPUrl oneline keepend syn region debcontrolStrictField start="^\%(XS-\)\=Vcs-\%(Browser\|Arch\|Bzr\|Darcs\|Hg\)" end="$" contains=debcontrolKey,debcontrolHTTPUrl oneline keepend
syn region debcontrolStrictField start="^\%(XS-\)\=Vcs-Svn" end="$" contains=debcontrolKey,debcontrolVcsSvn,debcontrolHTTPUrl oneline keepend syn region debcontrolStrictField start="^\%(XS-\)\=Vcs-Svn" end="$" contains=debcontrolKey,debcontrolVcsSvn,debcontrolHTTPUrl oneline keepend
@ -82,6 +84,7 @@ if version >= 508 || !exists("did_debcontrol_syn_inits")
HiLink debcontrolStrictField Error HiLink debcontrolStrictField Error
HiLink debcontrolMultiField Normal HiLink debcontrolMultiField Normal
HiLink debcontrolArchitecture Normal HiLink debcontrolArchitecture Normal
HiLink debcontrolMultiArch Normal
HiLink debcontrolName Normal HiLink debcontrolName Normal
HiLink debcontrolPriority Normal HiLink debcontrolPriority Normal
HiLink debcontrolSection Normal HiLink debcontrolSection Normal

View File

@ -2,8 +2,8 @@
" Language: Debian sources.list " Language: Debian sources.list
" Maintainer: Debian Vim Maintainers <pkg-vim-maintainers@lists.alioth.debian.org> " Maintainer: Debian Vim Maintainers <pkg-vim-maintainers@lists.alioth.debian.org>
" Former Maintainer: Matthijs Mohlmann <matthijs@cacholong.nl> " Former Maintainer: Matthijs Mohlmann <matthijs@cacholong.nl>
" Last Change: 2010 Oct 21 " Last Change: 2011 June 01
" URL: http://hg.debian.org/hg/pkg-vim/vim/raw-file/unstable/runtime/syntax/debsources.vim " URL: http://anonscm.debian.org/hg/pkg-vim/vim/raw-file/unstable/runtime/syntax/debsources.vim
" Standard syntax initialization " Standard syntax initialization
if version < 600 if version < 600
@ -23,7 +23,7 @@ syn match debsourcesComment /#.*/ contains=@Spell
" Match uri's " Match uri's
syn match debsourcesUri +\(http://\|ftp://\|[rs]sh://\|debtorrent://\|\(cdrom\|copy\|file\):\)[^' <>"]\++ syn match debsourcesUri +\(http://\|ftp://\|[rs]sh://\|debtorrent://\|\(cdrom\|copy\|file\):\)[^' <>"]\++
syn match debsourcesDistrKeyword +\([[:alnum:]_./]*\)\(lenny\|squeeze\|\(old\)\=stable\|testing\|unstable\|sid\|rc-buggy\|experimental\|dapper\|hardy\|jaunty\|karmic\|lucid\|maverick\|natty\)\([-[:alnum:]_./]*\)+ syn match debsourcesDistrKeyword +\([[:alnum:]_./]*\)\(lenny\|squeeze\|wheezy\|\(old\)\=stable\|testing\|unstable\|sid\|rc-buggy\|experimental\|hardy\|lucid\|maverick\|natty\|oneiric\)\([-[:alnum:]_./]*\)+
" Associate our matches and regions with pretty colours " Associate our matches and regions with pretty colours
hi def link debsourcesLine Error hi def link debsourcesLine Error

View File

@ -0,0 +1,33 @@
" Vim syntax file
" Language: directory pager
" Maintainer: Thilo Six <T.Six@gmx.de>
" Derived From: Nikolai Weibull's dircolors.vim
" Latest Revision: 2011-04-09
"
" usage: $ ls -la | view -c "set ft=dirpager" -
"
if exists("b:current_syntax")
finish
endif
let s:cpo_save = &cpo
set cpo&vim
setlocal nowrap
syn keyword DirPagerTodo contained FIXME TODO XXX NOTE
syn region DirPagerExe start='^...x\|^......x\|^.........x' end='$' contains=DirPagerTodo,@Spell
syn region DirPagerDir start='^d' end='$' contains=DirPagerTodo,@Spell
syn region DirPagerLink start='^l' end='$' contains=DirPagerTodo,@Spell
hi def link DirPagerTodo Todo
hi def DirPagerExe ctermfg=Green guifg=Green
hi def DirPagerDir ctermfg=Blue guifg=Blue
hi def DirPagerLink ctermfg=Cyan guifg=Cyan
let b:current_syntax = "dirpager"
let &cpo = s:cpo_save
unlet s:cpo_save

173
runtime/syntax/dnsmasq.vim Normal file
View File

@ -0,0 +1,173 @@
" Vim syntax file
" Language: dnsmasq(8) configuration file
" Maintainer: Thilo Six <T.Six@gmx.de>
" Last Change: 2011 Jul 14
" Credits: This file is a mix of cfg.vim, wget.vim and xf86conf.vim, credits go to:
" Igor N. Prischepoff
" Doug Kearns
" David Ne\v{c}as
"
" Options: You might want to add this to your vimrc:
"
" if &background == "dark"
" " dnsmasq.vim
" let dnsmasq_backrgound_light = 0
" else
" let dnsmasq_backrgound_light = 1
" endif
"
" 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
elseif exists ("b:current_syntax")
finish
endif
if !exists("b:dnsmasq_backrgound_light")
if exists("dnsmasq_backrgound_light")
let b:dnsmasq_backrgound_light = dnsmasq_backrgound_light
else
let b:dnsmasq_backrgound_light = 0
endif
endif
" case on
syn case match
syn match DnsmasqValues "=.*"hs=s+1 contains=DnsmasqComment,DnsmasqSpecial
syn match DnsmasqSpecial display '=\|@\|,\|!\|:' nextgroup=DnsmasqValues
syn match DnsmasqSpecial "#"
syn match DnsmasqIPv4 "\(\d\{1,3}\.\)\{3}\d\{1,3}" nextgroup=DnsmasqSubnet2,DnsmasqRange
syn match DnsmasqSubnet "\<255.\(\d\{1,3}\.\)\{2}\d\{1,3}"
syn match DnsmasqSubnet2 contained "\/\(\d\{1,2}\)\>"
syn match DnsmasqRange contained "-"
syn match DnsmasqMac "\<\(\x\x\?:\)\{5}\x\x\?"
syn match DnsmasqTime "\<\(\d\{1,3}\)[hm]\>"
" String
syn match DnsmasqString "\".*\""
syn match DnsmasqString "'.*'"
" Comments
syn match DnsmasqComment "^#.*$" contains=DnsmasqTodo
syn match DnsmasqComment "\s#.*$" contains=DnsmasqTodo
syn keyword DnsmasqTodo FIXME TODO XXX NOTE contained
syn match DnsmasqKeywordSpecial "\<set\>:"me=e-1
syn match DnsmasqKeywordSpecial "\<tag\>:"me=e-1
syn match DnsmasqKeywordSpecial ",\<static\>"hs=s+1 contains=DnsmasqSpecial
syn match DnsmasqKeywordSpecial ",\<infinite\>"hs=s+1 contains=DnsmasqSpecial
syn match DnsmasqKeywordSpecial "\<encap\>:"me=e-1
syn match DnsmasqKeywordSpecial "\<net\>:"me=e-1
syn match DnsmasqKeywordSpecial "\<vendor\>:"me=e-1
syn match DnsmasqKeywordSpecial "\<option\>:"me=e-1
syn match DnsmasqKeywordSpecial ",\<ignore\>"hs=s+1 contains=DnsmasqSpecial
syn match DnsmasqKeywordSpecial "\<id\>:"me=e-1
syn match DnsmasqKeyword "^\s*add-mac\>"
syn match DnsmasqKeyword "^\s*addn-hosts\>"
syn match DnsmasqKeyword "^\s*address\>"
syn match DnsmasqKeyword "^\s*alias\>"
syn match DnsmasqKeyword "^\s*all-servers\>"
syn match DnsmasqKeyword "^\s*bind-interfaces\>"
syn match DnsmasqKeyword "^\s*bogus-nxdomain\>"
syn match DnsmasqKeyword "^\s*bogus-priv\>"
syn match DnsmasqKeyword "^\s*cache-size\>"
syn match DnsmasqKeyword "^\s*clear-on-reload\>"
syn match DnsmasqKeyword "^\s*cname\>"
syn match DnsmasqKeyword "^\s*conf-dir\>"
syn match DnsmasqKeyword "^\s*conf-file\>"
syn match DnsmasqKeyword "^\s*dhcp-authoritative\>"
syn match DnsmasqKeyword "^\s*dhcp-boot\>"
syn match DnsmasqKeyword "^\s*dhcp-fqdn\>"
syn match DnsmasqKeyword "^\s*dhcp-host\>"
syn match DnsmasqKeyword "^\s*dhcp-ignore\>"
syn match DnsmasqKeyword "^\s*dhcp-lease-max\>"
syn match DnsmasqKeyword "^\s*dhcp-leasefile\>"
syn match DnsmasqKeyword "^\s*dhcp-mac\>"
syn match DnsmasqKeyword "^\s*dhcp-match\>"
syn match DnsmasqKeyword "^\s*dhcp-no-override\>"
syn match DnsmasqKeyword "^\s*dhcp-option-force\>"
syn match DnsmasqKeyword "^\s*dhcp-option\>"
syn match DnsmasqKeyword "^\s*dhcp-range\>"
syn match DnsmasqKeyword "^\s*dhcp-script\>"
syn match DnsmasqKeyword "^\s*dhcp-scriptuser\>"
syn match DnsmasqKeyword "^\s*dhcp-userclass\>"
syn match DnsmasqKeyword "^\s*dhcp-vendorclass\>"
syn match DnsmasqKeyword "^\s*domain-needed\>"
syn match DnsmasqKeyword "^\s*domain\>"
syn match DnsmasqKeyword "^\s*enable-dbus\>"
syn match DnsmasqKeyword "^\s*enable-tftp\>"
syn match DnsmasqKeyword "^\s*except-interface\>"
syn match DnsmasqKeyword "^\s*expand-hosts\>"
syn match DnsmasqKeyword "^\s*filterwin2k\>"
syn match DnsmasqKeyword "^\s*group\>"
syn match DnsmasqKeyword "^\s*interface\>"
syn match DnsmasqKeyword "^\s*keep-in-foreground\>"
syn match DnsmasqKeyword "^\s*leasefile-ro\>"
syn match DnsmasqKeyword "^\s*listen-address\>"
syn match DnsmasqKeyword "^\s*local-ttl\>"
syn match DnsmasqKeyword "^\s*local\>"
syn match DnsmasqKeyword "^\s*localise-queries\>"
syn match DnsmasqKeyword "^\s*localmx\>"
syn match DnsmasqKeyword "^\s*log-dhcp\>"
syn match DnsmasqKeyword "^\s*log-queries\>"
syn match DnsmasqKeyword "^\s*mx-host\>"
syn match DnsmasqKeyword "^\s*mx-target\>"
syn match DnsmasqKeyword "^\s*no-daemon\>"
syn match DnsmasqKeyword "^\s*no-dhcp-interface\>"
syn match DnsmasqKeyword "^\s*no-hosts\>"
syn match DnsmasqKeyword "^\s*no-negcache\>"
syn match DnsmasqKeyword "^\s*no-ping\>"
syn match DnsmasqKeyword "^\s*no-poll\>"
syn match DnsmasqKeyword "^\s*no-resolv\>"
syn match DnsmasqKeyword "^\s*proxy-dnssec\>"
syn match DnsmasqKeyword "^\s*ptr-record\>"
syn match DnsmasqKeyword "^\s*pxe-prompt\>"
syn match DnsmasqKeyword "^\s*pxe-service\>"
syn match DnsmasqKeyword "^\s*read-ethers\>"
syn match DnsmasqKeyword "^\s*rebind-localhost-ok\>"
syn match DnsmasqKeyword "^\s*resolv-file\>"
syn match DnsmasqKeyword "^\s*selfmx\>"
syn match DnsmasqKeyword "^\s*server\>"
syn match DnsmasqKeyword "^\s*srv-host\>"
syn match DnsmasqKeyword "^\s*stop-dns-rebind\>"
syn match DnsmasqKeyword "^\s*strict-order\>"
syn match DnsmasqKeyword "^\s*tftp-no-blocksize\>"
syn match DnsmasqKeyword "^\s*tftp-root\>"
syn match DnsmasqKeyword "^\s*tftp-secure\>"
syn match DnsmasqKeyword "^\s*tftp-unique-root\>"
syn match DnsmasqKeyword "^\s*txt-record\>"
syn match DnsmasqKeyword "^\s*user\>"
if b:dnsmasq_backrgound_light == 1
hi def DnsmasqParams ctermfg=DarkGreen guifg=DarkGreen
hi def DnsmasqKeyword ctermfg=DarkGreen guifg=DarkGreen
else
hi def link DnsmasqKeyword Keyword
hi def link DnsmasqParams Keyword
endif
hi def link DnsmasqKeywordSpecial Type
hi def link DnsmasqTodo Todo
hi def link DnsmasqSpecial Constant
hi def link DnsmasqIPv4 Identifier
hi def link DnsmasqSubnet2 DnsmasqSubnet
hi def link DnsmasqSubnet DnsmasqMac
hi def link DnsmasqRange DnsmasqMac
hi def link DnsmasqMac Preproc
hi def link DnsmasqTime Preproc
hi def link DnsmasqComment Comment
hi def link DnsmasqString Constant
hi def link DnsmasqValues Normal
let b:current_syntax = "dnsmasq"

View File

@ -1,9 +1,10 @@
" Vim syntax file " Vim syntax file
" Language: Configuration File (ini file) for MSDOS/MS Windows " Language: Configuration File (ini file) for MSDOS/MS Windows
" Version Info: @(#)dosini.vim 1.6 97/12/15 08:54:12 " Version: 2.0
" Author: Sean M. McKee <mckee@misslink.net> " Original Author: Sean M. McKee <mckee@misslink.net>
" Maintainer: Nima Talebi <nima@it.net.au> " Previous Maintainer: Nima Talebi <nima@it.net.au>
" Last Change: Mon, 26 Jun 2006 22:07:28 +1000 " Current Maintainer: Hong Xu <xuhdev@gmail.com>
" Last Change: 2011 Jul 21
" For version 5.x: Clear all syntax items " For version 5.x: Clear all syntax items
@ -17,9 +18,13 @@ endif
" shut case off " shut case off
syn case ignore syn case ignore
syn match dosiniLabel "^.\{-}=" syn match dosiniBool "\<\(yes\|no\|y\|n\|true\|false\)\>"
syn region dosiniHeader start="^\[" end="\]" syn match dosiniNumber "\<\d\+\>"
syn match dosiniComment "^;.*$" syn match dosiniNumber "\<\d*\.\d\+\>"
syn match dosiniNumber "\<\d\+e[+-]\=\d\+\>"
syn match dosiniLabel "^.\{-}="
syn region dosiniHeader start="^\s*\[" end="\]"
syn match dosiniComment "^[#;].*$"
" Define the default highlighting. " Define the default highlighting.
" For version 5.7 and earlier: only when not done already " For version 5.7 and earlier: only when not done already
@ -32,13 +37,15 @@ if version >= 508 || !exists("did_dosini_syntax_inits")
command -nargs=+ HiLink hi def link <args> command -nargs=+ HiLink hi def link <args>
endif endif
HiLink dosiniHeader Special HiLink dosiniBool Boolean
HiLink dosiniComment Comment HiLink dosiniNumber Number
HiLink dosiniLabel Type HiLink dosiniHeader Special
HiLink dosiniComment Comment
HiLink dosiniLabel Type
delcommand HiLink delcommand HiLink
endif endif
let b:current_syntax = "dosini" let b:current_syntax = "dosini"
" vim:ts=8 " vim: sts=2 sw=2 et

View File

@ -3,7 +3,7 @@
" Filenames: *.dot " Filenames: *.dot
" Maintainer: Markus Mottl <markus.mottl@gmail.com> " Maintainer: Markus Mottl <markus.mottl@gmail.com>
" URL: http://www.ocaml.info/vim/syntax/dot.vim " URL: http://www.ocaml.info/vim/syntax/dot.vim
" Last Change: 2006 Feb 05 " Last Change: 2011 May 17 - improved identifier matching + two new keywords
" 2001 May 04 - initial version " 2001 May 04 - initial version
" For version 5.x: Clear all syntax items " For version 5.x: Clear all syntax items
@ -47,10 +47,10 @@ syn keyword dotType shape shapefile sides skew width
" Edge attributes " Edge attributes
syn keyword dotType arrowhead arrowsize arrowtail constraint decorateP syn keyword dotType arrowhead arrowsize arrowtail constraint decorateP
syn keyword dotType dir headclip headlabel labelangle labeldistance syn keyword dotType dir headclip headlabel headport labelangle labeldistance
syn keyword dotType labelfontcolor labelfontname labelfontsize syn keyword dotType labelfontcolor labelfontname labelfontsize
syn keyword dotType minlen port_label_distance samehead sametail syn keyword dotType minlen port_label_distance samehead sametail
syn keyword dotType tailclip taillabel weight syn keyword dotType tailclip taillabel tailport weight
" Shared attributes (graphs, nodes, edges) " Shared attributes (graphs, nodes, edges)
syn keyword dotType color syn keyword dotType color
@ -67,7 +67,7 @@ syn match dotKeyChar ";"
syn match dotKeyChar "->" syn match dotKeyChar "->"
" Identifier " Identifier
syn match dotIdentifier /\<\w\+\>/ syn match dotIdentifier /\<\w\+\(:\w\+\)\?\>/
" Synchronization " Synchronization
syn sync minlines=50 syn sync minlines=50

View File

@ -1,9 +1,9 @@
" Vim syntax file " Vim syntax file
" Language: GDMO " Language: GDMO
" (ISO-10165-4; Guidelines for the Definition of Managed Object) " (ISO-10165-4; Guidelines for the Definition of Managed Object)
" Maintainer: Gyuman Kim <violino@dooly.modacom.co.kr> " Maintainer: Gyuman (Chester) Kim <violkim@gmail.com>
" URL: http://dooly.modacom.co.kr/gdmo.vim " URL: http://classicalprogrammer.wikidot.com/local--files/vim-syntax-file-for-gdmo/gdmo.vim
" Last change: 2001 Sep 02 " Last change: 8th June, 2011
" For version 5.x: Clear all syntax items " For version 5.x: Clear all syntax items
" For version 6.x: Quit when a syntax file was already loaded " For version 6.x: Quit when a syntax file was already loaded

93
runtime/syntax/gnash.vim Normal file
View File

@ -0,0 +1,93 @@
" Vim syntax file
" Language: gnash(1) configuration files
" http://www.gnu.org/software/gnash/manual/gnashuser.html#gnashrc
" Maintainer: Thilo Six <T.Six@gmx.de>
" Last Change: 2011 Jul 02
" Credidts: derived from readline.vim
" Nikolai Weibull
"
" 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
elseif exists ("b:current_syntax")
finish
endif
syn case match
syn keyword GnashTodo contained TODO FIXME XXX NOTE
" Comments
syn match GnashComment "^#.*$" contains=GnashTodo
syn match GnashComment "\s#.*$" contains=GnashTodo
syn match GnashNumber display '\<\d\+\>'
syn case ignore
syn keyword GnashOn ON YES TRUE
syn keyword GnashOff OFF NO FALSE
syn case match
syn match GnashSet '^\s*set\>'
syn match GnashSet '^\s*append\>'
syn case ignore
syn match GnashKeyword '\<CertDir\>'
syn match GnashKeyword '\<ASCodingErrorsVerbosity\>'
syn match GnashKeyword '\<CertFile\>'
syn match GnashKeyword '\<EnableExtensions\>'
syn match GnashKeyword '\<HWAccel\>'
syn match GnashKeyword '\<LCShmKey\>'
syn match GnashKeyword '\<LocalConnection\>'
syn match GnashKeyword '\<MalformedSWFVerbosity\>'
syn match GnashKeyword '\<Renderer\>'
syn match GnashKeyword '\<RootCert\>'
syn match GnashKeyword '\<SOLReadOnly\>'
syn match GnashKeyword '\<SOLSafeDir\>'
syn match GnashKeyword '\<SOLreadonly\>'
syn match GnashKeyword '\<SOLsafedir\>'
syn match GnashKeyword '\<StartStopped\>'
syn match GnashKeyword '\<StreamsTimeout\>'
syn match GnashKeyword '\<URLOpenerFormat\>'
syn match GnashKeyword '\<XVideo\>'
syn match GnashKeyword '\<actionDump\>'
syn match GnashKeyword '\<blacklist\>'
syn match GnashKeyword '\<debugger\>'
syn match GnashKeyword '\<debuglog\>'
syn match GnashKeyword '\<delay\>'
syn match GnashKeyword '\<enableExtensions\>'
syn match GnashKeyword '\<flashSystemManufacturer\>'
syn match GnashKeyword '\<flashSystemOS\>'
syn match GnashKeyword '\<flashVersionString\>'
syn match GnashKeyword '\<ignoreFSCommand\>'
syn match GnashKeyword '\<ignoreShowMenu\>'
syn match GnashKeyword '\<insecureSSL\>'
syn match GnashKeyword '\<localSandboxPath\>'
syn match GnashKeyword '\<localdomain\>'
syn match GnashKeyword '\<localhost\>'
syn match GnashKeyword '\<microphoneDevice\>'
syn match GnashKeyword '\<parserDump\>'
syn match GnashKeyword '\<pluginsound\>'
syn match GnashKeyword '\<quality\>'
syn match GnashKeyword '\<solLocalDomain\>'
syn match GnashKeyword '\<sound\>'
syn match GnashKeyword '\<splashScreen\>'
syn match GnashKeyword '\<startStopped\>'
syn match GnashKeyword '\<streamsTimeout\>'
syn match GnashKeyword '\<urlOpenerFormat\>'
syn match GnashKeyword '\<verbosity\>'
syn match GnashKeyword '\<webcamDevice\>'
syn match GnashKeyword '\<whitelist\>'
syn match GnashKeyword '\<writelog\>'
hi def link GnashOn Identifier
hi def link GnashOff Preproc
hi def link GnashComment Comment
hi def link GnashTodo Todo
hi def link GnashString String
hi def link GnashNumber Type
hi def link GnashSet String
hi def link GnashKeyword Keyword
let b:current_syntax = "gnash"

View File

@ -1,7 +1,7 @@
" Vim syntax file " Vim syntax file
" Language: Vim help file " Language: Vim help file
" Maintainer: Bram Moolenaar (Bram@vim.org) " Maintainer: Bram Moolenaar (Bram@vim.org)
" Last Change: 2010 Nov 03 " Last Change: 2011 Jul 11
" Quit when a (custom) syntax file was already loaded " Quit when a (custom) syntax file was already loaded
if exists("b:current_syntax") if exists("b:current_syntax")
@ -21,8 +21,13 @@ else
syn match helpHyperTextEntry "\*[#-)!+-~]\+\*\s"he=e-1 contains=helpStar syn match helpHyperTextEntry "\*[#-)!+-~]\+\*\s"he=e-1 contains=helpStar
syn match helpHyperTextEntry "\*[#-)!+-~]\+\*$" contains=helpStar syn match helpHyperTextEntry "\*[#-)!+-~]\+\*$" contains=helpStar
endif endif
syn match helpBar contained "|" conceal if has("conceal")
syn match helpStar contained "\*" conceal syn match helpBar contained "|" conceal
syn match helpStar contained "\*" conceal
else
syn match helpBar contained "|"
syn match helpStar contained "\*"
endif
syn match helpNormal "|.*====*|" syn match helpNormal "|.*====*|"
syn match helpNormal ":|vim:|" " for :help modeline syn match helpNormal ":|vim:|" " for :help modeline
syn match helpVim "Vim version [0-9.a-z]\+" syn match helpVim "Vim version [0-9.a-z]\+"
@ -31,7 +36,11 @@ syn match helpOption "'[a-z]\{2,\}'"
syn match helpOption "'t_..'" syn match helpOption "'t_..'"
syn match helpHeader "\s*\zs.\{-}\ze\s\=\~$" nextgroup=helpIgnore syn match helpHeader "\s*\zs.\{-}\ze\s\=\~$" nextgroup=helpIgnore
syn match helpGraphic ".* \ze`$" nextgroup=helpIgnore syn match helpGraphic ".* \ze`$" nextgroup=helpIgnore
syn match helpIgnore "." contained conceal if has("conceal")
syn match helpIgnore "." contained conceal
else
syn match helpIgnore "." contained
endif
syn keyword helpNote note Note NOTE note: Note: NOTE: Notes Notes: syn keyword helpNote note Note NOTE note: Note: NOTE: Notes Notes:
syn match helpSpecial "\<N\>" syn match helpSpecial "\<N\>"
syn match helpSpecial "\<N\.$"me=e-1 syn match helpSpecial "\<N\.$"me=e-1

View File

@ -0,0 +1,27 @@
" Vim syntax file
" Language: hosts.deny, hosts.allow configuration files
" Maintainer: Thilo Six <T.Six@gmx.de>
" Last Change: 2011 May 01
" Derived From: conf.vim
" Credits: Bram Moolenaar
"
" This file is there to get at least a minimal highlighting.
" A later version may be improved.
" Quit when a (custom) syntax file was already loaded
if exists("b:current_syntax")
finish
endif
" For a starter we just use conf.vim for highlighting
if version < 600
so <sfile>:p:h/conf.vim
else
runtime! syntax/conf.vim
unlet b:current_syntax
endif
let b:current_syntax = "hostsaccess"
" vim: ts=8 sw=2

View File

@ -1,6 +1,6 @@
" Interactive Data Language syntax file (IDL, too [:-)] " Interactive Data Language syntax file (IDL, too [:-)]
" Maintainer: Aleksandar Jelenak <ajelenak AT yahoo.com> " Maintainer: Aleksandar Jelenak <ajelenak AT yahoo.com>
" Last change: 2003 Apr 25 " Last change: 2011 Apr 11
" Created by: Hermann Rochholz <Hermann.Rochholz AT gmx.de> " Created by: Hermann Rochholz <Hermann.Rochholz AT gmx.de>
" Remove any old syntax stuff hanging around " Remove any old syntax stuff hanging around
@ -113,7 +113,7 @@ syn keyword idlangRoutine EXPAND_PATH EXPINT EXTRAC EXTRACT_SLICE F_CVF
syn keyword idlangRoutine F_PDF FACTORIAL FFT FILE_CHMOD FILE_DELETE syn keyword idlangRoutine F_PDF FACTORIAL FFT FILE_CHMOD FILE_DELETE
syn keyword idlangRoutine FILE_EXPAND_PATH FILE_MKDIR FILE_TEST FILE_WHICH syn keyword idlangRoutine FILE_EXPAND_PATH FILE_MKDIR FILE_TEST FILE_WHICH
syn keyword idlangRoutine FILEPATH FINDFILE FINDGEN FINITE FIX FLICK FLOAT syn keyword idlangRoutine FILEPATH FINDFILE FINDGEN FINITE FIX FLICK FLOAT
syn keyword idlangRoutine FLOOR FLOW3 FLTARR FLUSH FOR FORMAT_AXIS_VALUES syn keyword idlangRoutine FLOOR FLOW3 FLTARR FLUSH FORMAT_AXIS_VALUES
syn keyword idlangRoutine FORWARD_FUNCTION FREE_LUN FSTAT FULSTR FUNCT syn keyword idlangRoutine FORWARD_FUNCTION FREE_LUN FSTAT FULSTR FUNCT
syn keyword idlangRoutine FV_TEST FX_ROOT FZ_ROOTS GAMMA GAMMA_CT syn keyword idlangRoutine FV_TEST FX_ROOT FZ_ROOTS GAMMA GAMMA_CT
syn keyword idlangRoutine GAUSS_CVF GAUSS_PDF GAUSS2DFIT GAUSSFIT GAUSSINT syn keyword idlangRoutine GAUSS_CVF GAUSS_PDF GAUSS2DFIT GAUSSFIT GAUSSINT

110
runtime/syntax/jovial.vim Normal file
View File

@ -0,0 +1,110 @@
" Vim syntax file
" Language: JOVIAL J73
" Version: 1.2
" Maintainer: Paul McGinnis <paulmcg@aol.com>
" Last Change: 2011/06/17
" Remark: Based on MIL-STD-1589C for JOVIAL J73 language
" Quit when a (custom) syntax file was already loaded
if exists("b:current_syntax")
finish
endif
syn case ignore
syn keyword jovialTodo TODO FIXME XXX contained
" JOVIAL beads - first digit is number of bits, [0-9A-V] is the bit value
" representing 0-31 (for 5 bits on the bead)
syn match jovialBitConstant "[1-5]B'[0-9A-V]'"
syn match jovialNumber "\<\d\+\>"
syn match jovialFloat "\d\+E[-+]\=\d\+"
syn match jovialFloat "\d\+\.\d*\(E[-+]\=\d\+\)\="
syn match jovialFloat "\.\d\+\(E[-+]\=\d\+\)\="
syn region jovialComment start=/"/ end=/"/ contains=jovialTodo
syn region jovialComment start=/%/ end=/%/ contains=jovialTodo
" JOVIAL variable names. This rule is to prevent conflicts with strings.
" Handle special case where ' character can be part of a JOVIAL variable name.
syn match jovialIdentifier "[A-Z\$][A-Z0-9'\$]\+"
syn region jovialString start="\s*'" skip=/''/ end=/'/ oneline
" JOVIAL compiler directives -- see Section 9 in MIL-STD-1589C
syn region jovialPreProc start="\s*![A-Z]\+" end=/;/
syn keyword jovialOperator AND OR NOT XOR EQV MOD
" See Section 2.1 in MIL-STD-1589C for data types
syn keyword jovialType ITEM B C P V
syn match jovialType "\<S\(,R\|,T\|,Z\)\=\>"
syn match jovialType "\<U\(,R\|,T\|,Z\)\=\>"
syn match jovialType "\<F\(,R\|,T\|,Z\)\=\>"
syn match jovialType "\<A\(,R\|,T\|,Z\)\=\>"
syn keyword jovialStorageClass STATIC CONSTANT PARALLEL BLOCK N M D W
syn keyword jovialStructure TABLE STATUS
syn keyword jovialConstant NULL
syn keyword jovialBoolean FALSE TRUE
syn keyword jovialTypedef TYPE
syn keyword jovialStatement ABORT BEGIN BY BYREF BYRES BYVAL CASE COMPOOL
syn keyword jovialStatement DEF DEFAULT DEFINE ELSE END EXIT FALLTHRU FOR
syn keyword jovialStatement GOTO IF INLINE INSTANCE LABEL LIKE OVERLAY POS
syn keyword jovialStatement PROC PROGRAM REC REF RENT REP RETURN START STOP
syn keyword jovialStatement TERM THEN WHILE
" JOVIAL extensions, see section 8.2.2 in MIL-STD-1589C
syn keyword jovialStatement CONDITION ENCAPSULATION EXPORTS FREE HANDLER IN INTERRUPT NEW
syn keyword jovialStatement PROTECTED READONLY REGISTER SIGNAL TO UPDATE WITH WRITEONLY ZONE
" implementation specific constants and functions, see section 1.4 in MIL-STD-1589C
syn keyword jovialConstant BITSINBYTE BITSINWORD LOCSINWORD
syn keyword jovialConstant BYTESINWORD BITSINPOINTER INTPRECISION
syn keyword jovialConstant FLOATPRECISION FIXEDPRECISION FLOATRADIX
syn keyword jovialConstant MAXFLOATPRECISION MAXFIXEDPRECISION
syn keyword jovialConstant MAXINTSIZE MAXBYTES MAXBITS
syn keyword jovialConstant MAXTABLESIZE MAXSTOP MINSTOP MAXSIGDIGITS
syn keyword jovialFunction BYTEPOS MAXINT MININT
syn keyword jovialFunction IMPLFLOATPRECISION IMPLFIXEDPRECISION IMPLINTSIZE
syn keyword jovialFunction MINSIZE MINFRACTION MINSCALE MINRELPRECISION
syn keyword jovialFunction MAXFLOAT MINFLOAT FLOATRELPRECISION
syn keyword jovialFunction FLOATUNDERFLOW MAXFIXED MINFIXED
" JOVIAL built-in functions
syn keyword jovialFunction LOC NEXT BIT BYTE SHIFTL SHIFTR ABS SGN BITSIZE
syn keyword jovialFunction BYTESIZE WORDSIZE LBOUND UBOUND NWDSEN FIRST
syn keyword jovialFunction LAST NENT
" Define the default highlighting.
hi def link jovialBitConstant Number
hi def link jovialBoolean Boolean
hi def link jovialComment Comment
hi def link jovialConstant Constant
hi def link jovialFloat Float
hi def link jovialFunction Function
" No color highlighting for JOVIAL identifiers. See above,
" this is to prevent confusion with JOVIAL strings
"hi def link jovialIdentifier Identifier
hi def link jovialNumber Number
hi def link jovialOperator Operator
hi def link jovialPreProc PreProc
hi def link jovialStatement Statement
hi def link jovialStorageClass StorageClass
hi def link jovialString String
hi def link jovialStructure Structure
hi def link jovialTodo Todo
hi def link jovialType Type
hi def link jovialTypedef Typedef
let b:current_syntax = "jovial"
" vim: ts=8

View File

@ -4,6 +4,8 @@
" Credits: Preben 'Peppe' Guldberg <peppe-vim@wielders.org> " Credits: Preben 'Peppe' Guldberg <peppe-vim@wielders.org>
" Original author: Mario Eusebio " Original author: Mario Eusebio
" Last Change: Wed Jan 13 11:12:34 CET 2010 " Last Change: Wed Jan 13 11:12:34 CET 2010
" sinh added to matlab implicit commands
" Change History:
" - 'global' and 'persistent' keyword are now recognized " - 'global' and 'persistent' keyword are now recognized
" For version 5.x: Clear all syntax items " For version 5.x: Clear all syntax items
@ -68,7 +70,7 @@ syn keyword matlabOperator ceil floor size clear zeros eye mean std cov
syn keyword matlabFunction error eval function syn keyword matlabFunction error eval function
syn keyword matlabImplicit abs acos atan asin cos cosh exp log prod sum syn keyword matlabImplicit abs acos atan asin cos cosh exp log prod sum
syn keyword matlabImplicit log10 max min sign sin sqrt tan reshape syn keyword matlabImplicit log10 max min sign sin sinh sqrt tan reshape
syn match matlabError "-\=\<\d\+\.\d\+\.[^*/\\^]" syn match matlabError "-\=\<\d\+\.\d\+\.[^*/\\^]"
syn match matlabError "-\=\<\d\+\.\d\+[eEdD][-+]\=\d\+\.\([^*/\\^]\)" syn match matlabError "-\=\<\d\+\.\d\+[eEdD][-+]\=\d\+\.\([^*/\\^]\)"

View File

@ -88,7 +88,7 @@ if !exists("did_drchip_netrwlist_syntax")
hi default link netrwTimeSep netrwDateSep hi default link netrwTimeSep netrwDateSep
hi default link netrwComma netrwComment hi default link netrwComma netrwComment
hi default link netrwHide netrwComment hi default link netrwHide netrwComment
hi default link netrwMarkFile DiffChange hi default link netrwMarkFile TabLineSel
" special syntax highlighting (see :he g:netrw_special_syntax) " special syntax highlighting (see :he g:netrw_special_syntax)
hi default link netrwBak NonText hi default link netrwBak NonText

View File

@ -5,9 +5,9 @@
" Karl-Heinz Sylla <Karl-Heinz.Sylla@gmd.de> " Karl-Heinz Sylla <Karl-Heinz.Sylla@gmd.de>
" Issac Trotts <ijtrotts@ucdavis.edu> " Issac Trotts <ijtrotts@ucdavis.edu>
" URL: http://www.ocaml.info/vim/syntax/ocaml.vim " URL: http://www.ocaml.info/vim/syntax/ocaml.vim
" Last Change: 2007 Apr 13 - Added highlighting of nativeints (MM) " Last Change: 2010 Oct 11 - Added highlighting of lnot (MM, thanks to Erick Matsen)
" 2006 Oct 09 - More highlighting improvements to numbers (MM) " 2010 Sep 03 - Fixed escaping bug (MM, thanks to Florent Monnier)
" 2006 Sep 19 - Improved highlighting of numbers (Florent Monnier) " 2010 Aug 07 - Fixed module type bug (MM)
" A minor patch was applied to the official version so that object/end " A minor patch was applied to the official version so that object/end
" can be distinguished from begin/end, which is used for indentation, " can be distinguished from begin/end, which is used for indentation,
@ -24,14 +24,14 @@ endif
" OCaml is case sensitive. " OCaml is case sensitive.
syn case match syn case match
" Access to the method of an object
syn match ocamlMethod "#"
" Script headers highlighted like comments " Script headers highlighted like comments
syn match ocamlComment "^#!.*" syn match ocamlComment "^#!.*"
" Scripting directives " Scripting directives
syn match ocamlScript "^#\<\(quit\|labels\|warnings\|directory\|cd\|load\|use\|install_printer\|remove_printer\|require\|thread\|trace\|untrace\|untrace_all\|print_depth\|print_length\)\>" syn match ocamlScript "^#\<\(quit\|labels\|warnings\|directory\|cd\|load\|use\|install_printer\|remove_printer\|require\|thread\|trace\|untrace\|untrace_all\|print_depth\|print_length\|camlp4o\)\>"
" Script headers highlighted like comments
syn match ocamlComment "^#!.*"
" lowercase identifier - the standard way to match " lowercase identifier - the standard way to match
syn match ocamlLCIdentifier /\<\(\l\|_\)\(\w\|'\)*\>/ syn match ocamlLCIdentifier /\<\(\l\|_\)\(\w\|'\)*\>/
@ -69,7 +69,7 @@ syn cluster ocamlAllErrs contains=ocamlBraceErr,ocamlBrackErr,ocamlParenErr,oca
syn cluster ocamlAENoParen contains=ocamlBraceErr,ocamlBrackErr,ocamlCommentErr,ocamlCountErr,ocamlDoErr,ocamlDoneErr,ocamlEndErr,ocamlThenErr syn cluster ocamlAENoParen contains=ocamlBraceErr,ocamlBrackErr,ocamlCommentErr,ocamlCountErr,ocamlDoErr,ocamlDoneErr,ocamlEndErr,ocamlThenErr
syn cluster ocamlContained contains=ocamlTodo,ocamlPreDef,ocamlModParam,ocamlModParam1,ocamlPreMPRestr,ocamlMPRestr,ocamlMPRestr1,ocamlMPRestr2,ocamlMPRestr3,ocamlModRHS,ocamlFuncWith,ocamlFuncStruct,ocamlModTypeRestr,ocamlModTRWith,ocamlWith,ocamlWithRest,ocamlModType,ocamlFullMod syn cluster ocamlContained contains=ocamlTodo,ocamlPreDef,ocamlModParam,ocamlModParam1,ocamlPreMPRestr,ocamlMPRestr,ocamlMPRestr1,ocamlMPRestr2,ocamlMPRestr3,ocamlModRHS,ocamlFuncWith,ocamlFuncStruct,ocamlModTypeRestr,ocamlModTRWith,ocamlWith,ocamlWithRest,ocamlModType,ocamlFullMod,ocamlVal
" Enclosing delimiters " Enclosing delimiters
@ -109,9 +109,6 @@ syn region ocamlNone matchgroup=ocamlKeyword start="\<if\>" matchgroup=ocamlKe
"" Modules "" Modules
" "struct"
syn region ocamlStruct matchgroup=ocamlModule start="\<struct\>" matchgroup=ocamlModule end="\<end\>" contains=ALLBUT,@ocamlContained,ocamlEndErr
" "sig" " "sig"
syn region ocamlSig matchgroup=ocamlModule start="\<sig\>" matchgroup=ocamlModule end="\<end\>" contains=ALLBUT,@ocamlContained,ocamlEndErr,ocamlModule syn region ocamlSig matchgroup=ocamlModule start="\<sig\>" matchgroup=ocamlModule end="\<end\>" contains=ALLBUT,@ocamlContained,ocamlEndErr,ocamlModule
syn region ocamlModSpec matchgroup=ocamlKeyword start="\<module\>" matchgroup=ocamlModule end="\<\u\(\w\|'\)*\>" contained contains=@ocamlAllErrs,ocamlComment skipwhite skipempty nextgroup=ocamlModTRWith,ocamlMPRestr syn region ocamlModSpec matchgroup=ocamlKeyword start="\<module\>" matchgroup=ocamlModule end="\<\u\(\w\|'\)*\>" contained contains=@ocamlAllErrs,ocamlComment skipwhite skipempty nextgroup=ocamlModTRWith,ocamlMPRestr
@ -124,8 +121,8 @@ syn match ocamlKeyword "\<include\>" skipwhite skipempty nextgroup=ocamlModPa
" "module" - somewhat complicated stuff ;-) " "module" - somewhat complicated stuff ;-)
syn region ocamlModule matchgroup=ocamlKeyword start="\<module\>" matchgroup=ocamlModule end="\<\u\(\w\|'\)*\>" contains=@ocamlAllErrs,ocamlComment skipwhite skipempty nextgroup=ocamlPreDef syn region ocamlModule matchgroup=ocamlKeyword start="\<module\>" matchgroup=ocamlModule end="\<\u\(\w\|'\)*\>" contains=@ocamlAllErrs,ocamlComment skipwhite skipempty nextgroup=ocamlPreDef
syn region ocamlPreDef start="."me=e-1 matchgroup=ocamlKeyword end="\l\|="me=e-1 contained contains=@ocamlAllErrs,ocamlComment,ocamlModParam,ocamlModTypeRestr,ocamlModTRWith nextgroup=ocamlModPreRHS syn region ocamlPreDef start="."me=e-1 matchgroup=ocamlKeyword end="\l\|=\|)"me=e-1 contained contains=@ocamlAllErrs,ocamlComment,ocamlModParam,ocamlModTypeRestr,ocamlModTRWith nextgroup=ocamlModPreRHS
syn region ocamlModParam start="([^*]" end=")" contained contains=@ocamlAENoParen,ocamlModParam1 syn region ocamlModParam start="([^*]" end=")" contained contains=@ocamlAENoParen,ocamlModParam1,ocamlVal
syn match ocamlModParam1 "\<\u\(\w\|'\)*\>" contained skipwhite skipempty nextgroup=ocamlPreMPRestr syn match ocamlModParam1 "\<\u\(\w\|'\)*\>" contained skipwhite skipempty nextgroup=ocamlPreMPRestr
syn region ocamlPreMPRestr start="."me=e-1 end=")"me=e-1 contained contains=@ocamlAllErrs,ocamlComment,ocamlMPRestr,ocamlModTypeRestr syn region ocamlPreMPRestr start="."me=e-1 end=")"me=e-1 contained contains=@ocamlAllErrs,ocamlComment,ocamlMPRestr,ocamlModTypeRestr
@ -135,6 +132,8 @@ syn region ocamlMPRestr1 matchgroup=ocamlModule start="\ssig\s\=" matchgroup=o
syn region ocamlMPRestr2 start="\sfunctor\(\s\|(\)\="me=e-1 matchgroup=ocamlKeyword end="->" contained contains=@ocamlAllErrs,ocamlComment,ocamlModParam skipwhite skipempty nextgroup=ocamlFuncWith,ocamlMPRestr2 syn region ocamlMPRestr2 start="\sfunctor\(\s\|(\)\="me=e-1 matchgroup=ocamlKeyword end="->" contained contains=@ocamlAllErrs,ocamlComment,ocamlModParam skipwhite skipempty nextgroup=ocamlFuncWith,ocamlMPRestr2
syn match ocamlMPRestr3 "\w\(\w\|'\)*\(\.\w\(\w\|'\)*\)*" contained syn match ocamlMPRestr3 "\w\(\w\|'\)*\(\.\w\(\w\|'\)*\)*" contained
syn match ocamlModPreRHS "=" contained skipwhite skipempty nextgroup=ocamlModParam,ocamlFullMod syn match ocamlModPreRHS "=" contained skipwhite skipempty nextgroup=ocamlModParam,ocamlFullMod
syn keyword ocamlKeyword val
syn region ocamlVal matchgroup=ocamlKeyword start="\<val\>" matchgroup=ocamlLCIdentifier end="\<\l\(\w\|'\)*\>" contains=@ocamlAllErrs,ocamlComment skipwhite skipempty nextgroup=ocamlMPRestr
syn region ocamlModRHS start="." end=".\w\|([^*]"me=e-2 contained contains=ocamlComment skipwhite skipempty nextgroup=ocamlModParam,ocamlFullMod syn region ocamlModRHS start="." end=".\w\|([^*]"me=e-2 contained contains=ocamlComment skipwhite skipempty nextgroup=ocamlModParam,ocamlFullMod
syn match ocamlFullMod "\<\u\(\w\|'\)*\(\.\u\(\w\|'\)*\)*" contained skipwhite skipempty nextgroup=ocamlFuncWith syn match ocamlFullMod "\<\u\(\w\|'\)*\(\.\u\(\w\|'\)*\)*" contained skipwhite skipempty nextgroup=ocamlFuncWith
@ -146,8 +145,11 @@ syn region ocamlModTRWith start=":\s*("hs=s+1 end=")" contained contains=@ocam
syn match ocamlWith "\<\(\u\(\w\|'\)*\.\)*\w\(\w\|'\)*\>" contained skipwhite skipempty nextgroup=ocamlWithRest syn match ocamlWith "\<\(\u\(\w\|'\)*\.\)*\w\(\w\|'\)*\>" contained skipwhite skipempty nextgroup=ocamlWithRest
syn region ocamlWithRest start="[^)]" end=")"me=e-1 contained contains=ALLBUT,@ocamlContained syn region ocamlWithRest start="[^)]" end=")"me=e-1 contained contains=ALLBUT,@ocamlContained
" "struct"
syn region ocamlStruct matchgroup=ocamlModule start="\<\(module\s\+\)\=struct\>" matchgroup=ocamlModule end="\<end\>" contains=ALLBUT,@ocamlContained,ocamlEndErr
" "module type" " "module type"
syn region ocamlKeyword start="\<module\>\s*\<type\>" matchgroup=ocamlModule end="\<\w\(\w\|'\)*\>" contains=ocamlComment skipwhite skipempty nextgroup=ocamlMTDef syn region ocamlKeyword start="\<module\>\s*\<type\>\(\s*\<of\>\)\=" matchgroup=ocamlModule end="\<\w\(\w\|'\)*\>" contains=ocamlComment skipwhite skipempty nextgroup=ocamlMTDef
syn match ocamlMTDef "=\s*\w\(\w\|'\)*\>"hs=s+1,me=s syn match ocamlMTDef "=\s*\w\(\w\|'\)*\>"hs=s+1,me=s
syn keyword ocamlKeyword and as assert class syn keyword ocamlKeyword and as assert class
@ -159,7 +161,7 @@ syn keyword ocamlKeyword land lazy let match
syn keyword ocamlKeyword method mutable new of syn keyword ocamlKeyword method mutable new of
syn keyword ocamlKeyword parser private raise rec syn keyword ocamlKeyword parser private raise rec
syn keyword ocamlKeyword try type syn keyword ocamlKeyword try type
syn keyword ocamlKeyword val virtual when while with syn keyword ocamlKeyword virtual when while with
if exists("ocaml_revised") if exists("ocaml_revised")
syn keyword ocamlKeyword do value syn keyword ocamlKeyword do value
@ -174,7 +176,7 @@ syn keyword ocamlType array bool char exn float format format4
syn keyword ocamlType int int32 int64 lazy_t list nativeint option syn keyword ocamlType int int32 int64 lazy_t list nativeint option
syn keyword ocamlType string unit syn keyword ocamlType string unit
syn keyword ocamlOperator asr lor lsl lsr lxor mod not syn keyword ocamlOperator asr lnot lor lsl lsr lxor mod not
syn match ocamlConstructor "(\s*)" syn match ocamlConstructor "(\s*)"
syn match ocamlConstructor "\[\s*\]" syn match ocamlConstructor "\[\s*\]"
@ -189,6 +191,7 @@ syn match ocamlConstructor "`\w\(\w\|'\)*\>"
syn match ocamlModPath "\u\(\w\|'\)*\."he=e-1 syn match ocamlModPath "\u\(\w\|'\)*\."he=e-1
syn match ocamlCharacter "'\\\d\d\d'\|'\\[\'ntbr]'\|'.'" syn match ocamlCharacter "'\\\d\d\d'\|'\\[\'ntbr]'\|'.'"
syn match ocamlCharacter "'\\x\x\x'"
syn match ocamlCharErr "'\\\d\d'\|'\\\d'" syn match ocamlCharErr "'\\\d\d'\|'\\\d'"
syn match ocamlCharErr "'\\[^\'ntbr]'" syn match ocamlCharErr "'\\[^\'ntbr]'"
syn region ocamlString start=+"+ skip=+\\\\\|\\"+ end=+"+ syn region ocamlString start=+"+ skip=+\\\\\|\\"+ end=+"+
@ -220,7 +223,7 @@ syn match ocamlNumber "\<-\=\d\(_\|\d\)*[l|L|n]\?\>"
syn match ocamlNumber "\<-\=0[x|X]\(\x\|_\)\+[l|L|n]\?\>" syn match ocamlNumber "\<-\=0[x|X]\(\x\|_\)\+[l|L|n]\?\>"
syn match ocamlNumber "\<-\=0[o|O]\(\o\|_\)\+[l|L|n]\?\>" syn match ocamlNumber "\<-\=0[o|O]\(\o\|_\)\+[l|L|n]\?\>"
syn match ocamlNumber "\<-\=0[b|B]\([01]\|_\)\+[l|L|n]\?\>" syn match ocamlNumber "\<-\=0[b|B]\([01]\|_\)\+[l|L|n]\?\>"
syn match ocamlFloat "\<-\=\d\(_\|\d\)*\.\(_\|\d\)*\([eE][-+]\=\d\(_\|\d\)*\)\=\>" syn match ocamlFloat "\<-\=\d\(_\|\d\)*\.\?\(_\|\d\)*\([eE][-+]\=\d\(_\|\d\)*\)\=\>"
" Labels " Labels
syn match ocamlLabel "\~\(\l\|_\)\(\w\|'\)*"lc=1 syn match ocamlLabel "\~\(\l\|_\)\(\w\|'\)*"lc=1
@ -294,6 +297,7 @@ if version >= 508 || !exists("did_ocaml_syntax_inits")
HiLink ocamlConstructor Constant HiLink ocamlConstructor Constant
HiLink ocamlVal Keyword
HiLink ocamlModPreRHS Keyword HiLink ocamlModPreRHS Keyword
HiLink ocamlMPRestr2 Keyword HiLink ocamlMPRestr2 Keyword
HiLink ocamlKeyword Keyword HiLink ocamlKeyword Keyword

View File

@ -1,7 +1,7 @@
" Vim syntax file " Vim syntax file
" Language: pam(8) configuration file " Language: pam(8) configuration file
" Maintainer: Nikolai Weibull <now@bitwi.se> " Maintainer: Nikolai Weibull <now@bitwi.se>
" Latest Revision: 2006-04-19 " Latest Revision: 2011-08-03
if exists("b:current_syntax") if exists("b:current_syntax")
@ -33,7 +33,7 @@ syn match pamconfTypeLineCont contained '\\$'
\ pamconfTypeLineCont skipwhite skipnl \ pamconfTypeLineCont skipwhite skipnl
syn keyword pamconfControl contained requisite required sufficient syn keyword pamconfControl contained requisite required sufficient
\ optional \ optional include substack
\ nextgroup=pamconfMPath, \ nextgroup=pamconfMPath,
\ pamconfControlLineContH skipwhite \ pamconfControlLineContH skipwhite
@ -57,7 +57,9 @@ syn keyword pamconfControlValues contained success open_err symbol_err
\ bad_item and default \ bad_item and default
\ nextgroup=pamconfControlValueEq \ nextgroup=pamconfControlValueEq
syn match pamconfControlValueEq contained '=' nextgroup=pamconfControlAction syn match pamconfControlValueEq contained '='
\ nextgroup=pamconfControlActionN,
\ pamconfControlAction
syn match pamconfControlActionN contained '\d\+\>' syn match pamconfControlActionN contained '\d\+\>'
\ nextgroup=pamconfControlValues, \ nextgroup=pamconfControlValues,

File diff suppressed because it is too large Load Diff

View File

@ -1,11 +1,10 @@
" Vim syntax file " Vim syntax file
" Language: php PHP 3/4/5 " Language: php PHP 3/4/5
" Maintainer: Peter Hodge <toomuchphp-vim@yahoo.com> " Maintainer: Jason Woofenden <jason@jasonwoof.com>
" Last Change: June 9, 2006 " Last Change: July 29, 2011
" URL: http://www.vim.org/scripts/script.php?script_id=1571 " URL: https://gitorious.org/jasonwoof/vim-syntax/blobs/master/php.vim
" " Former Maintainers: Peter Hodge <toomuchphp-vim@yahoo.com>
" Former Maintainer: Debian VIM Maintainers <pkg-vim-maintainers@lists.alioth.debian.org> " Debian VIM Maintainers <pkg-vim-maintainers@lists.alioth.debian.org>
" Former URL: http://svn.debian.org/wsvn/pkg-vim/trunk/runtime/syntax/php.vim?op=file&rev=0&sc=0
" "
" Note: If you are using a colour terminal with dark background, you will probably find " Note: If you are using a colour terminal with dark background, you will probably find
" the 'elflord' colorscheme is much better for PHP's syntax than the default " the 'elflord' colorscheme is much better for PHP's syntax than the default
@ -55,14 +54,6 @@
" the string would be highlighted as an error, what is incorrect. " the string would be highlighted as an error, what is incorrect.
" ii) Same problem if you are setting php_folding = 2 with a closing " ii) Same problem if you are setting php_folding = 2 with a closing
" } inside an string on the first line of this string. " } inside an string on the first line of this string.
"
" - A double-quoted string like this:
" "$foo->someVar->someOtherVar->bar"
" will highight '->someOtherVar->bar' as though they will be parsed
" as object member variables, but PHP only recognizes the first
" object member variable ($foo->someVar).
"
"
" For version 5.x: Clear all syntax items " For version 5.x: Clear all syntax items
" For version 6.x: Quit when a syntax file was already loaded " For version 6.x: Quit when a syntax file was already loaded
@ -132,7 +123,7 @@ syn keyword phpCoreConstant PHP_VERSION PHP_OS DEFAULT_INCLUDE_PATH PEAR_INSTALL
syn case ignore syn case ignore
syn keyword phpConstant __LINE__ __FILE__ __FUNCTION__ __METHOD__ __CLASS__ contained syn keyword phpConstant __LINE__ __FILE__ __FUNCTION__ __METHOD__ __CLASS__ __DIR__ __NAMESPACE__ contained
" Function and Methods ripped from php_manual_de.tar.gz Jan 2003 " Function and Methods ripped from php_manual_de.tar.gz Jan 2003
@ -274,7 +265,7 @@ syn keyword phpRepeat as do endfor endforeach endwhile for foreach while contai
syn keyword phpLabel case default switch contained syn keyword phpLabel case default switch contained
" Statement " Statement
syn keyword phpStatement return break continue exit contained syn keyword phpStatement return break continue exit goto contained
" Keyword " Keyword
syn keyword phpKeyword var const contained syn keyword phpKeyword var const contained
@ -283,7 +274,7 @@ syn keyword phpKeyword var const contained
syn keyword phpType bool[ean] int[eger] real double float string array object NULL contained syn keyword phpType bool[ean] int[eger] real double float string array object NULL contained
" Structure " Structure
syn keyword phpStructure extends implements instanceof parent self contained syn keyword phpStructure namespace extends implements instanceof parent self contained
" Operator " Operator
syn match phpOperator "[-=+%^&|*!.~?:]" contained display syn match phpOperator "[-=+%^&|*!.~?:]" contained display
@ -303,11 +294,41 @@ syn match phpIdentifierSimply "${\h\w*}" contains=phpOperator,phpParent contai
syn region phpIdentifierComplex matchgroup=phpParent start="{\$"rs=e-1 end="}" contains=phpIdentifier,phpMemberSelector,phpVarSelector,phpIdentifierComplexP contained extend syn region phpIdentifierComplex matchgroup=phpParent start="{\$"rs=e-1 end="}" contains=phpIdentifier,phpMemberSelector,phpVarSelector,phpIdentifierComplexP contained extend
syn region phpIdentifierComplexP matchgroup=phpParent start="\[" end="]" contains=@phpClInside contained syn region phpIdentifierComplexP matchgroup=phpParent start="\[" end="]" contains=@phpClInside contained
" Interpolated indentifiers (inside strings)
syn match phpBrackets "[][}{]" contained display
" errors
syn match phpInterpSimpleError "\[[^]]*\]" contained display " fallback (if nothing else matches)
syn match phpInterpSimpleError "->[^a-zA-Z_]" contained display
" make sure these stay above the correct DollarCurlies so they don't take priority
syn match phpInterpBogusDollarCurley "${[^}]*}" contained display " fallback (if nothing else matches)
syn match phpinterpSimpleBracketsInner "\w\+" contained
syn match phpInterpSimpleBrackets "\[\h\w*]" contained contains=phpBrackets,phpInterpSimpleBracketsInner
syn match phpInterpSimpleBrackets "\[\d\+]" contained contains=phpBrackets,phpInterpSimpleBracketsInner
syn match phpInterpSimpleBrackets "\[0[xX]\x\+]" contained contains=phpBrackets,phpInterpSimpleBracketsInner
syn match phpInterpSimple "\$\h\w*\(\[[^]]*\]\|->\h\w*\)\?" contained contains=phpInterpSimpleBrackets,phpIdentifier,phpInterpSimpleError,phpMethods,phpMemberSelector display
syn match phpInterpVarname "\h\w*" contained
syn match phpInterpMethodName "\h\w*" contained " default color
syn match phpInterpSimpleCurly "\${\h\w*}" contains=phpInterpVarname contained extend
syn region phpInterpDollarCurley1Helper matchgroup=phpParent start="{" end="\[" contains=phpInterpVarname contained
syn region phpInterpDollarCurly1 matchgroup=phpParent start="\${\h\w*\["rs=s+1 end="]}" contains=phpInterpDollarCurley1Helper,@phpClConst contained extend
syn match phpInterpDollarCurley2Helper "{\h\w*->" contains=phpBrackets,phpInterpVarname,phpMemberSelector contained
syn region phpInterpDollarCurly2 matchgroup=phpParent start="\${\h\w*->"rs=s+1 end="}" contains=phpInterpDollarCurley2Helper,phpInterpMethodName contained
syn match phpInterpBogusDollarCurley "${\h\w*->}" contained display
syn match phpInterpBogusDollarCurley "${\h\w*\[]}" contained display
syn region phpInterpComplex matchgroup=phpParent start="{\$"rs=e-1 end="}" contains=phpIdentifier,phpMemberSelector,phpVarSelector,phpIdentifierComplexP contained extend
syn region phpIdentifierComplexP matchgroup=phpParent start="\[" end="]" contains=@phpClInside contained
" define a cluster to get all interpolation syntaxes for double-quoted strings
syn cluster phpInterpDouble contains=phpInterpSimple,phpInterpSimpleCurly,phpInterpDollarCurly1,phpInterpDollarCurly2,phpInterpBogusDollarCurley,phpInterpComplex
" Methoden " Methoden
syn match phpMethodsVar "->\h\w*" contained contains=phpMethods,phpMemberSelector display syn match phpMethodsVar "->\h\w*" contained contains=phpMethods,phpMemberSelector display
" Include " Include
syn keyword phpInclude include require include_once require_once contained syn keyword phpInclude include require include_once require_once use contained
" Peter Hodge - added 'clone' keyword " Peter Hodge - added 'clone' keyword
" Define " Define
@ -323,10 +344,18 @@ syn match phpNumber "\<0x\x\{1,8}\>" contained display
" Float " Float
syn match phpFloat "\(-\=\<\d+\|-\=\)\.\d\+\>" contained display syn match phpFloat "\(-\=\<\d+\|-\=\)\.\d\+\>" contained display
" SpecialChar " Backslash escapes
syn match phpSpecialChar "\\[abcfnrtyv\\]" contained display syn case match
syn match phpSpecialChar "\\\d\{3}" contained contains=phpOctalError display " for double quotes and heredoc
syn match phpSpecialChar "\\x\x\{2}" contained display syn match phpBackslashSequences "\\[fnrtv\\\"$]" contained display
syn match phpBackslashSequences "\\\d\{1,3}" contained contains=phpOctalError display
syn match phpBackslashSequences "\\x\x\{1,2}" contained display
" additional sequence for double quotes only
syn match phpBackslashDoubleQuote "\\[\"]" contained display
" for single quotes only
syn match phpBackslashSingleQuote "\\[\\']" contained display
syn case ignore
" Error " Error
syn match phpOctalError "[89]" contained display syn match phpOctalError "[89]" contained display
@ -355,23 +384,32 @@ endif
" String " String
if exists("php_parent_error_open") if exists("php_parent_error_open")
syn region phpStringDouble matchgroup=None start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=@phpAddStrings,phpIdentifier,phpSpecialChar,phpIdentifierSimply,phpIdentifierComplex contained keepend syn region phpStringDouble matchgroup=None start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=@phpAddStrings,phpBackslashSequences,phpBackslashDoubleQuote,@phpInterpDouble contained keepend
syn region phpBacktick matchgroup=None start=+`+ skip=+\\\\\|\\"+ end=+`+ contains=@phpAddStrings,phpIdentifier,phpSpecialChar,phpIdentifierSimply,phpIdentifierComplex contained keepend syn region phpBacktick matchgroup=None start=+`+ skip=+\\\\\|\\"+ end=+`+ contains=@phpAddStrings,phpIdentifier,phpBackslashSequences,phpIdentifierSimply,phpIdentifierComplex contained keepend
syn region phpStringSingle matchgroup=None start=+'+ skip=+\\\\\|\\'+ end=+'+ contains=@phpAddStrings contained keepend syn region phpStringSingle matchgroup=None start=+'+ skip=+\\\\\|\\'+ end=+'+ contains=@phpAddStrings,phpBackslashSingleQuote contained keepend
else else
syn region phpStringDouble matchgroup=None start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=@phpAddStrings,phpIdentifier,phpSpecialChar,phpIdentifierSimply,phpIdentifierComplex contained extend keepend syn region phpStringDouble matchgroup=None start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=@phpAddStrings,phpBackslashSequences,phpBackslashDoubleQuote,@phpInterpDouble contained extend keepend
syn region phpBacktick matchgroup=None start=+`+ skip=+\\\\\|\\"+ end=+`+ contains=@phpAddStrings,phpIdentifier,phpSpecialChar,phpIdentifierSimply,phpIdentifierComplex contained extend keepend syn region phpBacktick matchgroup=None start=+`+ skip=+\\\\\|\\"+ end=+`+ contains=@phpAddStrings,phpIdentifier,phpBackslashSequences,phpIdentifierSimply,phpIdentifierComplex contained extend keepend
syn region phpStringSingle matchgroup=None start=+'+ skip=+\\\\\|\\'+ end=+'+ contains=@phpAddStrings contained keepend extend syn region phpStringSingle matchgroup=None start=+'+ skip=+\\\\\|\\'+ end=+'+ contains=@phpAddStrings,phpBackslashSingleQuote contained keepend extend
endif endif
" HereDoc " HereDoc and NowDoc
if version >= 600 if version >= 600
syn case match syn case match
syn region phpHereDoc matchgroup=Delimiter start="\(<<<\)\@<=\z(\I\i*\)$" end="^\z1\(;\=$\)\@=" contained contains=phpIdentifier,phpIdentifierSimply,phpIdentifierComplex,phpSpecialChar,phpMethodsVar keepend extend
" HereDoc
syn region phpHereDoc matchgroup=Delimiter start="\(<<<\)\@<=\(\"\=\)\z(\I\i*\)\2$" end="^\z1\(;\=$\)\@=" contained contains=phpIdentifier,phpIdentifierSimply,phpIdentifierComplex,phpBackslashSequences,phpMethodsVar keepend extend
" including HTML,JavaScript,SQL even if not enabled via options " including HTML,JavaScript,SQL even if not enabled via options
syn region phpHereDoc matchgroup=Delimiter start="\(<<<\)\@<=\z(\(\I\i*\)\=\(html\)\c\(\i*\)\)$" end="^\z1\(;\=$\)\@=" contained contains=@htmlTop,phpIdentifier,phpIdentifierSimply,phpIdentifierComplex,phpSpecialChar,phpMethodsVar keepend extend syn region phpHereDoc matchgroup=Delimiter start="\(<<<\)\@<=\(\"\=\)\z(\(\I\i*\)\=\(html\)\c\(\i*\)\)\2$" end="^\z1\(;\=$\)\@=" contained contains=@htmlTop,phpIdentifier,phpIdentifierSimply,phpIdentifierComplex,phpBackslashSequences,phpMethodsVar keepend extend
syn region phpHereDoc matchgroup=Delimiter start="\(<<<\)\@<=\z(\(\I\i*\)\=\(sql\)\c\(\i*\)\)$" end="^\z1\(;\=$\)\@=" contained contains=@sqlTop,phpIdentifier,phpIdentifierSimply,phpIdentifierComplex,phpSpecialChar,phpMethodsVar keepend extend syn region phpHereDoc matchgroup=Delimiter start="\(<<<\)\@<=\(\"\=\)\z(\(\I\i*\)\=\(sql\)\c\(\i*\)\)\2$" end="^\z1\(;\=$\)\@=" contained contains=@sqlTop,phpIdentifier,phpIdentifierSimply,phpIdentifierComplex,phpBackslashSequences,phpMethodsVar keepend extend
syn region phpHereDoc matchgroup=Delimiter start="\(<<<\)\@<=\z(\(\I\i*\)\=\(javascript\)\c\(\i*\)\)$" end="^\z1\(;\=$\)\@=" contained contains=@htmlJavascript,phpIdentifierSimply,phpIdentifier,phpIdentifierComplex,phpSpecialChar,phpMethodsVar keepend extend syn region phpHereDoc matchgroup=Delimiter start="\(<<<\)\@<=\(\"\=\)\z(\(\I\i*\)\=\(javascript\)\c\(\i*\)\)\2$" end="^\z1\(;\=$\)\@=" contained contains=@htmlJavascript,phpIdentifierSimply,phpIdentifier,phpIdentifierComplex,phpBackslashSequences,phpMethodsVar keepend extend
" NowDoc
syn region phpNowDoc matchgroup=Delimiter start="\(<<<\)\@<='\z(\I\i*\)'$" end="^\z1\(;\=$\)\@=" contained keepend extend
" including HTML,JavaScript,SQL even if not enabled via options
syn region phpNowDoc matchgroup=Delimiter start="\(<<<\)\@<='\z(\(\I\i*\)\=\(html\)\c\(\i*\)\)'$" end="^\z1\(;\=$\)\@=" contained contains=@htmlTop keepend extend
syn region phpNowDoc matchgroup=Delimiter start="\(<<<\)\@<='\z(\(\I\i*\)\=\(sql\)\c\(\i*\)\)'$" end="^\z1\(;\=$\)\@=" contained contains=@sqlTop keepend extend
syn region phpNowDoc matchgroup=Delimiter start="\(<<<\)\@<='\z(\(\I\i*\)\=\(javascript\)\c\(\i*\)\)'$" end="^\z1\(;\=$\)\@=" contained contains=@htmlJavascript keepend extend
syn case ignore syn case ignore
endif endif
@ -388,7 +426,7 @@ else
endif endif
syn cluster phpClConst contains=phpFunctions,phpIdentifier,phpConditional,phpRepeat,phpStatement,phpOperator,phpRelation,phpStringSingle,phpStringDouble,phpBacktick,phpNumber,phpFloat,phpKeyword,phpType,phpBoolean,phpStructure,phpMethodsVar,phpConstant,phpCoreConstant,phpException syn cluster phpClConst contains=phpFunctions,phpIdentifier,phpConditional,phpRepeat,phpStatement,phpOperator,phpRelation,phpStringSingle,phpStringDouble,phpBacktick,phpNumber,phpFloat,phpKeyword,phpType,phpBoolean,phpStructure,phpMethodsVar,phpConstant,phpCoreConstant,phpException
syn cluster phpClInside contains=@phpClConst,phpComment,phpLabel,phpParent,phpParentError,phpInclude,phpHereDoc syn cluster phpClInside contains=@phpClConst,phpComment,phpLabel,phpParent,phpParentError,phpInclude,phpHereDoc,phpNowDoc
syn cluster phpClFunction contains=@phpClInside,phpDefine,phpParentError,phpStorageClass syn cluster phpClFunction contains=@phpClInside,phpDefine,phpParentError,phpStorageClass
syn cluster phpClTop contains=@phpClFunction,phpFoldFunction,phpFoldClass,phpFoldInterface,phpFoldTry,phpFoldCatch syn cluster phpClTop contains=@phpClFunction,phpFoldFunction,phpFoldClass,phpFoldInterface,phpFoldTry,phpFoldCatch
@ -451,17 +489,14 @@ else
syn keyword phpStorageClass final global private protected public static contained syn keyword phpStorageClass final global private protected public static contained
endif endif
" TODO: fold on "trait". For now just make sure it gets colored:
syn keyword phpStructure trait
" ================================================================ " ================================================================
" Peter Hodge - June 9, 2006 " Peter Hodge - June 9, 2006
" Some of these changes (highlighting isset/unset/echo etc) are not so " Some of these changes (highlighting isset/unset/echo etc) are not so
" critical, but they make things more colourful. :-) " critical, but they make things more colourful. :-)
" corrected highlighting for an escaped '\$' inside a double-quoted string
syn match phpSpecialChar "\\\$" contained display
" highlight object variables inside strings
syn match phpMethodsVar "->\h\w*" contained contains=phpMethods,phpMemberSelector display containedin=phpStringDouble
" highlight constant E_STRICT " highlight constant E_STRICT
syntax case match syntax case match
syntax keyword phpCoreConstant E_STRICT contained syntax keyword phpCoreConstant E_STRICT contained
@ -612,11 +647,21 @@ if version >= 508 || !exists("did_php_syn_inits")
HiLink phpType Type HiLink phpType Type
HiLink phpInclude Include HiLink phpInclude Include
HiLink phpDefine Define HiLink phpDefine Define
HiLink phpSpecialChar SpecialChar HiLink phpBackslashSequences SpecialChar
HiLink phpBackslashDoubleQuote SpecialChar
HiLink phpBackslashSingleQuote SpecialChar
HiLink phpParent Delimiter HiLink phpParent Delimiter
HiLink phpBrackets Delimiter
HiLink phpIdentifierConst Delimiter HiLink phpIdentifierConst Delimiter
HiLink phpParentError Error HiLink phpParentError Error
HiLink phpOctalError Error HiLink phpOctalError Error
HiLink phpInterpSimpleError Error
HiLink phpInterpBogusDollarCurley Error
HiLink phpInterpDollarCurly1 Error
HiLink phpInterpDollarCurly2 Error
HiLink phpInterpSimpleBracketsInner String
HiLink phpInterpSimpleCurly Delimiter
HiLink phpInterpVarname Identifier
HiLink phpTodo Todo HiLink phpTodo Todo
HiLink phpMemberSelector Structure HiLink phpMemberSelector Structure
if exists("php_oldStyle") if exists("php_oldStyle")
@ -628,13 +673,13 @@ if version >= 508 || !exists("did_php_syn_inits")
hi phpIdentifier guifg=DarkGray ctermfg=Brown hi phpIdentifier guifg=DarkGray ctermfg=Brown
hi phpIdentifierSimply guifg=DarkGray ctermfg=Brown hi phpIdentifierSimply guifg=DarkGray ctermfg=Brown
else else
HiLink phpIntVar Identifier HiLink phpIntVar Identifier
HiLink phpEnvVar Identifier HiLink phpEnvVar Identifier
HiLink phpOperator Operator HiLink phpOperator Operator
HiLink phpVarSelector Operator HiLink phpVarSelector Operator
HiLink phpRelation Operator HiLink phpRelation Operator
HiLink phpIdentifier Identifier HiLink phpIdentifier Identifier
HiLink phpIdentifierSimply Identifier HiLink phpIdentifierSimply Identifier
endif endif
delcommand HiLink delcommand HiLink

View File

@ -1,9 +1,7 @@
" Vim syntax file " Vim syntax file
" This is a GENERATED FILE. Please always refer to source file at the URI below. " Language: PoV-Ray(tm) 3.7 Scene Description Language
" Language: PoV-Ray(tm) 3.5 Scene Description Language " Maintainer: David Necas (Yeti) <yeti@physics.muni.cz>
" Maintainer: David Ne\v{c}as (Yeti) <yeti@physics.muni.cz> " Last Change: 2011-04-23
" Last Change: 2003 Apr 25
" URL: http://physics.muni.cz/~yeti/download/syntax/pov.vim
" Required Vim Version: 6.0 " Required Vim Version: 6.0
" Setup " Setup
@ -22,20 +20,21 @@ syn case match
" Top level stuff " Top level stuff
syn keyword povCommands global_settings syn keyword povCommands global_settings
syn keyword povObjects array atmosphere background bicubic_patch blob box camera component cone cubic cylinder disc fog height_field isosurface julia_fractal lathe light_group light_source mesh mesh2 object parametric pattern photons plane poly polygon prism quadric quartic rainbow sky_sphere smooth_triangle sor sphere sphere_sweep spline superellipsoid text torus triangle syn keyword povObjects array atmosphere background bicubic_patch blob box camera component cone cubic cylinder disc fog height_field isosurface julia_fractal lathe light_group light_source mesh mesh2 object ovus parametric pattern photons plane poly polygon polynomial prism quadric quartic rainbow sky_sphere smooth_triangle sor sphere sphere_sweep spline superellipsoid text torus triangle
syn keyword povCSG clipped_by composite contained_by difference intersection merge union syn keyword povCSG clipped_by composite contained_by difference intersection merge union
syn keyword povAppearance interior material media texture interior_texture texture_list syn keyword povAppearance interior material media texture interior_texture texture_list
syn keyword povGlobalSettings ambient_light assumed_gamma charset hf_gray_16 irid_wavelength max_intersections max_trace_level number_of_waves radiosity noise_generator syn keyword povGlobalSettings ambient_light assumed_gamma charset hf_gray_16 irid_wavelength max_intersections max_trace_level number_of_waves radiosity noise_generator
syn keyword povTransform inverse matrix rotate scale translate transform syn keyword povTransform inverse matrix rotate scale translate transform
" Descriptors " Descriptors
syn keyword povDescriptors finish normal pigment uv_mapping uv_vectors vertex_vectors syn keyword povDescriptors finish inside_vector normal pigment uv_mapping uv_vectors vertex_vectors
syn keyword povDescriptors adc_bailout always_sample brightness count error_bound distance_maximum gray_threshold load_file low_error_factor max_sample media minimum_reuse nearest_count normal pretrace_end pretrace_start recursion_limit save_file syn keyword povDescriptors adc_bailout always_sample brightness count error_bound distance_maximum gray_threshold load_file low_error_factor maximum_reuse max_sample media minimum_reuse mm_per_unit nearest_count normal pretrace_end pretrace_start recursion_limit save_file
syn keyword povDescriptors color colour gray rgb rgbt rgbf rgbft red green blue syn keyword povDescriptors color colour rgb rgbt rgbf rgbft srgb srgbf srgbt srgbft
syn match povDescriptors "\<\(red\|green\|blue\|gray\)\>"
syn keyword povDescriptors bump_map color_map colour_map image_map material_map pigment_map quick_color quick_colour normal_map texture_map image_pattern pigment_pattern syn keyword povDescriptors bump_map color_map colour_map image_map material_map pigment_map quick_color quick_colour normal_map texture_map image_pattern pigment_pattern
syn keyword povDescriptors ambient brilliance conserve_energy crand diffuse fresnel irid metallic phong phong_size refraction reflection reflection_exponent roughness specular syn keyword povDescriptors ambient brilliance conserve_energy crand diffuse fresnel irid metallic phong phong_size refraction reflection reflection_exponent roughness specular subsurface
syn keyword povDescriptors cylinder fisheye omnimax orthographic panoramic perspective spherical ultra_wide_angle syn keyword povDescriptors cylinder fisheye mesh_camera omnimax orthographic panoramic perspective spherical ultra_wide_angle
syn keyword povDescriptors agate average brick boxed bozo bumps cells checker crackle cylindrical dents facets function gradient granite hexagon julia leopard magnet mandel marble onion planar quilted radial ripples slope spherical spiral1 spiral2 spotted tiles tiles2 toroidal waves wood wrinkles syn keyword povDescriptors agate aoi average brick boxed bozo bumps cells checker crackle cylindrical dents facets function gradient granite hexagon julia leopard magnet mandel marble onion pavement planar quilted radial ripples slope spherical spiral1 spiral2 spotted square tiles tile2 tiling toroidal triangular waves wood wrinkles
syn keyword povDescriptors density_file syn keyword povDescriptors density_file
syn keyword povDescriptors area_light shadowless spotlight parallel syn keyword povDescriptors area_light shadowless spotlight parallel
syn keyword povDescriptors absorption confidence density emission intervals ratio samples scattering variance syn keyword povDescriptors absorption confidence density emission intervals ratio samples scattering variance
@ -46,32 +45,35 @@ syn keyword povDescriptors target
" Modifiers " Modifiers
syn keyword povModifiers caustics dispersion dispersion_samples fade_color fade_colour fade_distance fade_power ior syn keyword povModifiers caustics dispersion dispersion_samples fade_color fade_colour fade_distance fade_power ior
syn keyword povModifiers bounded_by double_illuminate hierarchy hollow no_shadow open smooth sturm threshold water_level syn keyword povModifiers bounded_by double_illuminate hierarchy hollow no_shadow open smooth sturm threshold water_level
syn keyword povModifiers importance no_radiosity
syn keyword povModifiers hypercomplex max_iteration precision quaternion slice syn keyword povModifiers hypercomplex max_iteration precision quaternion slice
syn keyword povModifiers conic_sweep linear_sweep syn keyword povModifiers conic_sweep linear_sweep
syn keyword povModifiers flatness type u_steps v_steps syn keyword povModifiers flatness type u_steps v_steps
syn keyword povModifiers aa_level aa_threshold adaptive falloff jitter looks_like media_attenuation media_interaction method point_at radius tightness syn keyword povModifiers aa_level aa_threshold adaptive area_illumination falloff jitter looks_like media_attenuation media_interaction method point_at radius tightness
syn keyword povModifiers angle aperture blur_samples confidence direction focal_point h_angle location look_at right sky up v_angle variance syn keyword povModifiers angle aperture bokeh blur_samples confidence direction focal_point h_angle location look_at right sky up v_angle variance
syn keyword povModifiers all bump_size filter interpolate map_type once slope_map transmit use_alpha use_color use_colour use_index syn keyword povModifiers all bump_size gamma interpolate map_type once premultiplied slope_map use_alpha use_color use_colour use_index
syn match povModifiers "\<\(filter\|transmit\)\>"
syn keyword povModifiers black_hole agate_turb brick_size control0 control1 cubic_wave density_map flip frequency interpolate inverse lambda metric mortar octaves offset omega phase poly_wave ramp_wave repeat scallop_wave sine_wave size strength triangle_wave thickness turbulence turb_depth type warp syn keyword povModifiers black_hole agate_turb brick_size control0 control1 cubic_wave density_map flip frequency interpolate inverse lambda metric mortar octaves offset omega phase poly_wave ramp_wave repeat scallop_wave sine_wave size strength triangle_wave thickness turbulence turb_depth type warp
syn keyword povModifiers eccentricity extinction syn keyword povModifiers eccentricity extinction
syn keyword povModifiers arc_angle falloff_angle width syn keyword povModifiers arc_angle falloff_angle width
syn keyword povModifiers accuracy all_intersections altitude autostop circular collect coords cutaway_textures dist_exp expand_thresholds exponent exterior gather global_lights major_radius max_trace no_bump_scale no_image no_reflection orient orientation pass_through precompute projected_through range_divider solid spacing split_union tolerance syn keyword povModifiers accuracy all_intersections altitude autostop circular collect coords cutaway_textures dist_exp expand_thresholds exponent exterior gather global_lights major_radius max_trace no_bump_scale no_image no_reflection orient orientation pass_through precompute projected_through range_divider solid spacing split_union tolerance
" Words not marked `reserved' in documentation, but... " Words not marked `reserved' in documentation, but...
syn keyword povBMPType alpha gif iff jpeg pgm png pot ppm sys tga tiff contained syn keyword povBMPType alpha exr gif hdr iff jpeg pgm png pot ppm sys tga tiff
syn keyword povFontType ttf contained syn keyword povFontType ttf contained
syn keyword povDensityType df3 contained syn keyword povDensityType df3 contained
syn keyword povCharset ascii utf8 contained syn keyword povCharset ascii utf8 contained
" Math functions on floats, vectors and strings " Math functions on floats, vectors and strings
syn keyword povFunctions abs acos acosh asc asin asinh atan atan2 atanh ceil cos cosh defined degrees dimensions dimension_size div exp file_exists floor int internal ln log max min mod pow radians rand seed select sin sinh sqrt strcmp strlen tan tanh val vdot vlength vstr vturbulence syn keyword povFunctions abs acos acosh asc asin asinh atan atan2 atanh bitwise_and bitwise_or bitwise_xor ceil cos cosh defined degrees dimensions dimension_size div exp file_exists floor inside int internal ln log max min mod pow prod radians rand seed select sin sinh sqrt strcmp strlen sum tan tanh val vdot vlength vstr vturbulence
syn keyword povFunctions min_extent max_extent trace vcross vrotate vaxis_rotate vnormalize vturbulence syn keyword povFunctions min_extent max_extent trace vcross vrotate vaxis_rotate vnormalize vturbulence
syn keyword povFunctions chr concat substr str strupr strlwr syn keyword povFunctions chr concat datetime now substr str strupr strlwr
syn keyword povJuliaFunctions acosh asinh atan cosh cube pwr reciprocal sinh sqr tanh syn keyword povJuliaFunctions acosh asinh atan cosh cube pwr reciprocal sinh sqr tanh
" Specialities " Specialities
syn keyword povConsts clock clock_delta clock_on final_clock final_frame frame_number initial_clock initial_frame image_width image_height false no off on pi t true u v version x y yes z syn keyword povConsts clock clock_delta clock_on final_clock final_frame frame_number initial_clock initial_frame input_file_name image_width image_height false no off on pi true version yes
syn match povDotItem "\.\@<=\(blue\|green\|filter\|red\|transmit\|t\|u\|v\|x\|y\|z\)\>" display syn match povConsts "\<[tuvxyz]\>"
syn match povDotItem "\.\@<=\(blue\|green\|gray\|filter\|red\|transmit\|hf\|t\|u\|v\|x\|y\|z\)\>" display
" Comments " Comments
syn region povComment start="/\*" end="\*/" contains=povTodo,povComment syn region povComment start="/\*" end="\*/" contains=povTodo,povComment
@ -83,16 +85,18 @@ syn keyword povTodo TODO FIXME XXX NOT contained
syn cluster povPRIVATE add=povTodo syn cluster povPRIVATE add=povTodo
" Language directives " Language directives
syn match povConditionalDir "#\s*\(else\|end\|if\|ifdef\|ifndef\|switch\|while\)\>" syn match povConditionalDir "#\s*\(else\|end\|for\|if\|ifdef\|ifndef\|switch\|while\)\>"
syn match povLabelDir "#\s*\(break\|case\|default\|range\)\>" syn match povLabelDir "#\s*\(break\|case\|default\|range\)\>"
syn match povDeclareDir "#\s*\(declare\|default\|local\|macro\|undef\|version\)\>" syn match povDeclareDir "#\s*\(declare\|default\|local\|macro\|undef\|version\)\>" nextgroup=povDeclareOption skipwhite
syn keyword povDeclareOption deprecated once contained nextgroup=povDeclareOption skipwhite
syn match povIncludeDir "#\s*include\>" syn match povIncludeDir "#\s*include\>"
syn match povFileDir "#\s*\(fclose\|fopen\|read\|write\)\>" syn match povFileDir "#\s*\(fclose\|fopen\|read\|write\)\>"
syn keyword povFileDataType uint8 sint8 unit16be uint16le sint16be sint16le sint32le sint32be
syn match povMessageDir "#\s*\(debug\|error\|render\|statistics\|warning\)\>" syn match povMessageDir "#\s*\(debug\|error\|render\|statistics\|warning\)\>"
syn region povFileOpen start="#\s*fopen\>" skip=+"[^"]*"+ matchgroup=povOpenType end="\<\(read\|write\|append\)\>" contains=ALLBUT,PovParenError,PovBraceError,@PovPRIVATE transparent keepend syn region povFileOpen start="#\s*fopen\>" skip=+"[^"]*"+ matchgroup=povOpenType end="\<\(read\|write\|append\)\>" contains=ALLBUT,PovParenError,PovBraceError,@PovPRIVATE transparent keepend
" Literal strings " Literal strings
syn match povSpecialChar "\\\d\d\d\|\\." contained syn match povSpecialChar "\\u\x\{4}\|\\\d\d\d\|\\." contained
syn region povString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=povSpecialChar oneline syn region povString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=povSpecialChar oneline
syn cluster povPRIVATE add=povSpecialChar syn cluster povPRIVATE add=povSpecialChar
@ -112,7 +116,7 @@ hi def link povNumber Number
hi def link povString String hi def link povString String
hi def link povFileOpen Constant hi def link povFileOpen Constant
hi def link povConsts Constant hi def link povConsts Constant
hi def link povDotItem Constant hi def link povDotItem povSpecial
hi def link povBMPType povSpecial hi def link povBMPType povSpecial
hi def link povCharset povSpecial hi def link povCharset povSpecial
hi def link povDensityType povSpecial hi def link povDensityType povSpecial
@ -123,8 +127,10 @@ hi def link povSpecial Special
hi def link povConditionalDir PreProc hi def link povConditionalDir PreProc
hi def link povLabelDir PreProc hi def link povLabelDir PreProc
hi def link povDeclareDir Define hi def link povDeclareDir Define
hi def link povDeclareOption Define
hi def link povIncludeDir Include hi def link povIncludeDir Include
hi def link povFileDir PreProc hi def link povFileDir PreProc
hi def link povFileDataType Special
hi def link povMessageDir Debug hi def link povMessageDir Debug
hi def link povAppearance povDescriptors hi def link povAppearance povDescriptors
hi def link povObjects povDescriptors hi def link povObjects povDescriptors

View File

@ -1,9 +1,7 @@
" Vim syntax file " Vim syntax file
" This is a GENERATED FILE. Please always refer to source file at the URI below. " Language: PoV-Ray(tm) 3.7 configuration/initialization files
" Language: PoV-Ray(tm) 3.5 configuration/initialization files " Maintainer: David Necas (Yeti) <yeti@physics.muni.cz>
" Maintainer: David Ne\v{c}as (Yeti) <yeti@physics.muni.cz> " Last Change: 2011-04-24
" Last Change: 2002-06-01
" URL: http://physics.muni.cz/~yeti/download/syntax/povini.vim
" Required Vim Version: 6.0 " Required Vim Version: 6.0
" Setup " Setup
@ -25,15 +23,17 @@ syn match poviniInclude "^\s*[^[+-;]\S*\s*$" contains=poviniSection
syn match poviniLabel "^.\{-1,}\ze=" transparent contains=poviniKeyword nextgroup=poviniBool,poviniNumber syn match poviniLabel "^.\{-1,}\ze=" transparent contains=poviniKeyword nextgroup=poviniBool,poviniNumber
syn keyword poviniBool On Off True False Yes No syn keyword poviniBool On Off True False Yes No
syn match poviniNumber "\<\d*\.\=\d\+\>" syn match poviniNumber "\<\d*\.\=\d\+\>"
syn keyword poviniKeyword Clock Initial_Frame Final_Frame Initial_Clock Final_Clock Subset_Start_Frame Subset_End_Frame Cyclic_Animation Field_Render Odd_Field syn keyword poviniKeyword Clock Initial_Frame Final_Frame Frame_Final Frame_Step Initial_Clock Final_Clock Subset_Start_Frame Subset_End_Frame Cyclic_Animation Clockless_Animation Real_Time_Raytracing Field_Render Odd_Field Work_Threads
syn keyword poviniKeyword Width Height Start_Column Start_Row End_Column End_Row Test_Abort Test_Abort_Count Continue_Trace Create_Ini syn keyword poviniKeyword Width Height Start_Column Start_Row End_Column End_Row Test_Abort Test_Abort_Count Continue_Trace Create_Ini
syn keyword poviniKeyword Display Video_Mode Palette Display_Gamma Pause_When_Done Verbose Draw_Vistas Preview_Start_Size Preview_End_Size syn keyword poviniKeyword Display Video_Mode Palette Display_Gamma Pause_When_Done Verbose Draw_Vistas Preview_Start_Size Preview_End_Size Render_Block_Size Render_Block_Step Render_Pattern Max_Image_Buffer_Memory
syn keyword poviniKeyword Output_to_File Output_File_Type Output_Alpha Bits_Per_Color Output_File_Name Buffer_Output Buffer_Size syn keyword poviniKeyword Output_to_File Output_File_Type Output_Alpha Bits_Per_Color Output_File_Name Buffer_Output Buffer_Size Dither Dither_Method File_Gamma
syn keyword poviniKeyword BSP_Base BSP_Child BSP_Isect BSP_Max BSP_Miss
syn keyword poviniKeyword Histogram_Type Histogram_Grid_Size Histogram_Name syn keyword poviniKeyword Histogram_Type Histogram_Grid_Size Histogram_Name
syn keyword poviniKeyword Input_File_Name Include_Header Library_Path Version syn keyword poviniKeyword Input_File_Name Include_Header Library_Path Version
syn keyword poviniKeyword Debug_Console Fatal_Console Render_Console Statistic_Console Warning_Console All_Console Debug_File Fatal_File Render_File Statistic_File Warning_File All_File Warning_Level syn keyword poviniKeyword Debug_Console Fatal_Console Render_Console Statistic_Console Warning_Console All_Console Debug_File Fatal_File Render_File Statistic_File Warning_File All_File Warning_Level
syn keyword poviniKeyword Quality Radiosity Bounding Bounding_Threshold Light_Buffer Vista_Buffer Remove_Bounds Split_Unions Antialias Sampling_Method Antialias_Threshold Jitter Jitter_Amount Antialias_Depth syn keyword poviniKeyword Quality Bounding Bounding_Method Bounding_Threshold Light_Buffer Vista_Buffer Remove_Bounds Split_Unions Antialias Sampling_Method Antialias_Threshold Jitter Jitter_Amount Antialias_Depth Antialias_Gamma
syn keyword poviniKeyword Pre_Scene_Return Pre_Frame_Return Post_Scene_Return Post_Frame_Return User_Abort_Return Fatal_Error_Return syn keyword poviniKeyword Pre_Scene_Return Pre_Frame_Return Post_Scene_Return Post_Frame_Return User_Abort_Return Fatal_Error_Return
syn keyword poviniKeyword Radiosity Radiosity_File_Name Radiosity_From_File Radiosity_To_File Radiosity_Vain_Pretrace High_Reproducibility
syn match poviniShellOut "^\s*\(Pre_Scene_Command\|Pre_Frame_Command\|Post_Scene_Command\|Post_Frame_Command\|User_Abort_Command\|Fatal_Error_Command\)\>" nextgroup=poviniShellOutEq skipwhite syn match poviniShellOut "^\s*\(Pre_Scene_Command\|Pre_Frame_Command\|Post_Scene_Command\|Post_Frame_Command\|User_Abort_Command\|Fatal_Error_Command\)\>" nextgroup=poviniShellOutEq skipwhite
syn match poviniShellOutEq "=" nextgroup=poviniShellOutRHS skipwhite contained syn match poviniShellOutEq "=" nextgroup=poviniShellOutRHS skipwhite contained
syn match poviniShellOutRHS "[^;]\+" skipwhite contained contains=poviniShellOutSpecial syn match poviniShellOutRHS "[^;]\+" skipwhite contained contains=poviniShellOutSpecial

View File

@ -1,8 +1,9 @@
" Vim syntax file " Vim syntax file
" Language: Ratpoison configuration/commands file ( /etc/ratpoisonrc ~/.ratpoisonrc ) " Language: Ratpoison configuration/commands file ( /etc/ratpoisonrc ~/.ratpoisonrc )
" Maintainer: Doug Kearns <djkea2@gus.gscit.monash.edu.au> " Maintainer: Magnus Woldrich <m@japh.se>
" URL: http://gus.gscit.monash.edu.au/~djkea2/vim/syntax/ratpoison.vim " URL: http://github.com/trapd00r/vim-syntax-ratpoison
" Last Change: 2005 Oct 06 " Last Change: 2011 Apr 11
" Previous Maintainer: Doug Kearns <djkea2@gus.gscit.monash.edu.au>
" For version 5.x: Clear all syntax items " For version 5.x: Clear all syntax items
" For version 6.x: Quit when a syntax file was already loaded " For version 6.x: Quit when a syntax file was already loaded
@ -94,6 +95,13 @@ syn keyword ratpoisonSetArg barpadding contained nextgroup=ratpoisonNumberArg
syn keyword ratpoisonSetArg bgcolor syn keyword ratpoisonSetArg bgcolor
syn keyword ratpoisonSetArg border contained nextgroup=ratpoisonNumberArg syn keyword ratpoisonSetArg border contained nextgroup=ratpoisonNumberArg
syn keyword ratpoisonSetArg fgcolor syn keyword ratpoisonSetArg fgcolor
syn keyword ratpoisonSetArg fwcolor
syn keyword ratpoisonSetArg bwcolor
syn keyword ratpoisonSetArg historysize
syn keyword ratpoisonSetArg historycompaction
syn keyword ratpoisonSetArg historyexpansion
syn keyword ratpoisonSetArg topkmap
syn keyword ratpoisonSetArg barinpadding
syn keyword ratpoisonSetArg font syn keyword ratpoisonSetArg font
syn keyword ratpoisonSetArg framesels syn keyword ratpoisonSetArg framesels
syn keyword ratpoisonSetArg inputwidth contained nextgroup=ratpoisonNumberArg syn keyword ratpoisonSetArg inputwidth contained nextgroup=ratpoisonNumberArg

View File

@ -1,11 +1,11 @@
" Vim syntax file " Vim syntax file
" Language: readline(3) configuration file " Language: readline(3) configuration file
" Maintainer: Nikolai Weibull <now@bitwi.se> " Maintainer: Nikolai Weibull <now@bitwi.se>
" Latest Revision: 2009-05-25 " Latest Revision: 2011-05-02
" readline_has_bash - if defined add support for bash specific " readline_has_bash - if defined add support for bash specific
" settings/functions " settings/functions
if exists("b:current_syntax") if exists('b:current_syntax')
finish finish
endif endif
@ -14,163 +14,382 @@ set cpo&vim
setlocal iskeyword+=- setlocal iskeyword+=-
syn keyword readlineTodo contained TODO FIXME XXX NOTE syn match readlineKey contained
\ '\S'
\ nextgroup=readlineKeyTerminator
syn region readlineComment display oneline start='^\s*#' end='$' syn match readlineBegin display '^'
\ contains=readlineTodo,@Spell \ nextgroup=readlineComment,
\ readlineConditional,
\ readlineInclude,
\ readlineKeyName,
\ readlineKey,
\ readlineKeySeq,
\ readlineKeyword
\ skipwhite
syn match readlineString '^\s*[A-Za-z-]\+:'me=e-1 contains=readlineKeys syn region readlineComment contained display oneline
syn region readlineString display oneline start=+"+ skip=+\\\\\|\\"+ \ start='#'
\ end=+"+ contains=readlineKeysTwo \ end='$'
\ contains=readlineTodo,
\ @Spell
syn keyword readlineTodo contained
\ TODO
\ FIXME
\ XXX
\ NOTE
syn match readlineConditional contained
\ '$if\>'
\ nextgroup=readlineTest,
\ readlineTestApp
\ skipwhite
syn keyword readlineTest contained
\ mode
\ nextgroup=readlineTestModeEq
syn match readlineTestModeEq contained
\ '='
\ nextgroup=readlineEditingMode
syn keyword readlineTest contained
\ term
\ nextgroup=readlineTestTermEq
syn match readlineTestTermEq contained
\ '='
\ nextgroup=readlineTestTerm
syn match readlineTestTerm contained
\ '\S\+'
syn match readlineTestApp contained
\ '\S\+'
syn match readlineConditional contained display
\ '$\%(else\|endif\)\>'
syn match readlineInclude contained display
\ '$include\>'
\ nextgroup=readlinePath
syn match readlinePath contained display
\ '.\+'
syn case ignore syn case ignore
syn keyword readlineKeys contained Control Meta Del Esc Escape LFD syn match readlineKeyName contained display
\ Newline Ret Return Rubout Space Spc Tab \ nextgroup=readlineKeySeparator,
\ readlineKeyTerminator
\ '\%(Control\|Del\|Esc\|Escape\|LFD\|Meta\|Newline\|Ret\|Return\|Rubout\|Space\|Spc\|Tab\)'
syn case match syn case match
syn match readlineKeysTwo contained display syn match readlineKeySeparator contained
\ +\\\([CM]-\|[e\\"'abdfnrtv]\|\o\{3}\|x\x\{3}\)+ \ '-'
\ nextgroup=readlineKeyName,
\ readlineKey
syn match readlineKeymaps contained display syn match readlineKeyTerminator contained
\ 'emacs\(-standard\|-meta\|-ctlx\)\=' \ ':'
syn match readlineKeymaps contained display \ nextgroup=readlineFunction
\ 'vi\(-move\|-command\|-insert\)\=' \ skipwhite
syn keyword readlineBellStyles contained audible visible none syn region readlineKeySeq contained display oneline
\ start=+"+
\ skip=+\\\\\|\\"+
\ end=+"+
\ contains=readlineKeyEscape
\ nextgroup=readlineKeyTerminator
syn match readlineNumber contained display '\<\d\+\>' syn match readlineKeyEscape contained display
\ +\\\([CM]-\|[e\\"'abdfnrtv]\|\o\{3}\|x\x\{2}\)+
syn keyword readlineKeyword contained
\ set
\ nextgroup=readlineVariable
\ skipwhite
syn keyword readlineVariable contained
\ nextgroup=readlineBellStyle
\ skipwhite
\ bell-style
syn keyword readlineVariable contained
\ nextgroup=readlineBoolean
\ skipwhite
\ bind-tty-special-chars
\ completion-ignore-case
\ completion-map-case
\ convert-meta
\ disable-completion
\ echo-control-characters
\ enable-keypad
\ enable-meta-key
\ expand-tilde
\ history-preserve-point
\ horizontal-scroll-mode
\ input-meta
\ meta-flag
\ mark-directories
\ mark-modified-lines
\ mark-symlinked-directories
\ match-hidden-files
\ menu-complete-display-prefix
\ output-meta
\ page-completions
\ print-completions-horizontally
\ revert-all-at-newline
\ show-all-if-ambiguous
\ show-all-if-unmodified
\ skip-completed-text
\ visible-stats
syn keyword readlineVariable contained
\ nextgroup=readlineString
\ skipwhite
\ comment-begin
\ isearch-terminators
syn keyword readlineVariable contained
\ nextgroup=readlineNumber
\ skipwhite
\ completion-display-width
\ completion-prefix-display-length
\ completion-query-items
\ history-size
syn keyword readlineVariable contained
\ nextgroup=readlineEditingMode
\ skipwhite
\ editing-mode
syn keyword readlineVariable contained
\ nextgroup=readlineKeymap
\ skipwhite
\ keymap
syn keyword readlineBellStyle contained
\ audible
\ visible
\ none
syn case ignore syn case ignore
syn keyword readlineBoolean contained on off syn keyword readlineBoolean contained
\ on
\ off
syn case match syn case match
syn keyword readlineIfOps contained mode term syn region readlineString contained display oneline
\ matchgroup=readlineStringDelimiter
\ start=+"+
\ skip=+\\\\\|\\"+
\ end=+"+
syn region readlineConditional display oneline transparent syn match readlineNumber contained display
\ matchgroup=readlineConditional \ '[+-]\d\+\>'
\ start='^\s*$if' end="$"
\ contains=readlineIfOps,readlineKeymaps
syn match readlineConditional display '^\s*$\(else\|endif\)\>'
syn match readlineInclude display '^\s*$include\>' syn keyword readlineEditingMode contained
\ emacs
\ vi
syn region readlineSet display oneline transparent syn match readlineKeymap contained display
\ matchgroup=readlineKeyword start='^\s*set\>' \ 'emacs\%(-\%(standard\|meta\|ctlx\)\)\=\|vi\%(-\%(move\|command\|insert\)\)\='
\ end="$"me=e-1 contains=readlineNumber,
\ readlineBoolean,readlineKeymaps,
\ readlineBellStyles,readlineSettings
syn keyword readlineSettings contained bell-style comment-begin syn keyword readlineFunction contained
\ completion-ignore-case completion-query-items \ beginning-of-line
\ convert-meta disable-completion editing-mode \ end-of-line
\ enable-keypad expand-tilde \ forward-char
\ horizontal-scroll-mode mark-directories \ backward-char
\ keymap mark-modified-lines meta-flag \ forward-word
\ input-meta output-meta \ backward-word
\ print-completions-horizontally \ clear-screen
\ show-all-if-ambiguous visible-stats \ redraw-current-line
\ prefer-visible-bell blink-matching-paren \
\ match-hidden-files history-preserve-point \ accept-line
\ isearch-terminators \ previous-history
\ next-history
syn region readlineBinding display oneline transparent \ beginning-of-history
\ matchgroup=readlineKeyword start=':' end='$' \ end-of-history
\ contains=readlineKeys,readlineFunctions \ reverse-search-history
\ forward-search-history
syn keyword readlineFunctions contained display \ non-incremental-reverse-search-history
\ beginning-of-line end-of-line forward-char \ non-incremental-forward-search-history
\ backward-char forward-word backward-word \ history-search-forward
\ clear-screen redraw-current-line \ history-search-backward
\ accept-line previous-history \ yank-nth-arg
\ next-history beginning-of-history \ yank-last-arg
\ end-of-history reverse-search-history \
\ forward-search-history \ delete-char
\ non-incremental-reverse-search-history \ backward-delete-char
\ non-incremental-forward-search-history \ forward-backward-delete-char
\ history-search-forward \ quoted-insert
\ history-search-backward \ tab-insert
\ yank-nth-arg yank-last-arg \ self-insert
\ delete-char backward-delete-char \ transpose-chars
\ forward-backward-delete-char quoted-insert \ transpose-words
\ tab-insert self-insert transpose-chars \ upcase-word
\ transpose-words upcase-word downcase-word \ downcase-word
\ capitalize-word overwrite-mode kill-line \ capitalize-word
\ backward-kill-line unix-line-discard \ overwrite-mode
\ kill-whole-line kill-word backward-kill-word \
\ unix-word-rubout unix-filename-rubout \ kill-line
\ delete-horizontal-space kill-region \ backward-kill-line
\ copy-region-as-kill copy-backward-word \ unix-line-discard
\ copy-forward-word yank yank-pop \ kill-whole-line
\ digit-argument universal-argument complete \ kill-word
\ possible-completions insert-completions \ backward-kill-word
\ menu-complete delete-char-or-list \ unix-word-rubout
\ start-kbd-macro end-kbd-macro \ unix-filename-rubout
\ call-last-kbd-macro re-read-init-file \ delete-horizontal-space
\ abort do-uppercase-version prefix-meta \ kill-region
\ undo revert-line tilde-expand set-mark \ copy-region-as-kill
\ exchange-point-and-mark character-search \ copy-backward-word
\ character-search-backward insert-comment \ copy-forward-word
\ dump-functions dump-variables dump-macros \ yank
\ emacs-editing-mode vi-editing-mode \ yank-pop
\ vi-complete vi-char-search vi-redo \
\ vi-search vi-arg-digit vi-append-eol \ digit-argument
\ vi-prev-word vi-change-to vi-delete-to \ universal-argument
\ vi-end-word vi-fetch-history vi-insert-beg \
\ vi-search-again vi-put vi-replace \ complete
\ vi-subst vi-yank-to vi-first-print \ possible-completions
\ vi-yank-arg vi-goto-mark vi-append-mode \ insert-completions
\ vi-insertion-mode prev-history vi-set-mark \ menu-complete
\ vi-search-again vi-put vi-change-char \ menu-complete-or-backward
\ vi-subst vi-delete vi-yank-to \ delete-char-or-list
\ vi-column vi-change-case vi-overstrike \
\ vi-overstrike-delete do-lowercase-version \ start-kbd-macro
\ delete-char-or-list tty-status \ end-kbd-macro
\ arrow-key-prefix vi-back-to-indent vi-bword \ call-last-kbd-macro
\ vi-bWord vi-eword vi-eWord vi-fword vi-fWord \
\ vi-next-word \ re-read-init-file
\ vi-movement-mode \ abort
\ do-uppercase-version
\ prefix-meta
\ undo
\ revert-line
\ tilde-expand
\ set-mark
\ exchange-point-and-mark
\ character-search
\ character-search-backward
\ skip-csi-sequence
\ insert-comment
\ dump-functions
\ dump-variables
\ dump-macros
\ emacs-editing-mode
\ vi-editing-mode
\
\ vi-eof-maybe
\ vi-movement-mode
\ vi-undo
\ vi-match
\ vi-tilde-expand
\ vi-complete
\ vi-char-search
\ vi-redo
\ vi-search
\ vi-arg-digit
\ vi-append-eol
\ vi-prev-word
\ vi-change-to
\ vi-delete-to
\ vi-end-word
\ vi-char-search
\ vi-fetch-history
\ vi-insert-beg
\ vi-search-again
\ vi-put
\ vi-replace
\ vi-subst
\ vi-char-search
\ vi-next-word
\ vi-yank-to
\ vi-first-print
\ vi-yank-arg
\ vi-goto-mark
\ vi-append-mode
\ vi-prev-word
\ vi-change-to
\ vi-delete-to
\ vi-end-word
\ vi-char-search
\ vi-insert-mode
\ vi-set-mark
\ vi-search-again
\ vi-put
\ vi-change-char
\ vi-subst
\ vi-char-search
\ vi-undo
\ vi-next-word
\ vi-delete
\ vi-yank-to
\ vi-column
\ vi-change-case
if exists("readline_has_bash") if exists("readline_has_bash")
syn keyword readlineFunctions contained syn keyword readlineFunction contained
\ shell-expand-line history-expand-line \ shell-expand-line
\ magic-space alias-expand-line \ history-expand-line
\ history-and-alias-expand-line \ magic-space
\ insert-last-argument operate-and-get-next \ alias-expand-line
\ forward-backward-delete-char \ history-and-alias-expand-line
\ delete-char-or-list complete-filename \ insert-last-argument
\ possible-filename-completions \ operate-and-get-next
\ complete-username \ forward-backward-delete-char
\ possible-username-completions \ delete-char-or-list
\ complete-variable \ complete-filename
\ possible-variable-completions \ possible-filename-completions
\ complete-hostname \ complete-username
\ possible-hostname-completions \ possible-username-completions
\ complete-command \ complete-variable
\ possible-command-completions \ possible-variable-completions
\ dynamic-complete-history \ complete-hostname
\ complete-into-braces \ possible-hostname-completions
\ glob-expand-word glob-list-expansions \ complete-command
\ display-shell-version glob-complete-word \ possible-command-completions
\ edit-and-execute-command \ dynamic-complete-history
\ complete-into-braces
\ glob-expand-word
\ glob-list-expansions
\ display-shell-version
\ glob-complete-word
\ edit-and-execute-command
endif endif
hi def link readlineComment Comment hi def link readlineKey readlineKeySeq
hi def link readlineTodo Todo hi def link readlineComment Comment
hi def link readlineString String hi def link readlineTodo Todo
hi def link readlineKeys SpecialChar hi def link readlineConditional Conditional
hi def link readlineKeysTwo SpecialChar hi def link readlineTest Type
hi def link readlineKeymaps Constant hi def link readlineDelimiter Delimiter
hi def link readlineBellStyles Constant hi def link readlineTestModeEq readlineEq
hi def link readlineNumber Number hi def link readlineTestTermEq readlineEq
hi def link readlineBoolean Boolean hi def link readlineTestTerm readlineString
hi def link readlineIfOps Type hi def link readlineTestAppEq readlineEq
hi def link readlineConditional Conditional hi def link readlineTestApp readlineString
hi def link readlineInclude Include hi def link readlineInclude Include
hi def link readlineKeyword Keyword hi def link readlinePath String
hi def link readlineSettings Type hi def link readlineKeyName SpecialChar
hi def link readlineFunctions Type hi def link readlineKeySeparator readlineKeySeq
hi def link readlineKeyTerminator readlineDelimiter
hi def link readlineKeySeq String
hi def link readlineKeyEscape SpecialChar
hi def link readlineKeyword Keyword
hi def link readlineVariable Identifier
hi def link readlineBellStyle Constant
hi def link readlineBoolean Boolean
hi def link readlineString String
hi def link readlineStringDelimiter readlineString
hi def link readlineNumber Number
hi def link readlineEditingMode Constant
hi def link readlineKeymap Constant
hi def link readlineFunction Function
let b:current_syntax = "readline" let b:current_syntax = 'readline'
let &cpo = s:cpo_save let &cpo = s:cpo_save
unlet s:cpo_save unlet s:cpo_save

View File

@ -1,7 +1,7 @@
" Vim syntax file " Vim syntax file
" Language: sysctl.conf(5) configuration file " Language: sysctl.conf(5) configuration file
" Maintainer: Nikolai Weibull <now@bitwi.se> " Maintainer: Nikolai Weibull <now@bitwi.se>
" Latest Revision: 2006-04-19 " Latest Revision: 2011-05-02
if exists("b:current_syntax") if exists("b:current_syntax")
finish finish
@ -13,7 +13,7 @@ set cpo&vim
syn match sysctlBegin display '^' syn match sysctlBegin display '^'
\ nextgroup=sysctlToken,sysctlComment skipwhite \ nextgroup=sysctlToken,sysctlComment skipwhite
syn match sysctlToken contained display '\S\+' syn match sysctlToken contained display '[^=]\+'
\ nextgroup=sysctlTokenEq skipwhite \ nextgroup=sysctlTokenEq skipwhite
syn match sysctlTokenEq contained display '=' nextgroup=sysctlValue skipwhite syn match sysctlTokenEq contained display '=' nextgroup=sysctlValue skipwhite

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