AxKit2
view release on metacpan or search on metacpan
plugins/spod5 view on Meta::CPAN
<xsl:template match="meta">
<xsl:element name="{substring-before(./text(), ' ')}">
<xsl:value-of select="substring-after(./text(), ' ')"/>
</xsl:element>
</xsl:template>
<xsl:template match="*|@*">
<xsl:copy>
<xsl:apply-templates select="*|@*|node()"/>
</xsl:copy>
</xsl:template>
</xsl:stylesheet>
EOT
$pod2s5 = <<'EOT';
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
>
<xsl:output method="html" doctype-public="-//W3C//DTD XHTML 1.0 Strict//EN"
doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"
indent="yes"/>
<xsl:template match="/pod">
<html>
<head>
<title><xsl:value-of select="meta/title"/></title>
<!-- metadata -->
<meta name="generator" content="spod5" />
<meta name="version" content="S5 1.1" />
<meta name="presdate" content="{meta/presdate}" />
<meta name="author" content="{meta/author}" />
<meta name="company" content="{meta/company}" />
<!-- configuration parameters -->
<meta name="defaultView" content="{meta/view or 'slideshow'}" />
<meta name="controlVis" content="{meta/controls or 'hidden'}" />
<base href="{meta/base}ui/{meta/ui-dir}/"/>
<!-- style sheet links -->
<link rel="stylesheet" href="{meta/slides}" type="text/css" media="projection" id="slideProj" />
<link rel="stylesheet" href="outline.css" type="text/css" media="screen" id="outlineStyle" />
<link rel="stylesheet" href="print.css" type="text/css" media="print" id="slidePrint" />
<link rel="stylesheet" href="opera.css" type="text/css" media="projection" id="operaFix" />
<!-- S5 JS -->
<script src="slides.js" type="text/javascript"></script>
<style type="text/css">
<!--
/*
* perltidy's styles
*/
.c { color: #228B22; } /* comment */
.cm { color: #000000; } /* comma */
.co { color: #000000; } /* colon */
.h { color: #CD5555; font-weight:bold; } /* here-doc-target */
.hh { color: #CD5555; font-style:italic; } /* here-doc-text */
.i { color: #00688B; } /* identifier */
.j { color: #000000; font-weight:bold; } /* label */
.k { color: #8B4513; font-weight:bold; } /* keyword */
.m { color: #FF0000; font-weight:bold; } /* subroutine */
.n { color: #B452CD; } /* numeric */
.p { color: #000000; } /* paren */
.pd { color: #228B22; font-style:italic; } /* pod-text */
.pu { color: #000000; } /* punctuation */
.q { color: #CD5555; } /* quote */
.s { color: #000000; } /* structure */
.sc { color: #000000; } /* semicolon */
.v { color: #B452CD; } /* v-string */
.w { color: #000000; } /* bareword */
/* ====================================================================== *
* Sample stylesheet for Syntax::Highlight::HTML *
* *
* Copyright (C)2004 Sebastien Aperghis-Tramoni, All Rights Reserved. *
* *
* This file is free software; you can redistribute it and/or modify *
* it under the same terms as Perl itself. *
* ====================================================================== */
.h-decl { color: #336699; font-style: italic; } /* doctype declaration */
.h-pi { color: #336699; } /* process instruction */
.h-com { color: #338833; font-style: italic; } /* comment */
.h-ab { color: #000000; font-weight: bold; } /* angles as tag delim. */
.h-tag { color: #993399; font-weight: bold; } /* tag name */
.h-attr { color: #000000; font-weight: bold; } /* attribute name */
.h-attv { color: #333399; } /* attribute value */
.h-ent { color: #cc3333; } /* entity */
.h-lno { color: #cccccc; background: #eee; } /* line numbers */
-->
</style>
</head>
<body>
<div class="layout">
<div id="controls"><!-- DO NOT EDIT --></div>
<div id="currentSlide"><!-- DO NOT EDIT --></div>
<div id="header"></div>
<div id="footer">
<h1><xsl:value-of select="meta/presdate"/></h1>
<h2><xsl:value-of select="meta/title"/></h2>
</div>
</div>
<div class="presentation">
<div class="slide">
<xsl:value-of select="meta/title_top"/>
<h1><xsl:value-of select="meta/title"/></h1>
<h3><xsl:value-of select="meta/author"/></h3>
<h4><xsl:value-of select="meta/company"/></h4>
<xsl:value-of select="meta/title_bottom"/>
</div>
<xsl:apply-templates select="*[starts-with(name(), 'head')]"/>
</div>
</body>
</html>
</xsl:template>
<xsl:template match="pod">
<xsl:apply-templates/>
</xsl:template>
<xsl:template match="para">
<xsl:choose>
<xsl:when test="./*[name() != 'orderedlist' and name() != 'itemizedlist']">
<p>
<xsl:apply-templates/>
</p>
</xsl:when>
<xsl:otherwise>
<xsl:apply-templates/>
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<xsl:template match="verbatim">
<pre class="verbatim"><xsl:apply-templates/></pre>
( run in 0.929 second using v1.01-cache-2.11-cpan-39bf76dae61 )