File: xmlroff.xsl

package info (click to toggle)
debian-faq 13.1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 6,540 kB
  • sloc: makefile: 176; perl: 116; sh: 58
file content (25 lines) | stat: -rw-r--r-- 780 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">

  <xsl:output
    method="xml" indent="yes" encoding="utf-8"
    doctype-system="http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd"
    doctype-public="-//OASIS//DTD DocBook XML V4.5//EN"/>


  <!-- You must convert footnote as (...) -->
  <xsl:template match="footnote">
    (<xsl:apply-templates select="*|@*|text()"/>)
  </xsl:template>

  <!-- You must skip paragraph breaks in footnote -->
  <xsl:template match="footnote/para">
    <xsl:apply-templates select="*|@*|text()"/>
  </xsl:template>

  <xsl:template match="*|@*|text()">
    <xsl:copy>
      <xsl:apply-templates select="*|@*|text()"/>
    </xsl:copy>
  </xsl:template>
</xsl:stylesheet>