Syntax #
concatenate(label;separator)
label
Label for the XML element that you want to join.
separator (optional)
Optional separator for use with concatenate.
Purpose #
The concatenate annotation is used to join elements of the same type in order to make a larger element. This is often used to join spans, especially in titles. A title that is not in one paragraph can cause conversion problems, especially if it’s the document’s title.
There is an optional separator that can be specified, so that the units joined are still obviously distinct from each other. A common use for this is when joining block-level elements such as paragraphs. The default separator, if none is specified, is a newline; this is stripped when published to HTML, so a Unicode newline is sometimes specified (U+2028) to force the published content to appear the same as the input source.
Example: Concatenate a divided title
This shows a short document with a divided title.
The following shows you what the output may look like before this annotation is applied. You will see that the title has been broken into two topics, which is not what is desired here.
<task> <title>Testing italic and bold text -</title> </task>
<concept> <title>How concatenate is sometimes used</title> <conbody>
Let’s apply the concatenate() annotation now to clean this up. This is what your rule may look like.
The following shows you what the output may look like after this annotation is applied. The title segments have been joined and are in the same topic.
<task> <title>Testing italic and bold text - How concatenate is sometimes used</title> <taskbody>