7.2.  Common Interaction Patterns

The following interaction patterns (called gestures) are common across the Sonargraph application:

  • Single clicking on an element normally means to select it; holding the control key (command key on Mac) while clicking normally aggregates the selection elements, and holding the SHIFT key normally selects all elements between the current one and the last selected one.

  • Double clicking not only selects the element but, if possible, shows it in a view that is best suited to inspect it or edit it. It is important to note that a double click gesture will show the selected element in another view only if at least one of the following two conditions is fulfilled:

    • Element is associated with a single source file: Elements like C/C++, Java and C# source files, types, structs, methods, and functions among others fulfill this conditions. For other elements like namespaces, packages or directories it is not possible to associate them with a single source file.

    • There is a single possibility of navigation: If the selected element only offers one view to navigate to, then the double-click gesture will show the element in that view, otherwise, it will not meet this condition.

  • Right clicking on elements normally presents a context menu with element-specific actions. Some of the most common interaction patterns available with right-click are showing elements in different views, exporting tables to Excel and exporting graphics as images to the file system among others.

  • Drag and drop is used in several different contexts in Sonargraph to perform different operations: filters can be re-organized in the Workspace view. Nodes can be re-arranged for better appreciation in the Graph and Cycle views while holding the SHIFT key pressed. Dragging and dropping the mouse cursor while holding the SHIFT key and the primary modifier key of the platform (CTRL on Windows/Linux and CMD on Mac) pressed in the Workspace Dependencies view allows to specify a new dependency between two nodes (see Section 7.7.2, “ Managing Module Dependencies ”).