[yelp-xsl] Updates to common HTML output, colors, and icons



commit 2cbc2b85f46da7edcfff89200bd4167df998e13d
Author: Shaun McCance <shaunm gnome org>
Date:   Wed May 26 10:24:07 2010 -0500

    Updates to common HTML output, colors, and icons

 .gitignore                          |   61 ++++
 configure.ac                        |    1 -
 doc/yelp-xsl/Makefile.am            |    3 +-
 xslt/Makefile.am                    |    2 +-
 xslt/common/Makefile.am             |    2 +
 xslt/common/html.xsl                |  273 ++++++++++++++-----
 xslt/common/utils.xsl               |   16 +-
 xslt/mallard/html/mal2html-css.xsl  |   48 ++--
 xslt/mallard/html/mal2html-page.xsl |    6 -
 xslt/mallard/html/mal2xhtml.xsl     |    9 +-
 xslt/theme/Makefile.am              |    9 -
 xslt/theme/test-theme.xslt          |  193 -------------
 xslt/theme/theme-colors.xsl         |  189 -------------
 xslt/theme/theme-html.xsl           |  521 -----------------------------------
 xslt/theme/theme-icons.xsl          |  167 -----------
 15 files changed, 311 insertions(+), 1189 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index e95fec7..86fe858 100644
--- a/.gitignore
+++ b/.gitignore
@@ -19,6 +19,67 @@ yelp-xsl.pc
 /doc/yelp-xsl/C/M__*.page
 /doc/yelp-xsl/C/P__*.page
 /doc/yelp-xsl/C/T__*.page
+/doc/yelp-xsl/C/color.page
+/doc/yelp-xsl/C/db-chunk.page
+/doc/yelp-xsl/C/db-common.page
+/doc/yelp-xsl/C/db-label.page
+/doc/yelp-xsl/C/db-title.page
+/doc/yelp-xsl/C/db-xref.page
+/doc/yelp-xsl/C/db2html-autotoc.page
+/doc/yelp-xsl/C/db2html-bibliography.page
+/doc/yelp-xsl/C/db2html-block.page
+/doc/yelp-xsl/C/db2html-callout.page
+/doc/yelp-xsl/C/db2html-classsynopsis.page
+/doc/yelp-xsl/C/db2html-cmdsynopsis.page
+/doc/yelp-xsl/C/db2html-css.page
+/doc/yelp-xsl/C/db2html-division.page
+/doc/yelp-xsl/C/db2html-ebnf.page
+/doc/yelp-xsl/C/db2html-footnote.page
+/doc/yelp-xsl/C/db2html-funcsynopsis.page
+/doc/yelp-xsl/C/db2html-index.page
+/doc/yelp-xsl/C/db2html-info.page
+/doc/yelp-xsl/C/db2html-inline.page
+/doc/yelp-xsl/C/db2html-l10n.page
+/doc/yelp-xsl/C/db2html-list.page
+/doc/yelp-xsl/C/db2html-media.page
+/doc/yelp-xsl/C/db2html-qanda.page
+/doc/yelp-xsl/C/db2html-refentry.page
+/doc/yelp-xsl/C/db2html-table.page
+/doc/yelp-xsl/C/db2html-title.page
+/doc/yelp-xsl/C/db2html-xref.page
+/doc/yelp-xsl/C/db2html.page
+/doc/yelp-xsl/C/db2omf.page
+/doc/yelp-xsl/C/db2xhtml.page
+/doc/yelp-xsl/C/dita-common.page
+/doc/yelp-xsl/C/dita2html-block.page
+/doc/yelp-xsl/C/dita2html-css.page
+/doc/yelp-xsl/C/dita2html-fallback.page
+/doc/yelp-xsl/C/dita2html-inline.page
+/doc/yelp-xsl/C/dita2html-list.page
+/doc/yelp-xsl/C/dita2html-media.page
+/doc/yelp-xsl/C/dita2html-page.page
+/doc/yelp-xsl/C/dita2html-table.page
+/doc/yelp-xsl/C/dita2html-topic.page
+/doc/yelp-xsl/C/dita2html.page
+/doc/yelp-xsl/C/dita2xhtml.page
+/doc/yelp-xsl/C/gettext.page
+/doc/yelp-xsl/C/html.page
+/doc/yelp-xsl/C/icons.page
+/doc/yelp-xsl/C/l10n-numbers.page
+/doc/yelp-xsl/C/mal-cache.page
+/doc/yelp-xsl/C/mal-chunk.page
+/doc/yelp-xsl/C/mal-link.page
+/doc/yelp-xsl/C/mal2html-block.page
+/doc/yelp-xsl/C/mal2html-css.page
+/doc/yelp-xsl/C/mal2html-inline.page
+/doc/yelp-xsl/C/mal2html-list.page
+/doc/yelp-xsl/C/mal2html-media.page
+/doc/yelp-xsl/C/mal2html-page.page
+/doc/yelp-xsl/C/mal2html-svg.page
+/doc/yelp-xsl/C/mal2html-table.page
+/doc/yelp-xsl/C/mal2html.page
+/doc/yelp-xsl/C/mal2xhtml.page
+/doc/yelp-xsl/C/utils.page
 /sandbox/mallard/html/mallard.cache
 /sandbox/mallard/html/*.html
 /sandbox/mallard/html/*.png
diff --git a/configure.ac b/configure.ac
index 28b51d4..9b6fca2 100644
--- a/configure.ac
+++ b/configure.ac
@@ -63,7 +63,6 @@ xslt/mallard/cache/Makefile
 xslt/mallard/common/Makefile
 xslt/mallard/html/Makefile
 xslt/gettext/Makefile
-xslt/theme/Makefile
 ])
 
 AC_OUTPUT
diff --git a/doc/yelp-xsl/Makefile.am b/doc/yelp-xsl/Makefile.am
index e9abaac..1dccf1f 100644
--- a/doc/yelp-xsl/Makefile.am
+++ b/doc/yelp-xsl/Makefile.am
@@ -8,8 +8,7 @@ xsldoc_dirs = 						\
 	$(ABS_SRCDIR)/../../xslt/docbook/omf		\
 	$(ABS_SRCDIR)/../../xslt/mallard/cache		\
 	$(ABS_SRCDIR)/../../xslt/mallard/common		\
-	$(ABS_SRCDIR)/../../xslt/mallard/html		\
-	$(ABS_SRCDIR)/../../xslt/theme
+	$(ABS_SRCDIR)/../../xslt/mallard/html
 
 xsldoc_xsls = $(filter-out %db2html-suppressed.xsl,			\
 	$(sort $(patsubst ./%, %,					\
diff --git a/xslt/Makefile.am b/xslt/Makefile.am
index 7bc3a19..4b918c1 100644
--- a/xslt/Makefile.am
+++ b/xslt/Makefile.am
@@ -1,2 +1,2 @@
 # gettext needs to be first
-SUBDIRS = gettext docbook mallard common theme
+SUBDIRS = gettext docbook mallard common
diff --git a/xslt/common/Makefile.am b/xslt/common/Makefile.am
index 9c999b4..e3d3c8e 100644
--- a/xslt/common/Makefile.am
+++ b/xslt/common/Makefile.am
@@ -1,6 +1,8 @@
 xsldir=$(datadir)/yelp-xsl/xslt/common
 
 xsl_DATA =		\
+	color.xsl	\
+	icons.xsl	\
 	html.xsl	\
 	utils.xsl
 
diff --git a/xslt/common/html.xsl b/xslt/common/html.xsl
index df5359b..15f26e2 100644
--- a/xslt/common/html.xsl
+++ b/xslt/common/html.xsl
@@ -25,13 +25,38 @@ Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
                 version="1.0">
 
 <!--!!==========================================================================
-Common HTML Utilities
-Output CSS for transformations to HTML.
-:Requires: gettext colors icons
+HTML Output
+Common utilities and CSS for transformations to HTML.
+:Requires: gettext color icons
 
-FIXME
+This stylesheet contains common templates for creating HTML output. The
+*{html.output} template creates an output file for a node in the source XML
+document, calling *{html.page} to create the actual output. Output files can
+be either XHTML or HTML, depending on the @{html.xhtml} parameter.
+
+This stylesheet matches #{/} and calls *{html.output} on the root XML element.
+This works for most input formats. If you need to do something different, you
+should override the match for #{/}.
 -->
+<xsl:template match="/">
+  <xsl:call-template name="html.output">
+    <xsl:with-param name="node" select="*"/>
+  </xsl:call-template>
+</xsl:template>
+
+
+
+<!--@@==========================================================================
+html.basename
+The base filename of the primary output file.
+:Revision:version="1.0" date="2010-05-25" status="final"
 
+This parameter specifies the base filename of the primary output file, without
+the filename extension. This is used by *{html.output} to determine the output
+filename, and may be used by format-specific linking code. By default, it uses
+the value of an #{id} or #{xml:id} attribute, if present. Otherwise, it uses
+the static string #{index}.
+-->
 <xsl:param name="html.basename">
   <xsl:choose>
     <xsl:when test="/*/@xml:id">
