metanorma-ogc 1.0.5 → 1.0.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/asciidoctor/ogc/converter.rb +1 -8
- data/lib/asciidoctor/ogc/isodoc.rng +6 -3
- data/lib/isodoc/ogc/html_convert.rb +3 -3
- data/lib/isodoc/ogc/ogc.abstract-specification-topic.xsl +3225 -0
- data/lib/isodoc/ogc/ogc.best-practice.xsl +3225 -0
- data/lib/isodoc/ogc/ogc.change-request-supporting-document.xsl +3225 -0
- data/lib/isodoc/ogc/ogc.community-practice.xsl +3225 -0
- data/lib/isodoc/ogc/ogc.community-standard.xsl +174 -89
- data/lib/isodoc/ogc/ogc.discussion-paper.xsl +3225 -0
- data/lib/isodoc/ogc/ogc.engineering-report.xsl +174 -89
- data/lib/isodoc/ogc/ogc.other.xsl +174 -89
- data/lib/isodoc/ogc/ogc.policy.xsl +174 -89
- data/lib/isodoc/ogc/ogc.reference-model.xsl +174 -89
- data/lib/isodoc/ogc/ogc.release-notes.xsl +174 -89
- data/lib/isodoc/ogc/ogc.standard.xsl +174 -89
- data/lib/isodoc/ogc/ogc.test-suite.xsl +174 -89
- data/lib/isodoc/ogc/ogc.user-guide.xsl +174 -89
- data/lib/isodoc/ogc/ogc.white-paper.xsl +3225 -0
- data/lib/isodoc/ogc/pdf_convert.rb +10 -6
- data/lib/metanorma/ogc/processor.rb +2 -2
- data/lib/metanorma/ogc/version.rb +1 -1
- metadata +8 -2
@@ -6,6 +6,8 @@
|
|
6
6
|
<xsl:variable name="pageHeight" select="'297mm'"/>
|
7
7
|
|
8
8
|
|
9
|
+
|
10
|
+
<xsl:variable name="debug">false</xsl:variable>
|
9
11
|
|
10
12
|
<xsl:variable name="copyright">
|
11
13
|
<xsl:text>© Open Geospatial Consortium </xsl:text>
|
@@ -338,10 +340,13 @@
|
|
338
340
|
</fo:static-content>
|
339
341
|
<xsl:call-template name="insertHeaderFooter"/>
|
340
342
|
<fo:flow flow-name="xsl-region-body">
|
341
|
-
|
342
|
-
|
343
|
-
|
344
|
-
|
343
|
+
|
344
|
+
<xsl:if test="$debug = 'true'">
|
345
|
+
<xsl:text disable-output-escaping="yes"><!--</xsl:text>
|
346
|
+
DEBUG
|
347
|
+
contents=<!-- <xsl:copy-of select="xalan:nodeset($contents)"/> -->
|
348
|
+
<xsl:text disable-output-escaping="yes">--></xsl:text>
|
349
|
+
</xsl:if>
|
345
350
|
|
346
351
|
<xsl:apply-templates select="/ogc:ogc-standard/ogc:boilerplate/ogc:license-statement"/>
|
347
352
|
<xsl:apply-templates select="/ogc:ogc-standard/ogc:boilerplate/ogc:feedback-statement"/>
|
@@ -1366,20 +1371,6 @@
|
|
1366
1371
|
</fo:list-item>
|
1367
1372
|
</xsl:template>
|
1368
1373
|
|
1369
|
-
<xsl:template match="ogc:link">
|
1370
|
-
<fo:inline>
|
1371
|
-
<fo:basic-link external-destination="{@target}" color="blue" text-decoration="underline" fox:alt-text="{@target}">
|
1372
|
-
<xsl:choose>
|
1373
|
-
<xsl:when test="normalize-space(.) = ''">
|
1374
|
-
<xsl:value-of select="@target"/>
|
1375
|
-
</xsl:when>
|
1376
|
-
<xsl:otherwise>
|
1377
|
-
<xsl:apply-templates/>
|
1378
|
-
</xsl:otherwise>
|
1379
|
-
</xsl:choose>
|
1380
|
-
</fo:basic-link>
|
1381
|
-
</fo:inline>
|
1382
|
-
</xsl:template>
|
1383
1374
|
|
1384
1375
|
<xsl:template match="ogc:preferred">
|
1385
1376
|
<xsl:param name="sectionNum"/>
|
@@ -1440,9 +1431,9 @@
|
|
1440
1431
|
<xsl:text>[SOURCE: </xsl:text>
|
1441
1432
|
<fo:inline color="blue" text-decoration="underline">
|
1442
1433
|
<xsl:value-of select="ogc:origin/@citeas"/>
|
1443
|
-
|
1444
|
-
|
1445
|
-
|
1434
|
+
|
1435
|
+
<xsl:apply-templates select="ogc:origin/ogc:localityStack"/>
|
1436
|
+
|
1446
1437
|
</fo:inline>
|
1447
1438
|
</fo:basic-link>
|
1448
1439
|
<xsl:apply-templates select="ogc:modification"/>
|
@@ -1608,10 +1599,7 @@
|
|
1608
1599
|
<xsl:template match="ogc:source">
|
1609
1600
|
<fo:basic-link internal-destination="{@bibitemid}" fox:alt-text="{@citeas}">
|
1610
1601
|
<xsl:value-of select="@citeas" disable-output-escaping="yes"/>
|
1611
|
-
<xsl:
|
1612
|
-
<xsl:text>, </xsl:text>
|
1613
|
-
<xsl:apply-templates select="ogc:locality"/>
|
1614
|
-
</xsl:if>
|
1602
|
+
<xsl:apply-templates select="ogc:localityStack"/>
|
1615
1603
|
</fo:basic-link>
|
1616
1604
|
</xsl:template>
|
1617
1605
|
|
@@ -1820,15 +1808,7 @@
|
|
1820
1808
|
</xsl:when>
|
1821
1809
|
<xsl:otherwise/>
|
1822
1810
|
</xsl:choose>
|
1823
|
-
<xsl:
|
1824
|
-
<xsl:text>, </xsl:text>
|
1825
|
-
<!-- <xsl:choose>
|
1826
|
-
<xsl:when test="ogc:locality/@type = 'section'">Section </xsl:when>
|
1827
|
-
<xsl:when test="ogc:locality/@type = 'clause'">Clause </xsl:when>
|
1828
|
-
<xsl:otherwise></xsl:otherwise>
|
1829
|
-
</xsl:choose> -->
|
1830
|
-
<xsl:apply-templates select="ogc:locality"/>
|
1831
|
-
</xsl:if>
|
1811
|
+
<xsl:apply-templates select="ogc:localityStack"/>
|
1832
1812
|
<xsl:apply-templates select="text()"/>
|
1833
1813
|
</fo:basic-link>
|
1834
1814
|
</xsl:template>
|
@@ -2086,11 +2066,17 @@
|
|
2086
2066
|
<xsl:value-of select="$section"/>
|
2087
2067
|
</xsl:template>
|
2088
2068
|
|
2089
|
-
<xsl:variable xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" name="lower">abcdefghijklmnopqrstuvwxyz</xsl:variable><xsl:variable xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" name="upper">ABCDEFGHIJKLMNOPQRSTUVWXYZ</xsl:variable><xsl:variable xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" name="en_chars" select="concat($lower,$upper,',.`1234567890-=~!@#$%^*()_+[]{}\|?/')"/><xsl:variable xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" name="linebreak" select="'
'"/><xsl:
|
2069
|
+
<xsl:variable xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" name="lower">abcdefghijklmnopqrstuvwxyz</xsl:variable><xsl:variable xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" name="upper">ABCDEFGHIJKLMNOPQRSTUVWXYZ</xsl:variable><xsl:variable xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" name="en_chars" select="concat($lower,$upper,',.`1234567890-=~!@#$%^*()_+[]{}\|?/')"/><xsl:variable xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" name="linebreak" select="'
'"/><xsl:attribute-set xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" name="link-style">
|
2070
|
+
|
2071
|
+
<xsl:attribute name="color">blue</xsl:attribute>
|
2072
|
+
<xsl:attribute name="text-decoration">underline</xsl:attribute>
|
2073
|
+
|
2074
|
+
|
2075
|
+
</xsl:attribute-set><xsl:template xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" match="text()">
|
2090
2076
|
<xsl:value-of select="."/>
|
2091
2077
|
</xsl:template><xsl:template xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" match="*[local-name()='br']">
|
2092
2078
|
<xsl:value-of select="$linebreak"/>
|
2093
|
-
</xsl:template><xsl:template xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" match="*[local-name()='td']//text() | *[local-name()='th']//text()" priority="1">
|
2079
|
+
</xsl:template><xsl:template xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" match="*[local-name()='td']//text() | *[local-name()='th']//text() | *[local-name()='dt']//text() | *[local-name()='dd']//text()" priority="1">
|
2094
2080
|
<xsl:call-template name="add-zero-spaces"/>
|
2095
2081
|
</xsl:template><xsl:template xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" match="*[local-name()='table']">
|
2096
2082
|
|
@@ -2106,7 +2092,9 @@
|
|
2106
2092
|
|
2107
2093
|
<!-- <xsl:variable name="namespace" select="substring-before(name(/*), '-')"/> -->
|
2108
2094
|
|
2109
|
-
|
2095
|
+
<!-- <xsl:if test="$namespace = 'iso'">
|
2096
|
+
<fo:block space-before="6pt"> </fo:block>
|
2097
|
+
</xsl:if> -->
|
2110
2098
|
|
2111
2099
|
<xsl:choose>
|
2112
2100
|
<xsl:when test="@unnumbered = 'true'"/>
|
@@ -2120,9 +2108,11 @@
|
|
2120
2108
|
|
2121
2109
|
|
2122
2110
|
|
2111
|
+
|
2123
2112
|
<xsl:attribute name="font-weight">normal</xsl:attribute>
|
2124
2113
|
<xsl:attribute name="font-size">11pt</xsl:attribute>
|
2125
2114
|
|
2115
|
+
|
2126
2116
|
<xsl:text>Table </xsl:text>
|
2127
2117
|
<xsl:choose>
|
2128
2118
|
<xsl:when test="ancestor::*[local-name()='executivesummary']"> <!-- NIST -->
|
@@ -2130,6 +2120,8 @@
|
|
2130
2120
|
</xsl:when>
|
2131
2121
|
<xsl:when test="ancestor::*[local-name()='annex']">
|
2132
2122
|
|
2123
|
+
|
2124
|
+
|
2133
2125
|
<xsl:number format="A." count="*[local-name()='annex']"/><xsl:number format="1"/>
|
2134
2126
|
|
2135
2127
|
|
@@ -2190,11 +2182,11 @@
|
|
2190
2182
|
</xsl:call-template>
|
2191
2183
|
</xsl:variable>
|
2192
2184
|
|
2193
|
-
<xsl:variable name="colwidths2">
|
2185
|
+
<!-- <xsl:variable name="colwidths2">
|
2194
2186
|
<xsl:call-template name="calculate-column-widths">
|
2195
2187
|
<xsl:with-param name="cols-count" select="$cols-count"/>
|
2196
2188
|
</xsl:call-template>
|
2197
|
-
</xsl:variable>
|
2189
|
+
</xsl:variable> -->
|
2198
2190
|
|
2199
2191
|
<!-- cols-count=<xsl:copy-of select="$cols-count"/>
|
2200
2192
|
colwidthsNew=<xsl:copy-of select="$colwidths"/>
|
@@ -2218,7 +2210,9 @@
|
|
2218
2210
|
<xsl:attribute name="margin-right">0mm</xsl:attribute>
|
2219
2211
|
<xsl:attribute name="space-after">12pt</xsl:attribute>
|
2220
2212
|
|
2221
|
-
|
2213
|
+
|
2214
|
+
<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">
|
2215
|
+
|
2222
2216
|
|
2223
2217
|
|
2224
2218
|
|
@@ -2245,6 +2239,9 @@
|
|
2245
2239
|
</xsl:for-each>
|
2246
2240
|
<xsl:apply-templates/>
|
2247
2241
|
</fo:table>
|
2242
|
+
|
2243
|
+
|
2244
|
+
|
2248
2245
|
</fo:block-container>
|
2249
2246
|
</xsl:template><xsl:template xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" match="*[local-name()='table']/*[local-name()='name']"/><xsl:template xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" match="*[local-name()='table']/*[local-name()='name']" mode="process">
|
2250
2247
|
<xsl:apply-templates/>
|
@@ -2298,9 +2295,13 @@
|
|
2298
2295
|
</xsl:when>
|
2299
2296
|
<xsl:otherwise>
|
2300
2297
|
<xsl:for-each select="xalan:nodeset($table)//tr">
|
2298
|
+
<xsl:variable name="td_text">
|
2299
|
+
<xsl:apply-templates select="td[$curr-col]" mode="td_text"/>
|
2300
|
+
</xsl:variable>
|
2301
2301
|
<xsl:variable name="words">
|
2302
2302
|
<xsl:call-template name="tokenize">
|
2303
|
-
<xsl:with-param name="text" select="translate(td[$curr-col],'- —:', ' ')"/>
|
2303
|
+
<!-- <xsl:with-param name="text" select="translate(td[$curr-col],'- —:', ' ')"/> -->
|
2304
|
+
<xsl:with-param name="text" select="translate(normalize-space($td_text),'- —:', ' ')"/>
|
2304
2305
|
</xsl:call-template>
|
2305
2306
|
</xsl:variable>
|
2306
2307
|
<xsl:variable name="max_length">
|
@@ -2341,58 +2342,82 @@
|
|
2341
2342
|
<xsl:with-param name="table" select="$table"/>
|
2342
2343
|
</xsl:call-template>
|
2343
2344
|
</xsl:if>
|
2345
|
+
</xsl:template><xsl:template xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" match="text()" mode="td_text">
|
2346
|
+
<xsl:variable name="zero-space"></xsl:variable>
|
2347
|
+
<xsl:value-of select="translate(., $zero-space, ' ')"/><xsl:text> </xsl:text>
|
2344
2348
|
</xsl:template><xsl:template xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" match="*[local-name()='table2']"/><xsl:template xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" match="*[local-name()='thead']"/><xsl:template xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" match="*[local-name()='thead']" mode="process">
|
2345
|
-
<!--
|
2346
|
-
|
2347
|
-
|
2348
|
-
|
2349
|
+
<!-- font-weight="bold" -->
|
2350
|
+
<fo:table-header>
|
2351
|
+
<xsl:apply-templates/>
|
2352
|
+
</fo:table-header>
|
2349
2353
|
</xsl:template><xsl:template xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" match="*[local-name()='tfoot']"/><xsl:template xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" match="*[local-name()='tfoot']" mode="process">
|
2350
2354
|
<xsl:apply-templates/>
|
2355
|
+
</xsl:template><xsl:template xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" name="insertTableFooter">
|
2356
|
+
<xsl:variable name="isNoteOrFnExist" select="../*[local-name()='note'] or ..//*[local-name()='fn'][local-name(..) != 'name']"/>
|
2357
|
+
<xsl:if test="../*[local-name()='tfoot'] or $isNoteOrFnExist = 'true'">
|
2358
|
+
|
2359
|
+
<fo:table-footer>
|
2360
|
+
|
2361
|
+
<xsl:apply-templates select="../*[local-name()='tfoot']" mode="process"/>
|
2362
|
+
|
2363
|
+
<!-- if there are note(s) or fn(s) then create footer row -->
|
2364
|
+
<xsl:if test="$isNoteOrFnExist = 'true'">
|
2365
|
+
|
2366
|
+
<xsl:variable name="cols-count">
|
2367
|
+
<xsl:choose>
|
2368
|
+
<xsl:when test="../*[local-name()='thead']">
|
2369
|
+
<!-- <xsl:value-of select="count(../*[local-name()='thead']/*[local-name()='tr']/*[local-name()='th'])"/> -->
|
2370
|
+
<xsl:call-template name="calculate-columns-numbers">
|
2371
|
+
<xsl:with-param name="table-row" select="../*[local-name()='thead']/*[local-name()='tr'][1]"/>
|
2372
|
+
</xsl:call-template>
|
2373
|
+
</xsl:when>
|
2374
|
+
<xsl:otherwise>
|
2375
|
+
<!-- <xsl:value-of select="count(./*[local-name()='tr'][1]/*[local-name()='td'])"/> -->
|
2376
|
+
<xsl:call-template name="calculate-columns-numbers">
|
2377
|
+
<xsl:with-param name="table-row" select="./*[local-name()='tr'][1]"/>
|
2378
|
+
</xsl:call-template>
|
2379
|
+
</xsl:otherwise>
|
2380
|
+
</xsl:choose>
|
2381
|
+
</xsl:variable>
|
2382
|
+
|
2383
|
+
<fo:table-row>
|
2384
|
+
<fo:table-cell border="solid black 1pt" padding-left="1mm" padding-right="1mm" padding-top="1mm" number-columns-spanned="{$cols-count}">
|
2385
|
+
|
2386
|
+
|
2387
|
+
|
2388
|
+
<!-- fn will be processed inside 'note' processing -->
|
2389
|
+
|
2390
|
+
|
2391
|
+
<!-- except gb -->
|
2392
|
+
|
2393
|
+
<xsl:apply-templates select="../*[local-name()='note']" mode="process"/>
|
2394
|
+
|
2395
|
+
|
2396
|
+
<!-- horizontal row separator -->
|
2397
|
+
|
2398
|
+
|
2399
|
+
<!-- fn processing -->
|
2400
|
+
<xsl:call-template name="fn_display"/>
|
2401
|
+
|
2402
|
+
</fo:table-cell>
|
2403
|
+
</fo:table-row>
|
2404
|
+
|
2405
|
+
</xsl:if>
|
2406
|
+
</fo:table-footer>
|
2407
|
+
|
2408
|
+
</xsl:if>
|
2351
2409
|
</xsl:template><xsl:template xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" match="*[local-name()='tbody']">
|
2352
|
-
|
2353
|
-
|
2354
|
-
|
2355
|
-
|
2356
|
-
|
2357
|
-
<xsl:with-param name="table-row" select="../*[local-name()='thead']/*[local-name()='tr'][1]"/>
|
2358
|
-
</xsl:call-template>
|
2359
|
-
</xsl:when>
|
2360
|
-
<xsl:otherwise>
|
2361
|
-
<!-- <xsl:value-of select="count(./*[local-name()='tr'][1]/*[local-name()='td'])"/> -->
|
2362
|
-
<xsl:call-template name="calculate-columns-numbers">
|
2363
|
-
<xsl:with-param name="table-row" select="./*[local-name()='tr'][1]"/>
|
2364
|
-
</xsl:call-template>
|
2365
|
-
</xsl:otherwise>
|
2366
|
-
</xsl:choose>
|
2367
|
-
</xsl:variable>
|
2368
|
-
|
2410
|
+
|
2411
|
+
<xsl:apply-templates select="../*[local-name()='thead']" mode="process"/>
|
2412
|
+
|
2413
|
+
<xsl:call-template name="insertTableFooter"/>
|
2414
|
+
|
2369
2415
|
<fo:table-body>
|
2370
|
-
<xsl:apply-templates select="../*[local-name()='thead']" mode="process"/>
|
2371
2416
|
<xsl:apply-templates/>
|
2372
|
-
<xsl:apply-templates select="../*[local-name()='tfoot']" mode="process"/>
|
2373
|
-
|
2374
|
-
<xsl:if test="../*[local-name()='note'] or ..//*[local-name()='fn'][local-name(..) != 'name']">
|
2375
|
-
<fo:table-row>
|
2376
|
-
<fo:table-cell border="solid black 1pt" padding-left="1mm" padding-right="1mm" padding-top="1mm" number-columns-spanned="{$cols-count}">
|
2377
|
-
|
2378
|
-
|
2379
|
-
|
2380
|
-
<!-- fn will be processed inside 'note' processing -->
|
2381
|
-
|
2382
|
-
|
2383
|
-
<xsl:apply-templates select="../*[local-name()='note']" mode="process"/>
|
2384
|
-
|
2385
|
-
<!-- horizontal row separator -->
|
2386
|
-
|
2387
|
-
|
2388
|
-
<!-- fn processing -->
|
2389
|
-
<xsl:call-template name="fn_display"/>
|
2390
|
-
|
2391
|
-
</fo:table-cell>
|
2392
|
-
</fo:table-row>
|
2393
|
-
|
2394
|
-
</xsl:if>
|
2417
|
+
<!-- <xsl:apply-templates select="../*[local-name()='tfoot']" mode="process"/> -->
|
2418
|
+
|
2395
2419
|
</fo:table-body>
|
2420
|
+
|
2396
2421
|
</xsl:template><xsl:template xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" match="*[local-name()='tr']">
|
2397
2422
|
<xsl:variable name="parent-name" select="local-name(..)"/>
|
2398
2423
|
<!-- <xsl:variable name="namespace" select="substring-before(name(/*), '-')"/> -->
|
@@ -2410,6 +2435,7 @@
|
|
2410
2435
|
|
2411
2436
|
</xsl:if>
|
2412
2437
|
|
2438
|
+
|
2413
2439
|
<xsl:apply-templates/>
|
2414
2440
|
</fo:table-row>
|
2415
2441
|
</xsl:template><xsl:template xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" match="*[local-name()='th']">
|
@@ -2444,6 +2470,8 @@
|
|
2444
2470
|
|
2445
2471
|
|
2446
2472
|
|
2473
|
+
|
2474
|
+
|
2447
2475
|
<xsl:if test="@colspan">
|
2448
2476
|
<xsl:attribute name="number-columns-spanned">
|
2449
2477
|
<xsl:value-of select="@colspan"/>
|
@@ -2476,13 +2504,17 @@
|
|
2476
2504
|
<fo:block font-size="10pt" margin-bottom="12pt">
|
2477
2505
|
|
2478
2506
|
|
2507
|
+
|
2479
2508
|
<fo:inline padding-right="2mm">
|
2509
|
+
|
2480
2510
|
<xsl:text>NOTE </xsl:text>
|
2481
2511
|
|
2482
2512
|
<xsl:variable name="id" select="ancestor::*[local-name() = 'table'][1]/@id"/>
|
2483
2513
|
<xsl:if test="count(//*[local-name()='note'][ancestor::*[@id = $id]]) > 1">
|
2484
2514
|
<xsl:number count="*[local-name()='note'][ancestor::*[@id = $id]]" level="any"/>
|
2485
2515
|
</xsl:if>
|
2516
|
+
|
2517
|
+
|
2486
2518
|
|
2487
2519
|
|
2488
2520
|
</fo:inline>
|
@@ -2513,6 +2545,7 @@
|
|
2513
2545
|
<fo:block margin-bottom="12pt">
|
2514
2546
|
|
2515
2547
|
|
2548
|
+
|
2516
2549
|
<fo:inline font-size="80%" padding-right="5mm" id="{@id}">
|
2517
2550
|
|
2518
2551
|
<xsl:attribute name="vertical-align">super</xsl:attribute>
|
@@ -2521,6 +2554,7 @@
|
|
2521
2554
|
|
2522
2555
|
|
2523
2556
|
|
2557
|
+
|
2524
2558
|
<xsl:value-of select="@reference"/>
|
2525
2559
|
|
2526
2560
|
</fo:inline>
|
@@ -2603,6 +2637,7 @@
|
|
2603
2637
|
<fo:inline font-size="80%" keep-with-previous.within-line="always">
|
2604
2638
|
|
2605
2639
|
|
2640
|
+
|
2606
2641
|
<xsl:attribute name="vertical-align">super</xsl:attribute>
|
2607
2642
|
<xsl:attribute name="color">blue</xsl:attribute>
|
2608
2643
|
|
@@ -2635,7 +2670,7 @@
|
|
2635
2670
|
|
2636
2671
|
|
2637
2672
|
<fo:block margin-bottom="12pt" text-align="left">
|
2638
|
-
|
2673
|
+
|
2639
2674
|
<xsl:text>where </xsl:text>
|
2640
2675
|
<xsl:apply-templates select="*[local-name()='dt']/*"/>
|
2641
2676
|
<xsl:text/>
|
@@ -2648,6 +2683,7 @@
|
|
2648
2683
|
|
2649
2684
|
|
2650
2685
|
|
2686
|
+
|
2651
2687
|
<xsl:text>where</xsl:text>
|
2652
2688
|
</fo:block>
|
2653
2689
|
</xsl:when>
|
@@ -2655,6 +2691,7 @@
|
|
2655
2691
|
<fo:block font-weight="bold" text-align="left" margin-bottom="12pt">
|
2656
2692
|
|
2657
2693
|
|
2694
|
+
|
2658
2695
|
<xsl:text>Key</xsl:text>
|
2659
2696
|
</fo:block>
|
2660
2697
|
</xsl:when>
|
@@ -2666,9 +2703,9 @@
|
|
2666
2703
|
|
2667
2704
|
|
2668
2705
|
|
2669
|
-
|
2670
2706
|
<fo:block>
|
2671
2707
|
|
2708
|
+
|
2672
2709
|
<!-- create virtual html table for dl/[dt and dd] -->
|
2673
2710
|
<xsl:variable name="html-table">
|
2674
2711
|
<xsl:variable name="ns" select="substring-before(name(/*), '-')"/>
|
@@ -2688,6 +2725,7 @@
|
|
2688
2725
|
<!-- colwidths=<xsl:value-of select="$colwidths"/> -->
|
2689
2726
|
|
2690
2727
|
<fo:table width="95%" table-layout="fixed">
|
2728
|
+
|
2691
2729
|
<xsl:choose>
|
2692
2730
|
<xsl:when test="normalize-space($key_iso) = 'true' and $parent = 'formula'">
|
2693
2731
|
<!-- <xsl:attribute name="font-size">11pt</xsl:attribute> -->
|
@@ -2787,6 +2825,7 @@
|
|
2787
2825
|
<fo:table-cell>
|
2788
2826
|
<fo:block margin-top="6pt">
|
2789
2827
|
|
2828
|
+
|
2790
2829
|
<xsl:if test="normalize-space($key_iso) = 'true'">
|
2791
2830
|
<xsl:attribute name="margin-top">0</xsl:attribute>
|
2792
2831
|
|
@@ -2794,6 +2833,7 @@
|
|
2794
2833
|
|
2795
2834
|
|
2796
2835
|
<xsl:apply-templates/>
|
2836
|
+
|
2797
2837
|
</fo:block>
|
2798
2838
|
</fo:table-cell>
|
2799
2839
|
<fo:table-cell>
|
@@ -2812,7 +2852,7 @@
|
|
2812
2852
|
</xsl:template><xsl:template xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" match="*[local-name()='dd']"/><xsl:template xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" match="*[local-name()='dd']" mode="process">
|
2813
2853
|
<xsl:apply-templates/>
|
2814
2854
|
</xsl:template><xsl:template xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" match="*[local-name()='dd']/*[local-name()='p']" mode="inline">
|
2815
|
-
<fo:inline><xsl:apply-templates/></fo:inline>
|
2855
|
+
<fo:inline><xsl:text> </xsl:text><xsl:apply-templates/></fo:inline>
|
2816
2856
|
</xsl:template><xsl:template xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" match="*[local-name()='em']">
|
2817
2857
|
<fo:inline font-style="italic">
|
2818
2858
|
<xsl:apply-templates/>
|
@@ -2927,6 +2967,7 @@
|
|
2927
2967
|
<xsl:variable name="zero-space-after-dot">.</xsl:variable>
|
2928
2968
|
<xsl:variable name="zero-space-after-colon">:</xsl:variable>
|
2929
2969
|
<xsl:variable name="zero-space-after-equal">=</xsl:variable>
|
2970
|
+
<xsl:variable name="zero-space-after-underscore">_</xsl:variable>
|
2930
2971
|
<xsl:variable name="zero-space"></xsl:variable>
|
2931
2972
|
<xsl:choose>
|
2932
2973
|
<xsl:when test="contains($text, $zero-space-after-chars)">
|
@@ -2961,6 +3002,14 @@
|
|
2961
3002
|
<xsl:with-param name="text" select="substring-after($text, $zero-space-after-equal)"/>
|
2962
3003
|
</xsl:call-template>
|
2963
3004
|
</xsl:when>
|
3005
|
+
<xsl:when test="contains($text, $zero-space-after-underscore)">
|
3006
|
+
<xsl:value-of select="substring-before($text, $zero-space-after-underscore)"/>
|
3007
|
+
<xsl:value-of select="$zero-space-after-underscore"/>
|
3008
|
+
<xsl:value-of select="$zero-space"/>
|
3009
|
+
<xsl:call-template name="add-zero-spaces">
|
3010
|
+
<xsl:with-param name="text" select="substring-after($text, $zero-space-after-underscore)"/>
|
3011
|
+
</xsl:call-template>
|
3012
|
+
</xsl:when>
|
2964
3013
|
<xsl:otherwise>
|
2965
3014
|
<xsl:value-of select="$text"/>
|
2966
3015
|
</xsl:otherwise>
|
@@ -3137,4 +3186,40 @@
|
|
3137
3186
|
<xsl:copy-of select="."/>
|
3138
3187
|
</fo:instream-foreign-object>
|
3139
3188
|
</fo:inline>
|
3189
|
+
</xsl:template><xsl:template xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" match="*[local-name()='localityStack']">
|
3190
|
+
<xsl:for-each select="*[local-name()='locality']">
|
3191
|
+
<xsl:if test="position() =1"><xsl:text>, </xsl:text></xsl:if>
|
3192
|
+
<xsl:apply-templates select="."/>
|
3193
|
+
<xsl:if test="position() != last()"><xsl:text>; </xsl:text></xsl:if>
|
3194
|
+
</xsl:for-each>
|
3195
|
+
</xsl:template><xsl:template xmlns:iso="https://www.metanorma.org/ns/iso" xmlns:iec="https://www.metanorma.org/ns/iec" xmlns:itu="https://www.metanorma.org/ns/itu" xmlns:nist="https://www.metanorma.org/ns/nist" xmlns:un="https://www.metanorma.org/ns/un" xmlns:csd="https://www.metanorma.org/ns/csd" match="*[local-name()='link']" name="link">
|
3196
|
+
<xsl:variable name="target">
|
3197
|
+
<xsl:choose>
|
3198
|
+
<xsl:when test="starts-with(normalize-space(@target), 'mailto:')">
|
3199
|
+
<xsl:value-of select="normalize-space(substring-after(@target, 'mailto:'))"/>
|
3200
|
+
</xsl:when>
|
3201
|
+
<xsl:otherwise>
|
3202
|
+
<xsl:value-of select="normalize-space(@target)"/>
|
3203
|
+
</xsl:otherwise>
|
3204
|
+
</xsl:choose>
|
3205
|
+
</xsl:variable>
|
3206
|
+
<fo:inline xsl:use-attribute-sets="link-style">
|
3207
|
+
<xsl:choose>
|
3208
|
+
<xsl:when test="$target = ''">
|
3209
|
+
<xsl:apply-templates/>
|
3210
|
+
</xsl:when>
|
3211
|
+
<xsl:otherwise>
|
3212
|
+
<fo:basic-link external-destination="{@target}" fox:alt-text="{@target}">
|
3213
|
+
<xsl:choose>
|
3214
|
+
<xsl:when test="normalize-space(.) = ''">
|
3215
|
+
<xsl:value-of select="$target"/>
|
3216
|
+
</xsl:when>
|
3217
|
+
<xsl:otherwise>
|
3218
|
+
<xsl:apply-templates/>
|
3219
|
+
</xsl:otherwise>
|
3220
|
+
</xsl:choose>
|
3221
|
+
</fo:basic-link>
|
3222
|
+
</xsl:otherwise>
|
3223
|
+
</xsl:choose>
|
3224
|
+
</fo:inline>
|
3140
3225
|
</xsl:template></xsl:stylesheet>
|