]> granicus.if.org Git - docbook-dsssl/commitdiff
Nearly complete rewrite; this will become V3.0
authorNorman Walsh <ndw@nwalsh.com>
Tue, 25 Jun 2002 13:58:12 +0000 (13:58 +0000)
committerNorman Walsh <ndw@nwalsh.com>
Tue, 25 Jun 2002 13:58:12 +0000 (13:58 +0000)
62 files changed:
slides/Makefile
slides/browser/overlay.js
slides/browser/slides-default.css [new file with mode: 0644]
slides/browser/slides-frames.css [new file with mode: 0644]
slides/browser/slides-plain.css [new file with mode: 0644]
slides/browser/slides-table.css [new file with mode: 0644]
slides/browser/slides-w3c.css [new file with mode: 0644]
slides/browser/slides.css
slides/graphics/active/arr-next.png [new file with mode: 0644]
slides/graphics/active/arr-prev.png [new file with mode: 0644]
slides/graphics/active/but-fforward.png [moved from slides/graphics/but-fforward.png with 100% similarity]
slides/graphics/active/but-info.png [moved from slides/graphics/but-info.png with 100% similarity]
slides/graphics/active/but-next.png [moved from slides/graphics/but-next.png with 100% similarity]
slides/graphics/active/but-prev.png [moved from slides/graphics/but-prev.png with 100% similarity]
slides/graphics/active/but-rewind.png [moved from slides/graphics/but-rewind.png with 100% similarity]
slides/graphics/active/nav-home.png [new file with mode: 0644]
slides/graphics/active/nav-next.png [new file with mode: 0644]
slides/graphics/active/nav-prev.png [new file with mode: 0644]
slides/graphics/active/nav-toc.png [new file with mode: 0644]
slides/graphics/active/nav-up.png [new file with mode: 0644]
slides/graphics/active/w3c-next.png [moved from slides/graphics/right.png with 100% similarity]
slides/graphics/active/w3c-prev.png [moved from slides/graphics/left.png with 100% similarity]
slides/graphics/active/w3c-toc.png [moved from slides/graphics/toc.png with 100% similarity]
slides/graphics/blank.png
slides/graphics/bullet.gif [deleted file]
slides/graphics/inactive/but-fforward.png [moved from slides/graphics/but-xfforward.png with 100% similarity]
slides/graphics/inactive/but-info.png [new file with mode: 0644]
slides/graphics/inactive/but-next.png [moved from slides/graphics/but-xnext.png with 100% similarity]
slides/graphics/inactive/but-prev.png [moved from slides/graphics/but-xprev.png with 100% similarity]
slides/graphics/inactive/but-rewind.png [moved from slides/graphics/but-xrewind.png with 100% similarity]
slides/graphics/inactive/nav-home.png [new file with mode: 0644]
slides/graphics/inactive/nav-next.png [new file with mode: 0644]
slides/graphics/inactive/nav-prev.png [new file with mode: 0644]
slides/graphics/inactive/nav-toc.png [new file with mode: 0644]
slides/graphics/inactive/nav-up.png [new file with mode: 0644]
slides/graphics/inactive/w3c-next.png [moved from slides/graphics/bright.png with 100% similarity]
slides/graphics/inactive/w3c-prev.png [moved from slides/graphics/bleft.png with 100% similarity]
slides/graphics/inactive/w3c-toc.png [new file with mode: 0644]
slides/graphics/left.gif [deleted file]
slides/graphics/minus.gif [deleted file]
slides/graphics/plus.gif
slides/graphics/pointer.png [new file with mode: 0644]
slides/graphics/right.gif [deleted file]
slides/graphics/toc/bullet.png [new file with mode: 0644]
slides/graphics/toc/closed.png [new file with mode: 0644]
slides/graphics/toc/open.png [new file with mode: 0644]
slides/slides-custom.dtd
slides/slides.mod
slides/tests/dbgentext.xml
slides/tests/minimal.xml [new file with mode: 0644]
slides/tests/test-full.xml
slides/tests/testhtml.xml
slides/xsl/default.xsl [new file with mode: 0644]
slides/xsl/frames.xsl
slides/xsl/graphics.xsl
slides/xsl/param.xweb
slides/xsl/plain.xsl [new file with mode: 0644]
slides/xsl/slides-common.xsl [new file with mode: 0644]
slides/xsl/slides.xsl [deleted file]
slides/xsl/tables.xsl
slides/xsl/vslides.xsl
slides/xsl/w3c.xsl

index 9e9eda0841f6ec479004d6a95a299ccf844da4fb..dc48b97de5bbd40a65ce10d2089d8be1eb9175a4 100644 (file)
@@ -5,7 +5,7 @@ NEWVER=
 
 all: slides.dtd
 
-slides.dtd: slides-custom.dtd
+slides.dtd: slides-custom.dtd slides.mod
        $(FLATTEN) $< > $@
 
 check:
index 644bb5b960f935d3d3d12b3459495ccd6b0b3614..9b52d9b7ce1cc6bd852f6081c01d7cac70beff84 100644 (file)
@@ -19,7 +19,7 @@ var overlayIE  = document.all ? 1 : 0;
 var overlayNS6 = document.getElementById && !document.all ? 1 : 0;
 
 var overlayPadX = 15;
-var overlayPadY = 5;
+var overlayPadY = 15;
 var overlayDelay = 60;
 
 var overlayCorner = 'ur'; // ul, ll, ur, lr, uc, lc, cl, cr
@@ -47,19 +47,21 @@ function overlayRefresh() {
         }
 
        overlayH  = overlayDiv.offsetHeight;
-       overlayW  = overlayDiv.offsetWidth;
+       overlayW  = body.offsetWidth; // overlayDiv.offsetWidth;
        contentH  = body.offsetHeight;
     } else if (overlayNS4) {
        overlayLy = window.innerHeight;
        overlayLx = window.innerWidth;
        overlayH  = document.overlayDiv.clip.height;
-       overlayW  = document.overlayDiv.clip.width;
+       overlayW  = body.clip.width; // document.overlayDiv.clip.width;
        contentH  = body.clip.height;
     } else if (overlayNS6) {
+       var odiv = document.getElementById('overlayDiv');
+
        overlayLy = window.innerHeight;
        overlayLx = window.innerWidth;
-       overlayH  = document.getElementById('overlayDiv').offsetHeight;
-       overlayW  = document.getElementById('overlayDiv').offsetWidth;
+       overlayH  = odiv.offsetHeight;
+       overlayW  = body.offsetWidth; // odiv.offsetWidth;
        contentH  = body.offsetHeight;
     }
 
