add "yp" and ",S" commands
This commit is contained in:
parent
a726149f59
commit
aba86e285d
1 changed files with 13 additions and 3 deletions
16
.vimrc
16
.vimrc
|
|
@ -13,7 +13,7 @@ call pathogen#infect()
|
||||||
" yankring - maintains a list of numbered registers containing the last deletes, see :YRShow
|
" yankring - maintains a list of numbered registers containing the last deletes, see :YRShow
|
||||||
" taglist - groups and displays the functions, classes, … in a Vim window
|
" taglist - groups and displays the functions, classes, … in a Vim window
|
||||||
|
|
||||||
set guifont=Inconsolata\ 12
|
set guifont=Inconsolata\ 11
|
||||||
|
|
||||||
syntax on " syntax coloring by default
|
syntax on " syntax coloring by default
|
||||||
|
|
||||||
|
|
@ -55,7 +55,7 @@ set showcmd " show informations about selection while in visual mode
|
||||||
|
|
||||||
set guioptions-=T "remove toolbar
|
set guioptions-=T "remove toolbar
|
||||||
|
|
||||||
set colorcolumn=80,120 " highligth the 80th and 120th column
|
set colorcolumn=72,120 " highligth the 80th and 120th column
|
||||||
|
|
||||||
"set cursorline " highlight current line
|
"set cursorline " highlight current line
|
||||||
|
|
||||||
|
|
@ -83,6 +83,9 @@ let mapleader = "," " leader key is comma
|
||||||
" xx will delete the line without copying it into the default register
|
" xx will delete the line without copying it into the default register
|
||||||
nnoremap xx "_dd
|
nnoremap xx "_dd
|
||||||
|
|
||||||
|
" Yank the line, comment it, paste it
|
||||||
|
nnoremap yp yygccp
|
||||||
|
|
||||||
" When jumping to a given line, center the screen
|
" When jumping to a given line, center the screen
|
||||||
nnoremap G Gzz
|
nnoremap G Gzz
|
||||||
|
|
||||||
|
|
@ -92,6 +95,9 @@ nnoremap <leader>v V`]
|
||||||
" ,s will split vertically and swith over the new panel
|
" ,s will split vertically and swith over the new panel
|
||||||
nnoremap <leader>s <C-w>v<C-w>l:bn<CR>
|
nnoremap <leader>s <C-w>v<C-w>l:bn<CR>
|
||||||
|
|
||||||
|
" ,S will split horizontally and swith over the new panel
|
||||||
|
nnoremap <leader>S <C-w>s<C-w>l:bn<CR>
|
||||||
|
|
||||||
" Wrap a paragraph and justify it
|
" Wrap a paragraph and justify it
|
||||||
:runtime macros/justify.vim
|
:runtime macros/justify.vim
|
||||||
nnoremap <leader>j gw}{V}:call Justify('tw',4)<CR>
|
nnoremap <leader>j gw}{V}:call Justify('tw',4)<CR>
|
||||||
|
|
@ -109,7 +115,7 @@ nnoremap <leader>c :%s/\/\*\_.*\*\/\n\{,1}\|^\s*\/\/.*\n\|\s*\/\/.*//<CR>:%s/^\s
|
||||||
nnoremap <leader>h :set guifont=Inconsolata\ 4<CR>
|
nnoremap <leader>h :set guifont=Inconsolata\ 4<CR>
|
||||||
|
|
||||||
" set a normal guifont size
|
" set a normal guifont size
|
||||||
nnoremap <leader>f :set guifont=Inconsolata\ 12<CR>
|
nnoremap <leader>f :set guifont=Inconsolata\ 11<CR>
|
||||||
|
|
||||||
" set a big guifont size
|
" set a big guifont size
|
||||||
nnoremap <leader>ç :set guifont=Inconsolata\ 14<CR>
|
nnoremap <leader>ç :set guifont=Inconsolata\ 14<CR>
|
||||||
|
|
@ -119,6 +125,10 @@ nnoremap <leader>ç :set guifont=Inconsolata\ 14<CR>
|
||||||
cnoremap %% <C-R>=expand('%:h').'/'<cr>
|
cnoremap %% <C-R>=expand('%:h').'/'<cr>
|
||||||
map <leader>p :CtrlP %%<cr>
|
map <leader>p :CtrlP %%<cr>
|
||||||
|
|
||||||
|
" semantic selection expansion/shrink
|
||||||
|
map + <Plug>(expand_region_expand)
|
||||||
|
map - <Plug>(expand_region_shrink)
|
||||||
|
|
||||||
" use shift-space as escape
|
" use shift-space as escape
|
||||||
"inoremap <S-Space> <Esc>
|
"inoremap <S-Space> <Esc>
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue