* Eric Leenman [2007.03.01 13:30]: > >How were you planning to use those? > > I want to use these as cut, paste and copy iso > CTRL-X, V and C.
Cutting and copying are compound operations in the sense that you need to specify /what/ they are going to act on. There are many ways to do this, depending on the mode you are in. > I now got > :vnoremap <kPlus> "+p > :vnoremap <kMinus> "+d > :vnoremap <kMultiply> "+y This looks fine. What you want to act on is implicitly the visual selection. > :noremap <kPlus> "+p This is fine. > :noremap <kMinus> "+d > :noremap <kMultiply> "+y Here you will need to specify *what* you want to "cut" or "paste" with a motion command after you have pressed <kMinus> of <kMultiply>. > :inoremap <kMinus> "+d > :inoremap <kMultiply> "+y These are "insert-mode" mappings. So of course you get "+d in your text. This is exactly what you told vim to do. What do you *mean* when you are in insert mode and want to "cut" or "copy"? "Copy" what? One possibility is to revert to normal mode and follow the command with a motion: :inoremap <kMinus> <C-O>"+d :inoremap <kPlus> <C-O>"+p > :inoremap <kPlus> "+p This is meaningful but the syntax is incorrect. Tony gave you the answer for this one. > I tried the help CTRL-R but I don't follow that. It would help if were more explicit about the parts you don't understand. In normal mode, pressing "+p means: 'put the content of register + after the cursor'. In insert mode, pressing "+p means: 'insert " then + then p'. It has nothing whatsoever to do with registers. This is where CTRL-R helps you. <CTRL-R>+ is the insert-mode equivalent of "+p in normal-mode. -- JR