<kwd>
The <kwd> element identifies a keyword within a syntax diagram
or phrase.
Usage information
A <kwd> might be entered by a user typing in the syntax, or rendered
by an application as part of a syntax prompt. The keyword value is typed or rendered exactly
as specified in the syntax diagram or phrase.
Specialization hierarchy
The <kwd> element is specialized from
<keyword>. It is defined in the syntax-diagram domain module, which
is a specialization of the programming domain module.
Content model
(Text | <text>)*
Contained by
<groupchoice>, <groupcomp>, <groupseq>, <synph>
- Text
<text>
Contained by
Inheritance
+ topic/keyword pr-d/keyword syntaxdiagram-d/kwd
The <kwd> element is specialized from <keyword>. It is defined in the syntaxdiagram-domain module.
Attributes
The following attributes are available on
this element: universal
attributes and
@keyref.
For this element, the
@importance attribute indicates
whether this item in a syntax diagram is optional, required,
or used by default. The attribute value is limited to
optional,
required,
default, or
-dita-use-conref-target.
The following attributes are available on this element: universal attributes and the attributes defined below.
@importance- For this element, the
@importanceattribute indicates whether this item in a syntax diagram is optional, required, or used by default. The attribute value is limited to optional, required, default, or -dita-use-conref-target. @keyref- Specifies a key
name that acts as a redirectable reference based on a key
definition within a map. See STUB CONTENT for information on using
this attribute.
For HDITA, the equivalent of
@keyrefis@data-keyref
Example
This section is non-normative.
The following code sample shows how the
<kwd> element can be used to identify text
that must be provided to the application exactly as specified:
<syntaxdiagram id="validate">
<title>Validate account setup</title>
<groupseq>
<kwd>clicmd</kwd>
<groupcomp>
<oper>--</oper><kwd>user</kwd><sep>=</sep><var>userid</var>
</groupcomp>
<groupcomp>
<oper>--</oper><kwd>validate</kwd>
</groupcomp>
</groupseq>
</syntaxdiagram>