diff options
author | Tom Ryder <tom@sanctum.geek.nz> | 2018-07-16 14:09:06 +1200 |
---|---|---|
committer | Tom Ryder <tom@sanctum.geek.nz> | 2018-07-16 14:09:06 +1200 |
commit | 4826ac2858d02df0ebd5f4e25abb4b18805cbfcc (patch) | |
tree | a65c2f423cb61bd591af6e1b857a147e23ed0fd1 /vim/autoload | |
parent | Merge branch 'release/v1.31.0' (diff) | |
parent | Bump VERSION (diff) | |
download | dotfiles-4826ac2858d02df0ebd5f4e25abb4b18805cbfcc.tar.gz dotfiles-4826ac2858d02df0ebd5f4e25abb4b18805cbfcc.zip |
Merge branch 'release/v1.32.0'v1.32.0
* release/v1.32.0:
Bump VERSION
Add \m 'magic' setting to mail headers jump
Add reformatting analogue to quote mappings
Don't default <Plug>(InsertCancel)
Reformat comment in wildignore.vim
Make a filetype.vim comment consistent
Diffstat (limited to 'vim/autoload')
-rw-r--r-- | vim/autoload/quote.vim | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/vim/autoload/quote.vim b/vim/autoload/quote.vim index 6e943091..26e95698 100644 --- a/vim/autoload/quote.vim +++ b/vim/autoload/quote.vim @@ -28,3 +28,15 @@ function! quote#QuoteOpfunc(type) abort endfor endfunction + +" Tack on reformatting the edited text afterwards +function! quote#QuoteReformat() abort + set operatorfunc=quote#QuoteReformatOpfunc + return 'g@' +endfunction + +" Wrapper operator function to reformat quoted text afterwards +function! quote#QuoteReformatOpfunc(type) abort + call quote#QuoteOpfunc(a:type) + normal! '[gq'] +endfunction |