

Last but not least, you can show an "Action" popover for the code under the caret by pressing Cmd + Shift + A. In the case of Swift source files, this will open a generated file that contains just the interface.

Xcode also makes it easy to open associated files by pressing Cmd + Ctrl + Arrow Up/Down.

No need to scroll around the source file or scan the mini map. Selecting a method from this menu jumps to its position in the source file. If you opened a file with the "Open Quickly" dialog and want to jump to its location in the navigator pane, you can press CMD + Shift + J to do so.Īnother handy shortcut when editing or reviewing source files is Ctrl + 6 which opens a menu in the navigation bar that contains all classes, properties and methods of the current source file and allows filtering by just typing away. Simply start typing any part of the file's name - it doesn't even have to be consecutive letters: "mwinco" will find your " Main Window Controller" class.Īs if this wouldn't be cool enough, this dialog also lets you decide which editor to open the file in: hold down CMD + OPT + SHIFT while double-clicking the file to open. Instead, you can use Xcode's "Open Quickly" dialog (CMD + SHIFT + O). You shouldn't waste your time digging for a file in your folder hierarchy.

You can also move the cursor to the edge of the window to open the file in a new editor there. The first visible editor will be highlighted and you can move that selection by moving the mouse cursor over another open editor to open the file there. When clicking on a file in the Navigator, hold down SHIFT + OPT.In Xcode, you can open a file in various ways: in the standard editor, in a new or existing assistant editor, in a new or existing tab, or in a new window.
