204
Building a tag editor
Defining a tag editor is requires the following three tasks:
1
2
3
Open the \Extensions\TagDefs\mytag.vtm file to see how these tasks are coded.
Defining controls
The
identical in definition, the difference being that only
capability to contain
A Panel control is a good example of a control that can be a container containing a
control, such as a label or a text box:
<tag>
</tag>
You can name the above template mytag.vtm and test it by attempting to edit an
empty
The example displays a single Panel container containing
controls. Only the following controls can be containers:
• TabDialog
• TabPage
• Panel
The control represented by a
attribute; the
The
is positioned. The anchor can be specified as the name of any control that was
already laid down. The corner specifies the corner of the anchor control to be used
for positioning. The possible values are
attributes then specify the pixel offset from the
Layout the dialog box controls.
Specify how to populate the controls with tag attributes.
Define the tag generation template.
and
control
container
control
<editorlayout height=50 width=200>
<container
name="Panel1" type="Panel" width=150 height=50>
<control name="lblCode" type="Label" caption="Code" down=20
right=20 width=70/>
<control name="txtCode" type="TextBox" anchor="lblCode"
<corner="NE" width="30"/>
</container>
</editorlayout>
tag.
mytag
A tab dialog control capable of containing
controls.
Only used inside a
A general purpose panel container control which can contain any
regular or container controls.
and
width
and
anchor
corner
Chapter 14 Customizing the Development Environment
tags represent graphical controls. The tags are nearly
tags.
TabDialog
or a
control
container
attributes determine the size.
height
attributes determine the point relative to which the control
,
NE
NW
tags have the
container
and
Label
TabPage
container control.
tag is defined by the
,
, and
. The
SE
SW
down
control.
anchor
TextBox
container
type
and
right