better foldtext
This commit is contained in:
parent
5578dc77d0
commit
087a57c7b1
|
@ -63,12 +63,11 @@ set mouse=a
|
||||||
|
|
||||||
set listchars=eol:¬,tab:->,trail:~,extends:>,precedes:<,space:·
|
set listchars=eol:¬,tab:->,trail:~,extends:>,precedes:<,space:·
|
||||||
|
|
||||||
" set foldtext=getline(v:lnum)
|
|
||||||
set foldtext=MyFoldText()
|
set foldtext=MyFoldText()
|
||||||
function MyFoldText()
|
function! MyFoldText()
|
||||||
let line = getline(v:foldstart)
|
let l:linecount = v:foldend - v:foldstart - 1
|
||||||
let sub = substitute(line, '/\*\|\*/\|{{{\d\=', '', 'g')
|
let l:line = getline(v:foldstart)
|
||||||
return v:folddashes . sub
|
return v:folddashes . ' ' . l:line . ' |+' . l:linecount . '|'
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue