The FormattedTextView (CL_WD_FORMATTED_TEXT=>E_TYPE-FORMATTED_TEXT) supports the tags listed in the following table. Note that the entries are case-sensitive.
XHTML Text Module Tags
Tag |
Description |
abbr |
Abbreviation |
acronym |
Acronym |
address |
Format as address |
blockquote |
Block quote |
br |
Line break |
cite |
Cite |
ode |
Inline Code |
dfn |
Definition |
div |
Div |
em |
Emphasis |
h1 |
Header Level 1 *1 |
h2 |
Header Level 2 *1 |
h3 |
Header Level 3 *1 |
h4 |
Header Level 4 *1 |
h5 |
Header Level 5 *1 (not supported) |
h6 |
Header Level 6 *1 (not supported) |
kbd |
Text to be entered via Keyboard |
p |
Paragraph |
pre |
Pre formatted text |
q |
Quotation |
samp |
Sample (block) |
span |
Span |
strong |
Strong |
var |
text that is a variable |
* Header tags must be on the top level.
See also: http://www.w3.org/TR/html4/struct/text.html
XHTML List Module Tags
Tag |
Description |
dl |
Definition list |
dt |
Definition topic |
dd |
Definition item |
ol |
Ordered list (numbered list) |
ul |
Unordered list (bullet list) |
li |
List item for "ol" and "ul" |
See also http://www.w3.org/TR/html4/struct/lists.html
Special Tags
Tag |
Description |
formattedText |
Root tag of the FormattedTextView |
a |
Anchor (for links) |
img |
Image |
sap:action |
Placeholder for an action (currently not supported) |
sap:field |
Placeholder for a field |
You have access to the tag name through CL_WD_FORMATTED_TEXT=>E_TAG (fro example, CL_WD_FORMATTED_TEXT=>E_TAG-ABBR)
<a href=”Reference” [Titel=”Tooltip”]>FormattedText</a>
· Reference
A text specified as a reference.
· Tooltip
Text for the quick info.
· FormattedText
Formatted text.
The “a” tag displays a link with the formatted text as the text of the link. When the link is clicked on, the event FormattedTextView.onAction is triggered. The “href” parameter of the clicked on link is provided in the event parameter “href”.
The FormattedTextView does not display a URL automatically when a link is clicked on, even if “href” contains an http URL.
<img src=”ImageSource” [Titel=”Tooltip”]/>
· ImageSource
URL of image.
· Tooltip
Text for the quick info.
The “img” tag displays an image. ImageSource is interpreted like the attribute source of the UI element Image.
<sap:field name=”AttributeName”/>
· AttributeName
An attribute of FormattedTextView.dataSource
The “sap:field” tag is replaced by the value (output representation) of the context attribute that is specified by the name attribute. The attribute is taken from the lead selection element of the context node that is specified by FormattedTextView.dataSource.
Supported tags for the explanation characteristics and the UI element Explanation (CL_WD_FORMATTED_TEXT=>E_TYPE-WAD).
Tag |
Description |
onscreenexplanation |
Root tag for the documentation text |
screenelement |
Inner text as the name of a screen element |
navigationpath |
Contains a list of screen elements as the navigation list |
Emphasis |
Highlighting |
The tag name is accessed using CL_WD_FORMATTED_TEXT=>E_WAD_TAG (for example, CL_WD_FORMATTED_TEXT=>E_WAD_TAG-EMPHASIS)