Common problems

The customised stylesheets used in cop-e-boox, and the standard DocBook stylesheets, are not bug-free. Users can expect some invalid markup or errors with typesetting to be generated in PDF and EPUB ebooks and web pages. This section presents the known problems that are created by the stylesheets. It also outlines how those problems can be resolved by editing parts of the generated ebook formats to achieve correctly formatted print, and valid and well-formed markup.

Problem Solution
PDF output
Front cover doesn't generate in a PDF
Note: The size of the image for the front cover can be produced in a graphics package slightly larger than the page size to accommodate page bleed.
Check the name of the front cover image is correct at stylesheet feature p3-10. Check that the height (p3-35) and width (p3-40) are the same size as the page size. The values for stylesheet features p3-15 to p3-30 might be too large, so reset them to zero ("0") or reduce them then readjust to change the horizontal and vertical positioning of the image (see the next problem below).
Image on the front cover of a PDF isn't positioned properly (e.g. there is a gap on one or more sides of the image) To shift the image up, use a negative value at p3-15 (top margin) and the same positive value at p3-20 (bottom margin). To shift the image down, use a positive value at p3-15 (top margin) and the same negative value at p3-20 (bottom margin). Use a similar approach to shift the image left or right.
Table of contents doesn't display the page numbers or titles correctly for the preliminary matter (preface) pages or glossaries Make sure that the xml:id values are different for each of those XML files
EPUB and web output
Tables do not conform to web accessibility requirements Cop-e-boox v 0.2 does not generate HTML5 "scope" and "headers" attributes in table markup for screen reader accessibility. You will need to add this markup to table data (<td> elements) in the generated HTML files (as part of tidying up table formatting).
Embedded index is not generated for EPUB or web pages Specify a unique xml:id name for the <index> element, such as "endindex".
The file names of a book's lists of titles (LOTs), when created in separate pages, do not appear in the EPUB package.opf file. When you select the value "1" in the stylesheet e0-epubdocbookmaster.xsl at feature e0-50, separate HTML files are created for the list of figures, list of tables, list of examples and list of equations. The names of these files do not appear in the EPUB package.opf manifest. You will need to add "item" elements into the manifest for each LOT file.
The dc:date metadata element doesn't generate a valid ISO date. There may be typesetting/transformation errors or validation errors when producing EPUB and web pages. Change the date in the dc:date element to the ISO 8601 standard (YYYY-MM-DD). For EPUB, this is in the package.opf file. For web pages, this is in the <head> element of the index.html page.
HTML5 elements in both EPUB and web pages are generated with class attributes for spans of text, but you don't want any class attributes (e.g. div class="name"). Cop-e-boox generates class names for titles and some body text such as special paragraphs. If you need cleaner HTML5 markup without class attributes, either delete them from HTML pages or contact Xmplar to customise your stylesheets.
Graphics are left-aligned and horizontal alignment can't be changed in HTML5 markup or CSS. Setting the feature c4-60 in stylesheet c4-epubwebtextformats.xsl to "1" creates a table around graphics (images and vector illustrations). If graphics have a "width" value set in the <imagedata> element in XML, then the alignment of graphics can't be changed in HTML5 or CSS styles. If graphics do not have a "width" value, then alignment can be changed in HTML5 and CSS styles for the <td> element. Setting c4-60 to "0" removes <table> markup from HTML5 and makes it easier to align graphics.
Punctuation that is inserted by processing instructions doesn't generate in EPUB and web pages If you use processing instructions within an <info> element to insert punctuation (see stylesheet c2-epubwebpi.xsl for examples), then that punctuation doesn't appear in HTML. The most obvious places are in a book title page and imprint page where content appears inside <book> <info> tags in XML. You need to edit the HTML files to add missing punctuation.