Contact Us or call 1-877-932-8228


Markers are used to add information about the current page to static regions. The two FOs used to create and reference markers are marker and retrieve-marker. Markers are grouped by class name with the marker-class-name attribute of the marker FO. This is the only attribute marker takes.

<xsl:template match="body/div/h2" mode="Stories"> <fo:block font-weight="bold" font-size="larger" id="{generate-id(.)}" break-before="odd-page"> <fo:marker marker-class-name="StoryTitle"> <xsl:value-of select="."/> </fo:marker> <xsl:value-of select="."/> </fo:block> </xsl:template>

The contents of a marker do not show up in the location of the marker itself. They only appear if the marker is referenced with a retrieve-marker FO.

<fo:static-content flow-name="evenHead"> <fo:block border-bottom-width="thin" border-bottom-style="solid" border-bottom-color="green" font-weight="bold" text-align="outside"> <fo:retrieve-marker retrieve-class-name="StoryTitle" retrieve-position="first-including-carryover"/> </fo:block> </fo:static-content>

As shown above, retrieve-marker uses the retrieve-class-name attribute to specify which marker class to reference. It uses the retrieve-position attribute to help identify which marker in that class to use. The retrieve-position attribute takes the following values:

  • first-starting-within-page - references the first marker on the current page.
  • first-including-carryover - references the first marker on the current page. If there are no markers on the current page, it references the last marker before the current page.
  • last-starting-within-page - references the last marker on the current page.
  • last-ending-within-page - references the last marker on the current page that is contained in a FO whose full content is also on the current page.

The retrieve-marker FO takes one additional attribute: retrieve-boundary, which is used to specify the domain in which to search for markers. By default, it is limited to the page-sequence, which is almost always what you want; however, you can change it so that it searches the whole document or just the current page.