Bug 229108 - [formatter] New comment formatter adds unnecessary spaces before and after <code> tags
Summary: [formatter] New comment formatter adds unnecessary spaces before and after <c...
Status: VERIFIED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.4   Edit
Hardware: PC All
: P3 normal (vote)
Target Milestone: 3.4 M7   Edit
Assignee: Frederic Fusier CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-04-28 12:12 EDT by Frederic Fusier CLA
Modified: 2008-04-29 11:16 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Frederic Fusier CLA 2008-04-28 12:12:46 EDT
I20080427-2000.

While fixing bug 229017, it appears that the new comment formatter inserts unnecessary space before and after code tags as shown in following test case:

public class X23d {

	/**
	 *	  <ul>
	 *	    <li><code>first line</code></li>
	 *	    <li><code>second line</code></li>
	 *	  </ul>
	 */
	void foo() {
	}
}

which is formatted as:

public class X23d {

	/**
	 * <ul>
	 * <li> <code>first line</code></li>
	 * <li> <code>second line</code></li>
	 * </ul>
	 */
	void foo() {
	}
}
Comment 1 Frederic Fusier CLA 2008-04-28 12:13:43 EDT
Need to handle whether a space exists before/after html tags to preserve them when  no new lines is inserted before or after...
Comment 2 Frederic Fusier CLA 2008-04-28 12:32:03 EDT
Released for 3.4M7 in HEAD stream.
Comment 3 Kent Johnson CLA 2008-04-29 11:16:46 EDT
Verified for 3.4M7 using I20080429-0100