Perspectives

Index of All Documentation » Wing Pro Reference Manual » Customization »


Wing Pro and Wing Personal allow you to create and switch between particular arrangements of the IDE's tools. This allows adjusting the user interface for particular kinds of work, such as editing, testing, debugging, working on documentation, and so forth.

These subsets, or perspectives, are named and then accessed from the Tools menu, which provides a sub-menu for switching between them. The current perspective's name is shown in [] brackets in the lower left of Wing's window.

Perspective Manager

Manage Perspectives in the Tools menu displays the Perspective Manager. This dialog shows the name of each perspective, whether or not the perspective is shared by all projects, whether or not the perspective is auto-saved, the perspective style, and the key binding (if any) that is assigned to it.

The name of a perspective can be changed by clicking on the name within the list and editing it in place.

When perspectives are shared, they are stored in the shared perspectives file, which is configured with the User Interface > Perspectives > Shared Perspective File preference, instead of in the project file. This makes the shared perspectives available to all projects, or potentially to multiple users. When multiple instances of Wing share this file, Wing will watch for changes and auto-reload the set of perspectives into each instance of Wing, as another instance makes changes. Note that when a shared perspective is un-shared, it is moved into the project currently open in the instance of Wing that un-shared it.

The perspective style can be used to control how much state is stored in the perspective: By default Wing stores only the overall layout of the GUI and set of tools present. Setting this to "Tools and Editors" will cause the perspective to control also which editors are open. Setting it to "All Visual State" will store also the detailed state of the tools and editors, including scroll position, selection, search strings, tree expansion states, and so forth.

When a key binding is defined, that key sequence will cause Wing to switch to the associated perspective.

Perspective Manager Context Menu

The Perspective Manager provides the following functionality in its context (right-click) menu:

  • New creates a new untitled perspective with the current state of the application.
  • Duplicate makes a copy of the selected perspective, including its stored application state.
  • Delete removes the selected perspective.
  • Set Key Binding displays a dialog to set a key binding that will cause Wing to switch to that perspective.
  • Update with Current State replaces the stored state for the selected perspective with the current application state.
  • Restore Saved State loads the state stored in the selected perspective without making that perspective current.

Preferences

The Perspective Manager's Configure button displays the preferences that control how perspectives work. These include:

  • User Interface > Perspectives > Auto-save Perspectives -- Selects when the current GUI state should be auto-saved into a perspective before switching to another perspective. Always will always auto-save all perspectives, Never disables auto-save entirely, Prompt causes Wing to prompt each time when leaving a perspective, and Configured by Perspective allows the behavior to be controlled for each perspective, in the Manage Perspectives dialog. The default is Always so that the last application state is always restored when returning to the perspective. Disabling auto-save can be useful for perspectives that should always start with a previously stored fixed state.
  • User Interface > Perspectives > Shared Perspective File -- This is used to specify where shared perspectives are stored on disk. The default is a file perspectives in the Settings Directory.

Auto-Perspectives

Auto-perspectives can be used to automatically switch between the built-in perspectives edit and debug when debugging is started and stopped. When this is enabled, Wing will show fewer tools when editing and most of the debugging tools only while debugging. If the user alters which tools are shown from the defaults, this will be remembered the next time debug is started or stopped.

Auto-perspectives are off by default and can be turned on with the Automatic Perspectives attribute under the Debug tab in Project Properties.

Once this is enabled, Wing will save the unnamed pre-existing perspective as user and will display the appropriate perspective edit or debug with its default tool set. Note that the perspectives edit and debug are not created until the first time debugging is started. After that, they appear in the Goto Perspective sub-menu in the Tools menu and in the perspective manager.

Restoring the Default Toolset

In Wing Pro, the Tools menu item Restore Default Toolset will restore the tools appropriate for the current perspective. The state that is restored will differ for edit, debug, and other perspectives.