Bug 43595 Javadoc formatter adds an extra line every time you format
20030924 Everytime you format a comment with a blank line another blank line is added. STEPS 1)Add a comment like this: /** * Get the progress monitor for a job. If it is a UIJob get the main * monitor from the status line. Otherwise get a background monitor. * * @return IProgressMonitor */ 2) Make a change in another method and format. It will look this this afterwards /** * Get the progress monitor for a job. If it is a UIJob get the main * monitor from the status line. Otherwise get a background monitor. * * * @return IProgressMonitor */
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/comment/JavaDocRegion.java
*/
	protected void markRegion() {
		int length= 0;
		String token= null;
		JavaDocRange range= null;
		for (final Iterator iterator= getRanges().iterator(); iterator.hasNext();) {
			range= (JavaDocRange)iterator.next();
			length= range.getLength();
			if (length > 0) {
				token= getText(range.getOffset(), length).toLowerCase();
				range.markJavadocTag(JAVADOC_PARAM_TAGS, token, JAVADOC_PARAMETER);
				range.markJavadocTag(JAVADOC_ROOT_TAGS, token, JAVADOC_ROOT);
				if (fSeparateRootTags && (range.hasAttribute(JAVADOC_ROOT) || range.hasAttribute(JAVADOC_PARAMETER))) {
					range.setAttribute(JAVADOC_PARAGRAPH);
					fSeparateRootTags= false;
				}
				if (range.hasAttribute(COMMENT_HTML)) {
					range.markHtmlTag(JAVADOC_SEPARATOR_TAGS, token, JAVADOC_SEPARATOR, true, true);
					range.markHtmlTag(JAVADOC_BREAK_TAGS, token, COMMENT_BREAK, false, true);
					range.markHtmlTag(JAVADOC_NEWLINE_TAGS, token, COMMENT_NEWLINE, true, false);
					range.markHtmlTag(JAVADOC_IMMUTABLE_TAGS, token, JAVADOC_IMMUTABLE, true, true);
				}
			}
		}
		markRanges(JAVADOC_IMMUTABLE_TAGS, JAVADOC_IMMUTABLE, true);
		if (fFormatSource)
			markRanges(JAVADOC_CODE_TAGS, JAVADOC_CODE, false);
	}
}