Mercurial > dotfiles
diff .chezmoitemplates/config.vim @ 463:1d2e33dfe0c6
Clean up folding and foldtexts
author | zegervdv <zegervdv@me.com> |
---|---|
date | Fri, 24 Sep 2021 10:03:31 +0200 |
parents | ae7e377bced8 |
children | d2b877b4ef8b |
line wrap: on
line diff
--- a/.chezmoitemplates/config.vim Fri Sep 24 09:44:17 2021 +0200 +++ b/.chezmoitemplates/config.vim Fri Sep 24 10:03:31 2021 +0200 @@ -240,25 +240,6 @@ augroup END " -" Custom folding by Steve Losh -function! MyFoldText() " - let line = getline(v:foldstart) - - let nucolwidth = &fdc + &number * &numberwidth - let windowwidth = winwidth(0) - nucolwidth - 3 - let foldedlinecount = v:foldend - v:foldstart - - " expand tabs into spaces - let onetab = strpart(' ', 0, &tabstop) - let line = substitute(line, '\t', onetab, 'g') - - let line = strpart(line, 0, windowwidth - 2 -len(foldedlinecount)) - let fillcharcount = windowwidth - len(line) - len(foldedlinecount) - return line . '…' . repeat(" ",fillcharcount) . foldedlinecount . '…' . ' ' -endfunction " -set foldtext=MyFoldText() -set foldopen+=jump - " Detect Filetype from content if file has no extension augroup newFileDetection au! @@ -649,7 +630,6 @@ au! au FileType systemverilog setlocal suffixesadd+=.sv,.v au FileType systemverilog setlocal foldmethod=expr - au FileType systemverilog setlocal foldexpr=nvim_treesitter#foldexpr() au FileType systemverilog,verilog call SVAlign() au FileType systemverilog,verilog let b:delimitMate_quotes = "\"" au FileType systemverilog,verilog set iskeyword+='