1<?xml version='1.0'?> 2<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" 3 xmlns:fo="http://www.w3.org/1999/XSL/Format" 4 xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" 5 exclude-result-prefixes="doc" 6 version='1.0'> 7 8<xsl:output method="xml" 9 indent="yes"/> 10 11<!-- ******************************************************************** 12 $Id$ 13 ******************************************************************** 14 15 This file is part of the XSL DocBook Stylesheet distribution. 16 See /README or http://nwalsh.com/docbook/xsl/ for copyright 17 and other information. 18 19 ******************************************************************** --> 20 21<!-- ==================================================================== --> 22 23<xsl:include href="/VERSION"/> 24<xsl:include href="param.xsl"/> 25<xsl:include href="/lib/lib.xsl"/> 26<xsl:include href="/common/l10n.xsl"/> 27<xsl:include href="/common/common.xsl"/> 28<xsl:include href="/common/labels.xsl"/> 29<xsl:include href="/common/titles.xsl"/> 30<xsl:include href="/common/subtitles.xsl"/> 31<xsl:include href="/common/gentext.xsl"/> 32<xsl:include href="autotoc.xsl"/> 33<xsl:include href="lists.xsl"/> 34<xsl:include href="callout.xsl"/> 35<xsl:include href="verbatim.xsl"/> 36<xsl:include href="graphics.xsl"/> 37<xsl:include href="xref.xsl"/> 38<xsl:include href="formal.xsl"/> 39<xsl:include href="table.xsl"/> 40<xsl:include href="sections.xsl"/> 41<xsl:include href="inline.xsl"/> 42<xsl:include href="footnote.xsl"/> 43<xsl:include href="fo.xsl"/> 44<xsl:include href="info.xsl"/> 45<xsl:include href="keywords.xsl"/> 46<xsl:include href="division.xsl"/> 47<xsl:include href="index.xsl"/> 48<xsl:include href="toc.xsl"/> 49<xsl:include href="refentry.xsl"/> 50<xsl:include href="math.xsl"/> 51<xsl:include href="admon.xsl"/> 52<xsl:include href="component.xsl"/> 53<xsl:include href="biblio.xsl"/> 54<xsl:include href="glossary.xsl"/> 55<xsl:include href="block.xsl"/> 56<xsl:include href="qandaset.xsl"/> 57<xsl:include href="synop.xsl"/> 58<xsl:include href="titlepage.xsl"/> 59<xsl:include href="titlepage.templates.xsl"/> 60<xsl:include href="pagesetup.xsl"/> 61<xsl:include href="pi.xsl"/> 62 63<xsl:include href="fop.xsl"/> 64 65<!-- ==================================================================== --> 66 67<xsl:template match="*"> 68 <xsl:message> 69 <xsl:value-of select="name(.)"/> 70 <xsl:text> encountered, but no template matches.</xsl:text> 71 </xsl:message> 72 <fo:block color="red"> 73 <xsl:text><</xsl:text> 74 <xsl:value-of select="name(.)"/> 75 <xsl:text>></xsl:text> 76 <xsl:apply-templates/> 77 <xsl:text></</xsl:text> 78 <xsl:value-of select="name(.)"/> 79 <xsl:text>></xsl:text> 80 </fo:block> 81</xsl:template> 82 83<xsl:template match="text()"> 84 <xsl:value-of select="."/> 85</xsl:template> 86 87<xsl:template match="/"> 88 <xsl:message> 89 <xsl:text>Making </xsl:text> 90 <xsl:value-of select="$page.orientation"/> 91 <xsl:text> pages on </xsl:text> 92 <xsl:value-of select="$paper.type"/> 93 <xsl:text> paper (</xsl:text> 94 <xsl:value-of select="$page.width"/> 95 <xsl:text>x</xsl:text> 96 <xsl:value-of select="$page.height"/> 97 <xsl:text>)</xsl:text> 98 </xsl:message> 99 100 <xsl:variable name="document.element" select="*[1]"/> 101 <xsl:variable name="title"> 102 <xsl:choose> 103 <xsl:when test="$document.element/title[1]"> 104 <xsl:value-of select="$document.element/title[1]"/> 105 </xsl:when> 106 <xsl:otherwise>[could not find document title]</xsl:otherwise> 107 </xsl:choose> 108 </xsl:variable> 109 110 <fo:root font-family="{$body.font.family}" 111 font-size="{$body.font.size}" 112 text-align="{$alignment}"> 113 <xsl:call-template name="setup.pagemasters"/> 114 <xsl:choose> 115 <xsl:when test="$rootid != ''"> 116 <xsl:choose> 117 <xsl:when test="count(id($rootid)) = 0"> 118 <xsl:message terminate="yes"> 119 <xsl:text>ID '</xsl:text> 120 <xsl:value-of select="$rootid"/> 121 <xsl:text>' not found in document.</xsl:text> 122 </xsl:message> 123 </xsl:when> 124 <xsl:otherwise> 125 <xsl:if test="$fop.extensions != 0"> 126 <xsl:apply-templates select="id($rootid)" mode="outline"/> 127 </xsl:if> 128 <xsl:apply-templates select="id($rootid)"/> 129 </xsl:otherwise> 130 </xsl:choose> 131 </xsl:when> 132 <xsl:otherwise> 133 <xsl:if test="$fop.extensions != 0"> 134 <xsl:apply-templates mode="outline"/> 135 </xsl:if> 136 <xsl:apply-templates/> 137 </xsl:otherwise> 138 </xsl:choose> 139 140 </fo:root> 141</xsl:template> 142 143<!-- ==================================================================== --> 144 145</xsl:stylesheet> 146