db-pdf.xsl 2.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. <?xml version='1.0'?>
  2. <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns="http://www.w3.org/1999/xhtml" xmlns:fo="http://www.w3.org/1999/XSL/Format" version="1.0">
  3. <xsl:import href="http://docbook.sourceforge.net/release/xsl/current/fo/docbook.xsl" />
  4. <!-- check project-plan.sh for how this is generated, needed to tweak
  5. the cover page
  6. -->
  7. <xsl:include href="/tmp/titlepage.xsl"/>
  8. <!-- To force a page break in document, i.e per section add a
  9. <?hard-pagebreak?> tag.
  10. -->
  11. <xsl:template match="processing-instruction('hard-pagebreak')">
  12. <fo:block break-before='page' />
  13. </xsl:template>
  14. <!--Fix for defualt indent getting TOC all wierd..
  15. See http://sources.redhat.com/ml/docbook-apps/2005-q1/msg00455.html
  16. FIXME: must be a better fix
  17. -->
  18. <xsl:param name="body.start.indent" select="'0'"/>
  19. <!--<xsl:param name="title.margin.left" select="'0'"/>-->
  20. <!-- stop long-ish header titles getting wrapped -->
  21. <xsl:param name="header.column.widths">1 10 1</xsl:param>
  22. <!-- customise headers and footers a little -->
  23. <xsl:template name="head.sep.rule">
  24. <xsl:if test="$header.rule != 0">
  25. <xsl:attribute name="border-bottom-width">0.5pt</xsl:attribute>
  26. <xsl:attribute name="border-bottom-style">solid</xsl:attribute>
  27. <xsl:attribute name="border-bottom-color">#cccccc</xsl:attribute>
  28. </xsl:if>
  29. </xsl:template>
  30. <xsl:template name="foot.sep.rule">
  31. <xsl:if test="$footer.rule != 0">
  32. <xsl:attribute name="border-top-width">0.5pt</xsl:attribute>
  33. <xsl:attribute name="border-top-style">solid</xsl:attribute>
  34. <xsl:attribute name="border-top-color">#cccccc</xsl:attribute>
  35. </xsl:if>
  36. </xsl:template>
  37. <xsl:attribute-set name="header.content.properties">
  38. <xsl:attribute name="color">#cccccc</xsl:attribute>
  39. </xsl:attribute-set>
  40. <xsl:attribute-set name="footer.content.properties">
  41. <xsl:attribute name="color">#cccccc</xsl:attribute>
  42. </xsl:attribute-set>
  43. <!-- general settings -->
  44. <xsl:param name="fop1.extensions" select="1"></xsl:param>
  45. <xsl:param name="paper.type" select="'A4'"></xsl:param>
  46. <xsl:param name="section.autolabel" select="1"></xsl:param>
  47. <xsl:param name="body.font.family" select="'verasans'"></xsl:param>
  48. <xsl:param name="title.font.family" select="'verasans'"></xsl:param>
  49. <xsl:param name="monospace.font.family" select="'veramono'"></xsl:param>
  50. </xsl:stylesheet>