@@ -46,8 +71,32 @@ FIXME
   </xsl:choose>
 </xsl:param>
 
+
+<!--@@==========================================================================
+html.xhtml
+Whether to output XHTML.
+:Revision:version="1.0" date="2010-05-25" status="final"
+
+If this parameter is set to true, this stylesheet will output XHTML. Otherwise,
+the output is assumed to be HTML. Note that for HTML output, the importing
+stylesheet still needs to call #{xsl:namespace-alias} to map the XHTML namespace
+to #{#default}. The @{html.namespace} will be set automatically based on this
+parameter. Stylesheets can use this parameter to check the output type, for
+example when using #{xsl:element}.
+-->
 <xsl:param name="html.xhtml" select="true()"/>
 
+
+<!--@@==========================================================================
+html.namespace
+The XML namespace for the output document.
+:Revision:version="1.0" date="2010-05-25" status="final"
+
+This parameter specifies the XML namespace of all output documents. It will be
+set automatically based on the ${html.xhtml} parameter, either to the XHTML
+namespace, or to the empty namespace. Stylesheets can use this parameter when
+using #{xsl:element}.
+-->
 <xsl:param name="html.namespace">
   <xsl:choose>
     <xsl:when test="$html.xhtml">
@@ -59,9 +108,19 @@ FIXME
   </xsl:choose>
 </xsl:param>
 
+
+<!--@@==========================================================================
+html.extension
+The filename extension for all output files.
+:Revision:version="1.0" date="2010-05-25" status="final"
+
+This parameter specifies a filename extension for all HTML output files. It
+should include the leading dot. By default, #{.xhtml} will be used if
+ {html xhtml} is true; otherwise, #{.html} will be used.
+-->
 <xsl:param name="html.extension">
   <xsl:choose>
