Mercurial > vim
diff runtime/doc/usr_05.txt @ 43:f55897d6921d v7.0026
updated for version 7.0026
author | vimboss |
---|---|
date | Wed, 29 Dec 2004 21:03:02 +0000 |
parents | cc049b00ee70 |
children | 8b0ee9d57d7f |
line wrap: on
line diff
--- a/runtime/doc/usr_05.txt +++ b/runtime/doc/usr_05.txt @@ -1,4 +1,4 @@ -*usr_05.txt* For Vim version 7.0aa. Last change: 2004 Aug 27 +*usr_05.txt* For Vim version 7.0aa. Last change: 2004 Dec 29 VIM USER MANUAL - by Bram Moolenaar @@ -150,12 +150,11 @@ it worked before Vim 5.0. Otherwise the will not need it. > - vnoremap p <Esc>:let current_reg = @"<CR>gvs<C-R>=current_reg<CR><Esc> + vnoremap _g y:exe "grep /" . escape(@", '\\/') . "/ *.c *.h"<CR> -This is a complicated mapping. It will not be explained how it works here. -What it does is to make "p" in Visual mode overwrite the selected text with -the previously yanked text. You can see that mappings can be used to do quite -complicated things. Still, it is just a sequence of commands that are +This mapping yanks the visually selected text and searches for it in C files. +This is a complicated mapping. You can see that mappings can be used to do +quite complicated things. Still, it is just a sequence of commands that are executed like you typed them. >