2023-06-22 05:32:39 +02:00
|
|
|
"TODO: port to LUA!
|
|
|
|
function! Minimal_foldtext()
|
2024-02-22 23:10:47 +01:00
|
|
|
let lines_count = v:foldend - v:foldstart + 1
|
|
|
|
let lines_count_text = '+' . v:folddashes . '| ' . printf("%10S" , lines_count) . ' lines |'
|
|
|
|
let line_level_text = '| ' . printf("%8S" , 'level ' . v:foldlevel) . ' |'
|
|
|
|
let fold_text_end = line_level_text . repeat('-',8)
|
|
|
|
let fold_text_length = strlen(lines_count_text . fold_text_end) + &foldcolumn
|
|
|
|
return lines_count_text . repeat('-' , winwidth(0) - fold_text_length - 4) . fold_text_end
|
2023-06-22 05:32:39 +02:00
|
|
|
endfunction
|