Mercurial > vim
diff runtime/doc/autocmd.txt @ 10140:b11ceef7116e
commit https://github.com/vim/vim/commit/64d8e25bf6efe5f18b032563521c3ce278c316ab
Author: Bram Moolenaar <Bram@vim.org>
Date: Tue Sep 6 22:12:34 2016 +0200
Updated runtime files.
author | Christian Brabandt <cb@256bit.org> |
---|---|
date | Tue, 06 Sep 2016 22:15:08 +0200 |
parents | 35ce559b8553 |
children | 9f48eab77d62 |
line wrap: on
line diff
--- a/runtime/doc/autocmd.txt +++ b/runtime/doc/autocmd.txt @@ -1,4 +1,4 @@ -*autocmd.txt* For Vim version 7.4. Last change: 2016 Jul 29 +*autocmd.txt* For Vim version 7.4. Last change: 2016 Sep 03 VIM REFERENCE MANUAL by Bram Moolenaar @@ -419,8 +419,8 @@ BufUnload Before unloading a buffer. NOTE: When this autocommand is executed, the current buffer "%" may be different from the buffer being unloaded "<afile>". - Don't change to another buffer, it will cause - problems. + Don't change to another buffer or window, it + will cause problems! When exiting and v:dying is 2 or more this event is not triggered. *BufWinEnter* @@ -784,7 +784,9 @@ QuickFixCmdPre Before a quickfix comma |:vimgrepadd|, |:lvimgrepadd|, |:cscope|, |:cfile|, |:cgetfile|, |:caddfile|, |:lfile|, |:lgetfile|, |:laddfile|, |:helpgrep|, - |:lhelpgrep|). + |:lhelpgrep|, |:cexpr|, |:cgetexpr|, + |:caddexpr|, |:cbuffer|, |:cgetbuffer|, + |:caddbuffer|). The pattern is matched against the command being run. When |:grep| is used but 'grepprg' is set to "internal" it still matches "grep". @@ -1065,6 +1067,9 @@ Note that for all systems the '/' charac MS-DOS and OS/2). This was done because the backslash is difficult to use in a pattern and to make the autocommands portable across different systems. +It is possible to use |pattern| items, but they may not work as expected, +because of the translation done for the above. + *autocmd-changes* Matching with the pattern is done when an event is triggered. Changing the buffer name in one of the autocommands, or even deleting the buffer, does not @@ -1163,11 +1168,12 @@ name! different from existing {event} names, as this most likely will not do what you intended. - *:augroup-delete* *E367* *W19* + *:augroup-delete* *E367* *W19* *E936* :aug[roup]! {name} Delete the autocmd group {name}. Don't use this if there is still an autocommand using this group! You will get a warning if doing - it anyway. + it anyway. when the group is the current group + you will get error E936. To enter autocommands for a specific group, use this method: 1. Select the group with ":augroup {name}".