Provides an overview of the namespace for the control description.
This chapter provides a discussion of an overview of the namespace for the control description, and its elements and attributes.
Provides an overview of the namespace for the control description.
A namespace used to describe user interface control used in XML documents in xfy technology user agent.
The namespace's URI reference of the control description is http://xmlns.xfytec.com/controls. In the following discussion, use the namespace prefix "ctrl:" in order to describe the elements of the control description.
Also, we use the following namespaces and their prefixes in the descriptions below.
xvcd: as the namespace prefix. For more information, see the VC Core Reference.
instruction: as the namespace prefix. For more information, see the Platform Command Instruction Reference.
event: as the namespace prefix. For more information, see the Platform Event Reference.
This section provides a discussion about elements, attributes, and events defined in the namespace for the control description.
Explains elements used to describe user interface control and behavior settings of user interface control.
Elements and attributes used to describe user interface control in control description's namespace are as follows:.
ctrl:input ElementCreates a control to input value. The following controls can be created by specifying a value for type attribute.
The date format to be input in a date input control is CCYY-MM-DD. (CC: first two digits of a year, YY: last two digits of a year, MM: month, DD: day)
type
Describes control type to create in order to create controls other than text field. This can be specified with one of the following strings.
boolean
date
Creates a text field, if omitted.
style
Describes the style sheet applied to the control. Describe a style sheet with CSS.
If omitted, no style sheet to apply is assumed.
ref
Describes a node of source XML document in XPath expression which reflects a value set in control.
If omitted, the node which reflects a value set in control is not assumed to exist.
relevant
Sets whether control is valid or not. It can be an XPath expression. A control is determined whether it is valid or not by evaluating its described XPath expression as true or false value.
true,
false,
If omitted, true() is assumed to be set.
readonly
Sets whether a control is reference only or not. It can be an XPath expression. A control is determined whether it is reference only or not by evaluating its described XPath expression as true or false value.
true,
false,
If omitted, false() is assumed to be set.
design-mode
Sets whether it uses design-mode or not. It can be a true/false value.
true
false
If omitted, false is assumed to be set.
maxlength
Sets maximum length of input string. This can be an integer value greater than 1. If a control other than text field is created according to type attribute, it becomes invalid.
If omitted, string length to input is not restricted.
text-filler
Sets string to display instead, if display string data does not exist. If a control other than text field is created according to type attribute, it becomes invalid.
If omitted, null string is assumed to be specified.
inputmode
Sets the IME input mode. This can be described in one of the following strings.
hiragana
katakana
katakana halfWidth
latin fullWidth
off
If a control other than text field is created according to type attribute, it becomes invalid. For IME input mode setting, see IME Control.
If omitted, IME control will not be performed.
dispatch-value-changed-event
Specifies when ctrl:value-changed event is issued. This can be described in one of the following strings.
text-committed
text-edited
If a control other than text field is created according to type attribute, it becomes invalid.
If omitted, text-committed is assumed to be set.
The ctrl:input element can contain the following elements.
ctrl:label Element
type attribute to boolean, be sure to specify one element.xvcd:action Element
ctrl:secret ElementCreates a string input control to display * instead of input text. Use to keep input string such as password from being read.
style
Describes the style sheet applied to the control. Describe a style sheet with CSS.
If omitted, no style sheet to apply is assumed.
ref
Describes a node of source XML document in XPath expression which reflects a value set in control.
If omitted, the node which reflects a value set in control is not assumed to exist.
relevant
Sets whether control is valid or not. It can be an XPath expression. A control is determined whether it is valid or not by evaluating its described XPath expression as true or false value.
true,
false,
If omitted, true() is assumed to be set.
readonly
Sets whether a control is reference only or not. It can be an XPath expression. A control is determined whether it is reference only or not by evaluating its described XPath expression as true or false value.
true,
false,
If omitted, false() is assumed to be set.
design-mode
Sets whether it uses design-mode or not. It can be a true/false value.
true
false
If omitted, false is assumed to be set.
maxlength
Sets maximum length of input string. This can be an integer value greater than 1.
If omitted, string length to input is not restricted.
The ctrl:secret element can contain the following elements.
ctrl:label Element
xvcd:action Element
ctrl:textarea ElementCreates multi-line string control to insert a line break.
style
Describes the style sheet applied to the control. Describe a style sheet with CSS.
If omitted, no style sheet to apply is assumed.
ref
Describes a node of source XML document in XPath expression which reflects a value set in control.
If omitted, the node which reflects a value set in control is not assumed to exist.
relevant
Sets whether control is valid or not. It can be an XPath expression. A control is determined whether it is valid or not by evaluating its described XPath expression as true or false value.
true,
false,
If omitted, true() is assumed to be set.
readonly
Sets whether a control is reference only or not. It can be an XPath expression. A control is determined whether it is reference only or not by evaluating its described XPath expression as true or false value.
true,
false,
If omitted, false() is assumed to be set.
design-mode
Sets whether it uses design-mode or not. It can be a true/false value.
true
false
If omitted, false is assumed to be set.
maxlength
Sets maximum length of input string. This can be an integer value greater than 1.
If omitted, string length to input is not restricted.
inputmode
Sets the IME input mode. This can be described in one of the following strings.
hiragana
katakana
katakana halfWidth
latin fullWidth
off
If a control other than text field is created according to type attribute, it becomes invalid. For IME input mode setting, see IME Control.
If omitted, IME control will not be performed.
dispatch-value-changed-event
Specifies when ctrl:value-changed event is issued. This can be described in one of the following strings.
text-committed
text-edited
If omitted, text-committed is assumed to be set.
The ctrl:textarea element can contain the following elements.
ctrl:label Element
xvcd:action Element
ctrl:range ElementCreates a spinner control to input specified range of numeric values.
start (mandatory)
Sets maximum value of input. This can be an integer value greater than -9,223,372,036,854,775,808 and less than 9,223,372,036,854,775,807. If fractional value is specified in step attribute, the maximum value set to control is 10 raised to the power of - specified value (number of decimals of step attribute value). If the number of decimals exceeds the number of decimals of step attribute, exceeded data will be truncated. You cannot specify the value to be set as exponent representation.
end (mandatory)
Sets minimum value of input. This can be an integer value greater than -9,223,372,036,854,775,808 and less than 9,223,372,036,854,775,807. If fractional value is specified in step attribute, the minimum value set to control is 10 raised to the power of - specified value (number of decimals of step attribute value). If the number of decimals exceeds the number of decimals of step attribute, exceeded data will be truncated. You cannot specify the value to be set as exponent representation.
step
Sets the range of numeric values to increase or decrease. If a fractional value is specified, you can input the number of decimals. 18 digits can be specified as a number of digits under decimal-point.
If omitted, 1 is assumed to be specified.
style
Describes the style sheet applied to the control. Describe a style sheet with CSS.
If omitted, no style sheet to apply is assumed.
ref
Describes a node of source XML document in XPath expression which reflects a value set in control.
If omitted, the node which reflects a value set in control is not assumed to exist.
relevant
Sets whether control is valid or not. It can be an XPath expression. A control is determined whether it is valid or not by evaluating its described XPath expression as true or false value.
true,
false,
If omitted, true() is assumed to be set.
readonly
Sets whether a control is reference only or not. It can be an XPath expression. A control is determined whether it is reference only or not by evaluating its described XPath expression as true or false value.
true,
false,
If omitted, false() is assumed to be set.
design-mode
Sets whether it uses design-mode or not. It can be a true/false value.
true
false
If omitted, false is assumed to be set.
The ctrl:range element can contain the following elements.
ctrl:label Element
xvcd:action Element
ctrl:select1 ElementCreates a control to select one from multiple choices. The following controls can be created by specifying a value for appearance attribute.
appearance
Sets appearance of control to create. This can be described in one of the following strings.
full
compact
minimal
If omitted, minimal is assumed to be set.
selection
When minimal is set as an appearance attribute value, specifies whether any string can be input or not. This can be described in one of the following strings.
open
closed
Ignored, if appearance attribute value is not minimal.
If omitted, closed is assumed to be specified.
direction
When full is set as an appearance attribute value, sets whether radio buttons are arranged horizontally or vertically. This can be described in one of the following strings.
vertical
horizontal
Ignored, if appearance attribute value is not full.
If omitted, horizontal is assumed to be specified.
style
Describes the style sheet applied to the control. Describe a style sheet with CSS.
If omitted, no style sheet to apply is assumed.
ref
Describes a node of source XML document in XPath expression which reflects a value set in control.
If omitted, the node which reflects a value set in control is not assumed to exist.
relevant
Sets whether control is valid or not. It can be an XPath expression. A control is determined whether it is valid or not by evaluating its described XPath expression as true or false value.
true,
false,
If omitted, true() is assumed to be set.
readonly
Sets whether a control is reference only or not. It can be an XPath expression. A control is determined whether it is reference only or not by evaluating its described XPath expression as true or false value.
true,
false,
If omitted, false() is assumed to be set.
design-mode
Sets whether it uses design-mode or not. It can be a true/false value.
true
false
If omitted, false is assumed to be set.
alert-invalid-value
If the value indicated by the node set to ref attribute cannot be set for a control, sets whether to show the warning or not. It can be a true/false value.
true
ref attribute cannot be set for a control, shows the warning.
false
ref attribute cannot be set.
If ref attribute is not specified or if the control is invalid, no warning is shown despite of the value to be set. Enabled when full is set to appearance attribute.
If omitted, true is assumed to be set.
maxlength
Sets maximum length of input string. This can be an integer value greater than 1.
If omitted, string length to input is not restricted.
inputmode
Sets the IME input mode. This can be described in one of the following strings.
hiragana
katakana
katakana halfWidth
latin fullWidth
off
If a control other than text field is created according to type attribute, it becomes invalid. For IME input mode setting, see IME Control.
If omitted, IME control will not be performed.
popup-height
Sets the height when showing a scroll bar in the popup of drop-down list or combo box. Specify using CSS length unit systems: px, em and ex.
If omitted, 200px is assumed to be specified.
The ctrl:select1 element can contain the following elements.
ctrl:label Element
ctrl:item Element
xvcd:action Element
ctrl:select ElementCreates a list box control to select multiple values from multiple choices
appearance
Sets appearance of control to create. This can be described in one of the following strings.
compact
If omitted, compact is assumed to be specified.
style
Describes the style sheet applied to the control. Describe a style sheet with CSS.
If omitted, no style sheet to apply is assumed.
ref
Describes a node of source XML document in XPath expression which reflects a value set in control.
If omitted, the node which reflects a value set in control is not assumed to exist.
relevant
Sets whether control is valid or not. It can be an XPath expression. A control is determined whether it is valid or not by evaluating its described XPath expression as true or false value.
true,
false,
If omitted, true() is assumed to be set.
readonly
Sets whether a control is reference only or not. It can be an XPath expression. A control is determined whether it is reference only or not by evaluating its described XPath expression as true or false value.
true,
false,
If omitted, false() is assumed to be set.
design-mode
Sets whether it uses design-mode or not. It can be a true/false value.
true
false
If omitted, false is assumed to be set.
The ctrl:select element can contain the following elements.
ctrl:label Element
ctrl:item Element
xvcd:action Element
ctrl:trigger ElementCreates a button control to issue a ctrl:triggered event on clicking.
style
Describes the style sheet applied to the control. Describe a style sheet with CSS.
If omitted, no style sheet to apply is assumed.
relevant
Sets whether control is valid or not. It can be an XPath expression. A control is determined whether it is valid or not by evaluating its described XPath expression as true or false value.
true,
false,
If omitted, true() is assumed to be set.
readonly
Sets whether a control is reference only or not. It can be an XPath expression. A control is determined whether it is reference only or not by evaluating its described XPath expression as true or false value.
true,
false,
If omitted, false() is assumed to be set.
command
Sets string which indicates the command issued in ctrl:triggered event. It can be QName. If an operation is specified using xvcd:action element in ctrl:trigger element, the command specified in command attribute will not be performed.
If omitted, execution command is not assumed to be set.
design-mode
Sets whether it uses design-mode or not. It can be a true/false value.
true
false
If omitted, false is assumed to be set.
The ctrl:trigger element can contain the following elements.
ctrl:label Element
xvcd:action Element
ctrl:select-color ElementCreates a color selection control.
pallete
Sets the color palette type used in color selection control. This can be described in one of the following strings.
css-defined
web-safe
If omitted, css-defined is assumed to be set.
style
Describes the style sheet applied to the control. Describe a style sheet with CSS.
If omitted, no style sheet to apply is assumed.
ref
Describes a node of source XML document in XPath expression which reflects a value set in control.
If omitted, the node which reflects a value set in control is not assumed to exist.
relevant
Sets whether control is valid or not. It can be an XPath expression. A control is determined whether it is valid or not by evaluating its described XPath expression as true or false value.
true,
false,
If omitted, true() is assumed to be set.
readonly
Sets whether a control is reference only or not. It can be an XPath expression. A control is determined whether it is reference only or not by evaluating its described XPath expression as true or false value.
true,
false,
If omitted, false() is assumed to be set.
design-mode
Sets whether it uses design-mode or not. It can be a true/false value.
true
false
If omitted, false is assumed to be set.
The ctrl:select-color element can contain the following elements.
ctrl:label Element
xvcd:action Element
ctrl:border ElementCreates a border to group controls and use title. Specify a group title in ctrl:label element of the element content.
style
Describes the style sheet applied to the control. Describe a style sheet with CSS.
If omitted, no style sheet to apply is assumed.
The ctrl:border element can contain the following elements.
ctrl:label Element
ctrl:input Element
ctrl:secret Element
ctrl:textarea Element
ctrl:range Element
ctrl:select1 Element
ctrl:select Element
ctrl:trigger Element
ctrl:select-color Element
ctrl:border Element
ctrl:static-label Element
ctrl:static-label ElementDisplays the label. Specify a display string in ctrl:label element of the element content.
Unlike ctrl:label element, available as a vertex element of control description vocabulary.
style
Describes the style sheet applied to the control. Describe a style sheet with CSS.
If omitted, no style sheet to apply is assumed.
relevant
Sets whether control is valid or not. It can be an XPath expression. A control is determined whether it is valid or not by evaluating its described XPath expression as true or false value.
true,
false,
If omitted, true() is assumed to be set.
design-mode
Sets whether it uses design-mode or not. It can be a true/false value.
true
false
If omitted, false is assumed to be set.
The ctrl:static-label element can contain the following elements.
ctrl:label Element
ctrl:label ElementSpecifies a label string in the element. Unlike ctrl:static-label element, specify it in the element content in order to set a label string to a control created in other elements.
Unavailable as vertex element of control description vocabulary.
style
Describes the style sheet applied to the control. Describe a style sheet with CSS.
If omitted, no style sheet to apply is assumed.
Specify control's label string by PCDATA string in ctrl:label element.
ctrl:item Element
Specifies single item selected in ctrl:select1 element or ctrl:select element. Specify an item value in ctrl:value element of the element content. Specify an item name in ctrl:label element of the element content. If ctrl:label element is omitted, ctrl:value element content is used as an item name.
Unavailable as vertex element of control description vocabulary.
style
Describes the style sheet applied to the control. Describe a style sheet with CSS.
If omitted, no style sheet to apply is assumed.
The element can contain the following elements.
ctrl:label Elementctrl:value Elementctrl:value Element
Specifies single item selected in ctrl:select1 element or ctrl:select element.
Unavailable as vertex element of control description vocabulary.
No attributes for the element.
Specify the string held in ctrl:item element by PCDATA string in ctrl:value element.
When creating a user interface with control in XVCD, you can create it in design mode.
In design mode, you can study control layout in the screen. In design mode, every control can be focused regardless of an attribute value. Other key or mouse operations are however invalid.
Specify whether to use control in design mode or not for each control described in XVCD.
If a control is used to input string, you can set IME input mode in XVCD when the control is focused. If you changed IME input mode in XVCD, IME does not go back to previous input mode after the control loses focus.
Even if control's IME input mode is set in XVCD, you can change IME input mode. Therefore, if input text size is restricted in the control, input string should be checked despite of IME input mode setting.
Explains about event handling in each element of control description namespace and defined event element.
An event corresponding to user operation is issued on the controls created in the following elements:
ctrl:input Element
ctrl:secret Element
ctrl:textarea Element
ctrl:range Element
ctrl:select1 Element
ctrl:select Element
ctrl:trigger Element
ctrl:select-color Element
If xvcd:action element is specified in each element content, you can specify a response to the event issued from control.
In the control element, in which ctrl:value-changed event is issued, the following build-in commands are provided as default event handling:
<xvcd:command>
<instruction:param name="ctrl:ref" />
<instruction:param name="event:event" />
<xvcd:set-text select="$crtl:ref" value="{$event:event/ctrl:*/@value}" />
</xvcd:command>
To use default ctrl:value-changed event handling, in ref attribute of each element, you should specify the node which reflects a value set in the control.
The event elements defined in the control description namespace are listed below. You don't write an event element to describe your XVCD. Describes the event elements with platform.
ctrl:value-changed EventIssued when control value is changed. Elements in which the event is issued are as follows:
ctrl:input Element
ctrl:secret Element
ctrl:textarea Element
ctrl:range Element
ctrl:select1 Element
ctrl:select Element
ctrl:select-color Element
value (mandatory)
The value set in the control is set to when an event is issued. The value's content to be set may vary according to control.
ctrl:input Element
type attribute.
type attribute:
boolean is set to type attribute:
true or false.
date is set to type attribute:
CCYY-MM-DD format.
ctrl:secret, ctrl:textarea elements
ctrl:range Element
ctrl:select1 Element
ctrl:value element content, which is described in the content of ctrl:item element corresponding to the selected item, is set.
ctrl:select Element
ctrl:value element content, which is described in the content of ctrl:item element corresponding to the selected item, and is separated and connected by single-bye space, is set.
ctrl:select-color Element
#RRGGBB format, is specified.
The ctrl:value-changed element is empty.
ctrl:caret-moved EventIssued when the caret moves in the control. Elements in which the event is issued are as follows:
ctrl:input element in which type attribute is not specified
ctrl:textarea Element
offset (mandatory)
Offset position is set from the top of the string input in a control. The offset position is represented by an integer from top of the string as zero.
The ctrl:caret-moved element is empty.
ctrl:triggered Event
Issued when the control created in ctrl:trigger element is clicked.
No attributes for the element.
The ctrl:triggered element is empty.