metanorma-rsd 1.4.7 → 1.4.8

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 802756f03295166bbb32dd6b0dfc244f6f64c1ba98dd9808263eb179b99b2b7c
4
- data.tar.gz: c84e0af4dc2d037bb15c615a20e7efc86de190958eadf3674d5475baf154b456
3
+ metadata.gz: 997591e5cfad77bcee7531385c1aff655ce796d206235543dcdb693768db2a71
4
+ data.tar.gz: d646c08f95be210686c828212a9fecdf788f0760fa272575cde8939baa6765b8
5
5
  SHA512:
6
- metadata.gz: 4c986c7e7f17108553e7f5096ae77c0fe457479af7c8b10f5af0d20b076350af888627908605cb044f278834a935eaba7138be0f229544fbbcd196df95b87794
7
- data.tar.gz: 9c96fec2b774c12fb73652f5e500fbb0d6b551618f9805a30a0961581753d193869f5ddb3756739a8619cb42eb7a64e92d22318b728728c10ea665dbbc48c94b
6
+ metadata.gz: aa056708f9db2c13bd46538ebaf35ae65581dee94fd08c5d2c9e985b40d19d7a2cdfb5ac92eca2f1960d287568b2e2f9f88ce3490a2c5bf0eecb301bdfea8ff0
7
+ data.tar.gz: 99fb7cbccce51537d1e35f4914fee9f08bf3fe1b68152c8c7342e6ccc1b68ec5d2530688e5a9954229ebf0592853c231cb848942003e38363f912e10f8b7f6f7
@@ -661,9 +661,9 @@
661
661
  <optional>
662
662
  <ref name="status"/>
663
663
  </optional>
664
- <optional>
664
+ <zeroOrMore>
665
665
  <ref name="copyright"/>
666
- </optional>
666
+ </zeroOrMore>
667
667
  <zeroOrMore>
668
668
  <ref name="docrelation"/>
669
669
  </zeroOrMore>
@@ -1021,7 +1021,17 @@
1021
1021
  <optional>
1022
1022
  <ref name="to"/>
1023
1023
  </optional>
1024
- <ref name="owner"/>
1024
+ <oneOrMore>
1025
+ <ref name="owner"/>
1026
+ </oneOrMore>
1027
+ <optional>
1028
+ <ref name="copyright_scope"/>
1029
+ </optional>
1030
+ </element>
1031
+ </define>
1032
+ <define name="copyright_scope">
1033
+ <element name="scope">
1034
+ <text/>
1025
1035
  </element>
1026
1036
  </define>
1027
1037
  <define name="from">
@@ -53,6 +53,14 @@
53
53
  <optional>
54
54
  <attribute name="alt"/>
55
55
  </optional>
56
+ <optional>
57
+ <attribute name="case">
58
+ <choice>
59
+ <value>capital</value>
60
+ <value>lowercase</value>
61
+ </choice>
62
+ </attribute>
63
+ </optional>
56
64
  <text/>
57
65
  </element>
58
66
  </define>
@@ -902,7 +910,15 @@
902
910
  <attribute name="id">
903
911
  <data type="ID"/>
904
912
  </attribute>
905
- <ref name="paragraph"/>
913
+ <oneOrMore>
914
+ <choice>
915
+ <ref name="paragraph"/>
916
+ <ref name="ul"/>
917
+ <ref name="ol"/>
918
+ <ref name="dl"/>
919
+ <ref name="formula"/>
920
+ </choice>
921
+ </oneOrMore>
906
922
  </element>
907
923
  </define>
908
924
  <define name="termexample">
@@ -129,14 +129,7 @@
129
129
  <xsl:value-of select="normalize-space($abstract)"/>
130
130
  </dc:description>
131
131
  <pdf:Keywords>
132
- <xsl:for-each select="/rsd:rsd-standard/rsd:bibdata//rsd:keyword">
133
- <xsl:sort data-type="text" order="ascending"/>
134
- <xsl:apply-templates/>
135
- <xsl:choose>
136
- <xsl:when test="position() != last()">, </xsl:when>
137
- <xsl:otherwise>.</xsl:otherwise>
138
- </xsl:choose>
139
- </xsl:for-each>
132
+ <xsl:call-template name="insertKeywords"/>
140
133
  </pdf:Keywords>
141
134
  </rdf:Description>
142
135
  <rdf:Description xmlns:xmp="http://ns.adobe.com/xap/1.0/" rdf:about="">
@@ -672,10 +665,14 @@
672
665
  </fo:block>
673
666
  <fo:block margin-bottom="12pt">The following are keywords to be used by search engines and document catalogues.</fo:block>
674
667
  <fo:block margin-bottom="12pt">
675
- <xsl:for-each select="/rsd:rsd-standard/rsd:bibdata/rsd:keyword">
668
+ <xsl:call-template name="insertKeywords">
669
+ <xsl:with-param name="sorting">no</xsl:with-param>
670
+ <xsl:with-param name="charAtEnd"/>
671
+ </xsl:call-template>
672
+ <!-- <xsl:for-each select="/rsd:rsd-standard/rsd:bibdata/rsd:keyword">
676
673
  <xsl:value-of select="."/>
677
674
  <xsl:if test="position() != last()">, </xsl:if>
678
- </xsl:for-each>
675
+ </xsl:for-each> -->
679
676
  </fo:block>
680
677
  </xsl:template>
681
678
  <!-- Submitting Organizations -->
@@ -1332,57 +1329,6 @@
1332
1329
  </fo:basic-link>
1333
1330
  </xsl:template>
1334
1331
 
