WIP: Fix/refactor/add AStyleFormatter's options
I am marking this merge request as "WIP" because the final fix/decision regarding !118 may require changes here. That is, if we can't completely fix
KDevelop::extractFormattedTextFromContext(), then perhaps the 3rd commit "Allow configuring add-braces astyle option" should be replaced with a simpler fix to reduce the likelihood of breaking reformatted code: remove the single
Originally I intended to base at least some of the fixes here on 5.5 rather than on master branch. But this branch was implemented on top of !116 (closed), which ended up only in master. Most of the bugs fixed here exist for a very long time and weren't noticed by many, so I suppose getting them into branch 5.5 is not critical and not worth dealing with merge conflicts.
See commit messages for details.