@@ -108,9 +110,11 @@ function overlayRefresh() {
        var div = document.getElementById("overlayDiv");
        var leftpx = overlayX;
        var toppx = overlayY+window.pageYOffset;
+       var widthpx = overlayW;
 
        div.style.left = leftpx + "px";
        div.style.top = toppx + "px";
+       div.style.width = widthpx + "px";
 
        if (contentH > overlayLy) {
            div.style.visibility = "hidden";
diff --git a/slides/browser/slides-default.css b/slides/browser/slides-default.css
new file mode 100644 (file)
index 0000000..1022d6b
--- /dev/null
@@ -0,0 +1,9 @@
+@import url('slides.css');
+
+.toclink { font-size: 10pt;
+             font-weight: normal;
+           }
+
+.toclink a         { color: blue; }
+.toclink a:link    { color: blue; }
+.toclink a:visited { color: blue; }
diff --git a/slides/browser/slides-frames.css b/slides/browser/slides-frames.css
new file mode 100644 (file)
index 0000000..47d6f8f
--- /dev/null
@@ -0,0 +1,73 @@
+@import url('slides.css');
+
+.toc-body             { margin-left: 2px;
+                        margin-right: 2px;
+                      }
+
+.foil-body            { margin-left: 2px;
+                        margin-right: 2px;
+                      }
+
+h1.title              { margin-top: 0px;
+                        padding-top: 0px;
+                      }
+
+.navhead              { display: visible;
+                      }
+
+.navfoot              { display: visible;
+                      }
+
+/* ====================================================================== */
+
+.navfoot              { border-top: 1px solid black;
+                        margin-top: 10px;
+                        padding-top: 4px;
+                      }
+/* ====================================================================== */
+
+.toc                  { font-weight: bold;
+                        font-size: 10pt;
+                      }
+
+.toc a                { text-decoration: none; }
+.toc a:link           { color: blue; }
+.toc a:visited        { color: blue; }
+
+.toc .toc-foilgroup a         { color: red; }
+.toc .toc-foilgroup a:link    { color: red; }
+.toc .toc-foilgroup a:visited { color: red; }
+
+.toc .toc-titlefoil a         { color: black; }
+.toc .toc-titlefoil a:link    { color: black; }
+.toc .toc-titlefoil a:visited { color: black; }
+
+.toc .toc-foil a         { color: blue; }
+.toc .toc-foil a:link    { color: blue; }
+.toc .toc-foil a:visited { color: blue; }
+
+.toc-slidesinfo       { font-family: sans-serif;
+                        font-weight: bold;
+                        text-align: center;
+                      }
+
+.toc-titlefoil        { font-family: sans-serif;
+                        font-weight: bold;
+                        text-align: center;
+                      }
+
+.toc-foilgroup        { font-family: sans-serif;
+                        margin-left: 0.25in;
+                        text-indent: -0.25in;
+                       font-weight: bold;
+                        color: red;
+                      }
+
+.toc-foil             { font-family: sans-serif;
+                        font-size: 10pt;
+                        margin-left: 0.25in;
+                        text-indent: -0.4in;
+                       font-weight: bold;
+                        color: blue;
+                      }
+
diff --git a/slides/browser/slides-plain.css b/slides/browser/slides-plain.css
new file mode 100644 (file)
index 0000000..c22f289
--- /dev/null
@@ -0,0 +1 @@
+@import url('slides.css');
diff --git a/slides/browser/slides-table.css b/slides/browser/slides-table.css
new file mode 100644 (file)
index 0000000..1c195c9
--- /dev/null
@@ -0,0 +1,41 @@
+@import url('slides.css');
+
+.toc-body             { margin-left: 2px;
+                        margin-right: 2px;
+                      }
+
+.foil-body            { margin-left: 2px;
+                        margin-right: 2px;
+                      }
+
+.foilgroup-body       { margin-left: 2px;
+                        margin-right: 2px;
+                      }
+
+h1.title              { 
+                        margin-top: 0px;
+                        padding-top: 0px;
+                      }
+
+/* ToC Stuff */
+
+.ttoc                 {
+                        font-size: 10pt;
+                       color: white;
+                      }
+
+.ttoc a               { text-decoration: none; }
+.ttoc a:link          { color: white }
+.ttoc a:visited       { color: white }
+
+.ttoc-title           {
+                        font-size: 10pt;
+                      }
+
+.ttoc-foilset         {
+                        font-size: 10pt;
+                      }
+
+.ttoc-foil            {
+                        font-size: 10pt;
+                      }
diff --git a/slides/browser/slides-w3c.css b/slides/browser/slides-w3c.css
new file mode 100644 (file)
index 0000000..c22f289
--- /dev/null
@@ -0,0 +1 @@
+@import url('slides.css');
index 85de086fe9e490a17d737cc57a0c50db3476d8ab..0febaa46598e846db474ea3fac3c5c470770fe45 100644 (file)
-.slidesinfo           { text-align: center }
-.slidesinfo h1.title  { color: blue;
-                        font-family: Arial;
+/* General formatting */
+
+body                  { font-family: sans-serif;
                         font-weight: bold;
                       }
+
+.copyright            { color: #7F7F7F;
+                      }
+
+/* Title page formatting */
+
+.slidesinfo           { text-align: center; }
+
+.slidesinfo h1.title  { color: blue;
+                      }
+
 .slidesinfo h1.author { color: green;
                       }
 
-.section              { font-family: sans-serif;
-                        font-size: 14pt;
-                        font-weight: bold;
+.slidesinfo .copyright { color: black;
                       }
-.section   h1.title   { text-align: center;
-                        color: red;
-                        font-family: Arial;
+
+
+/* ToC page formatting */
+
+.tocpage h1.title     { color: blue;
+                       text-align: center;
                       }
-.foil                 { font-family: sans-serif;
-                        font-size: 14pt;
-                        font-weight: bold;
+
+.tocpage a            { text-decoration: none; }
+.tocpage a:link       { color: blue; }
+.tocpage a:visited    { color: blue; }
+
+.toc-body             { margin-left: 0.5in;
+                        margin-right: 0.5in;
+                      }
+
+/* Foil page formatting */
+
+.foil                 { font-size: 16pt;
                       }
-.foil      h1.title   { text-align: center;
+.foil h1.title        { text-align: center;
                         color: blue;
-                        font-family: Arial;
                        padding-top: 0pt;
                        margin-top: 0pt;
                       }
-.foil      h2.subtitle   { text-align: center;
+.foil h2.subtitle     { text-align: center;
                         color: blue;
-                        font-family: Arial;
                        padding-top: 0pt;
                        margin-top: 0pt;
                       }
 
-.mediaobject          { text-align: center;
+.foil pre             { font-size: 18pt;
                       }
 
-/* ====================================================================== */
-
-span.navheader        { font-family: sans-serif;
-                        font-size: 10pt;
-                        font-weight: bold;
-                        color: black;
+.foil-body            { margin-left: 0.5in;
+                        margin-right: 0.5in;
                       }
 
-span.navfooter        { font-family: sans-serif;
-                        font-size: 8pt;
-                      }
-
-/* ====================================================================== */
+/* Foilgroup page formatting */
 
-.toc                  { font-weight: bold;
-                        font-size: 10pt;
+.foilgroup            { font-size: 16pt;
                       }
-
-.toc a                { text-decoration: none; }
-.toc a:link           { color: blue; }
-.toc a:visited        { color: blue; }
-
-.toc .toc-section a         { color: red; }
-.toc .toc-section a:link    { color: red; }
-.toc .toc-section a:visited { color: red; }
-
-.toc .toc-titlefoil a         { color: black; }
-.toc .toc-titlefoil a:link    { color: black; }
-.toc .toc-titlefoil a:visited { color: black; }
-
-.toc .toc-foil a         { color: blue; }
-.toc .toc-foil a:link    { color: blue; }
-.toc .toc-foil a:visited { color: blue; }
-
-.toc-slidesinfo       { font-family: sans-serif;
-                        font-weight: bold;
-                        text-align: center;
-                      }
-
-.toc-titlefoil        { font-family: sans-serif;
-                        font-weight: bold;
-                        text-align: center;
-                      }
-
-.toc-section          { font-family: sans-serif;
-                        margin-left: 0.25in;
-                        text-indent: -0.25in;
-                       font-weight: bold;
+.foilgroup h1.title   { text-align: center;
                         color: red;
+                       padding-top: 0pt;
+                       margin-top: 0pt;
                       }
-
-.toc-foil             { font-family: sans-serif;
-                        font-size: 10pt;
-                        margin-left: 0.25in;
-                        text-indent: -0.4in;
-                       font-weight: bold;
+.foilgroup h2.subtitle { text-align: center;
                         color: blue;
+                       padding-top: 0pt;
+                       margin-top: 0pt;
                       }
 
-/* ====================================================================== */
-
-.ttoc                 {
-                        font-size: 10pt;
-                       color: white;
+.foilgroup-body       { margin-left: 0.5in;
+                        margin-right: 0.5in;
                       }
 
-.ttoc a               { text-decoration: none; }
-.ttoc a:link          { color: white }
-.ttoc a:visited       { color: white }
+/* Navigation header formatting */
 
-.ttoc-title           {
-                        font-size: 10pt;
+.navhead              { border-bottom: 1px solid black;
+                        margin-bottom: 10px;
+                        padding-bottom: 4px;
                       }
 
-.ttoc-section         {
+.navhead hr.top-nav-sep { display: none; }
+
+.navhead .slidestitle { font-weight: normal;
                         font-size: 10pt;
+                        font-style: italic;
                       }
 
-.ttoc-foil            {
-                        font-size: 10pt;
+/* Navigation footer formatting */
+
+.navfoot              { border-top: 1px solid black;
+                        margin-top: 10px;
+                        padding-top: 4px;
                       }
 
-/* ====================================================================== */
+.navfoot hr.bottom-nav-sep { display: none; }
 
-body.topnavigation       { margin-top: 5px;
-                           margin-left: 10px;
-                           margin-right: 10px;
-                         }
+/* General navigation formatting */
 
-body.foil                { margin-top: 5px;
-                           margin-left: 10px;
-                           margin-right: 10px;
-                         }
+.link-text            { font-weight: bold
+                        font-size: 10pt;
+                      }
 
-body.botnavigation       { margin-top: 0px;
-                           padding-top: 0px;
-                           margin-left: 10px;
-                           margin-right: 10px;
-                         }
 
-/* ====================================================================== */
+.link-text a          { text-decoration: none; }
+.link-text a:link     { color: blue; }
+.link-text a:visited  { color: blue; }
 
-div.vnav              {
-                        margin-top: 2in;
-                      }
+.no-link-text         { color: #7F7F7F; }
 
-/* ====================================================================== */
+/* EOF */
diff --git a/slides/graphics/active/arr-next.png b/slides/graphics/active/arr-next.png
new file mode 100644 (file)
index 0000000..c8b8674
Binary files /dev/null and b/slides/graphics/active/arr-next.png differ
diff --git a/slides/graphics/active/arr-prev.png b/slides/graphics/active/arr-prev.png
new file mode 100644 (file)
index 0000000..f94e27e
Binary files /dev/null and b/slides/graphics/active/arr-prev.png differ
diff --git a/slides/graphics/active/nav-home.png b/slides/graphics/active/nav-home.png
new file mode 100644 (file)
index 0000000..95fe6ee
Binary files /dev/null and b/slides/graphics/active/nav-home.png differ
diff --git a/slides/graphics/active/nav-next.png b/slides/graphics/active/nav-next.png
new file mode 100644 (file)
index 0000000..46aac7d
Binary files /dev/null and b/slides/graphics/active/nav-next.png differ
diff --git a/slides/graphics/active/nav-prev.png b/slides/graphics/active/nav-prev.png
new file mode 100644 (file)
index 0000000..e744535
Binary files /dev/null and b/slides/graphics/active/nav-prev.png differ
diff --git a/slides/graphics/active/nav-toc.png b/slides/graphics/active/nav-toc.png
new file mode 100644 (file)
index 0000000..9b1e0ba
Binary files /dev/null and b/slides/graphics/active/nav-toc.png differ
diff --git a/slides/graphics/active/nav-up.png b/slides/graphics/active/nav-up.png
new file mode 100644 (file)
index 0000000..8ad45eb
Binary files /dev/null and b/slides/graphics/active/nav-up.png differ
index 9467705354c844ba2b36ce9ce7810ef01fcd6deb..8c58c6b9496429c02a3cb2c6df99ed1ad887b4c2 100644 (file)
Binary files a/slides/graphics/blank.png and b/slides/graphics/blank.png differ
diff --git a/slides/graphics/bullet.gif b/slides/graphics/bullet.gif
deleted file mode 100644 (file)
index b1369de..0000000
Binary files a/slides/graphics/bullet.gif and /dev/null differ
diff --git a/slides/graphics/inactive/but-info.png b/slides/graphics/inactive/but-info.png
new file mode 100644 (file)
index 0000000..fdf1f1d
Binary files /dev/null and b/slides/graphics/inactive/but-info.png differ
diff --git a/slides/graphics/inactive/nav-home.png b/slides/graphics/inactive/nav-home.png
new file mode 100644 (file)
index 0000000..734845a
Binary files /dev/null and b/slides/graphics/inactive/nav-home.png differ
diff --git a/slides/graphics/inactive/nav-next.png b/slides/graphics/inactive/nav-next.png
new file mode 100644 (file)
index 0000000..1d32d67
Binary files /dev/null and b/slides/graphics/inactive/nav-next.png differ
diff --git a/slides/graphics/inactive/nav-prev.png b/slides/graphics/inactive/nav-prev.png
new file mode 100644 (file)
index 0000000..cfca206
Binary files /dev/null and b/slides/graphics/inactive/nav-prev.png differ
diff --git a/slides/graphics/inactive/nav-toc.png b/slides/graphics/inactive/nav-toc.png
new file mode 100644 (file)
index 0000000..d63483b
Binary files /dev/null and b/slides/graphics/inactive/nav-toc.png differ
diff --git a/slides/graphics/inactive/nav-up.png b/slides/graphics/inactive/nav-up.png
new file mode 100644 (file)
index 0000000..689af7e
Binary files /dev/null and b/slides/graphics/inactive/nav-up.png differ
diff --git a/slides/graphics/inactive/w3c-toc.png b/slides/graphics/inactive/w3c-toc.png
new file mode 100644 (file)
index 0000000..458539d
Binary files /dev/null and b/slides/graphics/inactive/w3c-toc.png differ
diff --git a/slides/graphics/left.gif b/slides/graphics/left.gif
deleted file mode 100644 (file)
index 8d04f7b..0000000
Binary files a/slides/graphics/left.gif and /dev/null differ
diff --git a/slides/graphics/minus.gif b/slides/graphics/minus.gif
deleted file mode 100644 (file)
index 49c68b1..0000000
Binary files a/slides/graphics/minus.gif and /dev/null differ
index 530b337c286c066ff891c3cace785667a0853d4a..3cd2b081a12fda77ca2c696d1842e9615dc753a1 100644 (file)
Binary files a/slides/graphics/plus.gif and b/slides/graphics/plus.gif differ
diff --git a/slides/graphics/pointer.png b/slides/graphics/pointer.png
new file mode 100644 (file)
index 0000000..35d4830
Binary files /dev/null and b/slides/graphics/pointer.png differ
diff --git a/slides/graphics/right.gif b/slides/graphics/right.gif
deleted file mode 100644 (file)
index 0026633..0000000
Binary files a/slides/graphics/right.gif and /dev/null differ
diff --git a/slides/graphics/toc/bullet.png b/slides/graphics/toc/bullet.png
new file mode 100644 (file)
index 0000000..3878b5b
Binary files /dev/null and b/slides/graphics/toc/bullet.png differ
diff --git a/slides/graphics/toc/closed.png b/slides/graphics/toc/closed.png
new file mode 100644 (file)
index 0000000..b99daf7
Binary files /dev/null and b/slides/graphics/toc/closed.png differ
diff --git a/slides/graphics/toc/open.png b/slides/graphics/toc/open.png
new file mode 100644 (file)
index 0000000..e96afe3
Binary files /dev/null and b/slides/graphics/toc/open.png differ
index 95f5df69af6181f5ffda951cd0fb4111cf9bc93e..6d56721cd0abdc8b0534e6bd68507d4c8348d545 100644 (file)
@@ -65,8 +65,8 @@
 <!ENTITY % local.divcomponent.mix "|speakernotes">
 <!ENTITY % local.component.mix "|speakernotes">
 
-<!ENTITY % sdocbook.dtd PUBLIC "-//OASIS//DTD Simplified DocBook XML V1.0b2//EN"
-      "http://www.oasis-open.org/docbook/xml/simple/1.0b2/sdocbook-custom.dtd">
+<!ENTITY % sdocbook.dtd PUBLIC "-//OASIS//DTD Simplified DocBook XML V1.0CR//EN"
+      "http://www.oasis-open.org/docbook/xml/simple/1.0CR2/sdocbook-custom.dtd">
 %sdocbook.dtd;
 
 <!-- ====================================================================== -->
index 17972b6197a0379594bdf6c61ff54040f20afade..e195639f381313bae399f36182a6e79d4e34d872 100644 (file)
@@ -10,7 +10,8 @@
                                                                             -->
 <!-- ====================================================================== -->
 
-<!ELEMENT slides (slidesinfo, speakernotes?, (foil+|section+))>
+<!ELEMENT slides (slidesinfo, speakernotes?, foil*, foilgroup*)>
+
 <!ATTLIST slides
                %label.attrib;
                %status.attrib;
                %role.attrib;
 >
 
-<!ELEMENT section (sectioninfo?, title, subtitle?, titleabbrev?,
-                   speakernotes?,
+<!ELEMENT foilgroup (foilgroupinfo?, title, subtitle?, titleabbrev?,
+                   (%divcomponent.mix;)*,
                    foil+)>
-<!ATTLIST section
+<!ATTLIST foilgroup
                %label.attrib;
                %status.attrib;
                %common.attrib;
                %role.attrib;
 >
 
-<!ELEMENT sectioninfo ((mediaobject
+<!ELEMENT foilgroupinfo ((mediaobject
                       | legalnotice
                        | subjectset | keywordset
                        | %bibliocomponent.mix;)+)>
 
-<!ATTLIST sectioninfo
+<!ATTLIST foilgroupinfo
                %common.attrib;
                %role.attrib;
 >
index 8ad77b81b056002b143b1538c49e37d8165b5d62..dec7e6551b851f501df882a1eb4e59db0b55ca46 100644 (file)
@@ -1,6 +1,6 @@
 <?xml version='1.0'?>
 <!DOCTYPE slides SYSTEM "../slides.dtd">
-<?dbhtml graphics-dir="../graphics" css-stylesheet="../browser/slides.css"?>
+<?dbhtml graphics-dir="../graphics" css-stylesheet-dir="../browser"?>
 <?dbhtml script-dir="../browser"?>
 <slides>
 <slidesinfo>
              <holder>Sun Microsystems, Inc.</holder></copyright>
 </slidesinfo>
 
-<section><title>The Problem</title>
+<foil><title>Introduction</title>
+<para>This is the introductory slide</para>
+</foil>
+
+<foilgroup><title>The Problem</title>
+
+<para>This is one the foilgroup slide.</para>
 
 <foil><title>Generated Text</title>
 <itemizedlist>
@@ -54,8 +60,8 @@ naturally
 </itemizedlist>
 </foil>
 
-</section>
-<section><title>A Solution</title>
+</foilgroup>
+<foilgroup><title>A Solution</title>
 
 <foil><title>The Old Solution</title>
 
@@ -114,8 +120,8 @@ is taken from an independently maintained lookup table:</para>
 </itemizedlist>
 </foil>
 
-</section>
-<section><title>A Better Solution</title>
+</foilgroup>
+<foilgroup><title>A Better Solution</title>
 
 <foil><title>Use Markup Templates</title>
 
@@ -176,9 +182,9 @@ subtitle of the component, respectively.</para>
 ]]></screen>
 </foil>
 
-</section>
+</foilgroup>
 
-<section><title>Resources</title>
+<foilgroup><title>Resources</title>
 <foil><title>Resources</title>
 <itemizedlist>
 <listitem><para><ulink url="http://www.oasis-open.org/docbook/"/>, the
@@ -195,5 +201,5 @@ queries.
 </para></listitem>
 </itemizedlist>
 </foil>
-</section>
+</foilgroup>
 </slides>
diff --git a/slides/tests/minimal.xml b/slides/tests/minimal.xml
new file mode 100644 (file)
index 0000000..e60b023
--- /dev/null
@@ -0,0 +1,12 @@
+<?xml version='1.0'?>
+<!DOCTYPE slides PUBLIC "-//Norman Walsh//DTD Slides XML V3.0b1//EN"
+                 "http://docbook.sourceforge.net/release/slides/3.0b1/slides.dtd">
+<slides>
+<slidesinfo>
+<title>Presentation Title</title>
+</slidesinfo>
+<foil><title>Foil Title</title>
+<para>Foil content</para>
+</foil>
+</slides>
+
index 155d8df227bbac907b1b821dc5a986beab0ef877..118fe96937c186006bc07a797fb6539b1851604f 100644 (file)
@@ -6,7 +6,7 @@
   <copyright><year>2001</year><holder>Norman Walsh</holder></copyright>
 </slidesinfo>
 
-<section><title>Section 1</title>
+<foilgroup><title>Section 1</title>
 
 <foil><title>Test Slides Title 1</title>
 <para>...<keycombo><keycap>X</keycap></keycombo></para>
@@ -19,8 +19,8 @@ this is a screen
 </screen>
 </foil>
 
-</section>
-<section><title>Section 2</title>
+</foilgroup>
+<foilgroup><title>Section 2</title>
 
 <foil><title>Test Slides Title 1</title>
 <para>...</para>
@@ -33,6 +33,6 @@ this is a screen
 </screen>
 </foil>
 
-</section>
+</foilgroup>
 
 </slides>
index 257a10d32ad45b569bd3d7e4f6f12f3344045978..3f6c771eb76eb19dca0167d587d2577ee0e249db 100644 (file)
@@ -2,7 +2,7 @@
 <?dbhtml graphics-dir="../graphics"?>
 <?dbhtml css-stylesheet="../browser/slides.css"?>
 <?dbhtml script-dir="../browser"?>
-<slides xmlns:html='http://www.w3.org/1999/xhtml'>
+<slides>
 <slidesinfo>
   <title>HTML Test Slides Title</title>
   <copyright><year>2001</year><holder>Norman Walsh</holder></copyright>
@@ -54,8 +54,10 @@ this is a screen
 this is a screen
 </screen>
 
+<html:div xmlns:html='http://www.w3.org/1999/xhtml'>
 <html:p>This foil contains some XHTML:</html:p>
 <html:ol><html:li>item 1</html:li><html:li>item 2</html:li></html:ol>
+</html:div>
 
 </foil>
 
diff --git a/slides/xsl/default.xsl b/slides/xsl/default.xsl
new file mode 100644 (file)
index 0000000..0f94a95
--- /dev/null
@@ -0,0 +1,261 @@
+<?xml version='1.0'?>
+<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+               version="1.0">
+
+<xsl:import href="slides-common.xsl"/>
+
+<xsl:output method="html"/>
+
+<xsl:param name="css.stylesheet" select="'slides-default.css'"/>
+
+<xsl:template name="top-nav">
+  <xsl:param name="home"/>
+  <xsl:param name="up"/>
+  <xsl:param name="next"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="tocfile" select="$toc.html"/>
+
+  <div class="navhead">
+    <table width="100%" border="0" cellpadding="0" cellspacing="0"
+           summary="Navigation">
+      <tr>
+        <xsl:call-template name="generate.toc.hide.show"/>
+        <td align="left" width="10%">
+          <xsl:choose>
+            <xsl:when test="$prev">
+              <a>
+                <xsl:attribute name="href">
+                  <xsl:apply-templates select="$prev" mode="filename"/>
+                </xsl:attribute>
+
+                <img alt="Prev" border="0">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="prev.image"/>
+                  </xsl:attribute>
+                </img>
+              </a>
+            </xsl:when>
+            <xsl:otherwise>&#160;</xsl:otherwise>
+          </xsl:choose>
+        </td>
+        <td align="center" width="80%">
+          <xsl:variable name="prestitle">
+            <xsl:value-of select="(/slides/slidesinfo/title
+                                  |/slides/title)[1]"/>
+          </xsl:variable>
+
+          <span class="navheader">
+            <xsl:value-of select="$prestitle"/>
+          </span>
+        </td>
+        <td align="right" width="10%">
+          <xsl:choose>
+            <xsl:when test="$next">
+              <a>
+                <xsl:attribute name="href">
+                  <xsl:apply-templates select="$next" mode="filename"/>
+                </xsl:attribute>
+
+                <img alt="Next" border="0">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="next.image"/>
+                  </xsl:attribute>
+                </img>
+              </a>
+            </xsl:when>
+            <xsl:otherwise>&#160;</xsl:otherwise>
+          </xsl:choose>
+        </td>
+      </tr>
+    </table>
+    <hr class="top-nav-sep"/>
+  </div>
+</xsl:template>
+
+<xsl:template name="bottom-nav">
+  <xsl:param name="home"/>
+  <xsl:param name="up"/>
+  <xsl:param name="next"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="tocfile" select="$toc.html"/>
+
+  <div class="navfoot">
+    <hr class="bottom-nav-sep"/>
+    <table width="100%" border="0" cellpadding="0" cellspacing="0"
+           summary="Navigation">
+      <tr>
+        <td align="left" width="80%" valign="top">
+          <span class="navfooter">
+            <xsl:apply-templates select="/slides/slidesinfo/copyright"
+                                 mode="slide.footer.mode"/>
+          </span>
+        </td>
+        <td align="right" width="20%" valign="top">
+          <span class="index">
+            <xsl:value-of select="count(preceding::foil)
+                                  + count(preceding::foilgroup)
+                                  + count(ancestor::foilgroup)
+                                  + 1"/>
+          </span>
+          <xsl:text>&#160;</xsl:text>
+        </td>
+      </tr>
+    </table>
+  </div>
+</xsl:template>
+
+<!-- ====================================================================== -->
+
+<xsl:template name="titlepage-top-nav">
+  <xsl:param name="home"/>
+  <xsl:param name="up"/>
+  <xsl:param name="next"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="tocfile" select="$toc.html"/>
+
+  <div class="navhead">
+    <table width="100%" border="0" cellpadding="0" cellspacing="0"
+           summary="Navigation">
+      <tr>
+        <td align="left" width="10%">
+          <span class="toclink">
+            <a href="{$toc.html}">
+              <xsl:call-template name="gentext">
+                <xsl:with-param name="key">TableofContents</xsl:with-param>
+              </xsl:call-template>
+            </a>
+          </span>
+        </td>
+        <td align="center" width="80%">
+          <xsl:text>&#160;</xsl:text>
+        </td>
+        <td align="right" width="10%">
+          <xsl:text>&#160;</xsl:text>
+        </td>
+      </tr>
+    </table>
+  </div>
+</xsl:template>
+
+<xsl:template name="titlepage-bottom-nav">
+  <xsl:param name="home"/>
+  <xsl:param name="up"/>
+  <xsl:param name="next"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="tocfile" select="$toc.html"/>
+
+  <div class="navfoot">
+    <table width="100%" border="0"
+           cellspacing="0" cellpadding="0"
+           summary="Navigation">
+      <tr>
+        <td align="left" width="80%" valign="top">
+          <span class="navfooter">
+            <xsl:apply-templates select="/slides/slidesinfo/copyright"
+                                 mode="slide.footer.mode"/>
+          </span>
+        </td>
+        <td align="right" width="20%" valign="top">
+          <a>
+            <xsl:attribute name="href">
+              <xsl:apply-templates select="(following::foilset|following::foil)[1]"
+                                   mode="filename"/>
+            </xsl:attribute>
+            <img alt="Next" border="0">
+              <xsl:attribute name="src">
+                <xsl:call-template name="next.image"/>
+              </xsl:attribute>
+            </img>
+          </a>
+        </td>
+      </tr>
+    </table>
+  </div>
+</xsl:template>
+
+<xsl:template name="toc-top-nav">
+  <xsl:param name="home"/>
+  <xsl:param name="up"/>
+  <xsl:param name="next"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="tocfile" select="$toc.html"/>
+
+  <div class="navhead">
+    <table width="100%" border="0" cellpadding="0" cellspacing="0"
+           summary="Navigation">
+      <tr>
+        <td align="left">
+          <xsl:text>&#160;</xsl:text>
+        </td>
+      </tr>
+    </table>
+  </div>
+</xsl:template>
+
+<xsl:template name="toc-bottom-nav">
+  <div class="navfoot">
+    <table width="100%" border="0"
+           cellspacing="0" cellpadding="0"
+           summary="Navigation">
+      <tr>
+        <td align="left" width="80%" valign="top">
+          <span class="navfooter">
+            <xsl:apply-templates select="/slides/slidesinfo/copyright"
+                                 mode="slides.footer.mode"/>
+          </span>
+        </td>
+        <td align="right" width="20%" valign="top">
+          <a href="{$titlefoil.html}">
+            <img alt="Next" border="0">
+              <xsl:attribute name="src">
+                <xsl:call-template name="next.image"/>
+              </xsl:attribute>
+            </img>
+          </a>
+        </td>
+      </tr>
+    </table>
+  </div>
+</xsl:template>
+
+<!-- ====================================================================== -->
+
+<xsl:template name="generate.toc.hide.show">
+  <xsl:if test="$toc.hide.show != 0">
+    <td>
+      <img hspace="4" alt="Hide/Show TOC">
+        <xsl:attribute name="src">
+          <xsl:call-template name="hidetoc.image"/>
+       </xsl:attribute>
+       <xsl:attribute name="onClick">
+          <xsl:text>toggletoc(this,</xsl:text>
+          <xsl:value-of select="$toc.width"/>
+          <xsl:text>,'</xsl:text>
+          <xsl:call-template name="hidetoc.image"/>
+          <xsl:text>','</xsl:text>
+          <xsl:call-template name="showtoc.image"/>
+          <xsl:text>');</xsl:text>
+        </xsl:attribute>
+      </img>
+    </td>
+  </xsl:if>
+</xsl:template>
+
+<!-- ====================================================================== -->
+
+<xsl:template match="@*" mode="copy">
+  <xsl:attribute name="{local-name(.)}">
+    <xsl:value-of select="."/>
+  </xsl:attribute>
+</xsl:template>
+
+<xsl:template match="html:*" xmlns:html='http://www.w3.org/1999/xhtml'>
+  <xsl:element name="{local-name(.)}" namespace="">
+    <xsl:apply-templates select="@*" mode="copy"/>
+    <xsl:apply-templates/>
+  </xsl:element>
+</xsl:template>
+
+<!-- ====================================================================== -->
+
+</xsl:stylesheet>
index 3082828c0f92d0642f1d1c0197e321c19f6ac575..01043293c303f562e75a9a34550997286ec474b0 100644 (file)
@@ -2,7 +2,13 @@
 <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
                 version="1.0">
 
-<xsl:import href="slides.xsl"/>
+<xsl:import href="slides-common.xsl"/>
+
+<xsl:param name="titlefoil.html" select="'titlepg.html'"/>
+
+<xsl:param name="css.stylesheet" select="'slides-frames.css'"/>
+
+<!-- ====================================================================== -->
 
 <xsl:template match="slides">
   <xsl:variable name="title">
@@ -15,7 +21,7 @@
       </xsl:otherwise>
     </xsl:choose>
   </xsl:variable>
-  <xsl:variable name="toc.rows" select="1+count(//section)+count(//foil)"/>
+  <xsl:variable name="toc.rows" select="1+count(//foilgroup)+count(//foil)"/>
   <xsl:variable name="toc.height" select="$toc.rows * $toc.row.height"/>
 
   <xsl:if test="$overlay != 0 and $multiframe != 0">
@@ -64,7 +70,7 @@
           <xsl:if test="$overlay != 0 or $keyboard.nav != 0
                         or $dynamic.toc != 0 or $active.toc != 0
                         or $overlay.logo != ''">
-            <script language="JavaScript1.2"/>
+            <script language="JavaScript1.2" type="text/javascript"/>
           </xsl:if>
 
           <xsl:if test="$keyboard.nav != 0 or $dynamic.toc != 0 or $active.toc != 0">
@@ -86,7 +92,7 @@
           </xsl:if>
 
           <xsl:if test="$dynamic.toc != 0">
-            <script language="JavaScript"><xsl:text>
+            <script language="JavaScript" type="text/javascript"><xsl:text>
 function init() {
   var width = </xsl:text>
 <xsl:value-of select="$toc.width"/>
@@ -120,7 +126,7 @@ function init() {
 
           <xsl:if test="$overlay.logo != ''">
             <xsl:attribute name="onload">
-              <xsl:text>overlaySetup('lc');</xsl:text>
+              <xsl:text>overlaySetup('ll');</xsl:text>
             </xsl:attribute>
           </xsl:if>
 
@@ -130,7 +136,7 @@ function init() {
               <xsl:value-of select="$overlay"/>
               <xsl:text>);</xsl:text>
               <xsl:if test="$overlay.logo != ''">
-                <xsl:text>overlaySetup('lc');</xsl:text>
+                <xsl:text>overlaySetup('ll');</xsl:text>
               </xsl:if>
             </xsl:attribute>
           </xsl:if>
@@ -159,7 +165,12 @@ function init() {
   <xsl:apply-templates/>
 </xsl:template>
 
+<!-- ====================================================================== -->
+
 <xsl:template match="slidesinfo">
+  <xsl:variable name="next" select="(following::foil
+                                    |following::foilgroup)[1]"/>
+
   <xsl:call-template name="write.chunk">
     <xsl:with-param name="indent" select="$output.indent"/>
     <xsl:with-param name="filename"
@@ -168,36 +179,169 @@ function init() {
       <html>
         <head>
           <title><xsl:value-of select="title"/></title>
+
           <link type="text/css" rel="stylesheet">
             <xsl:attribute name="href">
               <xsl:call-template name="css.stylesheet"/>
             </xsl:attribute>
           </link>
 
-          <link rel="next">
+          <xsl:call-template name="links">
+            <xsl:with-param name="next" select="$next"/>
+          </xsl:call-template>
+
+          <xsl:if test="$overlay != 0 or $keyboard.nav != 0
+                        or $dynamic.toc != 0 or $active.toc != 0">
+            <script language="JavaScript1.2" type="text/javascript"/>
+          </xsl:if>
+
+          <xsl:if test="$keyboard.nav != 0 or $dynamic.toc != 0 or $active.toc != 0">
+            <xsl:call-template name="ua.js"/>
+            <xsl:call-template name="xbDOM.js">
+              <xsl:with-param name="language" select="'JavaScript'"/>
+            </xsl:call-template>
+            <xsl:call-template name="xbStyle.js"/>
+            <xsl:call-template name="xbCollapsibleLists.js"/>
+            <xsl:call-template name="slides.js">
+              <xsl:with-param name="language" select="'JavaScript'"/>
+            </xsl:call-template>
+          </xsl:if>
+
+          <xsl:if test="$overlay != '0'">
+            <xsl:call-template name="overlay.js">
+              <xsl:with-param name="language" select="'JavaScript'"/>
+            </xsl:call-template>
+          </xsl:if>
+        </head>
+        <xsl:choose>
+          <xsl:when test="$multiframe != 0">
+            <xsl:apply-templates select="." mode="multiframe"/>
+          </xsl:when>
+          <xsl:otherwise>
+            <xsl:apply-templates select="." mode="singleframe"/>
+          </xsl:otherwise>
+        </xsl:choose>
+      </html>
+    </xsl:with-param>
+  </xsl:call-template>
+
+  <xsl:if test="$multiframe != 0">
+    <xsl:apply-templates select="." mode="multiframe-top"/>
+    <xsl:apply-templates select="." mode="multiframe-body"/>
+    <xsl:apply-templates select="." mode="multiframe-bottom"/>
+  </xsl:if>
+</xsl:template>
+
+<xsl:template match="slidesinfo" mode="multiframe">
+  <xsl:variable name="thisfoil">
+    <xsl:value-of select="$titlefoil.html"/>
+  </xsl:variable>
+
+  <frameset rows="{$multiframe.navigation.height},*,{$multiframe.navigation.height}" border="0" name="foil" framespacing="0">
+    <xsl:attribute name="onkeypress">
+      <xsl:text>navigate(event)</xsl:text>
+    </xsl:attribute>
+    <frame src="top-{$thisfoil}" name="top" marginheight="0" scrolling="no" frameborder="0">
+      <xsl:attribute name="onkeypress">
+        <xsl:text>navigate(event)</xsl:text>
+      </xsl:attribute>
+    </frame>
+    <frame src="body-{$thisfoil}" name="body" marginheight="0" frameborder="0">
+      <xsl:attribute name="onkeypress">
+        <xsl:text>navigate(event)</xsl:text>
+      </xsl:attribute>
+    </frame>
+    <frame src="bot-{$thisfoil}" name="bottom" marginheight="0" scrolling="no" frameborder="0">
+      <xsl:attribute name="onkeypress">
+        <xsl:text>navigate(event)</xsl:text>
+      </xsl:attribute>
+    </frame>
+    <noframes>
+      <body class="frameset">
+        <xsl:call-template name="body.attributes"/>
+        <p>
+          <xsl:text>Your browser doesn't support frames.</xsl:text>
+        </p>
+      </body>
+    </noframes>
+  </frameset>
+</xsl:template>
+
+<xsl:template match="slidesinfo" mode="multiframe-top">
+  <xsl:variable name="thisfoil">
+    <xsl:value-of select="$titlefoil.html"/>
+  </xsl:variable>
+
+  <xsl:variable name="next" select="(following::foil
+                                    |following::foilgroup)[1]"/>
+
+  <xsl:call-template name="write.chunk">
+    <xsl:with-param name="indent" select="$output.indent"/>
+    <xsl:with-param name="filename" select="concat($base.dir,'top-',$thisfoil)"/>
+    <xsl:with-param name="content">
+      <html>
+        <head>
+          <title>Navigation</title>
+          <link type="text/css" rel="stylesheet">
             <xsl:attribute name="href">
-              <xsl:apply-templates select="(following::section|following::foil)[1]"
-                                   mode="filename"/>
-            </xsl:attribute>
-            <xsl:attribute name="title">
-              <xsl:value-of select="(following::section|following::foil)[1]/title"/>
+              <xsl:call-template name="css.stylesheet"/>
             </xsl:attribute>
           </link>
 
-          <xsl:for-each select="../section">
-            <link rel="section">
-              <xsl:attribute name="href">
-                <xsl:apply-templates select="." mode="filename"/>
-              </xsl:attribute>
-              <xsl:attribute name="title">
-                <xsl:value-of select="title[1]"/>
-              </xsl:attribute>
-            </link>
-          </xsl:for-each>
+          <xsl:if test="$overlay != 0 or $keyboard.nav != 0
+                        or $dynamic.toc != 0 or $active.toc != 0">
+            <script language="JavaScript1.2" type="text/javascript"/>
+          </xsl:if>
+
+          <xsl:if test="$keyboard.nav != 0 or $dynamic.toc != 0 or $active.toc != 0">
+            <xsl:call-template name="ua.js"/>
+            <xsl:call-template name="xbDOM.js">
+              <xsl:with-param name="language" select="'JavaScript'"/>
+            </xsl:call-template>
+            <xsl:call-template name="xbStyle.js"/>
+            <xsl:call-template name="xbCollapsibleLists.js"/>
+            <xsl:call-template name="slides.js">
+              <xsl:with-param name="language" select="'JavaScript'"/>
+            </xsl:call-template>
+          </xsl:if>
+
+          <xsl:if test="$overlay != '0'">
+            <xsl:call-template name="overlay.js">
+              <xsl:with-param name="language" select="'JavaScript'"/>
+            </xsl:call-template>
+          </xsl:if>
+        </head>
+        <body class="topnavigation" bgcolor="{$multiframe.top.bgcolor}">
+          <xsl:call-template name="foil-top-nav">
+            <xsl:with-param name="next" select="$next"/>
+          </xsl:call-template>
+        </body>
+      </html>
+    </xsl:with-param>
+  </xsl:call-template>
+</xsl:template>
+
+<xsl:template match="slidesinfo" mode="multiframe-body">
+  <xsl:variable name="thisfoil">
+    <xsl:value-of select="$titlefoil.html"/>
+  </xsl:variable>
+
+  <xsl:call-template name="write.chunk">
+    <xsl:with-param name="indent" select="$output.indent"/>
+    <xsl:with-param name="filename" select="concat($base.dir,'body-',$thisfoil)"/>
+    <xsl:with-param name="content">
+      <html>
+        <head>
+          <title>Body</title>
+          <link type="text/css" rel="stylesheet">
+            <xsl:attribute name="href">
+              <xsl:call-template name="css.stylesheet"/>
+            </xsl:attribute>
+          </link>
 
           <xsl:if test="$overlay != 0 or $keyboard.nav != 0
                         or $dynamic.toc != 0 or $active.toc != 0">
-            <script language="JavaScript1.2"/>
+            <script language="JavaScript1.2" type="text/javascript"/>
           </xsl:if>
 
           <xsl:if test="$keyboard.nav != 0 or $dynamic.toc != 0 or $active.toc != 0">
@@ -218,116 +362,305 @@ function init() {
             </xsl:call-template>
           </xsl:if>
         </head>
-        <body class="titlepage">
-          <xsl:call-template name="body.attributes"/>
-          <xsl:choose>
-            <xsl:when test="$active.toc != 0">
-              <xsl:attribute name="onload">
-                <xsl:text>newPage('</xsl:text>
-                <xsl:value-of select="$titlefoil.html"/>
-                <xsl:text>',</xsl:text>
-                <xsl:value-of select="$overlay"/>
-                <xsl:text>);</xsl:text>
-              </xsl:attribute>
-            </xsl:when>
-            <xsl:when test="$overlay != 0">
-              <xsl:attribute name="onload">
-                <xsl:text>overlaySetup('lc');</xsl:text>
-              </xsl:attribute>
-            </xsl:when>
-          </xsl:choose>
+        <xsl:apply-templates select="." mode="singleframe"/>
+      </html>
+    </xsl:with-param>
+  </xsl:call-template>
+</xsl:template>
+
+<xsl:template match="slidesinfo" mode="multiframe-bottom">
+  <xsl:variable name="thisfoil">
+    <xsl:value-of select="$titlefoil.html"/>
+  </xsl:variable>
 
-          <xsl:if test="$keyboard.nav != 0">
-            <xsl:attribute name="onkeypress">
-              <xsl:text>navigate(event)</xsl:text>
+  <xsl:variable name="next" select="(following::foil
+                                    |following::foilgroup)[1]"/>
+
+  <xsl:call-template name="write.chunk">
+    <xsl:with-param name="indent" select="$output.indent"/>
+    <xsl:with-param name="filename" select="concat($base.dir,'bot-',$thisfoil)"/>
+    <xsl:with-param name="content">
+      <html>
+        <head>
+          <title>Navigation</title>
+          <link type="text/css" rel="stylesheet">
+            <xsl:attribute name="href">
+              <xsl:call-template name="css.stylesheet"/>
             </xsl:attribute>
+          </link>
+
+          <xsl:if test="$overlay != 0 or $keyboard.nav != 0
+                        or $dynamic.toc != 0 or $active.toc != 0">
+            <script language="JavaScript1.2" type="text/javascript"/>
           </xsl:if>
 
-          <div class="{name(.)}">
-            <xsl:apply-templates mode="titlepage.mode"/>
-          </div>
+          <xsl:if test="$keyboard.nav != 0 or $dynamic.toc != 0 or $active.toc != 0">
+            <xsl:call-template name="ua.js"/>
+            <xsl:call-template name="xbDOM.js">
+              <xsl:with-param name="language" select="'JavaScript'"/>
+            </xsl:call-template>
+            <xsl:call-template name="xbStyle.js"/>
+            <xsl:call-template name="xbCollapsibleLists.js"/>
+            <xsl:call-template name="slides.js">
+              <xsl:with-param name="language" select="'JavaScript'"/>
+            </xsl:call-template>
+          </xsl:if>
 
-          <xsl:choose>
-            <xsl:when test="$multiframe=0">
-              <div id="overlayDiv" class="navfoot">
-                <xsl:choose>
-                  <xsl:when test="$overlay != 0">
-                    <xsl:attribute name="style">
-                      <xsl:text>position:absolute;visibility:visible;</xsl:text>
-                    </xsl:attribute>
-                    <hr/>
-                  </xsl:when>
-                  <xsl:otherwise>
-                    <xsl:attribute name="style">
-                      <xsl:text>padding-top: 2in;</xsl:text>
-                    </xsl:attribute>
-                  </xsl:otherwise>
-                </xsl:choose>
-
-                <table width="100%" border="0"
-                       cellspacing="0" cellpadding="0"
-                       summary="Navigation">
-                  <tr>
-                    <td align="left" width="80%" valign="top">
-                      <span class="navfooter">
-                        <xsl:apply-templates select="/slides/slidesinfo/copyright"
-                                             mode="slide.navigation.mode"/>
-                      </span>
-                    </td>
-                    <td align="right" width="20%" valign="top">
-                      <a href="foil01.html">
-                        <img alt="Next" border="0">
-                          <xsl:attribute name="src">
-                            <xsl:call-template name="right.image"/>
-                          </xsl:attribute>
-                        </img>
-                      </a>
-                    </td>
-                  </tr>
-                </table>
-              </div>
-            </xsl:when>
-            <xsl:otherwise>
-              <div class="navfoot" style="padding-top: 2in;">
-                <table width="100%" border="0"
-                       cellspacing="0" cellpadding="0"
-                       summary="Navigation">
-                  <tr>
-                    <td align="center" width="100%" valign="top">
-                      <span class="navfooter">
-                        <xsl:apply-templates select="/slides/slidesinfo/copyright"
-                                             mode="slide.navigation.mode"/>
-                      </span>
-                    </td>
-                  </tr>
-                </table>
-              </div>
-            </xsl:otherwise>
-          </xsl:choose>
+          <xsl:if test="$overlay != '0'">
+            <xsl:call-template name="overlay.js">
+              <xsl:with-param name="language" select="'JavaScript'"/>
+            </xsl:call-template>
+          </xsl:if>
+        </head>
+        <body class="botnavigation" bgcolor="{$multiframe.bottom.bgcolor}">
+          <xsl:call-template name="foil-bottom-nav">
+            <xsl:with-param name="next" select="$next"/>
+          </xsl:call-template>
         </body>
       </html>
     </xsl:with-param>
   </xsl:call-template>
 </xsl:template>
 
-<xsl:template match="section">
+<xsl:template match="slidesinfo" mode="singleframe">
+  <xsl:param name="thisfoil">
+    <xsl:value-of select="$titlefoil.html"/>
+  </xsl:param>
+
   <xsl:variable name="id">
     <xsl:call-template name="object.id"/>
   </xsl:variable>
 
-  <xsl:variable name="snumber">
-    <xsl:number count="section" level="any"/>
-  </xsl:variable>
+  <xsl:variable name="next" select="(following::foil
+                                    |following::foilgroup)[1]"/>
 
-  <xsl:variable name="thissection">
-    <xsl:text>section</xsl:text>
-    <xsl:number value="$snumber" format="01"/>
-    <xsl:text>.html</xsl:text>
-  </xsl:variable>
+  <body class="titlepage">
+    <xsl:call-template name="body.attributes"/>
+    <xsl:choose>
+      <xsl:when test="$active.toc != 0">
+        <xsl:attribute name="onload">
+          <xsl:text>newPage('</xsl:text>
+          <xsl:value-of select="$titlefoil.html"/>
+          <xsl:text>',</xsl:text>
+          <xsl:value-of select="$overlay"/>
+          <xsl:text>);</xsl:text>
+        </xsl:attribute>
+      </xsl:when>
+      <xsl:when test="$overlay != 0">
+        <xsl:attribute name="onload">
+          <xsl:text>overlaySetup('lc');</xsl:text>
+        </xsl:attribute>
+      </xsl:when>
+    </xsl:choose>
+
+    <xsl:if test="$keyboard.nav != 0">
+      <xsl:attribute name="onkeypress">
+        <xsl:text>navigate(event)</xsl:text>
+      </xsl:attribute>
+    </xsl:if>
+
+    <div class="{name(.)}">
+      <xsl:apply-templates mode="titlepage.mode"/>
+    </div>
+
+    <xsl:if test="$multiframe=0">
+      <div id="overlayDiv" class="navfoot">
+        <xsl:choose>
+          <xsl:when test="$overlay != 0">
+            <xsl:attribute name="style">
+              <xsl:text>position:absolute;visibility:visible;</xsl:text>
+            </xsl:attribute>
+            <hr/>
+          </xsl:when>
+          <xsl:otherwise>
+            <xsl:attribute name="style">
+              <xsl:text>padding-top: 2in;</xsl:text>
+            </xsl:attribute>
+          </xsl:otherwise>
+        </xsl:choose>
+
+        <table width="100%" border="0"
+               cellspacing="0" cellpadding="0"
+               summary="Navigation">
+          <tr>
+            <td align="left" width="80%" valign="top">
+              <span class="navfooter">
+                <xsl:apply-templates select="/slides/slidesinfo/copyright"
+                                     mode="slide.footer.mode"/>
+              </span>
+            </td>
+            <td align="right" width="20%" valign="top">
+              <a href="foil01.html">
+                <img alt="{$text.next}" border="0">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="next.image"/>
+                  </xsl:attribute>
+                </img>
+              </a>
+            </td>
+          </tr>
+        </table>
+      </div>
+    </xsl:if>
+  </body>
+</xsl:template>
+
+<!-- ====================================================================== -->
+
+<xsl:template name="top-nav">
+  <xsl:param name="home"/>
+  <xsl:param name="up"/>
+  <xsl:param name="next"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="tocfile" select="$toc.html"/>
+
+  <div class="navhead">
+    <table border="0" width="100%" cellspacing="0" cellpadding="0"
+           summary="Navigation table">
+      <tr>
+        <td align="left" valign="bottom" width="10%">
+          <xsl:choose>
+            <xsl:when test="$prev">
+              <span class="link-text">
+                <a>
+                  <xsl:attribute name="href">
+                    <xsl:apply-templates select="$prev" mode="filename"/>
+                  </xsl:attribute>
+                  <xsl:if test="$multiframe != 0">
+                    <xsl:attribute name="target">foil</xsl:attribute>
+                  </xsl:if>
+                  <img alt="{$text.prev}" border="0">
+                    <xsl:attribute name="src">
+                      <xsl:call-template name="prev.image"/>
+                    </xsl:attribute>
+                  </img>
+                </a>
+              </span>
+            </xsl:when>
+            <xsl:otherwise>
+              <span class="no-link-text">&#160;</span>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+        </td>
+        <td width="80%">&#160;</td>
+        <td align="right" valign="bottom" width="10%">
+          <xsl:choose>
+            <xsl:when test="$next">
+              <span class="link-text">
+                <a>
+                  <xsl:attribute name="href">
+                    <xsl:apply-templates select="$next" mode="filename"/>
+                  </xsl:attribute>
+                  <xsl:if test="$multiframe != 0">
+                    <xsl:attribute name="target">foil</xsl:attribute>
+                  </xsl:if>
+                  <img alt="{$text.next}" border="0">
+                    <xsl:attribute name="src">
+                      <xsl:call-template name="next.image"/>
+                    </xsl:attribute>
+                  </img>
+                </a>
+              </span>
+            </xsl:when>
+            <xsl:otherwise>
+              <span class="no-link-text">&#160;</span>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+        </td>
+      </tr>
+    </table>
+    <hr class="top-nav-sep"/>
+  </div>
+</xsl:template>
+
+<xsl:template name="bottom-nav">
+  <xsl:param name="home"/>
+  <xsl:param name="up"/>
+  <xsl:param name="next"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="tocfile" select="$toc.html"/>
+
+  <div class="navfoot">
+    <hr class="bottom-nav-sep"/>
+    <table border="0" width="100%" cellspacing="0" cellpadding="0"
+           summary="Navigation table">
+      <tr>
+        <td align="left" valign="top">
+          <xsl:apply-templates select="/slides/slidesinfo/copyright"
+                               mode="slide.footer.mode"/>
+          <xsl:text>&#160;</xsl:text>
+        </td>
+
+        <td align="right" valign="top">
+          <xsl:choose>
+            <xsl:when test="$prev">
+              <span class="link-text">
+                <a>
+                  <xsl:attribute name="href">
+                    <xsl:apply-templates select="$prev" mode="filename"/>
+                  </xsl:attribute>
+                  <xsl:if test="$multiframe != 0">
+                    <xsl:attribute name="target">foil</xsl:attribute>
+                  </xsl:if>
+                  <img alt="{$text.prev}" border="0">
+                    <xsl:attribute name="src">
+                      <xsl:call-template name="prev.image"/>
+                    </xsl:attribute>
+                  </img>
+                </a>
+              </span>
+            </xsl:when>
+            <xsl:otherwise>
+              <span class="no-link-text">&#160;</span>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+
+          <xsl:choose>
+            <xsl:when test="$next">
+              <span class="link-text">
+                <a>
+                  <xsl:attribute name="href">
+                    <xsl:apply-templates select="$next" mode="filename"/>
+                  </xsl:attribute>
+                  <xsl:if test="$multiframe != 0">
+                    <xsl:attribute name="target">foil</xsl:attribute>
+                  </xsl:if>
+                  <img alt="{$text.next}" border="0">
+                    <xsl:attribute name="src">
+                      <xsl:call-template name="next.image"/>
+                    </xsl:attribute>
+                  </img>
+                </a>
+              </span>
+            </xsl:when>
+            <xsl:otherwise>
+              <span class="no-link-text">&#160;</span>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+        </td>
+      </tr>
+    </table>
+  </div>
+</xsl:template>
+
+<!-- ====================================================================== -->
 
+<xsl:template match="foilgroup">
+  <xsl:param name="thisfoilgroup">
+    <xsl:apply-templates select="." mode="filename"/>
+  </xsl:param>
+
+  <xsl:variable name="home" select="/slides"/>
+  <xsl:variable name="up" select="(parent::slides|parent::foilgroup)[1]"/>
+  <xsl:variable name="next" select="foil[1]"/>
+  <xsl:variable name="prev" select="(preceding::foil|parent::foilgroup|/slides)[last()]"/>
   <xsl:call-template name="write.chunk">
     <xsl:with-param name="indent" select="$output.indent"/>
-    <xsl:with-param name="filename" select="concat($base.dir,$thissection)"/>
+    <xsl:with-param name="filename" select="concat($base.dir,$thisfoilgroup)"/>
     <xsl:with-param name="content">
       <head>
         <title><xsl:value-of select="title"/></title>
@@ -337,11 +670,16 @@ function init() {
           </xsl:attribute>
         </link>
 
-        <xsl:call-template name="section-links"/>
+        <xsl:call-template name="links">
+          <xsl:with-param name="home" select="$home"/>
+          <xsl:with-param name="up" select="$up"/>
+          <xsl:with-param name="next" select="$next"/>
+          <xsl:with-param name="prev" select="$prev"/>
+        </xsl:call-template>
 
         <xsl:if test="$overlay != 0 or $keyboard.nav != 0
                       or $dynamic.toc != 0 or $active.toc != 0">
-          <script language="JavaScript1.2"/>
+          <script language="JavaScript1.2" type="text/javascript"/>
         </xsl:if>
 
         <xsl:if test="$keyboard.nav != 0 or $dynamic.toc != 0 or $active.toc != 0">
@@ -382,23 +720,19 @@ function init() {
   <xsl:apply-templates select="foil"/>
 </xsl:template>
 
-<xsl:template match="section" mode="multiframe">
-  <xsl:variable name="snumber">
-    <xsl:number count="section" level="any"/>
-  </xsl:variable>
-
-  <xsl:variable name="thissection">
-    <xsl:text>section</xsl:text>
-    <xsl:number value="$snumber" format="01"/>
+<xsl:template match="foilgroup" mode="multiframe">
+  <xsl:variable name="thisfoilgroup">
+    <xsl:text>foilgrp</xsl:text>
+    <xsl:number count="foilgroup" level="any" format="01"/>
     <xsl:text>.html</xsl:text>
   </xsl:variable>
 
   <frameset rows="{$multiframe.navigation.height},*,{$multiframe.navigation.height}"
             border="0" name="foil" framespacing="0">
-    <frame src="top-{$thissection}" name="top" marginheight="0"
+    <frame src="top-{$thisfoilgroup}" name="top" marginheight="0"
            scrolling="no" frameborder="0"/>
-    <frame src="body-{$thissection}" name="body" marginheight="0" frameborder="0"/>
-    <frame src="bot-{$thissection}" name="bottom" marginheight="0"
+    <frame src="body-{$thisfoilgroup}" name="body" marginheight="0" frameborder="0"/>
+    <frame src="bot-{$thisfoilgroup}" name="bottom" marginheight="0"
            scrolling="no" frameborder="0"/>
     <noframes>
       <body class="frameset">
@@ -411,16 +745,21 @@ function init() {
   </frameset>
 </xsl:template>
 
-<xsl:template match="section" mode="multiframe-top">
-  <xsl:variable name="section">
-    <xsl:text>section</xsl:text>
-    <xsl:number count="section" level="any" format="01"/>
+<xsl:template match="foilgroup" mode="multiframe-top">
+  <xsl:variable name="foilgroup">
+    <xsl:text>foilgrp</xsl:text>
+    <xsl:number count="foilgroup" level="any" format="01"/>
     <xsl:text>.html</xsl:text>
   </xsl:variable>
 
+  <xsl:variable name="home" select="/slides"/>
+  <xsl:variable name="up" select="(parent::slides|parent::foilgroup)[1]"/>
+  <xsl:variable name="next" select="foil[1]"/>
+  <xsl:variable name="prev" select="(preceding::foil|parent::foilgroup|/slides)[last()]"/>
+
   <xsl:call-template name="write.chunk">
     <xsl:with-param name="indent" select="$output.indent"/>
-    <xsl:with-param name="filename" select="concat($base.dir,'top-',$section)"/>
+    <xsl:with-param name="filename" select="concat($base.dir,'top-',$foilgroup)"/>
     <xsl:with-param name="content">
       <html>
         <head>
@@ -433,7 +772,7 @@ function init() {
 
           <xsl:if test="$overlay != 0 or $keyboard.nav != 0
                         or $dynamic.toc != 0 or $active.toc != 0">
-            <script language="JavaScript1.2"/>
+            <script language="JavaScript1.2" type="text/javascript"/>
           </xsl:if>
 
           <xsl:if test="$keyboard.nav != 0 or $dynamic.toc != 0 or $active.toc != 0">
@@ -455,9 +794,11 @@ function init() {
           </xsl:if>
         </head>
         <body class="topnavigation" bgcolor="{$multiframe.top.bgcolor}">
-          <xsl:call-template name="section-top-nav">
-            <xsl:with-param name="prev-target" select="'foil'"/>
-            <xsl:with-param name="next-target" select="'foil'"/>
+          <xsl:call-template name="foilgroup-top-nav">
+            <xsl:with-param name="home" select="$home"/>
+            <xsl:with-param name="up" select="$up"/>
+            <xsl:with-param name="next" select="$next"/>
+            <xsl:with-param name="prev" select="$prev"/>
           </xsl:call-template>
         </body>
       </html>
@@ -465,24 +806,20 @@ function init() {
   </xsl:call-template>
 </xsl:template>
 
-<xsl:template match="section" mode="multiframe-body">
+<xsl:template match="foilgroup" mode="multiframe-body">
   <xsl:variable name="id">
     <xsl:call-template name="object.id"/>
   </xsl:variable>
 
-  <xsl:variable name="snumber">
-    <xsl:number count="section" level="any"/>
-  </xsl:variable>
-
-  <xsl:variable name="thissection">
-    <xsl:text>section</xsl:text>
-    <xsl:number value="$snumber" format="01"/>
+  <xsl:variable name="thisfoilgroup">
+    <xsl:text>foilgrp</xsl:text>
+    <xsl:number count="foilgroup" level="any" format="01"/>
     <xsl:text>.html</xsl:text>
   </xsl:variable>
 
   <xsl:call-template name="write.chunk">
     <xsl:with-param name="indent" select="$output.indent"/>
-    <xsl:with-param name="filename" select="concat($base.dir,'body-',$thissection)"/>
+    <xsl:with-param name="filename" select="concat($base.dir,'body-',$thisfoilgroup)"/>
     <xsl:with-param name="content">
       <html>
         <head>
@@ -495,7 +832,7 @@ function init() {
 
           <xsl:if test="$overlay != 0 or $keyboard.nav != 0
                         or $dynamic.toc != 0 or $active.toc != 0">
-            <script language="JavaScript1.2"/>
+            <script language="JavaScript1.2" type="text/javascript"/>
           </xsl:if>
 
           <xsl:if test="$keyboard.nav != 0 or $dynamic.toc != 0 or $active.toc != 0">
@@ -522,24 +859,21 @@ function init() {
   </xsl:call-template>
 </xsl:template>
 
-<xsl:template match="section" mode="multiframe-bottom">
-  <xsl:variable name="id">
-    <xsl:call-template name="object.id"/>
-  </xsl:variable>
-
-  <xsl:variable name="snumber">
-    <xsl:number count="section" level="any"/>
-  </xsl:variable>
-
-  <xsl:variable name="thissection">
-    <xsl:text>section</xsl:text>
-    <xsl:number value="$snumber" format="01"/>
+<xsl:template match="foilgroup" mode="multiframe-bottom">
+  <xsl:variable name="thisfoilgroup">
+    <xsl:text>foilgrp</xsl:text>
+    <xsl:number count="foilgroup" level="any" format="01"/>
     <xsl:text>.html</xsl:text>
   </xsl:variable>
 
+  <xsl:variable name="home" select="/slides"/>
+  <xsl:variable name="up" select="(parent::slides|parent::foilgroup)[1]"/>
+  <xsl:variable name="next" select="foil[1]"/>
+  <xsl:variable name="prev" select="(preceding::foil|parent::foilgroup|/slides)[last()]"/>
+
   <xsl:call-template name="write.chunk">
     <xsl:with-param name="indent" select="$output.indent"/>
-    <xsl:with-param name="filename" select="concat($base.dir,'bot-',$thissection)"/>
+    <xsl:with-param name="filename" select="concat($base.dir,'bot-',$thisfoilgroup)"/>
     <xsl:with-param name="content">
       <html>
         <head>
@@ -552,7 +886,7 @@ function init() {
 
           <xsl:if test="$overlay != 0 or $keyboard.nav != 0
                         or $dynamic.toc != 0 or $active.toc != 0">
-            <script language="JavaScript1.2"/>
+            <script language="JavaScript1.2" type="text/javascript"/>
           </xsl:if>
 
           <xsl:if test="$keyboard.nav != 0 or $dynamic.toc != 0 or $active.toc != 0">
@@ -574,35 +908,38 @@ function init() {
           </xsl:if>
         </head>
         <body class="botnavigation" bgcolor="{$multiframe.bottom.bgcolor}">
-          <xsl:call-template name="section-bottom-nav"/>
+          <xsl:call-template name="foilgroup-bottom-nav">
+            <xsl:with-param name="home" select="$home"/>
+            <xsl:with-param name="up" select="$up"/>
+            <xsl:with-param name="next" select="$next"/>
+            <xsl:with-param name="prev" select="$prev"/>
+          </xsl:call-template>
         </body>
       </html>
     </xsl:with-param>
   </xsl:call-template>
 </xsl:template>
 
-<xsl:template match="section" mode="singleframe">
+<xsl:template match="foilgroup" mode="singleframe">
   <xsl:variable name="id">
     <xsl:call-template name="object.id"/>
   </xsl:variable>
 
-  <xsl:variable name="snumber">
-    <xsl:number count="section" level="any"/>
-  </xsl:variable>
-
-  <xsl:variable name="thissection">
-    <xsl:text>section</xsl:text>
-    <xsl:number value="$snumber" format="01"/>
-    <xsl:text>.html</xsl:text>
-  </xsl:variable>
+  <xsl:param name="thisfoilgroup">
+    <xsl:apply-templates select="." mode="filename"/>
+  </xsl:param>
 
-  <body class="section">
+  <xsl:variable name="home" select="/slides"/>
+  <xsl:variable name="up" select="(parent::slides|parent::foilgroup)[1]"/>
+  <xsl:variable name="next" select="foil[1]"/>
+  <xsl:variable name="prev" select="(preceding::foil|parent::foilgroup|/slides)[last()]"/>
+  <body class="foilgroup">
     <xsl:call-template name="body.attributes"/>
     <xsl:choose>
       <xsl:when test="$active.toc != 0">
         <xsl:attribute name="onload">
           <xsl:text>newPage('</xsl:text>
-          <xsl:value-of select="$thissection"/>
+          <xsl:value-of select="$thisfoilgroup"/>
           <xsl:text>',</xsl:text>
           <xsl:value-of select="$overlay"/>
           <xsl:text>);</xsl:text>
@@ -622,12 +959,22 @@ function init() {
     <div class="{name(.)}" id="{$id}">
       <a name="{$id}"/>
       <xsl:if test="$multiframe=0">
-        <xsl:call-template name="section-top-nav"/>
+        <xsl:call-template name="foilgroup-top-nav">
+          <xsl:with-param name="home" select="$home"/>
+          <xsl:with-param name="up" select="$up"/>
+          <xsl:with-param name="next" select="$next"/>
+          <xsl:with-param name="prev" select="$prev"/>
+        </xsl:call-template>
       </xsl:if>
 
       <div class="{name(.)}" id="{$id}">
         <a name="{$id}"/>
-        <xsl:apply-templates select="title"/>
+        <xsl:call-template name="foilgroup-body">
+          <xsl:with-param name="home" select="$home"/>
+          <xsl:with-param name="up" select="$up"/>
+          <xsl:with-param name="next" select="$next"/>
+          <xsl:with-param name="prev" select="$prev"/>
+        </xsl:call-template>
       </div>
 
       <xsl:if test="$multiframe=0">
@@ -637,53 +984,33 @@ function init() {
               <xsl:text>position:absolute;visibility:visible;</xsl:text>
             </xsl:attribute>
           </xsl:if>
-          <xsl:call-template name="section-bottom-nav"/>
+          <xsl:call-template name="foilgroup-bottom-nav">
+            <xsl:with-param name="home" select="$home"/>
+            <xsl:with-param name="up" select="$up"/>
+            <xsl:with-param name="next" select="$next"/>
+            <xsl:with-param name="prev" select="$prev"/>
+          </xsl:call-template>
         </div>
       </xsl:if>
     </div>
   </body>
 </xsl:template>
 
-<xsl:template name="section-links">
-  <xsl:variable name="prevfoil"
-                select="(preceding::foil|/slides)[last()]"/>
-
-  <xsl:variable name="nextfoil" select="foil[1]"/>
-
-  <xsl:if test="$prevfoil">
-    <link rel="previous">
-      <xsl:attribute name="href">
-        <xsl:apply-templates select="$prevfoil" mode="filename"/>
-      </xsl:attribute>
-      <xsl:attribute name="title">
-        <xsl:value-of select="$prevfoil/title"/>
-      </xsl:attribute>
-    </link>
-  </xsl:if>
-
-  <xsl:if test="$nextfoil">
-    <link rel="next">
-      <xsl:attribute name="href">
-        <xsl:apply-templates select="$nextfoil" mode="filename"/>
-      </xsl:attribute>
-      <xsl:attribute name="title">
-        <xsl:value-of select="$nextfoil/title"/>
-      </xsl:attribute>
-    </link>
-  </xsl:if>
-</xsl:template>
-
 <!-- ====================================================================== -->
 
 <xsl:template match="foil">
-  <xsl:variable name="id">
-    <xsl:call-template name="object.id"/>
-  </xsl:variable>
-
   <xsl:variable name="thisfoil">
     <xsl:apply-templates select="." mode="filename"/>
   </xsl:variable>
 
+  <xsl:variable name="home" select="/slides"/>
+  <xsl:variable name="up"   select="(parent::slides|parent::foilgroup)[1]"/>
+  <xsl:variable name="next" select="(following::foil
+                                    |following::foilgroup)[1]"/>
+  <xsl:variable name="prev" select="(preceding-sibling::foil[1]
+                                    |parent::foilgroup[1]
+                                    |/slides)[last()]"/>
+
   <xsl:call-template name="write.chunk">
     <xsl:with-param name="indent" select="$output.indent"/>
     <xsl:with-param name="filename" select="concat($base.dir,$thisfoil)"/>
@@ -696,11 +1023,16 @@ function init() {
           </xsl:attribute>
         </link>
 
-        <xsl:call-template name="foil-links"/>
+        <xsl:call-template name="links">
+          <xsl:with-param name="home" select="$home"/>
+          <xsl:with-param name="up" select="$up"/>
+          <xsl:with-param name="next" select="$next"/>
+          <xsl:with-param name="prev" select="$prev"/>
+        </xsl:call-template>
 
         <xsl:if test="$overlay != 0 or $keyboard.nav != 0
                       or $dynamic.toc != 0 or $active.toc != 0">
-          <script language="JavaScript1.2"/>
+          <script language="JavaScript1.2" type="text/javascript"/>
         </xsl:if>
 
         <xsl:if test="$keyboard.nav != 0 or $dynamic.toc != 0 or $active.toc != 0">
@@ -740,7 +1072,7 @@ function init() {
 </xsl:template>
 
 <xsl:template match="foil" mode="multiframe">
-  <xsl:variable name="section" select="ancestor::section"/>
+  <xsl:variable name="foilgroup" select="ancestor::foilgroup"/>
 
   <xsl:variable name="thisfoil">
     <xsl:apply-templates select="." mode="filename"/>
@@ -781,6 +1113,14 @@ function init() {
     <xsl:apply-templates select="." mode="filename"/>
   </xsl:variable>
 
+  <xsl:variable name="home" select="/slides"/>
+  <xsl:variable name="up"   select="(parent::slides|parent::foilgroup)[1]"/>
+  <xsl:variable name="next" select="(following::foil
+                                    |following::foilgroup)[1]"/>
+  <xsl:variable name="prev" select="(preceding-sibling::foil[1]
+                                    |parent::foilgroup[1]
+                                    |/slides)[last()]"/>
+
   <xsl:call-template name="write.chunk">
     <xsl:with-param name="indent" select="$output.indent"/>
     <xsl:with-param name="filename" select="concat($base.dir,'top-',$thisfoil)"/>
@@ -796,7 +1136,7 @@ function init() {
 
           <xsl:if test="$overlay != 0 or $keyboard.nav != 0
                         or $dynamic.toc != 0 or $active.toc != 0">
-            <script language="JavaScript1.2"/>
+            <script language="JavaScript1.2" type="text/javascript"/>
           </xsl:if>
 
           <xsl:if test="$keyboard.nav != 0 or $dynamic.toc != 0 or $active.toc != 0">
@@ -819,8 +1159,10 @@ function init() {
         </head>
         <body class="topnavigation" bgcolor="{$multiframe.top.bgcolor}">
           <xsl:call-template name="foil-top-nav">
-            <xsl:with-param name="prev-target" select="'foil'"/>
-            <xsl:with-param name="next-target" select="'foil'"/>
+            <xsl:with-param name="home" select="$home"/>
+            <xsl:with-param name="up" select="$up"/>
+            <xsl:with-param name="next" select="$next"/>
+            <xsl:with-param name="prev" select="$prev"/>
           </xsl:call-template>
         </body>
       </html>
@@ -848,7 +1190,7 @@ function init() {
 
           <xsl:if test="$overlay != 0 or $keyboard.nav != 0
                         or $dynamic.toc != 0 or $active.toc != 0">
-            <script language="JavaScript1.2"/>
+            <script language="JavaScript1.2" type="text/javascript"/>
           </xsl:if>
 
           <xsl:if test="$keyboard.nav != 0 or $dynamic.toc != 0 or $active.toc != 0">
@@ -880,6 +1222,14 @@ function init() {
     <xsl:apply-templates select="." mode="filename"/>
   </xsl:variable>
 
+  <xsl:variable name="home" select="/slides"/>
+  <xsl:variable name="up"   select="(parent::slides|parent::foilgroup)[1]"/>
+  <xsl:variable name="next" select="(following::foil
+                                    |following::foilgroup)[1]"/>
+  <xsl:variable name="prev" select="(preceding-sibling::foil[1]
+                                    |parent::foilgroup[1]
+                                    |/slides)[last()]"/>
+
   <xsl:call-template name="write.chunk">
     <xsl:with-param name="indent" select="$output.indent"/>
     <xsl:with-param name="filename" select="concat($base.dir,'bot-',$thisfoil)"/>
@@ -895,7 +1245,7 @@ function init() {
 
           <xsl:if test="$overlay != 0 or $keyboard.nav != 0
                         or $dynamic.toc != 0 or $active.toc != 0">
-            <script language="JavaScript1.2"/>
+            <script language="JavaScript1.2" type="text/javascript"/>
           </xsl:if>
 
           <xsl:if test="$keyboard.nav != 0 or $dynamic.toc != 0 or $active.toc != 0">
@@ -917,7 +1267,12 @@ function init() {
           </xsl:if>
         </head>
         <body class="botnavigation" bgcolor="{$multiframe.bottom.bgcolor}">
-          <xsl:call-template name="foil-bottom-nav"/>
+          <xsl:call-template name="foil-bottom-nav">
+            <xsl:with-param name="home" select="$home"/>
+            <xsl:with-param name="up" select="$up"/>
+            <xsl:with-param name="next" select="$next"/>
+            <xsl:with-param name="prev" select="$prev"/>
+          </xsl:call-template>
         </body>
       </html>
     </xsl:with-param>
@@ -925,15 +1280,21 @@ function init() {
 </xsl:template>
 
 <xsl:template match="foil" mode="singleframe">
+  <xsl:param name="thisfoil">
+    <xsl:apply-templates select="." mode="filename"/>
+  </xsl:param>
+
   <xsl:variable name="id">
     <xsl:call-template name="object.id"/>
   </xsl:variable>
 
-  <xsl:variable name="section" select="ancestor::section"/>
-
-  <xsl:variable name="thisfoil">
-    <xsl:apply-templates select="." mode="filename"/>
-  </xsl:variable>
+  <xsl:variable name="home" select="/slides"/>
+  <xsl:variable name="up"   select="(parent::slides|parent::foilgroup)[1]"/>
+  <xsl:variable name="next" select="(following::foil
+                                    |following::foilgroup)[1]"/>
+  <xsl:variable name="prev" select="(preceding-sibling::foil[1]
+                                    |parent::foilgroup[1]
+                                    |/slides)[last()]"/>
 
   <body class="foil">
     <xsl:call-template name="body.attributes"/>
@@ -962,7 +1323,12 @@ function init() {
     <div class="{name(.)}" id="{$id}">
       <a name="{$id}"/>
       <xsl:if test="$multiframe=0">
-        <xsl:call-template name="foil-top-nav"/>
+        <xsl:call-template name="foil-top-nav">
+          <xsl:with-param name="home" select="$home"/>
+          <xsl:with-param name="up" select="$up"/>
+          <xsl:with-param name="next" select="$next"/>
+          <xsl:with-param name="prev" select="$prev"/>
+        </xsl:call-template>
       </xsl:if>
 
       <xsl:apply-templates/>
@@ -974,45 +1340,18 @@ function init() {
               <xsl:text>position:absolute;visibility:visible;</xsl:text>
             </xsl:attribute>
           </xsl:if>
-          <xsl:call-template name="foil-bottom-nav"/>
+          <xsl:call-template name="foil-bottom-nav">
+            <xsl:with-param name="home" select="$home"/>
+            <xsl:with-param name="up" select="$up"/>
+            <xsl:with-param name="next" select="$next"/>
+            <xsl:with-param name="prev" select="$prev"/>
+          </xsl:call-template>
         </div>
       </xsl:if>
     </div>
   </body>
 </xsl:template>
 
-<xsl:template name="foil-links">
-  <xsl:variable name="nextfoil" select="(following::foil
-                                        |following::section)[1]"/>
-
-  <xsl:variable name="prevfoil" select="(preceding-sibling::foil[1]
-                                        |parent::section[1]
-                                        |/slides)[last()]"/>
-
-
-  <xsl:if test="$prevfoil">
-    <link rel="previous">
-      <xsl:attribute name="href">
-        <xsl:apply-templates select="$prevfoil" mode="filename"/>
-      </xsl:attribute>
-      <xsl:attribute name="title">
-        <xsl:value-of select="$prevfoil/title"/>
-      </xsl:attribute>
-    </link>
-  </xsl:if>
-
-  <xsl:if test="$nextfoil">
-    <link rel="next">
-      <xsl:attribute name="href">
-        <xsl:apply-templates select="$nextfoil" mode="filename"/>
-      </xsl:attribute>
-      <xsl:attribute name="title">
-        <xsl:value-of select="$nextfoil/title"/>
-      </xsl:attribute>
-    </link>
-  </xsl:if>
-</xsl:template>
-
 <!-- ============================================================ -->
 
 <xsl:template match="slidesinfo" mode="toc">
@@ -1034,25 +1373,22 @@ function init() {
   </DIV>
 </xsl:template>
 
-<xsl:template match="section" mode="toc">
+<xsl:template match="foilgroup" mode="toc">
   <xsl:variable name="id"><xsl:call-template name="object.id"/></xsl:variable>
-  <xsl:variable name="snumber">
-    <xsl:number count="section" level="any"/>
-  </xsl:variable>
 
-  <xsl:variable name="thissection">
-    <xsl:text>section</xsl:text>
-    <xsl:number value="$snumber" format="01"/>
+  <xsl:variable name="thisfoilgroup">
+    <xsl:text>foilgrp</xsl:text>
+    <xsl:number count="foilgroup" level="any" format="01"/>
     <xsl:text>.html</xsl:text>
   </xsl:variable>
 
-  <DIV class="toc-section" id="{$id}">
+  <DIV class="toc-foilgroup" id="{$id}">
     <img alt="-">
       <xsl:attribute name="src">
         <xsl:call-template name="minus.image"/>
       </xsl:attribute>
     </img>
-    <A href="{$thissection}" target="foil">
+    <A href="{$thisfoilgroup}" target="foil">
       <xsl:choose>
         <xsl:when test="titleabbrev">
           <xsl:apply-templates select="titleabbrev" mode="toc"/>
@@ -1091,4 +1427,111 @@ function init() {
   </DIV>
 </xsl:template>
 
+<!-- ====================================================================== -->
+
+<xsl:template match="slidesinfo" mode="ns-toc">
+  <xsl:variable name="id">
+    <xsl:call-template name="object.id"/>
+  </xsl:variable>
+
+  <xsl:text>myList.addItem('</xsl:text>
+
+  <xsl:text disable-output-escaping="yes">&lt;DIV id="</xsl:text>
+  <xsl:value-of select="$id"/>
+  <xsl:text disable-output-escaping="yes">" class="toc-slidesinfo"&gt;</xsl:text>
+
+  <xsl:text disable-output-escaping="yes">&lt;A href="</xsl:text>
+  <xsl:value-of select="$titlefoil.html"/>
+  <xsl:text disable-output-escaping="yes">" target="foil"&gt;</xsl:text>
+
+  <xsl:choose>
+    <xsl:when test="titleabbrev">
+      <xsl:value-of select="titleabbrev"/>
+    </xsl:when>
+    <xsl:otherwise>
+      <xsl:value-of select="title"/>
+    </xsl:otherwise>
+  </xsl:choose>
+
+  <xsl:text disable-output-escaping="yes">&lt;/A&gt;&lt;/DIV&gt;</xsl:text>
+  <xsl:text>');&#10;</xsl:text>
+</xsl:template>
+
+<xsl:template match="foilgroup" mode="ns-toc">
+  <xsl:variable name="id">
+    <xsl:call-template name="object.id"/>
+  </xsl:variable>
+
+  <xsl:text>subList = new List(false, width, height, "</xsl:text>
+<xsl:value-of select="$toc.bg.color"/>
+<xsl:text>");&#10;</xsl:text>
+  <xsl:text>subList.setIndent(12);&#10;</xsl:text>
+  <xsl:apply-templates select="foil" mode="ns-toc"/>
+
+  <xsl:text>myList.addList(subList, '</xsl:text>
+
+  <xsl:text disable-output-escaping="yes">&lt;DIV id="</xsl:text>
+  <xsl:value-of select="$id"/>
+  <xsl:text disable-output-escaping="yes">" class="toc-section"&gt;</xsl:text>
+
+  <xsl:text disable-output-escaping="yes">&lt;A href="</xsl:text>
+  <xsl:apply-templates select="." mode="filename"/>
+  <xsl:text disable-output-escaping="yes">" target="foil"&gt;</xsl:text>
+
+  <xsl:choose>
+    <xsl:when test="titleabbrev">
+      <xsl:value-of select="titleabbrev"/>
+    </xsl:when>
+    <xsl:otherwise>
+      <xsl:value-of select="title"/>
+    </xsl:otherwise>
+  </xsl:choose>
+
+  <xsl:text disable-output-escaping="yes">&lt;/A&gt;&lt;/DIV&gt;</xsl:text>
+  <xsl:text>');&#10;</xsl:text>
+</xsl:template>
+
+<xsl:template match="foil" mode="ns-toc">
+  <xsl:variable name="id"><xsl:call-template name="object.id"/></xsl:variable>
+
+  <xsl:choose>
+    <xsl:when test="ancestor::foilgroup">
+      <xsl:text>subList.addItem('</xsl:text>
+    </xsl:when>
+    <xsl:otherwise>
+      <xsl:text>myList.addItem('</xsl:text>
+    </xsl:otherwise>
+  </xsl:choose>
+
+  <xsl:text disable-output-escaping="yes">&lt;DIV id="</xsl:text>
+  <xsl:value-of select="$id"/>
+  <xsl:text disable-output-escaping="yes">" class="toc-foil"&gt;</xsl:text>
+
+  <xsl:text disable-output-escaping="yes">&lt;img alt="-" src="</xsl:text>
+  <xsl:call-template name="bullet.image"/>
+  <xsl:text disable-output-escaping="yes">"&gt;</xsl:text>
+
+  <xsl:text disable-output-escaping="yes">&lt;A href="</xsl:text>
+  <xsl:apply-templates select="." mode="filename"/>
+  <xsl:text disable-output-escaping="yes">" target="foil"&gt;</xsl:text>
+
+  <xsl:choose>
+    <xsl:when test="titleabbrev">
+      <xsl:value-of select="titleabbrev"/>
+    </xsl:when>
+    <xsl:otherwise>
+      <xsl:value-of select="title"/>
+    </xsl:otherwise>
+  </xsl:choose>
+
+  <xsl:text disable-output-escaping="yes">&lt;/A&gt;&lt;/DIV&gt;</xsl:text>
+  <xsl:text>');&#10;</xsl:text>
+</xsl:template>
+
+<xsl:template match="speakernotes" mode="ns-toc">
+  <!-- nop -->
+</xsl:template>
+
+<!-- ====================================================================== -->
+
 </xsl:stylesheet>
index 150ec3582f267a3dc4723284168276b2db301235..9b6cb39aa56e0ec61b8b357a20cea8dd3455902f 100644 (file)
@@ -2,7 +2,7 @@
 <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
                 version="1.0">
 
-<xsl:output method="html"/>
+<!-- ====================================================================== -->
 
 <xsl:template name="graphics-file">
   <xsl:param name="image" select="'bullet.gif'"/>
   <xsl:value-of select="$image"/>
 </xsl:template>
 
-<xsl:template name="bullet.image">
+<!-- ====================================================================== -->
+<!-- active navigation images -->
+
+<xsl:template name="toc.image">
   <!-- Danger Will Robinson: template shadows parameter -->
   <xsl:call-template name="graphics-file">
-    <xsl:with-param name="image" select="$bullet.image"/>
+    <xsl:with-param name="image" select="$toc.image"/>
   </xsl:call-template>
 </xsl:template>
 
-<xsl:template name="left.image">
+<xsl:template name="home.image">
   <!-- Danger Will Robinson: template shadows parameter -->
   <xsl:call-template name="graphics-file">
-    <xsl:with-param name="image" select="$left.image"/>
+    <xsl:with-param name="image" select="$home.image"/>
   </xsl:call-template>
 </xsl:template>
 
-<xsl:template name="right.image">
+<xsl:template name="up.image">
   <!-- Danger Will Robinson: template shadows parameter -->
   <xsl:call-template name="graphics-file">
-    <xsl:with-param name="image" select="$right.image"/>
+    <xsl:with-param name="image" select="$up.image"/>
   </xsl:call-template>
 </xsl:template>
 
-<xsl:template name="plus.image">
+<xsl:template name="prev.image">
   <!-- Danger Will Robinson: template shadows parameter -->
   <xsl:call-template name="graphics-file">
-    <xsl:with-param name="image" select="$plus.image"/>
+    <xsl:with-param name="image" select="$prev.image"/>
   </xsl:call-template>
 </xsl:template>
 
-<xsl:template name="minus.image">
+<xsl:template name="next.image">
   <!-- Danger Will Robinson: template shadows parameter -->
   <xsl:call-template name="graphics-file">
-    <xsl:with-param name="image" select="$minus.image"/>
+    <xsl:with-param name="image" select="$next.image"/>
   </xsl:call-template>
 </xsl:template>
 
-<xsl:template name="hidetoc.image">
+<!-- inactive navigation images -->
+
+<xsl:template name="no.toc.image">
   <!-- Danger Will Robinson: template shadows parameter -->
   <xsl:call-template name="graphics-file">
-    <xsl:with-param name="image" select="$hidetoc.image"/>
+    <xsl:with-param name="image" select="$no.toc.image"/>
   </xsl:call-template>
 </xsl:template>
 
-<xsl:template name="showtoc.image">
+<xsl:template name="no.home.image">
   <!-- Danger Will Robinson: template shadows parameter -->
   <xsl:call-template name="graphics-file">
-    <xsl:with-param name="image" select="$showtoc.image"/>
+    <xsl:with-param name="image" select="$no.home.image"/>
   </xsl:call-template>
 </xsl:template>
 
-<xsl:template name="w3c.bleft.image">
+<xsl:template name="no.up.image">
+  <!-- Danger Will Robinson: template shadows parameter -->
   <xsl:call-template name="graphics-file">
-    <xsl:with-param name="image" select="'bleft.png'"/>
+    <xsl:with-param name="image" select="$no.up.image"/>
   </xsl:call-template>
 </xsl:template>
 
-<xsl:template name="w3c.left.image">
+<xsl:template name="no.prev.image">
+  <!-- Danger Will Robinson: template shadows parameter -->
   <xsl:call-template name="graphics-file">
-    <xsl:with-param name="image" select="'left.png'"/>
+    <xsl:with-param name="image" select="$no.prev.image"/>
   </xsl:call-template>
 </xsl:template>
 
-<xsl:template name="w3c.bright.image">
+<xsl:template name="no.next.image">
+  <!-- Danger Will Robinson: template shadows parameter -->
   <xsl:call-template name="graphics-file">
-    <xsl:with-param name="image" select="'bright.png'"/>
+    <xsl:with-param name="image" select="$no.next.image"/>
   </xsl:call-template>
 </xsl:template>
 
-<xsl:template name="w3c.right.image">
+<!-- ====================================================================== -->
+<!-- icon images -->
+
+<xsl:template name="bullet.image">
+  <!-- Danger Will Robinson: template shadows parameter -->
   <xsl:call-template name="graphics-file">
-    <xsl:with-param name="image" select="'right.png'"/>
+    <xsl:with-param name="image" select="$bullet.image"/>
   </xsl:call-template>
 </xsl:template>
 
-<xsl:template name="w3c.toc.image">
+<xsl:template name="plus.image">
+  <!-- Danger Will Robinson: template shadows parameter -->
   <xsl:call-template name="graphics-file">
-    <xsl:with-param name="image" select="'toc.png'"/>
+    <xsl:with-param name="image" select="$plus.image"/>
   </xsl:call-template>
 </xsl:template>
 
+<xsl:template name="minus.image">
+  <!-- Danger Will Robinson: template shadows parameter -->
+  <xsl:call-template name="graphics-file">
+    <xsl:with-param name="image" select="$minus.image"/>
+  </xsl:call-template>
+</xsl:template>
+
+<!-- ====================================================================== -->
+<!-- hide/show ToC images -->
+
+<xsl:template name="hidetoc.image">
+  <!-- Danger Will Robinson: template shadows parameter -->
+  <xsl:call-template name="graphics-file">
+    <xsl:with-param name="image" select="$hidetoc.image"/>
+  </xsl:call-template>
+</xsl:template>
+
+<xsl:template name="showtoc.image">
+  <!-- Danger Will Robinson: template shadows parameter -->
+  <xsl:call-template name="graphics-file">
+    <xsl:with-param name="image" select="$showtoc.image"/>
+  </xsl:call-template>
+</xsl:template>
+
+<!-- ====================================================================== -->
+
 </xsl:stylesheet>
index 0f442a209f3bd35b8d8a533d63ec9a217124b360..570037f6311d0d7ab3f3ffe96319e12d67489948 100644 (file)
@@ -117,7 +117,7 @@ can be set in the source document with the &lt;?dbhtml?&gt; pseudo-attribute
 
 <refsynopsisdiv>
 <src:fragment id='titlefoil.html.frag'>
-<xsl:param name="titlefoil.html" select="'titlefoil.html'"/>
+<xsl:param name="titlefoil.html" select="'index.html'"/>
 </src:fragment>
 </refsynopsisdiv>
 
@@ -582,7 +582,7 @@ image paths.</para>
 
 <refsynopsisdiv>
 <src:fragment id='bullet.image.frag'>
-<xsl:param name="bullet.image" select="'bullet.gif'"/>
+<xsl:param name="bullet.image" select="'toc/bullet.png'"/>
 </src:fragment>
 </refsynopsisdiv>
 
@@ -594,19 +594,19 @@ framed ToC.</para>
 </refsect1>
 </refentry>
 
-<refentry id="right.image">
+<refentry id="next.image">
 <refmeta>
-<refentrytitle>right.image</refentrytitle>
+<refentrytitle>next.image</refentrytitle>
 <refmiscinfo role="type">filename</refmiscinfo>
 </refmeta>
 <refnamediv>
-<refname>right.image</refname>
+<refname>next.image</refname>
 <refpurpose>Right-arrow image</refpurpose>
 </refnamediv>
 
 <refsynopsisdiv>
-<src:fragment id='right.image.frag'>
-<xsl:param name="right.image" select="'right.gif'"/>
+<src:fragment id='next.image.frag'>
+<xsl:param name="next.image" select="'active/nav-next.png'"/>
 </src:fragment>
 </refsynopsisdiv>
 
@@ -617,19 +617,19 @@ framed ToC.</para>
 </refsect1>
 </refentry>
 
-<refentry id="left.image">
+<refentry id="prev.image">
 <refmeta>
-<refentrytitle>left.image</refentrytitle>
+<refentrytitle>prev.image</refentrytitle>
 <refmiscinfo role="type">filename</refmiscinfo>
 </refmeta>
 <refnamediv>
-<refname>left.image</refname>
+<refname>prev.image</refname>
 <refpurpose>Left-arrow image</refpurpose>
 </refnamediv>
 
 <refsynopsisdiv>
-<src:fragment id='left.image.frag'>
-<xsl:param name="left.image" select="'left.gif'"/>
+<src:fragment id='prev.image.frag'>
+<xsl:param name="prev.image" select="'active/nav-prev.png'"/>
 </src:fragment>
 </refsynopsisdiv>
 
@@ -640,6 +640,194 @@ framed ToC.</para>
 </refsect1>
 </refentry>
 
+<refentry id="up.image">
+<refmeta>
+<refentrytitle>up.image</refentrytitle>
+<refmiscinfo role="type">filename</refmiscinfo>
+</refmeta>
+<refnamediv>
+<refname>up.image</refname>
+<refpurpose>Up-arrow image</refpurpose>
+</refnamediv>
+
+<refsynopsisdiv>
+<src:fragment id='up.image.frag'>
+<xsl:param name="up.image" select="'active/nav-up.png'"/>
+</src:fragment>
+</refsynopsisdiv>
+
+<refsect1><title>Description</title>
+
+<para>Specifies the filename of the upward-pointing navigation arrow.</para>
+
+</refsect1>
+</refentry>
+
+<refentry id="home.image">
+<refmeta>
+<refentrytitle>home.image</refentrytitle>
+<refmiscinfo role="type">filename</refmiscinfo>
+</refmeta>
+<refnamediv>
+<refname>home.image</refname>
+<refpurpose>Home image</refpurpose>
+</refnamediv>
+
+<refsynopsisdiv>
+<src:fragment id='home.image.frag'>
+<xsl:param name="home.image" select="'active/nav-home.png'"/>
+</src:fragment>
+</refsynopsisdiv>
+
+<refsect1><title>Description</title>
+
+<para>Specifies the filename of the home navigation icon.</para>
+
+</refsect1>
+</refentry>
+
+<refentry id="toc.image">
+<refmeta>
+<refentrytitle>toc.image</refentrytitle>
+<refmiscinfo role="type">filename</refmiscinfo>
+</refmeta>
+<refnamediv>
+<refname>toc.image</refname>
+<refpurpose>ToC image</refpurpose>
+</refnamediv>
+
+<refsynopsisdiv>
+<src:fragment id='toc.image.frag'>
+<xsl:param name="toc.image" select="'active/nav-toc.png'"/>
+</src:fragment>
+</refsynopsisdiv>
+
+<refsect1><title>Description</title>
+
+<para>Specifies the filename of the ToC navigation icon.</para>
+
+</refsect1>
+</refentry>
+
+<!-- ====================================================================== -->
+
+<refentry id="no.next.image">
+<refmeta>
+<refentrytitle>no.next.image</refentrytitle>
+<refmiscinfo role="type">filename</refmiscinfo>
+</refmeta>
+<refnamediv>
+<refname>no.next.image</refname>
+<refpurpose>Inactive right-arrow image</refpurpose>
+</refnamediv>
+
+<refsynopsisdiv>
+<src:fragment id='no.next.image.frag'>
+<xsl:param name="no.next.image" select="'inactive/nav-next.png'"/>
+</src:fragment>
+</refsynopsisdiv>
+
+<refsect1><title>Description</title>
+
+<para>Specifies the filename of the inactive right-pointing navigation arrow.</para>
+
+</refsect1>
+</refentry>
+
+<refentry id="no.prev.image">
+<refmeta>
+<refentrytitle>no.prev.image</refentrytitle>
+<refmiscinfo role="type">filename</refmiscinfo>
+</refmeta>
+<refnamediv>
+<refname>no.prev.image</refname>
+<refpurpose>Inactive left-arrow image</refpurpose>
+</refnamediv>
+
+<refsynopsisdiv>
+<src:fragment id='no.prev.image.frag'>
+<xsl:param name="no.prev.image" select="'inactive/nav-prev.png'"/>
+</src:fragment>
+</refsynopsisdiv>
+
+<refsect1><title>Description</title>
+
+<para>Specifies the filename of the inactive left-pointing navigation arrow.</para>
+
+</refsect1>
+</refentry>
+
+<refentry id="no.up.image">
+<refmeta>
+<refentrytitle>no.up.image</refentrytitle>
+<refmiscinfo role="type">filename</refmiscinfo>
+</refmeta>
+<refnamediv>
+<refname>no.up.image</refname>
+<refpurpose>Inactive up-arrow image</refpurpose>
+</refnamediv>
+
+<refsynopsisdiv>
+<src:fragment id='no.up.image.frag'>
+<xsl:param name="no.up.image" select="'inactive/nav-up.png'"/>
+</src:fragment>
+</refsynopsisdiv>
+
+<refsect1><title>Description</title>
+
+<para>Specifies the filename of the inactive upward-pointing navigation arrow.</para>
+
+</refsect1>
+</refentry>
+
+<refentry id="no.home.image">
+<refmeta>
+<refentrytitle>no.home.image</refentrytitle>
+<refmiscinfo role="type">filename</refmiscinfo>
+</refmeta>
+<refnamediv>
+<refname>no.home.image</refname>
+<refpurpose>Inactive home image</refpurpose>
+</refnamediv>
+
+<refsynopsisdiv>
+<src:fragment id='no.home.image.frag'>
+<xsl:param name="no.home.image" select="'inactive/nav-home.png'"/>
+</src:fragment>
+</refsynopsisdiv>
+
+<refsect1><title>Description</title>
+
+<para>Specifies the filename of the inactive home navigation icon.</para>
+
+</refsect1>
+</refentry>
+
+<refentry id="no.toc.image">
+<refmeta>
+<refentrytitle>no.toc.image</refentrytitle>
+<refmiscinfo role="type">filename</refmiscinfo>
+</refmeta>
+<refnamediv>
+<refname>no.toc.image</refname>
+<refpurpose>Inactive ToC image</refpurpose>
+</refnamediv>
+
+<refsynopsisdiv>
+<src:fragment id='no.toc.image.frag'>
+<xsl:param name="no.toc.image" select="'inactive/nav-toc.png'"/>
+</src:fragment>
+</refsynopsisdiv>
+
+<refsect1><title>Description</title>
+
+<para>Specifies the filename of the inactive ToC navigation icon.</para>
+
+</refsect1>
+</refentry>
+
+<!-- ====================================================================== -->
+
 <refentry id="plus.image">
 <refmeta>
 <refentrytitle>plus.image</refentrytitle>
@@ -652,7 +840,7 @@ framed ToC.</para>
 
 <refsynopsisdiv>
 <src:fragment id='plus.image.frag'>
-<xsl:param name="plus.image" select="'plus.gif'"/>
+<xsl:param name="plus.image" select="'toc/closed.png'"/>
 </src:fragment>
 </refsynopsisdiv>
 
@@ -677,7 +865,7 @@ can be expanded.</para>
 
 <refsynopsisdiv>
 <src:fragment id='minus.image.frag'>
-<xsl:param name="minus.image" select="'minus.gif'"/>
+<xsl:param name="minus.image" select="'toc/open.png'"/>
 </src:fragment>
 </refsynopsisdiv>
 
@@ -919,6 +1107,151 @@ that you will ever need to change this parameter.</para>
 </refentry>
 </reference>
 
+<reference>
+<title>Localization Parameters</title>
+
+<refentry id="text.home">
+<refmeta>
+<refentrytitle>text.home</refentrytitle>
+<refmiscinfo role="type">string</refmiscinfo>
+</refmeta>
+<refnamediv>
+<refname>text.home</refname>
+<refpurpose>Home</refpurpose>
+</refnamediv>
+
+<refsynopsisdiv>
+<src:fragment id='text.home.frag'>
+<xsl:param name="text.home" select="'Home'"/>
+</src:fragment>
+</refsynopsisdiv>
+
+<refsect1><title>Description</title>
+
+<para>FIXME:</para>
+
+</refsect1>
+</refentry>
+
+<refentry id="text.toc">
+<refmeta>
+<refentrytitle>text.toc</refentrytitle>
+<refmiscinfo role="type">string</refmiscinfo>
+</refmeta>
+<refnamediv>
+<refname>text.toc</refname>
+<refpurpose>FIXME:</refpurpose>
+</refnamediv>
+
+<refsynopsisdiv>
+<src:fragment id='text.toc.frag'>
+<xsl:param name="text.toc" select="'ToC'"/>
+</src:fragment>
+</refsynopsisdiv>
+
+<refsect1><title>Description</title>
+
+<para>FIXME:</para>
+
+</refsect1>
+</refentry>
+
+<refentry id="text.prev">
+<refmeta>
+<refentrytitle>text.prev</refentrytitle>
+<refmiscinfo role="type">string</refmiscinfo>
+</refmeta>
+<refnamediv>
+<refname>text.prev</refname>
+<refpurpose>FIXME:</refpurpose>
+</refnamediv>
+
+<refsynopsisdiv>
+<src:fragment id='text.prev.frag'>
+<xsl:param name="text.prev" select="'Prev'"/>
+</src:fragment>
+</refsynopsisdiv>
+
+<refsect1><title>Description</title>
+
+<para>FIXME:</para>
+
+</refsect1>
+</refentry>
+
+<refentry id="text.up">
+<refmeta>
+<refentrytitle>text.up</refentrytitle>
+<refmiscinfo role="type">string</refmiscinfo>
+</refmeta>
+<refnamediv>
+<refname>text.up</refname>
+<refpurpose>FIXME:</refpurpose>
+</refnamediv>
+
+<refsynopsisdiv>
+<src:fragment id='text.up.frag'>
+<xsl:param name="text.up" select="'Up'"/>
+</src:fragment>
+</refsynopsisdiv>
+
+<refsect1><title>Description</title>
+
+<para>FIXME:</para>
+
+</refsect1>
+</refentry>
+
+<refentry id="text.next">
+<refmeta>
+<refentrytitle>text.next</refentrytitle>
+<refmiscinfo role="type">string</refmiscinfo>
+</refmeta>
+<refnamediv>
+<refname>text.next</refname>
+<refpurpose>FIXME:</refpurpose>
+</refnamediv>
+
+<refsynopsisdiv>
+<src:fragment id='text.next.frag'>
+<xsl:param name="text.next" select="'Next'"/>
+</src:fragment>
+</refsynopsisdiv>
+
+<refsect1><title>Description</title>
+
+<para>FIXME:</para>
+
+</refsect1>
+</refentry>
+
+<!--
+<refentry id="">
+<refmeta>
+<refentrytitle></refentrytitle>
+<refmiscinfo role="type">string</refmiscinfo>
+</refmeta>
+<refnamediv>
+<refname></refname>
+<refpurpose></refpurpose>
+</refnamediv>
+
+<refsynopsisdiv>
+<src:fragment id='.frag'>
+<xsl:param name="" select="''"/>
+</src:fragment>
+</refsynopsisdiv>
+
+<refsect1><title>Description</title>
+
+<para>FIXME:</para>
+
+</refsect1>
+</refentry>
+-->
+
+</reference>
+
 <appendix><title>The Stylesheet</title>
 
 <para>The <filename>param.xsl</filename> stylesheet is just a wrapper
@@ -942,40 +1275,53 @@ around all these parameters.</para>
 
      ******************************************************************** -->
 
-<src:fragref linkend="keyboard.nav.frag"/>
+<src:fragref linkend="active.toc.frag"/>
+<src:fragref linkend="body.bg.color.frag"/>
+<src:fragref linkend="bullet.image.frag"/>
 <src:fragref linkend="css.stylesheet.frag"/>
-<src:fragref linkend="titlefoil.html.frag"/>
-<src:fragref linkend="toc.html.frag"/>
-<src:fragref linkend="output.indent.frag"/>
-<src:fragref linkend="overlay.frag"/>
-<src:fragref linkend="nav.separator.frag"/>
-<src:fragref linkend="toc.row.height.frag"/>
-<src:fragref linkend="toc.bg.color.frag"/>
-<src:fragref linkend="toc.width.frag"/>
-<src:fragref linkend="toc.hide.show.frag"/>
 <src:fragref linkend="dynamic.toc.frag"/>
-<src:fragref linkend="body.bg.color.frag"/>
-<src:fragref linkend="active.toc.frag"/>
-<src:fragref linkend="overlay.logo.frag"/>
-<src:fragref linkend="multiframe.frag"/>
-<src:fragref linkend="multiframe.top.bgcolor.frag"/>
+<src:fragref linkend="graphics.dir.frag"/>
+<src:fragref linkend="hidetoc.image.frag"/>
+<src:fragref linkend="home.image.frag"/>
+<src:fragref linkend="keyboard.nav.frag"/>
+<src:fragref linkend="minus.image.frag"/>
 <src:fragref linkend="multiframe.bottom.bgcolor.frag"/>
+<src:fragref linkend="multiframe.frag"/>
 <src:fragref linkend="multiframe.navigation.height.frag"/>
-<src:fragref linkend="graphics.dir.frag"/>
-<src:fragref linkend="bullet.image.frag"/>
-<src:fragref linkend="right.image.frag"/>
-<src:fragref linkend="left.image.frag"/>
+<src:fragref linkend="multiframe.top.bgcolor.frag"/>
+<src:fragref linkend="nav.separator.frag"/>
+<src:fragref linkend="next.image.frag"/>
+<src:fragref linkend="no.home.image.frag"/>
+<src:fragref linkend="no.next.image.frag"/>
+<src:fragref linkend="no.prev.image.frag"/>
+<src:fragref linkend="no.toc.image.frag"/>
+<src:fragref linkend="no.up.image.frag"/>
+<src:fragref linkend="output.indent.frag"/>
+<src:fragref linkend="overlay.frag"/>
+<src:fragref linkend="overlay.js.frag"/>
+<src:fragref linkend="overlay.logo.frag"/>
 <src:fragref linkend="plus.image.frag"/>
-<src:fragref linkend="minus.image.frag"/>
-<src:fragref linkend="hidetoc.image.frag"/>
-<src:fragref linkend="showtoc.image.frag"/>
+<src:fragref linkend="prev.image.frag"/>
 <src:fragref linkend="script.dir.frag"/>
+<src:fragref linkend="showtoc.image.frag"/>
+<src:fragref linkend="slides.js.frag"/>
+<src:fragref linkend="text.home.frag"/>
+<src:fragref linkend="text.next.frag"/>
+<src:fragref linkend="text.prev.frag"/>
+<src:fragref linkend="text.toc.frag"/>
+<src:fragref linkend="text.up.frag"/>
+<src:fragref linkend="titlefoil.html.frag"/>
+<src:fragref linkend="toc.bg.color.frag"/>
+<src:fragref linkend="toc.hide.show.frag"/>
+<src:fragref linkend="toc.html.frag"/>
+<src:fragref linkend="toc.image.frag"/>
+<src:fragref linkend="toc.row.height.frag"/>
+<src:fragref linkend="toc.width.frag"/>
 <src:fragref linkend="ua.js.frag"/>
+<src:fragref linkend="up.image.frag"/>
+<src:fragref linkend="xbCollapsibleLists.js.frag"/>
 <src:fragref linkend="xbDOM.js.frag"/>
 <src:fragref linkend="xbStyle.js.frag"/>
-<src:fragref linkend="xbCollapsibleLists.js.frag"/>
-<src:fragref linkend="overlay.js.frag"/>
-<src:fragref linkend="slides.js.frag"/>
 
 </xsl:stylesheet>
 </src:fragment>
diff --git a/slides/xsl/plain.xsl b/slides/xsl/plain.xsl
new file mode 100644 (file)
index 0000000..82cfed2
--- /dev/null
@@ -0,0 +1,469 @@
+<?xml version="1.0"?>
+<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+                version="1.0">
+
+<xsl:import href="slides-common.xsl"/>
+
+<xsl:param name="prev.image" select="'active/nav-prev.png'"/>
+<xsl:param name="next.image" select="'active/nav-next.png'"/>
+<xsl:param name="up.image" select="'active/nav-up.png'"/>
+<xsl:param name="toc.image" select="'active/nav-toc.png'"/>
+<xsl:param name="home.image" select="'active/nav-home.png'"/>
+
+<xsl:param name="no.prev.image" select="'inactive/nav-prev.png'"/>
+<xsl:param name="no.next.image" select="'inactive/nav-next.png'"/>
+<xsl:param name="no.up.image" select="'inactive/nav-up.png'"/>
+<xsl:param name="no.toc.image" select="'inactive/nav-toc.png'"/>
+<xsl:param name="no.home.image" select="'inactive/nav-home.png'"/>
+
+<xsl:param name="css.stylesheet" select="'slides-plain.css'"/>
+
+<!-- ====================================================================== -->
+
+<xsl:template name="top-nav">
+  <xsl:param name="prev"/>
+  <xsl:param name="next"/>
+  <xsl:param name="up"/>
+  <xsl:param name="home"/>
+  <xsl:param name="toc" select="$toc.html"/>
+
+  <div class="navhead">
+    <table width="100%" border="0" cellpadding="0" cellspacing="0"
+           summary="Navigation">
+      <tr>
+        <td align="left" width="50%">
+          <span class="slidestitle">
+            <xsl:value-of select="(/slides/slidesinfo/title)[1]"/>
+          </span>
+          <xsl:text>&#160;</xsl:text>
+        </td>
+        <td align="right" width="50%">
+          <xsl:choose>
+            <xsl:when test="$home">
+              <a>
+                <xsl:attribute name="href">
+                  <xsl:apply-templates select="$home" mode="filename"/>
+                </xsl:attribute>
+                <xsl:attribute name="title">
+                  <xsl:value-of select="$home/slidesinfo/title"/>
+                </xsl:attribute>
+                <img alt="Home" border="0">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="home.image"/>
+                  </xsl:attribute>
+                </img>
+              </a>
+            </xsl:when>
+            <xsl:otherwise>
+              <img alt="Home" border="0">
+                <xsl:attribute name="src">
+                  <xsl:call-template name="no.home.image"/>
+                </xsl:attribute>
+              </img>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+
+          <xsl:choose>
+            <xsl:when test="$toc != ''">
+              <a title="ToC" href="{$toc}">
+                <img alt="ToC" border="0">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="toc.image"/>
+                  </xsl:attribute>
+                </img>
+              </a>
+            </xsl:when>
+            <xsl:otherwise>
+              <img alt="ToC" border="0">
+                <xsl:attribute name="src">
+                  <xsl:call-template name="no.toc.image"/>
+                </xsl:attribute>
+              </img>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+
+          <xsl:choose>
+            <xsl:when test="$prev">
+              <a>
+                <xsl:attribute name="href">
+                  <xsl:apply-templates select="$prev" mode="filename"/>
+                </xsl:attribute>
+                <xsl:attribute name="title">
+                  <xsl:value-of select="$prev/title"/>
+                </xsl:attribute>
+                <img alt="Prev" border="0">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="prev.image"/>
+                  </xsl:attribute>
+                </img>
+              </a>
+            </xsl:when>
+            <xsl:otherwise>
+              <img alt="Prev" border="0">
+                <xsl:attribute name="src">
+                  <xsl:call-template name="no.prev.image"/>
+                </xsl:attribute>
+              </img>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+
+          <xsl:choose>
+            <xsl:when test="$up">
+              <a>
+                <xsl:attribute name="href">
+                  <xsl:apply-templates select="$up" mode="filename"/>
+                </xsl:attribute>
+                <xsl:attribute name="title">
+                  <xsl:value-of select="$up/title"/>
+                </xsl:attribute>
+                <img alt="Up" border="0">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="up.image"/>
+                  </xsl:attribute>
+                </img>
+              </a>
+            </xsl:when>
+            <xsl:otherwise>
+              <img alt="Up" border="0">
+                <xsl:attribute name="src">
+                  <xsl:call-template name="no.up.image"/>
+                </xsl:attribute>
+              </img>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+
+          <xsl:choose>
+            <xsl:when test="$next">
+              <a>
+                <xsl:attribute name="href">
+                  <xsl:apply-templates select="$next" mode="filename"/>
+                </xsl:attribute>
+                <xsl:attribute name="title">
+                  <xsl:value-of select="$next/title"/>
+                </xsl:attribute>
+                <img alt="Next" border="0">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="next.image"/>
+                  </xsl:attribute>
+                </img>
+              </a>
+            </xsl:when>
+            <xsl:otherwise>
+              <img alt="Next" border="0">
+                <xsl:attribute name="src">
+                  <xsl:call-template name="no.next.image"/>
+                </xsl:attribute>
+              </img>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+        </td>
+      </tr>
+    </table>
+    <hr class="top-nav-sep"/>
+  </div>
+</xsl:template>
+
+<!-- ============================================================ -->
+
+<xsl:template name="titlepage-top-nav">
+  <xsl:param name="home"/>
+  <xsl:param name="up"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="next"/>
+  <xsl:param name="toc" select="$toc.html"/>
+
+  <div class="navhead">
+    <table width="100%" border="0" cellpadding="0" cellspacing="0"
+           summary="Navigation">
+      <tr>
+        <td align="left" width="50%">
+          <xsl:text>&#160;</xsl:text>
+        </td>
+        <td align="right" width="50%">
+          <xsl:choose>
+            <xsl:when test="$home">
+              <a>
+                <xsl:attribute name="href">
+                  <xsl:apply-templates select="$home" mode="filename"/>
+                </xsl:attribute>
+                <xsl:attribute name="title">
+                  <xsl:value-of select="$home/slidesinfo/title"/>
+                </xsl:attribute>
+                <img alt="Home" border="0">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="home.image"/>
+                  </xsl:attribute>
+                </img>
+              </a>
+            </xsl:when>
+            <xsl:otherwise>
+              <img alt="Home" border="0">
+                <xsl:attribute name="src">
+                  <xsl:call-template name="no.home.image"/>
+                </xsl:attribute>
+              </img>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+
+          <xsl:choose>
+            <xsl:when test="$toc.html != ''">
+              <a title="ToC" href="{$toc.html}">
+                <img alt="ToC" border="0">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="toc.image"/>
+                  </xsl:attribute>
+                </img>
+              </a>
+            </xsl:when>
+            <xsl:otherwise>
+              <img alt="ToC" border="0">
+                <xsl:attribute name="src">
+                  <xsl:call-template name="no.toc.image"/>
+                </xsl:attribute>
+              </img>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+
+          <xsl:choose>
+            <xsl:when test="$prev">
+              <a>
+                <xsl:attribute name="href">
+                  <xsl:apply-templates select="$prev" mode="filename"/>
+                </xsl:attribute>
+                <xsl:attribute name="title">
+                  <xsl:value-of select="$prev/title"/>
+                </xsl:attribute>
+                <img alt="Prev" border="0">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="prev.image"/>
+                  </xsl:attribute>
+                </img>
+              </a>
+            </xsl:when>
+            <xsl:otherwise>
+              <img alt="Prev" border="0">
+                <xsl:attribute name="src">
+                  <xsl:call-template name="no.prev.image"/>
+                </xsl:attribute>
+              </img>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+
+          <xsl:choose>
+            <xsl:when test="$up">
+              <a>
+                <xsl:attribute name="href">
+                  <xsl:apply-templates select="$up" mode="filename"/>
+                </xsl:attribute>
+                <xsl:attribute name="title">
+                  <xsl:value-of select="$up/title"/>
+                </xsl:attribute>
+                <img alt="Up" border="0">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="up.image"/>
+                  </xsl:attribute>
+                </img>
+              </a>
+            </xsl:when>
+            <xsl:otherwise>
+              <img alt="Up" border="0">
+                <xsl:attribute name="src">
+                  <xsl:call-template name="no.up.image"/>
+                </xsl:attribute>
+              </img>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+
+          <xsl:choose>
+            <xsl:when test="$next">
+              <a>
+                <xsl:attribute name="href">
+                  <xsl:apply-templates select="$next" mode="filename"/>
+                </xsl:attribute>
+                <xsl:attribute name="title">
+                  <xsl:value-of select="$next/title"/>
+                </xsl:attribute>
+                <img alt="Next" border="0">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="next.image"/>
+                  </xsl:attribute>
+                </img>
+              </a>
+            </xsl:when>
+            <xsl:otherwise>
+              <img alt="Next" border="0">
+                <xsl:attribute name="src">
+                  <xsl:call-template name="no.next.image"/>
+                </xsl:attribute>
+              </img>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+        </td>
+      </tr>
+    </table>
+    <hr class="top-nav-sep"/>
+  </div>
+</xsl:template>
+
+<!-- ============================================================ -->
+
+<xsl:template name="toc-top-nav">
+  <xsl:param name="home" select="/slides"/>
+  <xsl:param name="up"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="next" select="(foil|foilset)[1]"/>
+  <xsl:param name="toc"/>
+
+  <div class="navhead">
+    <table width="100%" border="0" cellpadding="0" cellspacing="0"
+           summary="Navigation">
+      <tr>
+        <td align="left" width="50%">
+          <xsl:text>&#160;</xsl:text>
+        </td>
+        <td align="right" width="50%">
+          <xsl:choose>
+            <xsl:when test="$home">
+              <a>
+                <xsl:attribute name="href">
+                  <xsl:apply-templates select="$home" mode="filename"/>
+                </xsl:attribute>
+                <xsl:attribute name="title">
+                  <xsl:value-of select="$home/slidesinfo/title"/>
+                </xsl:attribute>
+                <img alt="Home" border="0">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="home.image"/>
+                  </xsl:attribute>
+                </img>
+              </a>
+            </xsl:when>
+            <xsl:otherwise>
+              <img alt="Home" border="0">
+                <xsl:attribute name="src">
+                  <xsl:call-template name="no.home.image"/>
+                </xsl:attribute>
+              </img>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+
+          <xsl:choose>
+            <xsl:when test="$toc != ''">
+              <a title="ToC" href="{$toc}">
+                <img alt="ToC" border="0">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="toc.image"/>
+                  </xsl:attribute>
+                </img>
+              </a>
+            </xsl:when>
+            <xsl:otherwise>
+              <img alt="ToC" border="0">
+                <xsl:attribute name="src">
+                  <xsl:call-template name="no.toc.image"/>
+                </xsl:attribute>
+              </img>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+
+          <xsl:choose>
+            <xsl:when test="$prev">
+              <a>
+                <xsl:attribute name="href">
+                  <xsl:apply-templates select="$prev" mode="filename"/>
+                </xsl:attribute>
+                <xsl:attribute name="title">
+                  <xsl:value-of select="$prev/title"/>
+                </xsl:attribute>
+                <img alt="Prev" border="0">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="prev.image"/>
+                  </xsl:attribute>
+                </img>
+              </a>
+            </xsl:when>
+            <xsl:otherwise>
+              <img alt="Prev" border="0">
+                <xsl:attribute name="src">
+                  <xsl:call-template name="no.prev.image"/>
+                </xsl:attribute>
+              </img>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+
+          <xsl:choose>
+            <xsl:when test="$up">
+              <a>
+                <xsl:attribute name="href">
+                  <xsl:apply-templates select="$up" mode="filename"/>
+                </xsl:attribute>
+                <xsl:attribute name="title">
+                  <xsl:value-of select="$up/title"/>
+                </xsl:attribute>
+                <img alt="Up" border="0">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="up.image"/>
+                  </xsl:attribute>
+                </img>
+              </a>
+            </xsl:when>
+            <xsl:otherwise>
+              <img alt="Up" border="0">
+                <xsl:attribute name="src">
+                  <xsl:call-template name="no.up.image"/>
+                </xsl:attribute>
+              </img>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+
+          <xsl:choose>
+            <xsl:when test="$next">
+              <a>
+                <xsl:attribute name="href">
+                  <xsl:apply-templates select="$next" mode="filename"/>
+                </xsl:attribute>
+                <xsl:attribute name="title">
+                  <xsl:value-of select="$next/title"/>
+                </xsl:attribute>
+                <img alt="Next" border="0">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="next.image"/>
+                  </xsl:attribute>
+                </img>
+              </a>
+            </xsl:when>
+            <xsl:otherwise>
+              <img alt="Next" border="0">
+                <xsl:attribute name="src">
+                  <xsl:call-template name="no.next.image"/>
+                </xsl:attribute>
+              </img>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+        </td>
+      </tr>
+    </table>
+    <hr class="top-nav-sep"/>
+  </div>
+</xsl:template>
+
+<!-- ====================================================================== -->
+
+<xsl:template name="bottom-nav"/>
+
+</xsl:stylesheet>
diff --git a/slides/xsl/slides-common.xsl b/slides/xsl/slides-common.xsl
new file mode 100644 (file)
index 0000000..cbd8bb2
--- /dev/null
@@ -0,0 +1,1320 @@
+<?xml version='1.0'?>
+<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+               version="1.0">
+
+<xsl:import href="http://docbook.sourceforge.net/release/xsl/current/html/chunk.xsl"/>
+
+<xsl:include href="param.xsl"/>
+<xsl:include href="jscript.xsl"/>
+<xsl:include href="graphics.xsl"/>
+
+<xsl:output method="html"/>
+
+<xsl:strip-space elements="slides foil foilgroup"/>
+
+<!-- Process the slides -->
+
+<xsl:template match="/">
+  <xsl:apply-templates/>
+</xsl:template>
+
+<xsl:template match="slides">
+  <xsl:apply-templates select="." mode="toc"/>
+  <xsl:apply-templates/>
+</xsl:template>
+
+<!-- ====================================================================== -->
+<!-- Every slide has top and bottom navigation -->
+
+<xsl:template name="top-nav">
+  <xsl:param name="home"/>
+  <xsl:param name="up"/>
+  <xsl:param name="next"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="tocfile" select="$toc.html"/>
+
+  <div class="navhead">
+    <table border="0" width="100%" cellspacing="0" cellpadding="0"
+           summary="Navigation table">
+      <tr>
+        <td align="left" valign="bottom">
+          <xsl:if test="$home">
+            <span class="slidestitle">
+              <a>
+                <xsl:attribute name="href">
+                  <xsl:apply-templates select="$home" mode="filename"/>
+                </xsl:attribute>
+                <xsl:value-of select="($home/title|$home/slidesinfo/title)[1]"/>
+              </a>
+            </span>
+          </xsl:if>
+          <xsl:text>&#160;</xsl:text>
+        </td>
+
+        <td align="right" valign="bottom">
+          <xsl:choose>
+            <xsl:when test="$home">
+              <span class="link-text">
+                <a>
+                  <xsl:attribute name="href">
+                    <xsl:apply-templates select="$home" mode="filename"/>
+                  </xsl:attribute>
+                  <img alt="{$text.home}" border="0">
+                    <xsl:attribute name="src">
+                      <xsl:call-template name="home.image"/>
+                    </xsl:attribute>
+                  </img>
+                </a>
+              </span>
+            </xsl:when>
+            <xsl:otherwise>
+              <span class="no-link-text">
+                <img alt="{$text.home}" border="0">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="no.home.image"/>
+                  </xsl:attribute>
+                </img>
+              </span>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+
+          <xsl:choose>
+            <xsl:when test="$tocfile">
+              <span class="link-text">
+                <a>
+                  <xsl:attribute name="href">
+                    <xsl:value-of select="$tocfile"/>
+                  </xsl:attribute>
+                  <img alt="{$text.toc}" border="0">
+                    <xsl:attribute name="src">
+                      <xsl:call-template name="toc.image"/>
+                    </xsl:attribute>
+                  </img>
+                </a>
+              </span>
+            </xsl:when>
+            <xsl:otherwise>
+              <span class="no-link-text">
+                <img alt="{$text.toc}" border="0">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="no.toc.image"/>
+                  </xsl:attribute>
+                </img>
+              </span>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+
+          <xsl:choose>
+            <xsl:when test="$prev">
+              <span class="link-text">
+                <a>
+                  <xsl:attribute name="href">
+                    <xsl:apply-templates select="$prev" mode="filename"/>
+                  </xsl:attribute>
+                  <img alt="{$text.prev}" border="0">
+                    <xsl:attribute name="src">
+                      <xsl:call-template name="prev.image"/>
+                    </xsl:attribute>
+                  </img>
+                </a>
+              </span>
+            </xsl:when>
+            <xsl:otherwise>
+              <span class="no-link-text">
+                <img alt="{$text.prev}" border="0">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="no.prev.image"/>
+                  </xsl:attribute>
+                </img>
+              </span>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+
+          <xsl:choose>
+            <xsl:when test="$up">
+              <span class="link-text">
+                <a>
+                  <xsl:attribute name="href">
+                    <xsl:apply-templates select="$up" mode="filename"/>
+                  </xsl:attribute>
+                  <img alt="{$text.up}" border="0">
+                    <xsl:attribute name="src">
+                      <xsl:call-template name="up.image"/>
+                    </xsl:attribute>
+                  </img>
+                </a>
+              </span>
+            </xsl:when>
+            <xsl:otherwise>
+              <span class="no-link-text">
+                <img alt="{$text.up}" border="0">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="no.up.image"/>
+                  </xsl:attribute>
+                </img>
+              </span>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+
+          <xsl:choose>
+            <xsl:when test="$next">
+              <span class="link-text">
+                <a>
+                  <xsl:attribute name="href">
+                    <xsl:apply-templates select="$next" mode="filename"/>
+                  </xsl:attribute>
+                  <img alt="{$text.next}" border="0">
+                    <xsl:attribute name="src">
+                      <xsl:call-template name="next.image"/>
+                    </xsl:attribute>
+                  </img>
+                </a>
+              </span>
+            </xsl:when>
+            <xsl:otherwise>
+              <span class="no-link-text">
+                <img alt="{$text.next}" border="0">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="no.next.image"/>
+                  </xsl:attribute>
+                </img>
+              </span>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+        </td>
+      </tr>
+    </table>
+    <hr class="top-nav-sep"/>
+  </div>
+</xsl:template>
+
+<xsl:template name="bottom-nav">
+  <xsl:param name="home"/>
+  <xsl:param name="up"/>
+  <xsl:param name="next"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="tocfile" select="$toc.html"/>
+
+  <div class="navfoot">
+    <hr class="bottom-nav-sep"/>
+    <table border="0" width="100%" cellspacing="0" cellpadding="0"
+           summary="Navigation table">
+      <tr>
+        <td align="left" valign="top">
+          <xsl:apply-templates select="/slides/slidesinfo/copyright"
+                               mode="slide.footer.mode"/>
+          <xsl:text>&#160;</xsl:text>
+        </td>
+
+        <td align="right" valign="top">
+          <xsl:choose>
+            <xsl:when test="$prev">
+              <span class="link-text">
+                <a>
+                  <xsl:attribute name="href">
+                    <xsl:apply-templates select="$prev" mode="filename"/>
+                  </xsl:attribute>
+                  <img alt="{$text.prev}" border="0">
+                    <xsl:attribute name="src">
+                      <xsl:call-template name="prev.image"/>
+                    </xsl:attribute>
+                  </img>
+                </a>
+              </span>
+            </xsl:when>
+            <xsl:otherwise>
+              <span class="no-link-text">
+                <img alt="{$text.prev}" border="0">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="no.prev.image"/>
+                  </xsl:attribute>
+                </img>
+              </span>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+
+          <xsl:choose>
+            <xsl:when test="$next">
+              <span class="link-text">
+                <a>
+                  <xsl:attribute name="href">
+                    <xsl:apply-templates select="$next" mode="filename"/>
+                  </xsl:attribute>
+                  <img alt="{$text.next}" border="0">
+                    <xsl:attribute name="src">
+                      <xsl:call-template name="next.image"/>
+                    </xsl:attribute>
+                  </img>
+                </a>
+              </span>
+            </xsl:when>
+            <xsl:otherwise>
+              <span class="no-link-text">
+                <img alt="{$text.next}" border="0">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="no.next.image"/>
+                  </xsl:attribute>
+                </img>
+              </span>
+            </xsl:otherwise>
+          </xsl:choose>
+          <xsl:text>&#160;</xsl:text>
+        </td>
+      </tr>
+    </table>
+  </div>
+</xsl:template>
+
+<!-- Navigation is also provided in the form of links in the head -->
+
+<xsl:template name="links">
+  <xsl:param name="home"/>
+  <xsl:param name="up"/>
+  <xsl:param name="next"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="tocfile" select="$toc.html"/>
+
+  <xsl:if test="$tocfile != ''">
+    <link rel="contents" href="{$tocfile}">
+      <xsl:attribute name="title">
+        <xsl:value-of select="/slides/slidesinfo/title"/>
+      </xsl:attribute>
+    </link>
+  </xsl:if>
+
+  <xsl:if test="$home">
+    <link rel="top">
+      <xsl:attribute name="href">
+        <xsl:apply-templates select="$home" mode="filename"/>
+      </xsl:attribute>
+      <xsl:attribute name="title">
+        <xsl:value-of select="($home/title|$home/slidesinfo/title)[1]"/>
+      </xsl:attribute>
+    </link>
+  </xsl:if>
+
+  <xsl:if test="$up">
+    <link rel="up">
+      <xsl:attribute name="href">
+        <xsl:apply-templates select="$up" mode="filename"/>
+      </xsl:attribute>
+      <xsl:attribute name="title">
+        <xsl:value-of select="($up/title|$up/slidesinfo/title)[1]"/>
+      </xsl:attribute>
+    </link>
+  </xsl:if>
+
+  <xsl:if test="$prev">
+    <link rel="previous">
+      <xsl:attribute name="href">
+        <xsl:apply-templates select="$prev" mode="filename"/>
+      </xsl:attribute>
+      <xsl:attribute name="title">
+        <xsl:value-of select="($prev/title|$prev/slidesinfo/title)[1]"/>
+      </xsl:attribute>
+    </link>
+  </xsl:if>
+
+  <xsl:if test="$next">
+    <link rel="next">
+      <xsl:attribute name="href">
+        <xsl:apply-templates select="$next" mode="filename"/>
+      </xsl:attribute>
+      <xsl:attribute name="title">
+        <xsl:value-of select="$next/title"/>
+      </xsl:attribute>
+    </link>
+  </xsl:if>
+
+  <xsl:for-each select="foil">
+    <link rel="slides">
+      <xsl:attribute name="href">
+        <xsl:apply-templates select="." mode="filename"/>
+      </xsl:attribute>
+      <xsl:attribute name="title">
+        <xsl:value-of select="title[1]"/>
+      </xsl:attribute>
+    </link>
+  </xsl:for-each>
+
+  <xsl:for-each select="foilgroup|../foilgroup">
+    <link rel="section">
+      <xsl:attribute name="href">
+        <xsl:apply-templates select="." mode="filename"/>
+      </xsl:attribute>
+      <xsl:attribute name="title">
+        <xsl:value-of select="title[1]"/>
+      </xsl:attribute>
+    </link>
+  </xsl:for-each>
+</xsl:template>
+
+<!-- ====================================================================== -->
+<!-- There are four kinds of slides: titlepage, toc, foil, and foilgroup -->
+<!-- titlepage -->
+
+<xsl:template match="slidesinfo">
+  <xsl:variable name="id">
+    <xsl:call-template name="object.id"/>
+  </xsl:variable>
+
+  <xsl:variable name="next" select="(/slides/foil|/slides/foilgroup)[1]"/>
+  <xsl:variable name="tocfile" select="$toc.html"/>
+
+  <xsl:call-template name="write.chunk">
+    <xsl:with-param name="filename" select="concat($base.dir, $titlefoil.html)"/>
+    <xsl:with-param name="content">
+      <html>
+        <head>
+          <title><xsl:value-of select="title"/></title>
+
+          <!-- Links -->
+
+          <link type="text/css" rel="stylesheet">
+            <xsl:attribute name="href">
+              <xsl:call-template name="css.stylesheet"/>
+            </xsl:attribute>
+          </link>
+
+          <xsl:call-template name="links">
+            <xsl:with-param name="home" select="/slides"/>
+            <xsl:with-param name="next" select="$next"/>
+            <xsl:with-param name="tocfile" select="$tocfile"/>
+          </xsl:call-template>
+
+          <!-- Scripts -->
+
+          <xsl:if test="$overlay != 0 or $keyboard.nav != 0">
+            <script language="JavaScript1.2" type="text/javascript"/>
+          </xsl:if>
+
+          <xsl:if test="$keyboard.nav != 0">
+            <xsl:call-template name="ua.js"/>
+            <xsl:call-template name="xbDOM.js">
+              <xsl:with-param name="language" select="'JavaScript'"/>
+            </xsl:call-template>
+            <xsl:call-template name="xbStyle.js"/>
+            <xsl:call-template name="xbCollapsibleLists.js"/>
+            <xsl:call-template name="slides.js">
+              <xsl:with-param name="language" select="'JavaScript'"/>
+            </xsl:call-template>
+          </xsl:if>
+
+          <xsl:if test="$overlay != '0'">
+            <xsl:call-template name="overlay.js">
+              <xsl:with-param name="language" select="'JavaScript'"/>
+            </xsl:call-template>
+          </xsl:if>
+        </head>
+        <body class="titlepage">
+          <xsl:call-template name="body.attributes"/>
+          <xsl:if test="$overlay != 0">
+            <xsl:attribute name="onload">
+              <xsl:text>overlaySetup('lc')</xsl:text>
+            </xsl:attribute>
+          </xsl:if>
+          <xsl:if test="$keyboard.nav != 0">
+            <xsl:attribute name="onkeypress">
+              <xsl:text>navigate(event)</xsl:text>
+            </xsl:attribute>
+          </xsl:if>
+
+          <div class="titlepage">
+            <a name="{$id}"/>
+            <xsl:call-template name="titlepage-top-nav">
+              <xsl:with-param name="next" select="$next"/>
+              <xsl:with-param name="tocfile" select="$tocfile"/>
+            </xsl:call-template>
+
+            <div class="titlepage-body">
+              <xsl:call-template name="titlepage-body"/>
+            </div>
+
+            <div id="overlayDiv">
+              <xsl:call-template name="overlayDiv.attributes"/>
+              <xsl:call-template name="titlepage-bottom-nav">
+                <xsl:with-param name="next" select="$next"/>
+                <xsl:with-param name="tocfile" select="$tocfile"/>
+              </xsl:call-template>
+            </div>
+          </div>
+        </body>
+      </html>
+    </xsl:with-param>
+  </xsl:call-template>
+</xsl:template>
+
+<xsl:template name="titlepage-body">
+  <div class="{name(.)}">
+    <xsl:apply-templates mode="titlepage.mode"/>
+  </div>
+</xsl:template>
+
+<xsl:template name="titlepage-top-nav">
+  <xsl:param name="home"/>
+  <xsl:param name="up"/>
+  <xsl:param name="next"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="tocfile" select="$toc.html"/>
+
+  <xsl:call-template name="top-nav">
+    <xsl:with-param name="home" select="$home"/>
+    <xsl:with-param name="up" select="$up"/>
+    <xsl:with-param name="next" select="$next"/>
+    <xsl:with-param name="prev" select="$prev"/>
+    <xsl:with-param name="tocfile" select="$tocfile"/>
+  </xsl:call-template>
+</xsl:template>
+
+<xsl:template name="titlepage-bottom-nav">
+  <xsl:param name="home"/>
+  <xsl:param name="up"/>
+  <xsl:param name="next"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="tocfile" select="$toc.html"/>
+
+  <xsl:call-template name="bottom-nav">
+    <xsl:with-param name="home" select="$home"/>
+    <xsl:with-param name="up" select="$up"/>
+    <xsl:with-param name="next" select="$next"/>
+    <xsl:with-param name="prev" select="$prev"/>
+    <xsl:with-param name="tocfile" select="$tocfile"/>
+  </xsl:call-template>
+</xsl:template>
+
+<xsl:template match="slidesinfo/title">
+  <h1 class="{name(.)}"><xsl:apply-templates/></h1>
+</xsl:template>
+
+<xsl:template match="slidesinfo/authorgroup">
+  <xsl:apply-templates/>
+</xsl:template>
+
+<xsl:template match="slidesinfo/author|slidesinfo/authorgroup/author">
+  <h1 class="{name(.)}"><xsl:apply-imports/></h1>
+</xsl:template>
+
+<xsl:template match="slidesinfo/releaseinfo">
+  <h4 class="{name(.)}"><xsl:apply-templates/></h4>
+</xsl:template>
+
+<xsl:template match="slidesinfo/date">
+  <h4 class="{name(.)}"><xsl:apply-templates/></h4>
+</xsl:template>
+
+<xsl:template match="slidesinfo/copyright">
+  <!-- nop -->
+</xsl:template>
+
+<!-- ====================================================================== -->
+<!-- toc -->
+
+<xsl:template match="slides" mode="toc">
+  <xsl:variable name="id">
+    <xsl:call-template name="object.id"/>
+  </xsl:variable>
+
+  <xsl:variable name="home" select="/slides"/>
+  <xsl:variable name="up" select="/slides"/>
+  <xsl:variable name="next" select="(foil|foilgroup)[1]"/>
+  <xsl:variable name="tocfile" select="''"/>
+
+  <xsl:call-template name="write.chunk">
+    <xsl:with-param name="filename" select="concat($base.dir, $toc.html)"/>
+    <xsl:with-param name="content">
+      <html>
+        <head>
+          <title><xsl:value-of select="slidesinfo/title"/></title>
+
+          <!-- Links -->
+
+          <link type="text/css" rel="stylesheet">
+            <xsl:attribute name="href">
+              <xsl:call-template name="css.stylesheet"/>
+            </xsl:attribute>
+          </link>
+
+          <xsl:call-template name="links">
+            <xsl:with-param name="home" select="$home"/>
+            <xsl:with-param name="up" select="$up"/>
+            <xsl:with-param name="next" select="$next"/>
+            <xsl:with-param name="tocfile" select="$tocfile"/>
+          </xsl:call-template>
+
+          <!-- Scripts -->
+
+          <xsl:if test="$overlay != 0 or $keyboard.nav != 0">
+            <script language="JavaScript1.2" type="text/javascript"/>
+          </xsl:if>
+
+          <xsl:if test="$keyboard.nav != 0">
+            <xsl:call-template name="ua.js"/>
+            <xsl:call-template name="xbDOM.js">
+              <xsl:with-param name="language" select="'JavaScript'"/>
+            </xsl:call-template>
+            <xsl:call-template name="xbStyle.js"/>
+            <xsl:call-template name="xbCollapsibleLists.js"/>
+            <xsl:call-template name="slides.js">
+              <xsl:with-param name="language" select="'JavaScript'"/>
+            </xsl:call-template>
+          </xsl:if>
+
+          <xsl:if test="$overlay != '0'">
+            <xsl:call-template name="overlay.js">
+              <xsl:with-param name="language" select="'JavaScript'"/>
+            </xsl:call-template>
+          </xsl:if>
+        </head>
+
+        <body class="tocpage">
+          <xsl:call-template name="body.attributes"/>
+          <xsl:if test="$overlay != 0">
+            <xsl:attribute name="onload">
+              <xsl:text>overlaySetup('lc')</xsl:text>
+            </xsl:attribute>
+          </xsl:if>
+          <xsl:if test="$keyboard.nav != 0">
+            <xsl:attribute name="onkeypress">
+              <xsl:text>navigate(event)</xsl:text>
+            </xsl:attribute>
+          </xsl:if>
+
+          <div>
+            <a name="{$id}.toc"/>
+            <xsl:call-template name="toc-top-nav">
+              <xsl:with-param name="home" select="$home"/>
+              <xsl:with-param name="up" select="$up"/>
+              <xsl:with-param name="next" select="$next"/>
+              <xsl:with-param name="tocfile" select="$tocfile"/>
+            </xsl:call-template>
+
+            <div class="toc-body">
+              <xsl:call-template name="toc-body"/>
+            </div>
+
+            <xsl:call-template name="toc-bottom-nav">
+              <xsl:with-param name="home" select="$home"/>
+              <xsl:with-param name="up" select="$up"/>
+              <xsl:with-param name="next" select="$next"/>
+              <xsl:with-param name="tocfile" select="$tocfile"/>
+            </xsl:call-template>
+          </div>
+        </body>
+      </html>
+    </xsl:with-param>
+  </xsl:call-template>
+</xsl:template>
+
+<xsl:template name="toc-body">
+  <h1 class="title">
+    <a href="{$titlefoil.html}">
+      <xsl:value-of select="/slides/slidesinfo/title"/>
+    </a>
+  </h1>
+
+  <p class="toctitle">
+    <b>
+      <xsl:call-template name="gentext">
+        <xsl:with-param name="key">TableofContents</xsl:with-param>
+      </xsl:call-template>
+    </b>
+  </p>
+  <dl>
+    <xsl:apply-templates select="foilgroup|foil" mode="toc"/>
+  </dl>
+</xsl:template>
+
+<xsl:template name="toc-top-nav">
+  <xsl:param name="home" select="/slides"/>
+  <xsl:param name="up"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="next" select="(foil|foilgroup)[1]"/>
+  <xsl:param name="tocfile"/>
+
+  <xsl:call-template name="top-nav">
+    <xsl:with-param name="home" select="$home"/>
+    <xsl:with-param name="up" select="$up"/>
+    <xsl:with-param name="next" select="$next"/>
+    <xsl:with-param name="prev" select="$prev"/>
+    <xsl:with-param name="tocfile" select="$tocfile"/>
+  </xsl:call-template>
+</xsl:template>
+
+<xsl:template name="toc-bottom-nav">
+  <xsl:param name="home" select="/slides"/>
+  <xsl:param name="up"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="next" select="(foil|foilgroup)[1]"/>
+  <xsl:param name="tocfile"/>
+
+  <xsl:call-template name="bottom-nav">
+    <xsl:with-param name="home" select="$home"/>
+    <xsl:with-param name="up" select="$up"/>
+    <xsl:with-param name="next" select="$next"/>
+    <xsl:with-param name="prev" select="$prev"/>
+    <xsl:with-param name="tocfile" select="$tocfile"/>
+  </xsl:call-template>
+</xsl:template>
+
+<xsl:template match="foilgroup" mode="toc">
+  <dt>
+    <xsl:apply-templates select="." mode="number"/>
+    <xsl:text>. </xsl:text>
+    <a>
+      <xsl:attribute name="href">
+        <xsl:apply-templates select="." mode="filename"/>
+      </xsl:attribute>
+      <xsl:value-of select="title"/>
+    </a>
+  </dt>
+  <dd>
+    <dl>
+      <xsl:apply-templates select="foil" mode="toc"/>
+    </dl>
+  </dd>
+</xsl:template>
+
+<xsl:template match="foil" mode="toc">
+  <dt>
+    <xsl:apply-templates select="." mode="number"/>
+    <xsl:text>. </xsl:text>
+    <a>
+      <xsl:attribute name="href">
+        <xsl:apply-templates select="." mode="filename"/>
+      </xsl:attribute>
+      <xsl:value-of select="title"/>
+    </a>
+  </dt>
+</xsl:template>
+
+<xsl:template match="title|titleabbrev" mode="toc">
+  <xsl:apply-templates mode="toc"/>
+</xsl:template>
+
+<xsl:template match="speakernotes" mode="toc">
+  <!-- nop -->
+</xsl:template>
+
+<!-- ====================================================================== -->
+<!-- foil -->
+
+<xsl:template match="foil">
+  <xsl:param name="thisfoil">
+    <xsl:apply-templates select="." mode="filename"/>
+  </xsl:param>
+
+  <xsl:variable name="id">
+    <xsl:call-template name="object.id"/>
+  </xsl:variable>
+
+  <xsl:variable name="home" select="/slides"/>
+  <xsl:variable name="up"   select="(parent::slides|parent::foilgroup)[1]"/>
+  <xsl:variable name="next" select="(following::foil
+                                    |following::foilgroup)[1]"/>
+  <xsl:variable name="prev" select="(preceding-sibling::foil[1]
+                                    |parent::foilgroup[1]
+                                    |/slides)[last()]"/>
+
+  <xsl:call-template name="write.chunk">
+    <xsl:with-param name="indent" select="$output.indent"/>
+    <xsl:with-param name="filename" select="concat($base.dir, $thisfoil)"/>
+    <xsl:with-param name="content">
+      <html>
+        <head>
+          <title><xsl:value-of select="title"/></title>
+
+          <!-- Links -->
+
+          <link type="text/css" rel="stylesheet">
+            <xsl:attribute name="href">
+              <xsl:call-template name="css.stylesheet"/>
+            </xsl:attribute>
+          </link>
+
+          <xsl:call-template name="links">
+            <xsl:with-param name="home" select="$home"/>
+            <xsl:with-param name="up" select="$up"/>
+            <xsl:with-param name="next" select="$next"/>
+            <xsl:with-param name="prev" select="$prev"/>
+          </xsl:call-template>
+
+          <!-- Scripts -->
+
+          <xsl:if test="$overlay != 0 or $keyboard.nav != 0">
+            <script language="JavaScript1.2" type="text/javascript"/>
+          </xsl:if>
+
+          <xsl:if test="$keyboard.nav != 0">
+            <xsl:call-template name="ua.js"/>
+            <xsl:call-template name="xbDOM.js">
+              <xsl:with-param name="language" select="'JavaScript'"/>
+            </xsl:call-template>
+            <xsl:call-template name="xbStyle.js"/>
+            <xsl:call-template name="xbCollapsibleLists.js"/>
+            <xsl:call-template name="slides.js">
+              <xsl:with-param name="language" select="'JavaScript'"/>
+            </xsl:call-template>
+          </xsl:if>
+
+          <xsl:if test="$overlay != '0'">
+            <xsl:call-template name="overlay.js">
+              <xsl:with-param name="language" select="'JavaScript'"/>
+            </xsl:call-template>
+          </xsl:if>
+        </head>
+        <body class="foil">
+          <xsl:call-template name="body.attributes"/>
+          <xsl:if test="$overlay != 0">
+            <xsl:attribute name="onload">
+              <xsl:text>overlaySetup('lc')</xsl:text>
+            </xsl:attribute>
+          </xsl:if>
+          <xsl:if test="$keyboard.nav != 0">
+            <xsl:attribute name="onkeypress">
+              <xsl:text>navigate(event)</xsl:text>
+            </xsl:attribute>
+          </xsl:if>
+
+          <div class="{name(.)}">
+            <a name="{$id}"/>
+            <xsl:call-template name="foil-top-nav">
+              <xsl:with-param name="home" select="$home"/>
+              <xsl:with-param name="up" select="$up"/>
+              <xsl:with-param name="next" select="$next"/>
+              <xsl:with-param name="prev" select="$prev"/>
+            </xsl:call-template>
+
+            <div class="foil-body">
+              <xsl:call-template name="foil-body">
+                <xsl:with-param name="home" select="$home"/>
+                <xsl:with-param name="up" select="$up"/>
+                <xsl:with-param name="next" select="$next"/>
+                <xsl:with-param name="prev" select="$prev"/>
+              </xsl:call-template>
+            </div>
+
+            <div id="overlayDiv">
+              <xsl:call-template name="overlayDiv.attributes"/>
+              <xsl:call-template name="foil-bottom-nav">
+                <xsl:with-param name="home" select="$home"/>
+                <xsl:with-param name="up" select="$up"/>
+                <xsl:with-param name="next" select="$next"/>
+                <xsl:with-param name="prev" select="$prev"/>
+              </xsl:call-template>
+            </div>
+          </div>
+        </body>
+      </html>
+    </xsl:with-param>
+  </xsl:call-template>
+</xsl:template>
+
+<xsl:template name="foil-body">
+  <xsl:param name="home"/>
+  <xsl:param name="up"/>
+  <xsl:param name="next"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="tocfile" select="$toc.html"/>
+
+  <xsl:apply-templates/>
+</xsl:template>
+
+<xsl:template name="foil-top-nav">
+  <xsl:param name="home"/>
+  <xsl:param name="up"/>
+  <xsl:param name="next"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="tocfile" select="$toc.html"/>
+
+  <xsl:call-template name="top-nav">
+    <xsl:with-param name="home" select="$home"/>
+    <xsl:with-param name="up" select="$up"/>
+    <xsl:with-param name="next" select="$next"/>
+    <xsl:with-param name="prev" select="$prev"/>
+  </xsl:call-template>
+</xsl:template>
+
+<xsl:template name="foil-bottom-nav">
+  <xsl:param name="home"/>
+  <xsl:param name="up"/>
+  <xsl:param name="next"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="tocfile" select="$toc.html"/>
+
+  <xsl:call-template name="bottom-nav">
+    <xsl:with-param name="home" select="$home"/>
+    <xsl:with-param name="up" select="$up"/>
+    <xsl:with-param name="next" select="$next"/>
+    <xsl:with-param name="prev" select="$prev"/>
+  </xsl:call-template>
+</xsl:template>
+
+<xsl:template match="foil/title">
+  <h1 class="{name(.)}">
+    <xsl:apply-templates/>
+  </h1>
+</xsl:template>
+
+<!-- ====================================================================== -->
+<!-- foilgroup -->
+
+<xsl:template match="foilgroup">
+  <xsl:param name="thisfoilgroup">
+    <xsl:apply-templates select="." mode="filename"/>
+  </xsl:param>
+
+  <xsl:variable name="id">
+    <xsl:call-template name="object.id"/>
+  </xsl:variable>
+
+  <xsl:variable name="home" select="/slides"/>
+  <xsl:variable name="up" select="(parent::slides|parent::foilgroup)[1]"/>
+  <xsl:variable name="next" select="foil[1]"/>
+  <xsl:variable name="prev" select="(preceding::foil|parent::foilgroup|/slides)[last()]"/>
+
+  <xsl:call-template name="write.chunk">
+    <xsl:with-param name="indent" select="$output.indent"/>
+    <xsl:with-param name="filename" select="concat($base.dir, $thisfoilgroup)"/>
+    <xsl:with-param name="content">
+      <head>
+        <title><xsl:value-of select="title"/></title>
+
+          <!-- Links -->
+
+        <link type="text/css" rel="stylesheet">
+          <xsl:attribute name="href">
+            <xsl:call-template name="css.stylesheet"/>
+          </xsl:attribute>
+        </link>
+
+        <xsl:call-template name="links">
+          <xsl:with-param name="home" select="$home"/>
+          <xsl:with-param name="up" select="$up"/>
+          <xsl:with-param name="next" select="$next"/>
+          <xsl:with-param name="prev" select="$prev"/>
+        </xsl:call-template>
+
+        <!-- Scripts -->
+
+        <xsl:if test="$overlay != 0 or $keyboard.nav != 0">
+          <script language="JavaScript1.2" type="text/javascript"/>
+        </xsl:if>
+
+        <xsl:if test="$keyboard.nav != 0">
+          <xsl:call-template name="ua.js"/>
+          <xsl:call-template name="xbDOM.js">
+            <xsl:with-param name="language" select="'JavaScript'"/>
+          </xsl:call-template>
+          <xsl:call-template name="xbStyle.js"/>
+          <xsl:call-template name="xbCollapsibleLists.js"/>
+          <xsl:call-template name="slides.js">
+            <xsl:with-param name="language" select="'JavaScript'"/>
+          </xsl:call-template>
+        </xsl:if>
+
+        <xsl:if test="$overlay != '0'">
+          <xsl:call-template name="overlay.js">
+            <xsl:with-param name="language" select="'JavaScript'"/>
+          </xsl:call-template>
+        </xsl:if>
+      </head>
+      <body class="foilgroup">
+        <xsl:call-template name="body.attributes"/>
+        <xsl:if test="$overlay != 0">
+          <xsl:attribute name="onload">
+            <xsl:text>overlaySetup('lc')</xsl:text>
+          </xsl:attribute>
+        </xsl:if>
+        <xsl:if test="$keyboard.nav != 0">
+          <xsl:attribute name="onkeypress">
+            <xsl:text>navigate(event)</xsl:text>
+          </xsl:attribute>
+        </xsl:if>
+
+        <div class="{name(.)}">
+          <a name="{$id}"/>
+          <xsl:call-template name="foilgroup-top-nav">
+            <xsl:with-param name="home" select="$home"/>
+            <xsl:with-param name="up" select="$up"/>
+            <xsl:with-param name="next" select="$next"/>
+            <xsl:with-param name="prev" select="$prev"/>
+          </xsl:call-template>
+
+          <div class="foilgroup-body">
+            <xsl:call-template name="foilgroup-body">
+              <xsl:with-param name="home" select="$home"/>
+              <xsl:with-param name="up" select="$up"/>
+              <xsl:with-param name="next" select="$next"/>
+              <xsl:with-param name="prev" select="$prev"/>
+            </xsl:call-template>
+          </div>
+
+          <div id="overlayDiv">
+            <xsl:call-template name="overlayDiv.attributes"/>
+            <xsl:call-template name="foilgroup-bottom-nav">
+              <xsl:with-param name="home" select="$home"/>
+              <xsl:with-param name="up" select="$up"/>
+              <xsl:with-param name="next" select="$next"/>
+              <xsl:with-param name="prev" select="$prev"/>
+            </xsl:call-template>
+          </div>
+        </div>
+      </body>
+    </xsl:with-param>
+  </xsl:call-template>
+
+  <xsl:apply-templates select="foil"/>
+</xsl:template>
+
+<xsl:template match="foilgroup/title">
+  <h1 class="{name(.)}"><xsl:apply-templates/></h1>
+</xsl:template>
+
+<xsl:template name="foilgroup-body">
+  <xsl:param name="home"/>
+  <xsl:param name="up"/>
+  <xsl:param name="next"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="tocfile" select="$toc.html"/>
+
+  <xsl:apply-templates select="*[name(.) != 'foil'
+                                and name(.) != 'foilgroup']"/>
+</xsl:template>
+
+<xsl:template name="foilgroup-top-nav">
+  <xsl:param name="home"/>
+  <xsl:param name="up"/>
+  <xsl:param name="next"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="tocfile" select="$toc.html"/>
+
+  <xsl:call-template name="top-nav">
+    <xsl:with-param name="home" select="$home"/>
+    <xsl:with-param name="up" select="$up"/>
+    <xsl:with-param name="next" select="$next"/>
+    <xsl:with-param name="prev" select="$prev"/>
+  </xsl:call-template>
+</xsl:template>
+
+<xsl:template name="foilgroup-bottom-nav">
+  <xsl:param name="home"/>
+  <xsl:param name="up"/>
+  <xsl:param name="next"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="tocfile" select="$toc.html"/>
+
+  <xsl:call-template name="bottom-nav">
+    <xsl:with-param name="home" select="$home"/>
+    <xsl:with-param name="up" select="$up"/>
+    <xsl:with-param name="next" select="$next"/>
+    <xsl:with-param name="prev" select="$prev"/>
+  </xsl:call-template>
+</xsl:template>
+
+<!-- ====================================================================== -->
+
+<xsl:template name="overlayDiv.attributes">
+  <xsl:choose>
+    <xsl:when test="$overlay != 0">
+      <xsl:attribute name="style">
+        <xsl:text>position: absolute; visibility: visible;</xsl:text>
+      </xsl:attribute>
+    </xsl:when>
+    <xsl:otherwise>
+      <xsl:attribute name="style">padding-top: 2in;</xsl:attribute>
+    </xsl:otherwise>
+  </xsl:choose>
+</xsl:template>
+
+<!-- ====================================================================== -->
+
+<xsl:template name="css.stylesheet">
+  <!-- danger will robinson: template shadows parameter -->
+  <xsl:variable name="source.css.stylesheet">
+    <xsl:call-template name="dbhtml-attribute">
+      <xsl:with-param name="pis" select="/processing-instruction('dbhtml')"/>
+      <xsl:with-param name="attribute" select="'css-stylesheet'"/>
+    </xsl:call-template>
+  </xsl:variable>
+
+  <xsl:variable name="source.css.stylesheet.dir">
+    <xsl:call-template name="dbhtml-attribute">
+      <xsl:with-param name="pis" select="/processing-instruction('dbhtml')"/>
+      <xsl:with-param name="attribute" select="'css-stylesheet-dir'"/>
+    </xsl:call-template>
+  </xsl:variable>
+
+  <xsl:choose>
+    <xsl:when test="$source.css.stylesheet != ''">
+      <xsl:value-of select="$source.css.stylesheet"/>
+    </xsl:when>
+    <xsl:otherwise>
+      <xsl:if test="$source.css.stylesheet.dir != ''">
+        <xsl:value-of select="$source.css.stylesheet.dir"/>
+        <xsl:text>/</xsl:text>
+      </xsl:if>
+      <xsl:value-of select="$css.stylesheet"/>
+    </xsl:otherwise>
+  </xsl:choose>
+</xsl:template>
+
+<!-- ====================================================================== -->
+
+<xsl:template match="foil" mode="number">
+  <xsl:number count="foil|foilgroup" level="any"/>
+</xsl:template>
+
+<xsl:template match="foilgroup" mode="number">
+  <xsl:number count="foil|foilgroup" level="any"/>
+</xsl:template>
+
+<!-- ====================================================================== -->
+
+<xsl:template match="slides" mode="filename">
+  <xsl:value-of select="$titlefoil.html"/>
+</xsl:template>
+
+<xsl:template match="foil" mode="filename">
+  <xsl:text>foil</xsl:text>
+  <xsl:number count="foil" level="any" format="01"/>
+  <xsl:text>.html</xsl:text>
+</xsl:template>
+
+<xsl:template match="foilgroup" mode="filename">
+  <xsl:text>foilgrp</xsl:text>
+  <xsl:number count="foilgroup" level="any" format="01"/>
+  <xsl:text>.html</xsl:text>
+</xsl:template>
+
+<!-- ============================================================ -->
+
+<xsl:template match="processing-instruction('Pub')">
+  <xsl:variable name="pidata"><xsl:value-of select="(.)"/></xsl:variable>
+  <xsl:choose>
+    <xsl:when test="contains($pidata,'UDT')"></xsl:when>
+    <xsl:when test="contains($pidata,'/_font')">
+      <xsl:text disable-output-escaping="yes">&lt;/span&gt;</xsl:text>
+    </xsl:when>
+    <xsl:when test="contains($pidata,'_font')">
+      <xsl:text disable-output-escaping="yes">&lt;span </xsl:text>
+      <xsl:choose>
+        <xsl:when test="contains($pidata,'green')">class="green"</xsl:when>
+        <xsl:when test="contains($pidata,'blue')">class="blue"</xsl:when>
+        <xsl:when test="contains($pidata,'orange')">class="orange"</xsl:when>
+        <xsl:when test="contains($pidata,'red')">class="red"</xsl:when>
+        <xsl:when test="contains($pidata,'brown')">class="brown"</xsl:when>
+        <xsl:when test="contains($pidata,'violet')">class="violet"</xsl:when>
+        <xsl:when test="contains($pidata,'black')">class="black"</xsl:when>
+        <xsl:otherwise>class="bold"</xsl:otherwise>
+      </xsl:choose>
+      <xsl:text disable-output-escaping="yes">&gt;</xsl:text>
+    </xsl:when>
+  </xsl:choose>
+</xsl:template>
+
+<!-- ============================================================ -->
+<!-- blocks -->
+
+<xsl:template match="figure">
+  <div class="{name(.)}">
+    <xsl:apply-imports/>
+  </div>
+  <xsl:if test="following-sibling::*"><hr/></xsl:if>
+</xsl:template>
+
+<xsl:template match="copyright" mode="slide.footer.mode">
+  <span class="{name(.)}">
+    <xsl:call-template name="gentext">
+      <xsl:with-param name="key" select="'Copyright'"/>
+    </xsl:call-template>
+    <xsl:call-template name="gentext.space"/>
+    <xsl:call-template name="dingbat">
+      <xsl:with-param name="dingbat">copyright</xsl:with-param>
+    </xsl:call-template>
+    <xsl:call-template name="gentext.space"/>
+    <xsl:call-template name="copyright.years">
+      <xsl:with-param name="years" select="year"/>
+      <xsl:with-param name="print.ranges" select="$make.year.ranges"/>
+      <xsl:with-param name="single.year.ranges"
+                      select="$make.single.year.ranges"/>
+    </xsl:call-template>
+    <xsl:call-template name="gentext.space"/>
+    <xsl:apply-templates select="holder" mode="titlepage.mode"/>
+  </span>
+</xsl:template>
+
+<!-- ============================================================ -->
+<!-- inlines -->
+
+<xsl:template match="link">
+  <xsl:call-template name="link">
+    <xsl:with-param name="a.target" select="'foil'"/>
+  </xsl:call-template>
+</xsl:template>
+
+<xsl:template match="ulink">
+  <a>
+    <xsl:if test="@id">
+      <xsl:attribute name="name"><xsl:value-of select="@id"/></xsl:attribute>
+    </xsl:if>
+    <xsl:attribute name="href"><xsl:value-of select="@url"/></xsl:attribute>
+    <xsl:if test="$ulink.target != ''">
+      <xsl:attribute name="target">
+        <xsl:value-of select="$ulink.target"/>
+      </xsl:attribute>
+    </xsl:if>
+    <xsl:choose>
+      <xsl:when test="count(child::node())=0">
+       <xsl:value-of select="@url"/>
+      </xsl:when>
+      <xsl:otherwise>
+       <xsl:apply-templates/>
+        <xsl:if test="@role='show'">
+          <xsl:text> (</xsl:text>
+          <xsl:value-of select="@url"/>
+          <xsl:text>)</xsl:text>
+        </xsl:if>
+      </xsl:otherwise>
+    </xsl:choose>
+  </a>
+</xsl:template>
+
+<xsl:template match="title/ulink">
+  <a>
+    <xsl:if test="@id">
+      <xsl:attribute name="name"><xsl:value-of select="@id"/></xsl:attribute>
+    </xsl:if>
+    <xsl:attribute name="href"><xsl:value-of select="@url"/></xsl:attribute>
+    <xsl:if test="$ulink.target != ''">
+      <xsl:attribute name="target">
+        <xsl:value-of select="$ulink.target"/>
+      </xsl:attribute>
+    </xsl:if>
+    <xsl:choose>
+      <xsl:when test="count(child::node())=0">
+       <xsl:value-of select="@url"/>
+      </xsl:when>
+      <xsl:otherwise>
+       <xsl:apply-templates/>
+      </xsl:otherwise>
+    </xsl:choose>
+  </a>
+</xsl:template>
+
+<xsl:template match="graphic">
+  <center>
+    <!-- can't this be done a better way? -->
+    <xsl:apply-imports/>
+  </center>
+</xsl:template>
+
+<xsl:template match="titleabbrev">
+  <!-- nop -->
+</xsl:template>
+
+<xsl:template match="speakernotes">
+  <!-- nop -->
+</xsl:template>
+
+<!-- ====================================================================== -->
+<!-- Chunking for slides -->
+
+<xsl:template name="chunk">
+  <xsl:param name="node" select="."/>
+  <xsl:choose>
+    <xsl:when test="name($node)='slides'">1</xsl:when>
+    <xsl:when test="name($node)='foilgroup'">1</xsl:when>
+    <xsl:when test="name($node)='foil'">1</xsl:when>
+    <xsl:otherwise>0</xsl:otherwise>
+  </xsl:choose>
+</xsl:template>
+
+<xsl:template match="*" mode="chunk-filename">
+  <xsl:param name="recursive">0</xsl:param>
+  <!-- returns the filename of a chunk -->
+  <xsl:variable name="ischunk"><xsl:call-template name="chunk"/></xsl:variable>
+  <xsl:variable name="filename">
+    <xsl:call-template name="dbhtml-filename"/>
+  </xsl:variable>
+  <xsl:variable name="dir">
+    <xsl:call-template name="dbhtml-dir"/>
+  </xsl:variable>
+
+  <xsl:choose>
+    <xsl:when test="$ischunk='0'">
+      <!-- if called on something that isn't a chunk, walk up... -->
+      <xsl:choose>
+        <xsl:when test="count(./parent::*)>0">
+          <xsl:apply-templates mode="chunk-filename" select="./parent::*">
+            <xsl:with-param name="recursive" select="$recursive"/>
+          </xsl:apply-templates>
+        </xsl:when>
+        <!-- unless there is no up, in which case return "" -->
+        <xsl:otherwise></xsl:otherwise>
+      </xsl:choose>
+    </xsl:when>
+
+    <xsl:when test="not($recursive) and $filename != ''">
+      <!-- if this chunk has an explicit name, use it -->
+      <xsl:if test="$dir != ''">
+        <xsl:value-of select="$dir"/>
+        <xsl:text>/</xsl:text>
+      </xsl:if>
+      <xsl:value-of select="$filename"/>
+    </xsl:when>
+
+    <xsl:when test="name(.)='foil'">
+      <xsl:variable name="foilnumber">
+       <xsl:number count="foil" level="any"/>
+      </xsl:variable>
+
+      <xsl:text>foil</xsl:text>
+      <xsl:number value="$foilnumber" format="01"/>
+      <xsl:text>.html</xsl:text>
+    </xsl:when>
+
+    <xsl:when test="name(.)='foilgroup'">
+      <xsl:variable name="foilgroupnumber">
+        <xsl:number count="foilgroup" level="any" format="01"/>
+      </xsl:variable>
+
+      <xsl:text>foilgroup</xsl:text>
+      <xsl:number value="$foilgroupnumber" format="01"/>
+      <xsl:text>.html</xsl:text>
+    </xsl:when>
+
+    <xsl:otherwise>
+      <xsl:text>chunk-filename-error-</xsl:text>
+      <xsl:value-of select="name(.)"/>
+      <xsl:number level="any" format="01" from="set"/>
+      <xsl:if test="not($recursive)">
+        <xsl:value-of select="$html.ext"/>
+      </xsl:if>
+    </xsl:otherwise>
+  </xsl:choose>
+</xsl:template>
+
+<!-- ====================================================================== -->
+
+<xsl:template match="@*" mode="copy">
+  <xsl:attribute name="{local-name(.)}">
+    <xsl:value-of select="."/>
+  </xsl:attribute>
+</xsl:template>
+
+<xsl:template match="html:*" xmlns:html='http://www.w3.org/1999/xhtml'>
+  <xsl:element name="{local-name(.)}" namespace="">
+    <xsl:apply-templates select="@*" mode="copy"/>
+    <xsl:apply-templates/>
+  </xsl:element>
+</xsl:template>
+
+<!-- ====================================================================== -->
+
+</xsl:stylesheet>
diff --git a/slides/xsl/slides.xsl b/slides/xsl/slides.xsl
deleted file mode 100644 (file)
index ae203b2..0000000
+++ /dev/null
@@ -1,1364 +0,0 @@
-<?xml version='1.0'?>
-<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
-               version="1.0">
-
-<xsl:import href="http://docbook.sourceforge.net/release/xsl/current/html/chunk.xsl"/>
-<xsl:include href="param.xsl"/>
-<xsl:include href="jscript.xsl"/>
-<xsl:include href="graphics.xsl"/>
-
-<xsl:output method="html"/>
-
-<xsl:strip-space elements="slides foil section"/>
-
-<!-- ============================================================ -->
-
-<xsl:template name="overlayDiv.attributes">
-  <xsl:choose>
-    <xsl:when test="$overlay != 0">
-      <xsl:attribute name="style">
-        <xsl:text>position: absolute; visibility: visible;</xsl:text>
-      </xsl:attribute>
-    </xsl:when>
-    <xsl:otherwise>
-      <xsl:attribute name="style">padding-top: 2in;</xsl:attribute>
-    </xsl:otherwise>
-  </xsl:choose>
-</xsl:template>
-
-<!-- ============================================================ -->
-
-<xsl:template name="css.stylesheet">
-  <!-- danger will robinson: template shadows parameter -->
-  <xsl:variable name="source.css.stylesheet">
-    <xsl:call-template name="dbhtml-attribute">
-      <xsl:with-param name="pis" select="/processing-instruction('dbhtml')"/>
-      <xsl:with-param name="attribute" select="'css-stylesheet'"/>
-    </xsl:call-template>
-  </xsl:variable>
-
-  <xsl:choose>
-    <xsl:when test="$source.css.stylesheet != ''">
-      <xsl:value-of select="$source.css.stylesheet"/>
-    </xsl:when>
-    <xsl:otherwise>
-      <xsl:value-of select="$css.stylesheet"/>
-    </xsl:otherwise>
-  </xsl:choose>
-</xsl:template>
-
-<!-- ============================================================ -->
-
-<xsl:template match="/">
-  <xsl:apply-templates/>
-</xsl:template>
-
-<xsl:template match="slides">
-  <xsl:call-template name="write.chunk">
-    <xsl:with-param name="indent" select="$output.indent"/>
-    <xsl:with-param name="filename" select="concat($base.dir, $toc.html)"/>
-    <xsl:with-param name="content">
-      <html>
-        <head>
-          <title><xsl:value-of select="slidesinfo/title"/></title>
-          <link type="text/css" rel="stylesheet">
-            <xsl:attribute name="href">
-              <xsl:call-template name="css.stylesheet"/>
-            </xsl:attribute>
-          </link>
-
-          <link rel="top">
-            <xsl:attribute name="href">
-              <xsl:apply-templates select="/slides" mode="filename"/>
-            </xsl:attribute>
-            <xsl:attribute name="title">
-              <xsl:value-of select="/slides/slidesinfo/title[1]"/>
-            </xsl:attribute>
-          </link>
-
-          <xsl:for-each select="section">
-            <link rel="section">
-              <xsl:attribute name="href">
-                <xsl:apply-templates select="." mode="filename"/>
-              </xsl:attribute>
-              <xsl:attribute name="title">
-                <xsl:value-of select="title[1]"/>
-              </xsl:attribute>
-            </link>
-          </xsl:for-each>
-
-          <xsl:if test="$overlay != 0 or $keyboard.nav != 0">
-            <script language="JavaScript1.2"/>
-          </xsl:if>
-
-          <xsl:if test="$keyboard.nav != 0">
-            <xsl:call-template name="ua.js"/>
-            <xsl:call-template name="xbDOM.js">
-              <xsl:with-param name="language" select="'JavaScript'"/>
-            </xsl:call-template>
-            <xsl:call-template name="xbStyle.js"/>
-            <xsl:call-template name="xbCollapsibleLists.js"/>
-            <xsl:call-template name="slides.js">
-              <xsl:with-param name="language" select="'JavaScript'"/>
-            </xsl:call-template>
-          </xsl:if>
-
-          <xsl:if test="$overlay != '0'">
-            <xsl:call-template name="overlay.js">
-              <xsl:with-param name="language" select="'JavaScript'"/>
-            </xsl:call-template>
-          </xsl:if>
-        </head>
-        <body class="tocpage">
-          <xsl:call-template name="body.attributes"/>
-          <xsl:if test="$overlay != 0">
-            <xsl:attribute name="onload">
-              <xsl:text>overlaySetup('lc')</xsl:text>
-            </xsl:attribute>
-          </xsl:if>
-          <xsl:if test="$keyboard.nav != 0">
-            <xsl:attribute name="onkeypress">
-              <xsl:text>navigate(event)</xsl:text>
-            </xsl:attribute>
-          </xsl:if>
-
-          <h1 class="title">
-            <a href="{$titlefoil.html}">
-              <xsl:value-of select="/slides/slidesinfo/title"/>
-            </a>
-          </h1>
-
-          <xsl:apply-templates select="." mode="toc"/>
-
-          <div id="overlayDiv" class="navfoot">
-            <xsl:call-template name="overlayDiv.attributes"/>
-            <xsl:if test="$overlay != 0">
-              <hr/>
-            </xsl:if>
-
-            <table width="100%" border="0"
-                   cellspacing="0" cellpadding="0"
-                   summary="Navigation">
-              <tr>
-                <td align="left" width="80%" valign="top">
-                  <span class="navfooter">
-                    <xsl:apply-templates select="/slides/slidesinfo/copyright"
-                                         mode="slide.navigation.mode"/>
-                  </span>
-                </td>
-                <td align="right" width="20%" valign="top">
-                  <a href="{$titlefoil.html}">
-                    <img alt="Next" border="0">
-                      <xsl:attribute name="src">
-                        <xsl:call-template name="right.image"/>
-                      </xsl:attribute>
-                    </img>
-                  </a>
-                </td>
-              </tr>
-            </table>
-          </div>
-        </body>
-      </html>
-    </xsl:with-param>
-  </xsl:call-template>
-
-  <xsl:apply-templates/>
-</xsl:template>
-
-<!-- ============================================================ -->
-
-<xsl:template match="slidesinfo">
-  <xsl:call-template name="write.chunk">
-    <xsl:with-param name="indent" select="$output.indent"/>
-    <xsl:with-param name="filename"
-                    select="concat($base.dir, $titlefoil.html)"/>
-    <xsl:with-param name="content">
-      <html>
-        <head>
-          <title><xsl:value-of select="title"/></title>
-          <link type="text/css" rel="stylesheet">
-            <xsl:attribute name="href">
-              <xsl:call-template name="css.stylesheet"/>
-            </xsl:attribute>
-          </link>
-
-          <link rel="contents" href="{$toc.html}">
-            <xsl:attribute name="title">
-              <xsl:value-of select="(following::section|following::foil)[1]/title"/>
-            </xsl:attribute>
-          </link>
-
-          <link rel="next">
-            <xsl:attribute name="href">
-              <xsl:apply-templates select="(following::section|following::foil)[1]"
-                                   mode="filename"/>
-            </xsl:attribute>
-            <xsl:attribute name="title">
-              <xsl:value-of select="(following::section|following::foil)[1]/title"/>
-            </xsl:attribute>
-          </link>
-
-          <xsl:for-each select="../section">
-            <link rel="section">
-              <xsl:attribute name="href">
-                <xsl:apply-templates select="." mode="filename"/>
-              </xsl:attribute>
-              <xsl:attribute name="title">
-                <xsl:value-of select="title[1]"/>
-              </xsl:attribute>
-            </link>
-          </xsl:for-each>
-
-          <xsl:if test="$overlay != 0 or $keyboard.nav != 0">
-            <script language="JavaScript1.2"/>
-          </xsl:if>
-
-          <xsl:if test="$keyboard.nav != 0">
-            <xsl:call-template name="ua.js"/>
-            <xsl:call-template name="xbDOM.js">
-              <xsl:with-param name="language" select="'JavaScript'"/>
-            </xsl:call-template>
-            <xsl:call-template name="xbStyle.js"/>
-            <xsl:call-template name="xbCollapsibleLists.js"/>
-            <xsl:call-template name="slides.js">
-              <xsl:with-param name="language" select="'JavaScript'"/>
-            </xsl:call-template>
-          </xsl:if>
-
-          <xsl:if test="$overlay != '0'">
-            <xsl:call-template name="overlay.js">
-              <xsl:with-param name="language" select="'JavaScript'"/>
-            </xsl:call-template>
-          </xsl:if>
-        </head>
-        <body class="titlepage">
-          <xsl:call-template name="body.attributes"/>
-          <xsl:if test="$overlay != 0">
-            <xsl:attribute name="onload">
-              <xsl:text>overlaySetup('lc')</xsl:text>
-            </xsl:attribute>
-          </xsl:if>
-          <xsl:if test="$keyboard.nav != 0">
-            <xsl:attribute name="onkeypress">
-              <xsl:text>navigate(event)</xsl:text>
-            </xsl:attribute>
-          </xsl:if>
-
-          <xsl:call-template name="slidesinfo-top-nav"/>
-
-          <xsl:call-template name="slidesinfo-titlepage"/>
-
-          <div id="overlayDiv" class="navfoot">
-            <xsl:call-template name="overlayDiv.attributes"/>
-            <xsl:if test="$overlay != 0">
-              <hr/>
-            </xsl:if>
-            <xsl:call-template name="slidesinfo-bottom-nav"/>
-          </div>
-        </body>
-      </html>
-    </xsl:with-param>
-  </xsl:call-template>
-</xsl:template>
-
-<xsl:template name="slidesinfo-titlepage">
-  <div class="{name(.)}">
-    <xsl:apply-templates mode="titlepage.mode"/>
-  </div>
-</xsl:template>
-
-<xsl:template name="slidesinfo-top-nav">
-  <xsl:param name="prev-target" select="''"/>
-  <xsl:param name="next-target" select="''"/>
-
-  <div class="navhead">
-    <table width="100%" border="0" cellpadding="0" cellspacing="0"
-           summary="Navigation">
-      <tr>
-        <td align="left" width="10%">
-          <a href="{$toc.html}">
-            <xsl:call-template name="gentext">
-              <xsl:with-param name="key">TableofContents</xsl:with-param>
-            </xsl:call-template>
-          </a>
-        </td>
-        <td align="center" width="80%">
-          <xsl:text>&#160;</xsl:text>
-        </td>
-        <td align="right" width="10%">
-          <xsl:text>&#160;</xsl:text>
-        </td>
-      </tr>
-    </table>
-  </div>
-</xsl:template>
-
-<xsl:template name="slidesinfo-bottom-nav">
-  <xsl:param name="prev-target" select="''"/>
-  <xsl:param name="next-target" select="''"/>
-
-  <table width="100%" border="0"
-         cellspacing="0" cellpadding="0"
-         summary="Navigation">
-    <tr>
-      <td align="left" width="80%" valign="top">
-        <span class="navfooter">
-          <xsl:apply-templates select="/slides/slidesinfo/copyright"
-                               mode="slide.navigation.mode"/>
-        </span>
-      </td>
-      <td align="right" width="20%" valign="top">
-        <a>
-          <xsl:attribute name="href">
-            <xsl:apply-templates select="(following::section|following::foil)[1]"
-                                 mode="filename"/>
-          </xsl:attribute>
-          <img alt="Next" border="0">
-            <xsl:attribute name="src">
-              <xsl:call-template name="right.image"/>
-            </xsl:attribute>
-          </img>
-        </a>
-      </td>
-    </tr>
-  </table>
-</xsl:template>
-
-<xsl:template match="slidesinfo/title">
-  <h1 class="{name(.)}"><xsl:apply-templates/></h1>
-</xsl:template>
-
-<xsl:template match="slidesinfo/authorgroup">
-  <xsl:apply-templates/>
-</xsl:template>
-
-<xsl:template match="slidesinfo/author|slidesinfo/authorgroup/author">
-  <h1 class="{name(.)}"><xsl:apply-imports/></h1>
-</xsl:template>
-
-<xsl:template match="slidesinfo/releaseinfo">
-  <h4 class="{name(.)}"><xsl:apply-templates/></h4>
-</xsl:template>
-
-<xsl:template match="slidesinfo/date">
-  <h4 class="{name(.)}"><xsl:apply-templates/></h4>
-</xsl:template>
-
-<xsl:template match="slidesinfo/copyright">
-  <!-- nop -->
-</xsl:template>
-
-<xsl:template match="copyright" mode="slide.navigation.mode">
-  <xsl:variable name="years" select="year"/>
-  <xsl:variable name="holders" select="holder"/>
-
-  <span class="{name(.)}">
-    <xsl:call-template name="gentext">
-      <xsl:with-param name="key" select="'Copyright'"/>
-    </xsl:call-template>
-    <xsl:call-template name="gentext.space"/>
-    <xsl:call-template name="dingbat">
-      <xsl:with-param name="dingbat">copyright</xsl:with-param>
-    </xsl:call-template>
-    <xsl:call-template name="gentext.space"/>
-    <xsl:apply-templates select="$years" mode="titlepage.mode"/>
-    <xsl:call-template name="gentext.space"/>
-    <xsl:apply-templates select="$holders" mode="titlepage.mode"/>
-  </span>
-</xsl:template>
-
-<!-- ============================================================ -->
-
-<xsl:template match="section">
-  <xsl:variable name="id">
-    <xsl:call-template name="object.id"/>
-  </xsl:variable>
-
-  <xsl:variable name="snumber">
-    <xsl:number count="section" level="any"/>
-  </xsl:variable>
-
-  <xsl:variable name="thissection">
-    <xsl:text>section</xsl:text>
-    <xsl:number value="$snumber" format="01"/>
-    <xsl:text>.html</xsl:text>
-  </xsl:variable>
-
-  <xsl:variable name="prevfoil"
-                select="(preceding::foil|/slides)[last()]"/>
-
-  <xsl:variable name="nextfoil" select="foil[1]"/>
-
-  <xsl:call-template name="write.chunk">
-    <xsl:with-param name="indent" select="$output.indent"/>
-    <xsl:with-param name="filename" select="concat($base.dir, $thissection)"/>
-    <xsl:with-param name="content">
-      <head>
-        <title><xsl:value-of select="title"/></title>
-        <link type="text/css" rel="stylesheet">
-          <xsl:attribute name="href">
-            <xsl:call-template name="css.stylesheet"/>
-          </xsl:attribute>
-        </link>
-
-        <xsl:call-template name="section-links"/>
-
-        <xsl:if test="$overlay != 0 or $keyboard.nav != 0">
-          <script language="JavaScript1.2"/>
-        </xsl:if>
-
-        <xsl:if test="$keyboard.nav != 0">
-          <xsl:call-template name="ua.js"/>
-          <xsl:call-template name="xbDOM.js">
-            <xsl:with-param name="language" select="'JavaScript'"/>
-          </xsl:call-template>
-          <xsl:call-template name="xbStyle.js"/>
-          <xsl:call-template name="xbCollapsibleLists.js"/>
-          <xsl:call-template name="slides.js">
-            <xsl:with-param name="language" select="'JavaScript'"/>
-          </xsl:call-template>
-        </xsl:if>
-
-        <xsl:if test="$overlay != '0'">
-          <xsl:call-template name="overlay.js">
-            <xsl:with-param name="language" select="'JavaScript'"/>
-          </xsl:call-template>
-        </xsl:if>
-      </head>
-      <body class="section">
-        <xsl:call-template name="body.attributes"/>
-        <xsl:if test="$overlay != 0">
-          <xsl:attribute name="onload">
-            <xsl:text>overlaySetup('lc')</xsl:text>
-          </xsl:attribute>
-        </xsl:if>
-        <xsl:if test="$keyboard.nav != 0">
-          <xsl:attribute name="onkeypress">
-            <xsl:text>navigate(event)</xsl:text>
-          </xsl:attribute>
-        </xsl:if>
-
-        <div class="{name(.)}" id="{$id}">
-          <a name="{$id}"/>
-          <xsl:call-template name="section-top-nav"/>
-
-          <xsl:apply-templates select="title"/>
-
-          <div id="overlayDiv">
-            <xsl:call-template name="overlayDiv.attributes"/>
-            <xsl:call-template name="section-bottom-nav"/>
-          </div>
-        </div>
-      </body>
-    </xsl:with-param>
-  </xsl:call-template>
-
-  <xsl:apply-templates select="foil"/>
-</xsl:template>
-
-<xsl:template match="section/title">
-  <h1 class="{name(.)}"><xsl:apply-templates/></h1>
-</xsl:template>
-
-<xsl:template match="section/title" mode="navheader">
-  <span class="navheader"><xsl:apply-templates/></span>
-</xsl:template>
-
-<xsl:template match="slides/title" mode="navheader">
-  <span class="navheader"><xsl:apply-templates/></span>
-</xsl:template>
-
-<xsl:template match="slides/slidesinfo/title" mode="navheader">
-  <span class="navheader"><xsl:apply-templates/></span>
-</xsl:template>
-
-<xsl:template name="section-links">
-  <xsl:variable name="prevfoil"
-                select="(preceding::foil|/slides)[last()]"/>
-
-  <xsl:variable name="nextfoil" select="foil[1]"/>
-
-  <link rel="contents" href="{$toc.html}">
-    <xsl:attribute name="title">
-      <xsl:value-of select="(following::section|following::foil)[1]/title"/>
-    </xsl:attribute>
-  </link>
-
-  <link rel="top">
-    <xsl:attribute name="href">
-      <xsl:apply-templates select="/slides" mode="filename"/>
-    </xsl:attribute>
-    <xsl:attribute name="title">
-      <xsl:value-of select="/slides/slidesinfo/title[1]"/>
-    </xsl:attribute>
-  </link>
-
-  <xsl:if test="parent::section">
-    <link rel="up">
-      <xsl:attribute name="href">
-        <xsl:apply-templates select="parent::section[1]" mode="filename"/>
-      </xsl:attribute>
-      <xsl:attribute name="title">
-        <xsl:value-of select="parent::section[1]/title"/>
-      </xsl:attribute>
-    </link>
-  </xsl:if>
-
-  <xsl:if test="$prevfoil">
-    <link rel="previous">
-      <xsl:attribute name="href">
-        <xsl:apply-templates select="$prevfoil" mode="filename"/>
-      </xsl:attribute>
-      <xsl:attribute name="title">
-        <xsl:value-of select="$prevfoil/title"/>
-      </xsl:attribute>
-    </link>
-  </xsl:if>
-
-  <xsl:if test="$nextfoil">
-    <link rel="next">
-      <xsl:attribute name="href">
-        <xsl:apply-templates select="$nextfoil" mode="filename"/>
-      </xsl:attribute>
-      <xsl:attribute name="title">
-        <xsl:value-of select="$nextfoil/title"/>
-      </xsl:attribute>
-    </link>
-  </xsl:if>
-
-  <xsl:for-each select="foil">
-    <link rel="slides">
-      <xsl:attribute name="href">
-        <xsl:apply-templates select="." mode="filename"/>
-      </xsl:attribute>
-      <xsl:attribute name="title">
-        <xsl:value-of select="title[1]"/>
-      </xsl:attribute>
-    </link>
-  </xsl:for-each>
-
-  <xsl:for-each select="../section">
-    <link rel="section">
-      <xsl:attribute name="href">
-        <xsl:apply-templates select="." mode="filename"/>
-      </xsl:attribute>
-      <xsl:attribute name="title">
-        <xsl:value-of select="title[1]"/>
-      </xsl:attribute>
-    </link>
-  </xsl:for-each>
-</xsl:template>
-
-<!-- ============================================================ -->
-
-<xsl:template match="foil">
-  <xsl:variable name="id">
-    <xsl:call-template name="object.id"/>
-  </xsl:variable>
-
-  <xsl:variable name="thisfoil">
-    <xsl:apply-templates select="." mode="filename"/>
-  </xsl:variable>
-
-  <xsl:variable name="nextfoil" select="(following::foil
-                                        |following::section)[1]"/>
-
-  <xsl:variable name="prevfoil" select="(preceding-sibling::foil[1]
-                                        |parent::section[1]
-                                        |/slides)[last()]"/>
-
-  <xsl:call-template name="write.chunk">
-    <xsl:with-param name="indent" select="$output.indent"/>
-    <xsl:with-param name="filename" select="concat($base.dir, $thisfoil)"/>
-    <xsl:with-param name="content">
-      <head>
-        <title><xsl:value-of select="title"/></title>
-        <link type="text/css" rel="stylesheet">
-          <xsl:attribute name="href">
-            <xsl:call-template name="css.stylesheet"/>
-          </xsl:attribute>
-        </link>
-
-        <xsl:call-template name="foil-links"/>
-
-        <xsl:if test="$overlay != 0 or $keyboard.nav != 0">
-          <script language="JavaScript1.2"/>
-        </xsl:if>
-
-        <xsl:if test="$keyboard.nav != 0">
-          <xsl:call-template name="ua.js"/>
-          <xsl:call-template name="xbDOM.js">
-            <xsl:with-param name="language" select="'JavaScript'"/>
-          </xsl:call-template>
-          <xsl:call-template name="xbStyle.js"/>
-          <xsl:call-template name="xbCollapsibleLists.js"/>
-          <xsl:call-template name="slides.js">
-            <xsl:with-param name="language" select="'JavaScript'"/>
-          </xsl:call-template>
-        </xsl:if>
-
-        <xsl:if test="$overlay != '0'">
-          <xsl:call-template name="overlay.js">
-            <xsl:with-param name="language" select="'JavaScript'"/>
-          </xsl:call-template>
-        </xsl:if>
-      </head>
-      <body class="foil">
-        <xsl:call-template name="body.attributes"/>
-        <xsl:if test="$overlay != 0">
-          <xsl:attribute name="onload">
-            <xsl:text>overlaySetup('lc')</xsl:text>
-          </xsl:attribute>
-        </xsl:if>
-        <xsl:if test="$keyboard.nav != 0">
-          <xsl:attribute name="onkeypress">
-            <xsl:text>navigate(event)</xsl:text>
-          </xsl:attribute>
-        </xsl:if>
-
-        <div class="{name(.)}" id="{$id}">
-          <a name="{$id}"/>
-          <xsl:call-template name="foil-top-nav"/>
-
-          <xsl:apply-templates/>
-
-          <div id="overlayDiv">
-            <xsl:call-template name="overlayDiv.attributes"/>
-            <xsl:call-template name="foil-bottom-nav"/>
-          </div>
-        </div>
-      </body>
-    </xsl:with-param>
-  </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="foil" mode="foilnumber">
-  <xsl:number count="foil" level="any"/>
-</xsl:template>
-
-<xsl:template match="slides" mode="filename">
-  <xsl:value-of select="$titlefoil.html"/>
-</xsl:template>
-
-<xsl:template match="foil" mode="filename">
-  <xsl:text>foil</xsl:text>
-  <xsl:number count="foil" level="any" format="01"/>
-  <xsl:text>.html</xsl:text>
-</xsl:template>
-
-<xsl:template match="section" mode="filename">
-  <xsl:text>section</xsl:text>
-  <xsl:number count="section" level="any" format="01"/>
-  <xsl:text>.html</xsl:text>
-</xsl:template>
-
-<xsl:template match="foil/title">
-  <h1 class="{name(.)}">
-    <xsl:apply-templates/>
-  </h1>
-</xsl:template>
-
-<xsl:template name="foil-links">
-  <xsl:variable name="nextfoil" select="(following::foil
-                                        |following::section)[1]"/>
-
-  <xsl:variable name="prevfoil" select="(preceding-sibling::foil[1]
-                                        |parent::section[1]
-                                        |/slides)[last()]"/>
-
-
-  <link rel="contents" href="{$toc.html}">
-    <xsl:attribute name="title">
-      <xsl:value-of select="(following::section|following::foil)[1]/title"/>
-    </xsl:attribute>
-  </link>
-
-  <link rel="top">
-    <xsl:attribute name="href">
-      <xsl:apply-templates select="/slides" mode="filename"/>
-    </xsl:attribute>
-    <xsl:attribute name="title">
-      <xsl:value-of select="/slides/slidesinfo/title[1]"/>
-    </xsl:attribute>
-  </link>
-
-  <xsl:if test="parent::section">
-    <link rel="up">
-      <xsl:attribute name="href">
-        <xsl:apply-templates select="parent::section[1]" mode="filename"/>
-      </xsl:attribute>
-      <xsl:attribute name="title">
-        <xsl:value-of select="parent::section[1]/title"/>
-      </xsl:attribute>
-    </link>
-  </xsl:if>
-
-  <xsl:if test="$prevfoil">
-    <link rel="previous">
-      <xsl:attribute name="href">
-        <xsl:apply-templates select="$prevfoil" mode="filename"/>
-      </xsl:attribute>
-      <xsl:attribute name="title">
-        <xsl:value-of select="$prevfoil/title"/>
-      </xsl:attribute>
-    </link>
-  </xsl:if>
-
-  <xsl:if test="preceding-sibling::foil">
-    <link rel="first">
-      <xsl:attribute name="href">
-        <xsl:apply-templates select="preceding-sibling::foil[last()]"
-                             mode="filename"/>
-      </xsl:attribute>
-      <xsl:attribute name="title">
-        <xsl:value-of select="preceding-sibling::foil[last()]/title"/>
-      </xsl:attribute>
-    </link>
-  </xsl:if>
-
-  <xsl:if test="$nextfoil">
-    <link rel="next">
-      <xsl:attribute name="href">
-        <xsl:apply-templates select="$nextfoil" mode="filename"/>
-      </xsl:attribute>
-      <xsl:attribute name="title">
-        <xsl:value-of select="$nextfoil/title"/>
-      </xsl:attribute>
-    </link>
-  </xsl:if>
-
-  <xsl:if test="following-sibling::foil">
-    <link rel="last">
-      <xsl:attribute name="href">
-        <xsl:apply-templates select="following-sibling::foil[last()]"
-                             mode="filename"/>
-      </xsl:attribute>
-      <xsl:attribute name="title">
-        <xsl:value-of select="following-sibling::foil[last()]/title"/>
-      </xsl:attribute>
-    </link>
-  </xsl:if>
-
-  <xsl:for-each select="../../section">
-    <link rel="section">
-      <xsl:attribute name="href">
-        <xsl:apply-templates select="." mode="filename"/>
-      </xsl:attribute>
-      <xsl:attribute name="title">
-        <xsl:value-of select="title[1]"/>
-      </xsl:attribute>
-    </link>
-  </xsl:for-each>
-
-  <xsl:for-each select="../foil">
-    <link rel="slides">
-      <xsl:attribute name="href">
-        <xsl:apply-templates select="." mode="filename"/>
-      </xsl:attribute>
-      <xsl:attribute name="title">
-        <xsl:value-of select="title[1]"/>
-      </xsl:attribute>
-    </link>
-  </xsl:for-each>
-</xsl:template>
-
-<!-- ============================================================ -->
-
-<xsl:template match="processing-instruction('Pub')">
-  <xsl:variable name="pidata"><xsl:value-of select="(.)"/></xsl:variable>
-  <xsl:choose>
-    <xsl:when test="contains($pidata,'UDT')"></xsl:when>
-    <xsl:when test="contains($pidata,'/_font')">
-      <xsl:text disable-output-escaping="yes">&lt;/span&gt;</xsl:text>
-    </xsl:when>
-    <xsl:when test="contains($pidata,'_font')">
-      <xsl:text disable-output-escaping="yes">&lt;span </xsl:text>
-      <xsl:choose>
-        <xsl:when test="contains($pidata,'green')">class="green"</xsl:when>
-        <xsl:when test="contains($pidata,'blue')">class="blue"</xsl:when>
-        <xsl:when test="contains($pidata,'orange')">class="orange"</xsl:when>
-        <xsl:when test="contains($pidata,'red')">class="red"</xsl:when>
-        <xsl:when test="contains($pidata,'brown')">class="brown"</xsl:when>
-        <xsl:when test="contains($pidata,'violet')">class="violet"</xsl:when>
-        <xsl:when test="contains($pidata,'black')">class="black"</xsl:when>
-        <xsl:otherwise>class="bold"</xsl:otherwise>
-      </xsl:choose>
-      <xsl:text disable-output-escaping="yes">&gt;</xsl:text>
-    </xsl:when>
-  </xsl:choose>
-</xsl:template>
-
-<!-- ============================================================ -->
-<!-- blocks -->
-
-<xsl:template match="figure">
-  <div class="{name(.)}">
-    <xsl:apply-imports/>
-  </div>
-  <xsl:if test="following-sibling::*"><hr/></xsl:if>
-</xsl:template>
-
-<!-- ============================================================ -->
-<!-- inlines -->
-
-<xsl:template match="link">
-  <xsl:call-template name="link">
-    <xsl:with-param name="a.target" select="'foil'"/>
-  </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="ulink">
-  <a>
-    <xsl:if test="@id">
-      <xsl:attribute name="name"><xsl:value-of select="@id"/></xsl:attribute>
-    </xsl:if>
-    <xsl:attribute name="href"><xsl:value-of select="@url"/></xsl:attribute>
-    <xsl:if test="$ulink.target != ''">
-      <xsl:attribute name="target">
-        <xsl:value-of select="$ulink.target"/>
-      </xsl:attribute>
-    </xsl:if>
-    <xsl:choose>
-      <xsl:when test="count(child::node())=0">
-       <xsl:value-of select="@url"/>
-      </xsl:when>
-      <xsl:otherwise>
-       <xsl:apply-templates/>
-        <xsl:if test="@role='show'">
-          <xsl:text> (</xsl:text>
-          <xsl:value-of select="@url"/>
-          <xsl:text>)</xsl:text>
-        </xsl:if>
-      </xsl:otherwise>
-    </xsl:choose>
-  </a>
-</xsl:template>
-
-<xsl:template match="title/ulink">
-  <a>
-    <xsl:if test="@id">
-      <xsl:attribute name="name"><xsl:value-of select="@id"/></xsl:attribute>
-    </xsl:if>
-    <xsl:attribute name="href"><xsl:value-of select="@url"/></xsl:attribute>
-    <xsl:if test="$ulink.target != ''">
-      <xsl:attribute name="target">
-        <xsl:value-of select="$ulink.target"/>
-      </xsl:attribute>
-    </xsl:if>
-    <xsl:choose>
-      <xsl:when test="count(child::node())=0">
-       <xsl:value-of select="@url"/>
-      </xsl:when>
-      <xsl:otherwise>
-       <xsl:apply-templates/>
-      </xsl:otherwise>
-    </xsl:choose>
-  </a>
-</xsl:template>
-
-<xsl:template match="graphic">
-  <center>
-    <!-- can't this be done a better way? -->
-    <xsl:apply-imports/>
-  </center>
-</xsl:template>
-
-<xsl:template match="titleabbrev">
-  <!-- nop -->
-</xsl:template>
-
-<xsl:template match="speakernotes">
-  <!-- nop -->
-</xsl:template>
-
-<!-- ============================================================ -->
-
-<xsl:template match="slides" mode="toc">
-  <p class="toctitle">
-    <b>
-      <xsl:call-template name="gentext">
-        <xsl:with-param name="key">TableofContents</xsl:with-param>
-      </xsl:call-template>
-    </b>
-  </p>
-  <dl>
-    <xsl:apply-templates select="section|foil" mode="toc"/>
-  </dl>
-</xsl:template>
-
-<xsl:template match="section" mode="toc">
-  <xsl:variable name="snumber">
-    <xsl:number count="section" level="any"/>
-  </xsl:variable>
-
-  <xsl:variable name="thissection">
-    <xsl:text>section</xsl:text>
-    <xsl:number value="$snumber" format="01"/>
-    <xsl:text>.html</xsl:text>
-  </xsl:variable>
-
-  <dt>
-    <a href="{$thissection}">
-      <xsl:value-of select="title"/>
-    </a>
-  </dt>
-  <dd>
-    <dl>
-      <xsl:apply-templates select="foil" mode="toc"/>
-    </dl>
-  </dd>
-</xsl:template>
-
-<xsl:template match="foil" mode="toc">
-  <xsl:variable name="thisfoil">
-    <xsl:apply-templates select="." mode="filename"/>
-  </xsl:variable>
-
-  <dt>
-    <xsl:apply-templates select="." mode="foilnumber"/>
-    <xsl:text>. </xsl:text>
-    <a href="{$thisfoil}">
-      <xsl:value-of select="title"/>
-    </a>
-  </dt>
-</xsl:template>
-
-<xsl:template match="title|titleabbrev" mode="toc">
-  <xsl:apply-templates mode="toc"/>
-</xsl:template>
-
-<xsl:template match="speakernotes" mode="toc">
-  <!-- nop -->
-</xsl:template>
-
-<!-- ============================================================ -->
-
-<xsl:template match="slidesinfo" mode="ns-toc">
-  <xsl:variable name="id">
-    <xsl:call-template name="object.id"/>
-  </xsl:variable>
-
-  <xsl:text>myList.addItem('</xsl:text>
-
-  <xsl:text disable-output-escaping="yes">&lt;DIV id="</xsl:text>
-  <xsl:value-of select="$id"/>
-  <xsl:text disable-output-escaping="yes">" class="toc-slidesinfo"&gt;</xsl:text>
-
-  <xsl:text disable-output-escaping="yes">&lt;A href="</xsl:text>
-  <xsl:value-of select="$titlefoil.html"/>
-  <xsl:text disable-output-escaping="yes">" target="foil"&gt;</xsl:text>
-
-  <xsl:choose>
-    <xsl:when test="titleabbrev">
-      <xsl:value-of select="titleabbrev"/>
-    </xsl:when>
-    <xsl:otherwise>
-      <xsl:value-of select="title"/>
-    </xsl:otherwise>
-  </xsl:choose>
-
-  <xsl:text disable-output-escaping="yes">&lt;/A&gt;&lt;/DIV&gt;</xsl:text>
-  <xsl:text>');&#10;</xsl:text>
-</xsl:template>
-
-<xsl:template match="section" mode="ns-toc">
-  <xsl:variable name="id">
-    <xsl:call-template name="object.id"/>
-  </xsl:variable>
-
-  <xsl:text>subList = new List(false, width, height, "</xsl:text>
-<xsl:value-of select="$toc.bg.color"/>
-<xsl:text>");&#10;</xsl:text>
-  <xsl:text>subList.setIndent(12);&#10;</xsl:text>
-  <xsl:apply-templates select="foil" mode="ns-toc"/>
-
-  <xsl:text>myList.addList(subList, '</xsl:text>
-
-  <xsl:text disable-output-escaping="yes">&lt;DIV id="</xsl:text>
-  <xsl:value-of select="$id"/>
-  <xsl:text disable-output-escaping="yes">" class="toc-section"&gt;</xsl:text>
-
-  <xsl:text disable-output-escaping="yes">&lt;A href="</xsl:text>
-  <xsl:apply-templates select="." mode="filename"/>
-  <xsl:text disable-output-escaping="yes">" target="foil"&gt;</xsl:text>
-
-  <xsl:choose>
-    <xsl:when test="titleabbrev">
-      <xsl:value-of select="titleabbrev"/>
-    </xsl:when>
-    <xsl:otherwise>
-      <xsl:value-of select="title"/>
-    </xsl:otherwise>
-  </xsl:choose>
-
-  <xsl:text disable-output-escaping="yes">&lt;/A&gt;&lt;/DIV&gt;</xsl:text>
-  <xsl:text>');&#10;</xsl:text>
-</xsl:template>
-
-<xsl:template match="foil" mode="ns-toc">
-  <xsl:variable name="id"><xsl:call-template name="object.id"/></xsl:variable>
-
-  <xsl:choose>
-    <xsl:when test="ancestor::section">
-      <xsl:text>subList.addItem('</xsl:text>
-    </xsl:when>
-    <xsl:otherwise>
-      <xsl:text>myList.addItem('</xsl:text>
-    </xsl:otherwise>
-  </xsl:choose>
-
-  <xsl:text disable-output-escaping="yes">&lt;DIV id="</xsl:text>
-  <xsl:value-of select="$id"/>
-  <xsl:text disable-output-escaping="yes">" class="toc-foil"&gt;</xsl:text>
-
-  <xsl:text disable-output-escaping="yes">&lt;img alt="-" src="</xsl:text>
-  <xsl:call-template name="bullet.image"/>
-  <xsl:text disable-output-escaping="yes">"&gt;</xsl:text>
-
-  <xsl:text disable-output-escaping="yes">&lt;A href="</xsl:text>
-  <xsl:apply-templates select="." mode="filename"/>
-  <xsl:text disable-output-escaping="yes">" target="foil"&gt;</xsl:text>
-
-  <xsl:choose>
-    <xsl:when test="titleabbrev">
-      <xsl:value-of select="titleabbrev"/>
-    </xsl:when>
-    <xsl:otherwise>
-      <xsl:value-of select="title"/>
-    </xsl:otherwise>
-  </xsl:choose>
-
-  <xsl:text disable-output-escaping="yes">&lt;/A&gt;&lt;/DIV&gt;</xsl:text>
-  <xsl:text>');&#10;</xsl:text>
-</xsl:template>
-
-<xsl:template match="speakernotes" mode="ns-toc">
-  <!-- nop -->
-</xsl:template>
-
-<!-- ============================================================ -->
-
-<xsl:template name="section-top-nav">
-  <xsl:param name="prev-target" select="''"/>
-  <xsl:param name="next-target" select="''"/>
-
-  <xsl:variable name="nextfoil">
-    <xsl:apply-templates select="foil[1]" mode="filename"/>
-  </xsl:variable>
-
-  <xsl:variable name="prevfoil">
-    <xsl:choose>
-      <xsl:when test="preceding::foil">
-        <xsl:apply-templates select="preceding::foil[1]" mode="filename"/>
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:value-of select="$titlefoil.html"/>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:variable>
-
-  <div class="navhead">
-    <table width="100%" border="0" cellpadding="0" cellspacing="0"
-           summary="Navigation">
-      <tr>
-        <xsl:call-template name="generate.toc.hide.show"/>
-        <td align="left" width="10%">
-          <xsl:choose>
-            <xsl:when test="$prevfoil != ''">
-              <a href="{$prevfoil}">
-                <xsl:if test="$prev-target != ''">
-                  <xsl:attribute name="target">
-                    <xsl:value-of select="$prev-target"/>
-                  </xsl:attribute>
-                </xsl:if>
-                <img alt="Prev" border="0">
-                  <xsl:attribute name="src">
-                    <xsl:call-template name="left.image"/>
-                  </xsl:attribute>
-                </img>
-              </a>
-            </xsl:when>
-            <xsl:otherwise>&#160;</xsl:otherwise>
-          </xsl:choose>
-        </td>
-        <td align="center" width="80%">
-          <xsl:variable name="prestitle">
-            <xsl:value-of select="(/slides/slidesinfo/title
-                                  |/slides/title)[1]"/>
-          </xsl:variable>
-
-          <span class="navheader">
-            <xsl:value-of select="$prestitle"/>
-          </span>
-        </td>
-        <td align="right" width="10%">
-          <xsl:choose>
-            <xsl:when test="$nextfoil != ''">
-              <a href="{$nextfoil}">
-                <xsl:if test="$next-target != ''">
-                  <xsl:attribute name="target">
-                    <xsl:value-of select="$next-target"/>
-                  </xsl:attribute>
-                </xsl:if>
-                <img alt="Next" border="0">
-                  <xsl:attribute name="src">
-                    <xsl:call-template name="right.image"/>
-                  </xsl:attribute>
-                </img>
-              </a>
-            </xsl:when>
-            <xsl:otherwise>&#160;</xsl:otherwise>
-          </xsl:choose>
-        </td>
-      </tr>
-    </table>
-    <hr class="head"/>
-  </div>
-</xsl:template>
-
-<xsl:template name="section-bottom-nav">
-  <div class="navfoot">
-    <hr class="foot"/>
-    <table width="100%" border="0" cellpadding="0" cellspacing="0"
-           summary="Navigation">
-      <tr>
-        <td align="left" width="80%" valign="top">
-          <span class="navfooter">
-            <xsl:apply-templates select="/slides/slidesinfo/copyright"
-                                 mode="slide.navigation.mode"/>
-          </span>
-        </td>
-        <td align="right" width="20%" valign="top">
-          <xsl:text>&#160;</xsl:text>
-        </td>
-      </tr>
-    </table>
-  </div>
-</xsl:template>
-
-<xsl:template name="foil-top-nav">
-  <xsl:param name="prev-target" select="''"/>
-  <xsl:param name="next-target" select="''"/>
-
-  <xsl:variable name="section" select="ancestor::section"/>
-
-  <xsl:variable name="nextfoil">
-    <xsl:apply-templates select="(following::foil
-                                 |following::section)[1]"
-                         mode="filename"/>
-  </xsl:variable>
-
-  <xsl:variable name="prevfoil">
-    <xsl:choose>
-      <xsl:when test="preceding-sibling::foil">
-        <xsl:apply-templates select="preceding-sibling::foil[1]"
-                             mode="filename"/>
-      </xsl:when>
-      <xsl:when test="parent::section">
-        <xsl:apply-templates select="parent::section[1]"
-                             mode="filename"/>
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:value-of select="$titlefoil.html"/>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:variable>
-
-  <div class="navhead">
-    <table width="100%" border="0" cellpadding="0" cellspacing="0"
-           summary="Navigation">
-      <tr>
-        <xsl:call-template name="generate.toc.hide.show"/>
-        <td align="left" width="10%">
-          <xsl:choose>
-            <xsl:when test="$prevfoil != ''">
-              <a href="{$prevfoil}">
-                <xsl:if test="$prev-target != ''">
-                  <xsl:attribute name="target">
-                    <xsl:value-of select="$prev-target"/>
-                  </xsl:attribute>
-                </xsl:if>
-                <img alt="Prev" border="0">
-                  <xsl:attribute name="src">
-                    <xsl:call-template name="left.image"/>
-                  </xsl:attribute>
-                </img>
-              </a>
-            </xsl:when>
-            <xsl:otherwise>&#160;</xsl:otherwise>
-          </xsl:choose>
-        </td>
-        <td align="center" width="80%">
-          <xsl:variable name="prestitle">
-            <xsl:value-of select="(/slides/slidesinfo/title
-                                  |/slides/title)[1]"/>
-          </xsl:variable>
-          <xsl:variable name="secttitle">
-            <xsl:if test="$section">
-              <xsl:value-of select="$section/title"/>
-            </xsl:if>
-          </xsl:variable>
-
-          <span class="navheader">
-            <xsl:value-of select="$prestitle"/>
-            <xsl:if test="$secttitle != ''">
-              <xsl:text>: </xsl:text>
-              <xsl:value-of select="$secttitle"/>
-            </xsl:if>
-          </span>
-        </td>
-        <td align="right" width="10%">
-          <xsl:choose>
-            <xsl:when test="$nextfoil != ''">
-              <a href="{$nextfoil}">
-                <xsl:if test="$next-target != ''">
-                  <xsl:attribute name="target">
-                    <xsl:value-of select="$next-target"/>
-                  </xsl:attribute>
-                </xsl:if>
-                <img alt="Next" border="0">
-                  <xsl:attribute name="src">
-                    <xsl:call-template name="right.image"/>
-                  </xsl:attribute>
-                </img>
-              </a>
-            </xsl:when>
-            <xsl:otherwise>&#160;</xsl:otherwise>
-          </xsl:choose>
-        </td>
-      </tr>
-    </table>
-    <hr/>
-  </div>
-</xsl:template>
-
-<xsl:template name="foil-bottom-nav">
-  <div class="navfoot">
-    <hr/>
-    <table width="100%" border="0" cellspacing="0" cellpadding="0"
-           summary="Navigation">
-      <tr>
-        <td align="left" width="80%" valign="top">
-          <span class="navfooter">
-            <xsl:text>&#160;</xsl:text>
-            <xsl:apply-templates select="/slides/slidesinfo/copyright"
-                                 mode="slide.navigation.mode"/>
-          </span>
-        </td>
-        <td align="right" width="20%" valign="top">
-          <span class="navfooter">
-            <xsl:number count="foil" level="any"/>
-            <xsl:text>&#160;</xsl:text>
-          </span>
-        </td>
-      </tr>
-    </table>
-  </div>
-</xsl:template>
-
-<xsl:template name="generate.toc.hide.show">
-  <xsl:if test="$toc.hide.show != 0">
-    <td>
-      <img hspace="4">
-        <xsl:attribute name="src">
-          <xsl:call-template name="hidetoc.image"/>
-       </xsl:attribute>
-       <xsl:attribute name="onClick">
-          <xsl:text>toggletoc(this,</xsl:text>
-          <xsl:value-of select="$toc.width"/>
-          <xsl:text>,'</xsl:text>
-          <xsl:call-template name="hidetoc.image"/>
-          <xsl:text>','</xsl:text>
-          <xsl:call-template name="showtoc.image"/>
-          <xsl:text>');</xsl:text>
-        </xsl:attribute>
-      </img>
-    </td>
-  </xsl:if>
-</xsl:template>
-
-<!-- ============================================================ -->
-
-<xsl:template name="chunk">
-  <xsl:param name="node" select="."/>
-  <xsl:choose>
-    <xsl:when test="name($node)='slides'">1</xsl:when>
-    <xsl:when test="name($node)='foil'">1</xsl:when>
-    <xsl:otherwise>0</xsl:otherwise>
-  </xsl:choose>
-</xsl:template>
-
-<xsl:template match="*" mode="chunk-filename">
-  <xsl:param name="recursive">0</xsl:param>
-  <!-- returns the filename of a chunk -->
-  <xsl:variable name="ischunk"><xsl:call-template name="chunk"/></xsl:variable>
-  <xsl:variable name="filename">
-    <xsl:call-template name="dbhtml-filename"/>
-  </xsl:variable>
-  <xsl:variable name="dir">
-    <xsl:call-template name="dbhtml-dir"/>
-  </xsl:variable>
-
-  <xsl:choose>
-    <xsl:when test="$ischunk='0'">
-      <!-- if called on something that isn't a chunk, walk up... -->
-      <xsl:choose>
-        <xsl:when test="count(./parent::*)>0">
-          <xsl:apply-templates mode="chunk-filename" select="./parent::*">
-            <xsl:with-param name="recursive" select="$recursive"/>
-          </xsl:apply-templates>
-        </xsl:when>
-        <!-- unless there is no up, in which case return "" -->
-        <xsl:otherwise></xsl:otherwise>
-      </xsl:choose>
-    </xsl:when>
-
-    <xsl:when test="not($recursive) and $filename != ''">
-      <!-- if this chunk has an explicit name, use it -->
-      <xsl:if test="$dir != ''">
-        <xsl:value-of select="$dir"/>
-        <xsl:text>/</xsl:text>
-      </xsl:if>
-      <xsl:value-of select="$filename"/>
-    </xsl:when>
-
-    <xsl:when test="name(.)='foil'">
-      <xsl:variable name="foilnumber">
-       <xsl:number count="foil" level="any"/>
-      </xsl:variable>
-
-      <xsl:text>foil</xsl:text>
-      <xsl:number value="$foilnumber" format="01"/>
-      <xsl:text>.html</xsl:text>
-    </xsl:when>
-
-    <xsl:otherwise>
-      <xsl:text>chunk-filename-error-</xsl:text>
-      <xsl:value-of select="name(.)"/>
-      <xsl:number level="any" format="01" from="set"/>
-      <xsl:if test="not($recursive)">
-        <xsl:value-of select="$html.ext"/>
-      </xsl:if>
-    </xsl:otherwise>
-  </xsl:choose>
-</xsl:template>
-
-<!-- ============================================================ -->
-
-<xsl:template match="@*" mode="copy">
-  <xsl:attribute name="{local-name(.)}">
-    <xsl:value-of select="."/>
-  </xsl:attribute>
-</xsl:template>
-
-<xsl:template match="html:*" xmlns:html='http://www.w3.org/1999/xhtml'>
-  <xsl:element name="{local-name(.)}" namespace="">
-    <xsl:apply-templates select="@*" mode="copy"/>
-    <xsl:apply-templates/>
-  </xsl:element>
-</xsl:template>
-
-<!-- ============================================================ -->
-
-</xsl:stylesheet>
index 5faab046988542373cb464ea1089e36159238b2d..fdbe2a0d2afda4e7ae3db07a5d5cd10dbbafdd83 100644 (file)
 <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
                 version="1.0">
 
-<xsl:import href="slides.xsl"/>
+<xsl:import href="slides-common.xsl"/>
 
-<xsl:param name="blank.image" select="'blank.gif'"/>
-<xsl:param name="arrow.image" select="'arrow.gif'"/>
+<xsl:param name="blank.image" select="'blank.png'"/>
+<xsl:param name="arrow.image" select="'pointer.png'"/>
 
 <xsl:param name="toc.bg.color">#6A719C</xsl:param>
 <xsl:param name="toc.width">220</xsl:param>
 
+<xsl:param name="css.stylesheet" select="'slides-table.css'"/>
+
 <!-- ============================================================ -->
 
-<xsl:template match="slides">
-  <xsl:apply-templates/>
+<xsl:template name="foilgroup-body">
+  <table border="0" width="100%" summary="Navigation and body table"
+         cellpadding="0" cellspacing="0">
+    <tr>
+      <td bgcolor="{$toc.bg.color}" width="{$toc.width}"
+          valign="top" align="left">
+        <div class="ttoc">
+          <xsl:apply-templates select="." mode="t-toc"/>
+        </div>
+      </td>
+      <td>&#160;</td>
+      <td bgcolor="{$body.bg.color}" valign="top" align="left">
+        <div class="{name(.)}">
+          <xsl:apply-templates select="*[name(.) != 'foil'
+                                         and name(.) != 'foilgroup']"/>
+        </div>
+      </td>
+    </tr>
+  </table>
 </xsl:template>
 
-<xsl:template match="slidesinfo">
-  <xsl:call-template name="write.chunk">
-    <xsl:with-param name="filename" select="concat($base.dir, $titlefoil.html)"/>
-    <xsl:with-param name="content">
-      <html>
-        <head>
-          <title><xsl:value-of select="title"/></title>
-          <link type="text/css" rel="stylesheet">
-            <xsl:attribute name="href">
-              <xsl:call-template name="css.stylesheet"/>
-            </xsl:attribute>
-          </link>
-        </head>
-        <body class="titlepage">
-          <xsl:call-template name="body.attributes"/>
-          <div class="{name(.)}">
-            <xsl:apply-templates mode="titlepage.mode"/>
-          </div>
-
-          <div class="navfoot" style="padding-top: 2in;">
-            <table width="100%" border="0"
-                   cellspacing="0" cellpadding="0"
-                   summary="Navigation">
-              <tr>
-                <td align="left" width="80%" valign="top">
-                  <span class="navfooter">
-                    <xsl:apply-templates select="/slides/slidesinfo/copyright"
-                                         mode="slide.navigation.mode"/>
-                  </span>
-                </td>
-                <td align="right" width="20%" valign="top">
-                  <a href="foil01.html">
-                    <img alt="Next" border="0">
-                      <xsl:attribute name="src">
-                        <xsl:call-template name="right.image"/>
-                      </xsl:attribute>
-                    </img>
-                  </a>
-                </td>
-              </tr>
-            </table>
-          </div>
-        </body>
-      </html>
-    </xsl:with-param>
-  </xsl:call-template>
+<xsl:template name="foil-body">
+  <table border="0" width="100%" summary="Navigation and body table"
+         cellpadding="0" cellspacing="0">
+    <tr>
+      <td bgcolor="{$toc.bg.color}" width="{$toc.width}"
+          valign="top" align="left">
+        <div class="ttoc">
+          <xsl:apply-templates select="." mode="t-toc"/>
+        </div>
+      </td>
+      <td>&#160;</td>
+      <td bgcolor="{$body.bg.color}" valign="top" align="left">
+        <div class="{name(.)}">
+          <xsl:apply-templates/>
+        </div>
+      </td>
+    </tr>
+  </table>
 </xsl:template>
 
-<xsl:template match="section">
-  <xsl:variable name="id">
-    <xsl:call-template name="object.id"/>
-  </xsl:variable>
-
-  <xsl:variable name="snumber">
-    <xsl:number count="section" level="any"/>
-  </xsl:variable>
-
-  <xsl:variable name="thissection">
-    <xsl:text>section</xsl:text>
-    <xsl:number value="$snumber" format="01"/>
-    <xsl:text>.html</xsl:text>
-  </xsl:variable>
-
-  <xsl:variable name="nextfoil">
-    <xsl:apply-templates select="foil[1]" mode="filename"/>
-  </xsl:variable>
-
-  <xsl:variable name="prevfoil">
-    <xsl:choose>
-      <xsl:when test="preceding::foil">
-        <xsl:apply-templates select="preceding::foil[1]" mode="filename"/>
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:value-of select="$titlefoil.html"/>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:variable>
-
-  <xsl:call-template name="write.chunk">
-    <xsl:with-param name="filename" select="concat($base.dir, $thissection)"/>
-    <xsl:with-param name="content">
-      <head>
-        <title><xsl:value-of select="title"/></title>
-        <link type="text/css" rel="stylesheet">
-          <xsl:attribute name="href">
-            <xsl:call-template name="css.stylesheet"/>
-          </xsl:attribute>
-        </link>
-      </head>
-      <body class="section">
-        <xsl:call-template name="body.attributes"/>
-        <table border="0" width="100%" summary="Navigation and body table"
-               cellpadding="0" cellspacing="0">
-          <tr>
-            <td bgcolor="{$toc.bg.color}" width="{$toc.width}"
-                valign="top" align="center">
-              <div class="ttoc">
-                <span class="ttoc-title">
-                  <a href="{$titlefoil.html}">
-                    <xsl:apply-templates select="/slides" mode="toc-title"/>
-                  </a>
-                </span>
-              </div>
-            </td>
-            <td>&#160;</td>
-            <td bgcolor="{$body.bg.color}" valign="top" align="left">
-              <a name="{$id}"/>
-              <xsl:call-template name="section-top-nav"/>
-            </td>
-          </tr>
-          <tr>
-            <td bgcolor="{$toc.bg.color}" width="{$toc.width}"
-                valign="top" align="left">
-              <div class="ttoc">
-                <xsl:apply-templates select="." mode="toc"/>
-              </div>
-            </td>
-            <td>&#160;</td>
-            <td bgcolor="{$body.bg.color}" valign="top" align="left">
-              <div class="{name(.)}">
-
-                <xsl:apply-templates/>
-              </div>
-            </td>
-          </tr>
-          <tr>
-            <td bgcolor="{$toc.bg.color}" width="{$toc.width}">
-              <xsl:text>&#160;</xsl:text>
-            </td>
-            <td>&#160;</td>
-            <td bgcolor="{$body.bg.color}" valign="top" align="left">
-              <xsl:call-template name="section-bottom-nav"/>
-            </td>
-          </tr>
-        </table>
-      </body>
-    </xsl:with-param>
-  </xsl:call-template>
-
-  <xsl:apply-templates select="foil"/>
-</xsl:template>
-
-<xsl:template match="foil">
-  <xsl:variable name="id">
-    <xsl:call-template name="object.id"/>
-  </xsl:variable>
-
-  <xsl:variable name="section" select="ancestor::section"/>
-
-  <xsl:variable name="thisfoil">
-    <xsl:apply-templates select="." mode="filename"/>
-  </xsl:variable>
+<!-- ============================================================ -->
 
-  <xsl:variable name="nextfoil">
-    <xsl:apply-templates select="(following::foil
-                                 |following::section)[1]"
-                         mode="filename"/>
-  </xsl:variable>
+<xsl:template match="foilgroup" mode="t-toc">
+  <xsl:variable name="thisfoilgroup" select="."/>
 
-  <xsl:variable name="prevfoil">
+  <xsl:for-each select="/slides/foil|/slides/foilgroup">
     <xsl:choose>
-      <xsl:when test="preceding-sibling::foil">
-        <xsl:apply-templates select="preceding-sibling::foil[1]"
-                             mode="filename"/>
-      </xsl:when>
-      <xsl:when test="parent::section">
-        <xsl:apply-templates select="parent::section[1]"
-                             mode="filename"/>
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:value-of select="$titlefoil.html"/>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:variable>
-
-  <xsl:call-template name="write.chunk">
-    <xsl:with-param name="filename" select="concat($base.dir, $thisfoil)"/>
-    <xsl:with-param name="content">
-      <head>
-        <title><xsl:value-of select="title"/></title>
-        <link type="text/css" rel="stylesheet">
-          <xsl:attribute name="href">
-            <xsl:call-template name="css.stylesheet"/>
-          </xsl:attribute>
-        </link>
-      </head>
-      <body class="foil">
-        <xsl:call-template name="body.attributes"/>
-        <table border="0" width="100%" summary="Navigation and body table"
-               cellpadding="0" cellspacing="0">
-          <tr>
-            <td bgcolor="{$toc.bg.color}" width="{$toc.width}"
-                valign="top" align="center">
-              <div class="ttoc">
-                <span class="ttoc-title">
-                  <a href="{$titlefoil.html}">
-                    <xsl:apply-templates select="/slides" mode="toc-title"/>
-                  </a>
-                </span>
-              </div>
-            </td>
-            <td>&#160;</td>
-            <td bgcolor="{$body.bg.color}" valign="top" align="left">
-              <a name="{$id}"/>
-              <xsl:call-template name="foil-top-nav"/>
-            </td>
-          </tr>
-          <tr>
-            <td bgcolor="{$toc.bg.color}" width="{$toc.width}"
-                valign="top" align="left">
-              <div class="ttoc">
-                <xsl:apply-templates select="." mode="toc"/>
-              </div>
-            </td>
-            <td>&#160;</td>
-            <td bgcolor="{$body.bg.color}" valign="top" align="left">
-              <div class="{name(.)}" id="{$id}">
-                <a name="{$id}"/>
-
-                <xsl:apply-templates/>
-              </div>
-            </td>
-          </tr>
-          <tr>
-            <td bgcolor="{$toc.bg.color}" width="{$toc.width}">
-              <xsl:text>&#160;</xsl:text>
-            </td>
-            <td>&#160;</td>
-            <td bgcolor="{$body.bg.color}" valign="top" align="left">
-              <xsl:call-template name="foil-bottom-nav"/>
-            </td>
-          </tr>
-        </table>
-      </body>
-    </xsl:with-param>
-  </xsl:call-template>
-</xsl:template>
-
-<!-- ============================================================ -->
+      <xsl:when test="name(.) = 'foilgroup'">
+        <xsl:choose>
+          <xsl:when test="$thisfoilgroup = .">
+            <img alt="+">
+              <xsl:attribute name="src">
+                <xsl:call-template name="graphics-file">
+                  <xsl:with-param name="image" select="$arrow.image"/>
+                </xsl:call-template>
+              </xsl:attribute>
+            </img>
+          </xsl:when>
+          <xsl:otherwise>
+            <img alt=" ">
+              <xsl:attribute name="src">
+                <xsl:call-template name="graphics-file">
+                  <xsl:with-param name="image" select="$blank.image"/>
+                </xsl:call-template>
+              </xsl:attribute>
+            </img>
+          </xsl:otherwise>
+        </xsl:choose>
 
-<xsl:template match="slides" mode="toc">
-  <xsl:apply-templates select="section|foil" mode="toc"/>
-</xsl:template>
+        <span class="ttoc-foilgroup">
+          <a>
+            <xsl:attribute name="href">
+              <xsl:apply-templates select="." mode="filename"/>
+            </xsl:attribute>
+            <xsl:apply-templates select="." mode="toc-title"/>
+          </a>
+        </span>
+        <br/>
 
-<xsl:template match="section" mode="toc">
-  <xsl:variable name="thissection" select="."/>
+        <xsl:if test="$thisfoilgroup = .">
+          <xsl:for-each select="foil">
+            <img alt=" ">
+              <xsl:attribute name="src">
+                <xsl:call-template name="graphics-file">
+                  <xsl:with-param name="image" select="$blank.image"/>
+                </xsl:call-template>
+              </xsl:attribute>
+            </img>
+            <img alt=" ">
+              <xsl:attribute name="src">
+                <xsl:call-template name="graphics-file">
+                  <xsl:with-param name="image" select="$blank.image"/>
+                </xsl:call-template>
+              </xsl:attribute>
+            </img>
 
-  <xsl:for-each select="/slides/section">
-    <xsl:choose>
-      <xsl:when test="$thissection = .">
-        <img alt="+">
-          <xsl:attribute name="src">
-            <xsl:call-template name="graphics-file">
-              <xsl:with-param name="image" select="$arrow.image"/>
-            </xsl:call-template>
-          </xsl:attribute>
-        </img>
+            <span class="ttoc-foil">
+              <a>
+                <xsl:attribute name="href">
+                  <xsl:apply-templates select="." mode="filename"/>
+                </xsl:attribute>
+                <xsl:apply-templates select="." mode="toc-title"/>
+              </a>
+            </span>
+            <br/>
+          </xsl:for-each>
+        </xsl:if>
       </xsl:when>
       <xsl:otherwise>
         <img alt=" ">
             </xsl:call-template>
           </xsl:attribute>
         </img>
-      </xsl:otherwise>
-    </xsl:choose>
-
-    <span class="ttoc-section">
-      <a>
-        <xsl:attribute name="href">
-          <xsl:apply-templates select="./foil[1]" mode="filename"/>
-        </xsl:attribute>
-        <xsl:apply-templates select="." mode="toc-title"/>
-      </a>
-    </span>
-    <br/>
-
-    <xsl:if test="$thissection = .">
-      <xsl:for-each select="foil">
-        <img alt=" ">
-          <xsl:attribute name="src">
-            <xsl:call-template name="graphics-file">
-              <xsl:with-param name="image" select="$blank.image"/>
-            </xsl:call-template>
-          </xsl:attribute>
-        </img>
-        <img alt=" ">
-          <xsl:attribute name="src">
-            <xsl:call-template name="graphics-file">
-              <xsl:with-param name="image" select="$blank.image"/>
-            </xsl:call-template>
-          </xsl:attribute>
-        </img>
-
         <span class="ttoc-foil">
           <a>
             <xsl:attribute name="href">
           </a>
         </span>
         <br/>
-      </xsl:for-each>
-    </xsl:if>
+      </xsl:otherwise>
+    </xsl:choose>
   </xsl:for-each>
 </xsl:template>
 
-<xsl:template match="foil" mode="toc">
+<xsl:template match="foil" mode="t-toc">
   <xsl:variable name="thisfoil" select="."/>
 
-  <xsl:choose>
-    <xsl:when test="/slides/section">
-      <xsl:for-each select="/slides/section">
+  <xsl:for-each select="/slides/foil|/slides/foilgroup">
+    <xsl:choose>
+      <xsl:when test="name(.) = 'foilgroup'">
         <img alt=" ">
           <xsl:attribute name="src">
             <xsl:call-template name="graphics-file">
             </xsl:call-template>
           </xsl:attribute>
         </img>
-        <span class="ttoc-section">
+        <span class="ttoc-foilgroup">
           <a>
             <xsl:attribute name="href">
-              <xsl:apply-templates select="./foil[1]" mode="filename"/>
+              <xsl:apply-templates select="." mode="filename"/>
             </xsl:attribute>
             <xsl:apply-templates select="." mode="toc-title"/>
           </a>
         </span>
         <br/>
 
-        <xsl:if test="$thisfoil/ancestor::section = .">
+        <xsl:if test="$thisfoil/ancestor::foilgroup = .">
           <xsl:for-each select="foil">
             <img alt=" ">
               <xsl:attribute name="src">
             <br/>
           </xsl:for-each>
         </xsl:if>
-      </xsl:for-each>
-    </xsl:when>
-    <xsl:otherwise>
-      <!-- foils only -->
-      <xsl:for-each select="/slides/foil">
-        <span class="ttoc-foil">
-          <xsl:apply-templates select="." mode="toc-title"/>
-        </span>
-        <br/>
-      </xsl:for-each>
-    </xsl:otherwise>
-  </xsl:choose>
+      </xsl:when>
+      <xsl:otherwise>
+        <!-- foils only -->
+        <xsl:for-each select="/slides/foil">
+          <xsl:choose>
+            <xsl:when test="$thisfoil = .">
+              <img alt="+">
+                <xsl:attribute name="src">
+                  <xsl:call-template name="graphics-file">
+                    <xsl:with-param name="image" select="$arrow.image"/>
+                  </xsl:call-template>
+                </xsl:attribute>
+              </img>
+            </xsl:when>
+            <xsl:otherwise>
+              <img alt=" ">
+                <xsl:attribute name="src">
+                  <xsl:call-template name="graphics-file">
+                    <xsl:with-param name="image" select="$blank.image"/>
+                  </xsl:call-template>
+                </xsl:attribute>
+              </img>
+            </xsl:otherwise>
+          </xsl:choose>
+          <span class="ttoc-foil">
+            <xsl:apply-templates select="." mode="toc-title"/>
+          </span>
+          <br/>
+        </xsl:for-each>
+      </xsl:otherwise>
+    </xsl:choose>
+  </xsl:for-each>
 </xsl:template>
 
 <!-- ============================================================ -->
   </xsl:call-template>
 </xsl:template>
 
-<xsl:template match="section" mode="toc-title">
+<xsl:template match="foilgroup" mode="toc-title">
   <xsl:call-template name="nobreak">
     <xsl:with-param name="string">
       <xsl:choose>
index 02b024ca2176c5cc8ac0bcb4804220fdec881663..208b76df8bc8526bd82248bc86dab81b28787641 100644 (file)
@@ -2,7 +2,7 @@
 <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
                 version="1.0">
 
-<xsl:import href="slides.xsl"/>
+<xsl:import href="slides-common.xsl"/>
 
 <xsl:param name="toc.width" select="100"/>
 
 <xsl:param name="but-prev.png" select="'but-prev.png'"/>
 <xsl:param name="but-rewind.png" select="'but-rewind.png'"/>
 <xsl:param name="but-xfforward.png" select="'but-xfforward.png'"/>
+<xsl:param name="but-xinfo.png" select="'but-xinfo.png'"/>
 <xsl:param name="but-xnext.png" select="'but-xnext.png'"/>
 <xsl:param name="but-xprev.png" select="'but-xprev.png'"/>
 <xsl:param name="but-xrewind.png" select="'but-xrewind.png'"/>
 
+<!-- overrides for this stylesheet -->
+<xsl:param name="titlefoil.html" select="'index.html'"/>
+<xsl:param name="toc.width" select="20"/>
+
 <!-- ============================================================ -->
 
 <xsl:template match="slides">
             </xsl:attribute>
           </link>
 
-          <link rel="top">
-            <xsl:attribute name="href">
-              <xsl:apply-templates select="/slides" mode="filename"/>
-            </xsl:attribute>
-            <xsl:attribute name="title">
-              <xsl:value-of select="/slides/slidesinfo/title[1]"/>
-            </xsl:attribute>
-          </link>
-
-          <xsl:for-each select="section">
-            <link rel="section">
-              <xsl:attribute name="href">
-                <xsl:apply-templates select="." mode="filename"/>
-              </xsl:attribute>
-              <xsl:attribute name="title">
-                <xsl:value-of select="title[1]"/>
-              </xsl:attribute>
-            </link>
-          </xsl:for-each>
+          <xsl:call-template name="links">
+            <xsl:with-param name="next" select="/slides"/>
+            <xsl:with-param name="tocfile" select="$toc.html"/>
+          </xsl:call-template>
 
           <xsl:if test="$keyboard.nav != 0">
-            <script language="JavaScript1.2"/>
+            <script language="JavaScript1.2" type="text/javascript"/>
           </xsl:if>
 
           <xsl:if test="$keyboard.nav != 0">
               <td bgcolor="{$toc.bg.color}" width="{$toc.width}"
                   valign="top" align="left">
 
-                <xsl:variable name="first" select="(/slides/section|/slides/foil)[1]"/>
-
                 <xsl:call-template name="vertical-navigation">
-                  <xsl:with-param name="first"/>
-                  <xsl:with-param name="prev"/>
                   <xsl:with-param name="next" select="/slides"/>
-                  <xsl:with-param name="last" select="(//foil)[last()]"/>
+                  <xsl:with-param name="tocfile"/>
                 </xsl:call-template>
 
               </td>
               <td bgcolor="{$body.bg.color}" valign="top" align="left">
                 <div class="{name(.)}">
-                  <h1 class="title">
-                    <a href="{$titlefoil.html}">
-                      <xsl:value-of select="/slides/slidesinfo/title"/>
-                    </a>
-                  </h1>
 
-                  <xsl:apply-templates select="." mode="toc"/>
+                  <div class="toc-body">
+                    <xsl:call-template name="toc-body"/>
+                  </div>
+
                 </div>
               </td>
             </tr>
               <xsl:call-template name="css.stylesheet"/>
             </xsl:attribute>
           </link>
+
+          <xsl:call-template name="links">
+            <xsl:with-param name="next" select="(/slides/foil|/slides/foilgroup)[1]"/>
+            <xsl:with-param name="tocfile" select="$toc.html"/>
+          </xsl:call-template>
+
+          <xsl:if test="$keyboard.nav != 0">
+            <script language="JavaScript1.2" type="text/javascript"/>
+          </xsl:if>
+
+          <xsl:if test="$keyboard.nav != 0">
+            <xsl:call-template name="ua.js"/>
+            <xsl:call-template name="xbDOM.js">
+              <xsl:with-param name="language" select="'JavaScript'"/>
+            </xsl:call-template>
+            <xsl:call-template name="xbStyle.js"/>
+            <xsl:call-template name="xbCollapsibleLists.js"/>
+            <xsl:call-template name="slides.js">
+              <xsl:with-param name="language" select="'JavaScript'"/>
+            </xsl:call-template>
+          </xsl:if>
         </head>
         <body class="titlepage">
           <xsl:call-template name="body.attributes"/>
 
                 <xsl:call-template name="vertical-navigation">
                   <xsl:with-param name="first"/>
-                  <xsl:with-param name="last" select="(following::section|following::foil)[last()]"/>
-                  <xsl:with-param name="next" select="(following::section|following::foil)[1]"/>
+                  <xsl:with-param name="last" select="(following::foilgroup|following::foil)[last()]"/>
+                  <xsl:with-param name="next" select="(following::foilgroup|following::foil)[1]"/>
                 </xsl:call-template>
 
               </td>
   </xsl:call-template>
 </xsl:template>
 
-<xsl:template match="section">
+<xsl:template match="foilgroup">
   <xsl:variable name="id">
     <xsl:call-template name="object.id"/>
   </xsl:variable>
 
-  <xsl:variable name="snumber">
-    <xsl:number count="section" level="any"/>
-  </xsl:variable>
-
-  <xsl:variable name="thissection">
-    <xsl:text>section</xsl:text>
-    <xsl:number value="$snumber" format="01"/>
-    <xsl:text>.html</xsl:text>
-  </xsl:variable>
+  <xsl:param name="thisfoilgroup">
+    <xsl:apply-templates select="." mode="filename"/>
+  </xsl:param>
 
   <xsl:variable name="nextfoil" select="foil[1]"/>
   <xsl:variable name="lastfoil" select="(descendant::foil|following::foil)[last()]"/>
   <xsl:variable name="prevfoil" select="(preceding::foil|/slides)[last()]"/>
 
   <xsl:call-template name="write.chunk">
-    <xsl:with-param name="filename" select="concat($base.dir, $thissection)"/>
+    <xsl:with-param name="filename" select="concat($base.dir, $thisfoilgroup)"/>
     <xsl:with-param name="content">
       <head>
         <title><xsl:value-of select="title"/></title>
             <xsl:call-template name="css.stylesheet"/>
           </xsl:attribute>
         </link>
+
+        <xsl:call-template name="links">
+          <xsl:with-param name="prev" select="$prevfoil"/>
+          <xsl:with-param name="next" select="$nextfoil"/>
+        </xsl:call-template>
+
+        <xsl:if test="$keyboard.nav != 0">
+          <script language="JavaScript1.2" type="text/javascript"/>
+        </xsl:if>
+
+        <xsl:if test="$keyboard.nav != 0">
+          <xsl:call-template name="ua.js"/>
+          <xsl:call-template name="xbDOM.js">
+            <xsl:with-param name="language" select="'JavaScript'"/>
+          </xsl:call-template>
+          <xsl:call-template name="xbStyle.js"/>
+          <xsl:call-template name="xbCollapsibleLists.js"/>
+          <xsl:call-template name="slides.js">
+            <xsl:with-param name="language" select="'JavaScript'"/>
+          </xsl:call-template>
+        </xsl:if>
       </head>
-      <body class="section">
+      <body class="foilgroup">
         <xsl:call-template name="body.attributes"/>
 
         <table border="0" width="100%" summary="Navigation and body table"
     <xsl:call-template name="object.id"/>
   </xsl:variable>
 
-  <xsl:variable name="section" select="ancestor::section"/>
+  <xsl:variable name="foilgroup" select="ancestor::foilgroup"/>
 
   <xsl:variable name="thisfoil">
     <xsl:apply-templates select="." mode="filename"/>
   </xsl:variable>
 
   <xsl:variable name="nextfoil" select="(following::foil
-                                        |following::section)[1]"/>
+                                        |following::foilgroup)[1]"/>
 
   <xsl:variable name="lastfoil" select="following::foil[last()]"/>
 
   <xsl:variable name="prevfoil" select="(preceding-sibling::foil[1]
-                                        |parent::section[1]
+                                        |parent::foilgroup[1]
                                         |/slides)[last()]"/>
 
   <xsl:call-template name="write.chunk">
     <xsl:with-param name="content">
       <head>
         <title><xsl:value-of select="title"/></title>
+
         <link type="text/css" rel="stylesheet">
           <xsl:attribute name="href">
             <xsl:call-template name="css.stylesheet"/>
           </xsl:attribute>
         </link>
+
+        <xsl:call-template name="links">
+          <xsl:with-param name="prev" select="$prevfoil"/>
+          <xsl:with-param name="next" select="$nextfoil"/>
+        </xsl:call-template>
+
+        <xsl:if test="$keyboard.nav != 0">
+          <script language="JavaScript1.2" type="text/javascript"/>
+        </xsl:if>
+
+        <xsl:if test="$keyboard.nav != 0">
+          <xsl:call-template name="ua.js"/>
+          <xsl:call-template name="xbDOM.js">
+            <xsl:with-param name="language" select="'JavaScript'"/>
+          </xsl:call-template>
+          <xsl:call-template name="xbStyle.js"/>
+          <xsl:call-template name="xbCollapsibleLists.js"/>
+          <xsl:call-template name="slides.js">
+            <xsl:with-param name="language" select="'JavaScript'"/>
+          </xsl:call-template>
+        </xsl:if>
       </head>
       <body class="foil">
         <xsl:call-template name="body.attributes"/>
       <tr>
         <td align="left">
           <xsl:apply-templates select="/slides/slidesinfo/copyright"
-                               mode="slide.navigation.mode"/>
+                               mode="slide.footer.mode"/>
         </td>
         <td align="right">
           <xsl:value-of select="count(preceding::foil)
-                                + count(preceding::section)
-                                + count(ancestor::section)
+                                + count(preceding::foilgroup)
+                                + count(ancestor::foilgroup)
                                 + 1"/>
         </td>
       </tr>
         <td align="center">
           <xsl:text>Slide </xsl:text>
           <xsl:value-of select="count(preceding::foil)
-                                + count(preceding::section)
-                                + count(ancestor::section)
+                                + count(preceding::foilgroup)
+                                + count(ancestor::foilgroup)
                                 + 1"/>
           <xsl:text> of </xsl:text>
-          <xsl:value-of select="count(//foil) + count(//section)"/>
+          <xsl:value-of select="count(//foil) + count(//foilgroup)"/>
         </td>
       </tr>
     </table>
   <xsl:param name="prev"/>
   <xsl:param name="last"/>
   <xsl:param name="next"/>
+  <xsl:param name="tocfile" select="$toc.html"/>
 
   <div class="vnav">
     <xsl:choose>
         </a>
       </xsl:when>
       <xsl:otherwise>
-        <img>
+        <img alt="First">
           <xsl:attribute name="src">
             <xsl:call-template name="graphics-file">
               <xsl:with-param name="image" select="$but-xrewind.png"/>
         </a>
       </xsl:when>
       <xsl:otherwise>
-        <img>
+        <img alt="Previous">
           <xsl:attribute name="src">
             <xsl:call-template name="graphics-file">
               <xsl:with-param name="image" select="$but-xprev.png"/>
         </a>
       </xsl:when>
       <xsl:otherwise>
-        <img>
+        <img alt="Last">
           <xsl:attribute name="src">
             <xsl:call-template name="graphics-file">
               <xsl:with-param name="image" select="$but-xnext.png"/>
         </a>
       </xsl:when>
       <xsl:otherwise>
-        <img>
+        <img alt="Next">
           <xsl:attribute name="src">
             <xsl:call-template name="graphics-file">
               <xsl:with-param name="image" select="$but-xfforward.png"/>
     <br/>
     <br/>
 
-    <a href="{$toc.html}">
-      <img border="0" alt="ToC">
-        <xsl:attribute name="src">
-          <xsl:call-template name="graphics-file">
-            <xsl:with-param name="image" select="$but-info.png"/>
-          </xsl:call-template>
-        </xsl:attribute>
-      </img>
-    </a>
+    <xsl:choose>
+      <xsl:when test="$tocfile != ''">
+        <a href="{$tocfile}">
+          <img border="0" alt="ToC">
+            <xsl:attribute name="src">
+              <xsl:call-template name="graphics-file">
+                <xsl:with-param name="image" select="$but-info.png"/>
+              </xsl:call-template>
+            </xsl:attribute>
+          </img>
+        </a>
+      </xsl:when>
+      <xsl:otherwise>
+        <img border="0" alt="ToC">
+          <xsl:attribute name="src">
+            <xsl:call-template name="graphics-file">
+              <xsl:with-param name="image" select="$but-xinfo.png"/>
+            </xsl:call-template>
+          </xsl:attribute>
+        </img>
+      </xsl:otherwise>
+    </xsl:choose>
   </div>
 </xsl:template>
 
index 8e0222e864449438f434e92fba2954613f2124e2..8777fd24fc444b6edbc46a792c1130cf40fbae09 100644 (file)
 <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
                version="1.0">
 
-<xsl:import href="slides.xsl"/>
+<xsl:import href="slides-common.xsl"/>
 
-<xsl:template name="overlayDiv.attributes"/>
+<xsl:param name="logo.image.uri" select="''"/>
+<xsl:param name="logo.uri" select="''"/>
+<xsl:param name="logo.title" select="''"/>
 
-<xsl:template name="logo">
-  <xsl:text>LOGO</xsl:text>
-</xsl:template>
+<xsl:param name="next.image" select="'active/w3c-next.png'"/>
+<xsl:param name="no.next.image" select="'inactive/w3c-next.png'"/>
 
-<!-- ============================================================ -->
-
-<xsl:template match="slides">
-  <xsl:call-template name="write.chunk">
-    <xsl:with-param name="indent" select="$output.indent"/>
-    <xsl:with-param name="filename" select="concat($base.dir, $toc.html)"/>
-    <xsl:with-param name="content">
-      <html>
-        <head>
-          <title><xsl:value-of select="title"/></title>
-          <link type="text/css" rel="stylesheet">
-            <xsl:attribute name="href">
-              <xsl:call-template name="css.stylesheet"/>
-            </xsl:attribute>
-          </link>
-          <link rel="top">
-            <xsl:attribute name="href">
-              <xsl:apply-templates select="/slides" mode="filename"/>
-            </xsl:attribute>
-            <xsl:attribute name="title">
-              <xsl:value-of select="/slides/slidesinfo/title[1]"/>
-            </xsl:attribute>
-          </link>
-          <xsl:for-each select="section">
-            <link rel="section">
-              <xsl:attribute name="href">
-                <xsl:apply-templates select="." mode="filename"/>
-              </xsl:attribute>
-              <xsl:attribute name="title">
-                <xsl:value-of select="title[1]"/>
-              </xsl:attribute>
-            </link>
-          </xsl:for-each>
-        </head>
-        <body class="tocpage">
-          <xsl:call-template name="body.attributes"/>
-
-          <div class="navhead">
-            <table class="navbar" cellspacing="0" cellpadding="0" border="0"
-                   width="97%" summary="Navigation buttons">
-              <tr valign="top">
-                <td align="left">
-                  <xsl:call-template name="logo"/>
-                </td>
-                <td valign="top" nowrap="nowrap">&#160;</td>
-              </tr>
-            </table>
-          </div>
-
-          <h1 class="title">
-            <a href="{$titlefoil.html}">
-              <xsl:value-of select="/slides/slidesinfo/title"/>
-            </a>
-          </h1>
-
-          <h3 class="author">
-            <xsl:text>by </xsl:text>
-            <xsl:variable name="author" select="(/slides/slidesinfo//author
-                                                |/slides/slidesinfo//editor)"/>
-            <xsl:for-each select="$author">
-              <xsl:choose>
-                <xsl:when test=".//email">
-                  <a href="mailto:{.//email[1]}">
-                    <xsl:call-template name="person.name"/>
-                  </a>
-                </xsl:when>
-                <xsl:otherwise>
-                  <xsl:call-template name="person.name"/>
-                </xsl:otherwise>
-              </xsl:choose>
-
-              <xsl:if test="position() &lt; last()">, </xsl:if>
-            </xsl:for-each>
-          </h3>
-
-          <xsl:apply-templates select="." mode="toc"/>
-        </body>
-      </html>
-    </xsl:with-param>
-  </xsl:call-template>
-  <xsl:apply-templates/>
-</xsl:template>
+<xsl:param name="prev.image" select="'active/w3c-prev.png'"/>
+<xsl:param name="no.prev.image" select="'inactive/w3c-prev.png'"/>
 
-<!-- ============================================================ -->
+<xsl:param name="toc.image" select="'active/w3c-toc.png'"/>
+<xsl:param name="no.toc.image" select="'inactive/w3c-toc.png'"/>
 
-<xsl:template name="slidesinfo-top-nav">
-  <xsl:param name="prev-target" select="''"/>
-  <xsl:param name="next-target" select="''"/>
-
-  <xsl:variable name="nextfoil" select="(following::foil
-                                        |following::section)[1]"/>
-
-  <xsl:variable name="nextfile">
-    <xsl:apply-templates select="$nextfoil" mode="filename"/>
-  </xsl:variable>
-
-  <div class="navhead">
-    <table class="navbar" cellspacing="0" cellpadding="0" border="0" width="97%"
-           summary="Navigation buttons">
-      <tr valign="top">
-        <td align="left">
-          <xsl:call-template name="logo"/>
-        </td>
-        <td valign="top" nowrap="nowrap" width="150">
-          <div align="right">
-            <img border="0" width="32" height="32" alt=" ">
-              <xsl:attribute name="src">
-                <xsl:call-template name="w3c.bleft.image"/>
-              </xsl:attribute>
-            </img>
-            <a rel="contents" href="toc.html" accesskey="C">
-              <img border="0" width="32" height="32"
-                   alt=" Contents" title="Table of Contents">
-                <xsl:attribute name="src">
-                  <xsl:call-template name="w3c.toc.image"/>
-                </xsl:attribute>
-              </img>
-            </a>
-            <a rel="next" href="{$nextfile}" accesskey="N">
-              <img border="0" width="32" height="32"
-                   alt=" Next" title="{$nextfoil/title}">
-                <xsl:attribute name="src">
-                  <xsl:call-template name="w3c.right.image"/>
-                </xsl:attribute>
-              </img>
-            </a>
-          </div>
-        </td>
-      </tr>
-    </table>
+<xsl:param name="css.stylesheet" select="'slides-w3c.css'"/>
 
-    <xsl:apply-templates select="title" mode="head.title"/>
-    <hr class="head"/>
-  </div>
+<xsl:template name="logo">
+  <xsl:if test="$logo.uri != ''">
+    <a href="{$logo.uri}" title="{$logo.title}">
+      <xsl:choose>
+        <xsl:when test="$logo.image.uri=''">
+          <xsl:value-of select="$logo.title"/>
+        </xsl:when>
+        <xsl:otherwise>
+          <img src="{$logo.image.uri}" alt="{$logo.title}" border="0"/>
+        </xsl:otherwise>
+      </xsl:choose>
+    </a>
+  </xsl:if>
 </xsl:template>
 
-<xsl:template name="slidesinfo-bottom-nav">
-  <xsl:param name="prev-target" select="''"/>
-  <xsl:param name="next-target" select="''"/>
-
-  <xsl:variable name="nextfoil" select="(following::foil
-                                        |following::section)[1]"/>
-
-  <xsl:variable name="nextfile">
-    <xsl:apply-templates select="$nextfoil" mode="filename"/>
-  </xsl:variable>
-
-  <div class="navfoot">
-    <hr class="foot"/>
-    <table class="footer" cellspacing="0" cellpadding="0" border="0" width="97%"
-           summary="footer">
-      <tr valign="bottom">
-        <td>&#160;</td>
-        <td>&#160;</td>
-        <td valign="top" nowrap="nowrap" width="150">
-          <div align="right">
-            <img border="0" width="32" height="32" alt=" ">
-              <xsl:attribute name="src">
-                <xsl:call-template name="w3c.bleft.image"/>
-              </xsl:attribute>
-            </img>
-            <a rel="next" href="{$nextfile}" accesskey="N">
-              <img border="0" width="32" height="32"
-                   alt=" Next" title="{$nextfoil/title}">
-                <xsl:attribute name="src">
-                  <xsl:call-template name="w3c.right.image"/>
-                </xsl:attribute>
-              </img>
-            </a>
-          </div>
-        </td>
-      </tr>
-    </table>
-  </div>
+<xsl:template name="overlayDiv.attributes">
+  <xsl:if test="$overlay != 0">
+    <xsl:attribute name="style">
+      <xsl:text>position: absolute; visibility: visible;</xsl:text>
+    </xsl:attribute>
+  </xsl:if>
 </xsl:template>
 
-<xsl:template match="slidesinfo/title" mode="titlepage.mode"/>
-
-<!-- ============================================================ -->
+<!-- ====================================================================== -->
 
-<xsl:template name="section-top-nav">
-  <xsl:param name="prev-target" select="''"/>
-  <xsl:param name="next-target" select="''"/>
-
-  <xsl:variable name="nextfoil" select="foil[1]"/>
-
-  <xsl:variable name="nextfile">
-    <xsl:apply-templates select="$nextfoil" mode="filename"/>
-  </xsl:variable>
-
-  <xsl:variable name="prevfoil" select="preceding::foil"/>
-
-  <xsl:variable name="prevfile">
-    <xsl:choose>
-      <xsl:when test="preceding::foil">
-        <xsl:apply-templates select="preceding::foil[1]" mode="filename"/>
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:value-of select="$titlefoil.html"/>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:variable>
+<xsl:template name="top-nav">
+  <xsl:param name="home"/>
+  <xsl:param name="up"/>
+  <xsl:param name="next"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="tocfile" select="$toc.html"/>
 
   <div class="navhead">
     <table class="navbar" cellspacing="0" cellpadding="0" border="0" width="97%"
            summary="Navigation buttons">
-      <tr valign="top">
-        <td align="left">
+      <tr>
+        <td align="left" valign="top">
           <xsl:call-template name="logo"/>
         </td>
         <td valign="top" nowrap="nowrap" width="150">
           <div align="right">
-            <a rel="previous" href="{$prevfile}" accesskey="P">
-              <img border="0" width="32" height="32"
-                   alt=" Previous" title="{$prevfoil/title}">
-                <xsl:attribute name="src">
-                  <xsl:call-template name="w3c.left.image"/>
-                </xsl:attribute>
-              </img>
-            </a>
-            <a rel="contents" href="toc.html" accesskey="C">
-              <img border="0" width="32" height="32"
-                   alt=" Contents" title="Table of Contents">
-                <xsl:attribute name="src">
-                  <xsl:call-template name="w3c.toc.image"/>
-                </xsl:attribute>
-              </img>
-            </a>
-            <a rel="next" href="{$nextfile}" accesskey="N">
-              <img border="0" width="32" height="32"
-                   alt=" Next" title="{$nextfoil/title}">
-                <xsl:attribute name="src">
-                  <xsl:call-template name="w3c.right.image"/>
-                </xsl:attribute>
-              </img>
-            </a>
+            <xsl:choose>
+              <xsl:when test="$prev">
+                <a rel="previous" accesskey="P">
+                  <xsl:attribute name="href">
+                    <xsl:apply-templates select="$prev" mode="filename"/>
+                  </xsl:attribute>
+                  <img border="0" width="32" height="32"
+                       alt=" Previous" title="{$prev/title}">
+                    <xsl:attribute name="src">
+                      <xsl:call-template name="prev.image"/>
+                    </xsl:attribute>
+                  </img>
+                </a>
+              </xsl:when>
+              <xsl:otherwise>
+                <img border="0" width="32" height="32" alt=" Previous" title="">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="no.prev.image"/>
+                  </xsl:attribute>
+                </img>
+              </xsl:otherwise>
+            </xsl:choose>
+
+            <xsl:choose>
+              <xsl:when test="$tocfile != ''">
+                <a rel="contents" href="{$tocfile}" accesskey="C">
+                  <img border="0" width="32" height="32"
+                       alt=" Contents" title="Table of Contents">
+                    <xsl:attribute name="src">
+                      <xsl:call-template name="toc.image"/>
+                    </xsl:attribute>
+                  </img>
+                </a>
+              </xsl:when>
+              <xsl:otherwise>
+                <img border="0" width="32" height="32"
+                     alt=" Contents" title="Table of Contents">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="no.toc.image"/>
+                  </xsl:attribute>
+                </img>
+              </xsl:otherwise>
+            </xsl:choose>
+
+            <xsl:choose>
+              <xsl:when test="$next">
+                <a rel="next" accesskey="N">
+                  <xsl:attribute name="href">
+                    <xsl:apply-templates select="$next" mode="filename"/>
+                  </xsl:attribute>
+                  <img border="0" width="32" height="32"
+                       alt=" Next" title="{$next/title}">
+                    <xsl:attribute name="src">
+                      <xsl:call-template name="next.image"/>
+                    </xsl:attribute>
+                  </img>
+                </a>
+              </xsl:when>
+              <xsl:otherwise>
+                <img border="0" width="32" height="32" alt=" Next" title="">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="no.next.image"/>
+                  </xsl:attribute>
+                </img>
+              </xsl:otherwise>
+            </xsl:choose>
           </div>
         </td>
       </tr>
     </table>
 
-    <xsl:apply-templates select="title" mode="head.title"/>
-    <hr class="foot"/>
+    <xsl:apply-templates select="title"/>
+    <hr class="top-nav-sep"/>
   </div>
 </xsl:template>
 
-<xsl:template match="section/title" mode="head.title">
-  <h1 class="{name(.)}"><xsl:apply-templates/></h1>
-</xsl:template>
-
-<xsl:template match="section/title"/>
-
-<xsl:template name="section-bottom-nav">
-  <xsl:param name="prev-target" select="''"/>
-  <xsl:param name="next-target" select="''"/>
-
-  <xsl:variable name="nextfoil" select="foil[1]"/>
-
-  <xsl:variable name="nextfile">
-    <xsl:apply-templates select="$nextfoil" mode="filename"/>
-  </xsl:variable>
-
-  <xsl:variable name="prevfoil" select="preceding::foil[1]"/>
-
-  <xsl:variable name="prevfile">
-    <xsl:choose>
-      <xsl:when test="$prevfoil">
-        <xsl:apply-templates select="$prevfoil" mode="filename"/>
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:value-of select="$titlefoil.html"/>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:variable>
+<xsl:template name="bottom-nav">
+  <xsl:param name="home"/>
+  <xsl:param name="up"/>
+  <xsl:param name="next"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="tocfile" select="$toc.html"/>
 
   <div class="navfoot">
-    <hr class="foot"/>
+    <hr class="bottom-nav-sep"/>
     <table class="footer" cellspacing="0" cellpadding="0" border="0" width="97%"
            summary="footer">
-      <tr valign="bottom">
-        <td>
+      <tr>
+        <td align="left" valign="top">
           <xsl:variable name="author" select="(/slides/slidesinfo//author
                                               |/slides/slidesinfo//editor)"/>
           <xsl:for-each select="$author">
             <xsl:if test="position() &lt; last()">, </xsl:if>
           </xsl:for-each>
         </td>
-        <td align="right">
-          <p class="index">
+        <td align="right" valign="top">
+          <span class="index">
             <xsl:value-of select="count(preceding::foil)
-                                  + count(preceding::section)
-                                  + count(ancestor::section)
+                                  + count(preceding::foilgroup)
+                                  + count(ancestor::foilgroup)
                                   + 1"/>
             <xsl:text> of </xsl:text>
-            <xsl:value-of select="count(//foil|//section)"/>
-          </p>
+            <xsl:value-of select="count(//foil|//foilgroup)"/>
+          </span>
         </td>
+
         <td valign="top" nowrap="nowrap" width="150">
           <div align="right">
-            <a rel="previous" href="{$prevfile}" accesskey="P">
-              <img border="0" width="32" height="32"
-                   alt=" Previous" title="{$prevfoil/title}">
-                <xsl:attribute name="src">
-                  <xsl:call-template name="w3c.left.image"/>
-                </xsl:attribute>
-              </img>
-            </a>
-            <a rel="next" href="{$nextfile}" accesskey="N">
-              <img border="0" width="32" height="32"
-                   alt=" Next" title="{$nextfoil/title}">
+            <xsl:choose>
+              <xsl:when test="$prev">
+                <a rel="previous" accesskey="P">
+                  <xsl:attribute name="href">
+                    <xsl:apply-templates select="$prev" mode="filename"/>
+                  </xsl:attribute>
+                  <img border="0" width="32" height="32"
+                       alt=" Previous" title="{$prev/title}">
+                    <xsl:attribute name="src">
+                      <xsl:call-template name="prev.image"/>
+                    </xsl:attribute>
+                  </img>
+                </a>
+              </xsl:when>
+              <xsl:otherwise>
                 <xsl:attribute name="src">
-                  <xsl:call-template name="w3c.right.image"/>
+                  <xsl:call-template name="prev.image"/>
                 </xsl:attribute>
-              </img>
-            </a>
+              </xsl:otherwise>
+            </xsl:choose>
+
+            <xsl:choose>
+              <xsl:when test="$next">
+                <a rel="next" accesskey="N">
+                  <xsl:attribute name="href">
+                    <xsl:apply-templates select="$next" mode="filename"/>
+                  </xsl:attribute>
+                  <img border="0" width="32" height="32"
+                       alt=" Next" title="{$next/title}">
+                    <xsl:attribute name="src">
+                      <xsl:call-template name="next.image"/>
+                    </xsl:attribute>
+                  </img>
+                </a>
+              </xsl:when>
+              <xsl:otherwise>
+                <img border="0" width="32" height="32" alt=" Next" title="">
+                  <xsl:attribute name="src">
+                    <xsl:call-template name="no.next.image"/>
+                  </xsl:attribute>
+                </img>
+              </xsl:otherwise>
+            </xsl:choose>
           </div>
         </td>
       </tr>
   </div>
 </xsl:template>
 
-<!-- ============================================================ -->
-
-<xsl:template name="foil-top-nav">
-  <xsl:param name="prev-target" select="''"/>
-  <xsl:param name="next-target" select="''"/>
-
-  <xsl:variable name="section" select="ancestor::section"/>
-
-  <xsl:variable name="nextfoil" select="(following::foil
-                                        |following::section)[1]"/>
+<!-- ====================================================================== -->
 
-  <xsl:variable name="nextfile">
-    <xsl:apply-templates select="$nextfoil" mode="filename"/>
-  </xsl:variable>
-
-  <xsl:variable name="prevfoil" select="(preceding-sibling::foil[1]
-                                        |parent::section[1])[last()]"/>
-
-  <xsl:variable name="prevfile">
-    <xsl:choose>
-      <xsl:when test="$prevfoil">
-        <xsl:apply-templates select="$prevfoil" mode="filename"/>
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:value-of select="$titlefoil.html"/>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:variable>
+<xsl:template name="titlepage-top-nav">
+  <xsl:param name="home"/>
+  <xsl:param name="up"/>
+  <xsl:param name="next"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="tocfile" select="$toc.html"/>
 
   <div class="navhead">
     <table class="navbar" cellspacing="0" cellpadding="0" border="0" width="97%"
            summary="Navigation buttons">
-      <tr valign="top">
-        <td align="left">
+      <tr>
+        <td align="left" valign="top">
           <xsl:call-template name="logo"/>
         </td>
         <td valign="top" nowrap="nowrap" width="150">
           <div align="right">
-            <a rel="previous" href="{$prevfile}" accesskey="P">
-              <img border="0" width="32" height="32"
-                   alt=" Previous" title="{$prevfoil/title}">
-                <xsl:attribute name="src">
-                  <xsl:call-template name="w3c.left.image"/>
-                </xsl:attribute>
-              </img>
-            </a>
-            <a rel="contents" href="toc.html" accesskey="C">
-              <img border="0" width="32" height="32"
-                   alt=" Contents" title="Table of Contents">
-                <xsl:attribute name="src">
-                  <xsl:call-template name="w3c.toc.image"/>
-                </xsl:attribute>
-              </img>
-            </a>
             <xsl:choose>
-              <xsl:when test="$nextfoil != ''">
-                <a rel="next" href="{$nextfile}" accesskey="N">
+              <xsl:when test="$prev">
+                <a rel="previous" accesskey="P">
+                  <xsl:attribute name="href">
+                    <xsl:apply-templates select="$prev" mode="filename"/>
+                  </xsl:attribute>
                   <img border="0" width="32" height="32"
-                       alt=" Next" title="{$nextfoil/title}">
+                       alt=" Previous" title="{$prev/title}">
                     <xsl:attribute name="src">
-                      <xsl:call-template name="w3c.right.image"/>
+                      <xsl:call-template name="prev.image"/>
                     </xsl:attribute>
                   </img>
                 </a>
               </xsl:when>
               <xsl:otherwise>
-                <img border="0" width="32" height="32" alt=" The End.">
+                <img border="0" width="32" height="32" alt=" Previous" title="">
                   <xsl:attribute name="src">
-                    <xsl:call-template name="w3c.bright.image"/>
+                    <xsl:call-template name="no.prev.image"/>
                   </xsl:attribute>
                 </img>
               </xsl:otherwise>
             </xsl:choose>
-          </div>
-        </td>
-      </tr>
-    </table>
 
-    <xsl:apply-templates select="title" mode="head.title"/>
-    <hr class="head"/>
-  </div>
-</xsl:template>
-
-<xsl:template name="foil-bottom-nav">
-  <xsl:param name="prev-target" select="''"/>
-  <xsl:param name="next-target" select="''"/>
-
-  <xsl:variable name="nextfoil" select="(following::foil
-                                        |following::section)[1]"/>
-
-  <xsl:variable name="nextfile">
-    <xsl:apply-templates select="$nextfoil" mode="filename"/>
-  </xsl:variable>
-
-  <xsl:variable name="prevfoil" select="(preceding-sibling::foil[1]
-                                        |parent::section[1])[last()]"/>
-
-  <xsl:variable name="prevfile">
-    <xsl:choose>
-      <xsl:when test="$prevfoil">
-        <xsl:apply-templates select="$prevfoil" mode="filename"/>
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:value-of select="$titlefoil.html"/>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:variable>
-
-  <div class="navfoot">
-    <hr class="foot"/>
-    <table class="footer" cellspacing="0" cellpadding="0" border="0" width="97%"
-           summary="footer">
-      <tr valign="bottom">
-        <td>
-          <xsl:variable name="author" select="(/slides/slidesinfo//author
-                                              |/slides/slidesinfo//editor)"/>
-          <xsl:for-each select="$author">
             <xsl:choose>
-              <xsl:when test=".//email">
-                <a href="mailto:{.//email[1]}">
-                  <xsl:call-template name="person.name"/>
+              <xsl:when test="$tocfile != ''">
+                <a rel="contents" href="{$tocfile}" accesskey="C">
+                  <img border="0" width="32" height="32"
+                       alt=" Contents" title="Table of Contents">
+                    <xsl:attribute name="src">
+                      <xsl:call-template name="toc.image"/>
+                    </xsl:attribute>
+                  </img>
                 </a>
               </xsl:when>
               <xsl:otherwise>
-                <xsl:call-template name="person.name"/>
-              </xsl:otherwise>
-            </xsl:choose>
-
-            <xsl:if test="position() &lt; last()">, </xsl:if>
-          </xsl:for-each>
-        </td>
-        <td align="right">
-          <p class="index">
-            <xsl:value-of select="count(preceding::foil)
-                                  + count(preceding::section)
-                                  + count(ancestor::section)
-                                  + 1"/>
-            <xsl:text> of </xsl:text>
-            <xsl:value-of select="count(//foil|//section)"/>
-          </p>
-        </td>
-        <td valign="top" nowrap="nowrap" width="150">
-          <div align="right">
-            <a rel="previous" href="{$prevfile}" accesskey="P">
-              <img border="0" width="32" height="32"
-                   alt=" Previous" title="{$prevfoil/title}">
+                <img border="0" width="32" height="32"
+                     alt=" Contents" title="Table of Contents">
                   <xsl:attribute name="src">
-                    <xsl:call-template name="w3c.left.image"/>
+                    <xsl:call-template name="no.toc.image"/>
                   </xsl:attribute>
                 </img>
-            </a>
+              </xsl:otherwise>
+            </xsl:choose>
+
             <xsl:choose>
-              <xsl:when test="$nextfoil != ''">
-                <a rel="next" href="{$nextfile}" accesskey="N">
-                  <img border="0" width="32" height="32"
-                       alt=" Next" title="{$nextfoil/title}">
-                  <xsl:attribute name="src">
-                    <xsl:call-template name="w3c.right.image"/>
+              <xsl:when test="$next">
+                <a rel="next" accesskey="N">
+                  <xsl:attribute name="href">
+                    <xsl:apply-templates select="$next" mode="filename"/>
                   </xsl:attribute>
-                </img>
+                  <img border="0" width="32" height="32"
+                       alt=" Next" title="{$next/title}">
+                    <xsl:attribute name="src">
+                      <xsl:call-template name="next.image"/>
+                    </xsl:attribute>
+                  </img>
                 </a>
               </xsl:when>
               <xsl:otherwise>
-                <img border="0" width="32" height="32" alt=" The End.">
+                <img border="0" width="32" height="32" alt=" Next" title="">
                   <xsl:attribute name="src">
-                    <xsl:call-template name="w3c.bright.image"/>
+                    <xsl:call-template name="no.next.image"/>
                   </xsl:attribute>
                 </img>
               </xsl:otherwise>
         </td>
       </tr>
     </table>
+
+    <hr class="top-nav-sep"/>
   </div>
 </xsl:template>
 
-<xsl:template match="title" mode="head.title">
-  <h1 class="{name(.)}">
-    <xsl:apply-templates/>
-  </h1>
+<!-- ====================================================================== -->
+
+<xsl:template name="foil-body">
+  <xsl:param name="home"/>
+  <xsl:param name="up"/>
+  <xsl:param name="next"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="tocfile" select="$toc.html"/>
+
+  <!-- skip the title -->
+  <xsl:apply-templates select="*[name(.) != 'title']"/>
 </xsl:template>
 
-<xsl:template match="foil/title"/>
+<xsl:template name="foilgroup-body">
+  <xsl:param name="home"/>
+  <xsl:param name="up"/>
+  <xsl:param name="next"/>
+  <xsl:param name="prev"/>
+  <xsl:param name="tocfile" select="$toc.html"/>
+
+  <!-- skip the title -->
+  <xsl:apply-templates select="*[name(.) != 'title'
+                                and name(.) != 'foil'
+                                and name(.) != 'foilgroup']"/>
+</xsl:template>
 
-<!-- ============================================================ -->
+<!-- ====================================================================== -->
 
 <xsl:template match="@*" mode="copy">
   <xsl:attribute name="{local-name(.)}">
   </xsl:element>
 </xsl:template>
 
-<!-- ============================================================ -->
+<!-- ====================================================================== -->
 
 </xsl:stylesheet>