1335
- <xsl:template match="rsd:appendix">
1336
- <fo:block font-size="12pt" font-weight="bold" margin-top="12pt" margin-bottom="12pt">
1337
- <fo:inline padding-right="5mm">Appendix <xsl:number/></fo:inline>
1338
- <xsl:apply-templates select="rsd:title" mode="process"/>
1339
- </fo:block>
1340
- <xsl:apply-templates/>
1341
- </xsl:template>
1342
-
1343
- <xsl:template match="rsd:appendix//rsd:example">
1344
- <fo:block font-family="SourceSansPro" font-size="11pt" margin-bottom="12pt">
1345
- <xsl:text>EXAMPLE</xsl:text>
1346
- <xsl:if test="rsd:name">
1347
- <xsl:text> — </xsl:text><xsl:apply-templates select="rsd:name" mode="process"/>
1348
- </xsl:if>
1349
- </fo:block>
1350
- <xsl:apply-templates/>
1351
- </xsl:template>
1352
-
1353
- <xsl:template match="rsd:appendix//rsd:example/rsd:name"/>
1354
- <xsl:template match="rsd:appendix//rsd:example/rsd:name" mode="process">
1355
- <fo:inline><xsl:apply-templates/></fo:inline>
1356
- </xsl:template>
1357
-
1358
- <xsl:template match="rsd:callout">
1359
- <fo:basic-link internal-destination="{@target}" fox:alt-text="{@target}">&lt;<xsl:apply-templates/>&gt;</fo:basic-link>
1360
- </xsl:template>
1361
-
1362
- <xsl:template match="rsd:annotation">
1363
- <fo:block>
1364
-
1365
- </fo:block>
1366
- <xsl:apply-templates/>
1367
- </xsl:template>
1368
-
1369
- <xsl:template match="rsd:annotation/text()"/>
1370
-
1371
- <xsl:template match="rsd:annotation/rsd:p">
1372
- <xsl:variable name="annotation-id" select="../@id"/>
1373
- <xsl:variable name="callout" select="//*[@target = $annotation-id]/text()"/>
1374
- <fo:block id="{$annotation-id}">
1375
- <xsl:value-of select="concat('&lt;', $callout, '&gt; ')"/>
1376
- <xsl:apply-templates/>
1377
- </fo:block>
1378
- </xsl:template>
1379
-
1380
-
1381
- <xsl:template match="rsd:appendix/rsd:title"/>
1382
- <xsl:template match="rsd:appendix/rsd:title" mode="process">
1383
- <fo:inline><xsl:apply-templates/></fo:inline>
1384
- </xsl:template>
1385
-
1386
1332
 
1387
1333
  <xsl:template match="rsd:xref">
1388
1334
  <fo:basic-link color="{$color-link}" internal-destination="{@target}" fox:alt-text="{@target}">
@@ -1411,17 +1357,8 @@
1411
1357
  </fo:basic-link>
1412
1358
  </xsl:template>
1413
1359
 
1414
- <xsl:template match="rsd:sourcecode">
1415
- <fo:block font-family="SourceCodePro" font-size="10pt" margin-bottom="6pt" keep-with-next="always" line-height="113%">
1416
- <xsl:choose>
1417
- <xsl:when test="@lang = 'en'"/>
1418
- <xsl:otherwise>
1419
- <xsl:attribute name="white-space">pre</xsl:attribute>
1420
- <xsl:attribute name="wrap-option">wrap</xsl:attribute>
1421
- </xsl:otherwise>
1422
- </xsl:choose>
1423
- <xsl:apply-templates/>
1424
- </fo:block>
1360
+ <xsl:template match="rsd:sourcecode" priority="2">
1361
+ <xsl:call-template name="sourcecode"/>
1425
1362
  <xsl:choose>
1426
1363
  <xsl:when test="@unnumbered='true'"/>
1427
1364
  <xsl:when test="ancestor::rsd:example"/>
@@ -1624,11 +1561,7 @@
1624
1561
  <fo:block> </fo:block>
1625
1562
  <fo:block break-after="page"/>
1626
1563
  </xsl:template>
1627
-
1628
- <xsl:template match="rsd:bookmark">
1629
- <fo:inline id="{@id}"/>
1630
- </xsl:template>
1631
-
1564
+
1632
1565
  <xsl:template name="insertHeaderFooter">
1633
1566
  <xsl:param name="font-weight" select="'bold'"/>
1634
1567
  <fo:static-content flow-name="header-odd">
@@ -5401,19 +5334,89 @@
5401
5334
  </xsl:template>
5402
5335
 
5403
5336
 
5404
- <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" xmlns:ogc="https://www.metanorma.org/ns/ogc" 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" xmlns:ogc="https://www.metanorma.org/ns/ogc" 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" xmlns:ogc="https://www.metanorma.org/ns/ogc" 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" xmlns:ogc="https://www.metanorma.org/ns/ogc" name="linebreak" select="'&#8232;'"/><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" xmlns:ogc="https://www.metanorma.org/ns/ogc" name="link-style">
5337
+ <xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-table">
5338
+
5339
+ <xsl:text>Table </xsl:text>
5340
+
5341
+
5342
+ </xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-note">
5343
+
5344
+ <xsl:text>NOTE </xsl:text>
5345
+
5346
+
5347
+ </xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-figure">
5348
+
5349
+ <xsl:text>Figure </xsl:text>
5350
+
5351
+
5352
+ </xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-example">
5353
+
5354
+ <xsl:text>EXAMPLE </xsl:text>
5355
+
5356
+
5357
+ </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">
5358
+
5359
+ <xsl:text>Annex </xsl:text>
5360
+
5361
+
5362
+ </xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-appendix">
5363
+ <xsl:text>Appendix </xsl:text>
5364
+ </xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-clause">
5365
+
5366
+ <xsl:text>Clause </xsl:text>
5367
+
5368
+
5369
+ </xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-edition">
5370
+ <xsl:text>Edition </xsl:text>
5371
+ </xsl:variable><xsl:variable xmlns:java="http://xml.apache.org/xalan/java" name="title-toc">
5372
+
5373
+
5374
+ </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="'&#8232;'"/><xsl:attribute-set xmlns:java="http://xml.apache.org/xalan/java" name="link-style">
5405
5375
 
5406
5376
  <xsl:attribute name="color">blue</xsl:attribute>
5407
5377
  <xsl:attribute name="text-decoration">underline</xsl:attribute>
5408
5378
 
5409
5379
 
5410
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="text()">
5380
+ </xsl:attribute-set><xsl:attribute-set xmlns:java="http://xml.apache.org/xalan/java" name="sourcecode-style">
5381
+
5382
+
5383
+ <xsl:attribute name="font-family">SourceCodePro</xsl:attribute>
5384
+ <xsl:attribute name="font-size">10pt</xsl:attribute>
5385
+ <xsl:attribute name="margin-bottom">6pt</xsl:attribute>
5386
+ <xsl:attribute name="keep-with-next">always</xsl:attribute>
5387
+ <xsl:attribute name="line-height">113%</xsl:attribute>
5388
+
5389
+
5390
+
5391
+
5392
+
5393
+
5394
+
5395
+ </xsl:attribute-set><xsl:attribute-set xmlns:java="http://xml.apache.org/xalan/java" name="appendix-style">
5396
+
5397
+
5398
+
5399
+ <xsl:attribute name="font-size">12pt</xsl:attribute>
5400
+ <xsl:attribute name="font-family">SourceSansPro</xsl:attribute>
5401
+ <xsl:attribute name="margin-top">12pt</xsl:attribute>
5402
+ <xsl:attribute name="margin-bottom">12pt</xsl:attribute>
5403
+
5404
+ </xsl:attribute-set><xsl:attribute-set xmlns:java="http://xml.apache.org/xalan/java" name="appendix-example-style">
5405
+
5406
+
5407
+
5408
+ <xsl:attribute name="font-family">SourceSansPro</xsl:attribute>
5409
+ <xsl:attribute name="font-size">11pt</xsl:attribute>
5410
+ <xsl:attribute name="margin-bottom">12pt</xsl:attribute>
5411
+
5412
+ </xsl:attribute-set><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="text()">
5411
5413
  <xsl:value-of select="."/>
