metanorma-iso 2.4.4 → 2.4.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/isodoc/iso/iso.amendment.xsl +226 -96
- data/lib/isodoc/iso/iso.international-standard.xsl +226 -96
- data/lib/isodoc/iso/presentation_xml_convert.rb +3 -3
- data/lib/isodoc/iso/presentation_xref.rb +0 -1
- data/lib/metanorma/iso/boilerplate-fr.adoc +34 -0
- data/lib/metanorma/iso/boilerplate-ru.adoc +30 -0
- data/lib/metanorma/iso/boilerplate.adoc +40 -0
- data/lib/metanorma/iso/cleanup.rb +2 -2
- data/lib/metanorma/iso/isodoc.rng +18 -0
- data/lib/metanorma/iso/version.rb +1 -1
- metadata +5 -5
- data/lib/metanorma/iso/boilerplate-fr.xml +0 -42
- data/lib/metanorma/iso/boilerplate-ru.xml +0 -38
- data/lib/metanorma/iso/boilerplate.xml +0 -50
@@ -284,6 +284,10 @@
|
|
284
284
|
<xsl:with-param name="root-style" select="$root-style"/>
|
285
285
|
</xsl:call-template>
|
286
286
|
|
287
|
+
<xsl:if test="/iso:iso-standard/iso:metanorma-extension/iso:presentation-metadata/iso:linenumbers = 'true'">
|
288
|
+
<xsl:processing-instruction name="add_line_numbers">true</xsl:processing-instruction>
|
289
|
+
</xsl:if>
|
290
|
+
|
287
291
|
<fo:layout-master-set>
|
288
292
|
|
289
293
|
<!-- cover page -->
|
@@ -1493,9 +1497,13 @@
|
|
1493
1497
|
<xsl:otherwise>
|
1494
1498
|
|
1495
1499
|
<fo:block-container font-weight="bold">
|
1500
|
+
|
1501
|
+
<!-- render 'Contents' outside if role="TOC" -->
|
1502
|
+
<xsl:apply-templates select="*[local-name() = 'title']"/>
|
1503
|
+
|
1496
1504
|
<fo:block role="TOC">
|
1497
1505
|
|
1498
|
-
<xsl:apply-templates/>
|
1506
|
+
<xsl:apply-templates select="node()[not(local-name() = 'title')]"/>
|
1499
1507
|
|
1500
1508
|
<xsl:if test="count(*) = 1 and *[local-name() = 'title']"> <!-- if there isn't user ToC -->
|
1501
1509
|
|
@@ -1516,45 +1524,51 @@
|
|
1516
1524
|
<xsl:if test="@level = 3">
|
1517
1525
|
<xsl:attribute name="margin-top">-0.7pt</xsl:attribute>
|
1518
1526
|
</xsl:if>
|
1519
|
-
|
1520
|
-
|
1521
|
-
|
1522
|
-
|
1523
|
-
|
1524
|
-
|
1525
|
-
|
1526
|
-
|
1527
|
-
|
1528
|
-
<xsl:
|
1529
|
-
|
1530
|
-
|
1531
|
-
|
1532
|
-
|
1533
|
-
|
1534
|
-
|
1535
|
-
|
1536
|
-
|
1537
|
-
|
1538
|
-
|
1539
|
-
|
1540
|
-
|
1541
|
-
|
1542
|
-
|
1543
|
-
|
1544
|
-
|
1545
|
-
<
|
1546
|
-
|
1547
|
-
|
1548
|
-
|
1549
|
-
|
1550
|
-
|
1527
|
+
|
1528
|
+
<fo:basic-link internal-destination="{@id}" fox:alt-text="{@section} {title}"> <!-- link at this level needs for PDF structure tags -->
|
1529
|
+
|
1530
|
+
<fo:list-block role="SKIP">
|
1531
|
+
<xsl:attribute name="margin-left"><xsl:value-of select="$margin-left * (@level - 1)"/>mm</xsl:attribute>
|
1532
|
+
<xsl:if test="@level >= 2 or @type = 'annex'">
|
1533
|
+
<xsl:attribute name="font-weight">normal</xsl:attribute>
|
1534
|
+
</xsl:if>
|
1535
|
+
<xsl:attribute name="provisional-distance-between-starts">
|
1536
|
+
<xsl:choose>
|
1537
|
+
<!-- skip 0 section without subsections -->
|
1538
|
+
<xsl:when test="@level >= 3"><xsl:value-of select="$margin-left * 1.2"/>mm</xsl:when>
|
1539
|
+
<xsl:when test="@section != ''"><xsl:value-of select="$margin-left"/>mm</xsl:when>
|
1540
|
+
<xsl:otherwise>0mm</xsl:otherwise>
|
1541
|
+
</xsl:choose>
|
1542
|
+
</xsl:attribute>
|
1543
|
+
<fo:list-item role="SKIP">
|
1544
|
+
<fo:list-item-label end-indent="label-end()" role="SKIP">
|
1545
|
+
<fo:block role="SKIP">
|
1546
|
+
<xsl:value-of select="@section"/>
|
1547
|
+
</fo:block>
|
1548
|
+
</fo:list-item-label>
|
1549
|
+
<fo:list-item-body start-indent="body-start()" role="SKIP">
|
1550
|
+
<fo:block text-align-last="justify" margin-left="12mm" text-indent="-12mm" role="SKIP">
|
1551
|
+
<fo:basic-link internal-destination="{@id}" fox:alt-text="{title}" role="SKIP">
|
1552
|
+
|
1553
|
+
<xsl:apply-templates select="title"/>
|
1554
|
+
|
1555
|
+
<fo:inline keep-together.within-line="always" role="SKIP">
|
1556
|
+
<fo:leader font-size="9pt" font-weight="normal" leader-pattern="dots"/>
|
1557
|
+
<fo:inline role="SKIP">
|
1558
|
+
<xsl:if test="@level = 1 and @type = 'annex'">
|
1559
|
+
<xsl:attribute name="font-weight">bold</xsl:attribute>
|
1560
|
+
</xsl:if>
|
1561
|
+
<fo:wrapper role="artifact">
|
1562
|
+
<fo:page-number-citation ref-id="{@id}"/>
|
1563
|
+
</fo:wrapper>
|
1564
|
+
</fo:inline>
|
1551
1565
|
</fo:inline>
|
1552
|
-
</fo:
|
1553
|
-
</fo:
|
1554
|
-
</fo:
|
1555
|
-
</fo:list-item
|
1556
|
-
</fo:list-
|
1557
|
-
</fo:
|
1566
|
+
</fo:basic-link>
|
1567
|
+
</fo:block>
|
1568
|
+
</fo:list-item-body>
|
1569
|
+
</fo:list-item>
|
1570
|
+
</fo:list-block>
|
1571
|
+
</fo:basic-link>
|
1558
1572
|
</fo:block>
|
1559
1573
|
|
1560
1574
|
</xsl:for-each>
|
@@ -1588,16 +1602,16 @@
|
|
1588
1602
|
|
1589
1603
|
<xsl:template match="iso:preface/iso:clause[@type = 'toc']/iso:title" priority="3">
|
1590
1604
|
<fo:block text-align-last="justify" font-size="16pt" margin-top="10pt" margin-bottom="18pt">
|
1591
|
-
<fo:inline font-size="16pt" font-weight="bold" role="
|
1605
|
+
<fo:inline font-size="16pt" font-weight="bold" role="SKIP">
|
1592
1606
|
<!-- Contents -->
|
1593
1607
|
<!-- <xsl:call-template name="getLocalizedString">
|
1594
1608
|
<xsl:with-param name="key">table_of_contents</xsl:with-param>
|
1595
1609
|
</xsl:call-template> -->
|
1596
1610
|
<xsl:apply-templates/>
|
1597
1611
|
</fo:inline>
|
1598
|
-
<fo:inline keep-together.within-line="always">
|
1612
|
+
<fo:inline keep-together.within-line="always" role="SKIP">
|
1599
1613
|
<fo:leader leader-pattern="space"/>
|
1600
|
-
<fo:inline font-weight="normal" font-size="10pt">
|
1614
|
+
<fo:inline font-weight="normal" font-size="10pt" role="SKIP">
|
1601
1615
|
<!-- Page -->
|
1602
1616
|
<xsl:call-template name="getLocalizedString">
|
1603
1617
|
<xsl:with-param name="key">locality.page</xsl:with-param>
|
@@ -2027,6 +2041,9 @@
|
|
2027
2041
|
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
2028
2042
|
<xsl:attribute name="line-height">0</xsl:attribute>
|
2029
2043
|
</xsl:if>
|
2044
|
+
<xsl:if test="ancestor::*[local-name() = 'li' or local-name() = 'td' or local-name() = 'th' or local-name() = 'dd']">
|
2045
|
+
<xsl:attribute name="role">SKIP</xsl:attribute>
|
2046
|
+
</xsl:if>
|
2030
2047
|
<xsl:apply-templates>
|
2031
2048
|
<xsl:with-param name="split_keep-within-line" select="$split_keep-within-line"/>
|
2032
2049
|
</xsl:apply-templates>
|
@@ -3386,6 +3403,10 @@
|
|
3386
3403
|
</xsl:attribute-set> <!-- formula-stem-number-style -->
|
3387
3404
|
<!-- End Formula's styles -->
|
3388
3405
|
|
3406
|
+
<xsl:template name="refine_formula-stem-number-style">
|
3407
|
+
|
3408
|
+
</xsl:template>
|
3409
|
+
|
3389
3410
|
<xsl:attribute-set name="image-style">
|
3390
3411
|
<xsl:attribute name="text-align">center</xsl:attribute>
|
3391
3412
|
|
@@ -3882,13 +3903,13 @@
|
|
3882
3903
|
|
3883
3904
|
<xsl:template name="processPrefaceSectionsDefault_Contents">
|
3884
3905
|
<xsl:variable name="nodes_preface_">
|
3885
|
-
<xsl:for-each select="/*/*[local-name()='preface']/*[not(local-name() = 'note' or local-name() = 'admonition')]">
|
3906
|
+
<xsl:for-each select="/*/*[local-name()='preface']/*[not(local-name() = 'note' or local-name() = 'admonition' or @type = 'toc')]">
|
3886
3907
|
<node id="{@id}"/>
|
3887
3908
|
</xsl:for-each>
|
3888
3909
|
</xsl:variable>
|
3889
3910
|
<xsl:variable name="nodes_preface" select="xalan:nodeset($nodes_preface_)"/>
|
3890
3911
|
|
3891
|
-
<xsl:for-each select="/*/*[local-name()='preface']/*[not(local-name() = 'note' or local-name() = 'admonition')]">
|
3912
|
+
<xsl:for-each select="/*/*[local-name()='preface']/*[not(local-name() = 'note' or local-name() = 'admonition' or @type = 'toc')]">
|
3892
3913
|
<xsl:sort select="@displayorder" data-type="number"/>
|
3893
3914
|
|
3894
3915
|
<!-- process Section's title -->
|
@@ -3922,12 +3943,12 @@
|
|
3922
3943
|
<xsl:apply-templates select="." mode="contents"/>
|
3923
3944
|
</xsl:for-each>
|
3924
3945
|
|
3925
|
-
<xsl:for-each select="/*/*[local-name()='annex']">
|
3946
|
+
<!-- <xsl:for-each select="/*/*[local-name()='annex']">
|
3926
3947
|
<xsl:sort select="@displayorder" data-type="number"/>
|
3927
3948
|
<xsl:apply-templates select="." mode="contents"/>
|
3928
|
-
</xsl:for-each>
|
3949
|
+
</xsl:for-each> -->
|
3929
3950
|
|
3930
|
-
<xsl:for-each select="/*/*[local-name()='bibliography']/*[not(@normative='true') and not(*[local-name()='references'][@normative='true'])][count(.//*[local-name() = 'bibitem'][not(@hidden) = 'true']) > 0] | /*/*[local-name()='bibliography']/*[local-name()='clause'][*[local-name()='references'][not(@normative='true')]][count(.//*[local-name() = 'bibitem'][not(@hidden) = 'true']) > 0]">
|
3951
|
+
<xsl:for-each select="/*/*[local-name()='annex'] | /*/*[local-name()='bibliography']/*[not(@normative='true') and not(*[local-name()='references'][@normative='true'])][count(.//*[local-name() = 'bibitem'][not(@hidden) = 'true']) > 0] | /*/*[local-name()='bibliography']/*[local-name()='clause'][*[local-name()='references'][not(@normative='true')]][count(.//*[local-name() = 'bibitem'][not(@hidden) = 'true']) > 0]">
|
3931
3952
|
<xsl:sort select="@displayorder" data-type="number"/>
|
3932
3953
|
<xsl:apply-templates select="." mode="contents"/>
|
3933
3954
|
</xsl:for-each>
|
@@ -4290,7 +4311,7 @@
|
|
4290
4311
|
</xsl:attribute>
|
4291
4312
|
</xsl:for-each>
|
4292
4313
|
|
4293
|
-
<xsl:variable name="isNoteOrFnExist" select="./*[local-name()='note'] or .//*[local-name()='fn'][local-name(..) != 'name'] or ./*[local-name()='source']"/>
|
4314
|
+
<xsl:variable name="isNoteOrFnExist" select="./*[local-name()='note'] or ./*[local-name()='example'] or .//*[local-name()='fn'][local-name(..) != 'name'] or ./*[local-name()='source']"/>
|
4294
4315
|
<xsl:if test="$isNoteOrFnExist = 'true'">
|
4295
4316
|
<xsl:attribute name="border-bottom">0pt solid black</xsl:attribute> <!-- set 0pt border, because there is a separete table below for footer -->
|
4296
4317
|
</xsl:if>
|
@@ -4334,7 +4355,7 @@
|
|
4334
4355
|
<xsl:apply-templates select="*[local-name()='thead']" mode="process_tbody"/>
|
4335
4356
|
</xsl:when>
|
4336
4357
|
<xsl:otherwise>
|
4337
|
-
<xsl:apply-templates select="node()[not(local-name() = 'name') and not(local-name() = 'note') and not(local-name() = 'dl') and not(local-name() = 'source') and not(local-name() = 'p') and not(local-name() = 'thead') and not(local-name() = 'tfoot')]"/> <!-- process all table' elements, except name, header, footer, note, source and dl which render separaterely -->
|
4358
|
+
<xsl:apply-templates select="node()[not(local-name() = 'name') and not(local-name() = 'note') and not(local-name() = 'example') and not(local-name() = 'dl') and not(local-name() = 'source') and not(local-name() = 'p') and not(local-name() = 'thead') and not(local-name() = 'tfoot')]"/> <!-- process all table' elements, except name, header, footer, note, source and dl which render separaterely -->
|
4338
4359
|
</xsl:otherwise>
|
4339
4360
|
</xsl:choose>
|
4340
4361
|
|
@@ -4379,7 +4400,7 @@
|
|
4379
4400
|
<fo:table-row>
|
4380
4401
|
<fo:table-cell column-number="2">
|
4381
4402
|
<xsl:copy-of select="$table-preamble"/>
|
4382
|
-
<fo:block>
|
4403
|
+
<fo:block role="SKIP">
|
4383
4404
|
<xsl:call-template name="setTrackChangesStyles">
|
4384
4405
|
<xsl:with-param name="isAdded" select="$isAdded"/>
|
4385
4406
|
<xsl:with-param name="isDeleted" select="$isDeleted"/>
|
@@ -4427,7 +4448,7 @@
|
|
4427
4448
|
<xsl:param name="continued"/>
|
4428
4449
|
<xsl:if test="normalize-space() != ''">
|
4429
4450
|
|
4430
|
-
<fo:block xsl:use-attribute-sets="table-name-style">
|
4451
|
+
<fo:block xsl:use-attribute-sets="table-name-style" role="SKIP">
|
4431
4452
|
|
4432
4453
|
<xsl:call-template name="refine_table-name-style">
|
4433
4454
|
<xsl:with-param name="continued" select="$continued"/>
|
@@ -4443,10 +4464,10 @@
|
|
4443
4464
|
</xsl:choose>
|
4444
4465
|
|
4445
4466
|
<xsl:if test="$continued = 'true'">
|
4446
|
-
<fo:inline font-weight="bold" font-style="normal">
|
4467
|
+
<fo:inline font-weight="bold" font-style="normal" role="SKIP">
|
4447
4468
|
<fo:retrieve-table-marker retrieve-class-name="table_number"/>
|
4448
4469
|
</fo:inline>
|
4449
|
-
<fo:inline font-weight="normal" font-style="italic">
|
4470
|
+
<fo:inline font-weight="normal" font-style="italic" role="SKIP">
|
4450
4471
|
<xsl:text> </xsl:text>
|
4451
4472
|
<fo:retrieve-table-marker retrieve-class-name="table_continued"/>
|
4452
4473
|
</fo:inline>
|
@@ -4826,8 +4847,8 @@
|
|
4826
4847
|
<xsl:template name="table-header-title">
|
4827
4848
|
<xsl:param name="cols-count"/>
|
4828
4849
|
<!-- row for title -->
|
4829
|
-
<fo:table-row>
|
4830
|
-
<fo:table-cell number-columns-spanned="{$cols-count}" border-left="1.5pt solid white" border-right="1.5pt solid white" border-top="1.5pt solid white" border-bottom="1.5pt solid black">
|
4850
|
+
<fo:table-row role="SKIP">
|
4851
|
+
<fo:table-cell number-columns-spanned="{$cols-count}" border-left="1.5pt solid white" border-right="1.5pt solid white" border-top="1.5pt solid white" border-bottom="1.5pt solid black" role="SKIP">
|
4831
4852
|
|
4832
4853
|
<xsl:call-template name="refine_table-header-title-style"/>
|
4833
4854
|
|
@@ -4836,7 +4857,7 @@
|
|
4836
4857
|
</xsl:apply-templates>
|
4837
4858
|
|
4838
4859
|
<xsl:if test="not(ancestor::*[local-name()='table']/*[local-name()='name'])"> <!-- to prevent empty fo:table-cell in case of missing table's name -->
|
4839
|
-
<fo:block/>
|
4860
|
+
<fo:block role="SKIP"/>
|
4840
4861
|
</xsl:if>
|
4841
4862
|
|
4842
4863
|
<xsl:for-each select="ancestor::*[local-name()='table'][1]">
|
@@ -4881,7 +4902,7 @@
|
|
4881
4902
|
<xsl:param name="colwidths"/>
|
4882
4903
|
<xsl:param name="colgroup"/>
|
4883
4904
|
|
4884
|
-
<xsl:variable name="isNoteOrFnExist" select="../*[local-name()='note'] or ../*[local-name()='dl'] or ..//*[local-name()='fn'][local-name(..) != 'name'] or ../*[local-name()='source'] or ../*[local-name()='p']"/>
|
4905
|
+
<xsl:variable name="isNoteOrFnExist" select="../*[local-name()='note'] or ../*[local-name()='example'] or ../*[local-name()='dl'] or ..//*[local-name()='fn'][local-name(..) != 'name'] or ../*[local-name()='source'] or ../*[local-name()='p']"/>
|
4885
4906
|
|
4886
4907
|
<xsl:variable name="isNoteOrFnExistShowAfterTable">
|
4887
4908
|
|
@@ -4954,6 +4975,7 @@
|
|
4954
4975
|
<xsl:apply-templates select="../*[local-name()='p']"/>
|
4955
4976
|
<xsl:apply-templates select="../*[local-name()='dl']"/>
|
4956
4977
|
<xsl:apply-templates select="../*[local-name()='note']"/>
|
4978
|
+
<xsl:apply-templates select="../*[local-name()='example']"/>
|
4957
4979
|
<xsl:apply-templates select="../*[local-name()='source']"/>
|
4958
4980
|
|
4959
4981
|
<xsl:variable name="isDisplayRowSeparator">
|
@@ -4962,7 +4984,7 @@
|
|
4962
4984
|
|
4963
4985
|
<!-- horizontal row separator -->
|
4964
4986
|
<xsl:if test="normalize-space($isDisplayRowSeparator) = 'true'">
|
4965
|
-
<xsl:if test="../*[local-name()='note'] and normalize-space($table_fn_block) != ''">
|
4987
|
+
<xsl:if test="(../*[local-name()='note'] or ../*[local-name()='example']) and normalize-space($table_fn_block) != ''">
|
4966
4988
|
<fo:block-container border-top="0.5pt solid black" padding-left="1mm" padding-right="1mm">
|
4967
4989
|
|
4968
4990
|
<xsl:call-template name="setBordersTableArray"/>
|
@@ -5042,24 +5064,24 @@
|
|
5042
5064
|
<xsl:variable name="title_start" select="ancestor::*[local-name()='table'][1]/*[local-name()='name']/node()[1][self::text()]"/>
|
5043
5065
|
<xsl:variable name="table_number" select="substring-before($title_start, '—')"/>
|
5044
5066
|
|
5045
|
-
<fo:table-row height="0" keep-with-next.within-page="always">
|
5046
|
-
<fo:table-cell>
|
5067
|
+
<fo:table-row height="0" keep-with-next.within-page="always" role="SKIP">
|
5068
|
+
<fo:table-cell role="SKIP">
|
5047
5069
|
|
5048
5070
|
<fo:marker marker-class-name="table_number"/>
|
5049
5071
|
<fo:marker marker-class-name="table_continued"/>
|
5050
5072
|
|
5051
|
-
<fo:block/>
|
5073
|
+
<fo:block role="SKIP"/>
|
5052
5074
|
</fo:table-cell>
|
5053
5075
|
</fo:table-row>
|
5054
|
-
<fo:table-row height="0" keep-with-next.within-page="always">
|
5055
|
-
<fo:table-cell>
|
5076
|
+
<fo:table-row height="0" keep-with-next.within-page="always" role="SKIP">
|
5077
|
+
<fo:table-cell role="SKIP">
|
5056
5078
|
|
5057
5079
|
<fo:marker marker-class-name="table_number"><xsl:value-of select="normalize-space(translate($table_number, ' ', ' '))"/></fo:marker>
|
5058
5080
|
|
5059
5081
|
<fo:marker marker-class-name="table_continued">
|
5060
5082
|
<xsl:value-of select="$title_continued"/>
|
5061
5083
|
</fo:marker>
|
5062
|
-
<fo:block/>
|
5084
|
+
<fo:block role="SKIP"/>
|
5063
5085
|
</fo:table-cell>
|
5064
5086
|
</fo:table-row>
|
5065
5087
|
|
@@ -5200,7 +5222,7 @@
|
|
5200
5222
|
|
5201
5223
|
<xsl:call-template name="refine_table-header-cell-style"/>
|
5202
5224
|
|
5203
|
-
<fo:block>
|
5225
|
+
<fo:block role="SKIP">
|
5204
5226
|
<xsl:apply-templates/>
|
5205
5227
|
</fo:block>
|
5206
5228
|
</fo:table-cell>
|
@@ -5253,7 +5275,7 @@
|
|
5253
5275
|
<xsl:attribute name="text-align">left</xsl:attribute>
|
5254
5276
|
</xsl:if>
|
5255
5277
|
|
5256
|
-
<fo:block>
|
5278
|
+
<fo:block role="SKIP">
|
5257
5279
|
|
5258
5280
|
<xsl:if test="$isGenerateTableIF = 'true'">
|
5259
5281
|
<xsl:attribute name="id"><xsl:value-of select="@id"/></xsl:attribute>
|
@@ -5267,13 +5289,13 @@
|
|
5267
5289
|
</fo:table-cell>
|
5268
5290
|
</xsl:template> <!-- td -->
|
5269
5291
|
|
5270
|
-
<xsl:template match="*[local-name()='table']/*[local-name()='note']" priority="2">
|
5292
|
+
<xsl:template match="*[local-name()='table']/*[local-name()='note' or local-name() = 'example']" priority="2">
|
5271
5293
|
|
5272
5294
|
<fo:block xsl:use-attribute-sets="table-note-style">
|
5273
5295
|
|
5274
5296
|
<xsl:call-template name="refine_table-note-style"/>
|
5275
5297
|
|
5276
|
-
<!-- Table's note name (NOTE, for example) -->
|
5298
|
+
<!-- Table's note/example name (NOTE, for example) -->
|
5277
5299
|
<fo:inline xsl:use-attribute-sets="table-note-name-style">
|
5278
5300
|
|
5279
5301
|
<xsl:call-template name="refine_table-note-name-style"/>
|
@@ -5287,7 +5309,7 @@
|
|
5287
5309
|
|
5288
5310
|
</xsl:template> <!-- table/note -->
|
5289
5311
|
|
5290
|
-
<xsl:template match="*[local-name()='table']/*[local-name()='note']/*[local-name()='p']" priority="2">
|
5312
|
+
<xsl:template match="*[local-name()='table']/*[local-name()='note' or local-name()='example']/*[local-name()='p']" priority="2">
|
5291
5313
|
<xsl:apply-templates/>
|
5292
5314
|
</xsl:template>
|
5293
5315
|
|
@@ -6136,7 +6158,7 @@
|
|
6136
6158
|
-->
|
6137
6159
|
<fo:table-row>
|
6138
6160
|
<fo:table-cell number-columns-spanned="2">
|
6139
|
-
<fo:block>
|
6161
|
+
<fo:block role="SKIP">
|
6140
6162
|
<xsl:call-template name="note"/>
|
6141
6163
|
</fo:block>
|
6142
6164
|
</fo:table-cell>
|
@@ -6201,7 +6223,7 @@
|
|
6201
6223
|
|
6202
6224
|
<xsl:call-template name="refine_dt-cell-style"/>
|
6203
6225
|
|
6204
|
-
<fo:block xsl:use-attribute-sets="dt-block-style">
|
6226
|
+
<fo:block xsl:use-attribute-sets="dt-block-style" role="SKIP">
|
6205
6227
|
<xsl:copy-of select="@id"/>
|
6206
6228
|
|
6207
6229
|
<xsl:if test="normalize-space($key_iso) = 'true'">
|
@@ -6231,7 +6253,7 @@
|
|
6231
6253
|
|
6232
6254
|
<xsl:call-template name="refine_dd-cell-style"/>
|
6233
6255
|
|
6234
|
-
<fo:block>
|
6256
|
+
<fo:block role="SKIP">
|
6235
6257
|
|
6236
6258
|
<xsl:if test="$isGenerateTableIF = 'true'">
|
6237
6259
|
<xsl:attribute name="id"><xsl:value-of select="@id"/></xsl:attribute>
|
@@ -6373,10 +6395,19 @@
|
|
6373
6395
|
<!-- ========================= -->
|
6374
6396
|
<xsl:template match="*[local-name()='em']">
|
6375
6397
|
<fo:inline font-style="italic">
|
6398
|
+
<xsl:call-template name="refine_italic_style"/>
|
6376
6399
|
<xsl:apply-templates/>
|
6377
6400
|
</fo:inline>
|
6378
6401
|
</xsl:template>
|
6379
6402
|
|
6403
|
+
<xsl:template name="refine_italic_style">
|
6404
|
+
|
6405
|
+
<xsl:if test="ancestor::*[local-name() = 'item']">
|
6406
|
+
<xsl:attribute name="role">SKIP</xsl:attribute>
|
6407
|
+
</xsl:if>
|
6408
|
+
|
6409
|
+
</xsl:template>
|
6410
|
+
|
6380
6411
|
<xsl:template match="*[local-name()='strong'] | *[local-name()='b']">
|
6381
6412
|
<xsl:param name="split_keep-within-line"/>
|
6382
6413
|
<fo:inline font-weight="bold">
|
@@ -6391,6 +6422,10 @@
|
|
6391
6422
|
|
6392
6423
|
<xsl:template name="refine_strong_style">
|
6393
6424
|
|
6425
|
+
<xsl:if test="ancestor::*[local-name() = 'item']">
|
6426
|
+
<xsl:attribute name="role">SKIP</xsl:attribute>
|
6427
|
+
</xsl:if>
|
6428
|
+
|
6394
6429
|
</xsl:template>
|
6395
6430
|
|
6396
6431
|
<xsl:template match="*[local-name()='padding']">
|
@@ -6599,11 +6634,41 @@
|
|
6599
6634
|
|
6600
6635
|
<xsl:template match="text()[ancestor::*[local-name()='smallcap']]">
|
6601
6636
|
<xsl:variable name="text" select="normalize-space(.)"/>
|
6602
|
-
<fo:inline font-size="75%">
|
6637
|
+
<fo:inline font-size="75%" role="SKIP">
|
6603
6638
|
<xsl:if test="string-length($text) > 0">
|
6604
|
-
<xsl:
|
6605
|
-
<xsl:
|
6606
|
-
|
6639
|
+
<xsl:variable name="smallCapsText">
|
6640
|
+
<xsl:call-template name="recursiveSmallCaps">
|
6641
|
+
<xsl:with-param name="text" select="$text"/>
|
6642
|
+
</xsl:call-template>
|
6643
|
+
</xsl:variable>
|
6644
|
+
<!-- merge neighboring fo:inline -->
|
6645
|
+
<xsl:for-each select="xalan:nodeset($smallCapsText)/node()">
|
6646
|
+
<xsl:choose>
|
6647
|
+
<xsl:when test="self::fo:inline and preceding-sibling::node()[1][self::fo:inline]"><!-- <xsl:copy-of select="."/> --></xsl:when>
|
6648
|
+
<xsl:when test="self::fo:inline and @font-size">
|
6649
|
+
<xsl:variable name="curr_pos" select="count(preceding-sibling::node()) + 1"/>
|
6650
|
+
<!-- <curr_pos><xsl:value-of select="$curr_pos"/></curr_pos> -->
|
6651
|
+
<xsl:variable name="next_text_" select="count(following-sibling::node()[not(local-name() = 'inline')][1]/preceding-sibling::node())"/>
|
6652
|
+
<xsl:variable name="next_text">
|
6653
|
+
<xsl:choose>
|
6654
|
+
<xsl:when test="$next_text_ = 0">99999999</xsl:when>
|
6655
|
+
<xsl:otherwise><xsl:value-of select="$next_text_ + 1"/></xsl:otherwise>
|
6656
|
+
</xsl:choose>
|
6657
|
+
</xsl:variable>
|
6658
|
+
<!-- <next_text><xsl:value-of select="$next_text"/></next_text> -->
|
6659
|
+
<fo:inline>
|
6660
|
+
<xsl:copy-of select="@*"/>
|
6661
|
+
<xsl:copy-of select="./node()"/>
|
6662
|
+
<xsl:for-each select="following-sibling::node()[position() < $next_text - $curr_pos]"> <!-- [self::fo:inline] -->
|
6663
|
+
<xsl:copy-of select="./node()"/>
|
6664
|
+
</xsl:for-each>
|
6665
|
+
</fo:inline>
|
6666
|
+
</xsl:when>
|
6667
|
+
<xsl:otherwise>
|
6668
|
+
<xsl:copy-of select="."/>
|
6669
|
+
</xsl:otherwise>
|
6670
|
+
</xsl:choose>
|
6671
|
+
</xsl:for-each>
|
6607
6672
|
</xsl:if>
|
6608
6673
|
</fo:inline>
|
6609
6674
|
</xsl:template>
|
@@ -6615,7 +6680,7 @@
|
|
6615
6680
|
<xsl:variable name="upperCase" select="java:toUpperCase(java:java.lang.String.new($char))"/>
|
6616
6681
|
<xsl:choose>
|
6617
6682
|
<xsl:when test="$char=$upperCase">
|
6618
|
-
<fo:inline font-size="{100 div 0.75}%">
|
6683
|
+
<fo:inline font-size="{100 div 0.75}%" role="SKIP">
|
6619
6684
|
<xsl:value-of select="$upperCase"/>
|
6620
6685
|
</fo:inline>
|
6621
6686
|
</xsl:when>
|
@@ -6848,6 +6913,10 @@
|
|
6848
6913
|
|
6849
6914
|
<xsl:when test="not(contains($text, $separator))">
|
6850
6915
|
<word>
|
6916
|
+
<xsl:if test="ancestor::*[local-name() = 'p'][@from_dl = 'true']">
|
6917
|
+
<xsl:text>
|
6918
|
+
</xsl:text> <!-- to add distance between dt and dd -->
|
6919
|
+
</xsl:if>
|
6851
6920
|
<xsl:call-template name="enclose_text_in_tags">
|
6852
6921
|
<xsl:with-param name="text" select="normalize-space($text)"/>
|
6853
6922
|
<xsl:with-param name="tags" select="$tags"/>
|
@@ -6856,6 +6925,10 @@
|
|
6856
6925
|
</xsl:when>
|
6857
6926
|
<xsl:otherwise>
|
6858
6927
|
<word>
|
6928
|
+
<xsl:if test="ancestor::*[local-name() = 'p'][@from_dl = 'true']">
|
6929
|
+
<xsl:text>
|
6930
|
+
</xsl:text> <!-- to add distance between dt and dd -->
|
6931
|
+
</xsl:if>
|
6859
6932
|
<xsl:call-template name="enclose_text_in_tags">
|
6860
6933
|
<xsl:with-param name="text" select="normalize-space(substring-before($text, $separator))"/>
|
6861
6934
|
<xsl:with-param name="tags" select="$tags"/>
|
@@ -7039,6 +7112,10 @@
|
|
7039
7112
|
<xsl:template name="getSimpleTable">
|
7040
7113
|
<xsl:param name="id"/>
|
7041
7114
|
|
7115
|
+
<!-- <test0>
|
7116
|
+
<xsl:copy-of select="."/>
|
7117
|
+
</test0> -->
|
7118
|
+
|
7042
7119
|
<xsl:variable name="simple-table">
|
7043
7120
|
|
7044
7121
|
<!-- Step 0. replace <br/> to <p>...</p> -->
|
@@ -8091,7 +8168,7 @@
|
|
8091
8168
|
<fo:table-body>
|
8092
8169
|
<fo:table-row>
|
8093
8170
|
<fo:table-cell display-align="center">
|
8094
|
-
<fo:block xsl:use-attribute-sets="formula-stem-block-style">
|
8171
|
+
<fo:block xsl:use-attribute-sets="formula-stem-block-style" role="SKIP">
|
8095
8172
|
|
8096
8173
|
<xsl:call-template name="refine_formula-stem-block-style"/>
|
8097
8174
|
|
@@ -8099,7 +8176,10 @@
|
|
8099
8176
|
</fo:block>
|
8100
8177
|
</fo:table-cell>
|
8101
8178
|
<fo:table-cell display-align="center">
|
8102
|
-
<fo:block xsl:use-attribute-sets="formula-stem-number-style">
|
8179
|
+
<fo:block xsl:use-attribute-sets="formula-stem-number-style" role="SKIP">
|
8180
|
+
|
8181
|
+
<xsl:call-template name="refine_formula-stem-number-style"/>
|
8182
|
+
|
8103
8183
|
<xsl:apply-templates select="../*[local-name() = 'name']"/>
|
8104
8184
|
</fo:block>
|
8105
8185
|
</fo:table-cell>
|
@@ -9611,7 +9691,7 @@
|
|
9611
9691
|
<!-- second td with sourcecode -->
|
9612
9692
|
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']//*[local-name()='tr']/*[local-name()='td'][preceding-sibling::*]" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode'] -->
|
9613
9693
|
<fo:table-cell>
|
9614
|
-
<fo:block>
|
9694
|
+
<fo:block role="SKIP">
|
9615
9695
|
<xsl:apply-templates/>
|
9616
9696
|
</fo:block>
|
9617
9697
|
</fo:table-cell>
|
@@ -10100,7 +10180,7 @@
|
|
10100
10180
|
|
10101
10181
|
<xsl:call-template name="setTableCellAttributes"/>
|
10102
10182
|
|
10103
|
-
<fo:block>
|
10183
|
+
<fo:block role="SKIP">
|
10104
10184
|
<xsl:apply-templates/>
|
10105
10185
|
</fo:block>
|
10106
10186
|
</fo:table-cell>
|
@@ -10122,7 +10202,7 @@
|
|
10122
10202
|
|
10123
10203
|
<xsl:call-template name="setTableCellAttributes"/>
|
10124
10204
|
|
10125
|
-
<fo:block>
|
10205
|
+
<fo:block role="SKIP">
|
10126
10206
|
<xsl:apply-templates/>
|
10127
10207
|
</fo:block>
|
10128
10208
|
</fo:table-cell>
|
@@ -10317,6 +10397,12 @@
|
|
10317
10397
|
|
10318
10398
|
</xsl:template>
|
10319
10399
|
|
10400
|
+
<xsl:template match="*[local-name() = 'table']/*[local-name() = 'example']/*[local-name() = 'name']">
|
10401
|
+
<fo:inline xsl:use-attribute-sets="example-name-style">
|
10402
|
+
<xsl:apply-templates/>
|
10403
|
+
</fo:inline>
|
10404
|
+
</xsl:template>
|
10405
|
+
|
10320
10406
|
<xsl:template match="*[local-name() = 'example']/*[local-name() = 'p']">
|
10321
10407
|
<xsl:param name="fo_element">block</xsl:param>
|
10322
10408
|
|
@@ -10891,6 +10977,50 @@
|
|
10891
10977
|
<xsl:otherwise><xsl:call-template name="setULLabel"/></xsl:otherwise>
|
10892
10978
|
</xsl:choose>
|
10893
10979
|
</xsl:when>
|
10980
|
+
<xsl:when test="local-name(..) = 'ol' and @label"> <!-- for ordered lists 'ol', and if there is @label, for instance label="1.1.2" -->
|
10981
|
+
|
10982
|
+
<xsl:variable name="label">
|
10983
|
+
|
10984
|
+
<xsl:variable name="type" select="../@type"/>
|
10985
|
+
|
10986
|
+
<xsl:variable name="style_prefix_">
|
10987
|
+
<xsl:if test="$type = 'roman'">
|
10988
|
+
<!-- Example: (i) -->
|
10989
|
+
</xsl:if>
|
10990
|
+
</xsl:variable>
|
10991
|
+
<xsl:variable name="style_prefix" select="normalize-space($style_prefix_)"/>
|
10992
|
+
|
10993
|
+
<xsl:variable name="style_suffix_">
|
10994
|
+
<xsl:choose>
|
10995
|
+
<xsl:when test="$type = 'arabic'">
|
10996
|
+
)
|
10997
|
+
</xsl:when>
|
10998
|
+
<xsl:when test="$type = 'alphabet' or $type = 'alphabetic'">
|
10999
|
+
)
|
11000
|
+
</xsl:when>
|
11001
|
+
<xsl:when test="$type = 'alphabet_upper' or $type = 'alphabetic_upper'">
|
11002
|
+
.
|
11003
|
+
</xsl:when>
|
11004
|
+
<xsl:when test="$type = 'roman'">
|
11005
|
+
)
|
11006
|
+
</xsl:when>
|
11007
|
+
<xsl:when test="$type = 'roman_upper'">.</xsl:when> <!-- Example: I. -->
|
11008
|
+
</xsl:choose>
|
11009
|
+
</xsl:variable>
|
11010
|
+
<xsl:variable name="style_suffix" select="normalize-space($style_suffix_)"/>
|
11011
|
+
|
11012
|
+
<xsl:if test="$style_prefix != '' and not(starts-with(@label, $style_prefix))">
|
11013
|
+
<xsl:value-of select="$style_prefix"/>
|
11014
|
+
</xsl:if>
|
11015
|
+
<xsl:value-of select="@label"/>
|
11016
|
+
<xsl:if test="not(java:endsWith(java:java.lang.String.new(@label),$style_suffix))">
|
11017
|
+
<xsl:value-of select="$style_suffix"/>
|
11018
|
+
</xsl:if>
|
11019
|
+
</xsl:variable>
|
11020
|
+
|
11021
|
+
<xsl:value-of select="normalize-space($label)"/>
|
11022
|
+
|
11023
|
+
</xsl:when>
|
10894
11024
|
<xsl:otherwise> <!-- for ordered lists 'ol' -->
|
10895
11025
|
|
10896
11026
|
<!-- Example: for BSI <?list-start 2?> -->
|
@@ -10948,10 +11078,10 @@
|
|
10948
11078
|
<xsl:when test="$type = 'arabic'">
|
10949
11079
|
1)
|
10950
11080
|
</xsl:when>
|
10951
|
-
<xsl:when test="$type = 'alphabet'">
|
11081
|
+
<xsl:when test="$type = 'alphabet' or $type = 'alphabetic'">
|
10952
11082
|
a)
|
10953
11083
|
</xsl:when>
|
10954
|
-
<xsl:when test="$type = 'alphabet_upper'">
|
11084
|
+
<xsl:when test="$type = 'alphabet_upper' or $type = 'alphabetic_upper'">
|
10955
11085
|
A.
|
10956
11086
|
</xsl:when>
|
10957
11087
|
<xsl:when test="$type = 'roman'">
|
@@ -11082,7 +11212,7 @@
|
|
11082
11212
|
<xsl:call-template name="refine_list-item-style"/>
|
11083
11213
|
|
11084
11214
|
<fo:list-item-label end-indent="label-end()">
|
11085
|
-
<fo:block xsl:use-attribute-sets="list-item-label-style">
|
11215
|
+
<fo:block xsl:use-attribute-sets="list-item-label-style" role="SKIP">
|
11086
11216
|
|
11087
11217
|
<xsl:call-template name="refine_list-item-label-style"/>
|
11088
11218
|
|
@@ -11096,7 +11226,7 @@
|
|
11096
11226
|
</fo:block>
|
11097
11227
|
</fo:list-item-label>
|
11098
11228
|
<fo:list-item-body start-indent="body-start()" xsl:use-attribute-sets="list-item-body-style">
|
11099
|
-
<fo:block>
|
11229
|
+
<fo:block role="SKIP">
|
11100
11230
|
|
11101
11231
|
<xsl:call-template name="refine_list-item-body-style"/>
|
11102
11232
|
|
@@ -11375,10 +11505,10 @@
|
|
11375
11505
|
<fo:table-body>
|
11376
11506
|
<fo:table-row text-align="center" font-weight="bold" background-color="black" color="white">
|
11377
11507
|
|
11378
|
-
<fo:table-cell border="1pt solid black"><fo:block>Date</fo:block></fo:table-cell>
|
11379
|
-
<fo:table-cell border="1pt solid black"><fo:block>Type</fo:block></fo:table-cell>
|
11380
|
-
<fo:table-cell border="1pt solid black"><fo:block>Change</fo:block></fo:table-cell>
|
11381
|
-
<fo:table-cell border="1pt solid black"><fo:block>Pages</fo:block></fo:table-cell>
|
11508
|
+
<fo:table-cell border="1pt solid black"><fo:block role="SKIP">Date</fo:block></fo:table-cell>
|
11509
|
+
<fo:table-cell border="1pt solid black"><fo:block role="SKIP">Type</fo:block></fo:table-cell>
|
11510
|
+
<fo:table-cell border="1pt solid black"><fo:block role="SKIP">Change</fo:block></fo:table-cell>
|
11511
|
+
<fo:table-cell border="1pt solid black"><fo:block role="SKIP">Pages</fo:block></fo:table-cell>
|
11382
11512
|
</fo:table-row>
|
11383
11513
|
<xsl:apply-templates/>
|
11384
11514
|
</fo:table-body>
|
@@ -11393,7 +11523,7 @@
|
|
11393
11523
|
|
11394
11524
|
<xsl:template match="*[local-name() = 'errata']/*[local-name() = 'row']/*">
|
11395
11525
|
<fo:table-cell border="1pt solid black" padding-left="1mm" padding-top="0.5mm">
|
11396
|
-
<fo:block><xsl:apply-templates/></fo:block>
|
11526
|
+
<fo:block role="SKIP"><xsl:apply-templates/></fo:block>
|
11397
11527
|
</fo:table-cell>
|
11398
11528
|
</xsl:template>
|
11399
11529
|
<!-- ============ -->
|
@@ -11464,8 +11594,8 @@
|
|
11464
11594
|
<fo:list-block id="{@id}" xsl:use-attribute-sets="bibitem-non-normative-list-style">
|
11465
11595
|
<fo:list-item>
|
11466
11596
|
<fo:list-item-label end-indent="label-end()">
|
11467
|
-
<fo:block>
|
11468
|
-
<fo:inline>
|
11597
|
+
<fo:block role="SKIP">
|
11598
|
+
<fo:inline role="SKIP">
|
11469
11599
|
|
11470
11600
|
<xsl:apply-templates select="*[local-name() = 'biblio-tag']">
|
11471
11601
|
<xsl:with-param name="biblio_tag_part">first</xsl:with-param>
|
@@ -11474,7 +11604,7 @@
|
|
11474
11604
|
</fo:block>
|
11475
11605
|
</fo:list-item-label>
|
11476
11606
|
<fo:list-item-body start-indent="body-start()">
|
11477
|
-
<fo:block xsl:use-attribute-sets="bibitem-non-normative-list-body-style">
|
11607
|
+
<fo:block xsl:use-attribute-sets="bibitem-non-normative-list-body-style" role="SKIP">
|
11478
11608
|
<xsl:call-template name="processBibitem">
|
11479
11609
|
<xsl:with-param name="biblio_tag_part">last</xsl:with-param>
|
11480
11610
|
</xsl:call-template>
|
@@ -11696,7 +11826,7 @@
|
|
11696
11826
|
<xsl:for-each select="*[local-name() = 'tab']">
|
11697
11827
|
<xsl:variable name="current_id" select="generate-id()"/>
|
11698
11828
|
<fo:table-cell>
|
11699
|
-
<fo:block line-height-shift-adjustment="disregard-shifts">
|
11829
|
+
<fo:block line-height-shift-adjustment="disregard-shifts" role="SKIP">
|
11700
11830
|
<xsl:call-template name="insert_basic_link">
|
11701
11831
|
<xsl:with-param name="element">
|
11702
11832
|
<fo:basic-link internal-destination="{$target}" fox:alt-text="{.}">
|
@@ -11714,7 +11844,7 @@
|
|
11714
11844
|
</xsl:for-each>
|
11715
11845
|
<!-- last column - for page numbers -->
|
11716
11846
|
<fo:table-cell text-align="right" font-size="10pt" font-weight="bold" font-family="Arial">
|
11717
|
-
<fo:block>
|
11847
|
+
<fo:block role="SKIP">
|
11718
11848
|
<xsl:call-template name="insert_basic_link">
|
11719
11849
|
<xsl:with-param name="element">
|
11720
11850
|
<fo:basic-link internal-destination="{$target}" fox:alt-text="{.}">
|