Navigation: TextEd > Syntax files >

Tag Auto Completion

 

 

 

When typing a tag (<) or a space inside a tag you can present the user with a list of tags or attributes. Also when typing a stop tag (</) the user can be presented with a list of stop tags.

1.Enter all the tags and stop tags.

2.For each tag enter the attributes that is available for this tag.

3.Select icon for the attribute.

4.Select the text that should be inserted for the attribute. If nothing is entered the attribute name will be inserted.
 

When typing ( < ) in the editor all the tags are listed in a listbox. If the user then enters a ( / ) the listbox changes and all stop tags are listed. When hitting the space bar inside a valid tag a list with attribute for that tag is shown in a listbox.

 

When a tag is selected in a listbox only the tag name is inserted.

When a stop tag is selected the stop tag name and a ( > ) character is inserted. E.g. when typing </ and the user selects applet applet> is inserted resulting in </applet>.

When an attribute is selected you can decide what should be inserted.


Variables can be used to simplify the editing.
 

Instead of a tag name, enter a variable name like @base. Add attributes to the variable, just like you did above. You can now use the variable name as a attribute variable of another tag and save you the trouble of typing all the attributes again. You can even use a variable within a variable.
 

E.g.
 

Create a variable named @base and add some attributes.
 

@base
 

class

onclick

title
 

Now we create a new tag called myTag. It should contain the attributes "class, onclick and title" plus a few more. We can now write:
 

myTag
 

@base

lang

onmousemove

 

 

 

 

 

 

 

 

Copyright © 2022 Rickard Johansson