OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help

docbook-apps message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]

Subject: Re: DocBook XSL*2* stylesheet reorganization

/ Norman Walsh <ndw@nwalsh.com> was heard to say:
| Fair warning to those of you living on the bleeding edge.

Ok. So I reconsidered a bit and didn't end up going the named-template
route after all. But I did change things around. Here's the new idiom
for XSLT2 customization layers:

<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform";
		exclude-result-prefixes="xs db f"

<xsl:import href="/path/to/base/format/docbook.xsl"/>

<xsl:template match="/">
  <!-- You must do this or the stylesheets won't work -->
  <xsl:variable name="normalized" as="document-node()"

  <!-- This checks that the root is a valid root. There's a two-argument
       form that takes an ID. It will return the node with that ID. -->
  <xsl:variable name="root" as="element()"

  <xsl:apply-templates select="$root"/>


Checking in now.

                                        Be seeing you,

Norman Walsh <ndw@nwalsh.com>      | What is familiar is what we are
http://www.oasis-open.org/docbook/ | used to; and what we are used to
Chair, DocBook Technical Committee | is most difficult to 'Know'--that
                                   | is, to see as a problem; that is,
                                   | to see as strange, as distant, as
                                   | 'outside us'.-- Nietzsche

PGP signature

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]