Edit Page
The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then publish the changes below to finish undoing the edit.
Latest revision | Your text | ||
Line 26: | Line 26: | ||
fu! FileEncoding() |
fu! FileEncoding() |
||
− | if &fileencoding == '' |
+ | if &fileencoding == '' |
return "is not set" |
return "is not set" |
||
else |
else |
||
− | return &fenc |
+ | return &fenc |
endif |
endif |
||
endf |
endf |
||
fu! GlobalEncoding() |
fu! GlobalEncoding() |
||
− | if &fileencoding == '' |
+ | if &fileencoding == '' |
return "is not set" |
return "is not set" |
||
else |
else |
||
− | return &enc |
+ | return &enc |
endif |
endif |
||
endf |
endf |
||
Line 49: | Line 49: | ||
"And we map switching on some unused key. |
"And we map switching on some unused key. |
||
− | map |
+ | map <F3> :call ToggleStatusLine()<CR> |
"Function that switch between several statuslines |
"Function that switch between several statuslines |
||
Line 57: | Line 57: | ||
let g:StatusLinesCurrent=0 |
let g:StatusLinesCurrent=0 |
||
endif |
endif |
||
− | let &statusline=g:StatusLines{g:StatusLinesCurrent} |
+ | let &statusline=g:StatusLines{g:StatusLinesCurrent} |
endf |
endf |
||
Line 92: | Line 92: | ||
<pre> |
<pre> |
||
− | let g:StatusLines{0}='%5* %*- |
+ | let g:StatusLines{0}='%5* %*->%7*[%*%1*%n%*%7*]%* %= %7*[%*%2*%03bD%* %7*|%* %2*%5(0x%02BH%)%*%7*]%* %7*[%*%3*%8oC%*%7*=%*%1*%3{Percent()}%%%*%7*]%* %7*[%*%4*%8c%*%7*]%* |
− | let g:StatusLines{1}='%5* %*- |
+ | let g:StatusLines{1}='%5* %*->%7*[%*%1*%n%*%7*]%* %= %7*[%*%1*ENC%* %2*%10{strlen(&enc)?&enc:"is not set"}%*%7*]%* %7*[%*%1*FENC%* %3*%10{strlen(&fenc)?&fenc:"is not set" |
− | let g:StatusLines{2}='%5* %*- |
+ | let g:StatusLines{2}='%5* %*->%7*[%*%1*%n%*%7*]%* %= %7*[%*%1*FILE%* %*%2*%t%*%7*]%*' |
let g:StatusLinesCurrent=-1 |
let g:StatusLinesCurrent=-1 |
||
Line 115: | Line 115: | ||
let g:StatusLinesCurrent=0 |
let g:StatusLinesCurrent=0 |
||
endif |
endif |
||
− | let &statusline=g:StatusLines{g:StatusLinesCurrent} |
+ | let &statusline=g:StatusLines{g:StatusLinesCurrent} |
endf |
endf |
||
</pre> |
</pre> |