Originally Posted By: TechMuc
Can you give me a list of what you would like to customize?


I really like it is done in Eclipse CDT. It is done like this:


You have different tabs for categories like indentation, braces, whitespace, etc. and othe options on the left and an example source code in a window on the right.

I could write down all the stuff, but it might be easier if you check it out yourself: go here and download the 32- or 64-bit version (depends on your OS), start eclipse.exe, open Window/Preferences and select in the tree C,C++/Code Style/Formatter, click on Edit... and you can see it for yourself.

Personally, I most often changes the settings for:

  • tab size
  • indent statements withing function bodies, blocks, switch bodies, case bodies, breaks
  • braces always on the next line for if, else, blocks in case statements and switch statements
  • whitespace in function heads before opening parenthesis
  • whitespace after opening- and before closing brace in initializer lists
  • no whitespace after typecast closing parenthesis
  • insert new line before "else" in an "if" statement
  • in if-else-if statements each statement (if, else) in a new line and indented
  • all ifs with braces, even simple ones
  • line wrapping at column x (e.g. 80)
  • indentation for wrapped lines = 2 tabs
  • auto-wrapping of comment blocks