10.3. Parameters of the XSLT stylesheets used to convert an ebook specification to XSL-FO

Parameter Value Default Value Description
apply-css-styles 'no' | 'yes' 'yes' Specifies whether CSS styles specified in XHTML style attributes, style and link elements also apply to the XSL-FO file.

Depending on the context, the following CSS properties are converted to their equivalent XSL-FO attributes. The corresponding shorthand CSS properties are supported too. Any other CSS property is ignored. Generated content (:before, :after) is ignored too.

  • margin-top, margin-right, margin-bottom, margin-left.
  • padding-top, padding-right, padding-bottom, padding-left.
  • border-top-style, border-right-style, border-bottom-style, border-left-style.
  • border-top-width, border-right-width, border-bottom-width, border-left-width.
  • border-top-color, border-right-color, border-bottom-color, border-left-color.
  • background-color, background-image, background-repeat, background-position.
  • color.
  • font-family, font-style, font-weight, font-size.
  • text-decoration.
  • text-align.
  • text-indent.
  • vertical-align.
  • line-height.
  • list-style-type, list-style-position, list-style-image.
  • width, height.
  • caption-side.
  • border-spacing.

Note that styles specified this way supersede all the other ways to specify the presentation in the output file, that is, parameters like base-font-size or the presentation attributes (xsl:attribute-set) specified in the XSLT stylesheets that generate the XSL-FO file.

base-font-size Length in pt '10pt' The size of the font used for most body elements (paragraphs, tables, lists, etc). All the other font sizes are computed relatively to this font size.
base-line-height A valid line height '10' The line height used for most body elements (paragraphs, tables, lists, etc). All the line heights are computed relatively to this line height.
external-href-after String ']' Appended after the external URL referenced by an a element. Ignored unless show-external-links='yes'.
external-href-before String ' [' Separates the text of an a element from the external URL it points to. Ignored unless show-external-links='yes'.
font-family One or more font families separated by commas 'serif' The font family used by default for all elements.
footer-center A mix of text and variables. See next column. Specifies the contents of the central part of a page footer. See Section 10.3.1. Specifying a header or a footer.

Default value:

two-sides even:: {{chapter-title}};;
two-sides body odd:: {{section1-title}};;
one-side:: {{chapter-title}}
footer-center-width String representing an integer larger than or equal to 1. '6' Specifies the proportional width of the central part of a page footer. See Section 10.3.1. Specifying a header or a footer.
footer-left A mix of text and variables. See next column. Specifies the contents of the left part of a page footer. See Section 10.3.1. Specifying a header or a footer.

Default value:

two-sides even:: {{page-number}}
footer-left-width String representing an integer larger than or equal to 1. '2' Specifies the proportional width of the left part of a page footer. See Section 10.3.1. Specifying a header or a footer.
footer-right A mix of text and variables. See next column. Specifies the contents of the right part of a page footer. See Section 10.3.1. Specifying a header or a footer.

Default value:

