metanorma-ogc 1.3.7 → 1.4.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/asciidoctor/ogc/boilerplate.xml +6 -6
- data/lib/asciidoctor/ogc/cleanup.rb +145 -0
- data/lib/asciidoctor/ogc/converter.rb +52 -64
- data/lib/asciidoctor/ogc/front.rb +1 -1
- data/lib/asciidoctor/ogc/isodoc.rng +52 -11
- data/lib/asciidoctor/ogc/ogc.rng +13 -13
- data/lib/asciidoctor/ogc/reqt.rng +15 -4
- data/lib/asciidoctor/ogc/validate.rb +35 -20
- data/lib/isodoc/ogc/base_convert.rb +47 -10
- data/lib/isodoc/ogc/biblio.rb +57 -51
- data/lib/isodoc/ogc/html/htmlstyle.css +10 -0
- data/lib/isodoc/ogc/html/htmlstyle.scss +12 -0
- data/lib/isodoc/ogc/html/ogc.css +4 -0
- data/lib/isodoc/ogc/html/ogc.scss +4 -0
- data/lib/isodoc/ogc/i18n-en.yaml +24 -8
- data/lib/isodoc/ogc/metadata.rb +1 -1
- data/lib/isodoc/ogc/ogc.abstract-specification-topic.xsl +398 -143
- data/lib/isodoc/ogc/ogc.best-practice.xsl +398 -143
- data/lib/isodoc/ogc/ogc.change-request-supporting-document.xsl +398 -143
- data/lib/isodoc/ogc/ogc.community-practice.xsl +398 -143
- data/lib/isodoc/ogc/ogc.community-standard.xsl +398 -143
- data/lib/isodoc/ogc/ogc.discussion-paper.xsl +398 -143
- data/lib/isodoc/ogc/ogc.engineering-report.xsl +398 -143
- data/lib/isodoc/ogc/ogc.other.xsl +398 -143
- data/lib/isodoc/ogc/ogc.policy.xsl +398 -143
- data/lib/isodoc/ogc/ogc.reference-model.xsl +398 -143
- data/lib/isodoc/ogc/ogc.release-notes.xsl +398 -143
- data/lib/isodoc/ogc/ogc.standard.xsl +398 -143
- data/lib/isodoc/ogc/ogc.test-suite.xsl +398 -143
- data/lib/isodoc/ogc/ogc.user-guide.xsl +398 -143
- data/lib/isodoc/ogc/ogc.white-paper.xsl +330 -98
- data/lib/isodoc/ogc/presentation_xml_convert.rb +58 -48
- data/lib/isodoc/ogc/reqt.rb +99 -38
- data/lib/isodoc/ogc/xref.rb +59 -43
- data/lib/metanorma/ogc/processor.rb +2 -1
- data/lib/metanorma/ogc/version.rb +1 -1
- metadata +3 -2
@@ -32,6 +32,7 @@
|
|
32
32
|
<xsl:attribute name="margin-top">18pt</xsl:attribute>
|
33
33
|
<xsl:attribute name="margin-bottom">18pt</xsl:attribute>
|
34
34
|
<xsl:attribute name="line-height">110%</xsl:attribute>
|
35
|
+
<xsl:attribute name="role">H1</xsl:attribute>
|
35
36
|
</xsl:attribute-set>
|
36
37
|
|
37
38
|
<xsl:attribute-set name="title-depth2-style">
|
@@ -42,6 +43,7 @@
|
|
42
43
|
<xsl:attribute name="margin-bottom">8pt</xsl:attribute>
|
43
44
|
<xsl:attribute name="keep-with-next">always</xsl:attribute>
|
44
45
|
<xsl:attribute name="line-height">110%</xsl:attribute>
|
46
|
+
<xsl:attribute name="role">H2</xsl:attribute>
|
45
47
|
</xsl:attribute-set>
|
46
48
|
|
47
49
|
<xsl:attribute-set name="title-depth3-style">
|
@@ -51,7 +53,8 @@
|
|
51
53
|
<xsl:attribute name="color">rgb(21, 43, 77)</xsl:attribute>
|
52
54
|
<xsl:attribute name="margin-top">6pt</xsl:attribute>
|
53
55
|
<xsl:attribute name="margin-bottom">8pt</xsl:attribute>
|
54
|
-
<xsl:attribute name="keep-with-next">always</xsl:attribute>
|
56
|
+
<xsl:attribute name="keep-with-next">always</xsl:attribute>
|
57
|
+
<xsl:attribute name="role">H3</xsl:attribute>
|
55
58
|
</xsl:attribute-set>
|
56
59
|
|
57
60
|
<xsl:attribute-set name="empty-style">
|
@@ -126,7 +129,7 @@
|
|
126
129
|
|
127
130
|
<fo:block-container margin-left="-12mm" margin-right="-9mm">
|
128
131
|
<fo:block-container margin-left="0mm" margin-right="0mm">
|
129
|
-
<fo:block font-size="36pt" background-color="{$color}" color="white" margin-left="2.5mm" padding-top="1mm" padding-left="1mm">
|
132
|
+
<fo:block font-size="36pt" background-color="{$color}" color="white" margin-left="2.5mm" padding-top="1mm" padding-left="1mm" role="H1">
|
130
133
|
<xsl:apply-templates select="/ogc:ogc-standard/ogc:bibdata/ogc:title/node()"/>
|
131
134
|
</fo:block>
|
132
135
|
</fo:block-container>
|
@@ -216,43 +219,45 @@
|
|
216
219
|
<fo:block break-after="page"/>
|
217
220
|
|
218
221
|
<fo:block-container line-height="1.08" font-family="Lato">
|
219
|
-
<fo:block
|
220
|
-
<
|
221
|
-
|
222
|
-
<xsl:variable name="margin-left">3.9</xsl:variable>
|
223
|
-
<xsl:for-each select="xalan:nodeset($contents)//item[@display = 'true']">
|
224
|
-
<fo:block margin-top="8pt" margin-bottom="5pt" margin-left="{(@level - 1) * $margin-left}mm" text-align-last="justify">
|
225
|
-
<fo:basic-link internal-destination="{@id}" fox:alt-text="{title}">
|
226
|
-
<xsl:if test="@section != ''">
|
227
|
-
<xsl:value-of select="@section"/><xsl:text> </xsl:text>
|
228
|
-
</xsl:if>
|
229
|
-
<xsl:apply-templates select="title"/>
|
230
|
-
<fo:inline keep-together.within-line="always">
|
231
|
-
<fo:leader leader-pattern="dots"/>
|
232
|
-
<fo:inline><fo:page-number-citation ref-id="{@id}"/></fo:inline>
|
233
|
-
</fo:inline>
|
234
|
-
</fo:basic-link>
|
235
|
-
</fo:block>
|
236
|
-
</xsl:for-each>
|
237
|
-
|
238
|
-
<xsl:if test="//ogc:figure[@id and ogc:name] or //ogc:table[@id and ogc:name]">
|
239
|
-
<fo:block font-size="11pt" margin-top="8pt"> </fo:block>
|
240
|
-
<fo:block font-size="11pt" margin-top="8pt"> </fo:block>
|
241
|
-
<fo:block xsl:use-attribute-sets="title-toc-style">
|
242
|
-
<xsl:text>Table of Figures</xsl:text>
|
222
|
+
<fo:block role="TOC">
|
223
|
+
<fo:block xsl:use-attribute-sets="title-toc-style" role="H1">
|
224
|
+
<xsl:text>Table of Contents</xsl:text>
|
243
225
|
</fo:block>
|
244
|
-
<xsl:
|
245
|
-
|
246
|
-
|
247
|
-
|
226
|
+
<xsl:variable name="margin-left">3.9</xsl:variable>
|
227
|
+
<xsl:for-each select="xalan:nodeset($contents)//item[@display = 'true']">
|
228
|
+
<fo:block margin-top="8pt" margin-bottom="5pt" margin-left="{(@level - 1) * $margin-left}mm" text-align-last="justify" role="TOCI">
|
229
|
+
<fo:basic-link internal-destination="{@id}" fox:alt-text="{title}">
|
230
|
+
<xsl:if test="@section != ''">
|
231
|
+
<xsl:value-of select="@section"/><xsl:text> </xsl:text>
|
232
|
+
</xsl:if>
|
233
|
+
<xsl:apply-templates select="title"/>
|
248
234
|
<fo:inline keep-together.within-line="always">
|
249
235
|
<fo:leader leader-pattern="dots"/>
|
250
|
-
<fo:page-number-citation ref-id="{@id}"
|
236
|
+
<fo:inline><fo:page-number-citation ref-id="{@id}"/></fo:inline>
|
251
237
|
</fo:inline>
|
252
238
|
</fo:basic-link>
|
253
239
|
</fo:block>
|
254
240
|
</xsl:for-each>
|
255
|
-
|
241
|
+
|
242
|
+
<xsl:if test="//ogc:figure[@id and ogc:name] or //ogc:table[@id and ogc:name]">
|
243
|
+
<fo:block font-size="11pt" margin-top="8pt"> </fo:block>
|
244
|
+
<fo:block font-size="11pt" margin-top="8pt"> </fo:block>
|
245
|
+
<fo:block xsl:use-attribute-sets="title-toc-style">
|
246
|
+
<xsl:text>Table of Figures</xsl:text>
|
247
|
+
</fo:block>
|
248
|
+
<xsl:for-each select="//ogc:figure[@id and ogc:name] | //ogc:table[@id and ogc:name]">
|
249
|
+
<fo:block margin-top="8pt" margin-bottom="5pt" text-align-last="justify" role="TOCI">
|
250
|
+
<fo:basic-link internal-destination="{@id}" fox:alt-text="{ogc:name}">
|
251
|
+
<xsl:apply-templates select="ogc:name" mode="contents"/>
|
252
|
+
<fo:inline keep-together.within-line="always">
|
253
|
+
<fo:leader leader-pattern="dots"/>
|
254
|
+
<fo:page-number-citation ref-id="{@id}"/>
|
255
|
+
</fo:inline>
|
256
|
+
</fo:basic-link>
|
257
|
+
</fo:block>
|
258
|
+
</xsl:for-each>
|
259
|
+
</xsl:if>
|
260
|
+
</fo:block>
|
256
261
|
</fo:block-container>
|
257
262
|
|
258
263
|
|
@@ -417,7 +422,10 @@
|
|
417
422
|
</xsl:template>
|
418
423
|
|
419
424
|
<xsl:template match="ogc:license-statement//ogc:title">
|
420
|
-
<
|
425
|
+
<xsl:variable name="level">
|
426
|
+
<xsl:call-template name="getLevel"/>
|
427
|
+
</xsl:variable>
|
428
|
+
<fo:block font-family="Lato" text-align="center" font-weight="bold" margin-top="4pt" role="H{$level}">
|
421
429
|
<xsl:apply-templates/>
|
422
430
|
</fo:block>
|
423
431
|
</xsl:template>
|
@@ -450,7 +458,10 @@
|
|
450
458
|
</xsl:template>
|
451
459
|
|
452
460
|
<xsl:template match="ogc:copyright-statement//ogc:title | ogc:legal-statement//ogc:title">
|
453
|
-
<
|
461
|
+
<xsl:variable name="level">
|
462
|
+
<xsl:call-template name="getLevel"/>
|
463
|
+
</xsl:variable>
|
464
|
+
<fo:block font-family="Lato" text-align="center" font-weight="bold" role="H{$level}">
|
454
465
|
<xsl:apply-templates/>
|
455
466
|
</fo:block>
|
456
467
|
</xsl:template>
|
@@ -489,8 +500,9 @@
|
|
489
500
|
<!-- ====== -->
|
490
501
|
|
491
502
|
<xsl:template match="ogc:annex/ogc:title">
|
492
|
-
<fo:block xsl:use-attribute-sets="title-depth1-style">
|
503
|
+
<fo:block xsl:use-attribute-sets="title-depth1-style" role="H1">
|
493
504
|
<xsl:apply-templates/>
|
505
|
+
<xsl:apply-templates select="following-sibling::*[1][local-name() = 'variant-title'][@type = 'sub']" mode="subtitle"/>
|
494
506
|
</fo:block>
|
495
507
|
</xsl:template>
|
496
508
|
|
@@ -520,7 +532,7 @@
|
|
520
532
|
</fo:inline>
|
521
533
|
</xsl:when>
|
522
534
|
<xsl:otherwise>
|
523
|
-
<fo:inline font-family="Lato">
|
535
|
+
<fo:inline font-family="Lato" role="H{$level}">
|
524
536
|
<xsl:apply-templates/>
|
525
537
|
</fo:inline>
|
526
538
|
</xsl:otherwise>
|
@@ -531,21 +543,25 @@
|
|
531
543
|
<xsl:when test="$level = 1">
|
532
544
|
<fo:block xsl:use-attribute-sets="title-depth1-style">
|
533
545
|
<xsl:apply-templates/>
|
546
|
+
<xsl:apply-templates select="following-sibling::*[1][local-name() = 'variant-title'][@type = 'sub']" mode="subtitle"/>
|
534
547
|
</fo:block>
|
535
548
|
</xsl:when>
|
536
549
|
<xsl:when test="$level = 2">
|
537
550
|
<fo:block xsl:use-attribute-sets="title-depth2-style">
|
538
551
|
<xsl:apply-templates/>
|
552
|
+
<xsl:apply-templates select="following-sibling::*[1][local-name() = 'variant-title'][@type = 'sub']" mode="subtitle"/>
|
539
553
|
</fo:block>
|
540
554
|
</xsl:when>
|
541
555
|
<xsl:when test="$level = 3">
|
542
556
|
<fo:block xsl:use-attribute-sets="title-depth3-style">
|
543
557
|
<xsl:apply-templates/>
|
558
|
+
<xsl:apply-templates select="following-sibling::*[1][local-name() = 'variant-title'][@type = 'sub']" mode="subtitle"/>
|
544
559
|
</fo:block>
|
545
560
|
</xsl:when>
|
546
561
|
<xsl:otherwise>
|
547
|
-
<fo:block font-family="Lato">
|
562
|
+
<fo:block font-family="Lato" role="H{$level}">
|
548
563
|
<xsl:apply-templates/>
|
564
|
+
<xsl:apply-templates select="following-sibling::*[1][local-name() = 'variant-title'][@type = 'sub']" mode="subtitle"/>
|
549
565
|
</fo:block>
|
550
566
|
</xsl:otherwise>
|
551
567
|
</xsl:choose>
|
@@ -751,7 +767,10 @@
|
|
751
767
|
<xsl:otherwise>12pt</xsl:otherwise>
|
752
768
|
</xsl:choose>
|
753
769
|
</xsl:variable>
|
754
|
-
<
|
770
|
+
<xsl:variable name="levelTerm">
|
771
|
+
<xsl:call-template name="getLevelTermName"/>
|
772
|
+
</xsl:variable>
|
773
|
+
<fo:block font-size="{$font-size}" role="H{$levelTerm}">
|
755
774
|
<fo:block font-weight="bold" keep-with-next="always">
|
756
775
|
<xsl:apply-templates select="ancestor::ogc:term/ogc:name" mode="presentation"/>
|
757
776
|
</fo:block>
|
@@ -861,13 +880,13 @@
|
|
861
880
|
</fo:block>
|
862
881
|
</fo:static-content>
|
863
882
|
|
864
|
-
<fo:static-content flow-name="header">
|
883
|
+
<fo:static-content flow-name="header" role="artifact">
|
865
884
|
<fo:block-container height="16.5mm" background-color="{$color}">
|
866
885
|
<fo:block> </fo:block>
|
867
886
|
</fo:block-container>
|
868
887
|
</fo:static-content>
|
869
888
|
|
870
|
-
<fo:static-content flow-name="footer">
|
889
|
+
<fo:static-content flow-name="footer" role="artifact">
|
871
890
|
<fo:block-container height="100%" display-align="after">
|
872
891
|
<fo:block-container height="23.5mm" background-color="{$color}" color="rgb(231, 230, 230)" display-align="after">
|
873
892
|
<fo:block-container margin-left="1in" margin-right="1in">
|
@@ -1072,6 +1091,7 @@
|
|
1072
1091
|
</xsl:attribute-set><xsl:attribute-set name="sourcecode-style">
|
1073
1092
|
<xsl:attribute name="white-space">pre</xsl:attribute>
|
1074
1093
|
<xsl:attribute name="wrap-option">wrap</xsl:attribute>
|
1094
|
+
<xsl:attribute name="role">Code</xsl:attribute>
|
1075
1095
|
|
1076
1096
|
|
1077
1097
|
|
@@ -1080,7 +1100,7 @@
|
|
1080
1100
|
|
1081
1101
|
|
1082
1102
|
|
1083
|
-
<xsl:attribute name="font-family">Courier</xsl:attribute>
|
1103
|
+
<xsl:attribute name="font-family">Courier New</xsl:attribute>
|
1084
1104
|
<xsl:attribute name="margin-bottom">6pt</xsl:attribute>
|
1085
1105
|
<xsl:attribute name="keep-with-next">always</xsl:attribute>
|
1086
1106
|
<xsl:attribute name="line-height">113%</xsl:attribute>
|
@@ -1124,8 +1144,13 @@
|
|
1124
1144
|
|
1125
1145
|
<xsl:attribute name="margin-bottom">12pt</xsl:attribute>
|
1126
1146
|
|
1127
|
-
</xsl:attribute-set><xsl:attribute-set name="
|
1128
|
-
</xsl:attribute-set><xsl:attribute-set name="
|
1147
|
+
</xsl:attribute-set><xsl:attribute-set name="subject-style">
|
1148
|
+
</xsl:attribute-set><xsl:attribute-set name="inherit-style">
|
1149
|
+
</xsl:attribute-set><xsl:attribute-set name="description-style">
|
1150
|
+
</xsl:attribute-set><xsl:attribute-set name="specification-style">
|
1151
|
+
</xsl:attribute-set><xsl:attribute-set name="measurement-target-style">
|
1152
|
+
</xsl:attribute-set><xsl:attribute-set name="verification-style">
|
1153
|
+
</xsl:attribute-set><xsl:attribute-set name="import-style">
|
1129
1154
|
</xsl:attribute-set><xsl:attribute-set name="recommendation-style">
|
1130
1155
|
|
1131
1156
|
<xsl:attribute name="margin-top">6pt</xsl:attribute>
|
@@ -1212,6 +1237,7 @@
|
|
1212
1237
|
|
1213
1238
|
|
1214
1239
|
|
1240
|
+
|
1215
1241
|
|
1216
1242
|
<xsl:attribute name="margin-bottom">14pt</xsl:attribute>
|
1217
1243
|
|
@@ -1228,7 +1254,9 @@
|
|
1228
1254
|
|
1229
1255
|
|
1230
1256
|
|
1231
|
-
</xsl:attribute-set><xsl:
|
1257
|
+
</xsl:attribute-set><xsl:variable name="table-border_">
|
1258
|
+
|
1259
|
+
</xsl:variable><xsl:variable name="table-border" select="normalize-space($table-border_)"/><xsl:attribute-set name="table-name-style">
|
1232
1260
|
<xsl:attribute name="keep-with-next">always</xsl:attribute>
|
1233
1261
|
|
1234
1262
|
|
@@ -1362,7 +1390,8 @@
|
|
1362
1390
|
|
1363
1391
|
|
1364
1392
|
|
1365
|
-
</xsl:attribute-set><xsl:attribute-set name="quote-style">
|
1393
|
+
</xsl:attribute-set><xsl:attribute-set name="quote-style">
|
1394
|
+
<xsl:attribute name="role">BlockQuote</xsl:attribute>
|
1366
1395
|
|
1367
1396
|
<xsl:attribute name="margin-top">12pt</xsl:attribute>
|
1368
1397
|
<xsl:attribute name="margin-left">13mm</xsl:attribute>
|
@@ -1461,7 +1490,7 @@
|
|
1461
1490
|
</xsl:attribute-set><xsl:attribute-set name="tt-style">
|
1462
1491
|
|
1463
1492
|
|
1464
|
-
<xsl:attribute name="font-family">Courier</xsl:attribute>
|
1493
|
+
<xsl:attribute name="font-family">Courier New</xsl:attribute>
|
1465
1494
|
|
1466
1495
|
|
1467
1496
|
</xsl:attribute-set><xsl:attribute-set name="sourcecode-name-style">
|
@@ -1569,9 +1598,13 @@
|
|
1569
1598
|
<fo:block> </fo:block>
|
1570
1599
|
</xsl:if> -->
|
1571
1600
|
|
1601
|
+
|
1602
|
+
<!-- Display table's name before table as standalone block -->
|
1572
1603
|
<!-- $namespace = 'iso' or -->
|
1573
1604
|
|
1574
|
-
|
1605
|
+
|
1606
|
+
|
1607
|
+
|
1575
1608
|
|
1576
1609
|
<xsl:call-template name="fn_name_display"/>
|
1577
1610
|
|
@@ -1648,6 +1681,12 @@
|
|
1648
1681
|
|
1649
1682
|
|
1650
1683
|
|
1684
|
+
|
1685
|
+
|
1686
|
+
|
1687
|
+
<!-- display table's name before table for PAS inside block-container (2-columnn layout) -->
|
1688
|
+
|
1689
|
+
|
1651
1690
|
<xsl:variable name="table_width">
|
1652
1691
|
<!-- for centered table always 100% (@width will be set for middle/second cell of outer table) -->
|
1653
1692
|
|
@@ -1672,6 +1711,7 @@
|
|
1672
1711
|
|
1673
1712
|
|
1674
1713
|
|
1714
|
+
|
1675
1715
|
<attribute name="margin-left">0mm</attribute>
|
1676
1716
|
<attribute name="margin-right">0mm</attribute>
|
1677
1717
|
|
@@ -1697,6 +1737,8 @@
|
|
1697
1737
|
<xsl:attribute name="border-bottom">0pt solid black</xsl:attribute> <!-- set 0pt border, because there is a separete table below for footer -->
|
1698
1738
|
</xsl:if>
|
1699
1739
|
|
1740
|
+
|
1741
|
+
|
1700
1742
|
<xsl:choose>
|
1701
1743
|
<xsl:when test="*[local-name()='colgroup']/*[local-name()='col']">
|
1702
1744
|
<xsl:for-each select="*[local-name()='colgroup']/*[local-name()='col']">
|
@@ -1983,9 +2025,9 @@
|
|
1983
2025
|
<xsl:apply-templates select="ancestor::*[local-name()='table']/*[local-name()='name']" mode="presentation">
|
1984
2026
|
<xsl:with-param name="continued">true</xsl:with-param>
|
1985
2027
|
</xsl:apply-templates>
|
1986
|
-
|
1987
|
-
|
1988
|
-
|
2028
|
+
|
2029
|
+
|
2030
|
+
|
1989
2031
|
|
1990
2032
|
</fo:table-cell>
|
1991
2033
|
</fo:table-row>
|
@@ -2067,7 +2109,11 @@
|
|
2067
2109
|
|
2068
2110
|
<xsl:variable name="isNoteOrFnExist" select="../*[local-name()='note'] or ..//*[local-name()='fn'][local-name(..) != 'name']"/>
|
2069
2111
|
|
2070
|
-
<xsl:
|
2112
|
+
<xsl:variable name="isNoteOrFnExistShowAfterTable">
|
2113
|
+
|
2114
|
+
</xsl:variable>
|
2115
|
+
|
2116
|
+
<xsl:if test="$isNoteOrFnExist = 'true' or normalize-space($isNoteOrFnExistShowAfterTable) = 'true'">
|
2071
2117
|
|
2072
2118
|
<xsl:variable name="cols-count">
|
2073
2119
|
<xsl:choose>
|
@@ -2096,6 +2142,8 @@
|
|
2096
2142
|
</xsl:choose>
|
2097
2143
|
</xsl:for-each>
|
2098
2144
|
|
2145
|
+
|
2146
|
+
|
2099
2147
|
<xsl:choose>
|
2100
2148
|
<xsl:when test="xalan:nodeset($colgroup)//*[local-name()='col']">
|
2101
2149
|
<xsl:for-each select="xalan:nodeset($colgroup)//*[local-name()='col']">
|
@@ -2132,6 +2180,7 @@
|
|
2132
2180
|
|
2133
2181
|
|
2134
2182
|
|
2183
|
+
|
2135
2184
|
<!-- for BSI (not PAS) display Notes before footnotes -->
|
2136
2185
|
|
2137
2186
|
|
@@ -2205,6 +2254,19 @@
|
|
2205
2254
|
|
2206
2255
|
</fo:table-body>
|
2207
2256
|
|
2257
|
+
</xsl:template><xsl:template match="*[local-name()='table']/*[local-name()='name']/text()[1]" priority="2" mode="presentation_name">
|
2258
|
+
<xsl:choose>
|
2259
|
+
<xsl:when test="substring-after(., '—') != ''">
|
2260
|
+
<xsl:text>—</xsl:text><xsl:value-of select="substring-after(., '—')"/>
|
2261
|
+
</xsl:when>
|
2262
|
+
<xsl:otherwise>
|
2263
|
+
<xsl:value-of select="."/>
|
2264
|
+
</xsl:otherwise>
|
2265
|
+
</xsl:choose>
|
2266
|
+
</xsl:template><xsl:template match="*[local-name()='table']/*[local-name()='name']" mode="presentation_name">
|
2267
|
+
<xsl:apply-templates mode="presentation_name"/>
|
2268
|
+
</xsl:template><xsl:template match="*[local-name()='table']/*[local-name()='name']/node()" mode="presentation_name">
|
2269
|
+
<xsl:apply-templates select="."/>
|
2208
2270
|
</xsl:template><xsl:template match="*[local-name()='tr']">
|
2209
2271
|
<xsl:variable name="parent-name" select="local-name(..)"/>
|
2210
2272
|
<!-- <xsl:variable name="namespace" select="substring-before(name(/*), '-')"/> -->
|
@@ -2217,6 +2279,8 @@
|
|
2217
2279
|
|
2218
2280
|
|
2219
2281
|
|
2282
|
+
|
2283
|
+
|
2220
2284
|
</xsl:if>
|
2221
2285
|
<xsl:if test="$parent-name = 'tfoot'">
|
2222
2286
|
|
@@ -2231,6 +2295,8 @@
|
|
2231
2295
|
|
2232
2296
|
|
2233
2297
|
|
2298
|
+
|
2299
|
+
|
2234
2300
|
<!-- <xsl:if test="$namespace = 'bipm'">
|
2235
2301
|
<xsl:attribute name="height">8mm</xsl:attribute>
|
2236
2302
|
</xsl:if> -->
|
@@ -2383,20 +2449,12 @@
|
|
2383
2449
|
<xsl:apply-templates/>
|
2384
2450
|
</xsl:template><xsl:template name="fn_display">
|
2385
2451
|
<xsl:variable name="references">
|
2452
|
+
|
2386
2453
|
<xsl:for-each select="..//*[local-name()='fn'][local-name(..) != 'name']">
|
2387
|
-
<
|
2388
|
-
|
2389
|
-
|
2390
|
-
<xsl:attribute name="id">
|
2391
|
-
<xsl:value-of select="@reference"/>
|
2392
|
-
<xsl:text>_</xsl:text>
|
2393
|
-
<xsl:value-of select="ancestor::*[local-name()='table'][1]/@id"/>
|
2394
|
-
</xsl:attribute>
|
2395
|
-
|
2396
|
-
<xsl:apply-templates/>
|
2397
|
-
</fn>
|
2454
|
+
<xsl:call-template name="create_fn"/>
|
2398
2455
|
</xsl:for-each>
|
2399
2456
|
</xsl:variable>
|
2457
|
+
|
2400
2458
|
<xsl:for-each select="xalan:nodeset($references)//fn">
|
2401
2459
|
<xsl:variable name="reference" select="@reference"/>
|
2402
2460
|
<xsl:if test="not(preceding-sibling::*[@reference = $reference])"> <!-- only unique reference puts in note-->
|
@@ -2432,6 +2490,18 @@
|
|
2432
2490
|
</fo:block>
|
2433
2491
|
</xsl:if>
|
2434
2492
|
</xsl:for-each>
|
2493
|
+
</xsl:template><xsl:template name="create_fn">
|
2494
|
+
<fn reference="{@reference}" id="{@reference}_{ancestor::*[@id][1]/@id}">
|
2495
|
+
|
2496
|
+
|
2497
|
+
<xsl:attribute name="id">
|
2498
|
+
<xsl:value-of select="@reference"/>
|
2499
|
+
<xsl:text>_</xsl:text>
|
2500
|
+
<xsl:value-of select="ancestor::*[local-name()='table'][1]/@id"/>
|
2501
|
+
</xsl:attribute>
|
2502
|
+
|
2503
|
+
<xsl:apply-templates/>
|
2504
|
+
</fn>
|
2435
2505
|
</xsl:template><xsl:template name="fn_name_display">
|
2436
2506
|
<!-- <xsl:variable name="references">
|
2437
2507
|
<xsl:for-each select="*[local-name()='name']//*[local-name()='fn']">
|
@@ -3424,16 +3494,68 @@
|
|
3424
3494
|
<xsl:with-param name="isDeleted" select="$isDeleted"/>
|
3425
3495
|
</xsl:call-template>
|
3426
3496
|
|
3497
|
+
|
3498
|
+
|
3427
3499
|
<xsl:variable name="mathml">
|
3428
3500
|
<xsl:apply-templates select="." mode="mathml"/>
|
3429
3501
|
</xsl:variable>
|
3430
3502
|
<fo:instream-foreign-object fox:alt-text="Math">
|
3431
3503
|
|
3432
3504
|
|
3505
|
+
<xsl:variable name="comment_text_following" select="following-sibling::node()[1][self::comment()]"/>
|
3506
|
+
<xsl:variable name="comment_text_">
|
3507
|
+
<xsl:choose>
|
3508
|
+
<xsl:when test="normalize-space($comment_text_following) != ''">
|
3509
|
+
<xsl:value-of select="$comment_text_following"/>
|
3510
|
+
</xsl:when>
|
3511
|
+
<xsl:otherwise>
|
3512
|
+
<xsl:value-of select="normalize-space(translate(.,' ',' '))"/>
|
3513
|
+
</xsl:otherwise>
|
3514
|
+
</xsl:choose>
|
3515
|
+
</xsl:variable>
|
3516
|
+
<xsl:variable name="comment_text" select="java:org.metanorma.fop.Util.unescape($comment_text_)"/>
|
3517
|
+
|
3518
|
+
<xsl:if test="normalize-space($comment_text) != ''">
|
3519
|
+
<!-- put Mathin Alternate Text -->
|
3520
|
+
<xsl:attribute name="fox:alt-text">
|
3521
|
+
<xsl:value-of select="java:org.metanorma.fop.Util.unescape($comment_text)"/>
|
3522
|
+
</xsl:attribute>
|
3523
|
+
</xsl:if>
|
3524
|
+
|
3525
|
+
<xsl:variable name="mathml_content">
|
3526
|
+
<xsl:apply-templates select="." mode="mathml_actual_text"/>
|
3527
|
+
</xsl:variable>
|
3528
|
+
<!-- put MathML in Actual Text -->
|
3529
|
+
<xsl:attribute name="fox:actual-text">
|
3530
|
+
<xsl:value-of select="$mathml_content"/>
|
3531
|
+
</xsl:attribute>
|
3532
|
+
|
3533
|
+
|
3433
3534
|
<!-- <xsl:copy-of select="."/> -->
|
3434
3535
|
<xsl:copy-of select="xalan:nodeset($mathml)"/>
|
3435
3536
|
</fo:instream-foreign-object>
|
3436
3537
|
</fo:inline>
|
3538
|
+
</xsl:template><xsl:template match="mathml:*" mode="mathml_actual_text">
|
3539
|
+
<!-- <xsl:text>a+b</xsl:text> -->
|
3540
|
+
<xsl:text><</xsl:text>
|
3541
|
+
<xsl:value-of select="local-name()"/>
|
3542
|
+
<xsl:if test="local-name() = 'math'">
|
3543
|
+
<xsl:text> xmlns="http://www.w3.org/1998/Math/MathML"</xsl:text>
|
3544
|
+
</xsl:if>
|
3545
|
+
<xsl:for-each select="@*">
|
3546
|
+
<xsl:text> </xsl:text>
|
3547
|
+
<xsl:value-of select="local-name()"/>
|
3548
|
+
<xsl:text>="</xsl:text>
|
3549
|
+
<xsl:value-of select="."/>
|
3550
|
+
<xsl:text>"</xsl:text>
|
3551
|
+
</xsl:for-each>
|
3552
|
+
<xsl:text>></xsl:text>
|
3553
|
+
<xsl:apply-templates mode="mathml_actual_text"/>
|
3554
|
+
<xsl:text></</xsl:text>
|
3555
|
+
<xsl:value-of select="local-name()"/>
|
3556
|
+
<xsl:text>></xsl:text>
|
3557
|
+
</xsl:template><xsl:template match="text()" mode="mathml_actual_text">
|
3558
|
+
<xsl:value-of select="normalize-space()"/>
|
3437
3559
|
</xsl:template><xsl:template match="@*|node()" mode="mathml">
|
3438
3560
|
<xsl:copy>
|
3439
3561
|
<xsl:apply-templates select="@*|node()" mode="mathml"/>
|
@@ -3443,19 +3565,6 @@
|
|
3443
3565
|
<!-- replace start and end spaces to non-break space -->
|
3444
3566
|
<xsl:value-of select="java:replaceAll(java:java.lang.String.new(.),'(^ )|( $)',' ')"/>
|
3445
3567
|
</xsl:copy>
|
3446
|
-
</xsl:template><xsl:template match="mathml:mi[. = ',' and not(following-sibling::*[1][local-name() = 'mtext' and text() = ' '])]" mode="mathml">
|
3447
|
-
<xsl:copy>
|
3448
|
-
<xsl:apply-templates select="@*|node()" mode="mathml"/>
|
3449
|
-
</xsl:copy>
|
3450
|
-
<xsl:choose>
|
3451
|
-
<!-- if in msub, then don't add space -->
|
3452
|
-
<xsl:when test="ancestor::mathml:mrow[parent::mathml:msub and preceding-sibling::*[1][self::mathml:mrow]]"/>
|
3453
|
-
<!-- if next char in digit, don't add space -->
|
3454
|
-
<xsl:when test="translate(substring(following-sibling::*[1]/text(),1,1),'0123456789','') = ''"/>
|
3455
|
-
<xsl:otherwise>
|
3456
|
-
<mathml:mspace width="0.5ex"/>
|
3457
|
-
</xsl:otherwise>
|
3458
|
-
</xsl:choose>
|
3459
3568
|
</xsl:template><xsl:template match="mathml:math/*[local-name()='unit']" mode="mathml"/><xsl:template match="mathml:math/*[local-name()='prefix']" mode="mathml"/><xsl:template match="mathml:math/*[local-name()='dimension']" mode="mathml"/><xsl:template match="mathml:math/*[local-name()='quantity']" mode="mathml"/><xsl:template match="*[local-name()='localityStack']"/><xsl:template match="*[local-name()='link']" name="link">
|
3460
3569
|
<xsl:variable name="target">
|
3461
3570
|
<xsl:choose>
|
@@ -3508,7 +3617,10 @@
|
|
3508
3617
|
</fo:block>
|
3509
3618
|
<xsl:apply-templates/>
|
3510
3619
|
</xsl:template><xsl:template match="*[local-name()='appendix']/*[local-name()='title']"/><xsl:template match="*[local-name()='appendix']/*[local-name()='title']" mode="process">
|
3511
|
-
<
|
3620
|
+
<xsl:variable name="level">
|
3621
|
+
<xsl:call-template name="getLevel"/>
|
3622
|
+
</xsl:variable>
|
3623
|
+
<fo:inline role="H{$level}"><xsl:apply-templates/></fo:inline>
|
3512
3624
|
</xsl:template><xsl:template match="*[local-name()='appendix']//*[local-name()='example']" priority="2">
|
3513
3625
|
<fo:block id="{@id}" xsl:use-attribute-sets="appendix-example-style">
|
3514
3626
|
<xsl:apply-templates select="*[local-name()='name']" mode="presentation"/>
|
@@ -3543,9 +3655,10 @@
|
|
3543
3655
|
|
3544
3656
|
</xsl:variable>
|
3545
3657
|
|
3658
|
+
<xsl:variable name="text"><xsl:apply-templates/></xsl:variable>
|
3546
3659
|
<xsl:choose>
|
3547
|
-
<xsl:when test="$lang = 'zh'"><xsl:text>、</xsl:text><xsl:value-of select="$title-modified"/><xsl:text>—</xsl:text></xsl:when>
|
3548
|
-
<xsl:otherwise><xsl:text>, </xsl:text><xsl:value-of select="$title-modified"/><xsl:text> — </xsl:text></xsl:otherwise>
|
3660
|
+
<xsl:when test="$lang = 'zh'"><xsl:text>、</xsl:text><xsl:value-of select="$title-modified"/><xsl:if test="normalize-space($text) != ''"><xsl:text>—</xsl:text></xsl:if></xsl:when>
|
3661
|
+
<xsl:otherwise><xsl:text>, </xsl:text><xsl:value-of select="$title-modified"/><xsl:if test="normalize-space($text) != ''"><xsl:text> — </xsl:text></xsl:if></xsl:otherwise>
|
3549
3662
|
</xsl:choose>
|
3550
3663
|
<xsl:apply-templates/>
|
3551
3664
|
</xsl:template><xsl:template match="*[local-name() = 'xref']">
|
@@ -3695,7 +3808,10 @@
|
|
3695
3808
|
</fo:block>
|
3696
3809
|
</xsl:template><xsl:template match="*[local-name() = 'term']/*[local-name() = 'name']"/><xsl:template match="*[local-name() = 'term']/*[local-name() = 'name']" mode="presentation">
|
3697
3810
|
<xsl:if test="normalize-space() != ''">
|
3698
|
-
<
|
3811
|
+
<xsl:variable name="level">
|
3812
|
+
<xsl:call-template name="getLevelTermName"/>
|
3813
|
+
</xsl:variable>
|
3814
|
+
<fo:inline role="H{$level}">
|
3699
3815
|
<xsl:apply-templates/>
|
3700
3816
|
<!-- <xsl:if test="$namespace = 'gb' or $namespace = 'ogc'">
|
3701
3817
|
<xsl:text>.</xsl:text>
|
@@ -3768,7 +3884,24 @@
|
|
3768
3884
|
</fo:instream-foreign-object>
|
3769
3885
|
</xsl:when>
|
3770
3886
|
<xsl:otherwise>
|
3771
|
-
<fo:external-graphic src="{$src}" fox:alt-text="Image {@alt}" xsl:use-attribute-sets="image-graphic-style"
|
3887
|
+
<fo:external-graphic src="{$src}" fox:alt-text="Image {@alt}" xsl:use-attribute-sets="image-graphic-style">
|
3888
|
+
<xsl:if test="not(@mimetype = 'image/svg+xml') and ../*[local-name() = 'name'] and not(ancestor::*[local-name() = 'table'])">
|
3889
|
+
|
3890
|
+
<xsl:variable name="img_src">
|
3891
|
+
<xsl:choose>
|
3892
|
+
<xsl:when test="not(starts-with(@src, 'data:'))"><xsl:value-of select="concat($basepath, @src)"/></xsl:when>
|
3893
|
+
<xsl:otherwise><xsl:value-of select="@src"/></xsl:otherwise>
|
3894
|
+
</xsl:choose>
|
3895
|
+
</xsl:variable>
|
3896
|
+
|
3897
|
+
<xsl:variable name="scale" select="java:org.metanorma.fop.Util.getImageScale($img_src, $width_effective, $height_effective)"/>
|
3898
|
+
<xsl:if test="number($scale) < 100">
|
3899
|
+
<xsl:attribute name="content-width"><xsl:value-of select="$scale"/>%</xsl:attribute>
|
3900
|
+
</xsl:if>
|
3901
|
+
|
3902
|
+
</xsl:if>
|
3903
|
+
|
3904
|
+
</fo:external-graphic>
|
3772
3905
|
</xsl:otherwise>
|
3773
3906
|
</xsl:choose>
|
3774
3907
|
|
@@ -3939,11 +4072,13 @@
|
|
3939
4072
|
<xsl:attribute name="width">100%</xsl:attribute>
|
3940
4073
|
<xsl:attribute name="content-height">100%</xsl:attribute>
|
3941
4074
|
<xsl:attribute name="content-width">scale-down-to-fit</xsl:attribute>
|
4075
|
+
<xsl:variable name="svg_width" select="xalan:nodeset($svg_content)/*/@width"/>
|
4076
|
+
<xsl:variable name="svg_height" select="xalan:nodeset($svg_content)/*/@height"/>
|
3942
4077
|
<!-- effective height 297 - 27.4 - 13 = 256.6 -->
|
3943
4078
|
<!-- effective width 210 - 12.5 - 25 = 172.5 -->
|
3944
4079
|
<!-- effective height / width = 1.48, 1.4 - with title -->
|
3945
|
-
<xsl:if test="
|
3946
|
-
<xsl:variable name="width" select="((
|
4080
|
+
<xsl:if test="$svg_height > ($svg_width * 1.4)"> <!-- for images with big height -->
|
4081
|
+
<xsl:variable name="width" select="(($svg_width * 1.4) div $svg_height) * 100"/>
|
3947
4082
|
<xsl:attribute name="width"><xsl:value-of select="$width"/>%</xsl:attribute>
|
3948
4083
|
</xsl:if>
|
3949
4084
|
<xsl:attribute name="scaling">uniform</xsl:attribute>
|
@@ -3960,6 +4095,23 @@
|
|
3960
4095
|
<xsl:attribute name="href" namespace="http://www.w3.org/1999/xlink">
|
3961
4096
|
<xsl:value-of select="."/>
|
3962
4097
|
</xsl:attribute>
|
4098
|
+
</xsl:template><xsl:template match="*[local-name() = 'svg'][not(@width and @height)]" mode="svg_update">
|
4099
|
+
<xsl:copy>
|
4100
|
+
<xsl:apply-templates select="@*" mode="svg_update"/>
|
4101
|
+
<xsl:variable name="viewbox">
|
4102
|
+
<xsl:call-template name="split">
|
4103
|
+
<xsl:with-param name="pText" select="@viewBox"/>
|
4104
|
+
<xsl:with-param name="sep" select="' '"/>
|
4105
|
+
</xsl:call-template>
|
4106
|
+
</xsl:variable>
|
4107
|
+
<xsl:attribute name="width">
|
4108
|
+
<xsl:value-of select="round(xalan:nodeset($viewbox)//item[3])"/>
|
4109
|
+
</xsl:attribute>
|
4110
|
+
<xsl:attribute name="height">
|
4111
|
+
<xsl:value-of select="round(xalan:nodeset($viewbox)//item[4])"/>
|
4112
|
+
</xsl:attribute>
|
4113
|
+
<xsl:apply-templates mode="svg_update"/>
|
4114
|
+
</xsl:copy>
|
3963
4115
|
</xsl:template><xsl:template match="*[local-name() = 'figure']/*[local-name() = 'image'][@mimetype = 'image/svg+xml' and @src[not(starts-with(., 'data:image/'))]]" priority="2">
|
3964
4116
|
<xsl:variable name="svg_content" select="document(@src)"/>
|
3965
4117
|
<xsl:variable name="name" select="ancestor::*[local-name() = 'figure']/*[local-name() = 'name']"/>
|
@@ -4301,6 +4453,7 @@
|
|
4301
4453
|
</xsl:when>
|
4302
4454
|
<xsl:otherwise>
|
4303
4455
|
<xsl:apply-templates/>
|
4456
|
+
<xsl:apply-templates select="following-sibling::*[1][local-name() = 'variant-title'][@type = 'sub']" mode="subtitle"/>
|
4304
4457
|
</xsl:otherwise>
|
4305
4458
|
</xsl:choose>
|
4306
4459
|
</fo:block>
|
@@ -4449,14 +4602,6 @@
|
|
4449
4602
|
<fo:block>
|
4450
4603
|
<fo:inline padding-right="3mm">Obligation</fo:inline><xsl:value-of select="."/>
|
4451
4604
|
</fo:block>
|
4452
|
-
</xsl:template><xsl:template match="*[local-name() = 'requirement']/*[local-name() = 'subject']"/><xsl:template match="*[local-name() = 'requirement']/*[local-name() = 'subject']" mode="presentation">
|
4453
|
-
<fo:block xsl:use-attribute-sets="requirement-subject-style">
|
4454
|
-
<xsl:text>Target Type </xsl:text><xsl:apply-templates/>
|
4455
|
-
</fo:block>
|
4456
|
-
</xsl:template><xsl:template match="*[local-name() = 'requirement']/*[local-name() = 'inherit']">
|
4457
|
-
<fo:block xsl:use-attribute-sets="requirement-inherit-style">
|
4458
|
-
<xsl:text>Dependency </xsl:text><xsl:apply-templates/>
|
4459
|
-
</fo:block>
|
4460
4605
|
</xsl:template><xsl:template match="*[local-name() = 'recommendation']">
|
4461
4606
|
<fo:block id="{@id}" xsl:use-attribute-sets="recommendation-style">
|
4462
4607
|
<xsl:apply-templates select="*[local-name()='name']" mode="presentation"/>
|
@@ -4473,6 +4618,38 @@
|
|
4473
4618
|
<fo:block xsl:use-attribute-sets="recommendation-label-style">
|
4474
4619
|
<xsl:apply-templates/>
|
4475
4620
|
</fo:block>
|
4621
|
+
</xsl:template><xsl:template match="*[local-name() = 'requirement']/*[local-name() = 'subject']" priority="2"/><xsl:template match="*[local-name() = 'requirement']/*[local-name() = 'subject']" mode="presentation">
|
4622
|
+
<fo:block xsl:use-attribute-sets="subject-style">
|
4623
|
+
<xsl:text>Target Type </xsl:text><xsl:apply-templates/>
|
4624
|
+
</fo:block>
|
4625
|
+
</xsl:template><xsl:template match="*[local-name() = 'subject']">
|
4626
|
+
<fo:block xsl:use-attribute-sets="subject-style">
|
4627
|
+
<xsl:text>Target Type </xsl:text><xsl:apply-templates/>
|
4628
|
+
</fo:block>
|
4629
|
+
</xsl:template><xsl:template match="*[local-name() = 'inherit'] | *[local-name() = 'component'][@class = 'inherit']">
|
4630
|
+
<fo:block xsl:use-attribute-sets="inherit-style">
|
4631
|
+
<xsl:text>Dependency </xsl:text><xsl:apply-templates/>
|
4632
|
+
</fo:block>
|
4633
|
+
</xsl:template><xsl:template match="*[local-name() = 'description'] | *[local-name() = 'component'][@class = 'description']">
|
4634
|
+
<fo:block xsl:use-attribute-sets="description-style">
|
4635
|
+
<xsl:apply-templates/>
|
4636
|
+
</fo:block>
|
4637
|
+
</xsl:template><xsl:template match="*[local-name() = 'specification'] | *[local-name() = 'component'][@class = 'specification']">
|
4638
|
+
<fo:block xsl:use-attribute-sets="specification-style">
|
4639
|
+
<xsl:apply-templates/>
|
4640
|
+
</fo:block>
|
4641
|
+
</xsl:template><xsl:template match="*[local-name() = 'measurement-target'] | *[local-name() = 'component'][@class = 'measurement-target']">
|
4642
|
+
<fo:block xsl:use-attribute-sets="measurement-target-style">
|
4643
|
+
<xsl:apply-templates/>
|
4644
|
+
</fo:block>
|
4645
|
+
</xsl:template><xsl:template match="*[local-name() = 'verification'] | *[local-name() = 'component'][@class = 'verification']">
|
4646
|
+
<fo:block xsl:use-attribute-sets="verification-style">
|
4647
|
+
<xsl:apply-templates/>
|
4648
|
+
</fo:block>
|
4649
|
+
</xsl:template><xsl:template match="*[local-name() = 'import'] | *[local-name() = 'component'][@class = 'import']">
|
4650
|
+
<fo:block xsl:use-attribute-sets="import-style">
|
4651
|
+
<xsl:apply-templates/>
|
4652
|
+
</fo:block>
|
4476
4653
|
</xsl:template><xsl:template match="*[local-name() = 'table'][@class = 'recommendation' or @class='requirement' or @class='permission']">
|
4477
4654
|
<fo:block-container margin-left="0mm" margin-right="0mm" margin-bottom="12pt">
|
4478
4655
|
<xsl:if test="ancestor::*[local-name() = 'table'][@class = 'recommendation' or @class='requirement' or @class='permission']">
|
@@ -4624,7 +4801,19 @@
|
|
4624
4801
|
</fo:inline>
|
4625
4802
|
</xsl:if>
|
4626
4803
|
</xsl:template><xsl:template match="*[local-name() = 'termexample']/*[local-name() = 'p']">
|
4627
|
-
<
|
4804
|
+
<xsl:variable name="element">inline
|
4805
|
+
|
4806
|
+
</xsl:variable>
|
4807
|
+
<xsl:choose>
|
4808
|
+
<xsl:when test="contains($element, 'block')">
|
4809
|
+
<fo:block xsl:use-attribute-sets="example-p-style">
|
4810
|
+
<xsl:apply-templates/>
|
4811
|
+
</fo:block>
|
4812
|
+
</xsl:when>
|
4813
|
+
<xsl:otherwise>
|
4814
|
+
<fo:inline><xsl:apply-templates/></fo:inline>
|
4815
|
+
</xsl:otherwise>
|
4816
|
+
</xsl:choose>
|
4628
4817
|
</xsl:template><xsl:template match="*[local-name() = 'example']">
|
4629
4818
|
<fo:block id="{@id}" xsl:use-attribute-sets="example-style">
|
4630
4819
|
|
@@ -5175,6 +5364,7 @@
|
|
5175
5364
|
</xsl:template><xsl:template match="*[local-name() = 'indexsect']//*[local-name() = 'li']" priority="4">
|
5176
5365
|
<xsl:variable name="level" select="count(ancestor::*[local-name() = 'ul'])"/>
|
5177
5366
|
<fo:block start-indent="{5 * $level}mm" text-indent="-5mm">
|
5367
|
+
|
5178
5368
|
<xsl:apply-templates/>
|
5179
5369
|
</fo:block>
|
5180
5370
|
</xsl:template><xsl:template match="*[local-name() = 'bookmark']" name="bookmark">
|
@@ -5214,7 +5404,6 @@
|
|
5214
5404
|
</xsl:template><xsl:template name="processBibitem">
|
5215
5405
|
|
5216
5406
|
|
5217
|
-
<!-- end BIPM bibitem processing-->
|
5218
5407
|
|
5219
5408
|
|
5220
5409
|
<!-- start OGC bibtem processing -->
|
@@ -5484,6 +5673,9 @@
|
|
5484
5673
|
<fo:block-container border="1pt solid black" width="50%">
|
5485
5674
|
<fo:block> </fo:block>
|
5486
5675
|
</fo:block-container>
|
5676
|
+
</xsl:template><xsl:template match="*[local-name() = 'variant-title'][@type = 'sub']"/><xsl:template match="*[local-name() = 'variant-title'][@type = 'sub']" mode="subtitle">
|
5677
|
+
<fo:inline padding-right="5mm"> </fo:inline>
|
5678
|
+
<fo:inline><xsl:apply-templates/></fo:inline>
|
5487
5679
|
</xsl:template><xsl:template name="convertDate">
|
5488
5680
|
<xsl:param name="date"/>
|
5489
5681
|
<xsl:param name="format" select="'short'"/>
|
@@ -5722,6 +5914,26 @@
|
|
5722
5914
|
<xsl:value-of select="$level"/>
|
5723
5915
|
</xsl:otherwise>
|
5724
5916
|
</xsl:choose>
|
5917
|
+
</xsl:template><xsl:template name="getLevelTermName">
|
5918
|
+
<xsl:choose>
|
5919
|
+
<xsl:when test="normalize-space(../@depth) != ''">
|
5920
|
+
<xsl:value-of select="../@depth"/>
|
5921
|
+
</xsl:when>
|
5922
|
+
<xsl:otherwise>
|
5923
|
+
<xsl:variable name="title_level_">
|
5924
|
+
<xsl:for-each select="../preceding-sibling::*[local-name() = 'title'][1]">
|
5925
|
+
<xsl:call-template name="getLevel"/>
|
5926
|
+
</xsl:for-each>
|
5927
|
+
</xsl:variable>
|
5928
|
+
<xsl:variable name="title_level" select="normalize-space($title_level_)"/>
|
5929
|
+
<xsl:choose>
|
5930
|
+
<xsl:when test="$title_level != ''"><xsl:value-of select="$title_level + 1"/></xsl:when>
|
5931
|
+
<xsl:otherwise>
|
5932
|
+
<xsl:call-template name="getLevel"/>
|
5933
|
+
</xsl:otherwise>
|
5934
|
+
</xsl:choose>
|
5935
|
+
</xsl:otherwise>
|
5936
|
+
</xsl:choose>
|
5725
5937
|
</xsl:template><xsl:template name="split">
|
5726
5938
|
<xsl:param name="pText" select="."/>
|
5727
5939
|
<xsl:param name="sep" select="','"/>
|
@@ -5819,20 +6031,40 @@
|
|
5819
6031
|
</xsl:call-template>
|
5820
6032
|
</xsl:if>
|
5821
6033
|
</xsl:template><xsl:template name="getLocalizedString">
|
5822
|
-
<xsl:param name="key"/>
|
6034
|
+
<xsl:param name="key"/>
|
6035
|
+
<xsl:param name="formatted">false</xsl:param>
|
5823
6036
|
|
5824
6037
|
<xsl:variable name="curr_lang">
|
5825
6038
|
<xsl:call-template name="getLang"/>
|
5826
6039
|
</xsl:variable>
|
5827
6040
|
|
5828
|
-
<xsl:variable name="data_value"
|
6041
|
+
<xsl:variable name="data_value">
|
6042
|
+
<xsl:choose>
|
6043
|
+
<xsl:when test="$formatted = 'true'">
|
6044
|
+
<xsl:apply-templates select="xalan:nodeset($bibdata)//*[local-name() = 'localized-string'][@key = $key and @language = $curr_lang]"/>
|
6045
|
+
</xsl:when>
|
6046
|
+
<xsl:otherwise>
|
6047
|
+
<xsl:value-of select="normalize-space(xalan:nodeset($bibdata)//*[local-name() = 'localized-string'][@key = $key and @language = $curr_lang])"/>
|
6048
|
+
</xsl:otherwise>
|
6049
|
+
</xsl:choose>
|
6050
|
+
</xsl:variable>
|
5829
6051
|
|
5830
6052
|
<xsl:choose>
|
5831
|
-
<xsl:when test="$data_value != ''">
|
5832
|
-
<xsl:
|
6053
|
+
<xsl:when test="normalize-space($data_value) != ''">
|
6054
|
+
<xsl:choose>
|
6055
|
+
<xsl:when test="$formatted = 'true'"><xsl:copy-of select="$data_value"/></xsl:when>
|
6056
|
+
<xsl:otherwise><xsl:value-of select="$data_value"/></xsl:otherwise>
|
6057
|
+
</xsl:choose>
|
5833
6058
|
</xsl:when>
|
5834
6059
|
<xsl:when test="/*/*[local-name() = 'localized-strings']/*[local-name() = 'localized-string'][@key = $key and @language = $curr_lang]">
|
5835
|
-
<xsl:
|
6060
|
+
<xsl:choose>
|
6061
|
+
<xsl:when test="$formatted = 'true'">
|
6062
|
+
<xsl:apply-templates select="/*/*[local-name() = 'localized-strings']/*[local-name() = 'localized-string'][@key = $key and @language = $curr_lang]"/>
|
6063
|
+
</xsl:when>
|
6064
|
+
<xsl:otherwise>
|
6065
|
+
<xsl:value-of select="/*/*[local-name() = 'localized-strings']/*[local-name() = 'localized-string'][@key = $key and @language = $curr_lang]"/>
|
6066
|
+
</xsl:otherwise>
|
6067
|
+
</xsl:choose>
|
5836
6068
|
</xsl:when>
|
5837
6069
|
<xsl:otherwise>
|
5838
6070
|
<xsl:variable name="key_">
|
@@ -5843,7 +6075,7 @@
|
|
5843
6075
|
<xsl:value-of select="$key_"/>
|
5844
6076
|
</xsl:otherwise>
|
5845
6077
|
</xsl:choose>
|
5846
|
-
|
6078
|
+
|
5847
6079
|
</xsl:template><xsl:template name="setTrackChangesStyles">
|
5848
6080
|
<xsl:param name="isAdded"/>
|
5849
6081
|
<xsl:param name="isDeleted"/>
|