From: Ciro Santilli Date: Sat, 30 Aug 2014 14:22:30 +0000 (+0200) Subject: Merge pull request #110 from cirosantilli/fix-header-increase X-Git-Url: https://git.madduck.net/etc/vim.git/commitdiff_plain/9a3b3126eeb98a1bf5a327912b2ff0bf591ccec2?hp=82ced930ae169ee276b85db716fb8d1e24dd53eb Merge pull request #110 from cirosantilli/fix-header-increase Fix header increase and decrease. --- diff --git a/ftplugin/mkd.vim b/ftplugin/mkd.vim index dfb5546..057947b 100644 --- a/ftplugin/mkd.vim +++ b/ftplugin/mkd.vim @@ -302,21 +302,21 @@ function! s:Markdown_Toc(...) endif try - silent vimgrep /\(^\S.*\(\n[=-]\+\n\)\@=\|^#\+\)/ % + silent lvimgrep /\(^\S.*\(\n[=-]\+\n\)\@=\|^#\+\)/ % catch /E480/ echom "Toc: No headers." return endtry if l:window_type ==# 'horizontal' - copen + lopen elseif l:window_type ==# 'vertical' - vertical copen + vertical lopen let &winwidth=(&columns/2) elseif l:window_type ==# 'tab' - tab copen + tab lopen else - copen + lopen endif set modifiable %s/\v^([^|]*\|){2,2} #//