two-sides first||odd:: {{page-number}};;
one-side:: {{page-number}}
footer-right-width String representing an integer larger than or equal to 1. '2' Specifies the proportional width of the right part of a page footer. See Section 10.3.1. Specifying a header or a footer.
footer-separator 'no' | 'yes' 'yes' Specifies whether an horizontal rule should be drawn above the page footer. See Section 10.3.1. Specifying a header or a footer.
header-center A mix of text and variables. '{{document-title}}' Specifies the contents of the central part of a page header. See Section 10.3.1. Specifying a header or a footer.
header-center-width String representing an integer larger than or equal to 1. '6' Specifies the proportional width of the central part of a page header. See Section 10.3.1. Specifying a header or a footer.
header-left A mix of text and variables. '' Specifies the contents of the left part of a page header. See Section 10.3.1. Specifying a header or a footer.
header-left-width String representing an integer larger than or equal to 1. '2' Specifies the proportional width of the left part of a page header. See Section 10.3.1. Specifying a header or a footer.
header-right A mix of text and variables. '' Specifies the contents of the right part of a page header. See Section 10.3.1. Specifying a header or a footer.
header-right-width String representing an integer larger than or equal to 1. '2' Specifies the proportional width of the right part of a page header. See Section 10.3.1. Specifying a header or a footer.
header-separator 'no' | 'yes' 'yes' Specifies whether an horizontal rule should be drawn below the page header. See Section 10.3.1. Specifying a header or a footer.
hyphenate 'no' | 'yes' 'no' Specifies whether words may be hyphenated.
justified 'no' | 'yes' 'no' Specifies whether text (e.g. in paragraphs) should be justified (that is, flush left and right) or just left aligned (that is, flush left and ragged right).
index-column-count Positive integer. '2' The number of columns of index pages.
index-column-gap Length. '2em' The distance which separates columns in index pages.
note-icon-height Length '0.333in' The height of a note icon. See parameter use-note-icon.
note-icon-width Length '0.333in' The width of a note icon. See parameter use-note-icon.
page-orientation 'portrait' | 'landscape' 'portrait' The orientation of the printed page.
page-ref-after String ']' Appended after the page number pointed to by an a element. Ignored unless show-xref-page='yes'.
page-ref-before String ' [' Separates the text of an a element from the page number it points to. Ignored unless show-xref-page='yes'.
paper-type Allowed values are: 'Letter', 'Legal', 'Ledger', 'Tabloid', 'A0', 'A1', 'A2', 'A3', 'A4', 'A5', 'A6', 'A7', 'A8', 'A9', 'A10', 'B0', 'B1', 'B2', 'B3', 'B4', 'B5', 'B6', 'B7', 'B8', 'B9', 'B10', 'C0', 'C1', 'C2', 'C3', 'C4', 'C5', 'C6', 'C7', 'C8', 'C9', 'C10' (case-insensitive). 'A4' A convenient way to specify the size of the printed page.I

t is also possible to specify a custom paper type by ignoring the paper-type parameter and directly specifying the page-width and page-height parameters.

pdf-outline 'no' | 'yes' 'no' Specifies whether PDF bookmarks should be generated.

Supported by the 'XEP', 'FOP' and 'AHF' XSL-FO processors. Not relevant, and thus ignored by 'XFC'.

show-external-links 'no' | 'yes' 'no' Specifies whether the external URL referenced by an a element should be displayed right after the text contained by this element.

