1 | <?xml version="1.0"?>
|
---|
2 |
|
---|
3 | <!--
|
---|
4 | Copyright (C) 2006-2022 Oracle Corporation
|
---|
5 |
|
---|
6 | This file is part of VirtualBox Open Source Edition (OSE), as
|
---|
7 | available from http://www.alldomusa.eu.org. This file is free software;
|
---|
8 | you can redistribute it and/or modify it under the terms of the GNU
|
---|
9 | General Public License (GPL) as published by the Free Software
|
---|
10 | Foundation, in version 2 as it comes in the "COPYING" file of the
|
---|
11 | VirtualBox OSE distribution. VirtualBox OSE is distributed in the
|
---|
12 | hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
|
---|
13 | -->
|
---|
14 |
|
---|
15 | <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
|
---|
16 |
|
---|
17 | <!-- Must strip spaces in 'arg' elements too, we'll get extra spaces when
|
---|
18 | using 'replaceable'. Adding option too, just in case. -->
|
---|
19 | <xsl:strip-space elements="arg option"/>
|
---|
20 |
|
---|
21 | <!-- Our hand written css styling. -->
|
---|
22 | <xsl:template name="user.head.content">
|
---|
23 | <style type="text/css">
|
---|
24 | <xsl:comment>
|
---|
25 | body
|
---|
26 | {
|
---|
27 | font-family: Verdana, Sans-serif, Arial, 'Trebuchet MS', 'Times New Roman';
|
---|
28 | font-size: small;
|
---|
29 | }
|
---|
30 | h2.title
|
---|
31 | {
|
---|
32 | font-family: Verdana, Sans-serif, Arial, 'Trebuchet MS', 'Times New Roman';
|
---|
33 | margin: 5px 0 0;
|
---|
34 | padding: 1px 5px 1px;
|
---|
35 | border: 1px solid #6b89d4;
|
---|
36 | -moz-border-radius: 0.3em;
|
---|
37 | background: #e6edff;
|
---|
38 | }
|
---|
39 | .titlepage
|
---|
40 | {
|
---|
41 | text-align: center;
|
---|
42 | }
|
---|
43 | .refsynopsisdiv, .refsect1, .refsect2, .refsect3
|
---|
44 | {
|
---|
45 | text-align: left;
|
---|
46 | }
|
---|
47 | .warning
|
---|
48 | {
|
---|
49 | padding: 5px;
|
---|
50 | border: 1px solid #ff0011;
|
---|
51 | -moz-border-radius: 0.3em;
|
---|
52 | background: #ffbbbb;
|
---|
53 | }
|
---|
54 | .warning .title { margin: 0px 0px 5px 0px; }
|
---|
55 | .warning p { margin: 1px; }
|
---|
56 | .note
|
---|
57 | {
|
---|
58 | padding: 1px 5px 1px;
|
---|
59 | border: 1px solid #84c43b;
|
---|
60 | -moz-border-radius: 0.3em;
|
---|
61 | background: #d7e9a7;
|
---|
62 | }
|
---|
63 | .note .title { margin: 0px 0px 5px 0px; }
|
---|
64 | .note p { margin: 1px; }
|
---|
65 | .cmdsynopsis
|
---|
66 | {
|
---|
67 | font-family: monospace;
|
---|
68 | }
|
---|
69 | .refsynopsisdiv > .cmdsynopsis p, .refsect1 > .cmdsynopsis p,
|
---|
70 | .refsynopsisdiv .sect2 > .cmdsynopsis p, .refsect1 .sect2 > .cmdsynopsis p
|
---|
71 | {
|
---|
72 | margin-top: 0px;
|
---|
73 | margin-bottom: 0px;
|
---|
74 | }
|
---|
75 | .cmdsynopsis p
|
---|
76 | {
|
---|
77 | padding-left: 3.4em;
|
---|
78 | text-indent: -2.2em;
|
---|
79 | }
|
---|
80 | p.nextcommand
|
---|
81 | {
|
---|
82 | margin-top: 0px;
|
---|
83 | margin-bottom: 0px;
|
---|
84 | }
|
---|
85 | p.lastcommand
|
---|
86 | {
|
---|
87 | margin-top: 0px;
|
---|
88 | }
|
---|
89 | .refentry * h3
|
---|
90 | {
|
---|
91 | font-size: large;
|
---|
92 | }
|
---|
93 | .refentry * h4
|
---|
94 | {
|
---|
95 | font-size: larger;
|
---|
96 | }
|
---|
97 | .refentry * h5
|
---|
98 | {
|
---|
99 | font-size: larger;
|
---|
100 | }
|
---|
101 |
|
---|
102 | </xsl:comment>
|
---|
103 | </style>
|
---|
104 | </xsl:template>
|
---|
105 |
|
---|
106 |
|
---|
107 | <!-- Ignore/skip the remark that the command overview inclusion file
|
---|
108 | uses as the root element. -->
|
---|
109 | <xsl:template match="remark[@role='VBoxManage-overview']">
|
---|
110 | <xsl:apply-templates select="node()"/>
|
---|
111 | </xsl:template>
|
---|
112 |
|
---|
113 |
|
---|
114 | <!-- This is for allow special CSS rules to apply to the refsect stuff. -->
|
---|
115 | <xsl:template match="sect2[ @role = 'not-in-toc']/title
|
---|
116 | | sect3[ @role = 'not-in-toc']/title
|
---|
117 | | sect4[ @role = 'not-in-toc']/title
|
---|
118 | | sect5[ @role = 'not-in-toc']/title
|
---|
119 | | section[ @role = 'not-in-toc']/title
|
---|
120 | | simplesect[@role = 'not-in-toc']/title
|
---|
121 | | sect1[ @condition = 'refentry']/title
|
---|
122 | | sect2[ @condition = 'refentry']/title
|
---|
123 | | sect1[ starts-with(@condition, 'refsect')]/title
|
---|
124 | | sect2[ starts-with(@condition, 'refsect')]/title
|
---|
125 | | sect3[ starts-with(@condition, 'refsect')]/title
|
---|
126 | | sect4[ starts-with(@condition, 'refsect')]/title
|
---|
127 | | sect5[ starts-with(@condition, 'refsect')]/title
|
---|
128 | | section[ starts-with(@condition, 'refsect')]/title
|
---|
129 | | simplesect[starts-with(@condition, 'refsect')]/title
|
---|
130 | " mode="titlepage.mode">
|
---|
131 | <xsl:element name="div">
|
---|
132 | <xsl:attribute name="class">
|
---|
133 | <xsl:value-of select="../@role"/>
|
---|
134 | <xsl:if test="../@role and ../@condition">
|
---|
135 | <xsl:text> </xsl:text>
|
---|
136 | </xsl:if>
|
---|
137 | <xsl:value-of select="../@condition"/>
|
---|
138 | </xsl:attribute>
|
---|
139 | <xsl:apply-imports/>
|
---|
140 | </xsl:element>
|
---|
141 | </xsl:template>
|
---|
142 |
|
---|
143 | <xsl:template match="sect2[ @role = 'not-in-toc']
|
---|
144 | | sect3[ @role = 'not-in-toc']
|
---|
145 | | sect4[ @role = 'not-in-toc']
|
---|
146 | | sect5[ @role = 'not-in-toc']
|
---|
147 | | section[ @role = 'not-in-toc']
|
---|
148 | | simplesect[@role = 'not-in-toc']
|
---|
149 | | sect1[ @condition = 'refentry']
|
---|
150 | | sect2[ @condition = 'refentry']
|
---|
151 | | sect1[ starts-with(@condition, 'refsect')]
|
---|
152 | | sect2[ starts-with(@condition, 'refsect')]
|
---|
153 | | sect3[ starts-with(@condition, 'refsect')]
|
---|
154 | | sect4[ starts-with(@condition, 'refsect')]
|
---|
155 | | sect5[ starts-with(@condition, 'refsect')]
|
---|
156 | | section[ starts-with(@condition, 'refsect')]
|
---|
157 | | simplesect[starts-with(@condition, 'refsect')]" >
|
---|
158 | <xsl:element name="div">
|
---|
159 | <xsl:attribute name="class">
|
---|
160 | <xsl:value-of select="@role"/>
|
---|
161 | <xsl:if test="@role and @condition">
|
---|
162 | <xsl:text> </xsl:text>
|
---|
163 | </xsl:if>
|
---|
164 | <xsl:value-of select="@condition"/>
|
---|
165 | </xsl:attribute>
|
---|
166 | <xsl:apply-imports/>
|
---|
167 | </xsl:element>
|
---|
168 | </xsl:template>
|
---|
169 |
|
---|
170 | <!-- To use CSS to correctly insert hanging indent when soft wrapping and
|
---|
171 | <sbr>'ing a synopsis, we must place each command in its own <p>. The default
|
---|
172 | is to must issue a <br /> before each <command>, except the first one.
|
---|
173 | Note! This is a bit ugly as we're going contrary to the grain of XSLT here
|
---|
174 | starting with an closing . -->
|
---|
175 | <xsl:template match="cmdsynopsis/command">
|
---|
176 | <xsl:text disable-output-escaping="yes"><![CDATA[</p><p class="nextcommand">]]></xsl:text>
|
---|
177 | <xsl:call-template name="inline.monoseq"/>
|
---|
178 | <xsl:text> </xsl:text>
|
---|
179 | </xsl:template>
|
---|
180 | <xsl:template match="cmdsynopsis/command[last()]">
|
---|
181 | <xsl:text disable-output-escaping="yes"><![CDATA[</p><p class="lastcommand">]]></xsl:text>
|
---|
182 | <xsl:call-template name="inline.monoseq"/>
|
---|
183 | <xsl:text> </xsl:text>
|
---|
184 | </xsl:template>
|
---|
185 |
|
---|
186 | </xsl:stylesheet>
|
---|
187 |
|
---|