Hi,
I have certain scripts in my plugin directory. And for them I have
several mappings. Nothing special. But now I want to merge two mappings
into one.
In script 1 I have a mapping <leader>f
"{{{ mappings and default options
if !hasmapto("<Plug>SimpleFold_Foldsearch")
map <unique> <silent> <Leader>f <Plug>SimpleFold_Foldsearch
endif
noremap <unique> <script> <Plug>SimpleFold_Foldsearch <SID>FoldSearch
noremap <SID>FoldSearch :call <SID>Foldsearch("")<cr>
In script 2 I have a mapping <C-space>
nnoremap <C-space> :call ToggleFold()<CR>
inoremap <C-space> <C-O>:call ToggleFold()<CR>
I want to updated the <C-space> mapping that it does first the <leader>f
function and then the orignal function after.
But then I write this as the mapping
nnoremap <C-space> <Leader>f :call ToggleFold()<CR>
inoremap <C-space> <C-O> <Leader>f :call ToggleFold()<CR>
Nothing happens.
Question 1: Can a nnoremap and and inoremap be combined?
Question 2: Is the leader mapping causing the problem? If not what else
might be the problem?
Alternative I can merge the scripts, but I prefer to keep them seperated.
Rgds,
Jeri
--
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