5412
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='br']">
5414
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='br']">
5413
5415
  <xsl:value-of select="$linebreak"/>
5414
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='td']//text() | *[local-name()='th']//text() | *[local-name()='dt']//text() | *[local-name()='dd']//text()" priority="1">
5415
- <xsl:call-template name="add-zero-spaces"/>
5416
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='table']">
5416
+ </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">
5417
+ <!-- <xsl:call-template name="add-zero-spaces"/> -->
5418
+ <xsl:call-template name="add-zero-spaces-java"/>
5419
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='table']">
5417
5420
 
5418
5421
  <xsl:variable name="simple-table">
5419
5422
  <!-- <xsl:copy> -->
@@ -5494,6 +5497,7 @@
5494
5497
 
5495
5498
 
5496
5499
 
5500
+
5497
5501
  <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">
5498
5502
 
5499
5503
 
@@ -5505,9 +5509,10 @@
5505
5509
 
5506
5510
 
5507
5511
 
5512
+
5508
5513
  <xsl:for-each select="xalan:nodeset($colwidths)//column">
5509
5514
  <xsl:choose>
5510
- <xsl:when test=". = 1">
5515
+ <xsl:when test=". = 1 or . = 0">
5511
5516
  <fo:table-column column-width="proportional-column-width(2)"/>
5512
5517
  </xsl:when>
5513
5518
  <xsl:otherwise>
@@ -5521,15 +5526,35 @@
5521
5526
 
5522
5527
 
5523
5528
  </fo:block-container>
5524
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" 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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='table']/*[local-name()='name']" mode="process">
5529
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="getTableNumber">
5530
+ <xsl:choose>
5531
+ <xsl:when test="ancestor::*[local-name()='executivesummary']"> <!-- NIST -->
5532
+ <xsl:text>ES-</xsl:text><xsl:number format="1" count="*[local-name()='executivesummary']//*[local-name()='table'][not(@unnumbered) or @unnumbered != 'true']"/>
5533
+ </xsl:when>
5534
+ <xsl:when test="ancestor::*[local-name()='annex']">
5535
+
5536
+
5537
+
5538
+
5539
+
5540
+
5541
+
5542
+
5543
+ </xsl:when>
5544
+ <xsl:otherwise>
5545
+
5546
+
5547
+ </xsl:otherwise>
5548
+ </xsl:choose>
5549
+ </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">
5525
5550
  <xsl:apply-templates/>
5526
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" name="calculate-columns-numbers">
5551
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="calculate-columns-numbers">
5527
5552
  <xsl:param name="table-row"/>
5528
5553
  <xsl:variable name="columns-count" select="count($table-row/*)"/>
5529
5554
  <xsl:variable name="sum-colspans" select="sum($table-row/*/@colspan)"/>
5530
5555
  <xsl:variable name="columns-with-colspan" select="count($table-row/*[@colspan])"/>
5531
5556
  <xsl:value-of select="$columns-count + $sum-colspans - $columns-with-colspan"/>
5532
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" name="calculate-column-widths">
5557
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="calculate-column-widths">
5533
5558
  <xsl:param name="table"/>
5534
5559
  <xsl:param name="cols-count"/>
5535
5560
  <xsl:param name="curr-col" select="1"/>
@@ -5538,7 +5563,7 @@
5538
5563
  <xsl:if test="$curr-col &lt;= $cols-count">
5539
5564
  <xsl:variable name="widths">
5540
5565
  <xsl:choose>
5541
- <xsl:when test="not($table)">
5566
+ <xsl:when test="not($table)"><!-- this branch is not using in production, for debug only -->
5542
5567
  <xsl:for-each select="*[local-name()='thead']//*[local-name()='tr']">
5543
5568
  <xsl:variable name="words">
5544
5569
  <xsl:call-template name="tokenize">
@@ -5577,9 +5602,16 @@
5577
5602
  <xsl:apply-templates select="td[$curr-col]" mode="td_text"/>
5578
5603
  </xsl:variable>
5579
5604
  <xsl:variable name="words">
5605
+ <xsl:variable name="string_with_added_zerospaces">
5606
+ <xsl:call-template name="add-zero-spaces-java">
5607
+ <xsl:with-param name="text" select="$td_text"/>
5608
+ </xsl:call-template>
5609
+ </xsl:variable>
5580
5610
  <xsl:call-template name="tokenize">
5581
5611
  <!-- <xsl:with-param name="text" select="translate(td[$curr-col],'- —:', ' ')"/> -->
5582
- <xsl:with-param name="text" select="translate(normalize-space($td_text),'- —:', ' ')"/>
5612
+ <!-- 2009 thinspace -->
5613
+ <!-- <xsl:with-param name="text" select="translate(normalize-space($td_text),'- —:', ' ')"/> -->
5614
+ <xsl:with-param name="text" select="normalize-space(translate($string_with_added_zerospaces, '​', ' '))"/>
5583
5615
  </xsl:call-template>
5584
5616
  </xsl:variable>
5585
5617
  <xsl:variable name="max_length">
@@ -5620,17 +5652,24 @@
5620
5652
  <xsl:with-param name="table" select="$table"/>
5621
5653
  </xsl:call-template>
5622
5654
  </xsl:if>
5623
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="text()" mode="td_text">
5655
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="text()" mode="td_text">
5624
5656
  <xsl:variable name="zero-space">​</xsl:variable>
5625
5657
  <xsl:value-of select="translate(., $zero-space, ' ')"/><xsl:text> </xsl:text>
