20.4 Using Code Structure View
The
Code Structure View tool displays a structure of the code in a tree-like form adjacent to the SQL Editor (Fig.
20.16).
The Code Structure View shows references to most important SQL commands in the code entered in target Editor. The references are grouped together by procedures, loops and conditional statements and intended to represent their level in the code structure. The references make it easy to move quickly through code.
You can invoke the Code Structure View using Ctrl+F12 hot key. Code Structure View can be also invoked using SQL Editor's popup menu.
The view displays the current SQL commands, such as CREATE, DROP, EXECUTE, SELECT, INSERT, DELETE, UPDATE, GRANT and REVOKE. For CREATE PROCEDURE and CREATE FUNCTION, a plus sign is displayed next to the command. You can use that plus sign to expand the CREATE command and display nested member SQL commands.
Figure 20.16:
The Code Structure View.
|
|
Tips:
- For CREATE PROCEDURE and CREATE FUNCTION commands, a plus sign is displayed next to the command. You can use that plus sign to expand the CREATE command and display the nested SQL commands which are part of the expanded procedure or function.
- A plus sign is also displayed for various loop structures such as FOR loops, WHILE, UNTIL and
generic LOOP loops and for conditional IF statements. Just like for CREATE commands you can click the plus sign to expand the nested SQL commands.
- Different icons and colors are used for different types of SQL statements in order to improve
visual appearance of the code structure and to allow users to locate the required SQL commands faster.
20.4.1 Code Navigation
You can immediately navigate to any command in the SQL Editor by clicking it in the Code Structure View or by pressing the Enter key while the command is selected in the view. The SQL Editor window will be scrolled as needed to make the selected SQL command visible on the screen and the caret will be set to the beginning of that command line.
Another helpful feature of the Code Structure View is dynamic code highlighting. When you move mouse pointer over commands displayed in the Code Structure View, SQL Assistant
TM automatically highlights them in the target editor if these commands are available in the visible frame of the target editor window.
20.4.2 Expanding / Collapsing Multiple Levels
The Code Structure View supports right-click context menu, which can be used to quickly expand or
collapse all levels or certain levels only. Commands are available expand/collapse up to 4 levels or all levels at once.
20.4.3 Scrolling
To scroll the Code Structure View window contents, using the mouse drag window scrollbar handles as needed. See Fig.
20.16 for information on where to locate the scrollbar handles.
20.4.4 Resizing Contents
To resize the Code Structure View window, drag the resizer handle in the bottom-right corner of the window. See Fig.
20.16 for information on where to locate the resizer handle.
Copyright © 2007 - 2009 HoneySoftware - All Rights Reserved
Submit feedback on this topic.