Coding style

Most of the changes were achieved by running `Uncrustify` (using `BBUncrustifyXcodePlugin`). The settings are available in uncrustify.cfg and need to be in the same folder when formatting. Of course, this is not perfect, so some changes had to be done manually. Ideally, we will not run this very often. A few details on the changes
- opening brace starts on the same line as method declaration/if/while/for...
- using all instruction blocks, no longer allowed simple instructions for if/else/for/while/...
- space formatting (instead of tabs)
- for #if macros, place a comment for the #else #endif with the #if part (so it's easier to match them)
- longer method calls extended on multiple lines
...but spaces here?