Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

vim: arpeggio: Add :Arpeggio for readability

  • Loading branch information...
commit ea422eb75d13430a605ecf295fec7cbda85dded3 1 parent 9797452
@kana kana authored
Showing with 18 additions and 0 deletions.
  1. +9 −0 autoload/arpeggio.vim
  2. +7 −0 doc/arpeggio.txt
  3. +2 −0  plugin/arpeggio.vim
View
9 autoload/arpeggio.vim
@@ -126,6 +126,15 @@ endfunction
" Core "{{{1
+function! arpeggio#_do(script) "{{{2
+ let _ = split(substitute(a:script, '^\s\+', '', ''), '^\S\+\zs')
+ execute 'Arpeggio'._[0] join(_[1:], '')
+ return
+endfunction
+
+
+
+
function! arpeggio#_map_or_list(modes, remap_p, q_args) "{{{2
let [options, lhs, rhs] = s:parse_args(a:q_args)
if rhs isnot 0
View
7 doc/arpeggio.txt
@@ -76,6 +76,10 @@ INTERFACE *arpeggio-interface*
------------------------------------------------------------------------------
COMMANDS *arpeggio-commands*
+:Arpeggio {command} ... *:Arpeggio*
+ Equivalent to ":Arpeggio{command} ...". This command
+ is just for readability.
+
:Arpeggiomap {lhs} {rhs} *:Arpeggiomap*
:Arpeggiomap! {lhs} {rhs} *:Arpeggiomap!*
:Arpeggiocmap {lhs} {rhs} *:Arpeggiocmap*
@@ -260,6 +264,9 @@ BUGS *arpeggio-bugs*
==============================================================================
CHANGELOG *arpeggio-changelog*
+0.0.3 2008-11-09T10:37:46+09:00
+ - Add |:Arpeggio|.
+
0.0.2 2008-11-07T22:16:51+09:00
- Fix |:Arpeggionoremap| that allowed remapping but it should not do
so. (Thanks for id:ampmmn)
View
2  plugin/arpeggio.vim
@@ -36,6 +36,8 @@ endif
+command! -nargs=+ Arpeggio call arpeggio#_do(<q-args>)
+
command! -bang -nargs=* Arpeggiomap
\ call arpeggio#_map_or_list(<bang>0 ? 'ic' : 'nvo', 1, <q-args>)
command! -nargs=* Arpeggiocmap call arpeggio#_map_or_list('c', 1, <q-args>)
Please sign in to comment.
Something went wrong with that request. Please try again.