1 <?xml version=
"1.0" encoding=
"UTF-8"?>
2 <xsl:stylesheet version=
"1.0" xmlns:
xsl=
"http://www.w3.org/1999/XSL/Transform">
3 <xsl:output indent=
"yes" method=
"xml"/>
5 <!-- SPECIFY YOUR FILE SYSTEM ROOT PATH TO THE HELP FILES -->
6 <xsl:param name=
"fsroot" select=
"'file:///handbuch/WORKBENCH/helpcontent2/source/'"/>
9 ######################################################
11 ######################################################
13 <xsl:template match=
"/">
14 <xsl:apply-templates/>
17 <xsl:template match=
"*|@*|comment()|processing-instruction()|text()">
19 <xsl:apply-templates select=
"*|@*|comment()|processing-instruction()|text()"/>
23 <xsl:template match=
"*|@*|comment()|processing-instruction()|text()" mode=
"embedded">
25 <xsl:apply-templates select=
"*|@*|comment()|processing-instruction()|text()" mode=
"embedded"/>
29 <xsl:template match=
"bookmark" mode=
"embedded" />
30 <xsl:template match=
"ahelp" mode=
"embedded">
31 <xsl:apply-templates mode=
"embedded"/>
34 <xsl:template match=
"paragraph[@role='heading']">
36 <xsl:apply-templates/>
40 <xsl:template match=
"paragraph[@role=*]">
42 <xsl:apply-templates/>
46 <xsl:template match=
"sort">
47 <xsl:apply-templates/>
52 ######################################################
54 ######################################################
56 <xsl:template match=
"embed">
58 <xsl:variable name=
"href"><xsl:value-of select=
"substring-before(concat($fsroot,@href),'#')"/></xsl:variable>
59 <xsl:variable name=
"anchor"><xsl:value-of select=
"substring-after(@href,'#')"/></xsl:variable>
60 <xsl:variable name=
"doc" select=
"document($href)"/>
61 <xsl:apply-templates select=
"$doc//section[@id=$anchor]" mode=
"embedded"/>
62 <xsl:if test=
"not($doc//section[@id=$anchor])"> <!-- fallback for embeds that actually should be embedvars -->
63 <paragraph role=
"paragraph"><xsl:apply-templates select=
"$doc//variable[@id=$anchor]" mode=
"embedded"/></paragraph>
68 ######################################################
70 ######################################################
72 <xsl:template match=
"embedvar">
73 <xsl:if test=
"not(@href='text/shared/00/00000004.xhp#wie')"> <!-- special treatment if howtoget links -->
74 <xsl:variable name=
"href"><xsl:value-of select=
"substring-before(concat($fsroot,@href),'#')"/></xsl:variable>
75 <xsl:variable name=
"anchor"><xsl:value-of select=
"substring-after(@href,'#')"/></xsl:variable>
76 <xsl:variable name=
"doc" select=
"document($href)"/>
77 <xsl:apply-templates select=
"$doc//variable[@id=$anchor]" mode=
"embedded"/>
80 <!-- FPE: embedvars, that point to "text/shared/00/00000004.xml#wie" will only be resolved in the main_transform -->