Insert mode mapping is for current buffer only #2

This commit is contained in:
Dhruva Sagar
2013-03-21 12:16:27 +05:30
parent 28dc1626ab
commit 7b89b6b50d
2 changed files with 6 additions and 6 deletions

View File

@@ -4,7 +4,7 @@
" Author: Dhruva Sagar <http://dhruvasagar.com/> " Author: Dhruva Sagar <http://dhruvasagar.com/>
" License: MIT (http://www.opensource.org/licenses/MIT) " License: MIT (http://www.opensource.org/licenses/MIT)
" Website: http://github.com/dhruvasagar/vim-table-mode " Website: http://github.com/dhruvasagar/vim-table-mode
" Version: 2.1.1 " Version: 2.1.2
" Note: This plugin was heavily inspired by the 'CucumberTables.vim' " Note: This plugin was heavily inspired by the 'CucumberTables.vim'
" (https://gist.github.com/tpope/287147) plugin by Tim Pope and " (https://gist.github.com/tpope/287147) plugin by Tim Pope and
" uses a small amount of code from it. " uses a small amount of code from it.
@@ -62,9 +62,9 @@ if !g:table_mode_always_active
endif endif
command! -nargs=0 -range Tableize <line1>,<line2>call tablemode#TableizeRange() command! -nargs=0 -range Tableize <line1>,<line2>call tablemode#TableizeRange()
exec "xnoremap <silent> " . g:table_mode_tableize_map . " :Tableize<CR>" execute "xnoremap <silent> " . g:table_mode_tableize_map . " :Tableize<CR>"
exec "nnoremap <silent> " . g:table_mode_tableize_map . " :Tableize<CR>" execute "nnoremap <silent> " . g:table_mode_tableize_map . " :Tableize<CR>"
"}}}1 "}}}1
" ModeLine {{{ " ModeLine {{{
" vim:fdm=marker " vim:fdl=0 fdm=marker

View File

@@ -4,7 +4,7 @@
" Author: Dhruva Sagar <http://dhruvasagar.com/> " Author: Dhruva Sagar <http://dhruvasagar.com/>
" License: MIT (http://www.opensource.org/licenses/MIT) " License: MIT (http://www.opensource.org/licenses/MIT)
" Website: http://github.com/dhruvasagar/vim-table-mode " Website: http://github.com/dhruvasagar/vim-table-mode
" Version: 2.1.1 " Version: 2.1.2
" Note: This plugin was heavily inspired by the 'CucumberTables.vim' " Note: This plugin was heavily inspired by the 'CucumberTables.vim'
" (https://gist.github.com/tpope/287147) plugin by Tim Pope and " (https://gist.github.com/tpope/287147) plugin by Tim Pope and
" uses a small amount of code from it. " uses a small amount of code from it.
@@ -65,7 +65,7 @@ endfunction
function! s:ToggleMapping() "{{{2 function! s:ToggleMapping() "{{{2
if exists('b:table_mode_active') && b:table_mode_active if exists('b:table_mode_active') && b:table_mode_active
execute "inoremap <silent> " . s:TableModeSeparatorMap() . ' ' . execute "inoremap <silent> <buffer> " . s:TableModeSeparatorMap() . ' ' .
\ s:TableModeSeparatorMap() . "<Esc>:call <SID>Tableize()<CR>a" \ s:TableModeSeparatorMap() . "<Esc>:call <SID>Tableize()<CR>a"
else else
execute "iunmap <silent> " . s:TableModeSeparatorMap() execute "iunmap <silent> " . s:TableModeSeparatorMap()