JavaDoc Formatting

JavaDoc formatting has been a problem ever since I can remember. My company uses non standard comment formatting ( not my idea ). Even though I have Enable JavaDoc formatting off two issues remain.

When copying and pasting code. I'd like to keep the code reformatting on without it affecting my comments.

When implementing Interface methods and copying the javaDoc. These get reformatted even when you turn off code reformatting on paste.

I know these sound like minor issues but all of our comments are indented using specific guidelines and any time I have to do the above things I have to tediously go and fix them.
Any suggestions would be welcome. Unfortunately using standard JavaDoc isn't an option...

Comment actions Permalink

I forgot: reformatting code, which we do a lot of, screws the comments up as well.

Comment actions Permalink

We also can't use Javadoc formatting because it's impossible to
configure it to meet our standards:


  • TAB, not blank, after leading star, like this

  • (assuming 4-character tabs),

  • Not this.



  • Descriptions on next line after tag, indented an extra

  • level.


  • @param i

  • Like this. With long descriptions continued

  • at the same level.


  • @return

  • Same thing for tags without arguments.


The first is particularly annoying, because IDEA, trying to be smart,
automatically creates the *-blank as you type Javadoc, whether you have
Javadoc formatting on or off. As far as I know, there is no way to alter
this behavior--or even turn it off.

Picky, yes; but things like this have a disproportionate impact on the
amount of "pleasure" one feels using the tool.


Please sign in to leave a comment.