XML technologies / DocBook / Generating FO (PDF) / Changing page sizes / Page layout parameters

(Excerpt from "DocBook-XML: Media-neutral and platform-independent publishing" by Thomas Schraitle)

Margins have preset defaults. The parameters in the following table control page layout.  

Table: DocBook XSL page layout parameters

Parameters

Description

page.width

Page width

page.height

Page height

page.margin.top

Distance from the physical page’s top edge to the top of the header

page.margin.bottom

Distance from the bottom of the footer to the physical page’s bottom edge

region.before.extent

Header height

region.after.extent

Footer height

body.margin.top

Distance from the top of the header to the start of the body text

body.margin.bottom

Distance from the end of the body text to the bottom of the footer

page.margin.inner

Distance from the binding edge to the start of the body text

page.margin.outer

Distance from the end of the body text to the outer page edge

double.sided

Controls double-sided printing; the default is 0 (disabled)  

To set the page size to 10 cm × 4 cm, run:

xsltproc --stringparam page.width 10cm \
  --stringparam page.height 4cm ...

To set these values in a customization file, add:

<xsl:param name="page.width">10cm</xsl:param>
<xsl:param name="page.height">4cm</xsl:param>

The following figure illustrates these parameters:

Page layout parameters

Figure: Page layout parameters

  

back to top