Changeset 33878

Show
Ignore:
Timestamp:
06/10/09 15:26:24 (4 years ago)
Author:
kozo-ni
Message:

moved smartchr setting from vimrc to python.vim

Location:
dotfiles/vim/kozo-ni
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • dotfiles/vim/kozo-ni/.vim/ftplugin/python.vim

    r33822 r33878  
     1" smartchr 
     2inoremap <buffer> <expr> = smartchr#one_of(' = ', ' == ', '=') 
     3inoremap <buffer> <expr> + smartchr#one_of(' + ', '+') 
     4 
    15setlocal tags+=$HOME/.vim/tags/python.ctags 
    26 
  • dotfiles/vim/kozo-ni/.vimrc

    r33821 r33878  
    245245" map each number to its shift-key character 
    246246inoremap 1 ! 
     247inoremap ! 1 
    247248cnoremap 1 ! 
     249 
    248250inoremap 2 ""<LEFT> 
     251inoremap " 2 
     252 
    249253inoremap 3 # 
     254inoremap # 3 
     255 
    250256inoremap 4 $ 
     257inoremap $ 4 
     258noremap 4 $ 
     259 
    251260inoremap 5 % 
     261inoremap % 5 
     262 
    252263inoremap 6 & 
     264inoremap & 6 
     265 
    253266inoremap 7 ''<LEFT> 
     267inoremap ' 7 
     268 
    254269inoremap 8 ()<LEFT> 
     270inoremap ( 8 
     271 
    255272inoremap 9 ) 
     273inoremap ) 9 
     274 
    256275inoremap 0 ~ 
    257  
    258 noremap 4 $ 
     276inoremap ~ 0 
    259277cnoremap 0 ~ 
     278 
    260279noremap - : 
    261280"noremap : - 
    262  
    263 " and then the opposite 
    264 inoremap ! 1 
    265 inoremap " 2 
    266 inoremap # 3 
    267 inoremap $ 4 
    268 inoremap % 5 
    269 inoremap & 6 
    270 inoremap ' 7 
    271 inoremap ( 8 
    272 inoremap ) 9 
    273 inoremap ~ 0 
    274  
    275 inoremap = - 
    276  
    277 " smartchr 
    278 inoremap <buffer> <expr> - smartchr#one_of(' = ', ' == ', '=') 
    279 inoremap <buffer> <expr> ; smartchr#one_of(' + ', '+') 
    280 inoremap + ; 
    281281 
    282282" }}}