travisjeffery / ClangFormat-Xcode

Xcode plug-in to to use clang-format from in Xcode and consistently format your code with Clang
https://twitter.com/travisjeffery
MIT License
2.89k stars 288 forks source link

Indentation is reset to zero when formatting a selected range that have non-zero indentation. #69

Closed yixiang closed 9 years ago

yixiang commented 9 years ago
1: int main() {
2:   if (a) {
3:     b();
4:   }
5: }
  1. select line 2-4
  2. Format Selected Text
  3. expect the format to stay the same, but go this instead.
1: int main() {
2: if (a) {
3:   b();
4: }
5: }
yixiang commented 9 years ago

Keeping it open until it's merged.

travisjeffery commented 9 years ago

Just merged!