Skip to content

Why is there a period after the block title in the PDF output?

Dan Allen edited this page Jun 11, 2013 · 2 revisions

If your document has blocks that have block titles, you may notice in the PDF output (as generated by a2x using the --fop flag) that a period gets added to the end of the block title.

You won’t see the period in the intermediary DocBook XML that’s generated when creating a PDF. Alas, it’s added by the DocBook XSL templates when the DocBook XML is converted to FO XML.

Here’s the attribute that controls what character is added after a block title and before the content (hint: it’s a period)

runinhead.default.title.end.punct

Default punctuation character on a run-in-head
See: http://docbook.sourceforge.net/release/xsl/1.78.1/doc/html/runinhead.default.title.end.punct.html

To get rid of it, you can add the following XSL parameter default in the docbook-xsl/common.xsl file that ships with AsciiDoc:

<xsl:param name="runinhead.default.title.end.punct"/>

The trailing period will be a goner.