<revprop>
The <revprop>
element in a DITAVAL
document identifies a value of the @rev
attribute for
flagging. Unlike the conditional processing attributes, which can be
used for both filtering and flagging, the @rev
attribute can only be used for flagging.
Usage information
Neither the <reprop>
element or the @rev
attribute are designed
to be used for version control.
Rendering expectations
If no alternate text is specified, processors can provide default alternate text to indicate the start and end point of the flagged content.
@color
and @backcolor
attributes on <prop>
and
<revprop>
, processors SHOULD support at least the following values:- The color names listed under the heading "<color>" in the XSL version 1.1 specification
- The associated hex code
@style
attribute
on <rev>
and
<revprop>
, processors SHOULD support the following tokens:- bold
- double-underline
- italics
- overline
- underline
In addition, processors MAY support proprietary tokens
for the @style
attribute. Such tokens SHOULD have a processor-specific
prefix to identify them as proprietary. If a processor encounters
an unsupported style token, it MAY issue a warning, and it MAY render content that is
flagged with such a style token by using some default
formatting.
Processing expectations
It is an error to include more than one
<revprop>
element with the same @val
attribute.
Recovery from this error is implementation dependent. In such cases processors MAY provide an error or warning message.
The following list outlines how processors apply
@outputclass
flags:
- If one or more DITAVAL properties apply
@outputclass
flags to the same element, and the element already specifies one or more values for the@outputclass
attribute, processors treat the element as if the tokens for the@outputclass
attribute that were provided in the DITAVAL document are specified first. - If two or more DITAVAL properties apply
@outputclass
flags to the same element, processors treat the element as if each value was specified for the@outputclass
attribute. The order of the tokens for the@outputclass
attribute that were provided in the DITAVAL document is undefined.
Content model
<startflag>
?,
<endflag>
?
- Optional
<startflag>
- Optional
<endflag>
Attributes
The following attributes are available on this element:
@action
(REQUIRED)-
Specifies the action to be taken. The following values are supported:
- flag
- Indicates that the content is included in the output and flagged, if the content has not been excluded.
- include
- Indicates that the content is included in the output and not flagged. This is the default behavior, unless otherwise set.
- passthrough
- Indicates that the content is included in the output and that the attribute value is preserved. This enables further processing by a runtime engine. The attribute value is preserved in the syntax that is required by the runtime engine.
@val
- Specifies the value of the
@rev
attribute. If the@val
attribute is not specified, then the<revprop>
element declares a default behavior for any instance of the@rev
attribute.
The following
attributes are only applicable when the @action
attribute is set to flag. If the
@action
attribute is not set to
flag, any value specified for these attributes
are ignored.
@backcolor
- Specifies the background color for flagged text. Colors can be entered by name or hex code. When images are flagged, the background color is rendered as a thick border.
@changebar
- Specifies a color, style, or character to be used for rendering a change bar.
@color
- Specifies the color for flagged text. Colors can be entered by name or hex code. When images are flagged, the color is rendered as a thin border.
@outputclass
- Specifies a value for the
@outputclass
attribute. The flagged element is treated as if the specified@outputclass
value was specified on that element. @style
- Specifies the formatting to use for flagged text. This attribute can contain multiple space-delimited tokens.
@action
(REQUIRED)-
Specifies the action to be taken. The following values are supported:
- flag
- Indicates that the content is included in the output and flagged, if the content has not been excluded.
- include
- Indicates that the content is included in the output and not flagged. This is the default behavior, unless otherwise set.
- passthrough
- Indicates that the content is included in the output and that the attribute value is preserved. This enables further processing by a runtime engine. The attribute value is preserved in the syntax that is required by the runtime engine.
@backcolor
- Specifies the background color for flagged text. Colors can be entered by name or hex code. When images are flagged, the background color is rendered as a thick border.
@changebar
- Specifies a color, style, or character to be used for rendering a change bar.
@color
- Specifies the color for flagged text. Colors can be entered by name or hex code. When images are flagged, the color is rendered as a thin border.
@outputclass
- Specifies a value for the
@outputclass
attribute. The flagged element is treated as if the specified@outputclass
value was specified on that element. @style
- Specifies the formatting to use for flagged text. This attribute can contain multiple space-delimited tokens.
@val
- Specifies the value of the
@rev
attribute. If the@val
attribute is not specified, then the<revprop>
element declares a default behavior for any instance of the@rev
attribute.
Example
This section is non-normative.
The following code sample shows how the
<revprop>
element can be used to flag
content that has been marked with the @rev
attribute. Elements that specify rev="edits"
are
rendered in red text, and glyphs mark the start and end points of
the flagged revision. Alternate text is provided.
<val>
<revprop action="flag" color="red" val="edits">
<startflag imageref="start-glyph.png>
<alt-text>Start of revision</alt-text>
</startflag>
<endflag imageref="end-glyph.png>
<alt-text>End of revision</alt-text>
</endflag>
</revprop>
</val>