-    <xsl:when test="$html.namespace = ''">
+    <xsl:when test="$html.xhtml">
       <xsl:text>.html</xsl:text>
     </xsl:when>
     <xsl:otherwise>
@@ -70,6 +129,10 @@ FIXME
   </xsl:choose>
 </xsl:param>
 
+
+<!--**==========================================================================
+html.output
+-->
 <xsl:template name="html.output">
   <xsl:param name="node" select="."/>
   <xsl:param name="href">
@@ -95,6 +158,9 @@ FIXME
   </exsl:document>
 </xsl:template>
 
+<!--**==========================================================================
+html.page
+-->
 <xsl:template name="html.page">
   <xsl:param name="node" select="."/>
   <html>
@@ -119,12 +185,42 @@ FIXME
   </html>
 </xsl:template>
 
-<xsl:template mode="html.page.mode" match="*"/>
 
+<!--%%==========================================================================
+html.header.mode
+-->
+<xsl:template mode="html.header.mode" match="*"/>
+
+
+<!--%%==========================================================================
+html.footer.mode
+-->
+<xsl:template mode="html.footer.mode" match="*"/>
+
+
+<!--%%==========================================================================
+html.body.mode
+-->
+<xsl:template mode="html.body.mode" match="*"/>
+
+
+<!--**==========================================================================
+html.head.custom
+Stub to output custom content for the HTML #{head} element.
+:Stub: true
+:Revision: version="1.0" date="2010-05-25" status="final"
+
+This template is a stub, called by *{html.page}. You can override this template
+to provide additional elements in the HTML #{head} element of output files.
+-->
 <xsl:template name="html.head.custom">
   <xsl:param name="node" select="."/>
 </xsl:template>
 
+
+<!--**==========================================================================
+html.css
+-->
 <xsl:template name="html.css">
   <xsl:param name="node" select="."/>
   <xsl:param name="direction">
@@ -164,6 +260,47 @@ FIXME
   </style>
 </xsl:template>
 
+
+<!--%%==========================================================================
+html.css.mode
+Output CSS specific to the input format.
+$direction: The directionality of the text, either #{ltr} or #{rtl}.
+$left: The starting alignment, either #{left} or #{right}.
+$right: The ending alignment, either #{left} or #{right}.
+-->
+<xsl:template mode="html.css.mode" match="*">
+  <xsl:param name="direction">
+    <xsl:call-template name="l10n.direction"/>
+  </xsl:param>
+  <xsl:param name="left">
+    <xsl:call-template name="l10n.align.start">
+      <xsl:with-param name="direction" select="$direction"/>
+    </xsl:call-template>
+  </xsl:param>
+  <xsl:param name="right">
+    <xsl:call-template name="l10n.align.end">
+      <xsl:with-param name="direction" select="$direction"/>
+    </xsl:call-template>
+  </xsl:param>
+</xsl:template>
+
+
+<!--**==========================================================================
+html.css.core
+Output CSS that does not reference source elements.
+:Revision: version="1.0" date="2010-05-25" status="final"
+$direction: The directionality of the text, either #{ltr} or #{rtl}.
+$left: The starting alignment, either #{left} or #{right}.
+$right: The ending alignment, either #{left} or #{right}.
+
+This template outputs CSS that can be used in any HTML.  It does not reference
+elements from DocBook, Mallard, or other source languages.  It provides the
+common spacings for block-level elements lik paragraphs and lists, defines
+styles for links, and defines four common wrapper divs: #{header}, #{side},
+#{body}, and #{footer}.
+
+All parameters can be automatically computed if not provided.
+-->
 <xsl:template name="html.css.core">
   <xsl:param name="direction">
     <xsl:call-template name="l10n.direction"/>
