Is there any shortcut key to align code content in Xcode? Is there any shortcut key to align code content in Xcode? xcode xcode

Is there any shortcut key to align code content in Xcode?


+ i (ctrl + i) is the shortcut key equivalent to Editor > Structure > Re-Indent ( in Xcode 6.4)

This will re-indent the line the cursor is on if no text is selected, or it will re-indent your selection.


1.) Select the text you want to align,

then

2.) press ctrl(^) + I.


If you want more than just indentation Xcode does not yet offer built in code formatting but you can use external tools like Uncrustify to apply a consistent code style.

I described how I last set this up here: http://blog.carbonfive.com/2009/08/07/code-formatting-in-xcode/