Last active
September 8, 2016 05:57
-
-
Save mmyers1474/c957768560fdb3afaf11e203ef909a96 to your computer and use it in GitHub Desktop.
VIM Status Line workspace
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
hi User1 guifg=#000000 guibg=#880c0e | |
hi User2 guifg=#000000 guibg=#C0C0C0 | |
hi User3 guifg=#C0C0C0 guibg=#0000FA | |
hi User4 guifg=#112605 guibg=#aefe7B | |
hi User5 guifg=#051d00 guibg=#7dcc7d | |
hi User7 guifg=#ffffff guibg=#880c0e gui=bold | |
hi User8 guifg=#ffffff guibg=#5b7fbb | |
hi User9 guifg=#ffffff guibg=#810085 | |
hi User0 guifg=#ffffff guibg=#094afe | |
hi statusline | |
set statusline= | |
set statusline+=%{ShowSpell()} | |
set statusline+=%{ShowWrap()} | |
set statusline+=%2* | |
set statusline+=\ %n\ | |
set statusline+=%3* | |
set statusline+=%{CenterFilename()} | |
set statusline+=%1* | |
function! CenterFilename() | |
let b:bfn = expand("%:t") | |
if strlen(b:bfn) < 15 | |
let nsp = ((15-strlen(b:bfn))/2) | |
else | |
let nsp = 1 | |
endif | |
let pad = repeat(' ',nsp) | |
let b:bfn = pad . b:bfn . pad | |
return b:bfn | |
endfunction | |
function! ShowWrap() | |
if &wrap | |
return "[Wrap]" | |
else | |
return "" | |
endfunction | |
function! ShowSpell() | |
if &spell | |
return "[Spell]" | |
else | |
return "" | |
endfunction | |
function ShowHighlight() | |
if &hl | |
endfunction | |
ai = autoindent | |
ff | |
ffs | |
fencs | |
ft | |
hl | |
hls | |
im = insertmode | |
ml = modeline | |
mls = modelines | |
mouse | |
paste | |
ruler ru | |
selection sel | |
selectmode slm | |
tabstop ts | |
command-line mode | |
modes: | |
normal | |
visual | |
select | |
operation-pending | |
insert | |
replace | |
command-line | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment