Shortcuts and settings
|Project view / Files view|
|Find in Path|
There are plenty of navigation views in AppCode. Knowing which one to call in a given situation will help you use the IDE more efficiently.
The Project view (
⌘1) is analogous to the Project navigator in Xcode. It shows all the projects included into the particular workspace and all the files and groups inside them:
By default, the Project view in AppCode shows files and folders in the same order as they are stored on the filesystem. You can change it by selecting Manual order in the options menu (if you selected Xcode behavior when setting up AppCode, this option will be enabled automatically):
There are also the Autoscroll from source and Autoscroll to source options. The former allows you to automatically open the code of a file when selecting it, while the latter automatically sets the focus on the file name in the Project view when the editor area is in focus:
Files view (
⇧⌘[) is an additional helpful mode for AppCode’s Project view. It shows all the files inside the directory where .xcworkspace or .xcproject is located. Using this view, you can easily open any file which is not included into your project and view it. As AppCode has lots of plugin integrations for various file types, it can be helpful, for example, when you need to edit your README.md in your project:
Structure view (
⌘7) and Structure popup (
⌥F12) show you the structure of a particular file together with all the
#pragma mark or
//MARK comments in your code. They work similarly to the Symbol navigator in Xcode:
The Imports hierarchy (
⌥⇧H) and Call hierarchy views (
^⌥H) allow you to see the hierarchy of imports in a particular file, or calls of particular methods or functions in Objective-C and C++:
The Find in Path (
⇧⌘F) dialog provides the same functionality as Find navigator in Xcode. Use it for full-text search:
When searching for code usages (usages of a variable, method, class name and so on), we recommend Find Usages (
⌥F7). Instead of just searching for text, it shows actual usages of a particular code symbol:
The Build messages tool window (
⌘0) shows compiler output and allows you to filter build messages by their type (see the Filter messages button on the left-hand side):
The Run tool window (
⌘4) shows the console where you can view the output of your application (or Tests runner if you are running the Test Run Configuration).
The Debug tool window (
⌘5) is similar to Xcode Debug navigator. It shows all the watches, local variables on the right-hand side, and the list of threads on the left-hand side:
The Breakpoints dialog (
⇧⌘F8) has the same functionality as Breakpoint navigator in Xcode - it shows the list of all breakpoints in your project:
The TODO tool window shows all
//FIXME comment tags in your code in a separate window:
Note that you can also create your custom filters for custom tags, by using the Filter TODO Items button on the left-hand side:
The Bookmarks dialog shows bookmarks in your code:
In AppCode you can bookmark any place in the code, or any file in the Project tool window, simply by pressing
F3. Edit the description via
⌥⏎ to give a summary for a bookmark.
The VCS (
⌘9) tool window provides everything you need to work with version control systems, including the Changes view, VCS log and more:
Finally, the Favorites tool window (
⌘2) aggregates bookmarks, breakpoints, and favorites:
Searching and filtering content in tool windows
Almost all tool windows and dialogs in AppCode (except for those that have a dedicated search field) allow you to search and filter its content just by typing some text. If you do not remember the whole name, try using fuzzy matching by typing just a part of the entity you are searching for:
Shortcuts and settings
|Go to class/file/symbol|
|Go to declaration/definition|
|Go to super definition|
|Go to related symbol|
|Go to last edited location|
|Go to line|
When working on your project, you often need to open and edit a specific class or file. The fastest way to do this is to use Go to Class (
⌘O) or Go to File (
Go to Symbol (
⌘⌥O) allows you to navigate directly to a symbol in your code - use fuzzy matching to enter just a part of the name:
Another important action from the Go to… family is Go to definition. Just place the caret at any symbol (variable or method) and press
⌘B to jump to its definition. If a method or class has several implementations,
⌘B will get you to the first one.
If you want to choose the definition to jump to, use
Go to super definition (
⌘U) will navigate you to the parent class declaration. Use Go to related symbol (
^⌘↑) to jump between the header and implementation.
Quick definition and documentation
To see the quick definition of a symbol in the code in-place, just press
F1 shows you the Quick documentation for the symbol under the caret.
Small icons in the gutter area are another way of navigating through your code. They’re useful to navigate through the class hierarchy:
In one click, these little icons can navigate you to a method’s definition or declaration, super methods, overridden methods, the implementation or a super class, and much more.
Recent files and Switcher
Recent files (
⌘E) shows you the list of recently opened files in the project:
The Switcher view (
^⇥) shows the same window, but works à la the window switcher on OSX.
Make your development much more efficient with these fast ways to navigate inside the code file:
⌘[/]- navigate back/forward between the navigation points.
F2/⇧F2- navigate to the next/previous error or warning in the code.
^↑/↓- jump to the previous/next method (extremely helpful when writing code).
⇧⌘⌫- jump to the last edited location.
⌘L- navigate to a specific line in the current file.
The following set of shortcuts help you search in AppCode efficiently:
- Use Find Usages (
⌥F7) to search for any code construct (class, variable, method, etc.):
- Use Find in Path (
⌘⇧F) to perform a regular full-text search in the project or directory.
- Use Find (
↑/↓to search inside a single file and navigate back/forward through the matches. Note that you can search using regular expressions.
Double⇧to Search Everywhere (even in IDE settings):
The last shortcut helps you search for IDE actions. Press
⇧⌘A to find nearly any action in the IDE or any preference you need, and jump directly to the desired place: