metanorma-iho 0.3.9 → 0.3.10
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/asciidoctor/iho/isodoc.rng +23 -9
- data/lib/isodoc/iho/iho.specification.xsl +203 -79
- data/lib/isodoc/iho/iho.standard.xsl +203 -79
- data/lib/metanorma/iho/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: '0480f7645d9956c2e7ca6e83f063d006dfa34d969b82e564ffc584a88c6be1c0'
|
4
|
+
data.tar.gz: 3ae35829efc283699f516c948b0db4e0f95f2dce221a5ba5bdd79f7d5b519cb5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 53d2919df0abbd58b42035ec909239e96312d4f9d69583434b60a3e92a1cda2e4c7ddc82483b590b071123fcfe5886984a8227215e036cec5576b9327feee6b3
|
7
|
+
data.tar.gz: e1bdfe5fd0bdcc5b85f3065e29c0099d99b0334c83aefe52ee078316351a624010c4e9cc5ac47e0e9477a8fbfc9ac238c183a5e0461a30a572ddf1722db0613a
|
@@ -32,6 +32,18 @@
|
|
32
32
|
<ref name="DocumentType"/>
|
33
33
|
</element>
|
34
34
|
</define>
|
35
|
+
<define name="section-title">
|
36
|
+
<element name="title">
|
37
|
+
<zeroOrMore>
|
38
|
+
<ref name="TextElement"/>
|
39
|
+
</zeroOrMore>
|
40
|
+
</element>
|
41
|
+
<zeroOrMore>
|
42
|
+
<element name="variant-title">
|
43
|
+
<ref name="TypedTitleString"/>
|
44
|
+
</element>
|
45
|
+
</zeroOrMore>
|
46
|
+
</define>
|
35
47
|
<define name="hyperlink">
|
36
48
|
<element name="link">
|
37
49
|
<attribute name="target">
|
@@ -158,15 +170,17 @@
|
|
158
170
|
<data type="boolean"/>
|
159
171
|
</attribute>
|
160
172
|
</optional>
|
161
|
-
<
|
162
|
-
<
|
163
|
-
<
|
164
|
-
|
165
|
-
|
166
|
-
|
167
|
-
|
168
|
-
|
169
|
-
|
173
|
+
<optional>
|
174
|
+
<attribute name="type">
|
175
|
+
<choice>
|
176
|
+
<value>roman</value>
|
177
|
+
<value>alphabet</value>
|
178
|
+
<value>arabic</value>
|
179
|
+
<value>roman_upper</value>
|
180
|
+
<value>alphabet_upper</value>
|
181
|
+
</choice>
|
182
|
+
</attribute>
|
183
|
+
</optional>
|
170
184
|
<oneOrMore>
|
171
185
|
<ref name="li"/>
|
172
186
|
</oneOrMore>
|
@@ -155,7 +155,7 @@
|
|
155
155
|
</fo:table-cell>
|
156
156
|
<fo:table-cell number-columns-spanned="2" border="0.5pt solid rgb(0, 21, 50)">
|
157
157
|
<fo:block-container height="154.4mm" text-align="center" display-align="center">
|
158
|
-
<fo:block font-size="28pt" font-weight="bold" color="rgb(0, 0, 76)">
|
158
|
+
<fo:block font-size="28pt" font-weight="bold" color="rgb(0, 0, 76)" role="H1">
|
159
159
|
<xsl:value-of select="$title-en"/>
|
160
160
|
</fo:block>
|
161
161
|
</fo:block-container>
|
@@ -215,61 +215,63 @@
|
|
215
215
|
<!-- Table of Contents -->
|
216
216
|
<fo:block-container margin-right="-12.7mm">
|
217
217
|
<fo:block-container margin-right="0mm">
|
218
|
-
<fo:block
|
219
|
-
<
|
220
|
-
<xsl:
|
221
|
-
<xsl:
|
222
|
-
|
223
|
-
|
224
|
-
|
225
|
-
|
226
|
-
<xsl:if test="$debug = 'true'">
|
227
|
-
<xsl:text disable-output-escaping="yes"><!--</xsl:text>
|
228
|
-
DEBUG
|
229
|
-
contents=<xsl:copy-of select="xalan:nodeset($contents)"/>
|
230
|
-
<xsl:text disable-output-escaping="yes">--></xsl:text>
|
231
|
-
</xsl:if>
|
232
|
-
|
233
|
-
<xsl:for-each select="xalan:nodeset($contents)//item[@display = 'true']"><!-- [not(@level = 2 and starts-with(@section, '0'))] skip clause from preface -->
|
234
|
-
<fo:block>
|
235
|
-
<xsl:if test="@level = 1">
|
236
|
-
<xsl:attribute name="margin-top">6pt</xsl:attribute>
|
237
|
-
</xsl:if>
|
238
|
-
|
239
|
-
<fo:list-block>
|
240
|
-
|
241
|
-
<xsl:attribute name="provisional-distance-between-starts">
|
242
|
-
<xsl:choose>
|
243
|
-
<xsl:when test="@level >= 1 and @root = 'preface'">0mm</xsl:when>
|
244
|
-
<xsl:when test="@level >= 1 and @root = 'annex' and not(@type = 'annex')">13mm</xsl:when>
|
245
|
-
<xsl:when test="@level >= 1 and not(@type = 'annex')">10mm</xsl:when>
|
246
|
-
<xsl:otherwise>0mm</xsl:otherwise>
|
247
|
-
</xsl:choose>
|
248
|
-
</xsl:attribute>
|
249
|
-
<fo:list-item>
|
250
|
-
<fo:list-item-label end-indent="label-end()">
|
251
|
-
<fo:block>
|
252
|
-
<xsl:if test="@section != '' and not(@type = 'annex')"> <!-- output below -->
|
253
|
-
<xsl:value-of select="@section"/>
|
254
|
-
</xsl:if>
|
255
|
-
</fo:block>
|
256
|
-
</fo:list-item-label>
|
257
|
-
<fo:list-item-body start-indent="body-start()">
|
258
|
-
<fo:block text-align-last="justify" margin-left="12mm" text-indent="-12mm">
|
259
|
-
<fo:basic-link internal-destination="{@id}" fox:alt-text="{title}">
|
260
|
-
<xsl:apply-templates select="title"/>
|
261
|
-
<fo:inline keep-together.within-line="always">
|
262
|
-
<fo:leader font-size="9pt" font-weight="normal" leader-pattern="dots"/>
|
263
|
-
<fo:inline><fo:page-number-citation ref-id="{@id}"/></fo:inline>
|
264
|
-
</fo:inline>
|
265
|
-
</fo:basic-link>
|
266
|
-
</fo:block>
|
267
|
-
</fo:list-item-body>
|
268
|
-
</fo:list-item>
|
269
|
-
</fo:list-block>
|
218
|
+
<fo:block role="TOC">
|
219
|
+
<fo:block color="rgb(14, 36, 133)" margin-bottom="15.5pt" role="H1">
|
220
|
+
<xsl:variable name="title-toc">
|
221
|
+
<xsl:call-template name="getTitle">
|
222
|
+
<xsl:with-param name="name" select="'title-toc'"/>
|
223
|
+
</xsl:call-template>
|
224
|
+
</xsl:variable>
|
225
|
+
<xsl:value-of select="$title-toc"/>
|
270
226
|
</fo:block>
|
227
|
+
<xsl:if test="$debug = 'true'">
|
228
|
+
<xsl:text disable-output-escaping="yes"><!--</xsl:text>
|
229
|
+
DEBUG
|
230
|
+
contents=<xsl:copy-of select="xalan:nodeset($contents)"/>
|
231
|
+
<xsl:text disable-output-escaping="yes">--></xsl:text>
|
232
|
+
</xsl:if>
|
271
233
|
|
272
|
-
|
234
|
+
<xsl:for-each select="xalan:nodeset($contents)//item[@display = 'true']"><!-- [not(@level = 2 and starts-with(@section, '0'))] skip clause from preface -->
|
235
|
+
<fo:block role="TOCI">
|
236
|
+
<xsl:if test="@level = 1">
|
237
|
+
<xsl:attribute name="margin-top">6pt</xsl:attribute>
|
238
|
+
</xsl:if>
|
239
|
+
|
240
|
+
<fo:list-block>
|
241
|
+
|
242
|
+
<xsl:attribute name="provisional-distance-between-starts">
|
243
|
+
<xsl:choose>
|
244
|
+
<xsl:when test="@level >= 1 and @root = 'preface'">0mm</xsl:when>
|
245
|
+
<xsl:when test="@level >= 1 and @root = 'annex' and not(@type = 'annex')">13mm</xsl:when>
|
246
|
+
<xsl:when test="@level >= 1 and not(@type = 'annex')">10mm</xsl:when>
|
247
|
+
<xsl:otherwise>0mm</xsl:otherwise>
|
248
|
+
</xsl:choose>
|
249
|
+
</xsl:attribute>
|
250
|
+
<fo:list-item>
|
251
|
+
<fo:list-item-label end-indent="label-end()">
|
252
|
+
<fo:block>
|
253
|
+
<xsl:if test="@section != '' and not(@type = 'annex')"> <!-- output below -->
|
254
|
+
<xsl:value-of select="@section"/>
|
255
|
+
</xsl:if>
|
256
|
+
</fo:block>
|
257
|
+
</fo:list-item-label>
|
258
|
+
<fo:list-item-body start-indent="body-start()">
|
259
|
+
<fo:block text-align-last="justify" margin-left="12mm" text-indent="-12mm">
|
260
|
+
<fo:basic-link internal-destination="{@id}" fox:alt-text="{title}">
|
261
|
+
<xsl:apply-templates select="title"/>
|
262
|
+
<fo:inline keep-together.within-line="always">
|
263
|
+
<fo:leader font-size="9pt" font-weight="normal" leader-pattern="dots"/>
|
264
|
+
<fo:inline><fo:page-number-citation ref-id="{@id}"/></fo:inline>
|
265
|
+
</fo:inline>
|
266
|
+
</fo:basic-link>
|
267
|
+
</fo:block>
|
268
|
+
</fo:list-item-body>
|
269
|
+
</fo:list-item>
|
270
|
+
</fo:list-block>
|
271
|
+
</fo:block>
|
272
|
+
|
273
|
+
</xsl:for-each>
|
274
|
+
</fo:block>
|
273
275
|
</fo:block-container>
|
274
276
|
</fo:block-container>
|
275
277
|
|
@@ -297,7 +299,7 @@
|
|
297
299
|
<fo:flow flow-name="xsl-region-body">
|
298
300
|
<fo:block-container>
|
299
301
|
|
300
|
-
<fo:block font-size="16pt" font-weight="bold" margin-bottom="18pt"><xsl:value-of select="$title-en"/></fo:block>
|
302
|
+
<fo:block font-size="16pt" font-weight="bold" margin-bottom="18pt" role="H1"><xsl:value-of select="$title-en"/></fo:block>
|
301
303
|
|
302
304
|
<xsl:apply-templates select="/*/*[local-name()='sections']/*[local-name()='clause'][@type='scope']"/>
|
303
305
|
<!-- Normative references -->
|
@@ -453,13 +455,14 @@
|
|
453
455
|
<!-- ====== -->
|
454
456
|
|
455
457
|
<xsl:template match="iho:annex/iho:title">
|
456
|
-
<fo:block font-size="13pt" font-weight="bold" text-align="center" margin-bottom="12pt" keep-with-next="always">
|
458
|
+
<fo:block font-size="13pt" font-weight="bold" text-align="center" margin-bottom="12pt" keep-with-next="always" role="H1">
|
457
459
|
<xsl:apply-templates/>
|
460
|
+
<xsl:apply-templates select="following-sibling::*[1][local-name() = 'variant-title'][@type = 'sub']" mode="subtitle"/>
|
458
461
|
</fo:block>
|
459
462
|
</xsl:template>
|
460
463
|
|
461
464
|
<xsl:template match="iho:bibliography/iho:references[not(@normative='true')]/iho:title">
|
462
|
-
<fo:block font-size="16pt" font-weight="bold" text-align="center" margin-top="6pt" margin-bottom="36pt" keep-with-next="always">
|
465
|
+
<fo:block font-size="16pt" font-weight="bold" text-align="center" margin-top="6pt" margin-bottom="36pt" keep-with-next="always" role="H1">
|
463
466
|
<xsl:apply-templates/>
|
464
467
|
</fo:block>
|
465
468
|
</xsl:template>
|
@@ -504,7 +507,10 @@
|
|
504
507
|
|
505
508
|
<xsl:attribute name="keep-with-next">always</xsl:attribute>
|
506
509
|
|
510
|
+
<xsl:attribute name="role">H<xsl:value-of select="$level"/></xsl:attribute>
|
511
|
+
|
507
512
|
<xsl:apply-templates/>
|
513
|
+
<xsl:apply-templates select="following-sibling::*[1][local-name() = 'variant-title'][@type = 'sub']" mode="subtitle"/>
|
508
514
|
</xsl:element>
|
509
515
|
|
510
516
|
<xsl:if test="$element-name = 'fo:inline' and not(following-sibling::iho:p)">
|
@@ -806,8 +812,10 @@
|
|
806
812
|
|
807
813
|
|
808
814
|
<xsl:template match="iho:preferred">
|
809
|
-
|
810
|
-
|
815
|
+
<xsl:variable name="levelTerm">
|
816
|
+
<xsl:call-template name="getLevelTermName"/>
|
817
|
+
</xsl:variable>
|
818
|
+
<fo:block line-height="1.1" role="H{$levelTerm}">
|
811
819
|
<fo:block font-weight="bold" keep-with-next="always">
|
812
820
|
<xsl:apply-templates select="ancestor::iho:term/iho:name" mode="presentation"/>
|
813
821
|
</fo:block>
|
@@ -822,14 +830,14 @@
|
|
822
830
|
|
823
831
|
<xsl:template name="insertHeaderFooter">
|
824
832
|
<xsl:param name="font-weight" select="'bold'"/>
|
825
|
-
<fo:static-content flow-name="header-odd">
|
833
|
+
<fo:static-content flow-name="header-odd" role="artifact">
|
826
834
|
<fo:block-container height="100%">
|
827
835
|
<fo:block padding-top="12.5mm" text-align="right">
|
828
836
|
<xsl:value-of select="$docidentifier"/>
|
829
837
|
</fo:block>
|
830
838
|
</fo:block-container>
|
831
839
|
</fo:static-content>
|
832
|
-
<fo:static-content flow-name="footer-odd">
|
840
|
+
<fo:static-content flow-name="footer-odd" role="artifact">
|
833
841
|
<fo:block-container height="100%" margin-right="-10mm" display-align="after">
|
834
842
|
<fo:block-container margin-right="0mm">
|
835
843
|
<fo:block padding-bottom="17mm" font-size="10pt" text-align-last="justify">
|
@@ -842,14 +850,14 @@
|
|
842
850
|
</fo:block-container>
|
843
851
|
</fo:block-container>
|
844
852
|
</fo:static-content>
|
845
|
-
<fo:static-content flow-name="header-even">
|
853
|
+
<fo:static-content flow-name="header-even" role="artifact">
|
846
854
|
<fo:block-container height="100%">
|
847
855
|
<fo:block padding-top="12.5mm">
|
848
856
|
<xsl:value-of select="$docidentifier"/>
|
849
857
|
</fo:block>
|
850
858
|
</fo:block-container>
|
851
859
|
</fo:static-content>
|
852
|
-
<fo:static-content flow-name="footer-even">
|
860
|
+
<fo:static-content flow-name="footer-even" role="artifact">
|
853
861
|
<fo:block-container height="100%" margin-right="-10mm" display-align="after">
|
854
862
|
<fo:block-container margin-right="0mm">
|
855
863
|
<fo:block padding-bottom="17mm" font-size="10pt" text-align-last="justify">
|
@@ -1131,6 +1139,7 @@
|
|
1131
1139
|
</xsl:attribute-set><xsl:attribute-set name="sourcecode-style">
|
1132
1140
|
<xsl:attribute name="white-space">pre</xsl:attribute>
|
1133
1141
|
<xsl:attribute name="wrap-option">wrap</xsl:attribute>
|
1142
|
+
<xsl:attribute name="role">Code</xsl:attribute>
|
1134
1143
|
|
1135
1144
|
|
1136
1145
|
|
@@ -1157,8 +1166,13 @@
|
|
1157
1166
|
|
1158
1167
|
</xsl:attribute-set><xsl:attribute-set name="requirement-label-style">
|
1159
1168
|
|
1160
|
-
</xsl:attribute-set><xsl:attribute-set name="
|
1161
|
-
</xsl:attribute-set><xsl:attribute-set name="
|
1169
|
+
</xsl:attribute-set><xsl:attribute-set name="subject-style">
|
1170
|
+
</xsl:attribute-set><xsl:attribute-set name="inherit-style">
|
1171
|
+
</xsl:attribute-set><xsl:attribute-set name="description-style">
|
1172
|
+
</xsl:attribute-set><xsl:attribute-set name="specification-style">
|
1173
|
+
</xsl:attribute-set><xsl:attribute-set name="measurement-target-style">
|
1174
|
+
</xsl:attribute-set><xsl:attribute-set name="verification-style">
|
1175
|
+
</xsl:attribute-set><xsl:attribute-set name="import-style">
|
1162
1176
|
</xsl:attribute-set><xsl:attribute-set name="recommendation-style">
|
1163
1177
|
|
1164
1178
|
|
@@ -1371,7 +1385,8 @@
|
|
1371
1385
|
|
1372
1386
|
|
1373
1387
|
|
1374
|
-
</xsl:attribute-set><xsl:attribute-set name="quote-style">
|
1388
|
+
</xsl:attribute-set><xsl:attribute-set name="quote-style">
|
1389
|
+
<xsl:attribute name="role">BlockQuote</xsl:attribute>
|
1375
1390
|
|
1376
1391
|
|
1377
1392
|
|
@@ -1576,7 +1591,9 @@
|
|
1576
1591
|
|
1577
1592
|
<xsl:apply-templates select="*[local-name()='name']" mode="presentation"/>
|
1578
1593
|
|
1579
|
-
|
1594
|
+
|
1595
|
+
|
1596
|
+
|
1580
1597
|
|
1581
1598
|
<xsl:call-template name="fn_name_display"/>
|
1582
1599
|
|
@@ -3445,16 +3462,68 @@
|
|
3445
3462
|
<xsl:with-param name="isDeleted" select="$isDeleted"/>
|
3446
3463
|
</xsl:call-template>
|
3447
3464
|
|
3465
|
+
|
3466
|
+
|
3448
3467
|
<xsl:variable name="mathml">
|
3449
3468
|
<xsl:apply-templates select="." mode="mathml"/>
|
3450
3469
|
</xsl:variable>
|
3451
3470
|
<fo:instream-foreign-object fox:alt-text="Math">
|
3452
3471
|
|
3453
3472
|
|
3473
|
+
<xsl:variable name="comment_text_following" select="following-sibling::node()[1][self::comment()]"/>
|
3474
|
+
<xsl:variable name="comment_text_">
|
3475
|
+
<xsl:choose>
|
3476
|
+
<xsl:when test="normalize-space($comment_text_following) != ''">
|
3477
|
+
<xsl:value-of select="$comment_text_following"/>
|
3478
|
+
</xsl:when>
|
3479
|
+
<xsl:otherwise>
|
3480
|
+
<xsl:value-of select="normalize-space(translate(.,' ',' '))"/>
|
3481
|
+
</xsl:otherwise>
|
3482
|
+
</xsl:choose>
|
3483
|
+
</xsl:variable>
|
3484
|
+
<xsl:variable name="comment_text" select="java:org.metanorma.fop.Util.unescape($comment_text_)"/>
|
3485
|
+
|
3486
|
+
<xsl:if test="normalize-space($comment_text) != ''">
|
3487
|
+
<!-- put Mathin Alternate Text -->
|
3488
|
+
<xsl:attribute name="fox:alt-text">
|
3489
|
+
<xsl:value-of select="java:org.metanorma.fop.Util.unescape($comment_text)"/>
|
3490
|
+
</xsl:attribute>
|
3491
|
+
</xsl:if>
|
3492
|
+
|
3493
|
+
<xsl:variable name="mathml_content">
|
3494
|
+
<xsl:apply-templates select="." mode="mathml_actual_text"/>
|
3495
|
+
</xsl:variable>
|
3496
|
+
<!-- put MathML in Actual Text -->
|
3497
|
+
<xsl:attribute name="fox:actual-text">
|
3498
|
+
<xsl:value-of select="$mathml_content"/>
|
3499
|
+
</xsl:attribute>
|
3500
|
+
|
3501
|
+
|
3454
3502
|
<!-- <xsl:copy-of select="."/> -->
|
3455
3503
|
<xsl:copy-of select="xalan:nodeset($mathml)"/>
|
3456
3504
|
</fo:instream-foreign-object>
|
3457
3505
|
</fo:inline>
|
3506
|
+
</xsl:template><xsl:template match="mathml:*" mode="mathml_actual_text">
|
3507
|
+
<!-- <xsl:text>a+b</xsl:text> -->
|
3508
|
+
<xsl:text><</xsl:text>
|
3509
|
+
<xsl:value-of select="local-name()"/>
|
3510
|
+
<xsl:if test="local-name() = 'math'">
|
3511
|
+
<xsl:text> xmlns="http://www.w3.org/1998/Math/MathML"</xsl:text>
|
3512
|
+
</xsl:if>
|
3513
|
+
<xsl:for-each select="@*">
|
3514
|
+
<xsl:text> </xsl:text>
|
3515
|
+
<xsl:value-of select="local-name()"/>
|
3516
|
+
<xsl:text>="</xsl:text>
|
3517
|
+
<xsl:value-of select="."/>
|
3518
|
+
<xsl:text>"</xsl:text>
|
3519
|
+
</xsl:for-each>
|
3520
|
+
<xsl:text>></xsl:text>
|
3521
|
+
<xsl:apply-templates mode="mathml_actual_text"/>
|
3522
|
+
<xsl:text></</xsl:text>
|
3523
|
+
<xsl:value-of select="local-name()"/>
|
3524
|
+
<xsl:text>></xsl:text>
|
3525
|
+
</xsl:template><xsl:template match="text()" mode="mathml_actual_text">
|
3526
|
+
<xsl:value-of select="normalize-space()"/>
|
3458
3527
|
</xsl:template><xsl:template match="@*|node()" mode="mathml">
|
3459
3528
|
<xsl:copy>
|
3460
3529
|
<xsl:apply-templates select="@*|node()" mode="mathml"/>
|
@@ -3516,7 +3585,10 @@
|
|
3516
3585
|
</fo:block>
|
3517
3586
|
<xsl:apply-templates/>
|
3518
3587
|
</xsl:template><xsl:template match="*[local-name()='appendix']/*[local-name()='title']"/><xsl:template match="*[local-name()='appendix']/*[local-name()='title']" mode="process">
|
3519
|
-
<
|
3588
|
+
<xsl:variable name="level">
|
3589
|
+
<xsl:call-template name="getLevel"/>
|
3590
|
+
</xsl:variable>
|
3591
|
+
<fo:inline role="H{$level}"><xsl:apply-templates/></fo:inline>
|
3520
3592
|
</xsl:template><xsl:template match="*[local-name()='appendix']//*[local-name()='example']" priority="2">
|
3521
3593
|
<fo:block id="{@id}" xsl:use-attribute-sets="appendix-example-style">
|
3522
3594
|
<xsl:apply-templates select="*[local-name()='name']" mode="presentation"/>
|
@@ -3551,9 +3623,10 @@
|
|
3551
3623
|
|
3552
3624
|
</xsl:variable>
|
3553
3625
|
|
3626
|
+
<xsl:variable name="text"><xsl:apply-templates/></xsl:variable>
|
3554
3627
|
<xsl:choose>
|
3555
|
-
<xsl:when test="$lang = 'zh'"><xsl:text>、</xsl:text><xsl:value-of select="$title-modified"/><xsl:text>—</xsl:text></xsl:when>
|
3556
|
-
<xsl:otherwise><xsl:text>, </xsl:text><xsl:value-of select="$title-modified"/><xsl:text> — </xsl:text></xsl:otherwise>
|
3628
|
+
<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>
|
3629
|
+
<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>
|
3557
3630
|
</xsl:choose>
|
3558
3631
|
<xsl:apply-templates/>
|
3559
3632
|
</xsl:template><xsl:template match="*[local-name() = 'xref']">
|
@@ -3701,7 +3774,10 @@
|
|
3701
3774
|
</fo:block>
|
3702
3775
|
</xsl:template><xsl:template match="*[local-name() = 'term']/*[local-name() = 'name']"/><xsl:template match="*[local-name() = 'term']/*[local-name() = 'name']" mode="presentation">
|
3703
3776
|
<xsl:if test="normalize-space() != ''">
|
3704
|
-
<
|
3777
|
+
<xsl:variable name="level">
|
3778
|
+
<xsl:call-template name="getLevelTermName"/>
|
3779
|
+
</xsl:variable>
|
3780
|
+
<fo:inline role="H{$level}">
|
3705
3781
|
<xsl:apply-templates/>
|
3706
3782
|
<!-- <xsl:if test="$namespace = 'gb' or $namespace = 'ogc'">
|
3707
3783
|
<xsl:text>.</xsl:text>
|
@@ -4332,6 +4408,7 @@
|
|
4332
4408
|
</xsl:when>
|
4333
4409
|
<xsl:otherwise>
|
4334
4410
|
<xsl:apply-templates/>
|
4411
|
+
<xsl:apply-templates select="following-sibling::*[1][local-name() = 'variant-title'][@type = 'sub']" mode="subtitle"/>
|
4335
4412
|
</xsl:otherwise>
|
4336
4413
|
</xsl:choose>
|
4337
4414
|
</fo:block>
|
@@ -4472,14 +4549,6 @@
|
|
4472
4549
|
<fo:block>
|
4473
4550
|
<fo:inline padding-right="3mm">Obligation</fo:inline><xsl:value-of select="."/>
|
4474
4551
|
</fo:block>
|
4475
|
-
</xsl:template><xsl:template match="*[local-name() = 'requirement']/*[local-name() = 'subject']"/><xsl:template match="*[local-name() = 'requirement']/*[local-name() = 'subject']" mode="presentation">
|
4476
|
-
<fo:block xsl:use-attribute-sets="requirement-subject-style">
|
4477
|
-
<xsl:text>Target Type </xsl:text><xsl:apply-templates/>
|
4478
|
-
</fo:block>
|
4479
|
-
</xsl:template><xsl:template match="*[local-name() = 'requirement']/*[local-name() = 'inherit']">
|
4480
|
-
<fo:block xsl:use-attribute-sets="requirement-inherit-style">
|
4481
|
-
<xsl:text>Dependency </xsl:text><xsl:apply-templates/>
|
4482
|
-
</fo:block>
|
4483
4552
|
</xsl:template><xsl:template match="*[local-name() = 'recommendation']">
|
4484
4553
|
<fo:block id="{@id}" xsl:use-attribute-sets="recommendation-style">
|
4485
4554
|
<xsl:apply-templates select="*[local-name()='name']" mode="presentation"/>
|
@@ -4496,6 +4565,38 @@
|
|
4496
4565
|
<fo:block xsl:use-attribute-sets="recommendation-label-style">
|
4497
4566
|
<xsl:apply-templates/>
|
4498
4567
|
</fo:block>
|
4568
|
+
</xsl:template><xsl:template match="*[local-name() = 'requirement']/*[local-name() = 'subject']" priority="2"/><xsl:template match="*[local-name() = 'requirement']/*[local-name() = 'subject']" mode="presentation">
|
4569
|
+
<fo:block xsl:use-attribute-sets="subject-style">
|
4570
|
+
<xsl:text>Target Type </xsl:text><xsl:apply-templates/>
|
4571
|
+
</fo:block>
|
4572
|
+
</xsl:template><xsl:template match="*[local-name() = 'subject']">
|
4573
|
+
<fo:block xsl:use-attribute-sets="subject-style">
|
4574
|
+
<xsl:text>Target Type </xsl:text><xsl:apply-templates/>
|
4575
|
+
</fo:block>
|
4576
|
+
</xsl:template><xsl:template match="*[local-name() = 'inherit'] | *[local-name() = 'component'][@class = 'inherit']">
|
4577
|
+
<fo:block xsl:use-attribute-sets="inherit-style">
|
4578
|
+
<xsl:text>Dependency </xsl:text><xsl:apply-templates/>
|
4579
|
+
</fo:block>
|
4580
|
+
</xsl:template><xsl:template match="*[local-name() = 'description'] | *[local-name() = 'component'][@class = 'description']">
|
4581
|
+
<fo:block xsl:use-attribute-sets="description-style">
|
4582
|
+
<xsl:apply-templates/>
|
4583
|
+
</fo:block>
|
4584
|
+
</xsl:template><xsl:template match="*[local-name() = 'specification'] | *[local-name() = 'component'][@class = 'specification']">
|
4585
|
+
<fo:block xsl:use-attribute-sets="specification-style">
|
4586
|
+
<xsl:apply-templates/>
|
4587
|
+
</fo:block>
|
4588
|
+
</xsl:template><xsl:template match="*[local-name() = 'measurement-target'] | *[local-name() = 'component'][@class = 'measurement-target']">
|
4589
|
+
<fo:block xsl:use-attribute-sets="measurement-target-style">
|
4590
|
+
<xsl:apply-templates/>
|
4591
|
+
</fo:block>
|
4592
|
+
</xsl:template><xsl:template match="*[local-name() = 'verification'] | *[local-name() = 'component'][@class = 'verification']">
|
4593
|
+
<fo:block xsl:use-attribute-sets="verification-style">
|
4594
|
+
<xsl:apply-templates/>
|
4595
|
+
</fo:block>
|
4596
|
+
</xsl:template><xsl:template match="*[local-name() = 'import'] | *[local-name() = 'component'][@class = 'import']">
|
4597
|
+
<fo:block xsl:use-attribute-sets="import-style">
|
4598
|
+
<xsl:apply-templates/>
|
4599
|
+
</fo:block>
|
4499
4600
|
</xsl:template><xsl:template match="*[local-name() = 'table'][@class = 'recommendation' or @class='requirement' or @class='permission']">
|
4500
4601
|
<fo:block-container margin-left="0mm" margin-right="0mm" margin-bottom="12pt">
|
4501
4602
|
<xsl:if test="ancestor::*[local-name() = 'table'][@class = 'recommendation' or @class='requirement' or @class='permission']">
|
@@ -5469,6 +5570,9 @@
|
|
5469
5570
|
<fo:block-container border="1pt solid black" width="50%">
|
5470
5571
|
<fo:block> </fo:block>
|
5471
5572
|
</fo:block-container>
|
5573
|
+
</xsl:template><xsl:template match="*[local-name() = 'variant-title'][@type = 'sub']"/><xsl:template match="*[local-name() = 'variant-title'][@type = 'sub']" mode="subtitle">
|
5574
|
+
<fo:inline padding-right="5mm"> </fo:inline>
|
5575
|
+
<fo:inline><xsl:apply-templates/></fo:inline>
|
5472
5576
|
</xsl:template><xsl:template name="convertDate">
|
5473
5577
|
<xsl:param name="date"/>
|
5474
5578
|
<xsl:param name="format" select="'short'"/>
|
@@ -5707,6 +5811,26 @@
|
|
5707
5811
|
<xsl:value-of select="$level"/>
|
5708
5812
|
</xsl:otherwise>
|
5709
5813
|
</xsl:choose>
|
5814
|
+
</xsl:template><xsl:template name="getLevelTermName">
|
5815
|
+
<xsl:choose>
|
5816
|
+
<xsl:when test="normalize-space(../@depth) != ''">
|
5817
|
+
<xsl:value-of select="../@depth"/>
|
5818
|
+
</xsl:when>
|
5819
|
+
<xsl:otherwise>
|
5820
|
+
<xsl:variable name="title_level_">
|
5821
|
+
<xsl:for-each select="../preceding-sibling::*[local-name() = 'title'][1]">
|
5822
|
+
<xsl:call-template name="getLevel"/>
|
5823
|
+
</xsl:for-each>
|
5824
|
+
</xsl:variable>
|
5825
|
+
<xsl:variable name="title_level" select="normalize-space($title_level_)"/>
|
5826
|
+
<xsl:choose>
|
5827
|
+
<xsl:when test="$title_level != ''"><xsl:value-of select="$title_level + 1"/></xsl:when>
|
5828
|
+
<xsl:otherwise>
|
5829
|
+
<xsl:call-template name="getLevel"/>
|
5830
|
+
</xsl:otherwise>
|
5831
|
+
</xsl:choose>
|
5832
|
+
</xsl:otherwise>
|
5833
|
+
</xsl:choose>
|
5710
5834
|
</xsl:template><xsl:template name="split">
|
5711
5835
|
<xsl:param name="pText" select="."/>
|
5712
5836
|
<xsl:param name="sep" select="','"/>
|
@@ -155,7 +155,7 @@
|
|
155
155
|
</fo:table-cell>
|
156
156
|
<fo:table-cell number-columns-spanned="2" border="0.5pt solid rgb(0, 21, 50)">
|
157
157
|
<fo:block-container height="154.4mm" text-align="center" display-align="center">
|
158
|
-
<fo:block font-size="28pt" font-weight="bold" color="rgb(0, 0, 76)">
|
158
|
+
<fo:block font-size="28pt" font-weight="bold" color="rgb(0, 0, 76)" role="H1">
|
159
159
|
<xsl:value-of select="$title-en"/>
|
160
160
|
</fo:block>
|
161
161
|
</fo:block-container>
|
@@ -215,61 +215,63 @@
|
|
215
215
|
<!-- Table of Contents -->
|
216
216
|
<fo:block-container margin-right="-12.7mm">
|
217
217
|
<fo:block-container margin-right="0mm">
|
218
|
-
<fo:block
|
219
|
-
<
|
220
|
-
<xsl:
|
221
|
-
<xsl:
|
222
|
-
|
223
|
-
|
224
|
-
|
225
|
-
|
226
|
-
<xsl:if test="$debug = 'true'">
|
227
|
-
<xsl:text disable-output-escaping="yes"><!--</xsl:text>
|
228
|
-
DEBUG
|
229
|
-
contents=<xsl:copy-of select="xalan:nodeset($contents)"/>
|
230
|
-
<xsl:text disable-output-escaping="yes">--></xsl:text>
|
231
|
-
</xsl:if>
|
232
|
-
|
233
|
-
<xsl:for-each select="xalan:nodeset($contents)//item[@display = 'true']"><!-- [not(@level = 2 and starts-with(@section, '0'))] skip clause from preface -->
|
234
|
-
<fo:block>
|
235
|
-
<xsl:if test="@level = 1">
|
236
|
-
<xsl:attribute name="margin-top">6pt</xsl:attribute>
|
237
|
-
</xsl:if>
|
238
|
-
|
239
|
-
<fo:list-block>
|
240
|
-
|
241
|
-
<xsl:attribute name="provisional-distance-between-starts">
|
242
|
-
<xsl:choose>
|
243
|
-
<xsl:when test="@level >= 1 and @root = 'preface'">0mm</xsl:when>
|
244
|
-
<xsl:when test="@level >= 1 and @root = 'annex' and not(@type = 'annex')">13mm</xsl:when>
|
245
|
-
<xsl:when test="@level >= 1 and not(@type = 'annex')">10mm</xsl:when>
|
246
|
-
<xsl:otherwise>0mm</xsl:otherwise>
|
247
|
-
</xsl:choose>
|
248
|
-
</xsl:attribute>
|
249
|
-
<fo:list-item>
|
250
|
-
<fo:list-item-label end-indent="label-end()">
|
251
|
-
<fo:block>
|
252
|
-
<xsl:if test="@section != '' and not(@type = 'annex')"> <!-- output below -->
|
253
|
-
<xsl:value-of select="@section"/>
|
254
|
-
</xsl:if>
|
255
|
-
</fo:block>
|
256
|
-
</fo:list-item-label>
|
257
|
-
<fo:list-item-body start-indent="body-start()">
|
258
|
-
<fo:block text-align-last="justify" margin-left="12mm" text-indent="-12mm">
|
259
|
-
<fo:basic-link internal-destination="{@id}" fox:alt-text="{title}">
|
260
|
-
<xsl:apply-templates select="title"/>
|
261
|
-
<fo:inline keep-together.within-line="always">
|
262
|
-
<fo:leader font-size="9pt" font-weight="normal" leader-pattern="dots"/>
|
263
|
-
<fo:inline><fo:page-number-citation ref-id="{@id}"/></fo:inline>
|
264
|
-
</fo:inline>
|
265
|
-
</fo:basic-link>
|
266
|
-
</fo:block>
|
267
|
-
</fo:list-item-body>
|
268
|
-
</fo:list-item>
|
269
|
-
</fo:list-block>
|
218
|
+
<fo:block role="TOC">
|
219
|
+
<fo:block color="rgb(14, 36, 133)" margin-bottom="15.5pt" role="H1">
|
220
|
+
<xsl:variable name="title-toc">
|
221
|
+
<xsl:call-template name="getTitle">
|
222
|
+
<xsl:with-param name="name" select="'title-toc'"/>
|
223
|
+
</xsl:call-template>
|
224
|
+
</xsl:variable>
|
225
|
+
<xsl:value-of select="$title-toc"/>
|
270
226
|
</fo:block>
|
227
|
+
<xsl:if test="$debug = 'true'">
|
228
|
+
<xsl:text disable-output-escaping="yes"><!--</xsl:text>
|
229
|
+
DEBUG
|
230
|
+
contents=<xsl:copy-of select="xalan:nodeset($contents)"/>
|
231
|
+
<xsl:text disable-output-escaping="yes">--></xsl:text>
|
232
|
+
</xsl:if>
|
271
233
|
|
272
|
-
|
234
|
+
<xsl:for-each select="xalan:nodeset($contents)//item[@display = 'true']"><!-- [not(@level = 2 and starts-with(@section, '0'))] skip clause from preface -->
|
235
|
+
<fo:block role="TOCI">
|
236
|
+
<xsl:if test="@level = 1">
|
237
|
+
<xsl:attribute name="margin-top">6pt</xsl:attribute>
|
238
|
+
</xsl:if>
|
239
|
+
|
240
|
+
<fo:list-block>
|
241
|
+
|
242
|
+
<xsl:attribute name="provisional-distance-between-starts">
|
243
|
+
<xsl:choose>
|
244
|
+
<xsl:when test="@level >= 1 and @root = 'preface'">0mm</xsl:when>
|
245
|
+
<xsl:when test="@level >= 1 and @root = 'annex' and not(@type = 'annex')">13mm</xsl:when>
|
246
|
+
<xsl:when test="@level >= 1 and not(@type = 'annex')">10mm</xsl:when>
|
247
|
+
<xsl:otherwise>0mm</xsl:otherwise>
|
248
|
+
</xsl:choose>
|
249
|
+
</xsl:attribute>
|
250
|
+
<fo:list-item>
|
251
|
+
<fo:list-item-label end-indent="label-end()">
|
252
|
+
<fo:block>
|
253
|
+
<xsl:if test="@section != '' and not(@type = 'annex')"> <!-- output below -->
|
254
|
+
<xsl:value-of select="@section"/>
|
255
|
+
</xsl:if>
|
256
|
+
</fo:block>
|
257
|
+
</fo:list-item-label>
|
258
|
+
<fo:list-item-body start-indent="body-start()">
|
259
|
+
<fo:block text-align-last="justify" margin-left="12mm" text-indent="-12mm">
|
260
|
+
<fo:basic-link internal-destination="{@id}" fox:alt-text="{title}">
|
261
|
+
<xsl:apply-templates select="title"/>
|
262
|
+
<fo:inline keep-together.within-line="always">
|
263
|
+
<fo:leader font-size="9pt" font-weight="normal" leader-pattern="dots"/>
|
264
|
+
<fo:inline><fo:page-number-citation ref-id="{@id}"/></fo:inline>
|
265
|
+
</fo:inline>
|
266
|
+
</fo:basic-link>
|
267
|
+
</fo:block>
|
268
|
+
</fo:list-item-body>
|
269
|
+
</fo:list-item>
|
270
|
+
</fo:list-block>
|
271
|
+
</fo:block>
|
272
|
+
|
273
|
+
</xsl:for-each>
|
274
|
+
</fo:block>
|
273
275
|
</fo:block-container>
|
274
276
|
</fo:block-container>
|
275
277
|
|
@@ -297,7 +299,7 @@
|
|
297
299
|
<fo:flow flow-name="xsl-region-body">
|
298
300
|
<fo:block-container>
|
299
301
|
|
300
|
-
<fo:block font-size="16pt" font-weight="bold" margin-bottom="18pt"><xsl:value-of select="$title-en"/></fo:block>
|
302
|
+
<fo:block font-size="16pt" font-weight="bold" margin-bottom="18pt" role="H1"><xsl:value-of select="$title-en"/></fo:block>
|
301
303
|
|
302
304
|
<xsl:apply-templates select="/*/*[local-name()='sections']/*[local-name()='clause'][@type='scope']"/>
|
303
305
|
<!-- Normative references -->
|
@@ -453,13 +455,14 @@
|
|
453
455
|
<!-- ====== -->
|
454
456
|
|
455
457
|
<xsl:template match="iho:annex/iho:title">
|
456
|
-
<fo:block font-size="13pt" font-weight="bold" text-align="center" margin-bottom="12pt" keep-with-next="always">
|
458
|
+
<fo:block font-size="13pt" font-weight="bold" text-align="center" margin-bottom="12pt" keep-with-next="always" role="H1">
|
457
459
|
<xsl:apply-templates/>
|
460
|
+
<xsl:apply-templates select="following-sibling::*[1][local-name() = 'variant-title'][@type = 'sub']" mode="subtitle"/>
|
458
461
|
</fo:block>
|
459
462
|
</xsl:template>
|
460
463
|
|
461
464
|
<xsl:template match="iho:bibliography/iho:references[not(@normative='true')]/iho:title">
|
462
|
-
<fo:block font-size="16pt" font-weight="bold" text-align="center" margin-top="6pt" margin-bottom="36pt" keep-with-next="always">
|
465
|
+
<fo:block font-size="16pt" font-weight="bold" text-align="center" margin-top="6pt" margin-bottom="36pt" keep-with-next="always" role="H1">
|
463
466
|
<xsl:apply-templates/>
|
464
467
|
</fo:block>
|
465
468
|
</xsl:template>
|
@@ -504,7 +507,10 @@
|
|
504
507
|
|
505
508
|
<xsl:attribute name="keep-with-next">always</xsl:attribute>
|
506
509
|
|
510
|
+
<xsl:attribute name="role">H<xsl:value-of select="$level"/></xsl:attribute>
|
511
|
+
|
507
512
|
<xsl:apply-templates/>
|
513
|
+
<xsl:apply-templates select="following-sibling::*[1][local-name() = 'variant-title'][@type = 'sub']" mode="subtitle"/>
|
508
514
|
</xsl:element>
|
509
515
|
|
510
516
|
<xsl:if test="$element-name = 'fo:inline' and not(following-sibling::iho:p)">
|
@@ -806,8 +812,10 @@
|
|
806
812
|
|
807
813
|
|
808
814
|
<xsl:template match="iho:preferred">
|
809
|
-
|
810
|
-
|
815
|
+
<xsl:variable name="levelTerm">
|
816
|
+
<xsl:call-template name="getLevelTermName"/>
|
817
|
+
</xsl:variable>
|
818
|
+
<fo:block line-height="1.1" role="H{$levelTerm}">
|
811
819
|
<fo:block font-weight="bold" keep-with-next="always">
|
812
820
|
<xsl:apply-templates select="ancestor::iho:term/iho:name" mode="presentation"/>
|
813
821
|
</fo:block>
|
@@ -822,14 +830,14 @@
|
|
822
830
|
|
823
831
|
<xsl:template name="insertHeaderFooter">
|
824
832
|
<xsl:param name="font-weight" select="'bold'"/>
|
825
|
-
<fo:static-content flow-name="header-odd">
|
833
|
+
<fo:static-content flow-name="header-odd" role="artifact">
|
826
834
|
<fo:block-container height="100%">
|
827
835
|
<fo:block padding-top="12.5mm" text-align="right">
|
828
836
|
<xsl:value-of select="$docidentifier"/>
|
829
837
|
</fo:block>
|
830
838
|
</fo:block-container>
|
831
839
|
</fo:static-content>
|
832
|
-
<fo:static-content flow-name="footer-odd">
|
840
|
+
<fo:static-content flow-name="footer-odd" role="artifact">
|
833
841
|
<fo:block-container height="100%" margin-right="-10mm" display-align="after">
|
834
842
|
<fo:block-container margin-right="0mm">
|
835
843
|
<fo:block padding-bottom="17mm" font-size="10pt" text-align-last="justify">
|
@@ -842,14 +850,14 @@
|
|
842
850
|
</fo:block-container>
|
843
851
|
</fo:block-container>
|
844
852
|
</fo:static-content>
|
845
|
-
<fo:static-content flow-name="header-even">
|
853
|
+
<fo:static-content flow-name="header-even" role="artifact">
|
846
854
|
<fo:block-container height="100%">
|
847
855
|
<fo:block padding-top="12.5mm">
|
848
856
|
<xsl:value-of select="$docidentifier"/>
|
849
857
|
</fo:block>
|
850
858
|
</fo:block-container>
|
851
859
|
</fo:static-content>
|
852
|
-
<fo:static-content flow-name="footer-even">
|
860
|
+
<fo:static-content flow-name="footer-even" role="artifact">
|
853
861
|
<fo:block-container height="100%" margin-right="-10mm" display-align="after">
|
854
862
|
<fo:block-container margin-right="0mm">
|
855
863
|
<fo:block padding-bottom="17mm" font-size="10pt" text-align-last="justify">
|
@@ -1131,6 +1139,7 @@
|
|
1131
1139
|
</xsl:attribute-set><xsl:attribute-set name="sourcecode-style">
|
1132
1140
|
<xsl:attribute name="white-space">pre</xsl:attribute>
|
1133
1141
|
<xsl:attribute name="wrap-option">wrap</xsl:attribute>
|
1142
|
+
<xsl:attribute name="role">Code</xsl:attribute>
|
1134
1143
|
|
1135
1144
|
|
1136
1145
|
|
@@ -1157,8 +1166,13 @@
|
|
1157
1166
|
|
1158
1167
|
</xsl:attribute-set><xsl:attribute-set name="requirement-label-style">
|
1159
1168
|
|
1160
|
-
</xsl:attribute-set><xsl:attribute-set name="
|
1161
|
-
</xsl:attribute-set><xsl:attribute-set name="
|
1169
|
+
</xsl:attribute-set><xsl:attribute-set name="subject-style">
|
1170
|
+
</xsl:attribute-set><xsl:attribute-set name="inherit-style">
|
1171
|
+
</xsl:attribute-set><xsl:attribute-set name="description-style">
|
1172
|
+
</xsl:attribute-set><xsl:attribute-set name="specification-style">
|
1173
|
+
</xsl:attribute-set><xsl:attribute-set name="measurement-target-style">
|
1174
|
+
</xsl:attribute-set><xsl:attribute-set name="verification-style">
|
1175
|
+
</xsl:attribute-set><xsl:attribute-set name="import-style">
|
1162
1176
|
</xsl:attribute-set><xsl:attribute-set name="recommendation-style">
|
1163
1177
|
|
1164
1178
|
|
@@ -1371,7 +1385,8 @@
|
|
1371
1385
|
|
1372
1386
|
|
1373
1387
|
|
1374
|
-
</xsl:attribute-set><xsl:attribute-set name="quote-style">
|
1388
|
+
</xsl:attribute-set><xsl:attribute-set name="quote-style">
|
1389
|
+
<xsl:attribute name="role">BlockQuote</xsl:attribute>
|
1375
1390
|
|
1376
1391
|
|
1377
1392
|
|
@@ -1576,7 +1591,9 @@
|
|
1576
1591
|
|
1577
1592
|
<xsl:apply-templates select="*[local-name()='name']" mode="presentation"/>
|
1578
1593
|
|
1579
|
-
|
1594
|
+
|
1595
|
+
|
1596
|
+
|
1580
1597
|
|
1581
1598
|
<xsl:call-template name="fn_name_display"/>
|
1582
1599
|
|
@@ -3445,16 +3462,68 @@
|
|
3445
3462
|
<xsl:with-param name="isDeleted" select="$isDeleted"/>
|
3446
3463
|
</xsl:call-template>
|
3447
3464
|
|
3465
|
+
|
3466
|
+
|
3448
3467
|
<xsl:variable name="mathml">
|
3449
3468
|
<xsl:apply-templates select="." mode="mathml"/>
|
3450
3469
|
</xsl:variable>
|
3451
3470
|
<fo:instream-foreign-object fox:alt-text="Math">
|
3452
3471
|
|
3453
3472
|
|
3473
|
+
<xsl:variable name="comment_text_following" select="following-sibling::node()[1][self::comment()]"/>
|
3474
|
+
<xsl:variable name="comment_text_">
|
3475
|
+
<xsl:choose>
|
3476
|
+
<xsl:when test="normalize-space($comment_text_following) != ''">
|
3477
|
+
<xsl:value-of select="$comment_text_following"/>
|
3478
|
+
</xsl:when>
|
3479
|
+
<xsl:otherwise>
|
3480
|
+
<xsl:value-of select="normalize-space(translate(.,' ',' '))"/>
|
3481
|
+
</xsl:otherwise>
|
3482
|
+
</xsl:choose>
|
3483
|
+
</xsl:variable>
|
3484
|
+
<xsl:variable name="comment_text" select="java:org.metanorma.fop.Util.unescape($comment_text_)"/>
|
3485
|
+
|
3486
|
+
<xsl:if test="normalize-space($comment_text) != ''">
|
3487
|
+
<!-- put Mathin Alternate Text -->
|
3488
|
+
<xsl:attribute name="fox:alt-text">
|
3489
|
+
<xsl:value-of select="java:org.metanorma.fop.Util.unescape($comment_text)"/>
|
3490
|
+
</xsl:attribute>
|
3491
|
+
</xsl:if>
|
3492
|
+
|
3493
|
+
<xsl:variable name="mathml_content">
|
3494
|
+
<xsl:apply-templates select="." mode="mathml_actual_text"/>
|
3495
|
+
</xsl:variable>
|
3496
|
+
<!-- put MathML in Actual Text -->
|
3497
|
+
<xsl:attribute name="fox:actual-text">
|
3498
|
+
<xsl:value-of select="$mathml_content"/>
|
3499
|
+
</xsl:attribute>
|
3500
|
+
|
3501
|
+
|
3454
3502
|
<!-- <xsl:copy-of select="."/> -->
|
3455
3503
|
<xsl:copy-of select="xalan:nodeset($mathml)"/>
|
3456
3504
|
</fo:instream-foreign-object>
|
3457
3505
|
</fo:inline>
|
3506
|
+
</xsl:template><xsl:template match="mathml:*" mode="mathml_actual_text">
|
3507
|
+
<!-- <xsl:text>a+b</xsl:text> -->
|
3508
|
+
<xsl:text><</xsl:text>
|
3509
|
+
<xsl:value-of select="local-name()"/>
|
3510
|
+
<xsl:if test="local-name() = 'math'">
|
3511
|
+
<xsl:text> xmlns="http://www.w3.org/1998/Math/MathML"</xsl:text>
|
3512
|
+
</xsl:if>
|
3513
|
+
<xsl:for-each select="@*">
|
3514
|
+
<xsl:text> </xsl:text>
|
3515
|
+
<xsl:value-of select="local-name()"/>
|
3516
|
+
<xsl:text>="</xsl:text>
|
3517
|
+
<xsl:value-of select="."/>
|
3518
|
+
<xsl:text>"</xsl:text>
|
3519
|
+
</xsl:for-each>
|
3520
|
+
<xsl:text>></xsl:text>
|
3521
|
+
<xsl:apply-templates mode="mathml_actual_text"/>
|
3522
|
+
<xsl:text></</xsl:text>
|
3523
|
+
<xsl:value-of select="local-name()"/>
|
3524
|
+
<xsl:text>></xsl:text>
|
3525
|
+
</xsl:template><xsl:template match="text()" mode="mathml_actual_text">
|
3526
|
+
<xsl:value-of select="normalize-space()"/>
|
3458
3527
|
</xsl:template><xsl:template match="@*|node()" mode="mathml">
|
3459
3528
|
<xsl:copy>
|
3460
3529
|
<xsl:apply-templates select="@*|node()" mode="mathml"/>
|
@@ -3516,7 +3585,10 @@
|
|
3516
3585
|
</fo:block>
|
3517
3586
|
<xsl:apply-templates/>
|
3518
3587
|
</xsl:template><xsl:template match="*[local-name()='appendix']/*[local-name()='title']"/><xsl:template match="*[local-name()='appendix']/*[local-name()='title']" mode="process">
|
3519
|
-
<
|
3588
|
+
<xsl:variable name="level">
|
3589
|
+
<xsl:call-template name="getLevel"/>
|
3590
|
+
</xsl:variable>
|
3591
|
+
<fo:inline role="H{$level}"><xsl:apply-templates/></fo:inline>
|
3520
3592
|
</xsl:template><xsl:template match="*[local-name()='appendix']//*[local-name()='example']" priority="2">
|
3521
3593
|
<fo:block id="{@id}" xsl:use-attribute-sets="appendix-example-style">
|
3522
3594
|
<xsl:apply-templates select="*[local-name()='name']" mode="presentation"/>
|
@@ -3551,9 +3623,10 @@
|
|
3551
3623
|
|
3552
3624
|
</xsl:variable>
|
3553
3625
|
|
3626
|
+
<xsl:variable name="text"><xsl:apply-templates/></xsl:variable>
|
3554
3627
|
<xsl:choose>
|
3555
|
-
<xsl:when test="$lang = 'zh'"><xsl:text>、</xsl:text><xsl:value-of select="$title-modified"/><xsl:text>—</xsl:text></xsl:when>
|
3556
|
-
<xsl:otherwise><xsl:text>, </xsl:text><xsl:value-of select="$title-modified"/><xsl:text> — </xsl:text></xsl:otherwise>
|
3628
|
+
<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>
|
3629
|
+
<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>
|
3557
3630
|
</xsl:choose>
|
3558
3631
|
<xsl:apply-templates/>
|
3559
3632
|
</xsl:template><xsl:template match="*[local-name() = 'xref']">
|
@@ -3701,7 +3774,10 @@
|
|
3701
3774
|
</fo:block>
|
3702
3775
|
</xsl:template><xsl:template match="*[local-name() = 'term']/*[local-name() = 'name']"/><xsl:template match="*[local-name() = 'term']/*[local-name() = 'name']" mode="presentation">
|
3703
3776
|
<xsl:if test="normalize-space() != ''">
|
3704
|
-
<
|
3777
|
+
<xsl:variable name="level">
|
3778
|
+
<xsl:call-template name="getLevelTermName"/>
|
3779
|
+
</xsl:variable>
|
3780
|
+
<fo:inline role="H{$level}">
|
3705
3781
|
<xsl:apply-templates/>
|
3706
3782
|
<!-- <xsl:if test="$namespace = 'gb' or $namespace = 'ogc'">
|
3707
3783
|
<xsl:text>.</xsl:text>
|
@@ -4332,6 +4408,7 @@
|
|
4332
4408
|
</xsl:when>
|
4333
4409
|
<xsl:otherwise>
|
4334
4410
|
<xsl:apply-templates/>
|
4411
|
+
<xsl:apply-templates select="following-sibling::*[1][local-name() = 'variant-title'][@type = 'sub']" mode="subtitle"/>
|
4335
4412
|
</xsl:otherwise>
|
4336
4413
|
</xsl:choose>
|
4337
4414
|
</fo:block>
|
@@ -4472,14 +4549,6 @@
|
|
4472
4549
|
<fo:block>
|
4473
4550
|
<fo:inline padding-right="3mm">Obligation</fo:inline><xsl:value-of select="."/>
|
4474
4551
|
</fo:block>
|
4475
|
-
</xsl:template><xsl:template match="*[local-name() = 'requirement']/*[local-name() = 'subject']"/><xsl:template match="*[local-name() = 'requirement']/*[local-name() = 'subject']" mode="presentation">
|
4476
|
-
<fo:block xsl:use-attribute-sets="requirement-subject-style">
|
4477
|
-
<xsl:text>Target Type </xsl:text><xsl:apply-templates/>
|
4478
|
-
</fo:block>
|
4479
|
-
</xsl:template><xsl:template match="*[local-name() = 'requirement']/*[local-name() = 'inherit']">
|
4480
|
-
<fo:block xsl:use-attribute-sets="requirement-inherit-style">
|
4481
|
-
<xsl:text>Dependency </xsl:text><xsl:apply-templates/>
|
4482
|
-
</fo:block>
|
4483
4552
|
</xsl:template><xsl:template match="*[local-name() = 'recommendation']">
|
4484
4553
|
<fo:block id="{@id}" xsl:use-attribute-sets="recommendation-style">
|
4485
4554
|
<xsl:apply-templates select="*[local-name()='name']" mode="presentation"/>
|
@@ -4496,6 +4565,38 @@
|
|
4496
4565
|
<fo:block xsl:use-attribute-sets="recommendation-label-style">
|
4497
4566
|
<xsl:apply-templates/>
|
4498
4567
|
</fo:block>
|
4568
|
+
</xsl:template><xsl:template match="*[local-name() = 'requirement']/*[local-name() = 'subject']" priority="2"/><xsl:template match="*[local-name() = 'requirement']/*[local-name() = 'subject']" mode="presentation">
|
4569
|
+
<fo:block xsl:use-attribute-sets="subject-style">
|
4570
|
+
<xsl:text>Target Type </xsl:text><xsl:apply-templates/>
|
4571
|
+
</fo:block>
|
4572
|
+
</xsl:template><xsl:template match="*[local-name() = 'subject']">
|
4573
|
+
<fo:block xsl:use-attribute-sets="subject-style">
|
4574
|
+
<xsl:text>Target Type </xsl:text><xsl:apply-templates/>
|
4575
|
+
</fo:block>
|
4576
|
+
</xsl:template><xsl:template match="*[local-name() = 'inherit'] | *[local-name() = 'component'][@class = 'inherit']">
|
4577
|
+
<fo:block xsl:use-attribute-sets="inherit-style">
|
4578
|
+
<xsl:text>Dependency </xsl:text><xsl:apply-templates/>
|
4579
|
+
</fo:block>
|
4580
|
+
</xsl:template><xsl:template match="*[local-name() = 'description'] | *[local-name() = 'component'][@class = 'description']">
|
4581
|
+
<fo:block xsl:use-attribute-sets="description-style">
|
4582
|
+
<xsl:apply-templates/>
|
4583
|
+
</fo:block>
|
4584
|
+
</xsl:template><xsl:template match="*[local-name() = 'specification'] | *[local-name() = 'component'][@class = 'specification']">
|
4585
|
+
<fo:block xsl:use-attribute-sets="specification-style">
|
4586
|
+
<xsl:apply-templates/>
|
4587
|
+
</fo:block>
|
4588
|
+
</xsl:template><xsl:template match="*[local-name() = 'measurement-target'] | *[local-name() = 'component'][@class = 'measurement-target']">
|
4589
|
+
<fo:block xsl:use-attribute-sets="measurement-target-style">
|
4590
|
+
<xsl:apply-templates/>
|
4591
|
+
</fo:block>
|
4592
|
+
</xsl:template><xsl:template match="*[local-name() = 'verification'] | *[local-name() = 'component'][@class = 'verification']">
|
4593
|
+
<fo:block xsl:use-attribute-sets="verification-style">
|
4594
|
+
<xsl:apply-templates/>
|
4595
|
+
</fo:block>
|
4596
|
+
</xsl:template><xsl:template match="*[local-name() = 'import'] | *[local-name() = 'component'][@class = 'import']">
|
4597
|
+
<fo:block xsl:use-attribute-sets="import-style">
|
4598
|
+
<xsl:apply-templates/>
|
4599
|
+
</fo:block>
|
4499
4600
|
</xsl:template><xsl:template match="*[local-name() = 'table'][@class = 'recommendation' or @class='requirement' or @class='permission']">
|
4500
4601
|
<fo:block-container margin-left="0mm" margin-right="0mm" margin-bottom="12pt">
|
4501
4602
|
<xsl:if test="ancestor::*[local-name() = 'table'][@class = 'recommendation' or @class='requirement' or @class='permission']">
|
@@ -5469,6 +5570,9 @@
|
|
5469
5570
|
<fo:block-container border="1pt solid black" width="50%">
|
5470
5571
|
<fo:block> </fo:block>
|
5471
5572
|
</fo:block-container>
|
5573
|
+
</xsl:template><xsl:template match="*[local-name() = 'variant-title'][@type = 'sub']"/><xsl:template match="*[local-name() = 'variant-title'][@type = 'sub']" mode="subtitle">
|
5574
|
+
<fo:inline padding-right="5mm"> </fo:inline>
|
5575
|
+
<fo:inline><xsl:apply-templates/></fo:inline>
|
5472
5576
|
</xsl:template><xsl:template name="convertDate">
|
5473
5577
|
<xsl:param name="date"/>
|
5474
5578
|
<xsl:param name="format" select="'short'"/>
|
@@ -5707,6 +5811,26 @@
|
|
5707
5811
|
<xsl:value-of select="$level"/>
|
5708
5812
|
</xsl:otherwise>
|
5709
5813
|
</xsl:choose>
|
5814
|
+
</xsl:template><xsl:template name="getLevelTermName">
|
5815
|
+
<xsl:choose>
|
5816
|
+
<xsl:when test="normalize-space(../@depth) != ''">
|
5817
|
+
<xsl:value-of select="../@depth"/>
|
5818
|
+
</xsl:when>
|
5819
|
+
<xsl:otherwise>
|
5820
|
+
<xsl:variable name="title_level_">
|
5821
|
+
<xsl:for-each select="../preceding-sibling::*[local-name() = 'title'][1]">
|
5822
|
+
<xsl:call-template name="getLevel"/>
|
5823
|
+
</xsl:for-each>
|
5824
|
+
</xsl:variable>
|
5825
|
+
<xsl:variable name="title_level" select="normalize-space($title_level_)"/>
|
5826
|
+
<xsl:choose>
|
5827
|
+
<xsl:when test="$title_level != ''"><xsl:value-of select="$title_level + 1"/></xsl:when>
|
5828
|
+
<xsl:otherwise>
|
5829
|
+
<xsl:call-template name="getLevel"/>
|
5830
|
+
</xsl:otherwise>
|
5831
|
+
</xsl:choose>
|
5832
|
+
</xsl:otherwise>
|
5833
|
+
</xsl:choose>
|
5710
5834
|
</xsl:template><xsl:template name="split">
|
5711
5835
|
<xsl:param name="pText" select="."/>
|
5712
5836
|
<xsl:param name="sep" select="','"/>
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: metanorma-iho
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.10
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ribose Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-08-
|
11
|
+
date: 2021-08-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: htmlentities
|