Community
Participate
Working Groups
See the following unresolved issue on stack overflow: http://stackoverflow.com/questions/11516623/stop-code-format-from-removing-whitespaces-in-eclipse To reproduce Add these local variables ... int ID = 0; int OBJECT_ID = 1; int SESSION_ID = 2; Select to format. Notice that eclipse changes the formatting and there does not appear to be an option to prevent this from happening. int ID = 0; int OBJECT_ID = 1; int SESSION_ID = 2; A mechanism is provided to align variable declarations in columns, but this is restricted to class variables. "Preferences: Java > Code Style > Formatter: Indentation > Align class fields in columns" There does not appear to be an option for local variables. So my carefully formatted code gets wiped out whenever the the formatter is run.
*** This bug has been marked as a duplicate of bug 131292 ***