TaskLauncherTextField DTD and XML definitions
The TaskLauncherTextField has the same attributes as a TextField,
with the additions of prefix and suffix attributes. The TaskLauncherTextField
has the following entry in the DTD file:
Table 1. TaskLauncherTextField definitionLine entry in the DTD file |
Description |
<!ELEMENT TaskLauncherTextField EMPTY> |
A TaskLauncherTextField does not contain any sub-elements |
<!ATTLIST TaskLauncherTextField
name CDATA #IMPLIED
width CDATA "32"
height CDATA "22"
x CDATA #REQUIRED
y CDATA #REQUIRED
focusTraversable (true|false) #IMPLIED
errorMessageOnInstantiateOperation CDATA "OperationerrorMessage"
delimChar CDATA #IMPLIED
horizontalAlignment CDATA "0"
hotKey CDATA #IMPLIED
onInitialize CDATA #IMPLIED
prefix CDATA #IMPLIED
suffix CDATA #IMPLIED
text CDATA #IMPLIED>
|
Attribute list |
Table 2. TaskLauncherTextField attributesAttribute |
Description |
name |
Name used by the Desktop to identify this component. Applications can
have access to this object at runtime by requesting it by name from the Desktop. |
width |
Width of the text field |
height |
Height of the text field |
x |
Horizontal coordinate for the location of the text field (mandatory) |
y |
Vertical coordinate for the location of the text field (mandatory) |
focusTraversable |
Whether the TaskLauncherTextField will be able to get focus |
ErrorMessageOn InstantiateOperation |
Text that displays if an error occurs when the task is launched |
delimChar |
Character that separates the task code or taskName from a list of parameters
entered by the end user. For example, if "#" is the delimChar and the text
entered in the TaskLauncherTextField is "TX01#15/11/1999, 12-0123-23456758,
1200", the task "TX01" is launched, and the remaining characters of the string
are handled as the parameters attribute in a TaskLauncher. |
horizontal Alignment |
Horizontal alignment of the text field. Following are the possible
values: - "0" for center alignment
- "2" for left alignment
- "4"for right alignment
|
hotKey |
Combination of keys used as a hot key for the text field. Pressing
this combination of keys when the text field is visible on the Desktop is
equivalent to clicking on the text field (which causes it to get focus). |
onInitialize |
Java™ code to be executed when the component is initialized |
prefix |
String prefixed to the code that the user enters in the field. If no
TaskInfo is found that matches the code, the prefix is concatenated with the
code and the search is done again. |
suffix |
String appended to the code that the user enters in the field. If no
TaskInfo is found that matches the code, the suffix is concatenated with the
code and the search is done again. |
text |
String to be inserted in the text field |
The following is an example of an XML definition for a TaskLauncherTextField:
<TaskLauncherTextField name="OperationsLauncher"
width="370" height="19" x="10" y="5"
onInitialize="this.setForeground(new java.awt.Color(255,255,255))"
/>