Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Xcode 4: Keyboard shortcut for switching Assistant Editor to Tracking (Automatic) mode?

Tags:

xcode

xcode4

I like using the Assistant Editor in Xcode 4. I frequently Option-Click files to open them in the Assistant Editor, or use Open Quickly (Command-Shift-O), and hold the option key when selecting a file to open it in the Assistant Editor.

Both of these actions switch the Assistant Editor to Manual mode. Is there a keyboard shortcut to switch the Assistant Editor back to Tracking mode (also called Automatic)? In tracking mode it automatically shows the counterpart, e.g. the corresponding header/implementation file for the file in your main editor. know I can select Automatic mode it with the mouse on the Assistant Editor Jump bar, but I really want a keyboard shortcut to do this.

like image 692
Jeremy Avatar asked Jul 15 '11 17:07

Jeremy


People also ask

What's new in the Xcode 11 assistant editor?

One big change in the Xcode 11 Assistant Editor is that there is no manual option. In order to open a destination file in the secondary editor, do a Shift + Command + O to do a quick open, and press the option key while selecting the file, as shown:

What are the keyboard shortcuts for Xcode navigation?

Xcode Navigation Keyboard Shortcuts 1. Project Navigator: Command + 1 Quickly view all your code, images, and user interface files.

How do I track my movement history in Xcode?

Xcode tracks your entire movement history as soon as you open or create a project. Any file you go to, any symbol you look up - it all is appended to the IDE’s navigation stack. Use ⌃ + ⌘ + ← and ⌃ + ⌘ + → to go back and forth between the source code locations you visited.

How to edit all in scope together in Xcode 9?

The following shortcut lets us edit all in scope together at the same time: In order to look at the outline of your file, the methods present, simply press Command + 6. It opens a jump bar from where you can search the desired method and you jump directly to it. Since Xcode 9, command+click doesn’t directly take you to the definition.


2 Answers

I made this to help answer another question... Does it help?

enter image description here

like image 152
Robert Avatar answered Oct 14 '22 18:10

Robert


In the View -> Assistant Editor menu, there's an item called "Reset Editor". The default keyboard shortcut is Cmd-Opt-Shift-Z. It resets the Assistant View to show Counterparts.

I don't know if it's new in Xcode 4.1, but it should be a little easier than AppleScripting.

Alternatively, you could create a behavior to reset the editor how you'd like and bind it to a keyboard shortcut.

like image 40
JimDusseau Avatar answered Oct 14 '22 19:10

JimDusseau