Bump to docbook-xsl-stylesheets 1.79.2
[platform/upstream/docbook-xsl-stylesheets.git] / roundtrip / normalise-common.xsl
1 <xsl:stylesheet version='1.0'
2   xmlns:xsl='http://www.w3.org/1999/XSL/Transform'
3   xmlns:rnd='http://docbook.org/ns/docbook/roundtrip'
4   xmlns:db='http://docbook.org/ns/docbook'
5   exclude-result-prefixes='db'>
6
7   <!-- ********************************************************************
8
9        This file is part of the XSL DocBook Stylesheet distribution.
10        See ../README or http://nwalsh.com/docbook/xsl/ for copyright
11        and other information.
12
13        ******************************************************************** -->
14
15   <!-- rnd:map-paragraph-style and rd:map-character-style
16        allows the application to customise
17        the style names used by overriding this template.
18        The idea is to map custom names back to standard names. -->
19   <xsl:template name='rnd:map-paragraph-style'>
20     <xsl:param name='style'/>
21     <xsl:choose>
22       <xsl:when test='starts-with($style, "Normal")'/>
23
24       <!-- Probably should fold all style names to lower-case -->
25       <xsl:when test='$style = "Caption"'>caption</xsl:when>
26
27       <xsl:otherwise>
28         <xsl:value-of select='$style'/>
29       </xsl:otherwise>
30     </xsl:choose>
31   </xsl:template>
32   <xsl:template name='rnd:map-character-style'>
33     <xsl:param name='style'/>
34     <xsl:value-of select='$style'/>
35   </xsl:template>
36
37 </xsl:stylesheet>