Next: , Previous: The Shell and Python Windows, Up: Description of the Main Windows


2.16 The Locations View

The Location Tree is filled whenever GPS needs to display a list of locations in the source files (typically, when performing a global search, compilation results, and so on).

locations-view.jpg

The Locations View shows a hierarchy of categories, which contain files, which contain locations. Clicking on a location item will bring up a file editor at the requested place. Right-clicking on file or category items brings up a contextual menu allowing you to remove the corresponding node from the view. Placing the mouse over an item automatically pop up a tooltip window with full text of the item if this text can't be completely shown in the window.

Every time a new category is created, as a result of a compilation or a search operation for example, the first entry of that category is automatically selected, and the corresponding editor opened. This behavior can be controlled through a preference Jump To First Location.

Closing the Locations view will remove from the editors locations that are also visible in the Locations view. If the Locations View is present when exiting GPS and the desktop is saved, the locations will be saved as part of the desktop for the current project, and will be loaded the next time GPS is started on the same project.

To navigate through the next and previous location (also called Tag), you can use the menu items Navigate->Previous Tag and Navigate->Next Tag, or the corresponding key bindings.

Left-clicking on a line in the Location Tree brings up a contextual menu with the following entries:

Filter panel
Controls availability of the filter panel at the bottom of the window.
Sort by subcategory
Toggle the sorting of the entries by sub-categories. This is useful, for example, for separating the warnings from the errors in the build results.
Expand category
Expand all the files in the current categories.
Collapse all
Collapse all the categories in the Locations View
Remove category/file/message
Remove the selected category, file or message from the Locations View. Selected message can be removed using Locations view->Remove message key binding also.
Export messages into text file
Export all messages of the selected category/file into text file.
Jump to location
Open the location contained in the message, if any.
Clear Locations View
Remove all entries from the Locations View.

In some cases, a wrench icon will be associated on the left of a compilation message. See Code Fixing for more information on how to make advantage of this icon.

The filter panel can be used to filter messages which match (or do not match) a text pattern or regular expression. As soon as you type in the text entry, the filter is enabled. If you clear the text, the filter is disabled. The Close button on the filter panel hides it and cancels the filter. The Regexp check button specifies how to use the filter text entry: as plain text or regular expression. The Hide matched check button reverts the filter, e.g. switch between matching and non-matching items.