137125Re: How to unmap all combinations that begin with ?
- Apr 8, 2013On 2013-04-08, Thiago Padilha wrote:
> I found these default mappings after typing :imapIf you didn't set those mappings in your ~/.vimrc, then they were
> i <Esc>[6~ <PageDown>
> i <Esc>[5~ <PageUp>
> i <Esc>OF <End>
> i <Esc>OH <Home>
> i <Esc>OD <Left>
> i <Esc>OC <Right>
> i <Esc>OB <Down>
> i <Esc>OA <Up>
> I want to get rid of all these mappings in my vimrc, so I can properly
> map key sequences that begin with escape without having vim wait to
> leav insert mode. I have tried to put the following in my vimrc:
> iunmap <Esc>[6~
> iunmap <Esc>[5~
> iunmap <Esc>OF
> iunmap <Esc>OH
> iunmap <Esc>OD
> iunmap <Esc>OC
> iunmap <Esc>OB
> iunmap <Esc>OA
> But it doesn't work and vim complains with messages of 'no such mappings'
probably set in a plugin. You can find out by executing
If they were set in a plugin, then they were set after your ~/.vimrc
was read. Since the mappings were not defined when your iunmap
commands were executed, there were 'no such mappings' to unmap.
Assuming that that is the problem, then one solution would be
to create a file named ~/.vim/after/plugin/<plugin> where <plugin>
is the name of the plugin file in which those mappings are defined,
and put your iunmap commands in that file.
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
For more options, visit https://groups.google.com/groups/opt_out.
- << Previous post in topic Next post in topic >>