[xml/sgml-commit] r1677 - in /packages/docbook-xsl-ns/trunk/debian: ./ patches/

dleidert-guest at users.alioth.debian.org dleidert-guest at users.alioth.debian.org
Fri Jan 22 15:23:59 UTC 2010


Author: dleidert-guest
Date: Fri Jan 22 15:23:57 2010
New Revision: 1677

URL: http://svn.debian.org/wsvn/debian-xml-sgml/?sc=1&rev=1677
Log:
* debian/patches/8539_554441_xhtml11_fix_ulink_param_target.dpatch: Added.
  - xhtml-1_1/param.xsl: Empty ulink.target to not create target attribute
    in anchor element (closes: #554441).
* debian/patches/561590_param_local_draft_image.dpatch: Added.
  - */param.xsl: Use a local path for the draft image (closes: #561590).
* debian/patches/562227_xhtml_fix_saxon_ns_leakage.dpatch: Added.
  - xhtml/html.xsl, xhtml-1_1/html.xsl: Fix leakage of xmlns:saxon namespace
    in XHTML output (closes: #562227).
* debian/patches/8563_562816_german_translation_fix.dpatch: Added.
  - common/de.xml: Fix an incorrect German translation (closes: #562816).
* debian/patches/00list: Adjusted.

Added:
    packages/docbook-xsl-ns/trunk/debian/patches/561590_param_local_draft_image.dpatch
      - copied unchanged from r1676, packages/docbook-xsl/trunk/debian/patches/561590_param_local_draft_image.dpatch
    packages/docbook-xsl-ns/trunk/debian/patches/562227_xhtml_fix_saxon_ns_leakage.dpatch
      - copied, changed from r1676, packages/docbook-xsl/trunk/debian/patches/562227_xhtml_fix_saxon_ns_leakage.dpatch
    packages/docbook-xsl-ns/trunk/debian/patches/8539_554441_xhtml11_fix_ulink_param_target.dpatch
      - copied unchanged from r1676, packages/docbook-xsl/trunk/debian/patches/8539_554441_xhtml11_fix_ulink_param_target.dpatch
    packages/docbook-xsl-ns/trunk/debian/patches/8563_562816_german_translation_fix.dpatch
      - copied unchanged from r1676, packages/docbook-xsl/trunk/debian/patches/8563_562816_german_translation_fix.dpatch
Modified:
    packages/docbook-xsl-ns/trunk/debian/changelog
    packages/docbook-xsl-ns/trunk/debian/patches/00list

Modified: packages/docbook-xsl-ns/trunk/debian/changelog
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/docbook-xsl-ns/trunk/debian/changelog?rev=1677&op=diff
==============================================================================
--- packages/docbook-xsl-ns/trunk/debian/changelog (original)
+++ packages/docbook-xsl-ns/trunk/debian/changelog Fri Jan 22 15:23:57 2010
@@ -1,6 +1,17 @@
 docbook-xsl-ns (1.75.2+dfsg-4) UNRELEASED; urgency=low
 
   * NOT RELEASED YET
+  * debian/patches/8539_554441_xhtml11_fix_ulink_param_target.dpatch: Added.
+    - xhtml-1_1/param.xsl: Empty ulink.target to not create target attribute
+      in anchor element (closes: #554441).
+  * debian/patches/561590_param_local_draft_image.dpatch: Added.
+    - */param.xsl: Use a local path for the draft image (closes: #561590).
+  * debian/patches/562227_xhtml_fix_saxon_ns_leakage.dpatch: Added.
+    - xhtml/html.xsl, xhtml-1_1/html.xsl: Fix leakage of xmlns:saxon namespace
+      in XHTML output (closes: #562227).
+  * debian/patches/8563_562816_german_translation_fix.dpatch: Added.
+    - common/de.xml: Fix an incorrect German translation (closes: #562816).
+  * debian/patches/00list: Adjusted.
 
  -- Daniel Leidert (dale) <daniel.leidert at wgdd.de>  Wed, 04 Nov 2009 01:30:24 +0100
 

Modified: packages/docbook-xsl-ns/trunk/debian/patches/00list
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/docbook-xsl-ns/trunk/debian/patches/00list?rev=1677&op=diff
==============================================================================
--- packages/docbook-xsl-ns/trunk/debian/patches/00list (original)
+++ packages/docbook-xsl-ns/trunk/debian/patches/00list Fri Jan 22 15:23:57 2010
@@ -1,3 +1,7 @@
 514030_debianize_dbtoepub
 8530_manpages_lists_indentation_fix
 portable_apostrophe_fix
+8539_554441_xhtml11_fix_ulink_param_target
+561590_param_local_draft_image
+562227_xhtml_fix_saxon_ns_leakage
+8563_562816_german_translation_fix

Copied: packages/docbook-xsl-ns/trunk/debian/patches/562227_xhtml_fix_saxon_ns_leakage.dpatch (from r1676, packages/docbook-xsl/trunk/debian/patches/562227_xhtml_fix_saxon_ns_leakage.dpatch)
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/docbook-xsl-ns/trunk/debian/patches/562227_xhtml_fix_saxon_ns_leakage.dpatch?rev=1677&op=diff
==============================================================================
--- packages/docbook-xsl/trunk/debian/patches/562227_xhtml_fix_saxon_ns_leakage.dpatch (original)
+++ packages/docbook-xsl-ns/trunk/debian/patches/562227_xhtml_fix_saxon_ns_leakage.dpatch Fri Jan 22 15:23:57 2010
@@ -9,26 +9,766 @@
 
 @DPATCH@
 diff -urNad trunk~/xhtml/html.xsl trunk/xhtml/html.xsl
---- trunk~/xhtml/html.xsl	2009-07-21 19:39:52.000000000 +0200
-+++ trunk/xhtml/html.xsl	2010-01-22 15:41:16.511934833 +0100
-@@ -165,7 +165,7 @@
+--- trunk~/xhtml/html.xsl	2009-07-21 19:59:06.000000000 +0200
++++ trunk/xhtml/html.xsl	2010-01-22 16:22:04.651934681 +0100
+@@ -167,7 +167,7 @@
        <xsl:with-param name="object" select="$node"/>
      </xsl:call-template>
    </xsl:variable>
--  <xslo:if xmlns:xslo="http://www.w3.org/1999/XSL/Transform" xmlns:saxon="http://icl.com/saxon" test="not($node[parent::blockquote])"><xsl:if test="$conditional = 0 or $node/@id or $node/@xml:id">
-+  <xslo:if xmlns:xslo="http://www.w3.org/1999/XSL/Transform" test="not($node[parent::blockquote])"><xsl:if test="$conditional = 0 or $node/@id or $node/@xml:id">
+-  <xslo:if xmlns:xslo="http://www.w3.org/1999/XSL/Transform" xmlns:saxon="http://icl.com/saxon" test="not($node[parent::d:blockquote])"><xsl:if test="$conditional = 0 or $node/@id or $node/@xml:id">
++  <xslo:if xmlns:xslo="http://www.w3.org/1999/XSL/Transform" test="not($node[parent::d:blockquote])"><xsl:if test="$conditional = 0 or $node/@id or $node/@xml:id">
      <a id="{$id}"/>
    </xsl:if></xslo:if>
  </xsl:template>
+diff -urNad trunk~/xhtml/html.xsl.~1~ trunk/xhtml/html.xsl.~1~
+--- trunk~/xhtml/html.xsl.~1~	1970-01-01 01:00:00.000000000 +0100
++++ trunk/xhtml/html.xsl.~1~	2009-07-21 19:59:06.000000000 +0200
+@@ -0,0 +1,366 @@
++<?xml version="1.0" encoding="ASCII"?>
++<!--This file was created automatically by html2xhtml-->
++<!--from the HTML stylesheets.-->
++<xsl:stylesheet exclude-result-prefixes="d"
++                 xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:d="http://docbook.org/ns/docbook"
++xmlns="http://www.w3.org/1999/xhtml" version="1.0">
++
++<!-- ********************************************************************
++     $Id: html.xsl 8421 2009-05-04 07:49:49Z bobstayton $
++     ********************************************************************
++
++     This file is part of the XSL DocBook Stylesheet distribution.
++     See ../README or http://docbook.sf.net/release/xsl/current/ for
++     copyright and other information.
++
++     ******************************************************************** -->
++
++<!-- These variables set the align attribute value for HTML output based on
++     the writing-mode specified in the gentext file for the document's lang. -->
++
++<xsl:variable name="direction.align.start">
++  <xsl:choose>
++    <xsl:when test="starts-with($writing.mode, 'lr')">left</xsl:when>
++    <xsl:when test="starts-with($writing.mode, 'rl')">right</xsl:when>
++    <xsl:otherwise>left</xsl:otherwise>
++  </xsl:choose>
++</xsl:variable>
++
++<xsl:variable name="direction.align.end">
++  <xsl:choose>
++    <xsl:when test="starts-with($writing.mode, 'lr')">right</xsl:when>
++    <xsl:when test="starts-with($writing.mode, 'rl')">left</xsl:when>
++    <xsl:otherwise>right</xsl:otherwise>
++  </xsl:choose>
++</xsl:variable>
++
++<xsl:variable name="direction.mode">
++  <xsl:choose>
++    <xsl:when test="starts-with($writing.mode, 'lr')">ltr</xsl:when>
++    <xsl:when test="starts-with($writing.mode, 'rl')">rtl</xsl:when>
++    <xsl:otherwise>ltr</xsl:otherwise>
++  </xsl:choose>
++</xsl:variable>
++
++<!-- The generate.html.title template is currently used for generating HTML -->
++<!-- "title" attributes for some inline elements only, but not for any -->
++<!-- block elements. It is called in eleven places in the inline.xsl -->
++<!-- file. But it's called by all the inline.* templates (e.g., -->
++<!-- inline.boldseq), which in turn are called by other (element) -->
++<!-- templates, so it results, currently, in supporting generation of the -->
++<!-- HTML "title" attribute for a total of about 92 elements. -->
++<!-- You can use mode="html.title.attribute" to get a title for -->
++<!-- an element specified by a param, including targets of cross references. -->
++<xsl:template name="generate.html.title">
++  <xsl:apply-templates select="." mode="html.title.attribute"/>
++</xsl:template>
++
++<!-- Generate a title attribute for the context node -->
++<xsl:template match="*" mode="html.title.attribute">
++  <xsl:variable name="is.title">
++    <xsl:call-template name="gentext.template.exists">
++      <xsl:with-param name="context" select="'title'"/>
++      <xsl:with-param name="name" select="local-name(.)"/>
++      <xsl:with-param name="lang">
++        <xsl:call-template name="l10n.language"/>
++      </xsl:with-param>
++    </xsl:call-template>
++  </xsl:variable>
++
++  <xsl:variable name="is.title-numbered">
++    <xsl:call-template name="gentext.template.exists">
++      <xsl:with-param name="context" select="'title-numbered'"/>
++      <xsl:with-param name="name" select="local-name(.)"/>
++      <xsl:with-param name="lang">
++        <xsl:call-template name="l10n.language"/>
++      </xsl:with-param>
++    </xsl:call-template>
++  </xsl:variable>
++
++  <xsl:variable name="is.title-unnumbered">
++    <xsl:call-template name="gentext.template.exists">
++      <xsl:with-param name="context" select="'title-unnumbered'"/>
++      <xsl:with-param name="name" select="local-name(.)"/>
++      <xsl:with-param name="lang">
++        <xsl:call-template name="l10n.language"/>
++      </xsl:with-param>
++    </xsl:call-template>
++  </xsl:variable>
++
++  <xsl:variable name="has.title.markup">
++    <xsl:apply-templates select="." mode="title.markup">
++      <xsl:with-param name="verbose" select="0"/>
++    </xsl:apply-templates>
++  </xsl:variable>
++
++  <xsl:variable name="gentext.title">
++    <xsl:if test="$has.title.markup != '???TITLE???' and                   ($is.title != 0 or                   $is.title-numbered != 0 or                   $is.title-unnumbered != 0)">
++      <xsl:apply-templates select="." mode="object.title.markup.textonly"/>
++    </xsl:if>
++  </xsl:variable>
++
++  <xsl:choose>
++    <xsl:when test="string-length($gentext.title) != 0">
++      <xsl:attribute name="title">
++        <xsl:value-of select="$gentext.title"/>
++      </xsl:attribute>
++    </xsl:when>
++    <!-- Fall back to alt if available -->
++    <xsl:when test="d:alt">
++      <xsl:attribute name="title">
++        <xsl:value-of select="normalize-space(d:alt)"/>
++      </xsl:attribute>
++    </xsl:when>
++  </xsl:choose>
++</xsl:template>
++
++<xsl:template match="d:qandaentry" mode="html.title.attribute">
++  <xsl:apply-templates select="d:question" mode="html.title.attribute"/>
++</xsl:template>
++
++<xsl:template match="d:question" mode="html.title.attribute">
++  <xsl:variable name="label.text">
++    <xsl:apply-templates select="." mode="qanda.label"/>
++  </xsl:variable>
++
++  <xsl:choose>
++    <xsl:when test="string-length($label.text) != 0">
++      <xsl:attribute name="title">
++        <xsl:value-of select="$label.text"/>
++      </xsl:attribute>
++    </xsl:when>
++    <!-- Fall back to alt if available -->
++    <xsl:when test="d:alt">
++      <xsl:attribute name="title">
++        <xsl:value-of select="normalize-space(d:alt)"/>
++      </xsl:attribute>
++    </xsl:when>
++  </xsl:choose>
++</xsl:template>
++
++<xsl:template name="dir">
++  <xsl:param name="inherit" select="0"/>
++
++  <xsl:variable name="dir">
++    <xsl:choose>
++      <xsl:when test="@dir">
++        <xsl:value-of select="@dir"/>
++      </xsl:when>
++      <xsl:when test="$inherit != 0">
++        <xsl:value-of select="ancestor::*/@dir[1]"/>
++      </xsl:when>
++    </xsl:choose>
++  </xsl:variable>
++
++  <xsl:if test="$dir != ''">
++    <xsl:attribute name="dir">
++      <xsl:value-of select="$dir"/>
++    </xsl:attribute>
++  </xsl:if>
++</xsl:template>
++
++<xsl:template name="anchor">
++  <xsl:param name="node" select="."/>
++  <xsl:param name="conditional" select="1"/>
++  <xsl:variable name="id">
++    <xsl:call-template name="object.id">
++      <xsl:with-param name="object" select="$node"/>
++    </xsl:call-template>
++  </xsl:variable>
++  <xslo:if xmlns:xslo="http://www.w3.org/1999/XSL/Transform" xmlns:saxon="http://icl.com/saxon" test="not($node[parent::d:blockquote])"><xsl:if test="$conditional = 0 or $node/@id or $node/@xml:id">
++    <a id="{$id}"/>
++  </xsl:if></xslo:if>
++</xsl:template>
++
++<xsl:template name="href.target.uri">
++  <xsl:param name="context" select="."/>
++  <xsl:param name="object" select="."/>
++  <xsl:text>#</xsl:text>
++  <xsl:call-template name="object.id">
++    <xsl:with-param name="object" select="$object"/>
++  </xsl:call-template>
++</xsl:template>
++
++<xsl:template name="href.target">
++  <xsl:param name="context" select="."/>
++  <xsl:param name="object" select="."/>
++  <xsl:text>#</xsl:text>
++  <xsl:call-template name="object.id">
++    <xsl:with-param name="object" select="$object"/>
++  </xsl:call-template>
++</xsl:template>
++
++<xsl:template name="href.target.with.base.dir">
++  <xsl:param name="context" select="."/>
++  <xsl:param name="object" select="."/>
++  <xsl:if test="$manifest.in.base.dir = 0">
++    <xsl:value-of select="$base.dir"/>
++  </xsl:if>
++  <xsl:call-template name="href.target">
++    <xsl:with-param name="context" select="$context"/>
++    <xsl:with-param name="object" select="$object"/>
++  </xsl:call-template>
++</xsl:template>
++
++<xsl:template name="dingbat">
++  <xsl:param name="dingbat">bullet</xsl:param>
++  <xsl:call-template name="dingbat.characters">
++    <xsl:with-param name="dingbat" select="$dingbat"/>
++  </xsl:call-template>
++</xsl:template>
++
++<xsl:template name="dingbat.characters">
++  <!-- now that I'm using the real serializer, all that dingbat malarky -->
++  <!-- isn't necessary anymore... -->
++  <xsl:param name="dingbat">bullet</xsl:param>
++  <xsl:choose>
++    <xsl:when test="$dingbat='bullet'">&#8226;</xsl:when>
++    <xsl:when test="$dingbat='copyright'">&#169;</xsl:when>
++    <xsl:when test="$dingbat='trademark'">&#8482;</xsl:when>
++    <xsl:when test="$dingbat='trade'">&#8482;</xsl:when>
++    <xsl:when test="$dingbat='registered'">&#174;</xsl:when>
++    <xsl:when test="$dingbat='service'">(SM)</xsl:when>
++    <xsl:when test="$dingbat='nbsp'">&#160;</xsl:when>
++    <xsl:when test="$dingbat='ldquo'">&#8220;</xsl:when>
++    <xsl:when test="$dingbat='rdquo'">&#8221;</xsl:when>
++    <xsl:when test="$dingbat='lsquo'">&#8216;</xsl:when>
++    <xsl:when test="$dingbat='rsquo'">&#8217;</xsl:when>
++    <xsl:when test="$dingbat='em-dash'">&#8212;</xsl:when>
++    <xsl:when test="$dingbat='mdash'">&#8212;</xsl:when>
++    <xsl:when test="$dingbat='en-dash'">&#8211;</xsl:when>
++    <xsl:when test="$dingbat='ndash'">&#8211;</xsl:when>
++    <xsl:otherwise>
++      <xsl:text>&#8226;</xsl:text>
++    </xsl:otherwise>
++  </xsl:choose>
++</xsl:template>
++
++<xsl:template name="id.warning">
++  <xsl:if test="$id.warnings != 0 and not(@id) and not(@xml:id) and parent::*">
++    <xsl:variable name="title">
++      <xsl:choose>
++        <xsl:when test="d:title">
++          <xsl:value-of select="d:title[1]"/>
++        </xsl:when>
++        <xsl:when test="substring(local-name(*[1]),                                   string-length(local-name(*[1])-3) = 'info')                         and *[1]/d:title">
++          <xsl:value-of select="*[1]/d:title[1]"/>
++        </xsl:when>
++        <xsl:when test="d:refmeta/d:refentrytitle">
++          <xsl:value-of select="d:refmeta/d:refentrytitle"/>
++        </xsl:when>
++        <xsl:when test="d:refnamediv/d:refname">
++          <xsl:value-of select="d:refnamediv/d:refname[1]"/>
++        </xsl:when>
++      </xsl:choose>
++    </xsl:variable>
++
++    <xsl:message>
++      <xsl:text>ID recommended on </xsl:text>
++      <xsl:value-of select="local-name(.)"/>
++      <xsl:if test="$title != ''">
++        <xsl:text>: </xsl:text>
++        <xsl:choose>
++          <xsl:when test="string-length($title) &gt; 40">
++            <xsl:value-of select="substring($title,1,40)"/>
++            <xsl:text>...</xsl:text>
++          </xsl:when>
++          <xsl:otherwise>
++            <xsl:value-of select="$title"/>
++          </xsl:otherwise>
++        </xsl:choose>
++      </xsl:if>
++    </xsl:message>
++  </xsl:if>
++</xsl:template>
++
++<xsl:template name="generate.class.attribute">
++  <xsl:param name="class" select="local-name(.)"/>
++  <xsl:apply-templates select="." mode="class.attribute">
++    <xsl:with-param name="class" select="$class"/>
++  </xsl:apply-templates>
++</xsl:template>
++
++<xsl:template match="*" mode="class.attribute">
++  <xsl:param name="class" select="local-name(.)"/>
++  <!-- permit customization of class attributes -->
++  <!-- Use element name by default -->
++  <xsl:attribute name="class">
++    <xsl:apply-templates select="." mode="class.value">
++      <xsl:with-param name="class" select="$class"/>
++    </xsl:apply-templates>
++  </xsl:attribute>
++</xsl:template>
++
++<xsl:template match="*" mode="class.value">
++  <xsl:param name="class" select="local-name(.)"/>
++  <!-- permit customization of class value only -->
++  <!-- Use element name by default -->
++  <xsl:value-of select="$class"/>
++</xsl:template>
++
++<!-- Apply common attributes such as class, lang, dir -->
++<xsl:template name="common.html.attributes">
++  <xsl:param name="inherit" select="0"/>
++  <xsl:param name="class" select="local-name(.)"/>
++  <xsl:apply-templates select="." mode="common.html.attributes">
++    <xsl:with-param name="class" select="$class"/>
++    <xsl:with-param name="inherit" select="$inherit"/>
++  </xsl:apply-templates>
++</xsl:template>
++
++<xsl:template match="*" mode="common.html.attributes">
++  <xsl:param name="class" select="local-name(.)"/>
++  <xsl:param name="inherit" select="0"/>
++  <xsl:call-template name="generate.html.lang"/>
++  <xsl:call-template name="dir">
++    <xsl:with-param name="inherit" select="$inherit"/>
++  </xsl:call-template>
++  <xsl:apply-templates select="." mode="class.attribute">
++    <xsl:with-param name="class" select="$class"/>
++  </xsl:apply-templates>
++  <xsl:call-template name="generate.html.title"/>
++</xsl:template>
++
++<!-- Apply common attributes not including class -->
++<xsl:template name="locale.html.attributes">
++  <xsl:apply-templates select="." mode="locale.html.attributes"/>
++</xsl:template>
++
++<xsl:template match="*" mode="locale.html.attributes">
++  <xsl:call-template name="generate.html.lang"/>
++  <xsl:call-template name="dir"/>
++  <xsl:call-template name="generate.html.title"/>
++</xsl:template>
++
++<!-- Pass through any lang attributes -->
++<xsl:template name="generate.html.lang">
++  <xsl:apply-templates select="." mode="html.lang.attribute"/>
++</xsl:template>
++
++<xsl:template match="*" mode="html.lang.attribute">
++  <!-- match the attribute name to the output type -->
++  <xsl:choose>
++    <xsl:when test="@lang and $stylesheet.result.type = 'html'">
++      <xsl:attribute name="lang">
++        <xsl:value-of select="@lang"/>
++      </xsl:attribute>
++    </xsl:when>
++    <xsl:when test="@lang and $stylesheet.result.type = 'xhtml'">
++      <xsl:attribute name="xml:lang">
++        <xsl:value-of select="@lang"/>
++      </xsl:attribute>
++    </xsl:when>
++    <xsl:when test="@xml:lang and $stylesheet.result.type = 'html'">
++      <xsl:attribute name="lang">
++        <xsl:value-of select="@xml:lang"/>
++      </xsl:attribute>
++    </xsl:when>
++    <xsl:when test="@xml:lang and $stylesheet.result.type = 'xhtml'">
++      <xsl:attribute name="xml:lang">
++        <xsl:value-of select="@xml:lang"/>
++      </xsl:attribute>
++    </xsl:when>
++  </xsl:choose>
++</xsl:template>
++
++</xsl:stylesheet>
 diff -urNad trunk~/xhtml-1_1/html.xsl trunk/xhtml-1_1/html.xsl
---- trunk~/xhtml-1_1/html.xsl	2009-07-21 19:40:02.000000000 +0200
-+++ trunk/xhtml-1_1/html.xsl	2010-01-22 15:42:29.547965529 +0100
-@@ -165,7 +165,7 @@
+--- trunk~/xhtml-1_1/html.xsl	2009-07-21 19:59:13.000000000 +0200
++++ trunk/xhtml-1_1/html.xsl	2010-01-22 16:22:22.796017944 +0100
+@@ -167,7 +167,7 @@
        <xsl:with-param name="object" select="$node"/>
      </xsl:call-template>
    </xsl:variable>
--  <xslo:if xmlns:xslo="http://www.w3.org/1999/XSL/Transform" xmlns:saxon="http://icl.com/saxon" test="not($node[parent::blockquote])"><xsl:if test="$conditional = 0 or $node/@id or $node/@xml:id">
-+  <xslo:if xmlns:xslo="http://www.w3.org/1999/XSL/Transform" test="not($node[parent::blockquote])"><xsl:if test="$conditional = 0 or $node/@id or $node/@xml:id">
+-  <xslo:if xmlns:xslo="http://www.w3.org/1999/XSL/Transform" xmlns:saxon="http://icl.com/saxon" test="not($node[parent::d:blockquote])"><xsl:if test="$conditional = 0 or $node/@id or $node/@xml:id">
++  <xslo:if xmlns:xslo="http://www.w3.org/1999/XSL/Transform" test="not($node[parent::d:blockquote])"><xsl:if test="$conditional = 0 or $node/@id or $node/@xml:id">
      <a id="{$id}"/>
    </xsl:if></xslo:if>
  </xsl:template>
+diff -urNad trunk~/xhtml-1_1/html.xsl.~1~ trunk/xhtml-1_1/html.xsl.~1~
+--- trunk~/xhtml-1_1/html.xsl.~1~	1970-01-01 01:00:00.000000000 +0100
++++ trunk/xhtml-1_1/html.xsl.~1~	2009-07-21 19:59:13.000000000 +0200
+@@ -0,0 +1,366 @@
++<?xml version="1.0" encoding="ASCII"?>
++<!--This file was created automatically by html2xhtml-->
++<!--from the HTML stylesheets.-->
++<xsl:stylesheet exclude-result-prefixes="d"
++                 xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:d="http://docbook.org/ns/docbook"
++xmlns="http://www.w3.org/1999/xhtml" version="1.0">
++
++<!-- ********************************************************************
++     $Id: html.xsl 8421 2009-05-04 07:49:49Z bobstayton $
++     ********************************************************************
++
++     This file is part of the XSL DocBook Stylesheet distribution.
++     See ../README or http://docbook.sf.net/release/xsl/current/ for
++     copyright and other information.
++
++     ******************************************************************** -->
++
++<!-- These variables set the align attribute value for HTML output based on
++     the writing-mode specified in the gentext file for the document's lang. -->
++
++<xsl:variable name="direction.align.start">
++  <xsl:choose>
++    <xsl:when test="starts-with($writing.mode, 'lr')">left</xsl:when>
++    <xsl:when test="starts-with($writing.mode, 'rl')">right</xsl:when>
++    <xsl:otherwise>left</xsl:otherwise>
++  </xsl:choose>
++</xsl:variable>
++
++<xsl:variable name="direction.align.end">
++  <xsl:choose>
++    <xsl:when test="starts-with($writing.mode, 'lr')">right</xsl:when>
++    <xsl:when test="starts-with($writing.mode, 'rl')">left</xsl:when>
++    <xsl:otherwise>right</xsl:otherwise>
++  </xsl:choose>
++</xsl:variable>
++
++<xsl:variable name="direction.mode">
++  <xsl:choose>
++    <xsl:when test="starts-with($writing.mode, 'lr')">ltr</xsl:when>
++    <xsl:when test="starts-with($writing.mode, 'rl')">rtl</xsl:when>
++    <xsl:otherwise>ltr</xsl:otherwise>
++  </xsl:choose>
++</xsl:variable>
++
++<!-- The generate.html.title template is currently used for generating HTML -->
++<!-- "title" attributes for some inline elements only, but not for any -->
++<!-- block elements. It is called in eleven places in the inline.xsl -->
++<!-- file. But it's called by all the inline.* templates (e.g., -->
++<!-- inline.boldseq), which in turn are called by other (element) -->
++<!-- templates, so it results, currently, in supporting generation of the -->
++<!-- HTML "title" attribute for a total of about 92 elements. -->
++<!-- You can use mode="html.title.attribute" to get a title for -->
++<!-- an element specified by a param, including targets of cross references. -->
++<xsl:template name="generate.html.title">
++  <xsl:apply-templates select="." mode="html.title.attribute"/>
++</xsl:template>
++
++<!-- Generate a title attribute for the context node -->
++<xsl:template match="*" mode="html.title.attribute">
++  <xsl:variable name="is.title">
++    <xsl:call-template name="gentext.template.exists">
++      <xsl:with-param name="context" select="'title'"/>
++      <xsl:with-param name="name" select="local-name(.)"/>
++      <xsl:with-param name="lang">
++        <xsl:call-template name="l10n.language"/>
++      </xsl:with-param>
++    </xsl:call-template>
++  </xsl:variable>
++
++  <xsl:variable name="is.title-numbered">
++    <xsl:call-template name="gentext.template.exists">
++      <xsl:with-param name="context" select="'title-numbered'"/>
++      <xsl:with-param name="name" select="local-name(.)"/>
++      <xsl:with-param name="lang">
++        <xsl:call-template name="l10n.language"/>
++      </xsl:with-param>
++    </xsl:call-template>
++  </xsl:variable>
++
++  <xsl:variable name="is.title-unnumbered">
++    <xsl:call-template name="gentext.template.exists">
++      <xsl:with-param name="context" select="'title-unnumbered'"/>
++      <xsl:with-param name="name" select="local-name(.)"/>
++      <xsl:with-param name="lang">
++        <xsl:call-template name="l10n.language"/>
++      </xsl:with-param>
++    </xsl:call-template>
++  </xsl:variable>
++
++  <xsl:variable name="has.title.markup">
++    <xsl:apply-templates select="." mode="title.markup">
++      <xsl:with-param name="verbose" select="0"/>
++    </xsl:apply-templates>
++  </xsl:variable>
++
++  <xsl:variable name="gentext.title">
++    <xsl:if test="$has.title.markup != '???TITLE???' and                   ($is.title != 0 or                   $is.title-numbered != 0 or                   $is.title-unnumbered != 0)">
++      <xsl:apply-templates select="." mode="object.title.markup.textonly"/>
++    </xsl:if>
++  </xsl:variable>
++
++  <xsl:choose>
++    <xsl:when test="string-length($gentext.title) != 0">
++      <xsl:attribute name="title">
++        <xsl:value-of select="$gentext.title"/>
++      </xsl:attribute>
++    </xsl:when>
++    <!-- Fall back to alt if available -->
++    <xsl:when test="d:alt">
++      <xsl:attribute name="title">
++        <xsl:value-of select="normalize-space(d:alt)"/>
++      </xsl:attribute>
++    </xsl:when>
++  </xsl:choose>
++</xsl:template>
++
++<xsl:template match="d:qandaentry" mode="html.title.attribute">
++  <xsl:apply-templates select="d:question" mode="html.title.attribute"/>
++</xsl:template>
++
++<xsl:template match="d:question" mode="html.title.attribute">
++  <xsl:variable name="label.text">
++    <xsl:apply-templates select="." mode="qanda.label"/>
++  </xsl:variable>
++
++  <xsl:choose>
++    <xsl:when test="string-length($label.text) != 0">
++      <xsl:attribute name="title">
++        <xsl:value-of select="$label.text"/>
++      </xsl:attribute>
++    </xsl:when>
++    <!-- Fall back to alt if available -->
++    <xsl:when test="d:alt">
++      <xsl:attribute name="title">
++        <xsl:value-of select="normalize-space(d:alt)"/>
++      </xsl:attribute>
++    </xsl:when>
++  </xsl:choose>
++</xsl:template>
++
++<xsl:template name="dir">
++  <xsl:param name="inherit" select="0"/>
++
++  <xsl:variable name="dir">
++    <xsl:choose>
++      <xsl:when test="@dir">
++        <xsl:value-of select="@dir"/>
++      </xsl:when>
++      <xsl:when test="$inherit != 0">
++        <xsl:value-of select="ancestor::*/@dir[1]"/>
++      </xsl:when>
++    </xsl:choose>
++  </xsl:variable>
++
++  <xsl:if test="$dir != ''">
++    <xsl:attribute name="dir">
++      <xsl:value-of select="$dir"/>
++    </xsl:attribute>
++  </xsl:if>
++</xsl:template>
++
++<xsl:template name="anchor">
++  <xsl:param name="node" select="."/>
++  <xsl:param name="conditional" select="1"/>
++  <xsl:variable name="id">
++    <xsl:call-template name="object.id">
++      <xsl:with-param name="object" select="$node"/>
++    </xsl:call-template>
++  </xsl:variable>
++  <xslo:if xmlns:xslo="http://www.w3.org/1999/XSL/Transform" xmlns:saxon="http://icl.com/saxon" test="not($node[parent::d:blockquote])"><xsl:if test="$conditional = 0 or $node/@id or $node/@xml:id">
++    <a id="{$id}"/>
++  </xsl:if></xslo:if>
++</xsl:template>
++
++<xsl:template name="href.target.uri">
++  <xsl:param name="context" select="."/>
++  <xsl:param name="object" select="."/>
++  <xsl:text>#</xsl:text>
++  <xsl:call-template name="object.id">
++    <xsl:with-param name="object" select="$object"/>
++  </xsl:call-template>
++</xsl:template>
++
++<xsl:template name="href.target">
++  <xsl:param name="context" select="."/>
++  <xsl:param name="object" select="."/>
++  <xsl:text>#</xsl:text>
++  <xsl:call-template name="object.id">
++    <xsl:with-param name="object" select="$object"/>
++  </xsl:call-template>
++</xsl:template>
++
++<xsl:template name="href.target.with.base.dir">
++  <xsl:param name="context" select="."/>
++  <xsl:param name="object" select="."/>
++  <xsl:if test="$manifest.in.base.dir = 0">
++    <xsl:value-of select="$base.dir"/>
++  </xsl:if>
++  <xsl:call-template name="href.target">
++    <xsl:with-param name="context" select="$context"/>
++    <xsl:with-param name="object" select="$object"/>
++  </xsl:call-template>
++</xsl:template>
++
++<xsl:template name="dingbat">
++  <xsl:param name="dingbat">bullet</xsl:param>
++  <xsl:call-template name="dingbat.characters">
++    <xsl:with-param name="dingbat" select="$dingbat"/>
++  </xsl:call-template>
++</xsl:template>
++
++<xsl:template name="dingbat.characters">
++  <!-- now that I'm using the real serializer, all that dingbat malarky -->
++  <!-- isn't necessary anymore... -->
++  <xsl:param name="dingbat">bullet</xsl:param>
++  <xsl:choose>
++    <xsl:when test="$dingbat='bullet'">&#8226;</xsl:when>
++    <xsl:when test="$dingbat='copyright'">&#169;</xsl:when>
++    <xsl:when test="$dingbat='trademark'">&#8482;</xsl:when>
++    <xsl:when test="$dingbat='trade'">&#8482;</xsl:when>
++    <xsl:when test="$dingbat='registered'">&#174;</xsl:when>
++    <xsl:when test="$dingbat='service'">(SM)</xsl:when>
++    <xsl:when test="$dingbat='nbsp'">&#160;</xsl:when>
++    <xsl:when test="$dingbat='ldquo'">&#8220;</xsl:when>
++    <xsl:when test="$dingbat='rdquo'">&#8221;</xsl:when>
++    <xsl:when test="$dingbat='lsquo'">&#8216;</xsl:when>
++    <xsl:when test="$dingbat='rsquo'">&#8217;</xsl:when>
++    <xsl:when test="$dingbat='em-dash'">&#8212;</xsl:when>
++    <xsl:when test="$dingbat='mdash'">&#8212;</xsl:when>
++    <xsl:when test="$dingbat='en-dash'">&#8211;</xsl:when>
++    <xsl:when test="$dingbat='ndash'">&#8211;</xsl:when>
++    <xsl:otherwise>
++      <xsl:text>&#8226;</xsl:text>
++    </xsl:otherwise>
++  </xsl:choose>
++</xsl:template>
++
++<xsl:template name="id.warning">
++  <xsl:if test="$id.warnings != 0 and not(@id) and not(@xml:id) and parent::*">
++    <xsl:variable name="title">
++      <xsl:choose>
++        <xsl:when test="d:title">
++          <xsl:value-of select="d:title[1]"/>
++        </xsl:when>
++        <xsl:when test="substring(local-name(*[1]),                                   string-length(local-name(*[1])-3) = 'info')                         and *[1]/d:title">
++          <xsl:value-of select="*[1]/d:title[1]"/>
++        </xsl:when>
++        <xsl:when test="d:refmeta/d:refentrytitle">
++          <xsl:value-of select="d:refmeta/d:refentrytitle"/>
++        </xsl:when>
++        <xsl:when test="d:refnamediv/d:refname">
++          <xsl:value-of select="d:refnamediv/d:refname[1]"/>
++        </xsl:when>
++      </xsl:choose>
++    </xsl:variable>
++
++    <xsl:message>
++      <xsl:text>ID recommended on </xsl:text>
++      <xsl:value-of select="local-name(.)"/>
++      <xsl:if test="$title != ''">
++        <xsl:text>: </xsl:text>
++        <xsl:choose>
++          <xsl:when test="string-length($title) &gt; 40">
++            <xsl:value-of select="substring($title,1,40)"/>
++            <xsl:text>...</xsl:text>
++          </xsl:when>
++          <xsl:otherwise>
++            <xsl:value-of select="$title"/>
++          </xsl:otherwise>
++        </xsl:choose>
++      </xsl:if>
++    </xsl:message>
++  </xsl:if>
++</xsl:template>
++
++<xsl:template name="generate.class.attribute">
++  <xsl:param name="class" select="local-name(.)"/>
++  <xsl:apply-templates select="." mode="class.attribute">
++    <xsl:with-param name="class" select="$class"/>
++  </xsl:apply-templates>
++</xsl:template>
++
++<xsl:template match="*" mode="class.attribute">
++  <xsl:param name="class" select="local-name(.)"/>
++  <!-- permit customization of class attributes -->
++  <!-- Use element name by default -->
++  <xsl:attribute name="class">
++    <xsl:apply-templates select="." mode="class.value">
++      <xsl:with-param name="class" select="$class"/>
++    </xsl:apply-templates>
++  </xsl:attribute>
++</xsl:template>
++
++<xsl:template match="*" mode="class.value">
++  <xsl:param name="class" select="local-name(.)"/>
++  <!-- permit customization of class value only -->
++  <!-- Use element name by default -->
++  <xsl:value-of select="$class"/>
++</xsl:template>
++
++<!-- Apply common attributes such as class, lang, dir -->
++<xsl:template name="common.html.attributes">
++  <xsl:param name="inherit" select="0"/>
++  <xsl:param name="class" select="local-name(.)"/>
++  <xsl:apply-templates select="." mode="common.html.attributes">
++    <xsl:with-param name="class" select="$class"/>
++    <xsl:with-param name="inherit" select="$inherit"/>
++  </xsl:apply-templates>
++</xsl:template>
++
++<xsl:template match="*" mode="common.html.attributes">
++  <xsl:param name="class" select="local-name(.)"/>
++  <xsl:param name="inherit" select="0"/>
++  <xsl:call-template name="generate.html.lang"/>
++  <xsl:call-template name="dir">
++    <xsl:with-param name="inherit" select="$inherit"/>
++  </xsl:call-template>
++  <xsl:apply-templates select="." mode="class.attribute">
++    <xsl:with-param name="class" select="$class"/>
++  </xsl:apply-templates>
++  <xsl:call-template name="generate.html.title"/>
++</xsl:template>
++
++<!-- Apply common attributes not including class -->
++<xsl:template name="locale.html.attributes">
++  <xsl:apply-templates select="." mode="locale.html.attributes"/>
++</xsl:template>
++
++<xsl:template match="*" mode="locale.html.attributes">
++  <xsl:call-template name="generate.html.lang"/>
++  <xsl:call-template name="dir"/>
++  <xsl:call-template name="generate.html.title"/>
++</xsl:template>
++
++<!-- Pass through any lang attributes -->
++<xsl:template name="generate.html.lang">
++  <xsl:apply-templates select="." mode="html.lang.attribute"/>
++</xsl:template>
++
++<xsl:template match="*" mode="html.lang.attribute">
++  <!-- match the attribute name to the output type -->
++  <xsl:choose>
++    <xsl:when test="@lang and $stylesheet.result.type = 'html'">
++      <xsl:attribute name="lang">
++        <xsl:value-of select="@lang"/>
++      </xsl:attribute>
++    </xsl:when>
++    <xsl:when test="@lang and $stylesheet.result.type = 'xhtml'">
++      <xsl:attribute name="xml:lang">
++        <xsl:value-of select="@lang"/>
++      </xsl:attribute>
++    </xsl:when>
++    <xsl:when test="@xml:lang and $stylesheet.result.type = 'html'">
++      <xsl:attribute name="lang">
++        <xsl:value-of select="@xml:lang"/>
++      </xsl:attribute>
++    </xsl:when>
++    <xsl:when test="@xml:lang and $stylesheet.result.type = 'xhtml'">
++      <xsl:attribute name="xml:lang">
++        <xsl:value-of select="@xml:lang"/>
++      </xsl:attribute>
++    </xsl:when>
++  </xsl:choose>
++</xsl:template>
++
++</xsl:stylesheet>




More information about the debian-xml-sgml-commit mailing list