From 4593ec04e71b2c81add89f9a7d3cc972ae14e316 Mon Sep 17 00:00:00 2001 From: mickey695 Date: Tue, 8 May 2018 02:59:08 +0300 Subject: [PATCH] Problem: Combination of `autoindent` and manual configuration of `g:DoxygenToolkit_start/inter/endCommentTag` with spaces in the string would create documentation with too much indentation, such as: /** * @brief ... * @param ... * @return ... **/ instead of the wanted: /** * @brief * @param * @return **/ Added workaround: Disable autoindent at the start of the documenting function and enable it at the end. --- plugin/DoxygenToolkit.vim | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/plugin/DoxygenToolkit.vim b/plugin/DoxygenToolkit.vim index 37d51a6..33621c5 100644 --- a/plugin/DoxygenToolkit.vim +++ b/plugin/DoxygenToolkit.vim @@ -552,6 +552,9 @@ endfunction """"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" function! DoxygenCommentFunc() + " Prevent autoindent from placing too much indentation when placing spaces in manual configuration + set noautoindent + " Initialize default templates. " Assure compatibility with Python for classes (cf. endDocPattern). let l:emptyLinePattern = '^[[:blank:]]*$' @@ -839,6 +842,8 @@ function! DoxygenCommentFunc() " endfor "endif + set autoindent + endfunction