VIM Doxygen support - auto asterisk (*) insertion on newline

c, c++, doxygen, vim

Solution

You need this in your `~/.vimrc`:

filetype plugin indent on

I don't know about DoxygenToolkit.vim, I have never used it. The above is all it takes to enable the described behaviour in my 7.x Vims.

You can find my commented ~/.vimrc online. Nothing too fancy in there, just what I use every day on half a dozen different Linux / AIX boxes. Perhaps there is more in there that you would like.

Problem

When I write Doxygen comments (in C file) I would like an asterisk to be automatically inserted on new line (either with the `o` command or just ↩ ). Like this example : ``` /** * My Doxygen comment being written ``` And when I hit ↩ ``` /** * My Doxygen comment bein written * ^ cursor is here ``` I have DoxygenToolkit.vim and `set syntax=c.doxygen` but none does what I want. I also found that but not sure what it is supposed to do, but doesn't solve my problem. I've googled for it but did not find. Any idea?

Original source