WildEditSmall.gif (1733 bytes)

Tag/API Config Editor

The Tag/API Config Editor, edits HTC files, which are simply a list of functions and/or html tags with their parameters and parameter types.   The functions and tags listed in a HTC file are available for use in WildEdit via the Tag/API Code Editor.

Use this editor to add, edit and delete your own API function calls and HTML tags.  For example, if you have created a wcCode program file that contains function calls that you use often, then you can add those calls to WildEdit using the Tag/API Config Editor. Why?  Your API function calls are then available to you during your code writing sessions.  As you write code and you need to use an API function or HTML tag function, hit the F5 key to invoke the Tag/API Code Editor, which allows you to quickly enter the function parameters, then add the function call to your source code.

The Tag/Api Config Editor allows you to add, delete and change the HTML tags and API functions and subroutines that the Tag/API Code Editor can edit.   Changes are saved to a default file of weTags.htc. Note that when you start WildEdit, it loads the default weTags.htc config file. You can change what HTC file is loaded at startup in the App Setup dialog.  If you are going to make changes to the default htc file, it is a good idea to copy the default htc file, weTags.htc, to another filename and edit the new htc file; also set the new file to be the default at WildEdit startup.

TagTypeEditor.jpg (81294 bytes)

Window Item Action/Explanation
Add button Invokes the Edit Tag Parameters dialog, allowing you to Add a new Tag type to the list. See screen shots of the Edit Tag Parameters dialog below.
Edit button Invokes the Edit Tag Parameters dialog, allowing you to change the selected Tag type and its parameters.   You can also double click an item to edit it.
Delete button Deletes the selected tag from the list.
New List button Creates a new, empty Tag List.
Open button Opens an existing htc (Html Tag Config) file.
Save button Saves the current Html Tag Config list to a htc file.
OK button Accepts the changes and save the current Tag/API Config file.  The current htc file is displayed in the statusbar at the bottom of the window.
Cancel button Cancels all changes and exit the dialog without saving.
Tag column Displays the tag/api type names in the loaded htc file.
API Call column Displays the API Call name associatied with the tag/api type.
Parameters column Displays the Parameters associated with the tag/api type.
End Tag column Displays the end tage associated with the tag/api type.  Note that some HTML tags do not have end tags and API Call tag type also do not have end tags; so for these please make sure you have "<none>" as the end tag.
API Call Name: On selecting a tag in the tag list (by clicking on a tag) the API Call Name will be displayed here is any.
API Call Add button If the selected tag has an API Call associated with it, the you can Add parameters to the API Call using this button.
API Call Edit button Invokes Edit API Parameter dialog for editing  the selected API Call Parameter.  See the Edit API Parameter dialog screen shot below.
API Call Delete button Deletes the selected API Call parameter.
Parameter column Displays the API Call parameter name.  Note give the parameters any name you wish; meaing that the parameter name does not have to match the actual parameter name in the API source code.  The order of the parameters is what is important.
Order column The order of the parameters is VERY important.  The parameters must be in the order in which they are declared in your API header file (.wch).  It does not matter if the parameters are not listed in order. Just make sure that you DO NOT have duplication order numbers.   When you close the window and save the file, then open the Tag/API window again, the parameters will be redisplayed in order.
Type column The parameter type is either a string or a non-string.
Default Value column Parameters can have default values.  This is not the same as the default values of parameters defined in your function or sub declaration.  The default value entered here, is what is entered by default when the API Call is selected in the Tag/Api Code Editor dialog.  If you do not have a default value, then enter "none"

Edit Tag Parameters dialog

EditTag1.jpg (19452 bytes) EditTag2.jpg (18104 bytes)
This dialog shows an example of a Html Tag type of <img>, which has no end tag, but does have an API Call associated with it. This dialog shows an example of an API Tag type of htmHiddenVar.  Note that this tag type does not have any parameters, because it is not an HTML tag.  The API Call parameters are edited using the Edit API Parameter dialog (below).

Edit API Parameter dialog

EditApiParam.jpg (12005 bytes) The Edit API Parameter dialog is invoked when an API parameter is double clicked or when a parameter is selected and the Edit button is clicked.

Each time you add a parameter the Order count is automatically incremented.

Enter the parameter name.  It does not have to match the actual parameter name specified in the API Call's declaration in a .wch or wcc file. The order of the parameters is important, not the names of the parameters.   Make sure you enter the parameter in the same order that you have declare them in your wch or wcc file. For example: if you have a function like:

declare function GetUserById(u as TUser, id as integer) as boolean

then your parameter order should be

1. user
2. id

Choose the parameter type. If the parameter is a string the select string. If it is any other type select Non-String.

Then enter a default value if any.   Strings and Empty string ( "" ) do not have to be enclosed in quote marks, but the can.

NOTE: Default values strings can not contain actual spaces.  To add spaces to a default value string use the space switch ( /[sx], where s means use the space character and x is the number of spaces to insert ).  For example, if I what my default value for the param "src" to be "Ryan Andersen", then I must enter "Ryan/[s1]Andersen" for the Default Value.
We do not use the underscore character ( _ ) as a substitute for space, because it is used quite often in filenames.