mirror of
https://github.com/EiffelSoftware/eiffel-org.git
synced 2025-12-08 07:42:33 +01:00
Author:halw
Date:2009-08-04T15:02:16.000000Z git-svn-id: https://svn.eiffel.com/eiffel-org/trunk@274 abb3cda0-5349-4a8f-a601-0c33ac3a8c38
This commit is contained in:
@@ -18,15 +18,20 @@ Class name auto-completion is most commonly used in the Editor Pane. But the sam
|
||||
* The "Entry:" text box on the New Class tool.
|
||||
* Expressions in the editable grid of the Watch tool
|
||||
* "Class name:" in the New Expression dialog of the Watch tool.
|
||||
* "Condition" in the Breakpoints dialog
|
||||
* "Edit Contract" in the Contract tool
|
||||
* "Add New Contract" in the Contract tool
|
||||
<br/>
|
||||
|
||||
==The class auto-completion window==
|
||||
Using the example above, when auto-completion is triggered, the class auto-completion window will pop up and display the list of class names which begin with the string `<code>LI</code>'. So, you can imaging the auto-completion as a search for class names using the characters you type followed by a wild card character, the asterisk (`*'). Of course, you don't have to put the asterisk at the end, it's always there by implication. Once you've triggered the auto-completion, you can however use the wild card character in the middle of a string, like this:
|
||||
Using the example above, when auto-completion is triggered, the class auto-completion window will pop up and display the list of class names which begin with the string "<code>LI</code>". So, you can think of the auto-completion as a search for class names using the characters you type followed by a wild card character, the asterisk ('*'). Of course, you don't have to put the asterisk at the end, it's always there by implication. Once you've triggered the auto-completion, you can however use the wild card character in the middle of a string, like this:
|
||||
<code>
|
||||
a_variable_name: LI*R
|
||||
</code>
|
||||
which would list all class names starting with `<code>LI</code>' and containing the character `<code>R</code>' appearing at some point after the `<code>LI</code>'.
|
||||
which would list all class names starting with "<code>LI</code>" and containing the character '<code>R</code>' appearing at some point after the "<code>LI</code>".
|
||||
|
||||
|
||||
{{note|Using the wild card character with auto-completion is valid only '''after''' auto-completion is triggered.}}
|
||||
|
||||
|
||||
When the list appears, the first list item will be selected. You can select a class name from the list by double-clicking a name in the list or by using the keyboard <code>Up</code> and <code>Down</code> buttons to navigate the list, then pressing <code>Enter</code> to select a highlighted class name. The auto-completion window can be cancelled by clicking outside the window or pressing <code>Esc</code>.
|
||||
|
||||
|
||||
@@ -3,26 +3,44 @@
|
||||
[[Property:uuid|40ae30a6-c033-dae7-8dae-2569e7ba0adc]]
|
||||
==Overview==
|
||||
|
||||
EiffelStudio editor will complete feature calls automatically.
|
||||
EiffelStudio editor provides automatic help for completing feature calls.
|
||||
|
||||
This means, for example, that when the user types:
|
||||
This means, for example, that in the Editor pane when you type:
|
||||
<code>
|
||||
an_string.a</code>
|
||||
and then triggers feature call auto-completion, one of two things will happen:
|
||||
and then trigger feature call auto-completion, one of two things will happen:
|
||||
# If there is only one available feature name that begins with "<code>a</code>", then a template for a call to that feature will be inserted into the code.
|
||||
# If more than one such feature name exists, the editor will propose a list of possible valid feature names from which to choose, as seen in Figure 1.
|
||||
|
||||
Feature call auto-completion can be triggered by pressing <code>crtl+space</code> or by following the edit menu path:
|
||||
Feature call auto-completion can be triggered:
|
||||
|
||||
<code>
|
||||
# Automatically as soon as you type a dot ('.') after a feature name
|
||||
# By pressing <code>crtl+space</code>
|
||||
# By following the edit menu path:
|
||||
|
||||
<code lang="text">
|
||||
Edit --> Advanced --> Complete word
|
||||
</code>
|
||||
|
||||
|
||||
Feature call auto-completion is most commonly used in the Editor pane. But the same functionality is also available elsewhere in EiffelStudio, for example:
|
||||
|
||||
* Expressions in the editable grid of the Watch tool.
|
||||
* "Expression" in the New Expression dialog of the Watch tool.
|
||||
* "Condition" in the Breakpoints dialog
|
||||
|
||||
|
||||
==The feature call auto-completion window==
|
||||
|
||||
Using the example above, when auto-completion is triggered, the feature call auto-completion window will pop up and display a list of feature names which begin with the string "<code>a</code>". So, you can think of the auto-completion as a search for feature names using the characters you
|
||||
|
||||
|
||||
[[Image:editor feature auto-completion window]]
|
||||
|
||||
Figure 1. The feature auto-completion window.
|
||||
|
||||
To trigger the auto complete, press the key combination "Ctrl+Space" or click on '''Complete word''' in the '''Advanced''' sub-menu of the [[Edit menu commands|menu]] . If automatic completion is possible, there are two cases : if only one name matches, this name will be inserted in the editor. If there are no matching names or several ones a window will appear. This window will contain a text field and a list. The text field will be filled with the beginning of the feature name that was entered. The first item in the list, if any, will be selected. <br/>
|
||||
|
||||
This window will contain a text field and a list. The text field will be filled with the beginning of the feature name that was entered. The first item in the list, if any, will be selected. <br/>
|
||||
To complete your code with the selected item, press "Enter" or "Ctrl+Space". <br/>
|
||||
To choose another item, use keyboard Up and Down arrows or the mouse. You can also modify the content of the text field. The list will be updated automatically. To validate your choice, press "Enter" or "Ctrl+Space". If there is no selected item, the content of the text field will be inserted. <br/>
|
||||
To cancel the auto-complete, press "Esc" at any time.
|
||||
|
||||
Reference in New Issue
Block a user