Bug 202552 - [clean up] Unify format and cleanup options
Summary: [clean up] Unify format and cleanup options
Status: ASSIGNED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.4   Edit
Hardware: All All
: P5 enhancement (vote)
Target Milestone: ---   Edit
Assignee: JDT-UI-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-09-06 19:18 EDT by Michael Stather CLA
Modified: 2008-11-13 03:11 EST (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Stather CLA 2007-09-06 19:18:32 EDT
The "format", "clean up", "sort members" options (and perhaps other features as well which auto-process the code) are IMHO a very great feature. I suggest that they're unified in a way that I can save all of those settings to one xml file, instead of having one xml file for every feature.
Then they could also have a common root in the options dialog, say "automatic code processing" or something like that. Currently "sort members" is in "appearance" while the others are in "code style".

Then there could also be an option to do all those tasks one after another (e.g. "do code cleanups"), for example first do a cleanup then sort the members and at last format the code.

I just think of shared projects, developers could agree on settings for all those functions, then export them into SVN for example and every developer could just use "do code cleanups" in the context menu to clean up the code as good as possible. The latter is currently not possible while the former is rather difficult.
Comment 1 Jerome Lanneluc CLA 2007-09-07 05:01:18 EDT
Moving to JDT/UI
Comment 2 Martin Aeschlimann CLA 2007-09-07 05:21:33 EDT
With the exception of the member sort order, you can already have project specific options that are then stored inside the project and shared in the CVS.

The clean up action 'Clean Up' can already be configured to perform a sort member and a format (last page). You can also enable 'Save action' to perform sort members, format and some of the clean up actions.

So I think it's all there, with the exception that you can define a project specific member sort order.

Do you agree?

The problem is that we use the member sort order for the sorting order in views. There its clearly an appearance settings and it's not common to have project specific settings. So maybe we have to split the preference.
Comment 3 Michael Stather CLA 2007-09-07 12:32:50 EDT
Yes, I also saw this, sorry for reporting this "issue" *gg

Since the exported files are xml files, could it be made possible that when I select "export" and an existing file, eclipse wouldn't overwrite it but attach the informations from the relevant formatting plugin to the file or at least ask me to do so. And the plugins just read their settings from such a file and don't comlain about the other values from other plugins when importing.

Then all relevant settings could be stored in a single file. Of course this is not important but IMHO nice to have.