2.15. Creating a Bookmark

Problem

You want to come back to a location in a file at a later time.

Solution

Create a bookmark by right-clicking the marker bar in an editor and specifying a name for the bookmark in the New Bookmark dialog.

Discussion

You’re editing code, and suddenly it’s quitting time. How can you save your place? Create a bookmark, and come back to it later by double-clicking that bookmark in the Bookmarks view. You create the bookmark by right-clicking the marker bar and naming the bookmark in the New Bookmark dialog. The bookmark will appear in the marker bar, as shown in Figure 2-14.

Using a bookmark

Figure 2-14. Using a bookmark

When you want to come back to the bookmarked location later, just open the Bookmarks view by selecting Window Show View Other Basics Bookmarks. You can see the bookmark we created in the Bookmarks view at the bottom of Figure 2-14; double-clicking it opens the bookmarked line in an editor.

As you’d expect, bookmarks work even if the file with the bookmark is closed; when you double-click the bookmark, that file opens automatically.

Get Eclipse Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.