Browse Source

adding features

master
lolson 9 years ago
parent
commit
d2e75ac1f0
1 changed files with 9 additions and 5 deletions
  1. +9
    -5
      plugin/makecols.vim

+ 9
- 5
plugin/makecols.vim View File

@ -64,10 +64,9 @@ endfunction
function! s:makecols(options) range function! s:makecols(options) range
let options = a:options let options = a:options
let orientation = options[0]
echom "Orientation: " . orientation
echom "Orientation: " . g:orientation
let cols = options[1] let cols = options[1]
echom "Number of Columns: " . cols
echom "Number of Columns: " . g:cols
let mode = visualmode() let mode = visualmode()
if (mode !=# "V") if (mode !=# "V")
echo "You must be in linewise visual mode" echo "You must be in linewise visual mode"
@ -82,9 +81,14 @@ function! s:makecols(options) range
endfunction endfunction
vnoremap <silent> mch :<C-U>call <SID>makecols(["horz", 5])<CR>
vnoremap <silent> mcv :<C-U>call <SID>makecols(["vert", 5])<CR>
vnoremap <silent> mc :<C-U>call <SID>makecols()<CR>
if exists(g:makecols_orientation) || ! g:makecols_orientation)
let g:makecols_orientation = "horz"
endif
if exists(g:makecols_cols) || ! g:makecols_cols)
let g:makecols_cols = "5"
endif

Loading…
Cancel
Save