Navigation: TextEd > Introduction > Tutorials and misc functions >

Code and Word Completion

 

 

 

 

Code completion is available in most programming languages and all data is included in the syntax files. Code completion with project files also include all found classes and functions.

 


Code completion using a symbol


In most programming languages you use a symbol to activate the completion list.


E.g.
 

In HTML we use the (<) less than sign.

 

 

In some languages we use a period (.), space ( ) or (->).


 

Code completion using UserMenu items


In the syntax file there is a section called [UserMenu]. You can invoke a list of all items in this section with the shortkey Ctrl+Space.


E.g.

 

 

As you can see this user menu list is very similar to the symbol invoked completion list. It doesn't have to be though. Also, when you select an item in this list, both the start and end tags are inserted.


 

Code completion in project files


You can use the completions described above with project files as well, but you can also invoke another code completion list not available in other files.


E.g.
 

In this example we use a VB .NET project. We want to access the class members of a object called myBoxEx. So we type "myBoxEx." and add the period at the end to invoke a completion list.
 


 

In the completion list we see the class name in the top dropdown list. All class members are listed below. The buttons can be used as filters, if you have a large amount of class members or if you e.g. just want to see the public class members. Lets say we want to insert the function MoveUp. If you start to type the word "Move", you will see the list content change and only members starting with "Move" will be listed.
 

This list can also be invoked with the shortkey Ctrl+J.
 

E.g.
 

We type "myBoxEx.Move" and press Ctrl+J


 


 

As you can see above only class members starting with "Move" are listed. Select one item by pressing the <Enter> key or using the mouse. If the function have parameters, you will see a parameter tooltip after the function has been inserted into the document.


 

Word Completion


If you set the option "Auto complete words" you will see a list of possible matches in a list every time you start to type something. The possible matches are words taken from the current document.


E.g.


In this example we start by typing a "b". A list of all words starting with the letter "b" will be displayed.
 


 

To insert, select and press <Enter> or use the mouse.

 

 



 

 

 

 

Copyright © 2024 Rickard Johansson