5626
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" 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" xmlns:ogc="https://www.metanorma.org/ns/ogc" 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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='thead']" mode="process">
5658
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='termsource']" mode="td_text">
5659
+ <xsl:value-of select="*[local-name()='origin']/@citeas"/>
5660
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='link']" mode="td_text">
5661
+ <xsl:value-of select="@target"/>
5662
+ </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">
5663
+ <xsl:param name="cols-count"/>
5627
5664
  <!-- font-weight="bold" -->
5628
- <fo:table-header>
5665
+ <fo:table-header>
5666
+
5629
5667
  <xsl:apply-templates/>
5630
5668
  </fo:table-header>
5631
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" 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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='tfoot']" mode="process">
5669
+ </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">
5632
5670
  <xsl:apply-templates/>
5633
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" name="insertTableFooter">
5671
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="insertTableFooter">
5672
+ <xsl:param name="cols-count"/>
5634
5673
  <xsl:variable name="isNoteOrFnExist" select="../*[local-name()='note'] or ..//*[local-name()='fn'][local-name(..) != 'name']"/>
5635
5674
  <xsl:if test="../*[local-name()='tfoot'] or $isNoteOrFnExist = 'true'">
5636
5675
 
@@ -5641,22 +5680,7 @@
5641
5680
  <!-- if there are note(s) or fn(s) then create footer row -->
5642
5681
  <xsl:if test="$isNoteOrFnExist = 'true'">
5643
5682
 
5644
- <xsl:variable name="cols-count">
5645
- <xsl:choose>
5646
- <xsl:when test="../*[local-name()='thead']">
5647
- <!-- <xsl:value-of select="count(../*[local-name()='thead']/*[local-name()='tr']/*[local-name()='th'])"/> -->
5648
- <xsl:call-template name="calculate-columns-numbers">
5649
- <xsl:with-param name="table-row" select="../*[local-name()='thead']/*[local-name()='tr'][1]"/>
5650
- </xsl:call-template>
5651
- </xsl:when>
5652
- <xsl:otherwise>
5653
- <!-- <xsl:value-of select="count(./*[local-name()='tr'][1]/*[local-name()='td'])"/> -->
5654
- <xsl:call-template name="calculate-columns-numbers">
5655
- <xsl:with-param name="table-row" select="./*[local-name()='tr'][1]"/>
5656
- </xsl:call-template>
5657
- </xsl:otherwise>
5658
- </xsl:choose>
5659
- </xsl:variable>
5683
+
5660
5684
 
5661
5685
  <fo:table-row>
5662
5686
  <fo:table-cell border="solid black 1pt" padding-left="1mm" padding-right="1mm" padding-top="1mm" number-columns-spanned="{$cols-count}">
@@ -5684,11 +5708,30 @@
5684
5708
  </fo:table-footer>
5685
5709
 
5686
5710
  </xsl:if>
5687
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='tbody']">
5711
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='tbody']">
5688
5712
 
5689
- <xsl:apply-templates select="../*[local-name()='thead']" mode="process"/>
5713
+ <xsl:variable name="cols-count">
5714
+ <xsl:choose>
5715
+ <xsl:when test="../*[local-name()='thead']">
5716
+ <xsl:call-template name="calculate-columns-numbers">
5717
+ <xsl:with-param name="table-row" select="../*[local-name()='thead']/*[local-name()='tr'][1]"/>
5718
+ </xsl:call-template>
5719
+ </xsl:when>
5720
+ <xsl:otherwise>
5721
+ <xsl:call-template name="calculate-columns-numbers">
5722
+ <xsl:with-param name="table-row" select="./*[local-name()='tr'][1]"/>
5723
+ </xsl:call-template>
5724
+ </xsl:otherwise>
5725
+ </xsl:choose>
5726
+ </xsl:variable>
5690
5727
 
5691
- <xsl:call-template name="insertTableFooter"/>
5728
+ <xsl:apply-templates select="../*[local-name()='thead']" mode="process">
5729
+ <xsl:with-param name="cols-count" select="$cols-count"/>
5730
+ </xsl:apply-templates>
5731
+
5732
+ <xsl:call-template name="insertTableFooter">
5733
+ <xsl:with-param name="cols-count" select="$cols-count"/>
5734
+ </xsl:call-template>
5692
5735
 
5693
5736
  <fo:table-body>
5694
5737
  <xsl:apply-templates/>
@@ -5696,7 +5739,7 @@
5696
5739
 
5697
5740
  </fo:table-body>
5698
5741
 
5699
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='tr']">
5742
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='tr']">
5700
5743
  <xsl:variable name="parent-name" select="local-name(..)"/>
5701
5744
  <!-- <xsl:variable name="namespace" select="substring-before(name(/*), '-')"/> -->
5702
5745
  <fo:table-row min-height="4mm">
@@ -5716,7 +5759,7 @@
5716
5759
 
5717
5760
  <xsl:apply-templates/>
5718
5761
  </fo:table-row>
5719
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='th']">
5762
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='th']">
5720
5763
  <fo:table-cell text-align="{@align}" font-weight="bold" border="solid black 1pt" padding-left="1mm" display-align="center">
5721
5764
 
5722
5765
 
@@ -5739,7 +5782,7 @@
5739
5782
  <xsl:apply-templates/>
5740
5783
  </fo:block>
5741
5784
  </fo:table-cell>
5742
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='td']">
5785
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='td']">
5743
5786
  <fo:table-cell text-align="{@align}" display-align="center" border="solid black 1pt" padding-left="1mm">
5744
5787
 
5745
5788
 
@@ -5761,6 +5804,7 @@
5761
5804
  </xsl:attribute>
5762
5805
  </xsl:if>
5763
5806
  <fo:block>
5807
+
5764
5808
  <xsl:apply-templates/>
5765
5809
  </fo:block>
5766
5810
  <!-- <xsl:choose>
@@ -5776,16 +5820,18 @@
5776
5820
 
5777
5821
 
5778
5822
  </fo:table-cell>
