Bug 47587 - Formatter gives static fields extra indentation due to //$NON-NLS-1$ flag
Summary: Formatter gives static fields extra indentation due to //$NON-NLS-1$ flag
Status: RESOLVED WORKSFORME
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.0   Edit
Hardware: PC Windows 2000
: P3 normal (vote)
Target Milestone: 3.0 M6   Edit
Assignee: Olivier Thomann CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-11-26 16:35 EST by Nick Edgar CLA
Modified: 2003-11-27 11:32 EST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Nick Edgar CLA 2003-11-26 16:35:33 EST
build I20031121

- load platform-ui module
- import prefs from: 
http://dev.eclipse.org/viewcvs/index.cgi/%7Echeckout%7E/platform-ui-home/code-
conventions/index.html
- open ActionFactory.java (in org.eclipse.ui.actions)
- format
- it indents all the static fields one step too far
- e.g.:

	/**
	 * Workbench action (id "activateEditor"): Activate the most recently 
used
	 * editor. This action maintains its enablement state.
	 */
		public static final ActionFactory ACTIVATE_EDITOR = new 
ActionFactory("activateEditor") {//$NON-NLS-1$
	/* (non-javadoc) method declared on ActionFactory */
...

The non-javadoc comment is also not indented correctly (it is outdented).

If the //$NON-NLS-1$ is taken out, these both get fixed up.
Comment 1 Nick Edgar CLA 2003-11-26 16:50:53 EST
Interestingly, this doesn't seem to be happening for IDEActionFactory.java.
Comment 2 Olivier Thomann CLA 2003-11-27 09:14:28 EST
Are you using the new formatter?
Check Preferences>Java>Work in progress.
Comment 3 Olivier Thomann CLA 2003-11-27 11:11:46 EST
I will investigate with the new formatter.
Comment 4 Olivier Thomann CLA 2003-11-27 11:32:44 EST
This is fixed with the new formatter.
Closing as WORKSFORME.