As you type in the command line, a scrollable list of suggestions displays above the command line.
Each suggestion has an icon with a letter and color-coding to indicate the type of suggestion. A letter in a square icon describes the type of the member in the suggestion list. A letter in a circle icon describes the nature of the return type.
Listed alphabetically are types of members, which are shown in square icons:
E = Enumeration
M = Method
N = Namespace
P = Property
S = Snippet
T = Type
V = Variable
– = Unidentified member (generally a Python type that cannot be extracted)
Once a member is selected, the nature of the return types available for this member are shown in circle icons. Listed alphabetically are return types:
C = Class
E = Enumeration
F = Field
I = Interface
S = Structure
Note: No icon displays for primitive types (such as integer, Boolean, or string) or if no suggestion is returned.
When you place the mouse cursor over any property or method in the list of
suggestions, the tooltip displays information about this item. The following image
shows the tooltip for the property Models
, which is available
when using the console with a project model associated with Ansys Mechanical.
Tooltips use color-coding to indicate the syntax:
green = accessibility
purple = type
orange = warning
blue = arguments
General formatting follows for properties and methods.
- Properties:
get/set mode: ReturnType PropertyName
Description of the property.
Returns: Description of what is returned (if any)
Remarks: Additional information (if any)
Example: Sample entry (if any)
- Methods:
ReturnType MethodName (ArgumentType ArgumentName)
Description of the method
ArgumentName
: Description of the argumentReturns: Description of what is returned (if any)
Remarks: Additional information (if any)
Example: Sample entry (if any)
Tooltips can also provide:
Scope variables (accessed by pressing Ctrl + space when no defined symbol appears under the text cursor).
.NET properties where applicable.
Warning messages when special attention is needed.
Prototype information for methods when cursor is inside brackets and indexers when cursor is inside square brackets.
Overloaded methods, including the following details:
Number of overloaded methods.
Prototypes for overloaded methods (accessed by pressing the arrows in the prototype tooltip).
Members for overloaded methods. (The tooltip for an overloaded method is a list of all members from all overloaded methods.)
The following images show examples of two different tooltips for the method
Equals
in two different stages of using autocompletion.
You can use the following key combinations to interact with autocompletion suggestions:
Key Combination | Action |
---|---|
Ctrl + space |
Open the suggestion tooltip |
Esc |
Close the suggestion tooltip |
Enter |
Apply the suggestion |
space or symbol Supported symbols:
|
Apply the suggestion followed by the space or symbol |
For available keyboard shortcuts, see Using Console Keyboard Shortcuts.