tags:

views:

278

answers:

5

Xcode 3.2 has implemented cursor-level history for the "Go Forward", "Go Backward" commands. Previously these worked at the file level, so you could navigate back and forth through recent files you've been editing. Now they navigate at a more fine-grained level, through the places within files where you have been editing.

The downside to this is if you navigate backwards through the files and make a minor edit, all of your forward history is wiped out, whereas in the past it used to be easy to return to the file you were working on. It also means issuing a lot more commands if you just want to move through files, since you have to skip through all the edit points within each file.

I can't find anything in the release notes or documentation about this new behavior, so does anyone know if it's possible to get the old 'go back/forward by file' commands in 3.2? If not, does anyone have any tips on other ways of easily navigating recent files in Xcode?

A: 

There are Next File and Previous File commands, however their history is also wiped out after an edit. That seems like a bug to me.

Darren
+2  A: 

Hold down the option key while you click the forward/backward arrows at the top of the code view, this will use the Xcode 3.0 behavior and go back a file at a time.

Rob Keniger
Thanks Rob, that is handy. As Darren noted I still lose my forward history as soon as I make an edit, but both your answers get me a lot closer.
+2  A: 

I had the same question as well and and Rob's answer on holding Option while clicking the forward/backward arrows works well.

I needed a keyboard shortcut though and I've found that Shift-Option-Cmd-left/right works.

Chu Yeow
A: 

This is plain stupid! What's the reason for suddenly change this ? Shift-Option-Cmd-left/right... great, more stupid shortcuts from Apple. I guess I soon have to use Shift-Option-Cmd-Left-Alt-Enter-N for something I use all the time. Can't they just implement a recent file list on ctrl-tab or something, like the Cmd-tab and the app switcher. Why would I want to grab for the mouse when I'm coding ? Still I have to use it lots in Xcode. Sorry for my rant :)

Geir
-1 because this isn't an answer; it's a rant
Abizern
+1  A: 

From the comments on this blog entry:

Hold down the Option key to get the old file-based Go Forward/Go Back behavior. We rarely change established behavior like this when adding new options, but in this case, the majority of users considered file-level navigation Broken and location-based navigation Correct, based on their experience in browsers and other IDEs. We chose to give what more people considered the “obvious” behavior the pride of place on the keyboard shortcut, but the old way is still there. -- Chris Espinosa

But like you guys have said, after every keyboard edit, the forward file history is lost. This is incredibly frustrating to me, as this is a feature I have heavily relied on for years, which is now broken. Is there still no fix?

Mark J