![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() |
||
| operator | %c | |
| Related Syntax | Related Concepts | |
Syntax
% format-modifier c
The parse continuation operator ("%c") causes OmniMark to resume parsing at the point it is encountered. %c must be placed within a text string. Any data output as the result of subsequent parsing is output at the place %c occurs in the string.
For example, to output the content generated by parsing element "list", surrounded by HTML unordered list tags, use the following code:
element list
output "<ul>%c</ul>"
The "<ul> will be output followed by the result of parsing element "list", followed by "</ul>". Assuming that element "list" consists of "item" elements, the rule fired when "list" is being processed would be the "item" rule:
element item
output "<li>%c%n"
Either %c or suppress must be executed once and once only within the processing of a markup rule. The %c or suppress may occur in the rule body or in any code executed as a result of actions in the rule body. It is a run-time error if a %c or suppress is executed more than once, or if neither one is executed at all in the course of processing the rule.
The %c parse continuation operator may have modifiers, called element content format modifiers. These modifiers apply to the stream (or streams) to which the "%c" is written to. These modifiers apply only to data content characters that are written as a result of parsing the content. Literal text written to these streams is not affected by the "%c" modifiers.
It is possible to override the subcomponents, even those going into the same stream, by removing the modifier with the following syntax:
put my-stream with " " "%c"
The element content format modifiers are:
insertion-break and replacement-break from applying to the content of the current component.
|
Related Syntax suppress |
Related Concepts Event handling |
| ---- |