Question

There is the small tag which is created at some places if I reformat the code in Android Studio and other Jetbrains products as well.

How can I prevent that?

enter image description here

Was it helpful?

Solution

The <p/> tag is generated on empty lines so that they are shown in the javadocs.

If you want to, you can turn this off when you reformat the code.

In Android Studio, go to File -> Settings -> Code Style -> Java -> JavaDoc tab -> Uncheck Generate "<p/>" on empty lines

Where to turn off generation of the p tag

Here is what the documentation will look like with and without the paragraph tag, where on the right is the text from the quick docs window.

Example of the docs with and without p tag.

Just take that into consideration.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top