46baae6f3aed

vim: tweaks
[view raw] [browse files]
author Steve Losh <steve@stevelosh.com>
date Mon, 09 May 2011 15:26:55 -0400
parents 8f472db0b208
children 9bbd28435e0e
branches/tags (none)
files vim/.vimrc

Changes

--- a/vim/.vimrc	Mon May 09 14:55:58 2011 -0400
+++ b/vim/.vimrc	Mon May 09 15:26:55 2011 -0400
@@ -373,6 +373,7 @@
 au Filetype python noremap  <localleader>rr :RopeRename<CR>
 au Filetype python vnoremap <localleader>rm :RopeExtractMethod<CR>
 au Filetype python noremap  <localleader>ri :RopeOrganizeImports<CR>
+au FileType python setlocal omnifunc=pythoncomplete#Complete
 
 " }}}
 " Django {{{
@@ -418,9 +419,6 @@
 " Clean whitespace
 map <leader>W :%s/\s\+$//<cr>:let @/=''<CR>
 
-" Ack
-map <leader>a :Ack 
-
 " Change case
 nnoremap <C-u> gUiw
 inoremap <C-u> <esc>gUiwea
@@ -452,7 +450,7 @@
 nmap <leader><tab> :Sscratch<cr><C-W>x<C-j>:resize 15<cr>
 
 " Better Completion
-set completeopt=longest,menuone
+set completeopt=longest,menuone,preview
 inoremap <expr> <CR>  pumvisible() ? "\<C-y>" : "\<C-g>u\<CR>"
 inoremap <expr> <C-p> pumvisible() ? '<C-n>'  : '<C-n><C-r>=pumvisible() ? "\<lt>up>" : ""<CR>'
 inoremap <expr> <C-n> pumvisible() ? '<C-n>'  : '<C-n><C-r>=pumvisible() ? "\<lt>Down>" : ""<CR>'
@@ -481,6 +479,11 @@
 " }}}
 " Plugin settings ------------------------------------------------------------- {{{
 
+" Ack {{{
+
+map <leader>a :Ack! 
+
+" }}}
 " NERD Tree {{{
 
 noremap <F2> :NERDTreeToggle<cr>
@@ -560,6 +563,18 @@
 nmap <Leader>x <Plug>ToggleAutoCloseMappings
 
 " }}}
+" Tasklist {{{
+
+let g:tlRememberPosition = 1
+map <leader>td <Plug>TaskList
+
+" }}}
+" Pydoc {{{
+
+au FileType python noremap <buffer> <localleader>lw :call ShowPyDoc('<C-R><C-W>', 1)<CR>
+au FileType python noremap <buffer> <localleader>lW :call ShowPyDoc('<C-R><C-A>', 1)<CR>
+
+" }}}
 
 " }}}
 " Synstack -------------------------------------------------------------------- {{{