metanorma-un 0.3.9 → 0.3.10
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/asciidoctor/un/biblio.rng +13 -3
- data/lib/asciidoctor/un/boilerplate.xml +1 -1
- data/lib/asciidoctor/un/isodoc.rng +17 -1
- data/lib/isodoc/un/html/word_unece_plenary_titlepage.html +9187 -101
- data/lib/isodoc/un/html_convert.rb +1 -0
- data/lib/isodoc/un/metadata.rb +4 -1
- data/lib/isodoc/un/pdf_convert.rb +11 -2
- data/lib/isodoc/un/un.plenary-attachment.xsl +3834 -0
- data/lib/isodoc/un/un.plenary.xsl +337 -124
- data/lib/isodoc/un/un.recommendation.xsl +332 -98
- data/lib/isodoc/un/word_convert.rb +1 -5
- data/lib/metanorma/un/version.rb +1 -1
- data/metanorma-unece.gemspec +1 -1
- metadata +5 -4
@@ -103,7 +103,9 @@
|
|
103
103
|
</xsl:variable>
|
104
104
|
<xsl:value-of select="normalize-space($abstract)"/>
|
105
105
|
</dc:description>
|
106
|
-
<pdf:Keywords
|
106
|
+
<pdf:Keywords>
|
107
|
+
<xsl:call-template name="insertKeywords"/>
|
108
|
+
</pdf:Keywords>
|
107
109
|
</rdf:Description>
|
108
110
|
<rdf:Description xmlns:xmp="http://ns.adobe.com/xap/1.0/" rdf:about="">
|
109
111
|
<!-- XMP properties go here -->
|
@@ -1400,15 +1402,7 @@
|
|
1400
1402
|
<xsl:apply-templates/>
|
1401
1403
|
</fo:block>
|
1402
1404
|
</xsl:template>
|
1403
|
-
|
1404
|
-
<xsl:template match="un:sourcecode">
|
1405
|
-
<fo:block font-family="Courier" font-size="10pt" margin-top="6pt" margin-bottom="6pt">
|
1406
|
-
<xsl:attribute name="white-space">pre</xsl:attribute>
|
1407
|
-
<xsl:attribute name="wrap-option">wrap</xsl:attribute>
|
1408
|
-
<xsl:apply-templates/>
|
1409
|
-
</fo:block>
|
1410
|
-
</xsl:template>
|
1411
|
-
|
1405
|
+
|
1412
1406
|
<xsl:template match="un:references">
|
1413
1407
|
<fo:block>
|
1414
1408
|
<xsl:if test="not(un:title)">
|
@@ -11902,16 +11896,76 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
11902
11896
|
</xsl:text>
|
11903
11897
|
</xsl:variable>
|
11904
11898
|
|
11905
|
-
<xsl:variable xmlns:
|
11899
|
+
<xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-table">
|
11900
|
+
|
11901
|
+
<xsl:text>Table </xsl:text>
|
11902
|
+
|
11903
|
+
|
11904
|
+
</xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-note">
|
11905
|
+
|
11906
|
+
<xsl:text>NOTE </xsl:text>
|
11907
|
+
|
11908
|
+
|
11909
|
+
</xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-figure">
|
11910
|
+
|
11911
|
+
<xsl:text>Figure </xsl:text>
|
11912
|
+
|
11913
|
+
|
11914
|
+
</xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-example">
|
11915
|
+
|
11916
|
+
<xsl:text>EXAMPLE </xsl:text>
|
11917
|
+
|
11918
|
+
|
11919
|
+
</xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-inequality">Inequality </xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-equation">Equation </xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-annex">
|
11920
|
+
|
11921
|
+
<xsl:text>Annex </xsl:text>
|
11922
|
+
|
11923
|
+
|
11924
|
+
</xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-appendix">
|
11925
|
+
<xsl:text>Appendix </xsl:text>
|
11926
|
+
</xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-clause">
|
11927
|
+
|
11928
|
+
<xsl:text>Clause </xsl:text>
|
11929
|
+
|
11930
|
+
|
11931
|
+
</xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-edition">
|
11932
|
+
<xsl:text>Edition </xsl:text>
|
11933
|
+
</xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-toc">
|
11934
|
+
|
11935
|
+
|
11936
|
+
</xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-page">Page</xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-key">Key</xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-where">where</xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-descriptors">Descriptors</xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-part-en">Part </xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-part-fr">Partie </xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-note-to-entry">Note # to entry: </xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-modified">modified</xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-source">SOURCE</xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-keywords">Keywords</xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="lower">abcdefghijklmnopqrstuvwxyz</xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="upper">ABCDEFGHIJKLMNOPQRSTUVWXYZ</xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="en_chars" select="concat($lower,$upper,',.`1234567890-=~!@#$%^*()_+[]{}\|?/')"/><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="linebreak" select="'
'"/><xsl:attribute-set xmlns:java="http://xml.apache.org/xalan/java" name="link-style">
|
11937
|
+
|
11938
|
+
|
11939
|
+
</xsl:attribute-set><xsl:attribute-set xmlns:java="http://xml.apache.org/xalan/java" name="sourcecode-style">
|
11940
|
+
|
11941
|
+
|
11942
|
+
|
11943
|
+
|
11944
|
+
|
11945
|
+
<xsl:attribute name="font-family">Courier</xsl:attribute>
|
11946
|
+
<xsl:attribute name="font-size">10pt</xsl:attribute>
|
11947
|
+
<xsl:attribute name="margin-top">6pt</xsl:attribute>
|
11948
|
+
<xsl:attribute name="margin-bottom">6pt</xsl:attribute>
|
11949
|
+
|
11950
|
+
|
11951
|
+
|
11952
|
+
|
11953
|
+
</xsl:attribute-set><xsl:attribute-set xmlns:java="http://xml.apache.org/xalan/java" name="appendix-style">
|
11954
|
+
|
11955
|
+
|
11956
|
+
|
11957
|
+
</xsl:attribute-set><xsl:attribute-set xmlns:java="http://xml.apache.org/xalan/java" name="appendix-example-style">
|
11906
11958
|
|
11907
11959
|
|
11908
|
-
|
11960
|
+
|
11961
|
+
</xsl:attribute-set><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="text()">
|
11909
11962
|
<xsl:value-of select="."/>
|
11910
|
-
</xsl:template><xsl:template xmlns:
|
11963
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='br']">
|
11911
11964
|
<xsl:value-of select="$linebreak"/>
|
11912
|
-
</xsl:template><xsl:template xmlns:
|
11913
|
-
<xsl:call-template name="add-zero-spaces"/>
|
11914
|
-
|
11965
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='td']//text() | *[local-name()='th']//text() | *[local-name()='dt']//text() | *[local-name()='dd']//text()" priority="1">
|
11966
|
+
<!-- <xsl:call-template name="add-zero-spaces"/> -->
|
11967
|
+
<xsl:call-template name="add-zero-spaces-java"/>
|
11968
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='table']">
|
11915
11969
|
|
11916
11970
|
<xsl:variable name="simple-table">
|
11917
11971
|
<!-- <xsl:copy> -->
|
@@ -11942,7 +11996,7 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
11942
11996
|
<xsl:attribute name="margin-top">12pt</xsl:attribute>
|
11943
11997
|
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
11944
11998
|
|
11945
|
-
<xsl:
|
11999
|
+
<xsl:value-of select="$title-table"/>
|
11946
12000
|
<xsl:choose>
|
11947
12001
|
<xsl:when test="ancestor::*[local-name()='executivesummary']"> <!-- NIST -->
|
11948
12002
|
<xsl:text>ES-</xsl:text><xsl:number format="1" count="*[local-name()='executivesummary']//*[local-name()='table'][not(@unnumbered) or @unnumbered != 'true']"/>
|
@@ -12032,6 +12086,7 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12032
12086
|
|
12033
12087
|
|
12034
12088
|
|
12089
|
+
|
12035
12090
|
<fo:table id="{@id}" table-layout="fixed" width="100%" margin-left="{$margin-left}mm" margin-right="{$margin-left}mm" table-omit-footer-at-break="true">
|
12036
12091
|
|
12037
12092
|
|
@@ -12051,9 +12106,10 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12051
12106
|
|
12052
12107
|
|
12053
12108
|
|
12109
|
+
|
12054
12110
|
<xsl:for-each select="xalan:nodeset($colwidths)//column">
|
12055
12111
|
<xsl:choose>
|
12056
|
-
<xsl:when test=". = 1">
|
12112
|
+
<xsl:when test=". = 1 or . = 0">
|
12057
12113
|
<fo:table-column column-width="proportional-column-width(2)"/>
|
12058
12114
|
</xsl:when>
|
12059
12115
|
<xsl:otherwise>
|
@@ -12067,15 +12123,43 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12067
12123
|
|
12068
12124
|
|
12069
12125
|
</fo:block-container>
|
12070
|
-
</xsl:template><xsl:template xmlns:
|
12126
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="getTableNumber">
|
12127
|
+
<xsl:choose>
|
12128
|
+
<xsl:when test="ancestor::*[local-name()='executivesummary']"> <!-- NIST -->
|
12129
|
+
<xsl:text>ES-</xsl:text><xsl:number format="1" count="*[local-name()='executivesummary']//*[local-name()='table'][not(@unnumbered) or @unnumbered != 'true']"/>
|
12130
|
+
</xsl:when>
|
12131
|
+
<xsl:when test="ancestor::*[local-name()='annex']">
|
12132
|
+
|
12133
|
+
|
12134
|
+
|
12135
|
+
|
12136
|
+
|
12137
|
+
|
12138
|
+
<!-- <xsl:variable name="annex-id" select="ancestor::*[local-name()='annex']/@id"/>
|
12139
|
+
<xsl:number format="I." count="*[local-name()='annex']"/> -->
|
12140
|
+
<xsl:text>A</xsl:text> <!-- 'A' means Annex -->
|
12141
|
+
<xsl:number format="1" level="any" count="*[local-name()='table'][not(@unnumbered) or @unnumbered != 'true'][ancestor::*[local-name()='annex']]"/> <!-- [@id = $annex-id] -->
|
12142
|
+
|
12143
|
+
|
12144
|
+
|
12145
|
+
</xsl:when>
|
12146
|
+
<xsl:otherwise>
|
12147
|
+
|
12148
|
+
|
12149
|
+
<xsl:number format="A." count="*[local-name()='annex']"/>
|
12150
|
+
<xsl:number format="1" level="any" count="//*[local-name()='table'] [not(ancestor::*[local-name()='annex']) and not(ancestor::*[local-name()='executivesummary']) and not(ancestor::*[local-name()='bibdata'])] [not(@unnumbered) or @unnumbered != 'true']"/>
|
12151
|
+
|
12152
|
+
</xsl:otherwise>
|
12153
|
+
</xsl:choose>
|
12154
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='table']/*[local-name()='name']"/><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='table']/*[local-name()='name']" mode="process">
|
12071
12155
|
<xsl:apply-templates/>
|
12072
|
-
</xsl:template><xsl:template xmlns:
|
12156
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="calculate-columns-numbers">
|
12073
12157
|
<xsl:param name="table-row"/>
|
12074
12158
|
<xsl:variable name="columns-count" select="count($table-row/*)"/>
|
12075
12159
|
<xsl:variable name="sum-colspans" select="sum($table-row/*/@colspan)"/>
|
12076
12160
|
<xsl:variable name="columns-with-colspan" select="count($table-row/*[@colspan])"/>
|
12077
12161
|
<xsl:value-of select="$columns-count + $sum-colspans - $columns-with-colspan"/>
|
12078
|
-
</xsl:template><xsl:template xmlns:
|
12162
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="calculate-column-widths">
|
12079
12163
|
<xsl:param name="table"/>
|
12080
12164
|
<xsl:param name="cols-count"/>
|
12081
12165
|
<xsl:param name="curr-col" select="1"/>
|
@@ -12084,7 +12168,7 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12084
12168
|
<xsl:if test="$curr-col <= $cols-count">
|
12085
12169
|
<xsl:variable name="widths">
|
12086
12170
|
<xsl:choose>
|
12087
|
-
<xsl:when test="not($table)"
|
12171
|
+
<xsl:when test="not($table)"><!-- this branch is not using in production, for debug only -->
|
12088
12172
|
<xsl:for-each select="*[local-name()='thead']//*[local-name()='tr']">
|
12089
12173
|
<xsl:variable name="words">
|
12090
12174
|
<xsl:call-template name="tokenize">
|
@@ -12123,9 +12207,16 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12123
12207
|
<xsl:apply-templates select="td[$curr-col]" mode="td_text"/>
|
12124
12208
|
</xsl:variable>
|
12125
12209
|
<xsl:variable name="words">
|
12210
|
+
<xsl:variable name="string_with_added_zerospaces">
|
12211
|
+
<xsl:call-template name="add-zero-spaces-java">
|
12212
|
+
<xsl:with-param name="text" select="$td_text"/>
|
12213
|
+
</xsl:call-template>
|
12214
|
+
</xsl:variable>
|
12126
12215
|
<xsl:call-template name="tokenize">
|
12127
12216
|
<!-- <xsl:with-param name="text" select="translate(td[$curr-col],'- —:', ' ')"/> -->
|
12128
|
-
|
12217
|
+
<!-- 2009 thinspace -->
|
12218
|
+
<!-- <xsl:with-param name="text" select="translate(normalize-space($td_text),'- —:', ' ')"/> -->
|
12219
|
+
<xsl:with-param name="text" select="normalize-space(translate($string_with_added_zerospaces, '', ' '))"/>
|
12129
12220
|
</xsl:call-template>
|
12130
12221
|
</xsl:variable>
|
12131
12222
|
<xsl:variable name="max_length">
|
@@ -12166,17 +12257,24 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12166
12257
|
<xsl:with-param name="table" select="$table"/>
|
12167
12258
|
</xsl:call-template>
|
12168
12259
|
</xsl:if>
|
12169
|
-
</xsl:template><xsl:template xmlns:
|
12260
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="text()" mode="td_text">
|
12170
12261
|
<xsl:variable name="zero-space"></xsl:variable>
|
12171
12262
|
<xsl:value-of select="translate(., $zero-space, ' ')"/><xsl:text> </xsl:text>
|
12172
|
-
</xsl:template><xsl:template xmlns:
|
12263
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='termsource']" mode="td_text">
|
12264
|
+
<xsl:value-of select="*[local-name()='origin']/@citeas"/>
|
12265
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='link']" mode="td_text">
|
12266
|
+
<xsl:value-of select="@target"/>
|
12267
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='table2']"/><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='thead']"/><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='thead']" mode="process">
|
12268
|
+
<xsl:param name="cols-count"/>
|
12173
12269
|
<!-- font-weight="bold" -->
|
12174
|
-
<fo:table-header>
|
12270
|
+
<fo:table-header>
|
12271
|
+
|
12175
12272
|
<xsl:apply-templates/>
|
12176
12273
|
</fo:table-header>
|
12177
|
-
</xsl:template><xsl:template xmlns:
|
12274
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='tfoot']"/><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='tfoot']" mode="process">
|
12178
12275
|
<xsl:apply-templates/>
|
12179
|
-
</xsl:template><xsl:template xmlns:
|
12276
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="insertTableFooter">
|
12277
|
+
<xsl:param name="cols-count"/>
|
12180
12278
|
<xsl:variable name="isNoteOrFnExist" select="../*[local-name()='note'] or ..//*[local-name()='fn'][local-name(..) != 'name']"/>
|
12181
12279
|
<xsl:if test="../*[local-name()='tfoot'] or $isNoteOrFnExist = 'true'">
|
12182
12280
|
|
@@ -12187,22 +12285,7 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12187
12285
|
<!-- if there are note(s) or fn(s) then create footer row -->
|
12188
12286
|
<xsl:if test="$isNoteOrFnExist = 'true'">
|
12189
12287
|
|
12190
|
-
|
12191
|
-
<xsl:choose>
|
12192
|
-
<xsl:when test="../*[local-name()='thead']">
|
12193
|
-
<!-- <xsl:value-of select="count(../*[local-name()='thead']/*[local-name()='tr']/*[local-name()='th'])"/> -->
|
12194
|
-
<xsl:call-template name="calculate-columns-numbers">
|
12195
|
-
<xsl:with-param name="table-row" select="../*[local-name()='thead']/*[local-name()='tr'][1]"/>
|
12196
|
-
</xsl:call-template>
|
12197
|
-
</xsl:when>
|
12198
|
-
<xsl:otherwise>
|
12199
|
-
<!-- <xsl:value-of select="count(./*[local-name()='tr'][1]/*[local-name()='td'])"/> -->
|
12200
|
-
<xsl:call-template name="calculate-columns-numbers">
|
12201
|
-
<xsl:with-param name="table-row" select="./*[local-name()='tr'][1]"/>
|
12202
|
-
</xsl:call-template>
|
12203
|
-
</xsl:otherwise>
|
12204
|
-
</xsl:choose>
|
12205
|
-
</xsl:variable>
|
12288
|
+
|
12206
12289
|
|
12207
12290
|
<fo:table-row>
|
12208
12291
|
<fo:table-cell border="solid black 1pt" padding-left="1mm" padding-right="1mm" padding-top="1mm" number-columns-spanned="{$cols-count}">
|
@@ -12230,11 +12313,30 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12230
12313
|
</fo:table-footer>
|
12231
12314
|
|
12232
12315
|
</xsl:if>
|
12233
|
-
</xsl:template><xsl:template xmlns:
|
12316
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='tbody']">
|
12317
|
+
|
12318
|
+
<xsl:variable name="cols-count">
|
12319
|
+
<xsl:choose>
|
12320
|
+
<xsl:when test="../*[local-name()='thead']">
|
12321
|
+
<xsl:call-template name="calculate-columns-numbers">
|
12322
|
+
<xsl:with-param name="table-row" select="../*[local-name()='thead']/*[local-name()='tr'][1]"/>
|
12323
|
+
</xsl:call-template>
|
12324
|
+
</xsl:when>
|
12325
|
+
<xsl:otherwise>
|
12326
|
+
<xsl:call-template name="calculate-columns-numbers">
|
12327
|
+
<xsl:with-param name="table-row" select="./*[local-name()='tr'][1]"/>
|
12328
|
+
</xsl:call-template>
|
12329
|
+
</xsl:otherwise>
|
12330
|
+
</xsl:choose>
|
12331
|
+
</xsl:variable>
|
12234
12332
|
|
12235
|
-
<xsl:apply-templates select="../*[local-name()='thead']" mode="process"
|
12333
|
+
<xsl:apply-templates select="../*[local-name()='thead']" mode="process">
|
12334
|
+
<xsl:with-param name="cols-count" select="$cols-count"/>
|
12335
|
+
</xsl:apply-templates>
|
12236
12336
|
|
12237
|
-
<xsl:call-template name="insertTableFooter"
|
12337
|
+
<xsl:call-template name="insertTableFooter">
|
12338
|
+
<xsl:with-param name="cols-count" select="$cols-count"/>
|
12339
|
+
</xsl:call-template>
|
12238
12340
|
|
12239
12341
|
<fo:table-body>
|
12240
12342
|
<xsl:apply-templates/>
|
@@ -12242,7 +12344,7 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12242
12344
|
|
12243
12345
|
</fo:table-body>
|
12244
12346
|
|
12245
|
-
</xsl:template><xsl:template xmlns:
|
12347
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='tr']">
|
12246
12348
|
<xsl:variable name="parent-name" select="local-name(..)"/>
|
12247
12349
|
<!-- <xsl:variable name="namespace" select="substring-before(name(/*), '-')"/> -->
|
12248
12350
|
<fo:table-row min-height="4mm">
|
@@ -12262,7 +12364,7 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12262
12364
|
|
12263
12365
|
<xsl:apply-templates/>
|
12264
12366
|
</fo:table-row>
|
12265
|
-
</xsl:template><xsl:template xmlns:
|
12367
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='th']">
|
12266
12368
|
<fo:table-cell text-align="{@align}" font-weight="bold" border="solid black 1pt" padding-left="1mm" display-align="center">
|
12267
12369
|
|
12268
12370
|
|
@@ -12301,7 +12403,7 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12301
12403
|
<xsl:apply-templates/>
|
12302
12404
|
</fo:block>
|
12303
12405
|
</fo:table-cell>
|
12304
|
-
</xsl:template><xsl:template xmlns:
|
12406
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='td']">
|
12305
12407
|
<fo:table-cell text-align="{@align}" display-align="center" border="solid black 1pt" padding-left="1mm">
|
12306
12408
|
|
12307
12409
|
|
@@ -12328,6 +12430,7 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12328
12430
|
</xsl:attribute>
|
12329
12431
|
</xsl:if>
|
12330
12432
|
<fo:block>
|
12433
|
+
|
12331
12434
|
<xsl:apply-templates/>
|
12332
12435
|
</fo:block>
|
12333
12436
|
<!-- <xsl:choose>
|
@@ -12343,16 +12446,18 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12343
12446
|
|
12344
12447
|
|
12345
12448
|
</fo:table-cell>
|
12346
|
-
</xsl:template><xsl:template xmlns:
|
12449
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='table']/*[local-name()='note']"/><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='table']/*[local-name()='note']" mode="process">
|
12347
12450
|
|
12348
12451
|
|
12349
12452
|
<fo:block font-size="10pt" margin-bottom="12pt">
|
12350
12453
|
|
12351
12454
|
|
12352
12455
|
|
12456
|
+
|
12353
12457
|
<fo:inline padding-right="2mm">
|
12354
12458
|
|
12355
|
-
|
12459
|
+
|
12460
|
+
<xsl:value-of select="$title-note"/>
|
12356
12461
|
|
12357
12462
|
|
12358
12463
|
|
@@ -12362,9 +12467,9 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12362
12467
|
<xsl:apply-templates mode="process"/>
|
12363
12468
|
</fo:block>
|
12364
12469
|
|
12365
|
-
</xsl:template><xsl:template xmlns:
|
12470
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='table']/*[local-name()='note']/*[local-name()='p']" mode="process">
|
12366
12471
|
<xsl:apply-templates/>
|
12367
|
-
</xsl:template><xsl:template xmlns:
|
12472
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="fn_display">
|
12368
12473
|
<xsl:variable name="references">
|
12369
12474
|
<xsl:for-each select="..//*[local-name()='fn'][local-name(..) != 'name']">
|
12370
12475
|
<fn reference="{@reference}" id="{@reference}_{ancestor::*[@id][1]/@id}">
|
@@ -12381,6 +12486,7 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12381
12486
|
|
12382
12487
|
|
12383
12488
|
|
12489
|
+
|
12384
12490
|
<fo:inline font-size="80%" padding-right="5mm" id="{@id}">
|
12385
12491
|
|
12386
12492
|
<xsl:attribute name="vertical-align">super</xsl:attribute>
|
@@ -12400,7 +12506,7 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12400
12506
|
</fo:block>
|
12401
12507
|
</xsl:if>
|
12402
12508
|
</xsl:for-each>
|
12403
|
-
</xsl:template><xsl:template xmlns:
|
12509
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="fn_name_display">
|
12404
12510
|
<!-- <xsl:variable name="references">
|
12405
12511
|
<xsl:for-each select="*[local-name()='name']//*[local-name()='fn']">
|
12406
12512
|
<fn reference="{@reference}" id="{@reference}_{ancestor::*[@id][1]/@id}">
|
@@ -12416,7 +12522,7 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12416
12522
|
<xsl:apply-templates/>
|
12417
12523
|
</fo:block>
|
12418
12524
|
</xsl:for-each>
|
12419
|
-
</xsl:template><xsl:template xmlns:
|
12525
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="fn_display_figure">
|
12420
12526
|
<xsl:variable name="key_iso">
|
12421
12527
|
<!-- and (not(@class) or @class !='pseudocode') -->
|
12422
12528
|
</xsl:variable>
|
@@ -12467,7 +12573,7 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12467
12573
|
</fo:block>
|
12468
12574
|
</xsl:if>
|
12469
12575
|
|
12470
|
-
</xsl:template><xsl:template xmlns:
|
12576
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='fn']">
|
12471
12577
|
<!-- <xsl:variable name="namespace" select="substring-before(name(/*), '-')"/> -->
|
12472
12578
|
<fo:inline font-size="80%" keep-with-previous.within-line="always">
|
12473
12579
|
|
@@ -12479,11 +12585,11 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12479
12585
|
<xsl:value-of select="@reference"/>
|
12480
12586
|
</fo:basic-link>
|
12481
12587
|
</fo:inline>
|
12482
|
-
</xsl:template><xsl:template xmlns:
|
12588
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='fn']/*[local-name()='p']">
|
12483
12589
|
<fo:inline>
|
12484
12590
|
<xsl:apply-templates/>
|
12485
12591
|
</fo:inline>
|
12486
|
-
</xsl:template><xsl:template xmlns:
|
12592
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='dl']">
|
12487
12593
|
<xsl:variable name="parent" select="local-name(..)"/>
|
12488
12594
|
|
12489
12595
|
<xsl:variable name="key_iso">
|
@@ -12495,8 +12601,8 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12495
12601
|
|
12496
12602
|
|
12497
12603
|
<fo:block margin-bottom="12pt" text-align="left">
|
12498
|
-
|
12499
|
-
<xsl:text>
|
12604
|
+
|
12605
|
+
<xsl:value-of select="$title-where"/><xsl:text> </xsl:text>
|
12500
12606
|
<xsl:apply-templates select="*[local-name()='dt']/*"/>
|
12501
12607
|
<xsl:text/>
|
12502
12608
|
<xsl:apply-templates select="*[local-name()='dd']/*" mode="inline"/>
|
@@ -12509,7 +12615,7 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12509
12615
|
|
12510
12616
|
|
12511
12617
|
|
12512
|
-
<xsl:
|
12618
|
+
<xsl:value-of select="$title-where"/>
|
12513
12619
|
</fo:block>
|
12514
12620
|
</xsl:when>
|
12515
12621
|
<xsl:when test="$parent = 'figure' and (not(../@class) or ../@class !='pseudocode')">
|
@@ -12517,7 +12623,7 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12517
12623
|
|
12518
12624
|
|
12519
12625
|
|
12520
|
-
<xsl:
|
12626
|
+
<xsl:value-of select="$title-key"/>
|
12521
12627
|
</fo:block>
|
12522
12628
|
</xsl:when>
|
12523
12629
|
</xsl:choose>
|
@@ -12528,9 +12634,11 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12528
12634
|
|
12529
12635
|
|
12530
12636
|
|
12637
|
+
|
12531
12638
|
<fo:block>
|
12532
12639
|
|
12533
12640
|
|
12641
|
+
|
12534
12642
|
<!-- create virtual html table for dl/[dt and dd] -->
|
12535
12643
|
<xsl:variable name="html-table">
|
12536
12644
|
<xsl:variable name="ns" select="substring-before(name(/*), '-')"/>
|
@@ -12582,7 +12690,7 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12582
12690
|
<xsl:otherwise>
|
12583
12691
|
<xsl:for-each select="xalan:nodeset($colwidths)//column">
|
12584
12692
|
<xsl:choose>
|
12585
|
-
<xsl:when test=". = 1">
|
12693
|
+
<xsl:when test=". = 1 or . = 0">
|
12586
12694
|
<fo:table-column column-width="proportional-column-width(2)"/>
|
12587
12695
|
</xsl:when>
|
12588
12696
|
<xsl:otherwise>
|
@@ -12605,7 +12713,7 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12605
12713
|
</fo:block>
|
12606
12714
|
</fo:block>
|
12607
12715
|
</xsl:if>
|
12608
|
-
</xsl:template><xsl:template xmlns:
|
12716
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='dl']/*[local-name()='note']">
|
12609
12717
|
<xsl:param name="key_iso"/>
|
12610
12718
|
|
12611
12719
|
<!-- <tr>
|
@@ -12621,7 +12729,7 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12621
12729
|
<xsl:if test="normalize-space($key_iso) = 'true'">
|
12622
12730
|
<xsl:attribute name="margin-top">0</xsl:attribute>
|
12623
12731
|
</xsl:if>
|
12624
|
-
|
12732
|
+
<xsl:value-of select="$title-note"/>
|
12625
12733
|
</fo:block>
|
12626
12734
|
</fo:table-cell>
|
12627
12735
|
<fo:table-cell>
|
@@ -12630,7 +12738,7 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12630
12738
|
</fo:block>
|
12631
12739
|
</fo:table-cell>
|
12632
12740
|
</fo:table-row>
|
12633
|
-
</xsl:template><xsl:template xmlns:
|
12741
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='dt']" mode="dl">
|
12634
12742
|
<tr>
|
12635
12743
|
<td>
|
12636
12744
|
<xsl:apply-templates/>
|
@@ -12643,11 +12751,12 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12643
12751
|
</td>
|
12644
12752
|
</tr>
|
12645
12753
|
|
12646
|
-
</xsl:template><xsl:template xmlns:
|
12754
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='dt']">
|
12647
12755
|
<xsl:param name="key_iso"/>
|
12648
12756
|
|
12649
12757
|
<fo:table-row>
|
12650
12758
|
<fo:table-cell>
|
12759
|
+
|
12651
12760
|
<fo:block margin-top="6pt">
|
12652
12761
|
|
12653
12762
|
|
@@ -12657,6 +12766,9 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12657
12766
|
</xsl:if>
|
12658
12767
|
|
12659
12768
|
|
12769
|
+
|
12770
|
+
|
12771
|
+
|
12660
12772
|
<xsl:apply-templates/>
|
12661
12773
|
|
12662
12774
|
</fo:block>
|
@@ -12672,37 +12784,37 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12672
12784
|
</fo:table-cell>
|
12673
12785
|
</fo:table-row>
|
12674
12786
|
|
12675
|
-
</xsl:template><xsl:template xmlns:
|
12787
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='dd']" mode="dl"/><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='dd']" mode="dl_process">
|
12676
12788
|
<xsl:apply-templates/>
|
12677
|
-
</xsl:template><xsl:template xmlns:
|
12789
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='dd']"/><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='dd']" mode="process">
|
12678
12790
|
<xsl:apply-templates/>
|
12679
|
-
</xsl:template><xsl:template xmlns:
|
12791
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='dd']/*[local-name()='p']" mode="inline">
|
12680
12792
|
<fo:inline><xsl:text> </xsl:text><xsl:apply-templates/></fo:inline>
|
12681
|
-
</xsl:template><xsl:template xmlns:
|
12793
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='em']">
|
12682
12794
|
<fo:inline font-style="italic">
|
12683
12795
|
<xsl:apply-templates/>
|
12684
12796
|
</fo:inline>
|
12685
|
-
</xsl:template><xsl:template xmlns:
|
12797
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='strong']">
|
12686
12798
|
<fo:inline font-weight="bold">
|
12687
12799
|
<xsl:apply-templates/>
|
12688
12800
|
</fo:inline>
|
12689
|
-
</xsl:template><xsl:template xmlns:
|
12801
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='sup']">
|
12690
12802
|
<fo:inline font-size="80%" vertical-align="super">
|
12691
12803
|
<xsl:apply-templates/>
|
12692
12804
|
</fo:inline>
|
12693
|
-
</xsl:template><xsl:template xmlns:
|
12805
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='sub']">
|
12694
12806
|
<fo:inline font-size="80%" vertical-align="sub">
|
12695
12807
|
<xsl:apply-templates/>
|
12696
12808
|
</fo:inline>
|
12697
|
-
</xsl:template><xsl:template xmlns:
|
12698
|
-
<fo:inline font-family="Courier" font-size="10pt">
|
12809
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='tt']">
|
12810
|
+
<fo:inline font-family="Courier" font-size="10pt">
|
12699
12811
|
<xsl:apply-templates/>
|
12700
12812
|
</fo:inline>
|
12701
|
-
</xsl:template><xsl:template xmlns:
|
12813
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='del']">
|
12702
12814
|
<fo:inline font-size="10pt" color="red" text-decoration="line-through">
|
12703
12815
|
<xsl:apply-templates/>
|
12704
12816
|
</fo:inline>
|
12705
|
-
</xsl:template><xsl:template xmlns:
|
12817
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="text()[ancestor::*[local-name()='smallcap']]">
|
12706
12818
|
<xsl:variable name="text" select="normalize-space(.)"/>
|
12707
12819
|
<fo:inline font-size="75%">
|
12708
12820
|
<xsl:if test="string-length($text) > 0">
|
@@ -12711,7 +12823,7 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12711
12823
|
</xsl:call-template>
|
12712
12824
|
</xsl:if>
|
12713
12825
|
</fo:inline>
|
12714
|
-
</xsl:template><xsl:template xmlns:
|
12826
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="recursiveSmallCaps">
|
12715
12827
|
<xsl:param name="text"/>
|
12716
12828
|
<xsl:variable name="char" select="substring($text,1,1)"/>
|
12717
12829
|
<xsl:variable name="upperCase" select="translate($char, $lower, $upper)"/>
|
@@ -12730,7 +12842,7 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12730
12842
|
<xsl:with-param name="text" select="substring($text,2)"/>
|
12731
12843
|
</xsl:call-template>
|
12732
12844
|
</xsl:if>
|
12733
|
-
</xsl:template><xsl:template xmlns:
|
12845
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="tokenize">
|
12734
12846
|
<xsl:param name="text"/>
|
12735
12847
|
<xsl:param name="separator" select="' '"/>
|
12736
12848
|
<xsl:choose>
|
@@ -12778,7 +12890,7 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12778
12890
|
</xsl:call-template>
|
12779
12891
|
</xsl:otherwise>
|
12780
12892
|
</xsl:choose>
|
12781
|
-
</xsl:template><xsl:template xmlns:
|
12893
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="max_length">
|
12782
12894
|
<xsl:param name="words"/>
|
12783
12895
|
<xsl:for-each select="$words//word">
|
12784
12896
|
<xsl:sort select="." data-type="number" order="descending"/>
|
@@ -12786,7 +12898,11 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12786
12898
|
<xsl:value-of select="."/>
|
12787
12899
|
</xsl:if>
|
12788
12900
|
</xsl:for-each>
|
12789
|
-
</xsl:template><xsl:template xmlns:
|
12901
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="add-zero-spaces-java">
|
12902
|
+
<xsl:param name="text" select="."/>
|
12903
|
+
<!-- add zero-width space (#x200B) after characters: dash, dot, colon, equal, underscore, em dash, thin space -->
|
12904
|
+
<xsl:value-of select="java:replaceAll(java:java.lang.String.new($text),'(-|\.|:|=|_|—| )','$1')"/>
|
12905
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="add-zero-spaces">
|
12790
12906
|
<xsl:param name="text" select="."/>
|
12791
12907
|
<xsl:variable name="zero-space-after-chars">-</xsl:variable>
|
12792
12908
|
<xsl:variable name="zero-space-after-dot">.</xsl:variable>
|
@@ -12839,7 +12955,7 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12839
12955
|
<xsl:value-of select="$text"/>
|
12840
12956
|
</xsl:otherwise>
|
12841
12957
|
</xsl:choose>
|
12842
|
-
</xsl:template><xsl:template xmlns:
|
12958
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="add-zero-spaces-equal">
|
12843
12959
|
<xsl:param name="text" select="."/>
|
12844
12960
|
<xsl:variable name="zero-space-after-equals">==========</xsl:variable>
|
12845
12961
|
<xsl:variable name="zero-space-after-equal">=</xsl:variable>
|
@@ -12865,7 +12981,7 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12865
12981
|
<xsl:value-of select="$text"/>
|
12866
12982
|
</xsl:otherwise>
|
12867
12983
|
</xsl:choose>
|
12868
|
-
</xsl:template><xsl:template xmlns:
|
12984
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="getSimpleTable">
|
12869
12985
|
<xsl:variable name="simple-table">
|
12870
12986
|
|
12871
12987
|
<!-- Step 1. colspan processing -->
|
@@ -12892,9 +13008,9 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12892
13008
|
</xsl:choose> -->
|
12893
13009
|
</xsl:variable>
|
12894
13010
|
<xsl:copy-of select="$simple-table"/>
|
12895
|
-
</xsl:template><xsl:template xmlns:
|
13011
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='thead'] | *[local-name()='tbody']" mode="simple-table-colspan">
|
12896
13012
|
<xsl:apply-templates mode="simple-table-colspan"/>
|
12897
|
-
</xsl:template><xsl:template xmlns:
|
13013
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='fn']" mode="simple-table-colspan"/><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='th'] | *[local-name()='td']" mode="simple-table-colspan">
|
12898
13014
|
<xsl:choose>
|
12899
13015
|
<xsl:when test="@colspan">
|
12900
13016
|
<xsl:variable name="td">
|
@@ -12916,16 +13032,16 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12916
13032
|
</xsl:element>
|
12917
13033
|
</xsl:otherwise>
|
12918
13034
|
</xsl:choose>
|
12919
|
-
</xsl:template><xsl:template xmlns:
|
13035
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="@colspan" mode="simple-table-colspan"/><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='tr']" mode="simple-table-colspan">
|
12920
13036
|
<xsl:element name="tr">
|
12921
13037
|
<xsl:apply-templates select="@*" mode="simple-table-colspan"/>
|
12922
13038
|
<xsl:apply-templates mode="simple-table-colspan"/>
|
12923
13039
|
</xsl:element>
|
12924
|
-
</xsl:template><xsl:template xmlns:
|
13040
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="@*|node()" mode="simple-table-colspan">
|
12925
13041
|
<xsl:copy>
|
12926
13042
|
<xsl:apply-templates select="@*|node()" mode="simple-table-colspan"/>
|
12927
13043
|
</xsl:copy>
|
12928
|
-
</xsl:template><xsl:template xmlns:
|
13044
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="repeatNode">
|
12929
13045
|
<xsl:param name="count"/>
|
12930
13046
|
<xsl:param name="node"/>
|
12931
13047
|
|
@@ -12936,18 +13052,18 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12936
13052
|
</xsl:call-template>
|
12937
13053
|
<xsl:copy-of select="$node"/>
|
12938
13054
|
</xsl:if>
|
12939
|
-
</xsl:template><xsl:template xmlns:
|
13055
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="@*|node()" mode="simple-table-rowspan">
|
12940
13056
|
<xsl:copy>
|
12941
13057
|
<xsl:apply-templates select="@*|node()" mode="simple-table-rowspan"/>
|
12942
13058
|
</xsl:copy>
|
12943
|
-
</xsl:template><xsl:template xmlns:
|
13059
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="tbody" mode="simple-table-rowspan">
|
12944
13060
|
<xsl:copy>
|
12945
13061
|
<xsl:copy-of select="tr[1]"/>
|
12946
13062
|
<xsl:apply-templates select="tr[2]" mode="simple-table-rowspan">
|
12947
13063
|
<xsl:with-param name="previousRow" select="tr[1]"/>
|
12948
13064
|
</xsl:apply-templates>
|
12949
13065
|
</xsl:copy>
|
12950
|
-
</xsl:template><xsl:template xmlns:
|
13066
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="tr" mode="simple-table-rowspan">
|
12951
13067
|
<xsl:param name="previousRow"/>
|
12952
13068
|
<xsl:variable name="currentRow" select="."/>
|
12953
13069
|
|
@@ -12981,13 +13097,13 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
12981
13097
|
<xsl:apply-templates select="following-sibling::tr[1]" mode="simple-table-rowspan">
|
12982
13098
|
<xsl:with-param name="previousRow" select="$newRow"/>
|
12983
13099
|
</xsl:apply-templates>
|
12984
|
-
</xsl:template><xsl:template xmlns:
|
13100
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="getLang">
|
12985
13101
|
<xsl:variable name="language" select="//*[local-name()='bibdata']//*[local-name()='language']"/>
|
12986
13102
|
<xsl:choose>
|
12987
13103
|
<xsl:when test="$language = 'English'">en</xsl:when>
|
12988
13104
|
<xsl:otherwise><xsl:value-of select="$language"/></xsl:otherwise>
|
12989
13105
|
</xsl:choose>
|
12990
|
-
</xsl:template><xsl:template xmlns:
|
13106
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="capitalizeWords">
|
12991
13107
|
<xsl:param name="str"/>
|
12992
13108
|
<xsl:variable name="str2" select="translate($str, '-', ' ')"/>
|
12993
13109
|
<xsl:choose>
|
@@ -13005,19 +13121,19 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
13005
13121
|
<xsl:value-of select="substring($str2, 2)"/>
|
13006
13122
|
</xsl:otherwise>
|
13007
13123
|
</xsl:choose>
|
13008
|
-
</xsl:template><xsl:template xmlns:
|
13124
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="mathml:math">
|
13009
13125
|
<fo:inline font-family="STIX2Math">
|
13010
13126
|
<fo:instream-foreign-object fox:alt-text="Math">
|
13011
13127
|
<xsl:copy-of select="."/>
|
13012
13128
|
</fo:instream-foreign-object>
|
13013
13129
|
</fo:inline>
|
13014
|
-
</xsl:template><xsl:template xmlns:
|
13130
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='localityStack']">
|
13015
13131
|
<xsl:for-each select="*[local-name()='locality']">
|
13016
13132
|
<xsl:if test="position() =1"><xsl:text>, </xsl:text></xsl:if>
|
13017
13133
|
<xsl:apply-templates select="."/>
|
13018
13134
|
<xsl:if test="position() != last()"><xsl:text>; </xsl:text></xsl:if>
|
13019
13135
|
</xsl:for-each>
|
13020
|
-
</xsl:template><xsl:template xmlns:
|
13136
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='link']" name="link">
|
13021
13137
|
<xsl:variable name="target">
|
13022
13138
|
<xsl:choose>
|
13023
13139
|
<xsl:when test="starts-with(normalize-space(@target), 'mailto:')">
|
@@ -13047,4 +13163,122 @@ w+FwgnQ4HA4nSIfD4XCCdDgcDidIh8Ph6HT8T4ABAB91/nepRFURAAAAAElFTkSuQmCC
|
|
13047
13163
|
</xsl:otherwise>
|
13048
13164
|
</xsl:choose>
|
13049
13165
|
</fo:inline>
|
13166
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='sourcecode']" name="sourcecode">
|
13167
|
+
<fo:block xsl:use-attribute-sets="sourcecode-style">
|
13168
|
+
<!-- <xsl:choose>
|
13169
|
+
<xsl:when test="@lang = 'en'"></xsl:when>
|
13170
|
+
<xsl:otherwise> -->
|
13171
|
+
<xsl:attribute name="white-space">pre</xsl:attribute>
|
13172
|
+
<xsl:attribute name="wrap-option">wrap</xsl:attribute>
|
13173
|
+
<!-- </xsl:otherwise>
|
13174
|
+
</xsl:choose> -->
|
13175
|
+
<xsl:apply-templates/>
|
13176
|
+
</fo:block>
|
13177
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='bookmark']">
|
13178
|
+
<fo:inline id="{@id}"/>
|
13179
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='appendix']">
|
13180
|
+
<fo:block id="{@id}" xsl:use-attribute-sets="appendix-style">
|
13181
|
+
<fo:inline padding-right="5mm"><xsl:value-of select="$title-appendix"/> <xsl:number/></fo:inline>
|
13182
|
+
<xsl:apply-templates select="*[local-name()='title']" mode="process"/>
|
13183
|
+
</fo:block>
|
13184
|
+
<xsl:apply-templates/>
|
13185
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='appendix']/*[local-name()='title']"/><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='appendix']/*[local-name()='title']" mode="process">
|
13186
|
+
<fo:inline><xsl:apply-templates/></fo:inline>
|
13187
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='appendix']//*[local-name()='example']">
|
13188
|
+
<fo:block xsl:use-attribute-sets="appendix-example-style">
|
13189
|
+
<xsl:variable name="claims_id" select="ancestor::*[local-name()='clause'][1]/@id"/>
|
13190
|
+
<xsl:value-of select="$title-example"/>
|
13191
|
+
<xsl:if test="count(ancestor::*[local-name()='clause'][1]//*[local-name()='example']) > 1">
|
13192
|
+
<xsl:number count="*[local-name()='example'][ancestor::*[local-name()='clause'][@id = $claims_id]]" level="any"/><xsl:text> </xsl:text>
|
13193
|
+
</xsl:if>
|
13194
|
+
<xsl:if test="*[local-name()='name']">
|
13195
|
+
<xsl:text>— </xsl:text><xsl:apply-templates select="*[local-name()='name']" mode="process"/>
|
13196
|
+
</xsl:if>
|
13197
|
+
</fo:block>
|
13198
|
+
<xsl:apply-templates/>
|
13199
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='appendix']//*[local-name()='example']/*[local-name()='name']"/><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='appendix']//*[local-name()='example']/*[local-name()='name']" mode="process">
|
13200
|
+
<fo:inline><xsl:apply-templates/></fo:inline>
|
13201
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name() = 'callout']">
|
13202
|
+
<fo:basic-link internal-destination="{@target}" fox:alt-text="{@target}"><<xsl:apply-templates/>></fo:basic-link>
|
13203
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name() = 'annotation']">
|
13204
|
+
<xsl:variable name="annotation-id" select="@id"/>
|
13205
|
+
<xsl:variable name="callout" select="//*[@target = $annotation-id]/text()"/>
|
13206
|
+
<fo:block id="{$annotation-id}" white-space="nowrap">
|
13207
|
+
<fo:inline>
|
13208
|
+
<xsl:apply-templates>
|
13209
|
+
<xsl:with-param name="callout" select="concat('<', $callout, '> ')"/>
|
13210
|
+
</xsl:apply-templates>
|
13211
|
+
</fo:inline>
|
13212
|
+
</fo:block>
|
13213
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name() = 'annotation']/*[local-name() = 'p']">
|
13214
|
+
<xsl:param name="callout"/>
|
13215
|
+
<fo:inline id="{@id}">
|
13216
|
+
<!-- for first p in annotation, put <x> -->
|
13217
|
+
<xsl:if test="not(preceding-sibling::*[local-name() = 'p'])"><xsl:value-of select="$callout"/></xsl:if>
|
13218
|
+
<xsl:apply-templates/>
|
13219
|
+
</fo:inline>
|
13220
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="convertDate">
|
13221
|
+
<xsl:param name="date"/>
|
13222
|
+
<xsl:param name="format" select="'short'"/>
|
13223
|
+
<xsl:variable name="year" select="substring($date, 1, 4)"/>
|
13224
|
+
<xsl:variable name="month" select="substring($date, 6, 2)"/>
|
13225
|
+
<xsl:variable name="day" select="substring($date, 9, 2)"/>
|
13226
|
+
<xsl:variable name="monthStr">
|
13227
|
+
<xsl:choose>
|
13228
|
+
<xsl:when test="$month = '01'">January</xsl:when>
|
13229
|
+
<xsl:when test="$month = '02'">February</xsl:when>
|
13230
|
+
<xsl:when test="$month = '03'">March</xsl:when>
|
13231
|
+
<xsl:when test="$month = '04'">April</xsl:when>
|
13232
|
+
<xsl:when test="$month = '05'">May</xsl:when>
|
13233
|
+
<xsl:when test="$month = '06'">June</xsl:when>
|
13234
|
+
<xsl:when test="$month = '07'">July</xsl:when>
|
13235
|
+
<xsl:when test="$month = '08'">August</xsl:when>
|
13236
|
+
<xsl:when test="$month = '09'">September</xsl:when>
|
13237
|
+
<xsl:when test="$month = '10'">October</xsl:when>
|
13238
|
+
<xsl:when test="$month = '11'">November</xsl:when>
|
13239
|
+
<xsl:when test="$month = '12'">December</xsl:when>
|
13240
|
+
</xsl:choose>
|
13241
|
+
</xsl:variable>
|
13242
|
+
<xsl:variable name="result">
|
13243
|
+
<xsl:choose>
|
13244
|
+
<xsl:when test="$format = 'short' or $day = ''">
|
13245
|
+
<xsl:value-of select="normalize-space(concat($monthStr, ' ', $year))"/>
|
13246
|
+
</xsl:when>
|
13247
|
+
<xsl:otherwise>
|
13248
|
+
<xsl:value-of select="normalize-space(concat($monthStr, ' ', $day, ', ' , $year))"/>
|
13249
|
+
</xsl:otherwise>
|
13250
|
+
</xsl:choose>
|
13251
|
+
</xsl:variable>
|
13252
|
+
<xsl:value-of select="$result"/>
|
13253
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="insertKeywords">
|
13254
|
+
<xsl:param name="sorting" select="'true'"/>
|
13255
|
+
<xsl:param name="charAtEnd" select="'.'"/>
|
13256
|
+
<xsl:param name="charDelim" select="', '"/>
|
13257
|
+
<xsl:choose>
|
13258
|
+
<xsl:when test="$sorting = 'true' or $sorting = 'yes'">
|
13259
|
+
<xsl:for-each select="/*/*[local-name() = 'bibdata']//*[local-name() = 'keyword']">
|
13260
|
+
<xsl:sort data-type="text" order="ascending"/>
|
13261
|
+
<xsl:call-template name="insertKeyword">
|
13262
|
+
<xsl:with-param name="charAtEnd" select="$charAtEnd"/>
|
13263
|
+
<xsl:with-param name="charDelim" select="$charDelim"/>
|
13264
|
+
</xsl:call-template>
|
13265
|
+
</xsl:for-each>
|
13266
|
+
</xsl:when>
|
13267
|
+
<xsl:otherwise>
|
13268
|
+
<xsl:for-each select="/*/*[local-name() = 'bibdata']//*[local-name() = 'keyword']">
|
13269
|
+
<xsl:call-template name="insertKeyword">
|
13270
|
+
<xsl:with-param name="charAtEnd" select="$charAtEnd"/>
|
13271
|
+
<xsl:with-param name="charDelim" select="$charDelim"/>
|
13272
|
+
</xsl:call-template>
|
13273
|
+
</xsl:for-each>
|
13274
|
+
</xsl:otherwise>
|
13275
|
+
</xsl:choose>
|
13276
|
+
</xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="insertKeyword">
|
13277
|
+
<xsl:param name="charAtEnd"/>
|
13278
|
+
<xsl:param name="charDelim"/>
|
13279
|
+
<xsl:apply-templates/>
|
13280
|
+
<xsl:choose>
|
13281
|
+
<xsl:when test="position() != last()"><xsl:value-of select="$charDelim"/></xsl:when>
|
13282
|
+
<xsl:otherwise><xsl:value-of select="$charAtEnd"/></xsl:otherwise>
|
13283
|
+
</xsl:choose>
|
13050
13284
|
</xsl:template></xsl:stylesheet>
|