From 86ee76daf5650d2c0526a6d7567ac3853c03b732 Mon Sep 17 00:00:00 2001 From: Tom Ryder Date: Fri, 14 Jun 2019 19:40:02 +1200 Subject: Move to body text correctly for start guesser --- vim/after/ftplugin/mail.vim | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'vim/after') diff --git a/vim/after/ftplugin/mail.vim b/vim/after/ftplugin/mail.vim index d9a24082..43586731 100644 --- a/vim/after/ftplugin/mail.vim +++ b/vim/after/ftplugin/mail.vim @@ -6,6 +6,12 @@ let b:quote_space = 0 " to start writing function! s:SuggestStart() abort + " Move to top of buffer + call setpos('.', [0, 1, 1, 0]) + + " Move to body text + call search('\m^$', 'c') | + + " Start by trying to move to the first quoted line; this may fail if there's " no quote, which is fine call search('\m^>', 'c') -- cgit v1.2.3