metanorma-ogc 1.3.8 → 1.4.3
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 +173 -0
- data/lib/asciidoctor/ogc/converter.rb +62 -64
- data/lib/asciidoctor/ogc/front.rb +1 -1
- data/lib/asciidoctor/ogc/isodoc.rng +49 -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 +541 -155
- data/lib/isodoc/ogc/ogc.best-practice.xsl +541 -155
- data/lib/isodoc/ogc/ogc.change-request-supporting-document.xsl +541 -155
- data/lib/isodoc/ogc/ogc.community-practice.xsl +541 -155
- data/lib/isodoc/ogc/ogc.community-standard.xsl +541 -155
- data/lib/isodoc/ogc/ogc.discussion-paper.xsl +541 -155
- data/lib/isodoc/ogc/ogc.engineering-report.xsl +541 -155
- data/lib/isodoc/ogc/ogc.other.xsl +541 -155
- data/lib/isodoc/ogc/ogc.policy.xsl +541 -155
- data/lib/isodoc/ogc/ogc.reference-model.xsl +541 -155
- data/lib/isodoc/ogc/ogc.release-notes.xsl +541 -155
- data/lib/isodoc/ogc/ogc.standard.xsl +541 -155
- data/lib/isodoc/ogc/ogc.test-suite.xsl +541 -155
- data/lib/isodoc/ogc/ogc.user-guide.xsl +541 -155
- data/lib/isodoc/ogc/ogc.white-paper.xsl +400 -96
- data/lib/isodoc/ogc/presentation_xml_convert.rb +58 -48
- data/lib/isodoc/ogc/reqt.rb +90 -36
- 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
@@ -174,7 +174,7 @@
|
|
174
174
|
|
175
175
|
<fo:block-container absolute-position="fixed" left="16.5mm" top="83mm" height="90mm">
|
176
176
|
<fo:block-container width="155mm">
|
177
|
-
<fo:block font-size="33pt">
|
177
|
+
<fo:block font-size="33pt" role="H1">
|
178
178
|
<xsl:call-template name="addLetterSpacing">
|
179
179
|
<xsl:with-param name="text" select="java:toUpperCase(java:java.lang.String.new($doctitle))"/>
|
180
180
|
<xsl:with-param name="letter-spacing" select="1.1"/>
|
@@ -332,7 +332,7 @@
|
|
332
332
|
<fo:block-container margin-left="-18mm">
|
333
333
|
<fo:block-container margin-left="0mm">
|
334
334
|
<fo:block margin-bottom="40pt">
|
335
|
-
<fo:block font-size="33pt" margin-bottom="4pt">
|
335
|
+
<fo:block font-size="33pt" margin-bottom="4pt" role="H1">
|
336
336
|
<xsl:call-template name="addLetterSpacing">
|
337
337
|
<xsl:with-param name="text" select="java:toUpperCase(java:java.lang.String.new($title-toc))"/>
|
338
338
|
<xsl:with-param name="letter-spacing" select="1.1"/>
|
@@ -348,73 +348,73 @@
|
|
348
348
|
|
349
349
|
|
350
350
|
<fo:block-container line-height="130%">
|
351
|
-
|
352
|
-
|
353
|
-
|
354
|
-
<fo:block>
|
355
|
-
<xsl:if test="@level = 1">
|
356
|
-
<xsl:attribute name="margin-top">14pt</xsl:attribute>
|
357
|
-
</xsl:if>
|
358
|
-
<xsl:if test="@level = 1 or @parent = 'annex'">
|
359
|
-
<xsl:attribute name="font-size">12pt</xsl:attribute>
|
360
|
-
</xsl:if>
|
361
|
-
<xsl:if test="@level = 2 and not(@parent = 'annex')">
|
362
|
-
<xsl:attribute name="font-size">10pt</xsl:attribute>
|
363
|
-
</xsl:if>
|
364
|
-
|
365
|
-
<xsl:choose>
|
366
|
-
<xsl:when test="@level = 1">
|
367
|
-
<fo:list-block provisional-distance-between-starts="7mm">
|
368
|
-
<xsl:if test="@type = 'annex'">
|
369
|
-
<xsl:attribute name="provisional-distance-between-starts">0mm</xsl:attribute>
|
370
|
-
</xsl:if>
|
371
|
-
<fo:list-item>
|
372
|
-
<fo:list-item-label end-indent="label-end()">
|
373
|
-
<fo:block>
|
374
|
-
<xsl:value-of select="java:toUpperCase(java:java.lang.String.new(@section))"/>
|
375
|
-
</fo:block>
|
376
|
-
</fo:list-item-label>
|
377
|
-
<fo:list-item-body start-indent="body-start()">
|
378
|
-
<fo:block text-align-last="justify" margin-left="12mm" text-indent="-12mm">
|
379
|
-
<fo:basic-link internal-destination="{@id}" fox:alt-text="{text()}">
|
380
|
-
<xsl:variable name="sectionTitle">
|
381
|
-
<xsl:apply-templates select="title"/>
|
382
|
-
</xsl:variable>
|
383
|
-
<xsl:value-of select="java:toUpperCase(java:java.lang.String.new($sectionTitle))"/>
|
384
|
-
<xsl:text> </xsl:text>
|
385
|
-
<fo:inline keep-together.within-line="always">
|
386
|
-
<fo:leader leader-pattern="dots"/>
|
387
|
-
<fo:inline><fo:page-number-citation ref-id="{@id}"/></fo:inline>
|
388
|
-
</fo:inline>
|
389
|
-
</fo:basic-link>
|
390
|
-
</fo:block>
|
391
|
-
</fo:list-item-body>
|
392
|
-
</fo:list-item>
|
393
|
-
</fo:list-block>
|
394
|
-
</xsl:when>
|
395
|
-
<xsl:otherwise>
|
396
|
-
<fo:block text-align-last="justify" margin-left="7mm">
|
397
|
-
<fo:basic-link internal-destination="{@id}" fox:alt-text="{text()}">
|
398
|
-
<xsl:value-of select="java:toUpperCase(java:java.lang.String.new(@section))"/>
|
399
|
-
<xsl:text> </xsl:text>
|
400
|
-
<xsl:apply-templates select="title"/>
|
401
|
-
<xsl:text> </xsl:text>
|
402
|
-
<fo:inline keep-together.within-line="always">
|
403
|
-
<fo:leader leader-pattern="dots"/>
|
404
|
-
<fo:inline><fo:page-number-citation ref-id="{@id}"/></fo:inline>
|
405
|
-
</fo:inline>
|
406
|
-
</fo:basic-link>
|
407
|
-
</fo:block>
|
408
|
-
</xsl:otherwise>
|
409
|
-
</xsl:choose>
|
410
|
-
|
351
|
+
<fo:block role="TOC">
|
352
|
+
<xsl:for-each select="xalan:nodeset($contents)//item[@display = 'true']">
|
411
353
|
|
412
|
-
|
413
|
-
|
414
|
-
|
354
|
+
<fo:block role="TOCI">
|
355
|
+
<xsl:if test="@level = 1">
|
356
|
+
<xsl:attribute name="margin-top">14pt</xsl:attribute>
|
357
|
+
</xsl:if>
|
358
|
+
<xsl:if test="@level = 1 or @parent = 'annex'">
|
359
|
+
<xsl:attribute name="font-size">12pt</xsl:attribute>
|
360
|
+
</xsl:if>
|
361
|
+
<xsl:if test="@level = 2 and not(@parent = 'annex')">
|
362
|
+
<xsl:attribute name="font-size">10pt</xsl:attribute>
|
363
|
+
</xsl:if>
|
364
|
+
|
365
|
+
<xsl:choose>
|
366
|
+
<xsl:when test="@level = 1">
|
367
|
+
<fo:list-block provisional-distance-between-starts="8mm">
|
368
|
+
<xsl:if test="@type = 'annex'">
|
369
|
+
<xsl:attribute name="provisional-distance-between-starts">0mm</xsl:attribute>
|
370
|
+
</xsl:if>
|
371
|
+
<fo:list-item>
|
372
|
+
<fo:list-item-label end-indent="label-end()">
|
373
|
+
<fo:block>
|
374
|
+
<xsl:value-of select="java:toUpperCase(java:java.lang.String.new(@section))"/>
|
375
|
+
</fo:block>
|
376
|
+
</fo:list-item-label>
|
377
|
+
<fo:list-item-body start-indent="body-start()">
|
378
|
+
<fo:block text-align-last="justify" margin-left="12mm" text-indent="-12mm">
|
379
|
+
<fo:basic-link internal-destination="{@id}" fox:alt-text="{text()}">
|
380
|
+
<xsl:variable name="sectionTitle">
|
381
|
+
<xsl:apply-templates select="title"/>
|
382
|
+
</xsl:variable>
|
383
|
+
<xsl:value-of select="java:toUpperCase(java:java.lang.String.new($sectionTitle))"/>
|
384
|
+
<xsl:text> </xsl:text>
|
385
|
+
<fo:inline keep-together.within-line="always">
|
386
|
+
<fo:leader leader-pattern="dots"/>
|
387
|
+
<fo:inline><fo:page-number-citation ref-id="{@id}"/></fo:inline>
|
388
|
+
</fo:inline>
|
389
|
+
</fo:basic-link>
|
390
|
+
</fo:block>
|
391
|
+
</fo:list-item-body>
|
392
|
+
</fo:list-item>
|
393
|
+
</fo:list-block>
|
394
|
+
</xsl:when>
|
395
|
+
<xsl:otherwise>
|
396
|
+
<fo:block text-align-last="justify" margin-left="8mm">
|
397
|
+
<fo:basic-link internal-destination="{@id}" fox:alt-text="{text()}">
|
398
|
+
<xsl:value-of select="java:toUpperCase(java:java.lang.String.new(@section))"/>
|
399
|
+
<xsl:text> </xsl:text>
|
400
|
+
<xsl:apply-templates select="title"/>
|
401
|
+
<xsl:text> </xsl:text>
|
402
|
+
<fo:inline keep-together.within-line="always">
|
403
|
+
<fo:leader leader-pattern="dots"/>
|
404
|
+
<fo:inline><fo:page-number-citation ref-id="{@id}"/></fo:inline>
|
405
|
+
</fo:inline>
|
406
|
+
</fo:basic-link>
|
407
|
+
</fo:block>
|
408
|
+
</xsl:otherwise>
|
409
|
+
</xsl:choose>
|
410
|
+
|
411
|
+
|
412
|
+
</fo:block>
|
413
|
+
</xsl:for-each>
|
414
|
+
</fo:block>
|
415
415
|
</fo:block-container>
|
416
416
|
|
417
|
-
<xsl:if test="//ogc:table[@id and ogc:name]">
|
417
|
+
<xsl:if test="//ogc:table[@id and ogc:name and contains(ogc:name, '—')]">
|
418
418
|
<xsl:variable name="title-list-tables">
|
419
419
|
<xsl:call-template name="getTitle">
|
420
420
|
<xsl:with-param name="name" select="'title-list-tables'"/>
|
@@ -429,8 +429,8 @@
|
|
429
429
|
</fo:block-container>
|
430
430
|
</fo:block-container>
|
431
431
|
<fo:block-container line-height="130%">
|
432
|
-
<xsl:for-each select="//ogc:table[@id and ogc:name]">
|
433
|
-
<fo:block text-align-last="justify" margin-top="2pt">
|
432
|
+
<xsl:for-each select="//ogc:table[@id and ogc:name and contains(ogc:name, '—')]">
|
433
|
+
<fo:block text-align-last="justify" margin-top="2pt" role="TOCI">
|
434
434
|
<fo:basic-link internal-destination="{@id}" fox:alt-text="{ogc:name}">
|
435
435
|
<xsl:apply-templates select="ogc:name" mode="contents"/>
|
436
436
|
<fo:inline keep-together.within-line="always">
|
@@ -443,7 +443,7 @@
|
|
443
443
|
</fo:block-container>
|
444
444
|
</xsl:if>
|
445
445
|
|
446
|
-
<xsl:if test="//ogc:figure[@id and ogc:name]">
|
446
|
+
<xsl:if test="//ogc:figure[@id and ogc:name and contains(ogc:name, '—')]">
|
447
447
|
<xsl:variable name="title-list-figures">
|
448
448
|
<xsl:call-template name="getTitle">
|
449
449
|
<xsl:with-param name="name" select="'title-list-figures'"/>
|
@@ -458,8 +458,8 @@
|
|
458
458
|
</fo:block-container>
|
459
459
|
|
460
460
|
<fo:block-container line-height="130%">
|
461
|
-
<xsl:for-each select="//ogc:figure[@id and ogc:name]">
|
462
|
-
<fo:block text-align-last="justify" margin-top="2pt">
|
461
|
+
<xsl:for-each select="//ogc:figure[@id and ogc:name and contains(ogc:name, '—')]">
|
462
|
+
<fo:block text-align-last="justify" margin-top="2pt" role="TOCI">
|
463
463
|
<fo:basic-link internal-destination="{@id}" fox:alt-text="{ogc:name}">
|
464
464
|
<xsl:apply-templates select="ogc:name" mode="contents"/>
|
465
465
|
<fo:inline keep-together.within-line="always">
|
@@ -492,7 +492,7 @@
|
|
492
492
|
<!-- <xsl:for-each select="//ogc:permission[@id and ogc:name] | //ogc:recommendation[@id and ogc:name] | //ogc:requirement[@id and ogc:name]"> -->
|
493
493
|
<xsl:for-each select="//ogc:table[.//ogc:p[@class = 'RecommendationTitle']]">
|
494
494
|
<xsl:variable name="table_id" select="@id"/>
|
495
|
-
<fo:block text-align-last="justify" margin-top="6pt">
|
495
|
+
<fo:block text-align-last="justify" margin-top="6pt" role="TOCI">
|
496
496
|
<fo:basic-link internal-destination="{@id}" fox:alt-text="{.//ogc:p[@class = 'RecommendationTitle'][1]/text()}">
|
497
497
|
<xsl:apply-templates select=".//ogc:p[@class = 'RecommendationTitle'][ancestor::ogc:table[1][@id= $table_id]]/node()"/>
|
498
498
|
<xsl:text> </xsl:text>
|
@@ -579,7 +579,7 @@
|
|
579
579
|
<xsl:value-of select="translate(., $thinspace, ' ')"/>
|
580
580
|
</xsl:template>
|
581
581
|
|
582
|
-
<xsl:template match="text()" priority="3" mode="contents">
|
582
|
+
<xsl:template match="ogc:title//text() | ogc:name//text()" priority="3" mode="contents">
|
583
583
|
<xsl:value-of select="translate(., $thinspace, ' ')"/>
|
584
584
|
</xsl:template>
|
585
585
|
|
@@ -587,7 +587,9 @@
|
|
587
587
|
<xsl:variable name="content">
|
588
588
|
<xsl:call-template name="add-zero-spaces"/>
|
589
589
|
</xsl:variable>
|
590
|
-
|
590
|
+
<!-- add zero-width space in the words like 'adeOfAbstractTransportaonSpace' to split it in the table's cell -->
|
591
|
+
<xsl:variable name="content2" select="java:replaceAll(java:java.lang.String.new($content),'([a-z]{2,})([A-Z])(.?)','$1$2$3')"/>
|
592
|
+
<xsl:value-of select="translate($content2, $thinspace, ' ')"/>
|
591
593
|
</xsl:template>
|
592
594
|
|
593
595
|
|
@@ -739,14 +741,20 @@
|
|
739
741
|
</fo:block>
|
740
742
|
</xsl:template>
|
741
743
|
|
742
|
-
<xsl:template match="ogc:license-statement//ogc:title">
|
743
|
-
<
|
744
|
+
<xsl:template match="ogc:license-statement//ogc:title">
|
745
|
+
<xsl:variable name="level">
|
746
|
+
<xsl:call-template name="getLevel"/>
|
747
|
+
</xsl:variable>
|
748
|
+
<fo:block font-weight="bold" color="{$color_blue}" role="H{$level}">
|
744
749
|
<xsl:apply-templates/>
|
745
750
|
</fo:block>
|
746
751
|
</xsl:template>
|
747
752
|
|
748
753
|
<xsl:template match="ogc:copyright-statement//ogc:title">
|
749
|
-
<
|
754
|
+
<xsl:variable name="level">
|
755
|
+
<xsl:call-template name="getLevel"/>
|
756
|
+
</xsl:variable>
|
757
|
+
<fo:block font-weight="bold" color="{$color_blue}" margin-top="24pt" role="H{$level}">
|
750
758
|
<xsl:apply-templates/>
|
751
759
|
</fo:block>
|
752
760
|
</xsl:template>
|
@@ -764,7 +772,10 @@
|
|
764
772
|
</xsl:template>
|
765
773
|
|
766
774
|
<xsl:template match="ogc:legal-statement//ogc:title">
|
767
|
-
<
|
775
|
+
<xsl:variable name="level">
|
776
|
+
<xsl:call-template name="getLevel"/>
|
777
|
+
</xsl:variable>
|
778
|
+
<fo:inline font-weight="bold" role="H{$level}">
|
768
779
|
<xsl:apply-templates/><xsl:text>: </xsl:text>
|
769
780
|
</fo:inline>
|
770
781
|
</xsl:template>
|
@@ -839,7 +850,7 @@
|
|
839
850
|
<xsl:when test="$level = 1">
|
840
851
|
<fo:block-container margin-left="-22mm">
|
841
852
|
<fo:block-container margin-left="0mm">
|
842
|
-
<fo:block margin-bottom="10pt" space-before="36pt" keep-with-next="always">
|
853
|
+
<fo:block margin-bottom="10pt" space-before="36pt" keep-with-next="always" role="H{$level}">
|
843
854
|
<fo:table table-layout="fixed" width="100%">
|
844
855
|
<fo:table-column column-width="22mm"/>
|
845
856
|
<fo:table-column column-width="158mm"/>
|
@@ -883,7 +894,7 @@
|
|
883
894
|
</fo:block-container>
|
884
895
|
</xsl:when>
|
885
896
|
<xsl:when test="$level = 2">
|
886
|
-
<fo:block space-before="24pt" margin-bottom="10pt">
|
897
|
+
<fo:block space-before="24pt" margin-bottom="10pt" role="H{$level}">
|
887
898
|
<xsl:attribute name="keep-with-next">always</xsl:attribute>
|
888
899
|
<xsl:variable name="title">
|
889
900
|
<xsl:choose>
|
@@ -899,18 +910,21 @@
|
|
899
910
|
<xsl:call-template name="insertSectionTitle">
|
900
911
|
<xsl:with-param name="section" select="$section"/>
|
901
912
|
<xsl:with-param name="title" select="$title"/>
|
913
|
+
<xsl:with-param name="level" select="$level"/>
|
902
914
|
</xsl:call-template>
|
903
915
|
</fo:block>
|
904
916
|
</xsl:when>
|
905
917
|
<xsl:otherwise>
|
906
918
|
<xsl:element name="{$element-name}">
|
907
919
|
<xsl:attribute name="font-size"><xsl:value-of select="$font-size"/></xsl:attribute>
|
908
|
-
<xsl:attribute name="font-weight"><xsl:value-of select="$font-weight"/></xsl:attribute>
|
909
|
-
<xsl:attribute name="keep-with-next">always</xsl:attribute>
|
910
|
-
<xsl:attribute name="margin-top">30pt</xsl:attribute>
|
911
|
-
<xsl:attribute name="margin-bottom">12pt</xsl:attribute>
|
912
|
-
<xsl:attribute name="color"><xsl:value-of select="$color_blue"/></xsl:attribute>
|
920
|
+
<xsl:attribute name="font-weight"><xsl:value-of select="$font-weight"/></xsl:attribute>
|
921
|
+
<xsl:attribute name="keep-with-next">always</xsl:attribute>
|
922
|
+
<xsl:attribute name="margin-top">30pt</xsl:attribute>
|
923
|
+
<xsl:attribute name="margin-bottom">12pt</xsl:attribute>
|
924
|
+
<xsl:attribute name="color"><xsl:value-of select="$color_blue"/></xsl:attribute>
|
925
|
+
<xsl:attribute name="role">H<xsl:value-of select="$level"/></xsl:attribute>
|
913
926
|
<xsl:apply-templates/>
|
927
|
+
<xsl:apply-templates select="following-sibling::*[1][local-name() = 'variant-title'][@type = 'sub']" mode="subtitle"/>
|
914
928
|
</xsl:element>
|
915
929
|
</xsl:otherwise>
|
916
930
|
</xsl:choose>
|
@@ -1044,7 +1058,13 @@
|
|
1044
1058
|
<xsl:template match="ogc:ul | ogc:ol" mode="ul_ol">
|
1045
1059
|
<fo:block-container margin-left="13mm">
|
1046
1060
|
<xsl:if test="ancestor::ogc:table">
|
1047
|
-
<xsl:attribute name="margin-left">
|
1061
|
+
<xsl:attribute name="margin-left">4mm</xsl:attribute>
|
1062
|
+
</xsl:if>
|
1063
|
+
<xsl:if test="ancestor::ogc:ul or ancestor::ogc:ol">
|
1064
|
+
<xsl:attribute name="margin-top">10pt</xsl:attribute>
|
1065
|
+
<xsl:if test="ancestor::ogc:table">
|
1066
|
+
<xsl:attribute name="margin-top">1mm</xsl:attribute>
|
1067
|
+
</xsl:if>
|
1048
1068
|
</xsl:if>
|
1049
1069
|
<fo:block-container margin-left="0mm">
|
1050
1070
|
<fo:list-block provisional-distance-between-starts="12mm" space-after="12pt" line-height="115%">
|
@@ -1053,6 +1073,9 @@
|
|
1053
1073
|
</xsl:if>
|
1054
1074
|
<xsl:if test="ancestor::ogc:ul | ancestor::ogc:ol">
|
1055
1075
|
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
1076
|
+
<xsl:if test="ancestor::ogc:table[not(@class)]">
|
1077
|
+
<xsl:attribute name="space-after">1mm</xsl:attribute>
|
1078
|
+
</xsl:if>
|
1056
1079
|
</xsl:if>
|
1057
1080
|
<xsl:if test="following-sibling::*[1][local-name() = 'ul' or local-name() = 'ol']">
|
1058
1081
|
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
@@ -1080,17 +1103,22 @@
|
|
1080
1103
|
<xsl:number format="a)" lang="en"/>
|
1081
1104
|
</xsl:when>
|
1082
1105
|
<xsl:when test="../@type = 'alphabet'">
|
1083
|
-
<xsl:number format="1
|
1106
|
+
<xsl:number format="1."/>
|
1084
1107
|
</xsl:when>
|
1085
1108
|
<xsl:when test="../@type = 'alphabet_upper'">
|
1086
1109
|
<xsl:number format="A)" lang="en"/>
|
1087
1110
|
</xsl:when>
|
1088
|
-
|
1089
1111
|
<xsl:when test="../@type = 'roman'">
|
1090
1112
|
<xsl:number format="i)"/>
|
1091
1113
|
</xsl:when>
|
1092
1114
|
<xsl:otherwise>
|
1093
|
-
<xsl:
|
1115
|
+
<xsl:variable name="level" select="count(ancestor-or-self::ogc:li)"/>
|
1116
|
+
<xsl:choose>
|
1117
|
+
<xsl:when test="$level = 1"><xsl:number format="a)" lang="en"/></xsl:when>
|
1118
|
+
<xsl:when test="$level = 2"><xsl:number format="1."/></xsl:when>
|
1119
|
+
<xsl:when test="$level = 3"><xsl:number format="i)"/></xsl:when>
|
1120
|
+
<xsl:otherwise><xsl:number format="a)" lang="en"/></xsl:otherwise>
|
1121
|
+
</xsl:choose>
|
1094
1122
|
</xsl:otherwise>
|
1095
1123
|
</xsl:choose>
|
1096
1124
|
</xsl:otherwise>
|
@@ -1099,6 +1127,12 @@
|
|
1099
1127
|
</fo:list-item-label>
|
1100
1128
|
<fo:list-item-body start-indent="body-start()" line-height-shift-adjustment="disregard-shifts">
|
1101
1129
|
<fo:block margin-bottom="10pt">
|
1130
|
+
<xsl:if test="ancestor::ogc:table[not(@class)]">
|
1131
|
+
<xsl:attribute name="margin-bottom">1mm</xsl:attribute>
|
1132
|
+
</xsl:if>
|
1133
|
+
<xsl:if test="not(following-sibling::*) and not(../following-sibling::*)">
|
1134
|
+
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
1135
|
+
</xsl:if>
|
1102
1136
|
<xsl:apply-templates/>
|
1103
1137
|
</fo:block>
|
1104
1138
|
</fo:list-item-body>
|
@@ -1118,7 +1152,10 @@
|
|
1118
1152
|
</xsl:template>
|
1119
1153
|
|
1120
1154
|
<xsl:template match="ogc:term/ogc:name" priority="2">
|
1121
|
-
<
|
1155
|
+
<xsl:variable name="levelTerm">
|
1156
|
+
<xsl:call-template name="getLevelTermName"/>
|
1157
|
+
</xsl:variable>
|
1158
|
+
<fo:block space-before="36pt" margin-bottom="10pt" keep-with-next="always" role="H{$levelTerm}">
|
1122
1159
|
<fo:block color="{$color_blue}" keep-with-next="always">
|
1123
1160
|
<fo:inline font-size="18pt" padding-right="1mm"><xsl:apply-templates/></fo:inline>
|
1124
1161
|
<xsl:apply-templates select="../ogc:preferred | ../ogc:deprecated | ../ogc:admitted" mode="term_name"/>
|
@@ -1244,7 +1281,6 @@
|
|
1244
1281
|
|
1245
1282
|
<xsl:template match="ogc:figure" priority="2">
|
1246
1283
|
<fo:block-container id="{@id}" margin-top="12pt" margin-bottom="12pt">
|
1247
|
-
<xsl:apply-templates select="ogc:name" mode="presentation"/>
|
1248
1284
|
<fo:block>
|
1249
1285
|
<xsl:apply-templates/>
|
1250
1286
|
</fo:block>
|
@@ -1252,6 +1288,7 @@
|
|
1252
1288
|
<xsl:for-each select="ogc:note">
|
1253
1289
|
<xsl:call-template name="note"/>
|
1254
1290
|
</xsl:for-each>
|
1291
|
+
<xsl:apply-templates select="ogc:name" mode="presentation"/>
|
1255
1292
|
</fo:block-container>
|
1256
1293
|
</xsl:template>
|
1257
1294
|
|
@@ -1263,7 +1300,7 @@
|
|
1263
1300
|
|
1264
1301
|
<xsl:template name="insertHeaderFooter">
|
1265
1302
|
<xsl:param name="color" select="$color_blue"/>
|
1266
|
-
<fo:static-content flow-name="footer">
|
1303
|
+
<fo:static-content flow-name="footer" role="artifact">
|
1267
1304
|
<fo:block-container font-size="8pt" height="100%" color="{$color}" padding-top="6mm">
|
1268
1305
|
<fo:table table-layout="fixed" width="100%">
|
1269
1306
|
<fo:table-column column-width="90%"/>
|
@@ -1412,6 +1449,7 @@
|
|
1412
1449
|
<xsl:template name="insertSectionTitle">
|
1413
1450
|
<xsl:param name="section"/>
|
1414
1451
|
<xsl:param name="title"/>
|
1452
|
+
<xsl:param name="level">1</xsl:param>
|
1415
1453
|
<fo:block>
|
1416
1454
|
<fo:block font-size="18pt" color="{$color_blue}" keep-with-next="always" line-height="150%">
|
1417
1455
|
<xsl:if test="$section != ''">
|
@@ -1422,7 +1460,30 @@
|
|
1422
1460
|
</xsl:call-template>
|
1423
1461
|
</fo:inline>
|
1424
1462
|
</xsl:if>
|
1425
|
-
<xsl:
|
1463
|
+
<xsl:choose>
|
1464
|
+
<xsl:when test="$level = 1">
|
1465
|
+
<xsl:apply-templates select="xalan:nodeset($title)" mode="titlesmall"/>
|
1466
|
+
</xsl:when>
|
1467
|
+
<xsl:otherwise>
|
1468
|
+
<xsl:apply-templates select="xalan:nodeset($title)" mode="titlesimple"/>
|
1469
|
+
</xsl:otherwise>
|
1470
|
+
</xsl:choose>
|
1471
|
+
|
1472
|
+
<xsl:variable name="variant-title">
|
1473
|
+
<xsl:choose>
|
1474
|
+
<xsl:when test="$level = 1">
|
1475
|
+
<xsl:apply-templates select="following-sibling::*[1][local-name() = 'variant-title'][@type = 'sub']" mode="titlesmall"/>
|
1476
|
+
</xsl:when>
|
1477
|
+
<xsl:otherwise>
|
1478
|
+
<xsl:apply-templates select="following-sibling::*[1][local-name() = 'variant-title'][@type = 'sub']" mode="titlesimple"/>
|
1479
|
+
</xsl:otherwise>
|
1480
|
+
</xsl:choose>
|
1481
|
+
</xsl:variable>
|
1482
|
+
<xsl:if test="normalize-space($variant-title) != ''">
|
1483
|
+
<fo:inline padding-right="5mm"> </fo:inline>
|
1484
|
+
<fo:inline><xsl:copy-of select="$variant-title"/></fo:inline>
|
1485
|
+
</xsl:if>
|
1486
|
+
|
1426
1487
|
</fo:block>
|
1427
1488
|
<xsl:call-template name="insertOrangeHorizontalLine"/>
|
1428
1489
|
</fo:block>
|
@@ -1435,25 +1496,59 @@
|
|
1435
1496
|
</xsl:call-template>
|
1436
1497
|
</xsl:template>
|
1437
1498
|
|
1499
|
+
<xsl:template match="text()" mode="titlesimple">
|
1500
|
+
<xsl:value-of select="."/>
|
1501
|
+
</xsl:template>
|
1502
|
+
|
1438
1503
|
<xsl:template match="ogc:strong" mode="titlesmall">
|
1439
1504
|
<xsl:apply-templates mode="titlesmall"/>
|
1440
1505
|
</xsl:template>
|
1506
|
+
<xsl:template match="ogc:strong" mode="titlesimple">
|
1507
|
+
<xsl:apply-templates mode="titlesimple"/>
|
1508
|
+
</xsl:template>
|
1441
1509
|
|
1442
1510
|
<xsl:template match="ogc:em" mode="titlesmall">
|
1443
1511
|
<fo:inline font-style="italic"><xsl:apply-templates mode="titlesmall"/></fo:inline>
|
1444
1512
|
</xsl:template>
|
1513
|
+
<xsl:template match="ogc:em" mode="titlesimple">
|
1514
|
+
<fo:inline font-style="italic"><xsl:apply-templates mode="titlesimple"/></fo:inline>
|
1515
|
+
</xsl:template>
|
1445
1516
|
|
1446
1517
|
<xsl:template match="ogc:fn" mode="titlesmall">
|
1447
1518
|
<xsl:call-template name="fn"/>
|
1448
1519
|
</xsl:template>
|
1520
|
+
<xsl:template match="ogc:fn" mode="titlesimple">
|
1521
|
+
<xsl:call-template name="fn"/>
|
1522
|
+
</xsl:template>
|
1449
1523
|
<xsl:template match="ogc:tab " mode="titlesmall">
|
1450
1524
|
<xsl:apply-templates select="."/>
|
1451
1525
|
</xsl:template>
|
1526
|
+
<xsl:template match="ogc:tab " mode="titlesimple">
|
1527
|
+
<xsl:apply-templates select="."/>
|
1528
|
+
</xsl:template>
|
1452
1529
|
|
1453
1530
|
<xsl:template match="ogc:br" mode="titlesmall">
|
1454
1531
|
<xsl:value-of select="$linebreak"/>
|
1455
1532
|
</xsl:template>
|
1456
|
-
|
1533
|
+
<xsl:template match="ogc:br" mode="titlesimple">
|
1534
|
+
<xsl:value-of select="$linebreak"/>
|
1535
|
+
</xsl:template>
|
1536
|
+
|
1537
|
+
<xsl:template match="*[local-name() = 'name']/text()[1]" priority="2">
|
1538
|
+
<!-- 0xA0 to space replacement -->
|
1539
|
+
<xsl:variable name="text" select="java:replaceAll(java:java.lang.String.new(.),' ',' ')"/>
|
1540
|
+
<xsl:variable name="separator" select="' — '"/>
|
1541
|
+
<xsl:choose>
|
1542
|
+
<xsl:when test="contains($text, $separator)">
|
1543
|
+
<fo:inline font-weight="bold"><xsl:value-of select="substring-before($text, $separator)"/></fo:inline>
|
1544
|
+
<xsl:value-of select="$separator"/>
|
1545
|
+
<xsl:value-of select="substring-after($text, $separator)"/>
|
1546
|
+
</xsl:when>
|
1547
|
+
<xsl:otherwise>
|
1548
|
+
<xsl:value-of select="$text"/>
|
1549
|
+
</xsl:otherwise>
|
1550
|
+
</xsl:choose>
|
1551
|
+
</xsl:template>
|
1457
1552
|
|
1458
1553
|
<xsl:template name="insertOrangeHorizontalLine">
|
1459
1554
|
<fo:block-container width="12.7mm" border-top="1pt solid {$color_orange}" margin-top="3mm">
|
@@ -1640,6 +1735,7 @@
|
|
1640
1735
|
</xsl:attribute-set><xsl:attribute-set name="sourcecode-style">
|
1641
1736
|
<xsl:attribute name="white-space">pre</xsl:attribute>
|
1642
1737
|
<xsl:attribute name="wrap-option">wrap</xsl:attribute>
|
1738
|
+
<xsl:attribute name="role">Code</xsl:attribute>
|
1643
1739
|
|
1644
1740
|
|
1645
1741
|
|
@@ -1691,8 +1787,13 @@
|
|
1691
1787
|
|
1692
1788
|
<xsl:attribute name="margin-bottom">12pt</xsl:attribute>
|
1693
1789
|
|
1694
|
-
</xsl:attribute-set><xsl:attribute-set name="
|
1695
|
-
</xsl:attribute-set><xsl:attribute-set name="
|
1790
|
+
</xsl:attribute-set><xsl:attribute-set name="subject-style">
|
1791
|
+
</xsl:attribute-set><xsl:attribute-set name="inherit-style">
|
1792
|
+
</xsl:attribute-set><xsl:attribute-set name="description-style">
|
1793
|
+
</xsl:attribute-set><xsl:attribute-set name="specification-style">
|
1794
|
+
</xsl:attribute-set><xsl:attribute-set name="measurement-target-style">
|
1795
|
+
</xsl:attribute-set><xsl:attribute-set name="verification-style">
|
1796
|
+
</xsl:attribute-set><xsl:attribute-set name="import-style">
|
1696
1797
|
</xsl:attribute-set><xsl:attribute-set name="recommendation-style">
|
1697
1798
|
|
1698
1799
|
<xsl:attribute name="margin-top">6pt</xsl:attribute>
|
@@ -1774,6 +1875,7 @@
|
|
1774
1875
|
|
1775
1876
|
|
1776
1877
|
|
1878
|
+
|
1777
1879
|
|
1778
1880
|
<xsl:attribute name="margin-bottom">14pt</xsl:attribute>
|
1779
1881
|
|
@@ -1805,6 +1907,7 @@
|
|
1805
1907
|
<xsl:attribute name="text-align">left</xsl:attribute>
|
1806
1908
|
<xsl:attribute name="margin-bottom">6pt</xsl:attribute>
|
1807
1909
|
<xsl:attribute name="font-weight">normal</xsl:attribute>
|
1910
|
+
<xsl:attribute name="color"><xsl:value-of select="$color_blue"/></xsl:attribute>
|
1808
1911
|
<xsl:attribute name="font-size">11pt</xsl:attribute>
|
1809
1912
|
|
1810
1913
|
|
@@ -1920,7 +2023,8 @@
|
|
1920
2023
|
|
1921
2024
|
|
1922
2025
|
|
1923
|
-
</xsl:attribute-set><xsl:attribute-set name="quote-style">
|
2026
|
+
</xsl:attribute-set><xsl:attribute-set name="quote-style">
|
2027
|
+
<xsl:attribute name="role">BlockQuote</xsl:attribute>
|
1924
2028
|
|
1925
2029
|
<xsl:attribute name="margin-top">12pt</xsl:attribute>
|
1926
2030
|
<xsl:attribute name="margin-left">13mm</xsl:attribute>
|
@@ -1963,9 +2067,14 @@
|
|
1963
2067
|
|
1964
2068
|
|
1965
2069
|
|
1966
|
-
<xsl:attribute name="
|
1967
|
-
<xsl:attribute name="margin-
|
1968
|
-
<xsl:attribute name="
|
2070
|
+
<xsl:attribute name="color"><xsl:value-of select="$color_blue"/></xsl:attribute>
|
2071
|
+
<!-- <xsl:attribute name="margin-top">12pt</xsl:attribute> -->
|
2072
|
+
<xsl:attribute name="margin-top">6pt</xsl:attribute>
|
2073
|
+
<!-- <xsl:attribute name="margin-bottom">6pt</xsl:attribute> -->
|
2074
|
+
<xsl:attribute name="margin-bottom">12pt</xsl:attribute>
|
2075
|
+
<!-- <xsl:attribute name="keep-with-next">always</xsl:attribute> -->
|
2076
|
+
<xsl:attribute name="keep-with-previous">always</xsl:attribute>
|
2077
|
+
<xsl:attribute name="text-align">center</xsl:attribute>
|
1969
2078
|
|
1970
2079
|
|
1971
2080
|
|
@@ -2059,13 +2168,20 @@
|
|
2059
2168
|
|
2060
2169
|
</xsl:attribute-set><xsl:attribute-set name="list-style">
|
2061
2170
|
|
2062
|
-
</xsl:attribute-set><xsl:
|
2171
|
+
</xsl:attribute-set><xsl:attribute-set name="toc-style">
|
2172
|
+
<xsl:attribute name="line-height">135%</xsl:attribute>
|
2173
|
+
</xsl:attribute-set><xsl:variable name="border-block-added">2.5pt solid rgb(0, 176, 80)</xsl:variable><xsl:variable name="border-block-deleted">2.5pt solid rgb(255, 0, 0)</xsl:variable><xsl:template name="OLD_processPrefaceSectionsDefault_Contents">
|
2063
2174
|
<xsl:apply-templates select="/*/*[local-name()='preface']/*[local-name()='abstract']" mode="contents"/>
|
2064
2175
|
<xsl:apply-templates select="/*/*[local-name()='preface']/*[local-name()='foreword']" mode="contents"/>
|
2065
2176
|
<xsl:apply-templates select="/*/*[local-name()='preface']/*[local-name()='introduction']" mode="contents"/>
|
2066
2177
|
<xsl:apply-templates select="/*/*[local-name()='preface']/*[local-name() != 'abstract' and local-name() != 'foreword' and local-name() != 'introduction' and local-name() != 'acknowledgements']" mode="contents"/>
|
2067
2178
|
<xsl:apply-templates select="/*/*[local-name()='preface']/*[local-name()='acknowledgements']" mode="contents"/>
|
2068
|
-
</xsl:template><xsl:template name="
|
2179
|
+
</xsl:template><xsl:template name="processPrefaceSectionsDefault_Contents">
|
2180
|
+
<xsl:for-each select="/*/*[local-name()='preface']/*">
|
2181
|
+
<xsl:sort select="@displayorder" data-type="number"/>
|
2182
|
+
<xsl:apply-templates select="." mode="contents"/>
|
2183
|
+
</xsl:for-each>
|
2184
|
+
</xsl:template><xsl:template name="OLD_processMainSectionsDefault_Contents">
|
2069
2185
|
<xsl:apply-templates select="/*/*[local-name()='sections']/*[local-name()='clause'][@type='scope']" mode="contents"/>
|
2070
2186
|
|
2071
2187
|
<!-- Normative references -->
|
@@ -2078,13 +2194,33 @@
|
|
2078
2194
|
<!-- Bibliography -->
|
2079
2195
|
<xsl:apply-templates select="/*/*[local-name()='bibliography']/*[local-name()='references'][not(@normative='true')] | /*/*[local-name()='bibliography']/*[local-name()='clause'][*[local-name()='references'][not(@normative='true')]]" mode="contents"/>
|
2080
2196
|
|
2081
|
-
</xsl:template><xsl:template name="
|
2197
|
+
</xsl:template><xsl:template name="processMainSectionsDefault_Contents">
|
2198
|
+
<xsl:for-each select="/*/*[local-name()='sections']/* | /*/*[local-name()='bibliography']/*[local-name()='references'][@normative='true']">
|
2199
|
+
<xsl:sort select="@displayorder" data-type="number"/>
|
2200
|
+
<xsl:apply-templates select="." mode="contents"/>
|
2201
|
+
</xsl:for-each>
|
2202
|
+
|
2203
|
+
<xsl:for-each select="/*/*[local-name()='annex']">
|
2204
|
+
<xsl:sort select="@displayorder" data-type="number"/>
|
2205
|
+
<xsl:apply-templates select="." mode="contents"/>
|
2206
|
+
</xsl:for-each>
|
2207
|
+
|
2208
|
+
<xsl:for-each select="/*/*[local-name()='bibliography']/*[not(@normative='true')] | /*/*[local-name()='bibliography']/*[local-name()='clause'][*[local-name()='references'][not(@normative='true')]]">
|
2209
|
+
<xsl:sort select="@displayorder" data-type="number"/>
|
2210
|
+
<xsl:apply-templates select="." mode="contents"/>
|
2211
|
+
</xsl:for-each>
|
2212
|
+
</xsl:template><xsl:template name="OLD_processPrefaceSectionsDefault">
|
2082
2213
|
<xsl:apply-templates select="/*/*[local-name()='preface']/*[local-name()='abstract']"/>
|
2083
2214
|
<xsl:apply-templates select="/*/*[local-name()='preface']/*[local-name()='foreword']"/>
|
2084
2215
|
<xsl:apply-templates select="/*/*[local-name()='preface']/*[local-name()='introduction']"/>
|
2085
2216
|
<xsl:apply-templates select="/*/*[local-name()='preface']/*[local-name() != 'abstract' and local-name() != 'foreword' and local-name() != 'introduction' and local-name() != 'acknowledgements']"/>
|
2086
2217
|
<xsl:apply-templates select="/*/*[local-name()='preface']/*[local-name()='acknowledgements']"/>
|
2087
|
-
</xsl:template><xsl:template name="
|
2218
|
+
</xsl:template><xsl:template name="processPrefaceSectionsDefault">
|
2219
|
+
<xsl:for-each select="/*/*[local-name()='preface']/*">
|
2220
|
+
<xsl:sort select="@displayorder" data-type="number"/>
|
2221
|
+
<xsl:apply-templates select="."/>
|
2222
|
+
</xsl:for-each>
|
2223
|
+
</xsl:template><xsl:template name="OLD_processMainSectionsDefault">
|
2088
2224
|
<xsl:apply-templates select="/*/*[local-name()='sections']/*[local-name()='clause'][@type='scope']"/>
|
2089
2225
|
|
2090
2226
|
<!-- Normative references -->
|
@@ -2096,6 +2232,22 @@
|
|
2096
2232
|
<xsl:apply-templates select="/*/*[local-name()='annex']"/>
|
2097
2233
|
<!-- Bibliography -->
|
2098
2234
|
<xsl:apply-templates select="/*/*[local-name()='bibliography']/*[local-name()='references'][not(@normative='true')]"/>
|
2235
|
+
</xsl:template><xsl:template name="processMainSectionsDefault">
|
2236
|
+
<xsl:for-each select="/*/*[local-name()='sections']/* | /*/*[local-name()='bibliography']/*[local-name()='references'][@normative='true']">
|
2237
|
+
<xsl:sort select="@displayorder" data-type="number"/>
|
2238
|
+
<xsl:apply-templates select="."/>
|
2239
|
+
|
2240
|
+
</xsl:for-each>
|
2241
|
+
|
2242
|
+
<xsl:for-each select="/*/*[local-name()='annex']">
|
2243
|
+
<xsl:sort select="@displayorder" data-type="number"/>
|
2244
|
+
<xsl:apply-templates select="."/>
|
2245
|
+
</xsl:for-each>
|
2246
|
+
|
2247
|
+
<xsl:for-each select="/*/*[local-name()='bibliography']/*[not(@normative='true')] | /*/*[local-name()='bibliography']/*[local-name()='clause'][*[local-name()='references'][not(@normative='true')]]">
|
2248
|
+
<xsl:sort select="@displayorder" data-type="number"/>
|
2249
|
+
<xsl:apply-templates select="."/>
|
2250
|
+
</xsl:for-each>
|
2099
2251
|
</xsl:template><xsl:template match="text()">
|
2100
2252
|
<xsl:value-of select="."/>
|
2101
2253
|
</xsl:template><xsl:template match="*[local-name()='br']">
|
@@ -2128,7 +2280,9 @@
|
|
2128
2280
|
|
2129
2281
|
<xsl:apply-templates select="*[local-name()='name']" mode="presentation"/>
|
2130
2282
|
|
2131
|
-
|
2283
|
+
|
2284
|
+
|
2285
|
+
|
2132
2286
|
|
2133
2287
|
<xsl:call-template name="fn_name_display"/>
|
2134
2288
|
|
@@ -2263,6 +2417,8 @@
|
|
2263
2417
|
<xsl:attribute name="border-bottom">0pt solid black</xsl:attribute> <!-- set 0pt border, because there is a separete table below for footer -->
|
2264
2418
|
</xsl:if>
|
2265
2419
|
|
2420
|
+
|
2421
|
+
|
2266
2422
|
<xsl:choose>
|
2267
2423
|
<xsl:when test="*[local-name()='colgroup']/*[local-name()='col']">
|
2268
2424
|
<xsl:for-each select="*[local-name()='colgroup']/*[local-name()='col']">
|
@@ -2547,9 +2703,9 @@
|
|
2547
2703
|
<xsl:apply-templates select="ancestor::*[local-name()='table']/*[local-name()='name']" mode="presentation">
|
2548
2704
|
<xsl:with-param name="continued">true</xsl:with-param>
|
2549
2705
|
</xsl:apply-templates>
|
2550
|
-
|
2551
|
-
|
2552
|
-
|
2706
|
+
|
2707
|
+
|
2708
|
+
|
2553
2709
|
|
2554
2710
|
</fo:table-cell>
|
2555
2711
|
</fo:table-row>
|
@@ -2633,7 +2789,11 @@
|
|
2633
2789
|
|
2634
2790
|
<xsl:variable name="isNoteOrFnExist" select="../*[local-name()='note'] or ..//*[local-name()='fn'][local-name(..) != 'name']"/>
|
2635
2791
|
|
2636
|
-
<xsl:
|
2792
|
+
<xsl:variable name="isNoteOrFnExistShowAfterTable">
|
2793
|
+
|
2794
|
+
</xsl:variable>
|
2795
|
+
|
2796
|
+
<xsl:if test="$isNoteOrFnExist = 'true' or normalize-space($isNoteOrFnExistShowAfterTable) = 'true'">
|
2637
2797
|
|
2638
2798
|
<xsl:variable name="cols-count">
|
2639
2799
|
<xsl:choose>
|
@@ -2776,6 +2936,19 @@
|
|
2776
2936
|
|
2777
2937
|
</fo:table-body>
|
2778
2938
|
|
2939
|
+
</xsl:template><xsl:template match="*[local-name()='table']/*[local-name()='name']/text()[1]" priority="2" mode="presentation_name">
|
2940
|
+
<xsl:choose>
|
2941
|
+
<xsl:when test="substring-after(., '—') != ''">
|
2942
|
+
<xsl:text>—</xsl:text><xsl:value-of select="substring-after(., '—')"/>
|
2943
|
+
</xsl:when>
|
2944
|
+
<xsl:otherwise>
|
2945
|
+
<xsl:value-of select="."/>
|
2946
|
+
</xsl:otherwise>
|
2947
|
+
</xsl:choose>
|
2948
|
+
</xsl:template><xsl:template match="*[local-name()='table']/*[local-name()='name']" mode="presentation_name">
|
2949
|
+
<xsl:apply-templates mode="presentation_name"/>
|
2950
|
+
</xsl:template><xsl:template match="*[local-name()='table']/*[local-name()='name']/node()" mode="presentation_name">
|
2951
|
+
<xsl:apply-templates select="."/>
|
2779
2952
|
</xsl:template><xsl:template match="*[local-name()='tr']">
|
2780
2953
|
<xsl:variable name="parent-name" select="local-name(..)"/>
|
2781
2954
|
<!-- <xsl:variable name="namespace" select="substring-before(name(/*), '-')"/> -->
|
@@ -2902,6 +3075,8 @@
|
|
2902
3075
|
|
2903
3076
|
|
2904
3077
|
<xsl:attribute name="border">solid 0pt white</xsl:attribute>
|
3078
|
+
<xsl:attribute name="padding-top">1mm</xsl:attribute>
|
3079
|
+
<xsl:attribute name="padding-bottom">1mm</xsl:attribute>
|
2905
3080
|
|
2906
3081
|
|
2907
3082
|
|
@@ -2964,20 +3139,12 @@
|
|
2964
3139
|
<xsl:apply-templates/>
|
2965
3140
|
</xsl:template><xsl:template name="fn_display">
|
2966
3141
|
<xsl:variable name="references">
|
3142
|
+
|
2967
3143
|
<xsl:for-each select="..//*[local-name()='fn'][local-name(..) != 'name']">
|
2968
|
-
<
|
2969
|
-
|
2970
|
-
|
2971
|
-
<xsl:attribute name="id">
|
2972
|
-
<xsl:value-of select="@reference"/>
|
2973
|
-
<xsl:text>_</xsl:text>
|
2974
|
-
<xsl:value-of select="ancestor::*[local-name()='table'][1]/@id"/>
|
2975
|
-
</xsl:attribute>
|
2976
|
-
|
2977
|
-
<xsl:apply-templates/>
|
2978
|
-
</fn>
|
3144
|
+
<xsl:call-template name="create_fn"/>
|
2979
3145
|
</xsl:for-each>
|
2980
3146
|
</xsl:variable>
|
3147
|
+
|
2981
3148
|
<xsl:for-each select="xalan:nodeset($references)//fn">
|
2982
3149
|
<xsl:variable name="reference" select="@reference"/>
|
2983
3150
|
<xsl:if test="not(preceding-sibling::*[@reference = $reference])"> <!-- only unique reference puts in note-->
|
@@ -3013,6 +3180,18 @@
|
|
3013
3180
|
</fo:block>
|
3014
3181
|
</xsl:if>
|
3015
3182
|
</xsl:for-each>
|
3183
|
+
</xsl:template><xsl:template name="create_fn">
|
3184
|
+
<fn reference="{@reference}" id="{@reference}_{ancestor::*[@id][1]/@id}">
|
3185
|
+
|
3186
|
+
|
3187
|
+
<xsl:attribute name="id">
|
3188
|
+
<xsl:value-of select="@reference"/>
|
3189
|
+
<xsl:text>_</xsl:text>
|
3190
|
+
<xsl:value-of select="ancestor::*[local-name()='table'][1]/@id"/>
|
3191
|
+
</xsl:attribute>
|
3192
|
+
|
3193
|
+
<xsl:apply-templates/>
|
3194
|
+
</fn>
|
3016
3195
|
</xsl:template><xsl:template name="fn_name_display">
|
3017
3196
|
<!-- <xsl:variable name="references">
|
3018
3197
|
<xsl:for-each select="*[local-name()='name']//*[local-name()='fn']">
|
@@ -4004,16 +4183,68 @@
|
|
4004
4183
|
<xsl:with-param name="isDeleted" select="$isDeleted"/>
|
4005
4184
|
</xsl:call-template>
|
4006
4185
|
|
4186
|
+
|
4187
|
+
|
4007
4188
|
<xsl:variable name="mathml">
|
4008
4189
|
<xsl:apply-templates select="." mode="mathml"/>
|
4009
4190
|
</xsl:variable>
|
4010
4191
|
<fo:instream-foreign-object fox:alt-text="Math">
|
4011
4192
|
|
4012
4193
|
|
4194
|
+
<xsl:variable name="comment_text_following" select="following-sibling::node()[1][self::comment()]"/>
|
4195
|
+
<xsl:variable name="comment_text_">
|
4196
|
+
<xsl:choose>
|
4197
|
+
<xsl:when test="normalize-space($comment_text_following) != ''">
|
4198
|
+
<xsl:value-of select="$comment_text_following"/>
|
4199
|
+
</xsl:when>
|
4200
|
+
<xsl:otherwise>
|
4201
|
+
<xsl:value-of select="normalize-space(translate(.,' ',' '))"/>
|
4202
|
+
</xsl:otherwise>
|
4203
|
+
</xsl:choose>
|
4204
|
+
</xsl:variable>
|
4205
|
+
<xsl:variable name="comment_text" select="java:org.metanorma.fop.Util.unescape($comment_text_)"/>
|
4206
|
+
|
4207
|
+
<xsl:if test="normalize-space($comment_text) != ''">
|
4208
|
+
<!-- put Mathin Alternate Text -->
|
4209
|
+
<xsl:attribute name="fox:alt-text">
|
4210
|
+
<xsl:value-of select="java:org.metanorma.fop.Util.unescape($comment_text)"/>
|
4211
|
+
</xsl:attribute>
|
4212
|
+
</xsl:if>
|
4213
|
+
|
4214
|
+
<xsl:variable name="mathml_content">
|
4215
|
+
<xsl:apply-templates select="." mode="mathml_actual_text"/>
|
4216
|
+
</xsl:variable>
|
4217
|
+
<!-- put MathML in Actual Text -->
|
4218
|
+
<xsl:attribute name="fox:actual-text">
|
4219
|
+
<xsl:value-of select="$mathml_content"/>
|
4220
|
+
</xsl:attribute>
|
4221
|
+
|
4222
|
+
|
4013
4223
|
<!-- <xsl:copy-of select="."/> -->
|
4014
4224
|
<xsl:copy-of select="xalan:nodeset($mathml)"/>
|
4015
4225
|
</fo:instream-foreign-object>
|
4016
4226
|
</fo:inline>
|
4227
|
+
</xsl:template><xsl:template match="mathml:*" mode="mathml_actual_text">
|
4228
|
+
<!-- <xsl:text>a+b</xsl:text> -->
|
4229
|
+
<xsl:text><</xsl:text>
|
4230
|
+
<xsl:value-of select="local-name()"/>
|
4231
|
+
<xsl:if test="local-name() = 'math'">
|
4232
|
+
<xsl:text> xmlns="http://www.w3.org/1998/Math/MathML"</xsl:text>
|
4233
|
+
</xsl:if>
|
4234
|
+
<xsl:for-each select="@*">
|
4235
|
+
<xsl:text> </xsl:text>
|
4236
|
+
<xsl:value-of select="local-name()"/>
|
4237
|
+
<xsl:text>="</xsl:text>
|
4238
|
+
<xsl:value-of select="."/>
|
4239
|
+
<xsl:text>"</xsl:text>
|
4240
|
+
</xsl:for-each>
|
4241
|
+
<xsl:text>></xsl:text>
|
4242
|
+
<xsl:apply-templates mode="mathml_actual_text"/>
|
4243
|
+
<xsl:text></</xsl:text>
|
4244
|
+
<xsl:value-of select="local-name()"/>
|
4245
|
+
<xsl:text>></xsl:text>
|
4246
|
+
</xsl:template><xsl:template match="text()" mode="mathml_actual_text">
|
4247
|
+
<xsl:value-of select="normalize-space()"/>
|
4017
4248
|
</xsl:template><xsl:template match="@*|node()" mode="mathml">
|
4018
4249
|
<xsl:copy>
|
4019
4250
|
<xsl:apply-templates select="@*|node()" mode="mathml"/>
|
@@ -4023,19 +4254,6 @@
|
|
4023
4254
|
<!-- replace start and end spaces to non-break space -->
|
4024
4255
|
<xsl:value-of select="java:replaceAll(java:java.lang.String.new(.),'(^ )|( $)',' ')"/>
|
4025
4256
|
</xsl:copy>
|
4026
|
-
</xsl:template><xsl:template match="mathml:mi[. = ',' and not(following-sibling::*[1][local-name() = 'mtext' and text() = ' '])]" mode="mathml">
|
4027
|
-
<xsl:copy>
|
4028
|
-
<xsl:apply-templates select="@*|node()" mode="mathml"/>
|
4029
|
-
</xsl:copy>
|
4030
|
-
<xsl:choose>
|
4031
|
-
<!-- if in msub, then don't add space -->
|
4032
|
-
<xsl:when test="ancestor::mathml:mrow[parent::mathml:msub and preceding-sibling::*[1][self::mathml:mrow]]"/>
|
4033
|
-
<!-- if next char in digit, don't add space -->
|
4034
|
-
<xsl:when test="translate(substring(following-sibling::*[1]/text(),1,1),'0123456789','') = ''"/>
|
4035
|
-
<xsl:otherwise>
|
4036
|
-
<mathml:mspace width="0.5ex"/>
|
4037
|
-
</xsl:otherwise>
|
4038
|
-
</xsl:choose>
|
4039
4257
|
</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">
|
4040
4258
|
<xsl:variable name="target">
|
4041
4259
|
<xsl:choose>
|
@@ -4088,7 +4306,10 @@
|
|
4088
4306
|
</fo:block>
|
4089
4307
|
<xsl:apply-templates/>
|
4090
4308
|
</xsl:template><xsl:template match="*[local-name()='appendix']/*[local-name()='title']"/><xsl:template match="*[local-name()='appendix']/*[local-name()='title']" mode="process">
|
4091
|
-
<
|
4309
|
+
<xsl:variable name="level">
|
4310
|
+
<xsl:call-template name="getLevel"/>
|
4311
|
+
</xsl:variable>
|
4312
|
+
<fo:inline role="H{$level}"><xsl:apply-templates/></fo:inline>
|
4092
4313
|
</xsl:template><xsl:template match="*[local-name()='appendix']//*[local-name()='example']" priority="2">
|
4093
4314
|
<fo:block id="{@id}" xsl:use-attribute-sets="appendix-example-style">
|
4094
4315
|
<xsl:apply-templates select="*[local-name()='name']" mode="presentation"/>
|
@@ -4123,9 +4344,10 @@
|
|
4123
4344
|
|
4124
4345
|
</xsl:variable>
|
4125
4346
|
|
4347
|
+
<xsl:variable name="text"><xsl:apply-templates/></xsl:variable>
|
4126
4348
|
<xsl:choose>
|
4127
|
-
<xsl:when test="$lang = 'zh'"><xsl:text>、</xsl:text><xsl:value-of select="$title-modified"/><xsl:text>—</xsl:text></xsl:when>
|
4128
|
-
<xsl:otherwise><xsl:text>, </xsl:text><xsl:value-of select="$title-modified"/><xsl:text> — </xsl:text></xsl:otherwise>
|
4349
|
+
<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>
|
4350
|
+
<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>
|
4129
4351
|
</xsl:choose>
|
4130
4352
|
<xsl:apply-templates/>
|
4131
4353
|
</xsl:template><xsl:template match="*[local-name() = 'xref']">
|
@@ -4277,7 +4499,10 @@
|
|
4277
4499
|
</fo:block>
|
4278
4500
|
</xsl:template><xsl:template match="*[local-name() = 'term']/*[local-name() = 'name']"/><xsl:template match="*[local-name() = 'term']/*[local-name() = 'name']" mode="presentation">
|
4279
4501
|
<xsl:if test="normalize-space() != ''">
|
4280
|
-
<
|
4502
|
+
<xsl:variable name="level">
|
4503
|
+
<xsl:call-template name="getLevelTermName"/>
|
4504
|
+
</xsl:variable>
|
4505
|
+
<fo:inline role="H{$level}">
|
4281
4506
|
<xsl:apply-templates/>
|
4282
4507
|
<!-- <xsl:if test="$namespace = 'gb' or $namespace = 'ogc'">
|
4283
4508
|
<xsl:text>.</xsl:text>
|
@@ -4578,6 +4803,13 @@
|
|
4578
4803
|
</xsl:attribute>
|
4579
4804
|
<xsl:apply-templates mode="svg_update"/>
|
4580
4805
|
</xsl:copy>
|
4806
|
+
</xsl:template><xsl:template match="*[local-name() = 'figure']/*[local-name() = 'image'][*[local-name() = 'svg']]" priority="3">
|
4807
|
+
<xsl:variable name="name" select="ancestor::*[local-name() = 'figure']/*[local-name() = 'name']"/>
|
4808
|
+
<xsl:for-each select="*[local-name() = 'svg']">
|
4809
|
+
<xsl:call-template name="image_svg">
|
4810
|
+
<xsl:with-param name="name" select="$name"/>
|
4811
|
+
</xsl:call-template>
|
4812
|
+
</xsl:for-each>
|
4581
4813
|
</xsl:template><xsl:template match="*[local-name() = 'figure']/*[local-name() = 'image'][@mimetype = 'image/svg+xml' and @src[not(starts-with(., 'data:image/'))]]" priority="2">
|
4582
4814
|
<xsl:variable name="svg_content" select="document(@src)"/>
|
4583
4815
|
<xsl:variable name="name" select="ancestor::*[local-name() = 'figure']/*[local-name() = 'name']"/>
|
@@ -4682,7 +4914,7 @@
|
|
4682
4914
|
</fo:basic-link>
|
4683
4915
|
</fo:block>
|
4684
4916
|
</fo:block-container>
|
4685
|
-
</xsl:template><xsl:template match="*[local-name() = 'figure']/*[local-name() = 'name']"/><xsl:template match="*[local-name() = 'figure']/*[local-name() = 'name'] | *[local-name() = 'table']/*[local-name() = 'name'] | *[local-name() = 'permission']/*[local-name() = 'name'] | *[local-name() = 'recommendation']/*[local-name() = 'name'] | *[local-name() = 'requirement']/*[local-name() = 'name']" mode="contents">
|
4917
|
+
</xsl:template><xsl:template match="*[local-name() = 'emf']"/><xsl:template match="*[local-name() = 'figure']/*[local-name() = 'name']"/><xsl:template match="*[local-name() = 'figure']/*[local-name() = 'name'] | *[local-name() = 'table']/*[local-name() = 'name'] | *[local-name() = 'permission']/*[local-name() = 'name'] | *[local-name() = 'recommendation']/*[local-name() = 'name'] | *[local-name() = 'requirement']/*[local-name() = 'name']" mode="contents">
|
4686
4918
|
<xsl:apply-templates mode="contents"/>
|
4687
4919
|
<xsl:text> </xsl:text>
|
4688
4920
|
</xsl:template><xsl:template match="*[local-name() = 'figure']/*[local-name() = 'name'] | *[local-name() = 'table']/*[local-name() = 'name'] | *[local-name() = 'permission']/*[local-name() = 'name'] | *[local-name() = 'recommendation']/*[local-name() = 'name'] | *[local-name() = 'requirement']/*[local-name() = 'name']" mode="bookmarks">
|
@@ -4951,6 +5183,7 @@
|
|
4951
5183
|
</xsl:when>
|
4952
5184
|
<xsl:otherwise>
|
4953
5185
|
<xsl:apply-templates/>
|
5186
|
+
<xsl:apply-templates select="following-sibling::*[1][local-name() = 'variant-title'][@type = 'sub']" mode="subtitle"/>
|
4954
5187
|
</xsl:otherwise>
|
4955
5188
|
</xsl:choose>
|
4956
5189
|
</fo:block>
|
@@ -5099,14 +5332,6 @@
|
|
5099
5332
|
<fo:block>
|
5100
5333
|
<fo:inline padding-right="3mm">Obligation</fo:inline><xsl:value-of select="."/>
|
5101
5334
|
</fo:block>
|
5102
|
-
</xsl:template><xsl:template match="*[local-name() = 'requirement']/*[local-name() = 'subject']"/><xsl:template match="*[local-name() = 'requirement']/*[local-name() = 'subject']" mode="presentation">
|
5103
|
-
<fo:block xsl:use-attribute-sets="requirement-subject-style">
|
5104
|
-
<xsl:text>Target Type </xsl:text><xsl:apply-templates/>
|
5105
|
-
</fo:block>
|
5106
|
-
</xsl:template><xsl:template match="*[local-name() = 'requirement']/*[local-name() = 'inherit']">
|
5107
|
-
<fo:block xsl:use-attribute-sets="requirement-inherit-style">
|
5108
|
-
<xsl:text>Dependency </xsl:text><xsl:apply-templates/>
|
5109
|
-
</fo:block>
|
5110
5335
|
</xsl:template><xsl:template match="*[local-name() = 'recommendation']">
|
5111
5336
|
<fo:block id="{@id}" xsl:use-attribute-sets="recommendation-style">
|
5112
5337
|
<xsl:apply-templates select="*[local-name()='name']" mode="presentation"/>
|
@@ -5123,6 +5348,38 @@
|
|
5123
5348
|
<fo:block xsl:use-attribute-sets="recommendation-label-style">
|
5124
5349
|
<xsl:apply-templates/>
|
5125
5350
|
</fo:block>
|
5351
|
+
</xsl:template><xsl:template match="*[local-name() = 'requirement']/*[local-name() = 'subject']" priority="2"/><xsl:template match="*[local-name() = 'requirement']/*[local-name() = 'subject']" mode="presentation">
|
5352
|
+
<fo:block xsl:use-attribute-sets="subject-style">
|
5353
|
+
<xsl:text>Target Type </xsl:text><xsl:apply-templates/>
|
5354
|
+
</fo:block>
|
5355
|
+
</xsl:template><xsl:template match="*[local-name() = 'subject']">
|
5356
|
+
<fo:block xsl:use-attribute-sets="subject-style">
|
5357
|
+
<xsl:text>Target Type </xsl:text><xsl:apply-templates/>
|
5358
|
+
</fo:block>
|
5359
|
+
</xsl:template><xsl:template match="*[local-name() = 'inherit'] | *[local-name() = 'component'][@class = 'inherit']">
|
5360
|
+
<fo:block xsl:use-attribute-sets="inherit-style">
|
5361
|
+
<xsl:text>Dependency </xsl:text><xsl:apply-templates/>
|
5362
|
+
</fo:block>
|
5363
|
+
</xsl:template><xsl:template match="*[local-name() = 'description'] | *[local-name() = 'component'][@class = 'description']">
|
5364
|
+
<fo:block xsl:use-attribute-sets="description-style">
|
5365
|
+
<xsl:apply-templates/>
|
5366
|
+
</fo:block>
|
5367
|
+
</xsl:template><xsl:template match="*[local-name() = 'specification'] | *[local-name() = 'component'][@class = 'specification']">
|
5368
|
+
<fo:block xsl:use-attribute-sets="specification-style">
|
5369
|
+
<xsl:apply-templates/>
|
5370
|
+
</fo:block>
|
5371
|
+
</xsl:template><xsl:template match="*[local-name() = 'measurement-target'] | *[local-name() = 'component'][@class = 'measurement-target']">
|
5372
|
+
<fo:block xsl:use-attribute-sets="measurement-target-style">
|
5373
|
+
<xsl:apply-templates/>
|
5374
|
+
</fo:block>
|
5375
|
+
</xsl:template><xsl:template match="*[local-name() = 'verification'] | *[local-name() = 'component'][@class = 'verification']">
|
5376
|
+
<fo:block xsl:use-attribute-sets="verification-style">
|
5377
|
+
<xsl:apply-templates/>
|
5378
|
+
</fo:block>
|
5379
|
+
</xsl:template><xsl:template match="*[local-name() = 'import'] | *[local-name() = 'component'][@class = 'import']">
|
5380
|
+
<fo:block xsl:use-attribute-sets="import-style">
|
5381
|
+
<xsl:apply-templates/>
|
5382
|
+
</fo:block>
|
5126
5383
|
</xsl:template><xsl:template match="*[local-name() = 'table'][@class = 'recommendation' or @class='requirement' or @class='permission']">
|
5127
5384
|
<fo:block-container margin-left="0mm" margin-right="0mm" margin-bottom="12pt">
|
5128
5385
|
<xsl:if test="ancestor::*[local-name() = 'table'][@class = 'recommendation' or @class='requirement' or @class='permission']">
|
@@ -5274,7 +5531,19 @@
|
|
5274
5531
|
</fo:inline>
|
5275
5532
|
</xsl:if>
|
5276
5533
|
</xsl:template><xsl:template match="*[local-name() = 'termexample']/*[local-name() = 'p']">
|
5277
|
-
<
|
5534
|
+
<xsl:variable name="element">inline
|
5535
|
+
|
5536
|
+
</xsl:variable>
|
5537
|
+
<xsl:choose>
|
5538
|
+
<xsl:when test="contains($element, 'block')">
|
5539
|
+
<fo:block xsl:use-attribute-sets="example-p-style">
|
5540
|
+
<xsl:apply-templates/>
|
5541
|
+
</fo:block>
|
5542
|
+
</xsl:when>
|
5543
|
+
<xsl:otherwise>
|
5544
|
+
<fo:inline><xsl:apply-templates/></fo:inline>
|
5545
|
+
</xsl:otherwise>
|
5546
|
+
</xsl:choose>
|
5278
5547
|
</xsl:template><xsl:template match="*[local-name() = 'example']">
|
5279
5548
|
<fo:block id="{@id}" xsl:use-attribute-sets="example-style">
|
5280
5549
|
|
@@ -5372,14 +5641,15 @@
|
|
5372
5641
|
</xsl:if>
|
5373
5642
|
</xsl:template><xsl:variable name="localized.source">
|
5374
5643
|
<xsl:call-template name="getLocalizedString">
|
5375
|
-
|
5376
|
-
|
5644
|
+
<xsl:with-param name="key">source</xsl:with-param>
|
5645
|
+
</xsl:call-template>
|
5377
5646
|
</xsl:variable><xsl:template match="*[local-name() = 'origin']">
|
5378
5647
|
<fo:basic-link internal-destination="{@bibitemid}" fox:alt-text="{@citeas}">
|
5379
5648
|
<xsl:if test="normalize-space(@citeas) = ''">
|
5380
5649
|
<xsl:attribute name="fox:alt-text"><xsl:value-of select="@bibitemid"/></xsl:attribute>
|
5381
5650
|
</xsl:if>
|
5382
5651
|
|
5652
|
+
<xsl:text>[</xsl:text>
|
5383
5653
|
<fo:inline>
|
5384
5654
|
|
5385
5655
|
<xsl:attribute name="font-weight">bold</xsl:attribute>
|
@@ -5389,18 +5659,18 @@
|
|
5389
5659
|
|
5390
5660
|
|
5391
5661
|
|
5392
|
-
|
5393
|
-
<xsl:call-template name="getTitle">
|
5394
|
-
<xsl:with-param name="name" select="'title-source'"/>
|
5395
|
-
</xsl:call-template>
|
5662
|
+
<xsl:value-of select="$localized.source"/>
|
5396
5663
|
<xsl:text>: </xsl:text>
|
5397
5664
|
|
5398
5665
|
|
5666
|
+
|
5667
|
+
|
5399
5668
|
</fo:inline>
|
5400
5669
|
|
5401
5670
|
<fo:inline xsl:use-attribute-sets="origin-style">
|
5402
5671
|
<xsl:apply-templates/>
|
5403
5672
|
</fo:inline>
|
5673
|
+
<xsl:text>]</xsl:text>
|
5404
5674
|
</fo:basic-link>
|
5405
5675
|
</xsl:template><xsl:template match="*[local-name() = 'modification']/*[local-name() = 'p']">
|
5406
5676
|
<fo:inline><xsl:apply-templates/></fo:inline>
|
@@ -5467,6 +5737,9 @@
|
|
5467
5737
|
|
5468
5738
|
</xsl:if>
|
5469
5739
|
|
5740
|
+
<xsl:variable name="citeas" select="java:replaceAll(java:java.lang.String.new(@citeas),'^\[?(.+?)\]?$','$1')"/> <!-- remove leading and trailing brackets -->
|
5741
|
+
<xsl:variable name="text" select="normalize-space()"/>
|
5742
|
+
|
5470
5743
|
|
5471
5744
|
|
5472
5745
|
<fo:basic-link internal-destination="{@bibitemid}" fox:alt-text="{@citeas}">
|
@@ -5480,7 +5753,9 @@
|
|
5480
5753
|
|
5481
5754
|
|
5482
5755
|
</xsl:if>
|
5483
|
-
|
5756
|
+
|
5757
|
+
|
5758
|
+
|
5484
5759
|
<xsl:apply-templates/>
|
5485
5760
|
</fo:basic-link>
|
5486
5761
|
|
@@ -5818,6 +6093,7 @@
|
|
5818
6093
|
</xsl:template><xsl:template match="*[local-name() = 'indexsect']//*[local-name() = 'li']" priority="4">
|
5819
6094
|
<xsl:variable name="level" select="count(ancestor::*[local-name() = 'ul'])"/>
|
5820
6095
|
<fo:block start-indent="{5 * $level}mm" text-indent="-5mm">
|
6096
|
+
|
5821
6097
|
<xsl:apply-templates/>
|
5822
6098
|
</fo:block>
|
5823
6099
|
</xsl:template><xsl:template match="*[local-name() = 'bookmark']" name="bookmark">
|
@@ -5857,7 +6133,6 @@
|
|
5857
6133
|
</xsl:template><xsl:template name="processBibitem">
|
5858
6134
|
|
5859
6135
|
|
5860
|
-
<!-- end BIPM bibitem processing-->
|
5861
6136
|
|
5862
6137
|
|
5863
6138
|
<!-- start OGC bibtem processing -->
|
@@ -6129,6 +6404,97 @@
|
|
6129
6404
|
<fo:block-container border="1pt solid black" width="50%">
|
6130
6405
|
<fo:block> </fo:block>
|
6131
6406
|
</fo:block-container>
|
6407
|
+
</xsl:template><xsl:template match="*[local-name() = 'toc']">
|
6408
|
+
<xsl:param name="colwidths"/>
|
6409
|
+
<xsl:variable name="colwidths_">
|
6410
|
+
<xsl:choose>
|
6411
|
+
<xsl:when test="not($colwidths)">
|
6412
|
+
<xsl:variable name="toc_table_simple">
|
6413
|
+
<tbody>
|
6414
|
+
<xsl:apply-templates mode="toc_table_width"/>
|
6415
|
+
</tbody>
|
6416
|
+
</xsl:variable>
|
6417
|
+
<xsl:variable name="cols-count" select="count(xalan:nodeset($toc_table_simple)/*/tr[1]/td)"/>
|
6418
|
+
<xsl:call-template name="calculate-column-widths">
|
6419
|
+
<xsl:with-param name="cols-count" select="$cols-count"/>
|
6420
|
+
<xsl:with-param name="table" select="$toc_table_simple"/>
|
6421
|
+
</xsl:call-template>
|
6422
|
+
</xsl:when>
|
6423
|
+
<xsl:otherwise>
|
6424
|
+
<xsl:copy-of select="$colwidths"/>
|
6425
|
+
</xsl:otherwise>
|
6426
|
+
</xsl:choose>
|
6427
|
+
</xsl:variable>
|
6428
|
+
<fo:block role="TOCI" space-after="16pt">
|
6429
|
+
<fo:table width="100%" table-layout="fixed">
|
6430
|
+
<xsl:for-each select="xalan:nodeset($colwidths_)/column">
|
6431
|
+
<fo:table-column column-width="proportional-column-width({.})"/>
|
6432
|
+
</xsl:for-each>
|
6433
|
+
<fo:table-body>
|
6434
|
+
<xsl:apply-templates/>
|
6435
|
+
</fo:table-body>
|
6436
|
+
</fo:table>
|
6437
|
+
</fo:block>
|
6438
|
+
</xsl:template><xsl:template match="*[local-name() = 'toc']//*[local-name() = 'li']">
|
6439
|
+
<fo:table-row min-height="5mm">
|
6440
|
+
<xsl:apply-templates/>
|
6441
|
+
</fo:table-row>
|
6442
|
+
</xsl:template><xsl:template match="*[local-name() = 'toc']//*[local-name() = 'li']/*[local-name() = 'p']">
|
6443
|
+
<xsl:apply-templates/>
|
6444
|
+
</xsl:template><xsl:template match="*[local-name() = 'toc']//*[local-name() = 'xref']" priority="3">
|
6445
|
+
<!-- <xref target="cgpm9th1948r6">1.6.3<tab/>“9th CGPM, 1948:<tab/>decision to establish the SI”</xref> -->
|
6446
|
+
<xsl:variable name="target" select="@target"/>
|
6447
|
+
<xsl:for-each select="*[local-name() = 'tab']">
|
6448
|
+
<xsl:variable name="current_id" select="generate-id()"/>
|
6449
|
+
<fo:table-cell>
|
6450
|
+
<fo:block>
|
6451
|
+
<fo:basic-link internal-destination="{$target}" fox:alt-text="{.}">
|
6452
|
+
<xsl:for-each select="following-sibling::node()[not(self::*[local-name() = 'tab']) and preceding-sibling::*[local-name() = 'tab'][1][generate-id() = $current_id]]">
|
6453
|
+
<xsl:choose>
|
6454
|
+
<xsl:when test="self::text()"><xsl:value-of select="."/></xsl:when>
|
6455
|
+
<xsl:otherwise><xsl:apply-templates select="."/></xsl:otherwise>
|
6456
|
+
</xsl:choose>
|
6457
|
+
</xsl:for-each>
|
6458
|
+
</fo:basic-link>
|
6459
|
+
</fo:block>
|
6460
|
+
</fo:table-cell>
|
6461
|
+
</xsl:for-each>
|
6462
|
+
<!-- last column - for page numbers -->
|
6463
|
+
<fo:table-cell text-align="right" font-size="10pt" font-weight="bold" font-family="Arial">
|
6464
|
+
<fo:block>
|
6465
|
+
<fo:basic-link internal-destination="{$target}" fox:alt-text="{.}">
|
6466
|
+
<fo:page-number-citation ref-id="{$target}"/>
|
6467
|
+
</fo:basic-link>
|
6468
|
+
</fo:block>
|
6469
|
+
</fo:table-cell>
|
6470
|
+
</xsl:template><xsl:template match="*" mode="toc_table_width">
|
6471
|
+
<xsl:apply-templates mode="toc_table_width"/>
|
6472
|
+
</xsl:template><xsl:template match="*[local-name() = 'clause'][@type = 'toc']/*[local-name() = 'title']" mode="toc_table_width"/><xsl:template match="*[local-name() = 'clause'][not(@type = 'toc')]/*[local-name() = 'title']" mode="toc_table_width"/><xsl:template match="*[local-name() = 'li']" mode="toc_table_width">
|
6473
|
+
<tr>
|
6474
|
+
<xsl:apply-templates mode="toc_table_width"/>
|
6475
|
+
</tr>
|
6476
|
+
</xsl:template><xsl:template match="*[local-name() = 'xref']" mode="toc_table_width">
|
6477
|
+
<!-- <xref target="cgpm9th1948r6">1.6.3<tab/>“9th CGPM, 1948:<tab/>decision to establish the SI”</xref> -->
|
6478
|
+
<xsl:for-each select="*[local-name() = 'tab']">
|
6479
|
+
<xsl:variable name="current_id" select="generate-id()"/>
|
6480
|
+
<td>
|
6481
|
+
<xsl:for-each select="following-sibling::node()[not(self::*[local-name() = 'tab']) and preceding-sibling::*[local-name() = 'tab'][1][generate-id() = $current_id]]">
|
6482
|
+
<xsl:copy-of select="."/>
|
6483
|
+
</xsl:for-each>
|
6484
|
+
</td>
|
6485
|
+
</xsl:for-each>
|
6486
|
+
<td>333</td> <!-- page number, just for fill -->
|
6487
|
+
</xsl:template><xsl:template match="*[local-name() = 'variant-title'][@type = 'sub']"/><xsl:template match="*[local-name() = 'variant-title'][@type = 'sub']" mode="subtitle">
|
6488
|
+
<fo:inline padding-right="5mm"> </fo:inline>
|
6489
|
+
<fo:inline><xsl:apply-templates/></fo:inline>
|
6490
|
+
</xsl:template><xsl:template match="*[local-name() = 'blacksquare']" name="blacksquare">
|
6491
|
+
<fo:inline padding-right="2.5mm" baseline-shift="5%">
|
6492
|
+
<fo:instream-foreign-object content-height="2mm" content-width="2mm" fox:alt-text="Quad">
|
6493
|
+
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve" viewBox="0 0 2 2">
|
6494
|
+
<rect x="0" y="0" width="2" height="2" fill="black"/>
|
6495
|
+
</svg>
|
6496
|
+
</fo:instream-foreign-object>
|
6497
|
+
</fo:inline>
|
6132
6498
|
</xsl:template><xsl:template name="convertDate">
|
6133
6499
|
<xsl:param name="date"/>
|
6134
6500
|
<xsl:param name="format" select="'short'"/>
|
@@ -6367,6 +6733,26 @@
|
|
6367
6733
|
<xsl:value-of select="$level"/>
|
6368
6734
|
</xsl:otherwise>
|
6369
6735
|
</xsl:choose>
|
6736
|
+
</xsl:template><xsl:template name="getLevelTermName">
|
6737
|
+
<xsl:choose>
|
6738
|
+
<xsl:when test="normalize-space(../@depth) != ''">
|
6739
|
+
<xsl:value-of select="../@depth"/>
|
6740
|
+
</xsl:when>
|
6741
|
+
<xsl:otherwise>
|
6742
|
+
<xsl:variable name="title_level_">
|
6743
|
+
<xsl:for-each select="../preceding-sibling::*[local-name() = 'title'][1]">
|
6744
|
+
<xsl:call-template name="getLevel"/>
|
6745
|
+
</xsl:for-each>
|
6746
|
+
</xsl:variable>
|
6747
|
+
<xsl:variable name="title_level" select="normalize-space($title_level_)"/>
|
6748
|
+
<xsl:choose>
|
6749
|
+
<xsl:when test="$title_level != ''"><xsl:value-of select="$title_level + 1"/></xsl:when>
|
6750
|
+
<xsl:otherwise>
|
6751
|
+
<xsl:call-template name="getLevel"/>
|
6752
|
+
</xsl:otherwise>
|
6753
|
+
</xsl:choose>
|
6754
|
+
</xsl:otherwise>
|
6755
|
+
</xsl:choose>
|
6370
6756
|
</xsl:template><xsl:template name="split">
|
6371
6757
|
<xsl:param name="pText" select="."/>
|
6372
6758
|
<xsl:param name="sep" select="','"/>
|