@@ -185,9 +322,9 @@ body {
   padding-top: 1em;
   padding-</xsl:text><xsl:value-of select="$left"/><xsl:text>: 1em;
   background-color: </xsl:text>
-    <xsl:value-of select="$theme.color.gray_background"/><xsl:text>;
+    <xsl:value-of select="$color.gray_background"/><xsl:text>;
   color: </xsl:text>
-    <xsl:value-of select="$theme.color.text"/><xsl:text>;
+    <xsl:value-of select="$color.text"/><xsl:text>;
   direction: </xsl:text><xsl:value-of select="$direction"/><xsl:text>;
   max-width: 73em;
   position: relative;
@@ -198,9 +335,9 @@ div.body {
   max-width: 60em;
   min-height: 20em;
   background-color: </xsl:text>
-    <xsl:value-of select="$theme.color.background"/><xsl:text>;
+    <xsl:value-of select="$color.background"/><xsl:text>;
   border: solid 1px </xsl:text>
-    <xsl:value-of select="$theme.color.gray_border"/><xsl:text>;
+    <xsl:value-of select="$color.gray_border"/><xsl:text>;
 }
 div.header {
   max-width: 60em;
@@ -223,19 +360,19 @@ div.trail {
   padding: 0;
   text-indent: -1em;
   color: </xsl:text>
-    <xsl:value-of select="$theme.color.text_light"/><xsl:text>;
+    <xsl:value-of select="$color.text_light"/><xsl:text>;
 }
 a.trail { white-space: nowrap; }
 div.hgroup {
   margin: 0 0 0.5em 0;
   color: </xsl:text>
-    <xsl:value-of select="$theme.color.text_light"/><xsl:text>;
+    <xsl:value-of select="$color.text_light"/><xsl:text>;
   border-bottom: solid 1px </xsl:text>
-    <xsl:value-of select="$theme.color.gray_border"/><xsl:text>;
+    <xsl:value-of select="$color.gray_border"/><xsl:text>;
 }
 h1, h2, h3, h4, h5, h6, h7 {
   margin: 0; padding: 0;
-  color: </xsl:text><xsl:value-of select="$theme.color.text_light"/><xsl:text>;
+  color: </xsl:text><xsl:value-of select="$color.text_light"/><xsl:text>;
   font-weight: bold;
 }
 h1 { font-size: 1.44em; }
@@ -251,13 +388,13 @@ p img { vertical-align: middle; }
 
 table {
   border-collapse: collapse;
-  border-color: </xsl:text><xsl:value-of select="$theme.color.text_light"/><xsl:text>;
+  border-color: </xsl:text><xsl:value-of select="$color.text_light"/><xsl:text>;
   border-width: 1px;
 }
 td, th {
   padding: 0.5em;
   vertical-align: top;
-  border-color: </xsl:text><xsl:value-of select="$theme.color.text_light"/><xsl:text>;
+  border-color: </xsl:text><xsl:value-of select="$color.text_light"/><xsl:text>;
   border-width: 1px;
 }
 thead td, thead th, tfoot td, tfoot th {
@@ -288,10 +425,10 @@ dl.compact dt + dt { margin-top: 0; }
 
 a {
   text-decoration: none;
-  color: </xsl:text><xsl:value-of select="$theme.color.link"/><xsl:text>;
+  color: </xsl:text><xsl:value-of select="$color.link"/><xsl:text>;
 }
 a:visited { color: </xsl:text>
-  <xsl:value-of select="$theme.color.link_visited"/><xsl:text>; }
+  <xsl:value-of select="$color.link_visited"/><xsl:text>; }
 a:hover { text-decoration: underline; }
 a img { border: none; }
 </xsl:text>
@@ -301,6 +438,7 @@ a img { border: none; }
 <!--**==========================================================================
 html.css.elements
 Output CSS for common elements from source formats.
+:Revision: version="1.0" date="2010-05-25" status="final"
 $direction: The directionality of the text, either #{ltr} or #{rtl}.
 $left: The starting alignment, either #{left} or #{right}.
 $right: The ending alignment, either #{left} or #{right}.
@@ -331,7 +469,7 @@ All parameters can be automatically computed if not provided.
 div.title {
   margin: 0 0 0.2em 0;
   font-weight: bold;
-  color: </xsl:text><xsl:value-of select="$theme.color.text_light"/><xsl:text>;
+  color: </xsl:text><xsl:value-of select="$color.text_light"/><xsl:text>;
 }
 div.desc { margin: 0 0 0.2em 0; }
 div.contents + div.desc { margin: 0.2em 0 0 0; }
@@ -344,37 +482,37 @@ pre.linenumbering {
   float: </xsl:text><xsl:value-of select="$left"/><xsl:text>;
   margin-</xsl:text><xsl:value-of select="$right"/><xsl:text>: 0.5em;
   text-align: </xsl:text><xsl:value-of select="$right"/><xsl:text>;
-  color: </xsl:text><xsl:value-of select="$theme.color.text_light"/><xsl:text>;
+  color: </xsl:text><xsl:value-of select="$color.text_light"/><xsl:text>;
   background-color: </xsl:text>
-    <xsl:value-of select="$theme.color.yellow_background"/><xsl:text>;
+    <xsl:value-of select="$color.yellow_background"/><xsl:text>;
 }
 div.code {
   background: url('</xsl:text>
-    <xsl:value-of select="$theme.icons.code"/><xsl:text>') no-repeat top </xsl:text>
+    <xsl:value-of select="$icons.code"/><xsl:text>') no-repeat top </xsl:text>
     <xsl:value-of select="$right"/><xsl:text>;
   border: solid 1px </xsl:text>
-    <xsl:value-of select="$theme.color.gray_border"/><xsl:text>;
+    <xsl:value-of select="$color.gray_border"/><xsl:text>;
 }
 div.figure {
   margin-</xsl:text><xsl:value-of select="$left"/><xsl:text>: 1.72em;
   padding: 4px;
   color: </xsl:text>
-    <xsl:value-of select="$theme.color.text_light"/><xsl:text>;
+    <xsl:value-of select="$color.text_light"/><xsl:text>;
   border: solid 1px </xsl:text>
-    <xsl:value-of select="$theme.color.gray_border"/><xsl:text>;
+    <xsl:value-of select="$color.gray_border"/><xsl:text>;
   background-color: </xsl:text>
-    <xsl:value-of select="$theme.color.gray_background"/><xsl:text>;
+    <xsl:value-of select="$color.gray_background"/><xsl:text>;
 }
 div.figure > div.inner > div.contents {
   margin: 0;
   padding: 0.5em 1em 0.5em 1em;
   text-align: center;
   color: </xsl:text>
-    <xsl:value-of select="$theme.color.text"/><xsl:text>;
+    <xsl:value-of select="$color.text"/><xsl:text>;
   border: solid 1px </xsl:text>
-    <xsl:value-of select="$theme.color.gray_border"/><xsl:text>;
+    <xsl:value-of select="$color.gray_border"/><xsl:text>;
   background-color: </xsl:text>
-    <xsl:value-of select="$theme.color.background"/><xsl:text>;
+    <xsl:value-of select="$color.background"/><xsl:text>;
 }
 div.list > div.title { margin-bottom: 0.5em; }
 div.listing > div.inner { margin: 0; padding: 0; }
@@ -382,63 +520,63 @@ div.listing > div.inner > div.desc { font-style: italic; }
 div.note {
   padding: 6px;
   border-top: solid 1px </xsl:text>
-    <xsl:value-of select="$theme.color.red_border"/><xsl:text>;
+    <xsl:value-of select="$color.red_border"/><xsl:text>;
   border-bottom: solid 1px </xsl:text>
-    <xsl:value-of select="$theme.color.red_border"/><xsl:text>;
+    <xsl:value-of select="$color.red_border"/><xsl:text>;
   background-color: </xsl:text>
-    <xsl:value-of select="$theme.color.yellow_background"/><xsl:text>;
+    <xsl:value-of select="$color.yellow_background"/><xsl:text>;
 }
 div.note > div.inner > div.title {
   margin-</xsl:text><xsl:value-of select="$left"/><xsl:text>: </xsl:text>
-    <xsl:value-of select="$theme.icons.size.note + 6"/><xsl:text>px;
+    <xsl:value-of select="$icons.size.note + 6"/><xsl:text>px;
 }
 div.note > div.inner > div.contents {
   margin: 0; padding: 0;
   margin-</xsl:text><xsl:value-of select="$left"/><xsl:text>: </xsl:text>
-    <xsl:value-of select="$theme.icons.size.note + 6"/><xsl:text>px;
+    <xsl:value-of select="$icons.size.note + 6"/><xsl:text>px;
 }
 div.note > div.inner {
   margin: 0; padding: 0;
   background-image: url("</xsl:text>
-    <xsl:value-of select="$theme.icons.note"/><xsl:text>");
+    <xsl:value-of select="$icons.note"/><xsl:text>");
   background-position: </xsl:text><xsl:value-of select="$left"/><xsl:text> top;
   background-repeat: no-repeat;
-  min-height: </xsl:text><xsl:value-of select="$theme.icons.size.note"/><xsl:text>px;
+  min-height: </xsl:text><xsl:value-of select="$icons.size.note"/><xsl:text>px;
 }
 div.note-advanced div.inner { <!-- background-image: url("</xsl:text>
-  <xsl:value-of select="$theme.icons.note.advanced"/><xsl:text>"); --> }
+  <xsl:value-of select="$icons.note.advanced"/><xsl:text>"); --> }
 div.note-bug div.inner { background-image: url("</xsl:text>
-  <xsl:value-of select="$theme.icons.note.bug"/><xsl:text>"); }
+  <xsl:value-of select="$icons.note.bug"/><xsl:text>"); }
 div.note-important div.inner { background-image: url("</xsl:text>
-  <xsl:value-of select="$theme.icons.note.important"/><xsl:text>"); }
+  <xsl:value-of select="$icons.note.important"/><xsl:text>"); }
 div.note-tip div.inner { background-image: url("</xsl:text>
-  <xsl:value-of select="$theme.icons.note.tip"/><xsl:text>"); }
+  <xsl:value-of select="$icons.note.tip"/><xsl:text>"); }
 div.note-warning div.inner { background-image: url("</xsl:text>
-  <xsl:value-of select="$theme.icons.note.warning"/><xsl:text>"); }
+  <xsl:value-of select="$icons.note.warning"/><xsl:text>"); }
 div.quote {
   padding: 0;
   background-image: url('</xsl:text>
-    <xsl:value-of select="$theme.icons.quote"/><xsl:text>');
+    <xsl:value-of select="$icons.quote"/><xsl:text>');
   background-repeat: no-repeat;
   background-position: top </xsl:text><xsl:value-of select="$left"/><xsl:text>;
   min-height: </xsl:text>
-    <xsl:value-of select="$theme.icons.size.quote"/><xsl:text>px;
+    <xsl:value-of select="$icons.size.quote"/><xsl:text>px;
 }
 div.quote > div.inner > div.title {
   margin: 0 0 0.5em 0;
   margin-</xsl:text><xsl:value-of select="$left"/><xsl:text>: </xsl:text>
-    <xsl:value-of select="$theme.icons.size.quote"/><xsl:text>px;
+    <xsl:value-of select="$icons.size.quote"/><xsl:text>px;
 }
 blockquote {
   margin: 0; padding: 0;
   margin-</xsl:text><xsl:value-of select="$left"/><xsl:text>: </xsl:text>
-    <xsl:value-of select="$theme.icons.size.quote"/><xsl:text>px;
+    <xsl:value-of select="$icons.size.quote"/><xsl:text>px;
 }
 div.quote > div.inner > div.cite {
   margin-top: 0.5em;
   margin-</xsl:text><xsl:value-of select="$left"/><xsl:text>: </xsl:text>
-    <xsl:value-of select="$theme.icons.size.quote"/><xsl:text>px;
-  color: </xsl:text><xsl:value-of select="$theme.color.text_light"/><xsl:text>;
+    <xsl:value-of select="$icons.size.quote"/><xsl:text>px;
+  color: </xsl:text><xsl:value-of select="$color.text_light"/><xsl:text>;
 }
 div.quote > div.inner > div.cite::before {
   <!-- FIXME: i18n -->
@@ -446,9 +584,9 @@ div.quote > div.inner > div.cite::before {
 }
 div.screen {
   background-color: </xsl:text>
-    <xsl:value-of select="$theme.color.gray_background"/><xsl:text>;
+    <xsl:value-of select="$color.gray_background"/><xsl:text>;
   border: solid 1px </xsl:text>
-    <xsl:value-of select="$theme.color.gray_border"/><xsl:text>;
+    <xsl:value-of select="$color.gray_border"/><xsl:text>;
 }
 ol.steps, ul.steps {
   margin: 0;
@@ -456,9 +594,9 @@ ol.steps, ul.steps {
   border-top: solid 1px;
   border-bottom: solid 1px;
   border-color: </xsl:text>
-    <xsl:value-of select="$theme.color.blue_border"/><xsl:text>;
+    <xsl:value-of select="$color.blue_border"/><xsl:text>;
   background-color: </xsl:text>
-    <xsl:value-of select="$theme.color.yellow_background"/><xsl:text>;
+    <xsl:value-of select="$color.yellow_background"/><xsl:text>;
 }
 ol.steps .steps {
   padding: 0;
@@ -472,9 +610,9 @@ div.synopsis > div.inner > div.contents, div.synopsis > pre.contents {
   border-top: solid 1px;
   border-bottom: solid 1px;
   border-color: </xsl:text>
-    <xsl:value-of select="$theme.color.blue_border"/><xsl:text>;
+    <xsl:value-of select="$color.blue_border"/><xsl:text>;
   background-color: </xsl:text>
-    <xsl:value-of select="$theme.color.gray_background"/><xsl:text>;
+    <xsl:value-of select="$color.gray_background"/><xsl:text>;
 }
 div.synopsis > div.inner > div.desc { font-style: italic; }
 div.synopsis div.code {
@@ -485,63 +623,63 @@ div.synopsis div.code {
 div.synopsis div.code > pre.contents { margin: 0; padding: 0; }
 .table {}
 tr.shade {
-  background-color: </xsl:text><xsl:value-of select="$theme.color.gray_background"/><xsl:text>;
+  background-color: </xsl:text><xsl:value-of select="$color.gray_background"/><xsl:text>;
 }
 td.shade {
-  background-color: </xsl:text><xsl:value-of select="$theme.color.gray_background"/><xsl:text>;
+  background-color: </xsl:text><xsl:value-of select="$color.gray_background"/><xsl:text>;
 }
 tr.shade td.shade {
-  background-color: </xsl:text><xsl:value-of select="$theme.color.dark_background"/><xsl:text>;
+  background-color: </xsl:text><xsl:value-of select="$color.dark_background"/><xsl:text>;
 }
 
 span.app { font-style: italic; }
 span.cmd {
   font-family: monospace;
   background-color: </xsl:text>
-    <xsl:value-of select="$theme.color.gray_background"/><xsl:text>;
+    <xsl:value-of select="$color.gray_background"/><xsl:text>;
   padding: 0 0.2em 0 0.2em;
 }
 span.cmd span.cmd { background-color: none; padding: 0; }
 pre span.cmd { background-color: none; padding: 0; }
 span.code {
   font-family: monospace;
-  border-bottom: solid 1px </xsl:text><xsl:value-of select="$theme.color.dark_background"/><xsl:text>;
+  border-bottom: solid 1px </xsl:text><xsl:value-of select="$color.dark_background"/><xsl:text>;
 }
 span.code span.code { border: none; }
 pre span.code { border: none; }
 span.em { font-style: italic; }
 span.em-bold {
   font-style: normal; font-weight: bold;
-  color: </xsl:text><xsl:value-of select="$theme.color.text_light"/><xsl:text>;
+  color: </xsl:text><xsl:value-of select="$color.text_light"/><xsl:text>;
 }
 pre span.error {
-  color: </xsl:text><xsl:value-of select="$theme.color.text_error"/><xsl:text>;
+  color: </xsl:text><xsl:value-of select="$color.text_error"/><xsl:text>;
 }
 span.file { font-family: monospace; }
 span.gui, span.guiseq { color: </xsl:text>
-  <xsl:value-of select="$theme.color.text_light"/><xsl:text>; }
+  <xsl:value-of select="$color.text_light"/><xsl:text>; }
 span.input { font-family: monospace; }
 pre span.input {
   font-weight: bold;
-  color: </xsl:text><xsl:value-of select="$theme.color.text_light"/><xsl:text>;
+  color: </xsl:text><xsl:value-of select="$color.text_light"/><xsl:text>;
 }
 span.key {
   color: </xsl:text>
-    <xsl:value-of select="$theme.color.text_light"/><xsl:text>;
+    <xsl:value-of select="$color.text_light"/><xsl:text>;
   border: solid 1px </xsl:text>
-    <xsl:value-of select="$theme.color.yellow_border"/><xsl:text>;
+    <xsl:value-of select="$color.yellow_border"/><xsl:text>;
   padding: 0 0.2em 0 0.2em;
 }
 span.keyseq {
   color: </xsl:text>
-    <xsl:value-of select="$theme.color.text_light"/><xsl:text>;
+    <xsl:value-of select="$color.text_light"/><xsl:text>;
 }
 span.output { font-family: monospace; }
 pre span.output {
-  color: </xsl:text><xsl:value-of select="$theme.color.text"/><xsl:text>;
+  color: </xsl:text><xsl:value-of select="$color.text"/><xsl:text>;
 }
 pre span.prompt {
-  color: </xsl:text><xsl:value-of select="$theme.color.text_light"/><xsl:text>;
+  color: </xsl:text><xsl:value-of select="$color.text_light"/><xsl:text>;
 }
 span.sys { font-family: monospace; }
 span.var { font-style: italic; }
@@ -553,6 +691,7 @@ span.var { font-style: italic; }
 html.css.custom
 Stub to output custom CSS common to all HTML transformations.
 :Stub: true
+:Revision: version="1.0" date="2010-05-25" status="final"
 $direction: The directionality of the text, either #{ltr} or #{rtl}.
 $left: The starting alignment, either #{left} or #{right}.
 $right: The ending alignment, either #{left} or #{right}.
diff --git a/xslt/common/utils.xsl b/xslt/common/utils.xsl
index 55315d5..03c5d8b 100644
--- a/xslt/common/utils.xsl
+++ b/xslt/common/utils.xsl
@@ -20,18 +20,22 @@ Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
                 version="1.0">
 
 <!--!!==========================================================================
-Common XSLT Utilities
+Utilities
+Common XSLT Utilities.
+:Revision:version="1.0" date="2010-05-25" status="final"
 
-REMARK: Describe this module
+This stylesheet contains various useful utilities that are used throughout
+the Yelp stylesheets.
 -->
 
 
 <!--**==========================================================================
 utils.strip_newlines
-Strips leading or trailing newlines from a string
-$string: The string to strip newlines from
-$leading: Whether to strip leading newlines
-$trailing: Whether to strip trailing newlines
+Strip leading or trailing newlines from a string.
+:Revision:version="1.0" date="2010-05-25" status="final"
+$string: The string to strip newlines from.
+$leading: Whether to strip leading newlines.
+$trailing: Whether to strip trailing newlines.
 
 This template strips at most one leading and one trailing newline from
 ${string}.  This is useful for preformatted block elements where leading and
diff --git a/xslt/mallard/html/mal2html-css.xsl b/xslt/mallard/html/mal2html-css.xsl
index a364bdb..b333e2d 100644
--- a/xslt/mallard/html/mal2html-css.xsl
+++ b/xslt/mallard/html/mal2html-css.xsl
@@ -24,6 +24,10 @@ Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
                 extension-element-prefixes="exsl"
                 version="1.0">
 
+<!--!!==========================================================================
+Mallard to HTML - CSS
+-->
+
 <xsl:template mode="html.css.mode" match="mal:page">
   <xsl:param name="direction">
     <xsl:call-template name="l10n.direction"/>
@@ -59,26 +63,26 @@ a.navbar-prev::before {
   <xsl:when test="$left = 'left'"><xsl:text>&#x25C0;&#x00A0;&#x00A0;</xsl:text></xsl:when>
   <xsl:otherwise><xsl:text>&#x25B6;&#x00A0;&#x00A0;</xsl:text></xsl:otherwise>
   </xsl:choose><xsl:text>';
-  color: </xsl:text><xsl:value-of select="$theme.color.text_light"/><xsl:text>;
+  color: </xsl:text><xsl:value-of select="$color.text_light"/><xsl:text>;
 }
 a.navbar-next::after {
   content: '</xsl:text><xsl:choose>
   <xsl:when test="$left = 'left'"><xsl:text>&#x00A0;&#x00A0;&#x25B6;</xsl:text></xsl:when>
   <xsl:otherwise><xsl:text>&#x00A0;&#x00A0;&#x25C0;</xsl:text></xsl:otherwise>
   </xsl:choose><xsl:text>';
-  color: </xsl:text><xsl:value-of select="$theme.color.text_light"/><xsl:text>;
+  color: </xsl:text><xsl:value-of select="$color.text_light"/><xsl:text>;
 }
 div.copyrights {
   text-align: center;
   color: </xsl:text>
-    <xsl:value-of select="$theme.color.text_light"/><xsl:text>;
+    <xsl:value-of select="$color.text_light"/><xsl:text>;
 }
 
 div.autolinks ul { margin: 0; padding: 0; }
 div.autolinks div.title { margin: 1em 0 0 1em; }
 div.autolinks div.title span {
   border-bottom: solid 1px </xsl:text>
-    <xsl:value-of select="$theme.color.gray_border"/><xsl:text>;
+    <xsl:value-of select="$color.gray_border"/><xsl:text>;
 }
 li.autolink { margin: 0.5em 0 0 0; padding: 0 0 0 1em; list-style-type: none; }
 
@@ -99,32 +103,32 @@ div.linkdiv {
   padding: 0.5em;
   -moz-border-radius: 6px;
   border: solid 1px </xsl:text>
-    <xsl:value-of select="$theme.color.background"/><xsl:text>;
+    <xsl:value-of select="$color.background"/><xsl:text>;
 }
 div.linkdiv:hover {
   border-color: </xsl:text>
-    <xsl:value-of select="$theme.color.blue_border"/><xsl:text>;
+    <xsl:value-of select="$color.blue_border"/><xsl:text>;
   background-color: </xsl:text>
-    <xsl:value-of select="$theme.color.blue_background"/><xsl:text>;
+    <xsl:value-of select="$color.blue_background"/><xsl:text>;
 }
 div.linkdivsep {
   margin: 0.5em;
   list-style-type: none;
   max-width: 24em;
   border-bottom: solid 1px </xsl:text>
-    <xsl:value-of select="$theme.color.gray_border"/><xsl:text>;
+    <xsl:value-of select="$color.gray_border"/><xsl:text>;
 }
 
 
 div.example {
   border-</xsl:text><xsl:value-of select="$left"/><xsl:text>: solid 4px </xsl:text>
-    <xsl:value-of select="$theme.color.gray_border"/><xsl:text>;
+    <xsl:value-of select="$color.gray_border"/><xsl:text>;
   padding-</xsl:text><xsl:value-of select="$left"/><xsl:text>: 1em;
 }
 
 div.cite-comment {
   margin-top: 0.5em;
-  color: </xsl:text><xsl:value-of select="$theme.color.text_light"/><xsl:text>;
+  color: </xsl:text><xsl:value-of select="$color.text_light"/><xsl:text>;
 }
 
 
@@ -139,7 +143,7 @@ div.tree-lines ul.tree { margin-left: 0; }
 
 span.hi {
   background-color: </xsl:text>
-    <xsl:value-of select="$theme.color.yellow_background"/><xsl:text>;
+    <xsl:value-of select="$color.yellow_background"/><xsl:text>;
 }
 </xsl:text>
 <xsl:if test="$mal2html.editor_mode">
@@ -153,9 +157,9 @@ div.version {
   max-width: 24em;
   -moz-border-radius: 6px;
   border: solid 1px </xsl:text>
-    <xsl:value-of select="$theme.color.gray_border"/><xsl:text>;
+    <xsl:value-of select="$color.gray_border"/><xsl:text>;
   background-color: </xsl:text>
-    <xsl:value-of select="$theme.color.yellow_background"/><xsl:text>;
+    <xsl:value-of select="$color.yellow_background"/><xsl:text>;
 }
 div.version:hover { opacity: 0.8; }
 div.version p.version { margin-top: 0.2em; }
@@ -165,29 +169,29 @@ div.linkdiv div.title span.status {
   padding-left: 0.2em;
   padding-right: 0.2em;
   color: </xsl:text>
-    <xsl:value-of select="$theme.color.text_light"/><xsl:text>;
+    <xsl:value-of select="$color.text_light"/><xsl:text>;
   border: solid 1px </xsl:text>
-    <xsl:value-of select="$theme.color.red_border"/><xsl:text>;
+    <xsl:value-of select="$color.red_border"/><xsl:text>;
 }
 div.linkdiv div.title span.status-stub { background-color: </xsl:text>
-  <xsl:value-of select="$theme.color.red_background"/><xsl:text>; }
+  <xsl:value-of select="$color.red_background"/><xsl:text>; }
 div.linkdiv div.title span.status-draft { background-color: </xsl:text>
-  <xsl:value-of select="$theme.color.red_background"/><xsl:text>; }
+  <xsl:value-of select="$color.red_background"/><xsl:text>; }
 div.linkdiv div.title span.status-incomplete { background-color: </xsl:text>
-  <xsl:value-of select="$theme.color.red_background"/><xsl:text>; }
+  <xsl:value-of select="$color.red_background"/><xsl:text>; }
 div.linkdiv div.title span.status-review { background-color: </xsl:text>
-  <xsl:value-of select="$theme.color.yellow_background"/><xsl:text>; }
+  <xsl:value-of select="$color.yellow_background"/><xsl:text>; }
 div.linkdiv div.desc {
   margin-top: 0.2em;
   color: </xsl:text>
-    <xsl:value-of select="$theme.color.text_light"/><xsl:text>;
+    <xsl:value-of select="$color.text_light"/><xsl:text>;
 }
 div.comment {
   padding: 0.5em;
   border: solid 2px </xsl:text>
-    <xsl:value-of select="$theme.color.red_border"/><xsl:text>;
+    <xsl:value-of select="$color.red_border"/><xsl:text>;
   background-color: </xsl:text>
-    <xsl:value-of select="$theme.color.red_background"/><xsl:text>;
+    <xsl:value-of select="$color.red_background"/><xsl:text>;
 }
 div.comment div.comment {
   margin: 1em 1em 0 1em;
diff --git a/xslt/mallard/html/mal2html-page.xsl b/xslt/mallard/html/mal2html-page.xsl
index bd85a30..dc3dbf1 100644
--- a/xslt/mallard/html/mal2html-page.xsl
+++ b/xslt/mallard/html/mal2html-page.xsl
@@ -528,12 +528,6 @@ REMARK: Describe this template
 
 <!-- == Matched Templates == -->
 
-<!-- = / = -->
-<xsl:template match="/">
-  <xsl:call-template name="html.output">
-    <xsl:with-param name="node" select="*"/>
-  </xsl:call-template>
-</xsl:template>
 
 <xsl:template mode="html.title.mode" match="mal:page">
   <xsl:variable name="title" select="mal:info/mal:title[ type = 'text'][1]"/>
diff --git a/xslt/mallard/html/mal2xhtml.xsl b/xslt/mallard/html/mal2xhtml.xsl
index 6bd1057..b1f8468 100644
--- a/xslt/mallard/html/mal2xhtml.xsl
+++ b/xslt/mallard/html/mal2xhtml.xsl
@@ -30,13 +30,12 @@ REMARK: Describe this module
 -->
 
 <xsl:import href="../../gettext/gettext.xsl"/>
+<xsl:import href="../../common/colors.xsl"/>
+<xsl:import href="../../common/icons.xsl"/>
 <xsl:import href="../../common/html.xsl"/>
-<xsl:import href="../common/mal-link.xsl"/>
-
 <xsl:import href="../../common/utils.xsl"/>
-<xsl:import href="../../theme/theme-colors.xsl"/>
-<xsl:import href="../../theme/theme-icons.xsl"/>
-<xsl:import href="../../theme/theme-html.xsl"/>
+
+<xsl:import href="../common/mal-link.xsl"/>
 
 <xsl:param name="mal.link.extension" select="$html.extension"/>
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]