5779
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='table']/*[local-name()='note']"/><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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='table']/*[local-name()='note']" mode="process">
5823
+ </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">
5780
5824
 
5781
5825
 
5782
5826
  <fo:block font-size="10pt" margin-bottom="12pt">
5783
5827
 
5784
5828
 
5785
5829
 
5830
+
5786
5831
  <fo:inline padding-right="2mm">
5787
5832
 
5788
- <xsl:text>NOTE </xsl:text>
5833
+
5834
+ <xsl:value-of select="$title-note"/>
5789
5835
 
5790
5836
 
5791
5837
 
@@ -5793,9 +5839,9 @@
5793
5839
  <xsl:apply-templates mode="process"/>
5794
5840
  </fo:block>
5795
5841
 
5796
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='table']/*[local-name()='note']/*[local-name()='p']" mode="process">
5842
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='table']/*[local-name()='note']/*[local-name()='p']" mode="process">
5797
5843
  <xsl:apply-templates/>
5798
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" name="fn_display">
5844
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="fn_display">
5799
5845
  <xsl:variable name="references">
5800
5846
  <xsl:for-each select="..//*[local-name()='fn'][local-name(..) != 'name']">
5801
5847
  <fn reference="{@reference}" id="{@reference}_{ancestor::*[@id][1]/@id}">
@@ -5812,6 +5858,7 @@
5812
5858
 
5813
5859
 
5814
5860
 
5861
+
5815
5862
  <fo:inline font-size="80%" padding-right="5mm" id="{@id}">
5816
5863
 
5817
5864
 
@@ -5829,7 +5876,7 @@
5829
5876
  </fo:block>
5830
5877
  </xsl:if>
5831
5878
  </xsl:for-each>
5832
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" name="fn_name_display">
5879
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="fn_name_display">
5833
5880
  <!-- <xsl:variable name="references">
5834
5881
  <xsl:for-each select="*[local-name()='name']//*[local-name()='fn']">
5835
5882
  <fn reference="{@reference}" id="{@reference}_{ancestor::*[@id][1]/@id}">
@@ -5845,7 +5892,7 @@
5845
5892
  <xsl:apply-templates/>
5846
5893
  </fo:block>
5847
5894
  </xsl:for-each>
5848
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" name="fn_display_figure">
5895
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="fn_display_figure">
5849
5896
  <xsl:variable name="key_iso">
5850
5897
  <!-- and (not(@class) or @class !='pseudocode') -->
5851
5898
  </xsl:variable>
@@ -5896,7 +5943,7 @@
5896
5943
  </fo:block>
5897
5944
  </xsl:if>
5898
5945
 
5899
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='fn']">
5946
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='fn']">
5900
5947
  <!-- <xsl:variable name="namespace" select="substring-before(name(/*), '-')"/> -->
5901
5948
  <fo:inline font-size="80%" keep-with-previous.within-line="always">
5902
5949
 
@@ -5908,11 +5955,11 @@
5908
5955
  <xsl:value-of select="@reference"/>
5909
5956
  </fo:basic-link>
5910
5957
  </fo:inline>
5911
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='fn']/*[local-name()='p']">
5958
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='fn']/*[local-name()='p']">
5912
5959
  <fo:inline>
5913
5960
  <xsl:apply-templates/>
5914
5961
  </fo:inline>
5915
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='dl']">
5962
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='dl']">
5916
5963
  <xsl:variable name="parent" select="local-name(..)"/>
5917
5964
 
5918
5965
  <xsl:variable name="key_iso">
@@ -5930,7 +5977,7 @@
5930
5977
 
5931
5978
 
5932
5979
 
5933
- <xsl:text>where</xsl:text>
5980
+ <xsl:value-of select="$title-where"/>
5934
5981
  </fo:block>
5935
5982
  </xsl:when>
5936
5983
  <xsl:when test="$parent = 'figure' and (not(../@class) or ../@class !='pseudocode')">
@@ -5938,7 +5985,7 @@
5938
5985
 
5939
5986
 
5940
5987
 
5941
- <xsl:text>Key</xsl:text>
5988
+ <xsl:value-of select="$title-key"/>
5942
5989
  </fo:block>
5943
5990
  </xsl:when>
5944
5991
  </xsl:choose>
@@ -5949,9 +5996,11 @@
5949
5996
 
5950
5997
 
5951
5998
 
5999
+
5952
6000
  <fo:block>
5953
6001
 
5954
6002
 
6003
+
5955
6004
  <!-- create virtual html table for dl/[dt and dd] -->
5956
6005
  <xsl:variable name="html-table">
5957
6006
  <xsl:variable name="ns" select="substring-before(name(/*), '-')"/>
@@ -6003,7 +6052,7 @@
6003
6052
  <xsl:otherwise>
6004
6053
  <xsl:for-each select="xalan:nodeset($colwidths)//column">
6005
6054
  <xsl:choose>
6006
- <xsl:when test=". = 1">
6055
+ <xsl:when test=". = 1 or . = 0">
6007
6056
  <fo:table-column column-width="proportional-column-width(2)"/>
6008
6057
  </xsl:when>
6009
6058
  <xsl:otherwise>
@@ -6026,7 +6075,7 @@
6026
6075
  </fo:block>
6027
6076
  </fo:block>
6028
6077
  </xsl:if>
6029
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='dl']/*[local-name()='note']">
6078
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='dl']/*[local-name()='note']">
6030
6079
  <xsl:param name="key_iso"/>
6031
6080
 
6032
6081
  <!-- <tr>
@@ -6042,7 +6091,7 @@
6042
6091
  <xsl:if test="normalize-space($key_iso) = 'true'">
6043
6092
  <xsl:attribute name="margin-top">0</xsl:attribute>
6044
6093
  </xsl:if>
6045
- NOTE
6094
+ <xsl:value-of select="$title-note"/>
6046
6095
  </fo:block>
6047
6096
  </fo:table-cell>
6048
6097
  <fo:table-cell>
@@ -6051,7 +6100,7 @@
6051
6100
  </fo:block>
6052
6101
  </fo:table-cell>
6053
6102
  </fo:table-row>
6054
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='dt']" mode="dl">
6103
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='dt']" mode="dl">
6055
6104
  <tr>
6056
6105
  <td>
6057
6106
  <xsl:apply-templates/>
@@ -6062,11 +6111,12 @@
6062
6111
  </td>
6063
6112
  </tr>
6064
6113
 
6065
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='dt']">
6114
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='dt']">
6066
6115
  <xsl:param name="key_iso"/>
6067
6116
 
6068
6117
  <fo:table-row>
6069
6118
  <fo:table-cell>
6119
+
6070
6120
  <fo:block margin-top="6pt">
6071
6121
 
6072
6122
 
@@ -6076,6 +6126,9 @@
6076
6126
  </xsl:if>
6077
6127
 
6078
6128
 
6129
+
6130
+
6131
+
6079
6132
  <xsl:apply-templates/>
6080
6133
 
6081
6134
  </fo:block>
@@ -6089,37 +6142,37 @@
6089
6142
  </fo:table-cell>
6090
6143
  </fo:table-row>
6091
6144
 
6092
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='dd']" mode="dl"/><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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='dd']" mode="dl_process">
6145
+ </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">
6093
6146
  <xsl:apply-templates/>
6094
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" 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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='dd']" mode="process">
6147
+ </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">
6095
6148
  <xsl:apply-templates/>
6096
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='dd']/*[local-name()='p']" mode="inline">
6149
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='dd']/*[local-name()='p']" mode="inline">
6097
6150
  <fo:inline><xsl:text> </xsl:text><xsl:apply-templates/></fo:inline>
6098
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='em']">
6151
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='em']">
6099
6152
  <fo:inline font-style="italic">
6100
6153
  <xsl:apply-templates/>
6101
6154
  </fo:inline>
6102
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='strong']">
6155
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='strong']">
6103
6156
  <fo:inline font-weight="bold">
6104
6157
  <xsl:apply-templates/>
6105
6158
  </fo:inline>
6106
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='sup']">
6159
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='sup']">
6107
6160
  <fo:inline font-size="80%" vertical-align="super">
6108
6161
  <xsl:apply-templates/>
6109
6162
  </fo:inline>
6110
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='sub']">
6163
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='sub']">
6111
6164
  <fo:inline font-size="80%" vertical-align="sub">
6112
6165
  <xsl:apply-templates/>
6113
6166
  </fo:inline>
6114
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='tt']">
6115
- <fo:inline font-family="Courier" font-size="10pt">
6167
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='tt']">
6168
+ <fo:inline font-family="Courier" font-size="10pt">
6116
6169
  <xsl:apply-templates/>
6117
6170
  </fo:inline>
6118
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='del']">
6171
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='del']">
6119
6172
  <fo:inline font-size="10pt" color="red" text-decoration="line-through">
6120
6173
  <xsl:apply-templates/>
6121
6174
  </fo:inline>
6122
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="text()[ancestor::*[local-name()='smallcap']]">
6175
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="text()[ancestor::*[local-name()='smallcap']]">
6123
6176
  <xsl:variable name="text" select="normalize-space(.)"/>
6124
6177
  <fo:inline font-size="75%">
6125
6178
  <xsl:if test="string-length($text) &gt; 0">
@@ -6128,7 +6181,7 @@
6128
6181
  </xsl:call-template>
6129
6182
  </xsl:if>
6130
6183
  </fo:inline>
6131
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" name="recursiveSmallCaps">
6184
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="recursiveSmallCaps">
6132
6185
  <xsl:param name="text"/>
6133
6186
  <xsl:variable name="char" select="substring($text,1,1)"/>
6134
6187
  <xsl:variable name="upperCase" select="translate($char, $lower, $upper)"/>
@@ -6147,7 +6200,7 @@
6147
6200
  <xsl:with-param name="text" select="substring($text,2)"/>
6148
6201
  </xsl:call-template>
6149
6202
  </xsl:if>
6150
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" name="tokenize">
6203
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="tokenize">
6151
6204
  <xsl:param name="text"/>
6152
6205
  <xsl:param name="separator" select="' '"/>
6153
6206
  <xsl:choose>
@@ -6195,7 +6248,7 @@
6195
6248
  </xsl:call-template>
6196
6249
  </xsl:otherwise>
6197
6250
  </xsl:choose>
6198
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" name="max_length">
6251
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="max_length">
6199
6252
  <xsl:param name="words"/>
6200
6253
  <xsl:for-each select="$words//word">
6201
6254
  <xsl:sort select="." data-type="number" order="descending"/>
@@ -6203,7 +6256,11 @@
6203
6256
  <xsl:value-of select="."/>
6204
6257
  </xsl:if>
6205
6258
  </xsl:for-each>
6206
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" name="add-zero-spaces">
6259
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="add-zero-spaces-java">
6260
+ <xsl:param name="text" select="."/>
6261
+ <!-- add zero-width space (#x200B) after characters: dash, dot, colon, equal, underscore, em dash, thin space -->
6262
+ <xsl:value-of select="java:replaceAll(java:java.lang.String.new($text),'(-|\.|:|=|_|—| )','$1​')"/>
6263
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="add-zero-spaces">
6207
6264
  <xsl:param name="text" select="."/>
6208
6265
  <xsl:variable name="zero-space-after-chars">-</xsl:variable>
6209
6266
  <xsl:variable name="zero-space-after-dot">.</xsl:variable>
@@ -6256,7 +6313,7 @@
6256
6313
  <xsl:value-of select="$text"/>
6257
6314
  </xsl:otherwise>
6258
6315
  </xsl:choose>
6259
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" name="add-zero-spaces-equal">
6316
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="add-zero-spaces-equal">
6260
6317
  <xsl:param name="text" select="."/>
6261
6318
  <xsl:variable name="zero-space-after-equals">==========</xsl:variable>
6262
6319
  <xsl:variable name="zero-space-after-equal">=</xsl:variable>
@@ -6282,7 +6339,7 @@
6282
6339
  <xsl:value-of select="$text"/>
6283
6340
  </xsl:otherwise>
6284
6341
  </xsl:choose>
6285
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" name="getSimpleTable">
6342
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="getSimpleTable">
6286
6343
  <xsl:variable name="simple-table">
6287
6344
 
6288
6345
  <!-- Step 1. colspan processing -->
@@ -6309,9 +6366,9 @@
6309
6366
  </xsl:choose> -->
6310
6367
  </xsl:variable>
6311
6368
  <xsl:copy-of select="$simple-table"/>
6312
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='thead'] | *[local-name()='tbody']" mode="simple-table-colspan">
6369
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='thead'] | *[local-name()='tbody']" mode="simple-table-colspan">
6313
6370
  <xsl:apply-templates mode="simple-table-colspan"/>
6314
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='fn']" mode="simple-table-colspan"/><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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='th'] | *[local-name()='td']" mode="simple-table-colspan">
6371
+ </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">
6315
6372
  <xsl:choose>
6316
6373
  <xsl:when test="@colspan">
6317
6374
  <xsl:variable name="td">
@@ -6333,16 +6390,16 @@
6333
6390
  </xsl:element>
6334
6391
  </xsl:otherwise>
6335
6392
  </xsl:choose>
6336
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="@colspan" mode="simple-table-colspan"/><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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='tr']" mode="simple-table-colspan">
6393
+ </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">
6337
6394
  <xsl:element name="tr">
6338
6395
  <xsl:apply-templates select="@*" mode="simple-table-colspan"/>
6339
6396
  <xsl:apply-templates mode="simple-table-colspan"/>
6340
6397
  </xsl:element>
6341
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="@*|node()" mode="simple-table-colspan">
6398
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="@*|node()" mode="simple-table-colspan">
6342
6399
  <xsl:copy>
6343
6400
  <xsl:apply-templates select="@*|node()" mode="simple-table-colspan"/>
6344
6401
  </xsl:copy>
6345
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" name="repeatNode">
6402
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="repeatNode">
6346
6403
  <xsl:param name="count"/>
6347
6404
  <xsl:param name="node"/>
6348
6405
 
@@ -6353,18 +6410,18 @@
6353
6410
  </xsl:call-template>
6354
6411
  <xsl:copy-of select="$node"/>
6355
6412
  </xsl:if>
6356
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="@*|node()" mode="simple-table-rowspan">
6413
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="@*|node()" mode="simple-table-rowspan">
6357
6414
  <xsl:copy>
6358
6415
  <xsl:apply-templates select="@*|node()" mode="simple-table-rowspan"/>
6359
6416
  </xsl:copy>
6360
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="tbody" mode="simple-table-rowspan">
6417
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="tbody" mode="simple-table-rowspan">
6361
6418
  <xsl:copy>
6362
6419
  <xsl:copy-of select="tr[1]"/>
6363
6420
  <xsl:apply-templates select="tr[2]" mode="simple-table-rowspan">
6364
6421
  <xsl:with-param name="previousRow" select="tr[1]"/>
6365
6422
  </xsl:apply-templates>
6366
6423
  </xsl:copy>
6367
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="tr" mode="simple-table-rowspan">
6424
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="tr" mode="simple-table-rowspan">
6368
6425
  <xsl:param name="previousRow"/>
6369
6426
  <xsl:variable name="currentRow" select="."/>
6370
6427
 
@@ -6398,13 +6455,13 @@
6398
6455
  <xsl:apply-templates select="following-sibling::tr[1]" mode="simple-table-rowspan">
6399
6456
  <xsl:with-param name="previousRow" select="$newRow"/>
6400
6457
  </xsl:apply-templates>
6401
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" name="getLang">
6458
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="getLang">
6402
6459
  <xsl:variable name="language" select="//*[local-name()='bibdata']//*[local-name()='language']"/>
6403
6460
  <xsl:choose>
6404
6461
  <xsl:when test="$language = 'English'">en</xsl:when>
6405
6462
  <xsl:otherwise><xsl:value-of select="$language"/></xsl:otherwise>
6406
6463
  </xsl:choose>
6407
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" name="capitalizeWords">
6464
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="capitalizeWords">
6408
6465
  <xsl:param name="str"/>
6409
6466
  <xsl:variable name="str2" select="translate($str, '-', ' ')"/>
6410
6467
  <xsl:choose>
@@ -6422,19 +6479,19 @@
6422
6479
  <xsl:value-of select="substring($str2, 2)"/>
6423
6480
  </xsl:otherwise>
6424
6481
  </xsl:choose>
6425
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="mathml:math">
6482
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="mathml:math">
6426
6483
  <fo:inline font-family="STIX2Math">
6427
6484
  <fo:instream-foreign-object fox:alt-text="Math">
6428
6485
  <xsl:copy-of select="."/>
6429
6486
  </fo:instream-foreign-object>
6430
6487
  </fo:inline>
6431
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='localityStack']">
6488
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='localityStack']">
6432
6489
  <xsl:for-each select="*[local-name()='locality']">
6433
6490
  <xsl:if test="position() =1"><xsl:text>, </xsl:text></xsl:if>
6434
6491
  <xsl:apply-templates select="."/>
6435
6492
  <xsl:if test="position() != last()"><xsl:text>; </xsl:text></xsl:if>
6436
6493
  </xsl:for-each>
6437
- </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" xmlns:ogc="https://www.metanorma.org/ns/ogc" match="*[local-name()='link']" name="link">
6494
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='link']" name="link">
6438
6495
  <xsl:variable name="target">
6439
6496
  <xsl:choose>
6440
6497
  <xsl:when test="starts-with(normalize-space(@target), 'mailto:')">
@@ -6464,4 +6521,122 @@
6464
6521
  </xsl:otherwise>
6465
6522
  </xsl:choose>
6466
6523
  </fo:inline>
6524
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='sourcecode']" name="sourcecode">
6525
+ <fo:block xsl:use-attribute-sets="sourcecode-style">
6526
+ <!-- <xsl:choose>
6527
+ <xsl:when test="@lang = 'en'"></xsl:when>
6528
+ <xsl:otherwise> -->
6529
+ <xsl:attribute name="white-space">pre</xsl:attribute>
6530
+ <xsl:attribute name="wrap-option">wrap</xsl:attribute>
6531
+ <!-- </xsl:otherwise>
6532
+ </xsl:choose> -->
6533
+ <xsl:apply-templates/>
6534
+ </fo:block>
6535
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='bookmark']">
6536
+ <fo:inline id="{@id}"/>
6537
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='appendix']">
6538
+ <fo:block id="{@id}" xsl:use-attribute-sets="appendix-style">
6539
+ <fo:inline padding-right="5mm"><xsl:value-of select="$title-appendix"/> <xsl:number/></fo:inline>
6540
+ <xsl:apply-templates select="*[local-name()='title']" mode="process"/>
6541
+ </fo:block>
6542
+ <xsl:apply-templates/>
6543
+ </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">
6544
+ <fo:inline><xsl:apply-templates/></fo:inline>
6545
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name()='appendix']//*[local-name()='example']">
6546
+ <fo:block xsl:use-attribute-sets="appendix-example-style">
6547
+ <xsl:variable name="claims_id" select="ancestor::*[local-name()='clause'][1]/@id"/>
6548
+ <xsl:value-of select="$title-example"/>
6549
+ <xsl:if test="count(ancestor::*[local-name()='clause'][1]//*[local-name()='example']) &gt; 1">
6550
+ <xsl:number count="*[local-name()='example'][ancestor::*[local-name()='clause'][@id = $claims_id]]" level="any"/><xsl:text> </xsl:text>
6551
+ </xsl:if>
6552
+ <xsl:if test="*[local-name()='name']">
6553
+ <xsl:text>— </xsl:text><xsl:apply-templates select="*[local-name()='name']" mode="process"/>
6554
+ </xsl:if>
6555
+ </fo:block>
6556
+ <xsl:apply-templates/>
6557
+ </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">
6558
+ <fo:inline><xsl:apply-templates/></fo:inline>
6559
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name() = 'callout']">
6560
+ <fo:basic-link internal-destination="{@target}" fox:alt-text="{@target}">&lt;<xsl:apply-templates/>&gt;</fo:basic-link>
6561
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name() = 'annotation']">
6562
+ <xsl:variable name="annotation-id" select="@id"/>
6563
+ <xsl:variable name="callout" select="//*[@target = $annotation-id]/text()"/>
6564
+ <fo:block id="{$annotation-id}" white-space="nowrap">
6565
+ <fo:inline>
6566
+ <xsl:apply-templates>
6567
+ <xsl:with-param name="callout" select="concat('&lt;', $callout, '&gt; ')"/>
6568
+ </xsl:apply-templates>
6569
+ </fo:inline>
6570
+ </fo:block>
6571
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" match="*[local-name() = 'annotation']/*[local-name() = 'p']">
6572
+ <xsl:param name="callout"/>
6573
+ <fo:inline id="{@id}">
6574
+ <!-- for first p in annotation, put <x> -->
6575
+ <xsl:if test="not(preceding-sibling::*[local-name() = 'p'])"><xsl:value-of select="$callout"/></xsl:if>
6576
+ <xsl:apply-templates/>
6577
+ </fo:inline>
6578
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="convertDate">
6579
+ <xsl:param name="date"/>
6580
+ <xsl:param name="format" select="'short'"/>
6581
+ <xsl:variable name="year" select="substring($date, 1, 4)"/>
6582
+ <xsl:variable name="month" select="substring($date, 6, 2)"/>
6583
+ <xsl:variable name="day" select="substring($date, 9, 2)"/>
6584
+ <xsl:variable name="monthStr">
6585
+ <xsl:choose>
6586
+ <xsl:when test="$month = '01'">January</xsl:when>
6587
+ <xsl:when test="$month = '02'">February</xsl:when>
6588
+ <xsl:when test="$month = '03'">March</xsl:when>
6589
+ <xsl:when test="$month = '04'">April</xsl:when>
6590
+ <xsl:when test="$month = '05'">May</xsl:when>
6591
+ <xsl:when test="$month = '06'">June</xsl:when>
6592
+ <xsl:when test="$month = '07'">July</xsl:when>
6593
+ <xsl:when test="$month = '08'">August</xsl:when>
6594
+ <xsl:when test="$month = '09'">September</xsl:when>
6595
+ <xsl:when test="$month = '10'">October</xsl:when>
6596
+ <xsl:when test="$month = '11'">November</xsl:when>
6597
+ <xsl:when test="$month = '12'">December</xsl:when>
6598
+ </xsl:choose>
6599
+ </xsl:variable>
6600
+ <xsl:variable name="result">
6601
+ <xsl:choose>
6602
+ <xsl:when test="$format = 'short' or $day = ''">
6603
+ <xsl:value-of select="normalize-space(concat($monthStr, ' ', $year))"/>
6604
+ </xsl:when>
6605
+ <xsl:otherwise>
6606
+ <xsl:value-of select="normalize-space(concat($monthStr, ' ', $day, ', ' , $year))"/>
6607
+ </xsl:otherwise>
6608
+ </xsl:choose>
6609
+ </xsl:variable>
6610
+ <xsl:value-of select="$result"/>
6611
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="insertKeywords">
6612
+ <xsl:param name="sorting" select="'true'"/>
6613
+ <xsl:param name="charAtEnd" select="'.'"/>
6614
+ <xsl:param name="charDelim" select="', '"/>
6615
+ <xsl:choose>
6616
+ <xsl:when test="$sorting = 'true' or $sorting = 'yes'">
6617
+ <xsl:for-each select="/*/*[local-name() = 'bibdata']//*[local-name() = 'keyword']">
6618
+ <xsl:sort data-type="text" order="ascending"/>
6619
+ <xsl:call-template name="insertKeyword">
6620
+ <xsl:with-param name="charAtEnd" select="$charAtEnd"/>
6621
+ <xsl:with-param name="charDelim" select="$charDelim"/>
6622
+ </xsl:call-template>
6623
+ </xsl:for-each>
6624
+ </xsl:when>
6625
+ <xsl:otherwise>
6626
+ <xsl:for-each select="/*/*[local-name() = 'bibdata']//*[local-name() = 'keyword']">
6627
+ <xsl:call-template name="insertKeyword">
6628
+ <xsl:with-param name="charAtEnd" select="$charAtEnd"/>
6629
+ <xsl:with-param name="charDelim" select="$charDelim"/>
6630
+ </xsl:call-template>
6631
+ </xsl:for-each>
6632
+ </xsl:otherwise>
6633
+ </xsl:choose>
6634
+ </xsl:template><xsl:template xmlns:java="http://xml.apache.org/xalan/java" name="insertKeyword">
6635
+ <xsl:param name="charAtEnd"/>
6636
+ <xsl:param name="charDelim"/>
6637
+ <xsl:apply-templates/>
6638
+ <xsl:choose>
6639
+ <xsl:when test="position() != last()"><xsl:value-of select="$charDelim"/></xsl:when>
6640
+ <xsl:otherwise><xsl:value-of select="$charAtEnd"/></xsl:otherwise>
6641
+ </xsl:choose>
6467
6642
  </xsl:template></xsl:stylesheet>
@@ -1,5 +1,5 @@
1
1
  module Metanorma
2
2
  module Rsd
3
- VERSION = "1.4.7"
3
+ VERSION = "1.4.8"
4
4
  end
5
5
  end
@@ -30,7 +30,7 @@ Gem::Specification.new do |spec|
30
30
 
31
31
  spec.add_dependency "htmlentities", "~> 4.3.4"
32
32
  #spec.add_dependency "nokogiri"
33
- spec.add_dependency "metanorma-standoc", "~> 1.3.0"
33
+ spec.add_dependency "metanorma-standoc", "~> 1.4.0"
34
34
  spec.add_dependency "isodoc", "~> 1.0.0"
35
35
  spec.add_dependency 'metanorma-generic', '~> 1.4.0'
36
36
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: metanorma-rsd
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.4.7
4
+ version: 1.4.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ribose Inc.
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2020-05-26 00:00:00.000000000 Z
11
+ date: 2020-06-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: htmlentities
@@ -30,14 +30,14 @@ dependencies:
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: 1.3.0
33
+ version: 1.4.0
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: 1.3.0
40
+ version: 1.4.0
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: isodoc
43
43
  requirement: !ruby/object:Gem::Requirement