Skip to content

Cover Page Customization

Steven Higgs edited this page Dec 19, 2016 · 6 revisions

Cover page customization might be the first customization that you might want to implement since most companies want a custom design for the first page, such as a unique logo and a title with custom fonts.

For the oXygen XML Editor user manual, we have chosen a pretty simple design with our logo and a specific title in front of a custom background:

Cover Page

To implement this, we have made the following customizations:

  • Logo and title

    Logo and title customization is implemented in the com.oxygenxml.pdf2.ug/Customization/fo/xsl/front-matter.xsl stylesheet by overriding the createFrontCoverContents template.

    This template is used to generate a table with one row. The row has two cells for a logo and a title.

  • Cover page background

    This customization is implemented in the com.oxygenxml.pdf2.ug/Customization/fo/attrs/layout-masters-attr.xsl stylesheet (see the region-body__frontmatter.odd attribute set).

    This attribute set defines the background-image property for the fo:region-body associated with the front cover page. To impose a fixed dimension to the background image we have used two Apache FOP extensions: fox:background-image-width and fox:background-image-height.

Declaring PDF plugin parameters to specify a certain product

This customization is used to generate three distributions of our user manual for the following products: oXygen XML Editor, oXygen XML Author, and oXygen XML Developer.

Each of the published distributions have different logos and background images. Therefore, we need an XSLT parameter to identify the current published distribution. In this scope, we've declared the oxy-ug-distribution parameter in the com.oxygenxml.pdf2.ug/Customization/fo/xsl/custom.xsl stylesheet. To make this parameter available for the DITA ANT process, it should be also declared in the
com.oxygenxml.pdf2.ug/plugin.xml, see the dita.conductor.pdf2.param extension point.

Related informations

Clone this wiki locally