Example: show-external-links='yes' causes <a href="http://www.oasis-open.org/">Oasis</a> to be rendered as follows: Oasis [http://www.oasis-open.org/].

show-map-links 'no' | 'yes' 'yes' Specifies whether a numbered list should be generated for a XHTML map element, with one list item per area element.

A list item contains the link specified by the area element. No list items are generated for “dead areas” (area elements specifying no link at all).

show-xref-page 'no' | 'yes' 'no' Specifies whether the page number corresponding to the internal link target referenced by an a element should be displayed right after the text contained by this element.

Example: show-xref-page='yes' causes <a href="#introduction">Introduction</a> to be rendered as follows: Introduction [3].

two-sided 'no' | 'yes' 'no' Specifies whether the document should be printed double sided.
ul-li-bullets One or more bullet characters separated by spaces '&#x2022; &#x2013;' Specify which bullet character to use for an ul/li element. Additional characters are used for nested li elements.

For example, if ul-li-bullets="* - +", "*" will be used for ul/li elements, "-" will be used for ul/li elements contained in a ul/li element and "+" will be used for ul/li elements nested in two ul/li elements.

use-note-icon 'no' | 'yes' 'no' Specifies whether an icon should be added to blockquote elements having a class attribute containing role-note, role-attention, role-caution, role-danger, role-fastpath, role-important, role-notice, role-remember, role-restriction, role-tip, role-trouble, role-warning.
use-note-label 'no' | 'yes' 'no' Specifies whether a title should be added to blockquote elements having a class attribute containing role-note, role-attention, role-caution, role-danger, role-fastpath, role-important, role-notice, role-remember, role-restriction, role-tip, role-trouble, role-warning.
watermark Allowed values are one or more of 'blank', 'title', 'toc', 'booklist', 'frontmatter', 'body', 'backmatter', 'index', 'all' separated by whitespace. 'all' Specifies which pages in the output document are to be given a watermark.

By default, all pages are given a watermark. If for example, parameter watermark is set to 'frontmatter body backmatter', then only the pages which are part of the front matter, body and back matter of the output document are given a watermark. The title page, TOC pages, etc, are not given a watermark.

No effect unless parameter watermark-image is specified.

watermark-image URI. If the URI is relative, it is relative to the current working directory of the user. No default. Specifies an image file which is to be used as a watermark in all the pages comprising the output document. See also parameter watermark.
xfc-render-as-table A string containing zero or more roles or element names separated by whitespace.

Supported roles and element names are: admonition, aside, blockquote, footer, header, nav.

'admonition aside blockquote' Specifies whether XMLmind XSL-FO Converter should render the fo:blocks representing specified elements as fo:tables.

This parameter enables a workaround for a limitation of XMLmind XSL-FO Converter: a fo:block having a border and/or background color and containing several other blocks, lists or tables is very poorly rendered in RTF, WML, DOCX and ODT.

Inserting a <?pagebreak?> processing-instruction in the XHTML5 source between paragraphs, notes, tables, lists, etc, may be used to force a page break when generating any of the output formats which uses XSL-FO as an intermediate format (PDF, RTF, DOCX, etc).

§ Page layout parameters

Parameter Value Default Value Description
body-bottom-margin Length '0.5in' See Figure 10-1. Page areas below.
body-top-margin Length '0.5in' See Figure 10-1. Page areas below.
footer-height Length '0.4in' See Figure 10-1. Page areas below.
header-height Length '0.4in' See Figure 10-1. Page areas below.
page-bottom-margin Length '0.5in' See Figure 10-1. Page areas below.
page-height Length. Example: '297mm'. Depends on parameter paper-type. The height of the printed page.
page-inner-margin Length If parameter two-sided is specified as 'yes' then '1.25in' otherwise '1in'. See Figure 10-1. Page areas below.
page-outer-margin Length If parameter two-sided is specified as 'yes' then '0.75in' otherwise '1in'. See Figure 10-1. Page areas below.
page-top-margin Length '0.5in' See Figure 10-1. Page areas below.
page-width Length. Example: '8.5in'. Depends on parameter paper-type. The width of the printed page.
Figure 10-1. Page areas
Page areas

§ System parameters

Such system parameters are not intended to be specified by the end-user. Such system parameters are documented here only because the end-user may see them referenced in some dialog boxes, in some configuration files or in the source code of the XSLT stylesheets.

Parameter Value Default Value Description
foProcessor 'FOP' | 'XEP' | 'XFC' |'AHF' Automatically set by the application hosting XMLmind Ebook Compiler The name of the XSL-FO processor used to convert the XSL-FO file generated by the XSLT stylesheets to the target output format.
img-src-path URI ending with '/' '' If this parameter is not empty and if the value of the src attribute is a relative URI, then this parameter is prepended to the value of the src attribute.

This low-level alternative to resolve-img-src='yes' also allows the generation of an XSL-FO file where all the references to graphic files are absolute URIs.

outputFormat String. Examples: 'ps', 'pdf', 'rtf', 'wml', 'docx', 'odt'. Automatically set by the application hosting XMLmind Ebook Compiler The file extension of the target output file.
resolve-a-href 'no' | 'yes' 'no' In the XSL-FO file, convert relative URIs contained in the href attribute of a elements to absolute URIs. This is done by resolving the relative URI against the base of the a element.
resolve-img-src 'no' | 'yes' 'no' In the XSL-FO file, convert relative URIs contained in the src attribute of img elements to absolute URIs. This is done by resolving the relative URI against the base of the img element.
screen-resolution Number 96.0 Screen resolution in DPI. Used to convert px to pt.
xsl-resources-directory URL 'resources/' resolved against the directory which contains the XSLT stylesheets. These XSLT stylesheets generate files which reference resources such as note icons. This parameter specifies the directory containing such resources.