Changeset 8186
- Timestamp:
- 07/01/07 04:54:53 (1 year ago)
- Files:
-
- branches/new-xsl/docbook-xsl-snapshot/VERSION (modified) (4 diffs)
- branches/new-xsl/docbook-xsl-snapshot/common/autoidx-kimber.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/common/autoidx-kosek.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/common/common.xsl (modified) (35 diffs)
- branches/new-xsl/docbook-xsl-snapshot/common/entities.ent (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/common/gentext.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/common/l10n.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/common/labels.xsl (modified) (4 diffs)
- branches/new-xsl/docbook-xsl-snapshot/common/pi.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/common/refentry.xsl (modified) (27 diffs)
- branches/new-xsl/docbook-xsl-snapshot/common/stripns.xsl (modified) (2 diffs)
- branches/new-xsl/docbook-xsl-snapshot/common/subtitles.xsl (modified) (2 diffs)
- branches/new-xsl/docbook-xsl-snapshot/common/table.xsl (modified) (4 diffs)
- branches/new-xsl/docbook-xsl-snapshot/common/targets.xsl (modified) (2 diffs)
- branches/new-xsl/docbook-xsl-snapshot/common/titles.xsl (modified) (2 diffs)
- branches/new-xsl/docbook-xsl-snapshot/common/utility.xsl (added)
- branches/new-xsl/docbook-xsl-snapshot/common/zh_cn.xml (modified) (9 diffs)
- branches/new-xsl/docbook-xsl-snapshot/fo/admon.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/annotations.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/autoidx-kimber.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/autoidx-kosek.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/autoidx-ng.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/autoidx.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/autotoc.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/biblio-iso690.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/biblio.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/block.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/callout.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/component.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/division.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/docbook.xsl (modified) (2 diffs)
- branches/new-xsl/docbook-xsl-snapshot/fo/ebnf.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/fo-rtf.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/fo.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/footnote.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/formal.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/glossary.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/graphics.xsl (modified) (2 diffs)
- branches/new-xsl/docbook-xsl-snapshot/fo/highlight.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/htmltbl.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/index.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/info.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/inline.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/keywords.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/lists.xsl (modified) (3 diffs)
- branches/new-xsl/docbook-xsl-snapshot/fo/math.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/pagesetup.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/param.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/pi.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/profile-docbook.xsl (modified) (2 diffs)
- branches/new-xsl/docbook-xsl-snapshot/fo/qandaset.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/refentry.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/sections.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/synop.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/table.xsl (modified) (3 diffs)
- branches/new-xsl/docbook-xsl-snapshot/fo/task.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/titlepage.templates.xml (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/titlepage.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/toc.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/verbatim.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/xep.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/fo/xref.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/highlighting/common.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/html/chunker.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/lib/lib.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/admon.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/autoidx-kimber.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/autoidx-kosek.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/autoidx-ng.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/autoidx.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/autotoc.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/biblio-iso690.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/biblio.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/block.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/callout.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/changebars.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/chunk-code.xsl (modified) (2 diffs)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/chunk-common.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/chunk.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/chunker.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/chunkfast.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/chunktoc.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/component.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/division.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/docbook.xsl (modified) (2 diffs)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/ebnf.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/footnote.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/formal.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/glossary.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/graphics.xsl (modified) (3 diffs)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/highlight.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/html-rtf.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/html.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/htmltbl.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/index.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/info.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/inline.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/keywords.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/lists.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/maketoc.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/manifest.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/math.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/oldchunker.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/onechunk.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/param.xsl (modified) (2 diffs)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/pi.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/profile-chunk-code.xsl (modified) (2 diffs)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/profile-chunk.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/profile-docbook.xsl (modified) (2 diffs)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/profile-onechunk.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/qandaset.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/refentry.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/sections.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/synop.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/table.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/task.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/titlepage.xsl (modified) (3 diffs)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/toc.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/verbatim.xsl (modified) (1 diff)
- branches/new-xsl/docbook-xsl-snapshot/xhtml/xref.xsl (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
branches/new-xsl/docbook-xsl-snapshot/VERSION
r8175 r8186 1 <?xml version='1.0'?> <!-- -*- nxml -*- -->1 <?xml version='1.0'?> <!-- -*- nxml -*- vim: set foldlevel=2: --> 2 2 <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" 3 xmlns:fm="http://freshmeat.net/projects/freshmeat-submit/"4 xmlns:sf="http://sourceforge.net/"5 exclude-result-prefixes="fm sf"6 version='1.0'>3 xmlns:fm="http://freshmeat.net/projects/freshmeat-submit/" 4 xmlns:sf="http://sourceforge.net/" 5 exclude-result-prefixes="fm sf" 6 version='1.0'> 7 7 8 8 <xsl:param name="VERSION" select="string(document('')//fm:Version[1])"/> … … 12 12 <xsl:param name="PreviousReleaseRevision">6553</xsl:param> 13 13 <xsl:param name="Revision">$Revision$</xsl:param> 14 <xsl:param name="VersionFileURL">$URL: https://svn.sourceforge.net/svnroot/docbook/trunk/xsl/VERSION $</xsl:param> 14 15 <xsl:param name="sf-relid" select="0"/> 15 16 <xsl:strip-space elements="fm:*"/> … … 18 19 <fm:Project>DocBook</fm:Project> 19 20 <fm:Branch>XSL Stylesheets</fm:Branch> 20 <fm:Version>snapshot_6 877</fm:Version>21 <fm:Version>snapshot_6925</fm:Version> 21 22 <!-- 22 23 <fm:License>MIT/X Consortium License</fm:License> … … 38 39 <fm:Bzipped-Tar-URL>http://prdownloads.sourceforge.net/docbook/{DISTRONAME-VERSION}.bz2?download</fm:Bzipped-Tar-URL> 39 40 <fm:Changelog-URL>http://sourceforge.net/project/shownotes.php?release_id={SFRELID}</fm:Changelog-URL> 40 <fm:CVS-URL>http://docbook. cvs.sourceforge.net/docbook/</fm:CVS-URL>41 <fm:CVS-URL>http://docbook.svn.sourceforge.net/viewvc/docbook/</fm:CVS-URL> 41 42 <fm:Mailing-List-URL>http://lists.oasis-open.org/archives/docbook-apps/</fm:Mailing-List-URL> 42 43 <fm:Changes>This is a bug-fix release with a few feature enhancements. branches/new-xsl/docbook-xsl-snapshot/common/autoidx-kimber.xsl
r7978 r8186 18 18 This file is part of the DocBook XSL Stylesheet distribution. 19 19 See ../README or http://docbook.sf.net/ for copyright 20 and other information.20 copyright and other information. 21 21 22 22 ******************************************************************** --> branches/new-xsl/docbook-xsl-snapshot/common/autoidx-kosek.xsl
r7978 r8186 20 20 This file is part of the DocBook XSL Stylesheet distribution. 21 21 See ../README or http://docbook.sf.net/ for copyright 22 and other information.22 copyright and other information. 23 23 24 24 ******************************************************************** --> branches/new-xsl/docbook-xsl-snapshot/common/common.xsl
r8175 r8186 12 12 13 13 This file is part of the XSL DocBook Stylesheet distribution. 14 See ../README or http:// nwalsh.com/docbook/xsl/ for copyright15 and other information.14 See ../README or http://docbook.sf.net/release/xsl/current/ for 15 copyright and other information. 16 16 17 17 This file contains general templates common to both the HTML and FO … … 26 26 <author><surname>Walsh</surname> 27 27 <firstname>Norman</firstname></author> 28 <copyright><year>1999 </year><year>2000</year>28 <copyright><year>1999-2007</year> 29 29 <holder>Norman Walsh</holder> 30 30 </copyright> … … 35 35 <title>Introduction</title> 36 36 37 <para>This is technical reference documentation for the DocBook XSL 38 Stylesheets; it documents (some of) the parameters, templates, and 39 other elements of the stylesheets.</para> 40 41 <para>This is not intended to be <quote>user</quote> documentation. 42 It is provided for developers writing customization layers for the 43 stylesheets, and for anyone who's interested in <quote>how it 44 works</quote>.</para> 45 46 <para>Although I am trying to be thorough, this documentation is known 47 to be incomplete. Don't forget to read the source, too :-)</para> 37 <para>This is technical reference documentation for the âcommonâ 38 templates in the DocBook XSL Stylesheets. The common templates are 39 âcommonâ because they are shared across output formats (that is, 40 theyâre not output-format-dependent).</para> 41 42 <para>This documentation is not intended to be <quote>user</quote> 43 documentation. It is provided for developers writing 44 customization layers for the stylesheets, and for anyone who's 45 interested in <quote>how it works</quote>.</para> 46 48 47 </partintro> 49 48 … … 100 99 <refpurpose>Tests if a given node is a component-level element</refpurpose> 101 100 102 <refdescription >101 <refdescription id="is.component-desc"> 103 102 <para>This template returns '1' if the specified node is a component 104 103 (Chapter, Appendix, etc.), and '0' otherwise.</para> 105 104 </refdescription> 106 105 107 <refparameter >106 <refparameter id="is.component-params"> 108 107 <variablelist> 109 108 <varlistentry><term>node</term> … … 115 114 </refparameter> 116 115 117 <refreturn >116 <refreturn id="is.component-returns"> 118 117 <para>This template returns '1' if the specified node is a component 119 118 (Chapter, Appendix, etc.), and '0' otherwise.</para> … … 140 139 <refpurpose>Tests if a given node is a section-level element</refpurpose> 141 140 142 <refdescription >141 <refdescription id="is.section-desc"> 143 142 <para>This template returns '1' if the specified node is a section 144 143 (Section, Sect1, Sect2, etc.), and '0' otherwise.</para> 145 144 </refdescription> 146 145 147 <refparameter >146 <refparameter id="is.section-params"> 148 147 <variablelist> 149 148 <varlistentry><term>node</term> … … 155 154 </refparameter> 156 155 157 <refreturn >156 <refreturn id="is.section-returns"> 158 157 <para>This template returns '1' if the specified node is a section 159 158 (Section, Sect1, Sect2, etc.), and '0' otherwise.</para> … … 183 182 <refpurpose>Returns the hierarchical level of a section</refpurpose> 184 183 185 <refdescription >184 <refdescription id="section.level-desc"> 186 185 <para>This template calculates the hierarchical level of a section. 187 186 The element <sgmltag>sect1</sgmltag> is at level 1, <sgmltag>sect2</sgmltag> is … … 191 190 </refdescription> 192 191 193 <refparameter >192 <refparameter id="section.level-params"> 194 193 <variablelist> 195 194 <varlistentry><term>node</term> … … 202 201 </refparameter> 203 202 204 <refreturn >203 <refreturn id="section.level-returns"> 205 204 <para>The section level, <quote>1</quote>, <quote>2</quote>, etc. 206 205 </para> … … 260 259 <refpurpose>Returns the hierarchical level of a QandASet</refpurpose> 261 260 262 <refdescription >261 <refdescription id="qanda.section.level-desc"> 263 262 <para>This template calculates the hierarchical level of a QandASet. 264 263 </para> 265 264 </refdescription> 266 265 267 <refreturn >266 <refreturn id="qanda.section.level-returns"> 268 267 <para>The level, <quote>1</quote>, <quote>2</quote>, etc. 269 268 </para> … … 507 506 508 507 <!-- handle corpauthor as a special case...--> 508 <!-- * MikeSmith 2007-06: I'm wondering if the person.name template --> 509 <!-- * actually ever gets called to handle corpauthor.. maybe --> 510 <!-- * we don't actually need to check for corpauthor here. --> 509 511 <xsl:when test="local-name($node)='corpauthor'"> 510 512 <xsl:apply-templates select="$node"/> … … 829 831 <refpurpose>Selects and processes an appropriate media object from a list</refpurpose> 830 832 831 <refdescription >833 <refdescription id="select.mediaobject-desc"> 832 834 <para>This template takes a list of media objects (usually the 833 835 children of a mediaobject or inlinemediaobject) and processes … … 841 843 </refdescription> 842 844 843 <refparameter >845 <refparameter id="select.mediaobject-params"> 844 846 <variablelist> 845 847 <varlistentry><term>olist</term> … … 851 853 </refparameter> 852 854 853 <refreturn >855 <refreturn id="select.mediaobject-returns"> 854 856 <para>Calls <xsl:apply-templates> on the selected object.</para> 855 857 </refreturn> … … 878 880 <refpurpose>Selects the position of the appropriate media object from a list</refpurpose> 879 881 880 <refdescription >882 <refdescription id="select.mediaobject.index-desc"> 881 883 <para>This template takes a list of media objects (usually the 882 884 children of a mediaobject or inlinemediaobject) and determines … … 898 900 </refdescription> 899 901 900 <refparameter >902 <refparameter id="select.mediaobject.index-params"> 901 903 <variablelist> 902 904 <varlistentry><term>olist</term> … … 914 916 </refparameter> 915 917 916 <refreturn >918 <refreturn id="select.mediaobject.index-returns"> 917 919 <para>Returns the position in the original list of the selected object.</para> 918 920 </refreturn> … … 1046 1048 <refpurpose>Returns '1' if the specified media object is recognized</refpurpose> 1047 1049 1048 <refdescription >1050 <refdescription id="is.acceptable.mediaobject-desc"> 1049 1051 <para>This template examines a media object and returns '1' if the 1050 1052 object is recognized as a graphic.</para> 1051 1053 </refdescription> 1052 1054 1053 <refparameter >1055 <refparameter id="is.acceptable.mediaobject-params"> 1054 1056 <variablelist> 1055 1057 <varlistentry><term>object</term> … … 1061 1063 </refparameter> 1062 1064 1063 <refreturn >1065 <refreturn id="is.acceptable.mediaobject-returns"> 1064 1066 <para>0 or 1</para> 1065 1067 </refreturn> … … 1192 1194 <doc:template name="check.id.unique" xmlns=""> 1193 1195 <refpurpose>Warn users about references to non-unique IDs</refpurpose> 1194 <refdescription >1196 <refdescription id="check.id.unique-desc"> 1195 1197 <para>If passed an ID in <varname>linkend</varname>, 1196 1198 <function>check.id.unique</function> prints … … 1232 1234 <doc:template name="check.idref.targets" xmlns=""> 1233 1235 <refpurpose>Warn users about incorrectly typed references</refpurpose> 1234 <refdescription >1236 <refdescription id="check.idref.targets-desc"> 1235 1237 <para>If passed an ID in <varname>linkend</varname>, 1236 1238 <function>check.idref.targets</function> makes sure that the element … … 1488 1490 <refpurpose>Print a set of years with collapsed ranges</refpurpose> 1489 1491 1490 <refdescription >1492 <refdescription id="copyright.years-desc"> 1491 1493 <para>This template prints a list of year elements with consecutive 1492 1494 years printed as a range. In other words:</para> … … 1510 1512 </refdescription> 1511 1513 1512 <refparameter >1514 <refparameter id="copyright.years-params"> 1513 1515 <variablelist> 1514 1516 <varlistentry><term>years</term> … … 1534 1536 </refparameter> 1535 1537 1536 <refreturn >1538 <refreturn id="copyright.years-returns"> 1537 1539 <para>This template returns the formatted list of years.</para> 1538 1540 </refreturn> … … 1666 1668 <refpurpose>Search in a table for the "best" match for the node</refpurpose> 1667 1669 1668 <refdescription >1670 <refdescription id="find.path.params-desc"> 1669 1671 <para>This template searches in a table for the value that most-closely 1670 1672 (in the typical best-match sense of XSLT) matches the current (element) … … 1816 1818 <refpurpose>Converts a string to all uppercase letters</refpurpose> 1817 1819 1818 <refdescription >1820 <refdescription id="string.upper-desc"> 1819 1821 <para>Given a string, this template does a language-aware conversion 1820 1822 of that string to all uppercase letters, based on the values of the … … 1827 1829 </refdescription> 1828 1830 1829 <refparameter >1831 <refparameter id="string.upper-params"> 1830 1832 <variablelist> 1831 1833 <varlistentry><term>string</term> … … 1857 1859 <refpurpose>Converts a string to all lowercase letters</refpurpose> 1858 1860 1859 <refdescription >1861 <refdescription id="string.lower-desc"> 1860 1862 <para>Given a string, this template does a language-aware conversion 1861 1863 of that string to all lowercase letters, based on the values of the … … 1868 1870 </refdescription> 1869 1871 1870 <refparameter >1872 <refparameter id="string.lower-params"> 1871 1873 <variablelist> 1872 1874 <varlistentry><term>string</term> … … 1897 1899 <doc:template name="select.choice.separator" xmlns=""> 1898 1900 <refpurpose>Returns localized choice separator</refpurpose> 1899 <refdescription >1901 <refdescription id="select.choice.separator-desc"> 1900 1902 <para>This template enables auto-generation of an appropriate 1901 1903 localized "choice" separator (for example, "and" or "or") before … … 1963 1965 <doc:template name="evaluate.info.profile" xmlns=""> 1964 1966 <refpurpose>Evaluates an info profile</refpurpose> 1965 <refdescription >1967 <refdescription id="evaluate.info.profile-desc"> 1966 1968 <para>This template evaluates an "info profile" matching the XPath 1967 1969 expression given by the <parameter>profile</parameter> … … 1978 1980 <function>evaluate()</function> extension function.</para> 1979 1981 </refdescription> 1980 <refparameter >1982 <refparameter id="evaluate.info.profile-params"> 1981 1983 <variablelist> 1982 1984 <varlistentry> … … 1995 1997 </refparameter> 1996 1998 1997 <refreturn >1999 <refreturn id="evaluate.info.profile-returns"> 1998 2000 <para>Returns a node (the result of evaluating the 1999 2001 <parameter>profile</parameter> parameter)</para> … … 2024 2026 </xsl:template> 2025 2027 2026 <!-- ===================================== -->2027 2028 <doc:template name="log.message" xmlns="">2029 <refpurpose>Logs/emits formatted notes and warnings</refpurpose>2030 2031 <refdescription>2032 <para>The <function>log.message</function> template is a utility2033 template for logging/emitting formatted messages â that is,2034 notes and warnings, along with a given log "level" and an2035 identifier for the "source" that the message relates to.</para>2036 </refdescription>2037 2038 <refparameter>2039 <variablelist>2040 <varlistentry>2041 <term>level</term>2042 <listitem>2043 <para>Text to log/emit in the message-level field to2044 indicate the message level2045 (<literal>Note</literal> or2046 <literal>Warning</literal>)</para>2047 </listitem>2048 </varlistentry>2049 <varlistentry>2050 <term>source</term>2051 <listitem>2052 <para>Text to log/emit in the source field to identify the2053 âsourceâ to which the notification/warning relates.2054 This can be any arbitrary string, but because the2055 message lacks line and column numbers to identify the2056 exact part of the source document to which it2057 relates, the intention is that the value you pass2058 into the <literal>source</literal> parameter should2059 give the user some way to identify the portion of2060 their source document on which to take potentially2061 take action in response to the log message (for2062 example, to edit, change, or add content).</para>2063 <para>So the <literal>source</literal> value should be,2064 for example, an ID, book/chapter/article title, title2065 of some formal object, or even a string giving an2066 XPath expression.</para>2067 </listitem>2068 </varlistentry>2069 <varlistentry>2070 <term>context-desc</term>2071 <listitem>2072 <para>Text to log/emit in the context-description field to2073 describe the context for the message.</para>2074 </listitem>2075 </varlistentry>2076 <varlistentry>2077 <term>context-desc-field-length</term>2078 <listitem>2079 <para>Specifies length of the context-description field2080 (in characters); default is 12</para>2081 <para>If the text specified by the2082 <literal>context-desc</literal> parameter is longer2083 than the number of characters specified in2084 <literal>context-desc-field-length</literal>, it is2085 truncated to <literal>context-desc-field-length</literal>2086 (12 characters by default).</para>2087 <para>If the specified text is shorter than2088 <literal>context-desc-field-length</literal>,2089 it is right-padded out to2090 <literal>context-desc-field-length</literal> (12 by2091 default).</para>2092 <para>If no value has been specified for the2093 <literal>context-desc</literal> parameter, the field is2094 left empty and the text of the log message begins with2095 the value of the <literal>message</literal>2096 parameter.</para>2097 </listitem>2098 </varlistentry>2099 <varlistentry>2100 <term>message</term>2101 <listitem>2102 <para>Text to log/emit in the actual message field</para>2103 </listitem>2104 </varlistentry>2105 <varlistentry>2106 <term>message-field-length</term>2107 <listitem>2108 <para>Specifies length of the message2109 field (in characters); default is 45</para>2110 </listitem>2111 </varlistentry>2112 </variablelist>2113 </refparameter>2114 <refreturn>2115 <para>Outputs a message (generally, to standard error).</para></refreturn>2116 </doc:template>2117 <xsl:template name="log.message">2118 <xsl:param name="level"/>2119 <xsl:param name="source"/>2120 <xsl:param name="context-desc"/>2121 <xsl:param name="context-desc-field-length">12</xsl:param>2122 <xsl:param name="context-desc-padded">2123 <xsl:if test="not($context-desc = '')">2124 <xsl:call-template name="pad-string">2125 <xsl:with-param name="leftRight">right</xsl:with-param>2126 <xsl:with-param name="padVar"2127 select="substring($context-desc, 1, $context-desc-field-length)"/>2128 <xsl:with-param name="length" select="$context-desc-field-length"/>2129 </xsl:call-template>2130 </xsl:if>2131 </xsl:param>2132 <xsl:param name="message"/>2133 <xsl:param name="message-field-length" select="45"/>2134 <xsl:param name="message-padded">2135 <xsl:variable name="spaces-for-blank-level">2136 <!-- * if the level field is blank, we'll need to pad out -->2137 <!-- * the message field with spaces to compensate -->2138 <xsl:choose>2139 <xsl:when test="$level = ''">2140 <xsl:value-of select="4 + 2"/>2141 <!-- * 4 = hard-coded length of comment text ("Note" or "Warn") -->2142 <!-- * + 2 = length of colon-plus-space separator ": " -->2143 </xsl:when>2144 <xsl:otherwise>2145 <xsl:value-of select="0"/>2146 </xsl:otherwise>2147 </xsl:choose>2148 </xsl:variable>2149 <xsl:variable name="spaces-for-blank-context-desc">2150 <!-- * if the context-description field is blank, we'll need -->2151 <!-- * to pad out the message field with spaces to compensate -->2152 <xsl:choose>2153 <xsl:when test="$context-desc = ''">2154 <xsl:value-of select="$context-desc-field-length + 2"/>2155 <!-- * + 2 = length of colon-plus-space separator ": " -->2156 </xsl:when>2157 <xsl:otherwise>2158 <xsl:value-of select="0"/>2159 </xsl:otherwise>2160 </xsl:choose>2161 </xsl:variable>2162 <xsl:variable name="extra-spaces"2163 select="$spaces-for-blank-level + $spaces-for-blank-context-desc"/>2164 <xsl:call-template name="pad-string">2165 <xsl:with-param name="leftRight">right</xsl:with-param>2166 <xsl:with-param name="padVar"2167 select="substring($message, 1, ($message-field-length + $extra-spaces))"/>2168 <xsl:with-param name="length"2169 select="$message-field-length + $extra-spaces"/>2170 </xsl:call-template>2171 </xsl:param>2172 <!-- * emit the actual log message -->2173 <xsl:message>2174 <xsl:if test="not($level = '')">2175 <xsl:value-of select="$level"/>2176 <xsl:text>: </xsl:text>2177 </xsl:if>2178 <xsl:if test="not($context-desc = '')">2179 <xsl:value-of select="$context-desc-padded"/>2180 <xsl:text>: </xsl:text>2181 </xsl:if>2182 <xsl:value-of select="$message-padded"/>2183 <xsl:text> </xsl:text>2184 <xsl:value-of select="$source"/>2185 </xsl:message>2186 </xsl:template>2187 2188 <!-- ===================================== -->2189 <doc:template name="get.doc.title" xmlns="">2190 <refpurpose>Get a title for the current document</refpurpose>2191 <refdescription>2192 <para>The <function>get.doc.title</function> template is a2193 utility template for returning the first title found in the2194 current document.</para>2195 </refdescription>2196 <refreturn>2197 <para>Returns a string containing some identifying title for the2198 current document .</para></refreturn>2199 </doc:template>2200 <xsl:template name="get.doc.title">2201 <xsl:choose>2202 <xsl:when test="//*[local-name() = 'title'2203 or local-name() = 'refname']">2204 <xsl:value-of select="//*[local-name() = 'title'2205 or local-name() = 'refname'][1]"/>2206 </xsl:when>2207 <xsl:when test="substring(local-name(*[1]),2208 string-length(local-name(*[1])-3) = 'info')2209 and *[1]/*[local-name() = 'title']">2210 <xsl:value-of select="*[1]/*[local-name() = 'title'][1]"/>2211 </xsl:when>2212 </xsl:choose>2213 </xsl:template>2214 2215 <!-- ===================================== -->2216 <doc:template name="pad.string" xmlns="">2217 <refpurpose>Right-pad or left-pad a string out to a certain length</refpurpose>2218 <refdescription>2219 <para>This function takes string <parameter>padVar</parameter> and2220 pads it out in the direction <parameter>rightLeft</parameter> to2221 the string-length <parameter>length</parameter>, using string2222 <parameter>padChar</parameter> (a space character by default) as2223 the padding string (note that <parameter>padChar</parameter> can2224 be a string; it is not limited to just being a single2225 character).</para>2226 2227 <note>2228 <para>This function began as a copy of Nate Austin's2229 <function>prepend-pad</function> function in the <ulink2230 url="http://www.dpawson.co.uk/xsl/sect2/padding.html" >Padding2231 Content</ulink> section of Dave Pawson's <ulink2232 url="http://www.dpawson.co.uk/xsl/index.html" >XSLT2233 FAQ</ulink>.</para>2234 </note>2235 </refdescription>2236 <refreturn>2237 <para>Returns a (padded) string.</para></refreturn>2238 </doc:template>2239 2240 <xsl:template name="pad-string">2241 <!-- * recursive template to right/left pad the value with -->2242 <!-- * whatever padChar is passed in -->2243 <xsl:param name="padChar" select="' '"/>2244 <xsl:param name="leftRight">left</xsl:param>2245 <xsl:param name="padVar"/>2246 <xsl:param name="length"/>2247 <xsl:choose>2248 <xsl:when test="string-length($padVar) < $length">2249 <xsl:call-template name="pad-string">2250 <xsl:with-param name="padChar" select="$padChar"/>2251 <xsl:with-param name="leftRight" select="$leftRight"/>2252 <xsl:with-param name="padVar">2253 <xsl:choose>2254 <!-- * determine whether string should be -->2255 <!-- * right- or left-padded -->2256 <xsl:when test="$leftRight = 'left'">2257 <!-- * pad it to left -->2258 <xsl:value-of select="concat($padChar,$padVar)"/>2259 </xsl:when>2260 <xsl:otherwise>2261 <!-- * otherwise, right-pad the string -->2262 <xsl:value-of select="concat($padVar,$padChar)"/>2263 </xsl:otherwise>2264 </xsl:choose>2265 </xsl:with-param>2266 <xsl:with-param name="length" select="$length"/>2267 </xsl:call-template>2268 </xsl:when>2269 <xsl:otherwise>2270 <xsl:value-of2271 select="substring($padVar,string-length($padVar) - $length + 1)"/>2272 </xsl:otherwise>2273 </xsl:choose>2274 </xsl:template>2275 2276 2028 </xsl:stylesheet> branches/new-xsl/docbook-xsl-snapshot/common/entities.ent
r8171 r8186 7 7 8 8 This file is part of the XSL DocBook Stylesheet distribution. 9 See ../README or http:// nwalsh.com/docbook/xsl/ for copyright10 and other information.9 See ../README or http://docbook.sf.net/release/xsl/current/ for 10 copyright and other information. 11 11 12 12 ******************************************************************** --> branches/new-xsl/docbook-xsl-snapshot/common/gentext.xsl
r7978 r8186 10 10 11 11 This file is part of the XSL DocBook Stylesheet distribution. 12 See ../README or http:// nwalsh.com/docbook/xsl/ for copyright13 and other information.12 See ../README or http://docbook.sf.net/release/xsl/current/ for 13 copyright and other information. 14 14 15 15 ******************************************************************** --> branches/new-xsl/docbook-xsl-snapshot/common/l10n.xsl
r7978 r8186 10 10 11 11 This file is part of the XSL DocBook Stylesheet distribution. 12 See ../README or http:// nwalsh.com/docbook/xsl/ for copyright13 and other information.12 See ../README or http://docbook.sf.net/release/xsl/current/ for 13 copyright and other information. 14 14 15 15 This file contains localization templates (for internationalization)
