xref: /OK3568_Linux_fs/kernel/tools/lib/perf/Documentation/manpage-base.xsl (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593Smuzhiyun<!-- manpage-base.xsl:
2*4882a593Smuzhiyun     special formatting for manpages rendered from asciidoc+docbook -->
3*4882a593Smuzhiyun<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
4*4882a593Smuzhiyun		version="1.0">
5*4882a593Smuzhiyun
6*4882a593Smuzhiyun<!-- these params silence some output from xmlto -->
7*4882a593Smuzhiyun<xsl:param name="man.output.quietly" select="1"/>
8*4882a593Smuzhiyun<xsl:param name="refentry.meta.get.quietly" select="1"/>
9*4882a593Smuzhiyun
10*4882a593Smuzhiyun<!-- convert asciidoc callouts to man page format;
11*4882a593Smuzhiyun     git.docbook.backslash and git.docbook.dot params
12*4882a593Smuzhiyun     must be supplied by another XSL file or other means -->
13*4882a593Smuzhiyun<xsl:template match="co">
14*4882a593Smuzhiyun	<xsl:value-of select="concat(
15*4882a593Smuzhiyun			      $git.docbook.backslash,'fB(',
16*4882a593Smuzhiyun			      substring-after(@id,'-'),')',
17*4882a593Smuzhiyun			      $git.docbook.backslash,'fR')"/>
18*4882a593Smuzhiyun</xsl:template>
19*4882a593Smuzhiyun<xsl:template match="calloutlist">
20*4882a593Smuzhiyun	<xsl:value-of select="$git.docbook.dot"/>
21*4882a593Smuzhiyun	<xsl:text>sp&#10;</xsl:text>
22*4882a593Smuzhiyun	<xsl:apply-templates/>
23*4882a593Smuzhiyun	<xsl:text>&#10;</xsl:text>
24*4882a593Smuzhiyun</xsl:template>
25*4882a593Smuzhiyun<xsl:template match="callout">
26*4882a593Smuzhiyun	<xsl:value-of select="concat(
27*4882a593Smuzhiyun			      $git.docbook.backslash,'fB',
28*4882a593Smuzhiyun			      substring-after(@arearefs,'-'),
29*4882a593Smuzhiyun			      '. ',$git.docbook.backslash,'fR')"/>
30*4882a593Smuzhiyun	<xsl:apply-templates/>
31*4882a593Smuzhiyun	<xsl:value-of select="$git.docbook.dot"/>
32*4882a593Smuzhiyun	<xsl:text>br&#10;</xsl:text>
33*4882a593Smuzhiyun</xsl:template>
34*4882a593Smuzhiyun
35*4882a593Smuzhiyun</xsl:stylesheet>
36