Difference between revisions of "OtfDeclarationExplorer"

From emotive
Jump to navigation Jump to search
 
Line 3: Line 3:
 
==Overview==
 
==Overview==
 
{|
 
{|
| style="vertical-align:top;"|
+
| style="vertical-align:top; text-align:justify;"|
The '''Declaration Explorer''' is a efficient tool window for doing all tasks related to the declarations such as adding, editing, inputting ect. In the Declaration Explorer, all the local declarations (including the parameters) of the current procedure and all the global declarations (including the validities) of the current document are listed in the ascending order or in groups according to the declaration types. You can change the way of listing declarations by clicking on the "Group" button, see the image below.  
+
The '''Declaration Explorer''' is a efficient tool window for doing all tasks related to the declarations such as adding, editing, inputting ect. In the Declaration Explorer, all the local declarations (including the parameters) of the current procedure and all the global declarations (including the validities) of the current document are listed in the ascending order or in groups according to the declaration types. You can change the way of listing declarations by clicking on the "'''Group'''" button.  
  
 
Each declaration is displayed with the detailed information such as name, type, visibility, specification and initial value. When you set the mouse over a declaration for a while, you can see this information clearer with the pop-up tooltip.  
 
Each declaration is displayed with the detailed information such as name, type, visibility, specification and initial value. When you set the mouse over a declaration for a while, you can see this information clearer with the pop-up tooltip.  
  
As a tool window, the Declaration Explorer can be docked, floating, opened, closed, resized or set to auto hide. When starting the OTF the first time, the Declaration Explorer is already opened and docked under the [[OtfSolutionExplorer|Solution Explorer]]. You can open or close this editor via the "Declaration Explorer" button in the [[OtfMenuBar|Ribbon]], see the image below.  
+
As a tool window, the Declaration Explorer can be docked, floating, opened, closed, resized or set to auto hide. When starting the OTF the first time, the Declaration Explorer is already opened and docked under the [[OtfSolutionExplorer|Solution Explorer]]. You can open or close this editor via the "'''Declaration Explorer'''" button ("[[File:DeclarationWindow.png]]") in the [[OtfMenuBar|Ribbon]].  
  
 
The features and functions of the Declaration Explorer are described in the following sections.
 
The features and functions of the Declaration Explorer are described in the following sections.
  
| style="width:10px;" |
+
| style="width:30px;" |
| style="vertical-align:top;"| {{ImageStyleCenter|DeclarationExplorer.png||Declaration Explorer allows for doing tasks with declaration efficiently}}
+
| style="vertical-align:top;"| {{ImageStyleCenter|DeclarationExplorer.png|350|Declaration Explorer allows for performing tasks on declarations efficiently}}
 
|}
 
|}
  
Line 70: Line 70:
 
|3.1  
 
|3.1  
 
| style="width:3px;" |
 
| style="width:3px;" |
| If the declaration is a constant (or a context variable, or an in-parameter), a new Assignment is created at the current position with the declaration already input to the "Term" property.
+
| If the declaration is a constant (or a context variable, or an in-parameter), a new Assignment is created at the current position with the declaration already input to the "'''Term'''" property.
 
|- style="vertical-align:top;"
 
|- style="vertical-align:top;"
 
|3.2  
 
|3.2  
 
| style="width:3px;" |
 
| style="width:3px;" |
| If the declaration is a variable (or out- / inout-parameter), a new Assignment is created at the current position with the declaration already input to the "Result" property.
+
| If the declaration is a variable (or out- / inout-parameter), a new Assignment is created at the current position with the declaration already input to the "'''Result'''" property.
 
|}</li>
 
|}</li>
 
</ol>
 
</ol>
  
 
{{Note|You can not add a new Assignment by dragging and dropping of a '''validity''' from the Declaration Explorer.}}
 
{{Note|You can not add a new Assignment by dragging and dropping of a '''validity''' from the Declaration Explorer.}}

Latest revision as of 10:06, 15 September 2014


Overview

The Declaration Explorer is a efficient tool window for doing all tasks related to the declarations such as adding, editing, inputting ect. In the Declaration Explorer, all the local declarations (including the parameters) of the current procedure and all the global declarations (including the validities) of the current document are listed in the ascending order or in groups according to the declaration types. You can change the way of listing declarations by clicking on the "Group" button.

Each declaration is displayed with the detailed information such as name, type, visibility, specification and initial value. When you set the mouse over a declaration for a while, you can see this information clearer with the pop-up tooltip.

As a tool window, the Declaration Explorer can be docked, floating, opened, closed, resized or set to auto hide. When starting the OTF the first time, the Declaration Explorer is already opened and docked under the Solution Explorer. You can open or close this editor via the "Declaration Explorer" button ("DeclarationWindow.png") in the Ribbon.

The features and functions of the Declaration Explorer are described in the following sections.

DeclarationExplorer.png
Declaration Explorer allows for performing tasks on declarations efficiently

Features and functions

Adding a new declaration

To add a new declaration via the Declaration Explorer, please proceed as follows:

  1. Click on the drop-down button on the right of the add new declaration button.
  2. Select the type of declaration that you want to create.
  3. Click on the add new declaration button.
  4. When the setting dialog box of the new declaration occurs, complete the setting for the new declaration.
  5. Click OK button to add the new declaration.
  6. Now the new declaration appears in the Declaration Explorer to use.
  7. If you want to add another declaration of the same type, just click on the add new declaration button; otherwise, click on the drop-down button to select another declaration type.

Editing a declaration

To edit a declaration via the Declaration Explorer, please proceed as follows:

  1. Double-click on a declaration in the Declaration Explorer.
  2. The setting dialog box of the declaration occurs
  3. Changes the setting of the declaration as you desire.
  4. Click OK button to apply the changes.

Inputting a declaration to an activity

To input a declaration to an activity via the Declaration Explorer, please proceed as follows:

  1. Find the corresponding declaration in the Declaration Explorer.
  2. Drag the declaration from the Declaration Explorer and drop on the corresponding activity in the designer.
  3. There may be 3 cases:
    3.1 If the activity does not have any property with the similar type with the declaration, nothing happens.
    3.2 If the activity has only one property with the similar type with the declaration, the declaration is automatically input to the corresponding property.
    3.3 If the activity has many properties with the similar type with the declaration, a context menu appears listing all the corresponding properties (if the declaration has the same name with one of the property, that property is displayed on top with a separate line). Select one of the propety, and the declaration is input to the selected property.

Adding a new Assignment activity with an input declaration

To add a new Assignment activity with an input declaration via the Declaration Explorer, please proceed as follows:

  1. Find the corresponding declaration in the Declaration Explorer.
  2. Drag the declaration from the Declaration Explorer and drop on a flow connector (on a green plus) in the designer.
  3. There may be 2 cases:
    3.1 If the declaration is a constant (or a context variable, or an in-parameter), a new Assignment is created at the current position with the declaration already input to the "Term" property.
    3.2 If the declaration is a variable (or out- / inout-parameter), a new Assignment is created at the current position with the declaration already input to the "Result" property.
Icons Note.png You can not add a new Assignment by dragging and dropping of a validity from the Declaration Explorer.