OLD | NEW |
| (Empty) |
1 <refentry xmlns="http://docbook.org/ns/docbook" | |
2 xmlns:xlink="http://www.w3.org/1999/xlink" | |
3 xmlns:xi="http://www.w3.org/2001/XInclude" | |
4 xmlns:src="http://nwalsh.com/xmlns/litprog/fragment" | |
5 xmlns:xsl="http://www.w3.org/1999/XSL/Transform" | |
6 version="5.0" xml:id="docbook.css.source"> | |
7 <refmeta> | |
8 <refentrytitle>docbook.css.source</refentrytitle> | |
9 <refmiscinfo class="other" otherclass="datatype">string</refmiscinfo> | |
10 </refmeta> | |
11 <refnamediv> | |
12 <refname>docbook.css.source</refname> | |
13 <refpurpose>Name of the default CSS input file</refpurpose> | |
14 </refnamediv> | |
15 | |
16 <refsynopsisdiv> | |
17 <src:fragment xml:id="docbook.css.source.frag"><xsl:param name="docbook.css.
source">docbook.css.xml</xsl:param></src:fragment> | |
18 </refsynopsisdiv> | |
19 | |
20 <refsection><info><title>Description</title></info> | |
21 | |
22 <para>The <parameter>docbook.css.source</parameter> parameter | |
23 specifies the name of the file containing the default DocBook | |
24 CSS styles. Those styles are necessary when the | |
25 <parameter>make.clean.html</parameter> parameter is nonzero.</para> | |
26 | |
27 <para>The file is a well-formed XML file that | |
28 must consist of a single <tag>style</tag> root | |
29 element that contains CSS styles as its text content. | |
30 The default value of the parameter (and filename) | |
31 is <literal>docbook.css.xml</literal>. | |
32 The stylesheets ship with the default file. You can substitute | |
33 your own and specify its path in this parameter.</para> | |
34 | |
35 <para>If <parameter>docbook.css.source</parameter> is not blank, | |
36 and <parameter>make.clean.html</parameter> is nonzero, then | |
37 the stylesheet takes the following actions:</para> | |
38 | |
39 <orderedlist> | |
40 <listitem> | |
41 <para>The stylesheet uses the XSLT <literal>document()</literal> | |
42 function to open the file specified by the parameter and | |
43 load it into a variable.</para> | |
44 </listitem> | |
45 <listitem> | |
46 <para>The stylesheet forms an output pathname consisting of the | |
47 value of the <parameter>base.dir</parameter> parameter (if it is set) | |
48 and the value of <parameter>docbook.css.source</parameter>, | |
49 with the <literal>.xml</literal> suffix stripped off. | |
50 </para> | |
51 </listitem> | |
52 <listitem> | |
53 <para>The stylesheet removes the <tag>style</tag> | |
54 wrapper element and writes just the CSS text content to the output file.</pa
ra> | |
55 </listitem> | |
56 <listitem> | |
57 <para>The stylesheet adds a <tag>link</tag> element to the | |
58 HTML <tag>HEAD</tag> element to reference the external CSS stylesheet. | |
59 For example:</para> | |
60 <programlisting><link rel="stylesheet" href="docbook.css" type="text/css"
> | |
61 </programlisting> | |
62 <para>However, if the <parameter>docbook.css.link</parameter> | |
63 parameter is set to zero, then no <tag>link</tag> is written | |
64 for the default CSS file. That is useful if a custom | |
65 CSS file will import the default CSS stylesheet to ensure | |
66 proper cascading of styles.</para> | |
67 </listitem> | |
68 </orderedlist> | |
69 | |
70 <para>If the <parameter>docbook.css.source</parameter> parameter | |
71 is changed from its default <literal>docbook.css.xml</literal> to blank, | |
72 then no default CSS is generated. Likewise if the | |
73 <parameter>make.clean.html</parameter> parameter is set to zero, | |
74 then no default CSS is generated. The | |
75 <parameter>custom.css.source</parameter> parameter can be used | |
76 instead to generate a complete custom CSS file.</para> | |
77 | |
78 <para>You can use the <parameter>generate.css.header</parameter> | |
79 parameter to instead write the CSS to each HTML <tag>HEAD</tag> | |
80 element in a <tag>style</tag> tag instead of an external CSS file.</para> | |
81 | |
82 </refsection> | |
83 </refentry> | |
OLD | NEW |