Navigate Backward and Navigate Forward

Tips Search

If you like the tips then you'll love the book!

Order your copy today:
http://www.amazon.com/gp/product/0735649928

Navigate Backward and Navigate Forward

  • Comments 3

Keyboard:  CTRL + -; CTRL + SHIFT + - 
Menu:  View -> Navigate Backward; View -> Navigate Forward
Command:  View.NavigateBackward; View.NavigateForward
Versions:  2008,2010
Published:  3/1/2010
Code:  vstipEdit0024

 

image

 

The editor remembers locations when you move in a single command more than several lines away from where you are currently working, or if you edit in a particular location that is not adjacent to the last place you edited.

 

The goal is to remember interesting locations so that you can recall where you have been working without remembering so many locations the feature is not useful (such as every character typed, or every line entering several new lines of code one right after the other).

 

A go-back marker is dropped under the following conditions:

  • An incremental search (including reverse) leaves a go-back marker at the beginning of the search and another one at the end.

  • A Go To Line action, like CTRL + G, or a mouse-click that moves the cursor 11 lines or more from the current position drops a go-back marker at the new location.

  • A destructive action (like hitting Backspace) after having moved the cursor to a new location drops a go-back marker.

  • Doing a search, like Ctrl+F, drops a go-back marker at the found location.

  • Opening a file drops a go-back marker wherever the cursor was on the old file and drops another on the opened file.

 

So with all that, welcome back to the wonderful world of the Navigate buttons (and keyboard shortcuts, too)!  These gems make travelling around your code much, much easier:

image

  • Thank you, now I understand the logic behind the navigate Forward/backward better.

  • Why don't you leave a go-back marker when a file is closed  also? the same way you do when you open a file

    (Opening a file drops a go-back marker wherever the cursor was on the old file and drops another on the opened file.)

    That way someone could hit CTRL + (-) and open the file in the exact position he was when he closed it.

    Is there a way to do this manually.

  • Andreas,

    Sadly all the go back markers in a file are removed when the file is closed so this isn't possible by any means I know of.

    Z

Page 1 of 1 (3 items)
Leave a Comment
  • Please add 3 and 3 and type the answer here:
  • Post