Changeset 2168
- Timestamp:
- 11/30/07 15:01:53 (5 years ago)
- Location:
- dotfiles/vim/kana
- Files:
-
- 1 added
- 3 modified
-
dot.vim/autoload/textobj/user.vim (modified) (1 diff)
-
dot.vim/ftplugin/issue.vim (modified) (3 diffs)
-
dot.vim/plugin/surround_config.vim (added)
-
dot.vimrc (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
dotfiles/vim/kana/dot.vim/autoload/textobj/user.vim
r1732 r2168 209 209 let r = a:pattern 210 210 let r = substitute(r, '<', '<LT>', 'g') 211 let r = substitute(r, '>', '<GT>', 'g')212 211 let r = substitute(r, '|', '<Bar>', 'g') 213 212 return r -
dotfiles/vim/kana/dot.vim/ftplugin/issue.vim
r1923 r2168 13 13 14 14 15 let s:RE_ISSUE_ID = '#\<\d\+\>' 16 17 15 18 16 19 … … 23 26 nnoremap <buffer> <LocalLeader>s :<C-u>call <SID>ShowStatus()<Return> 24 27 25 26 28 nnoremap <buffer> <LocalLeader>i :<C-u>call <SID>NewIssue()<Return> 27 29 nnoremap <buffer> <LocalLeader>n :<C-u>call <SID>NewNote()<Return> 28 30 31 nnoremap <buffer> <Return> :<C-u>call <SID>JumpToIssue()<Return> 32 33 call textobj#user#define(s:RE_ISSUE_ID, '', '', { 34 \ 'move-to-next': '<LocalLeader>j', 35 \ 'move-to-prev': '<LocalLeader>k', 36 \ }) 29 37 30 38 "" Moving around elements (just a memo; not implemented yet). … … 79 87 80 88 89 function! s:JumpToIssue() 90 echo 'FIXME: Not Implemented Yet.' 91 return 92 let BAD = [0, 0] 93 let pos = [line('.'), col('.')] 94 95 let fb = textobj#user#move(s:RE_ISSUE_ID, 'n') 96 let fe = textobj#user#move(s:RE_ISSUE_ID, 'ne') 97 let fdiff = s:Distance(pos, fb, fe) 98 99 let bb = textobj#user#move(s:RE_ISSUE_ID, 'nb') 100 let be = textobj#user#move(s:RE_ISSUE_ID, 'nbe') 101 let bdiff = s:Distance(pos, bb, be) 102 103 if fdiff != BAD && bdiff != BAD 104 if s:LT(fdiff, bdiff) 105 endif 106 elseif fdiff != BAD && bdiff == BAD 107 elseif fdiff == BAD && bdiff != BAD 108 else " if fdiff == BAD && bdiff == BAD 109 " nop 110 endif 111 endfunction 112 113 114 115 81 116 function! s:GetIDInfo() 82 117 let pos = getpos('.') -
dotfiles/vim/kana/dot.vimrc
r1923 r2168 1083 1083 1084 1084 " Make I/A available in characterwise-visual and linewise-visual. 1085 vnoremap <expr> I visualmode() == "\<C-v>" ? 'I' : "\<C-v>I" 1086 vnoremap <expr> A visualmode() == "\<C-v>" ? 'A' : "\<C-v>A" 1085 vnoremap I :<C-u>call <SID>ForceBlockwiseVisual('I')<Return> 1086 vnoremap A :<C-u>call <SID>ForceBlockwiseVisual('A')<Return> 1087 1088 function! s:ForceBlockwiseVisual(next_key) 1089 normal! gv 1090 if visualmode() != "\<C-v>" 1091 execute 'normal!' "\<C-v>" 1092 endif 1093 call feedkeys(a:next_key, 'n') 1094 endfunction 1087 1095 1088 1096 … … 1429 1437 nmap ss <Plug>Yssurround 1430 1438 1431 autocmd MyAutoCmd User DelayedSettings 1432 \ if exists('g:loaded_surround') || exists('*SurroundRegister') 1433 \ | call SurroundRegister('g', 'js', "「\r」") 1434 \ | call SurroundRegister('g', 'jd', "『\r』") 1435 \ | endif 1439 " See also ~/.vim/plugin/surround_config.vim . 1436 1440 1437 1441 … … 1500 1504 1501 1505 " __END__ "{{{1 1502 " vim: fileencoding=utf-8bomb1506 " vim: bomb 1503 1507 " vim: expandtab softtabstop=2 shiftwidth=2 1504 1508 " vim: foldmethod=marker
![(please configure the [header_logo] section in trac.ini)](/share/chrome/site/your_project_logo.png)