Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Moving caret back/forward to previous/next editing position within a document in Xcode 4?

In Xcode 3, I could go back to previous editing point within a document by pressing Command+Control+[Left|Right]. (I'm confusing it was Control or Option... However) In Xcode 4, the key combination is assigned to other feature. Code folding..? What did this key change into?

like image 267
eonil Avatar asked Mar 13 '11 10:03

eonil


People also ask

How do I navigate back 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 do I go to a line in Xcode?

Jump to Line: ⌘ + L (Command + L) This command will jump to a specific line in the current file.


2 Answers

The shortcut in XCode 4 for "Go forward/backward" is "Control" + "Command" + "Arrow"

This is super annoying for me. When I tried to change the shortcut in the Shortcut Editor back to the Xcode 3 way, Xcode crashes. Fun.

like image 188
mdizzle Avatar answered Sep 18 '22 10:09

mdizzle


Another option for switching to Previous/Next editing position (Go Back/Go Forward) is using two finger swipe (left for Go Back, right for Go Forward). I realize that this is not a keyboard shortcut but if you are using a Trackpad, it is much faster than trying to click on the buttons.

Note: The pointer does need to be in the editor for swiping to work.

like image 21
Brian T. Avatar answered Sep 21 '22 10:09

Brian T.