metanorma-plateau 1.1.6 → 1.2.0
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/plateau/i18n-ja.yaml +9 -0
- data/lib/isodoc/plateau/init.rb +4 -1
- data/lib/isodoc/plateau/plateau.international-standard.xsl +497 -406
- data/lib/isodoc/plateau/presentation_xml_convert.rb +31 -0
- data/lib/metanorma/plateau/biblio.rng +1 -1
- data/lib/metanorma/plateau/converter.rb +3 -2
- data/lib/metanorma/plateau/isodoc.rng +35 -10
- data/lib/metanorma/plateau/log.rb +17 -0
- data/lib/metanorma/plateau/version.rb +1 -1
- data/lib/relaton/render-plateau/citations.rb +9 -0
- data/lib/relaton/render-plateau/config-en.yml +2 -0
- data/lib/relaton/render-plateau/config-ja.yml +2 -0
- data/lib/relaton/render-plateau/general.rb +91 -0
- data/lib/relaton/render-plateau/i18n.rb +21 -0
- data/metanorma-plateau.gemspec +4 -3
- metadata +25 -5
|
@@ -586,143 +586,150 @@
|
|
|
586
586
|
|
|
587
587
|
<xsl:template name="cover-page">
|
|
588
588
|
<xsl:param name="num"/>
|
|
589
|
-
<
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
<xsl:attribute name="font-family">Noto Sans</xsl:attribute>
|
|
596
|
-
</xsl:if>
|
|
597
|
-
|
|
598
|
-
<fo:static-content flow-name="header" role="artifact" id="__internal_layout__coverpage_header_{generate-id()}">
|
|
599
|
-
<!-- background cover image -->
|
|
600
|
-
<xsl:call-template name="insertBackgroundPageImage"/>
|
|
601
|
-
</fo:static-content>
|
|
602
|
-
|
|
603
|
-
<fo:static-content flow-name="footer" role="artifact">
|
|
604
|
-
<fo:block-container>
|
|
605
|
-
<fo:table table-layout="fixed" width="100%">
|
|
606
|
-
<fo:table-column column-width="proportional-column-width(140)"/>
|
|
607
|
-
<fo:table-column column-width="proportional-column-width(13.5)"/>
|
|
608
|
-
<xsl:choose>
|
|
609
|
-
<xsl:when test="$doctype = 'technical-report'">
|
|
610
|
-
<fo:table-column column-width="proportional-column-width(20)"/>
|
|
611
|
-
</xsl:when>
|
|
612
|
-
<xsl:otherwise>
|
|
613
|
-
<fo:table-column column-width="proportional-column-width(11)"/>
|
|
614
|
-
</xsl:otherwise>
|
|
615
|
-
</xsl:choose>
|
|
616
|
-
<fo:table-body>
|
|
617
|
-
<fo:table-row>
|
|
618
|
-
<fo:table-cell>
|
|
619
|
-
<fo:block font-size="28pt" font-family="Noto Sans JP">
|
|
620
|
-
<xsl:if test="$doctype = 'annex'">
|
|
621
|
-
<xsl:attribute name="text-indent">-7mm</xsl:attribute>
|
|
622
|
-
<xsl:value-of select="concat('(', $i18n_doctype_dict_annex)"/>
|
|
623
|
-
<fo:inline letter-spacing="-3mm">)</fo:inline>
|
|
624
|
-
</xsl:if>
|
|
625
|
-
<xsl:if test="$doctype = 'technical-report'">
|
|
626
|
-
<xsl:attribute name="font-size">18pt</xsl:attribute>
|
|
627
|
-
<xsl:attribute name="line-height">1.8</xsl:attribute>
|
|
628
|
-
</xsl:if>
|
|
629
|
-
<xsl:variable name="title">
|
|
630
|
-
<xsl:apply-templates select="/*/mn:bibdata/mn:title[@language = 'ja' and @type = 'title-main']/node()"/>
|
|
631
|
-
</xsl:variable>
|
|
632
|
-
<xsl:copy-of select="$title"/>
|
|
633
|
-
<xsl:if test="$doctype = 'technical-report'">
|
|
634
|
-
<xsl:choose>
|
|
635
|
-
<xsl:when test="string-length($title) > 60">
|
|
636
|
-
<fo:inline> <xsl:value-of select="$i18n_doctype_dict_technical_report"/></fo:inline>
|
|
637
|
-
</xsl:when>
|
|
638
|
-
<xsl:otherwise>
|
|
639
|
-
<fo:block><xsl:value-of select="$i18n_doctype_dict_technical_report"/></fo:block>
|
|
640
|
-
</xsl:otherwise>
|
|
641
|
-
</xsl:choose>
|
|
642
|
-
</xsl:if>
|
|
643
|
-
</fo:block>
|
|
644
|
-
<fo:block font-size="14pt" margin-top="3mm">
|
|
645
|
-
<xsl:if test="$doctype = 'technical-report'">
|
|
646
|
-
<xsl:attribute name="font-size">9pt</xsl:attribute>
|
|
647
|
-
<xsl:attribute name="margin-top">1mm</xsl:attribute>
|
|
648
|
-
</xsl:if>
|
|
649
|
-
<xsl:apply-templates select="/*/mn:bibdata/mn:title[@language = 'en' and @type = 'title-main']/node()"/>
|
|
650
|
-
</fo:block>
|
|
651
|
-
</fo:table-cell>
|
|
652
|
-
<fo:table-cell text-align="right" font-size="8.5pt" padding-top="3mm" padding-right="2mm">
|
|
653
|
-
<xsl:if test="$doctype = 'technical-report'">
|
|
654
|
-
<xsl:attribute name="font-size">9.5pt</xsl:attribute>
|
|
655
|
-
<xsl:attribute name="padding-top">2mm</xsl:attribute>
|
|
656
|
-
</xsl:if>
|
|
657
|
-
<fo:block>series</fo:block>
|
|
658
|
-
<fo:block>No.</fo:block>
|
|
659
|
-
</fo:table-cell>
|
|
660
|
-
<fo:table-cell text-align="right">
|
|
661
|
-
<xsl:if test="$doctype = 'technical-report'">
|
|
662
|
-
<xsl:attribute name="text-align">center</xsl:attribute>
|
|
663
|
-
</xsl:if>
|
|
664
|
-
<fo:block font-size="32pt">
|
|
665
|
-
<xsl:if test="$doctype = 'technical-report'">
|
|
666
|
-
<xsl:attribute name="font-size">28pt</xsl:attribute>
|
|
667
|
-
</xsl:if>
|
|
668
|
-
<xsl:variable name="docnumber" select="/*/mn:bibdata/mn:docnumber"/>
|
|
669
|
-
<xsl:if test="string-length($docnumber) = 1">0</xsl:if><xsl:value-of select="$docnumber"/>
|
|
670
|
-
</fo:block>
|
|
671
|
-
</fo:table-cell>
|
|
672
|
-
</fo:table-row>
|
|
673
|
-
</fo:table-body>
|
|
674
|
-
</fo:table>
|
|
675
|
-
</fo:block-container>
|
|
676
|
-
</fo:static-content>
|
|
589
|
+
<xsl:choose>
|
|
590
|
+
<xsl:when test="/mn:metanorma/mn:metanorma-extension/mn:presentation-metadata[mn:name = 'coverpage-image']/mn:value/mn:image and normalize-space(/mn:metanorma/mn:metanorma-extension/mn:presentation-metadata/mn:full-coverpage-replacement) = 'true'">
|
|
591
|
+
<xsl:call-template name="insertCoverPageFullImage"/>
|
|
592
|
+
</xsl:when>
|
|
593
|
+
<xsl:otherwise>
|
|
594
|
+
<fo:page-sequence master-reference="cover-page" force-page-count="no-force" font-family="Noto Sans Condensed">
|
|
677
595
|
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
<xsl:if test="$doctype = 'technical-report'">
|
|
681
|
-
<xsl:attribute name="margin-left">5.5mm</xsl:attribute>
|
|
596
|
+
<xsl:if test="$doctype = 'annex'">
|
|
597
|
+
<xsl:attribute name="color">white</xsl:attribute>
|
|
682
598
|
</xsl:if>
|
|
683
|
-
<fo:instream-foreign-object content-width="24mm" fox:alt-text="PLATEAU Logo">
|
|
684
|
-
<xsl:if test="$doctype = 'technical-report'">
|
|
685
|
-
<xsl:attribute name="content-width">20.5mm</xsl:attribute>
|
|
686
|
-
</xsl:if>
|
|
687
|
-
<xsl:choose>
|
|
688
|
-
<xsl:when test="$doctype = 'annex'">
|
|
689
|
-
<xsl:copy-of select="$PLATEAU-Logo-inverted"/>
|
|
690
|
-
</xsl:when>
|
|
691
|
-
<xsl:otherwise>
|
|
692
|
-
<xsl:copy-of select="$PLATEAU-Logo"/>
|
|
693
|
-
</xsl:otherwise>
|
|
694
|
-
</xsl:choose>
|
|
695
|
-
</fo:instream-foreign-object>
|
|
696
|
-
</fo:block>
|
|
697
|
-
<fo:block-container reference-orientation="-90" width="205mm" height="36mm" margin-top="6mm">
|
|
698
599
|
<xsl:if test="$doctype = 'technical-report'">
|
|
699
|
-
<xsl:attribute name="
|
|
600
|
+
<xsl:attribute name="font-family">Noto Sans</xsl:attribute>
|
|
700
601
|
</xsl:if>
|
|
701
|
-
<fo:block font-size="21.2pt" margin-top="7mm">
|
|
702
|
-
<xsl:if test="$doctype = 'technical-report'">
|
|
703
|
-
<xsl:attribute name="font-size">16pt</xsl:attribute>
|
|
704
|
-
<xsl:attribute name="margin-top">8mm</xsl:attribute>
|
|
705
|
-
</xsl:if>
|
|
706
|
-
<xsl:apply-templates select="/*/mn:bibdata/mn:title[@language = 'en' and @type = 'title-intro']/node()"/>
|
|
707
|
-
</fo:block>
|
|
708
|
-
<fo:block font-family="Noto Sans JP" font-size="14.2pt" margin-top="2mm">
|
|
709
|
-
<xsl:if test="$doctype = 'annex'">
|
|
710
|
-
<xsl:attribute name="text-indent">-3.5mm</xsl:attribute>
|
|
711
|
-
<xsl:value-of select="concat('(', $i18n_doctype_dict_annex)"/>
|
|
712
|
-
<fo:inline letter-spacing="-1mm">)</fo:inline>
|
|
713
|
-
</xsl:if>
|
|
714
|
-
<xsl:if test="$doctype = 'technical-report'">
|
|
715
|
-
<xsl:attribute name="font-size">12pt</xsl:attribute>
|
|
716
|
-
</xsl:if>
|
|
717
|
-
<xsl:apply-templates select="/*/mn:bibdata/mn:title[@language = 'ja' and @type = 'title-intro']/node()"/>
|
|
718
|
-
</fo:block>
|
|
719
|
-
</fo:block-container>
|
|
720
|
-
</fo:static-content>
|
|
721
602
|
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
603
|
+
<fo:static-content flow-name="header" role="artifact" id="__internal_layout__coverpage_header_{generate-id()}">
|
|
604
|
+
<!-- background cover image -->
|
|
605
|
+
<xsl:call-template name="insertBackgroundPageImage"/>
|
|
606
|
+
</fo:static-content>
|
|
607
|
+
|
|
608
|
+
<fo:static-content flow-name="footer" role="artifact">
|
|
609
|
+
<fo:block-container>
|
|
610
|
+
<fo:table table-layout="fixed" width="100%">
|
|
611
|
+
<fo:table-column column-width="proportional-column-width(140)"/>
|
|
612
|
+
<fo:table-column column-width="proportional-column-width(13.5)"/>
|
|
613
|
+
<xsl:choose>
|
|
614
|
+
<xsl:when test="$doctype = 'technical-report'">
|
|
615
|
+
<fo:table-column column-width="proportional-column-width(20)"/>
|
|
616
|
+
</xsl:when>
|
|
617
|
+
<xsl:otherwise>
|
|
618
|
+
<fo:table-column column-width="proportional-column-width(11)"/>
|
|
619
|
+
</xsl:otherwise>
|
|
620
|
+
</xsl:choose>
|
|
621
|
+
<fo:table-body>
|
|
622
|
+
<fo:table-row>
|
|
623
|
+
<fo:table-cell>
|
|
624
|
+
<fo:block font-size="28pt" font-family="Noto Sans JP">
|
|
625
|
+
<xsl:if test="$doctype = 'annex'">
|
|
626
|
+
<xsl:attribute name="text-indent">-7mm</xsl:attribute>
|
|
627
|
+
<xsl:value-of select="concat('(', $i18n_doctype_dict_annex)"/>
|
|
628
|
+
<fo:inline letter-spacing="-3mm">)</fo:inline>
|
|
629
|
+
</xsl:if>
|
|
630
|
+
<xsl:if test="$doctype = 'technical-report'">
|
|
631
|
+
<xsl:attribute name="font-size">18pt</xsl:attribute>
|
|
632
|
+
<xsl:attribute name="line-height">1.8</xsl:attribute>
|
|
633
|
+
</xsl:if>
|
|
634
|
+
<xsl:variable name="title">
|
|
635
|
+
<xsl:apply-templates select="/*/mn:bibdata/mn:title[@language = 'ja' and @type = 'title-main']/node()"/>
|
|
636
|
+
</xsl:variable>
|
|
637
|
+
<xsl:copy-of select="$title"/>
|
|
638
|
+
<xsl:if test="$doctype = 'technical-report'">
|
|
639
|
+
<xsl:choose>
|
|
640
|
+
<xsl:when test="string-length($title) > 60">
|
|
641
|
+
<fo:inline> <xsl:value-of select="$i18n_doctype_dict_technical_report"/></fo:inline>
|
|
642
|
+
</xsl:when>
|
|
643
|
+
<xsl:otherwise>
|
|
644
|
+
<fo:block><xsl:value-of select="$i18n_doctype_dict_technical_report"/></fo:block>
|
|
645
|
+
</xsl:otherwise>
|
|
646
|
+
</xsl:choose>
|
|
647
|
+
</xsl:if>
|
|
648
|
+
</fo:block>
|
|
649
|
+
<fo:block font-size="14pt" margin-top="3mm">
|
|
650
|
+
<xsl:if test="$doctype = 'technical-report'">
|
|
651
|
+
<xsl:attribute name="font-size">9pt</xsl:attribute>
|
|
652
|
+
<xsl:attribute name="margin-top">1mm</xsl:attribute>
|
|
653
|
+
</xsl:if>
|
|
654
|
+
<xsl:apply-templates select="/*/mn:bibdata/mn:title[@language = 'en' and @type = 'title-main']/node()"/>
|
|
655
|
+
</fo:block>
|
|
656
|
+
</fo:table-cell>
|
|
657
|
+
<fo:table-cell text-align="right" font-size="8.5pt" padding-top="3mm" padding-right="2mm">
|
|
658
|
+
<xsl:if test="$doctype = 'technical-report'">
|
|
659
|
+
<xsl:attribute name="font-size">9.5pt</xsl:attribute>
|
|
660
|
+
<xsl:attribute name="padding-top">2mm</xsl:attribute>
|
|
661
|
+
</xsl:if>
|
|
662
|
+
<fo:block>series</fo:block>
|
|
663
|
+
<fo:block>No.</fo:block>
|
|
664
|
+
</fo:table-cell>
|
|
665
|
+
<fo:table-cell text-align="right">
|
|
666
|
+
<xsl:if test="$doctype = 'technical-report'">
|
|
667
|
+
<xsl:attribute name="text-align">center</xsl:attribute>
|
|
668
|
+
</xsl:if>
|
|
669
|
+
<fo:block font-size="32pt">
|
|
670
|
+
<xsl:if test="$doctype = 'technical-report'">
|
|
671
|
+
<xsl:attribute name="font-size">28pt</xsl:attribute>
|
|
672
|
+
</xsl:if>
|
|
673
|
+
<xsl:variable name="docnumber" select="/*/mn:bibdata/mn:docnumber"/>
|
|
674
|
+
<xsl:if test="string-length($docnumber) = 1">0</xsl:if><xsl:value-of select="$docnumber"/>
|
|
675
|
+
</fo:block>
|
|
676
|
+
</fo:table-cell>
|
|
677
|
+
</fo:table-row>
|
|
678
|
+
</fo:table-body>
|
|
679
|
+
</fo:table>
|
|
680
|
+
</fo:block-container>
|
|
681
|
+
</fo:static-content>
|
|
682
|
+
|
|
683
|
+
<fo:static-content flow-name="left-region" role="artifact" id="__internal_layout__coverpage_left_region_{generate-id()}">
|
|
684
|
+
<fo:block text-align="center" margin-top="14.5mm" margin-left="2mm">
|
|
685
|
+
<xsl:if test="$doctype = 'technical-report'">
|
|
686
|
+
<xsl:attribute name="margin-left">5.5mm</xsl:attribute>
|
|
687
|
+
</xsl:if>
|
|
688
|
+
<fo:instream-foreign-object content-width="24mm" fox:alt-text="PLATEAU Logo">
|
|
689
|
+
<xsl:if test="$doctype = 'technical-report'">
|
|
690
|
+
<xsl:attribute name="content-width">20.5mm</xsl:attribute>
|
|
691
|
+
</xsl:if>
|
|
692
|
+
<xsl:choose>
|
|
693
|
+
<xsl:when test="$doctype = 'annex'">
|
|
694
|
+
<xsl:copy-of select="$PLATEAU-Logo-inverted"/>
|
|
695
|
+
</xsl:when>
|
|
696
|
+
<xsl:otherwise>
|
|
697
|
+
<xsl:copy-of select="$PLATEAU-Logo"/>
|
|
698
|
+
</xsl:otherwise>
|
|
699
|
+
</xsl:choose>
|
|
700
|
+
</fo:instream-foreign-object>
|
|
701
|
+
</fo:block>
|
|
702
|
+
<fo:block-container reference-orientation="-90" width="205mm" height="36mm" margin-top="6mm">
|
|
703
|
+
<xsl:if test="$doctype = 'technical-report'">
|
|
704
|
+
<xsl:attribute name="margin-top">2mm</xsl:attribute>
|
|
705
|
+
</xsl:if>
|
|
706
|
+
<fo:block font-size="21.2pt" margin-top="7mm">
|
|
707
|
+
<xsl:if test="$doctype = 'technical-report'">
|
|
708
|
+
<xsl:attribute name="font-size">16pt</xsl:attribute>
|
|
709
|
+
<xsl:attribute name="margin-top">8mm</xsl:attribute>
|
|
710
|
+
</xsl:if>
|
|
711
|
+
<xsl:apply-templates select="/*/mn:bibdata/mn:title[@language = 'en' and @type = 'title-intro']/node()"/>
|
|
712
|
+
</fo:block>
|
|
713
|
+
<fo:block font-family="Noto Sans JP" font-size="14.2pt" margin-top="2mm">
|
|
714
|
+
<xsl:if test="$doctype = 'annex'">
|
|
715
|
+
<xsl:attribute name="text-indent">-3.5mm</xsl:attribute>
|
|
716
|
+
<xsl:value-of select="concat('(', $i18n_doctype_dict_annex)"/>
|
|
717
|
+
<fo:inline letter-spacing="-1mm">)</fo:inline>
|
|
718
|
+
</xsl:if>
|
|
719
|
+
<xsl:if test="$doctype = 'technical-report'">
|
|
720
|
+
<xsl:attribute name="font-size">12pt</xsl:attribute>
|
|
721
|
+
</xsl:if>
|
|
722
|
+
<xsl:apply-templates select="/*/mn:bibdata/mn:title[@language = 'ja' and @type = 'title-intro']/node()"/>
|
|
723
|
+
</fo:block>
|
|
724
|
+
</fo:block-container>
|
|
725
|
+
</fo:static-content>
|
|
726
|
+
|
|
727
|
+
<fo:flow flow-name="xsl-region-body">
|
|
728
|
+
<fo:block id="firstpage_id_{$num}"> </fo:block>
|
|
729
|
+
</fo:flow>
|
|
730
|
+
</fo:page-sequence>
|
|
731
|
+
</xsl:otherwise>
|
|
732
|
+
</xsl:choose>
|
|
726
733
|
</xsl:template> <!-- cover-page -->
|
|
727
734
|
|
|
728
735
|
<xsl:template name="inner-cover-page">
|
|
@@ -900,54 +907,6 @@
|
|
|
900
907
|
<xsl:call-template name="getLevel"/>
|
|
901
908
|
</xsl:variable>
|
|
902
909
|
|
|
903
|
-
<xsl:variable name="font-size">
|
|
904
|
-
<xsl:choose>
|
|
905
|
-
<!-- <xsl:when test="@parent = 'preface'">10pt</xsl:when> -->
|
|
906
|
-
<xsl:when test="$doctype = 'technical-report' and $level = 1">16pt</xsl:when>
|
|
907
|
-
<xsl:when test="$doctype = 'technical-report' and $level = 2">14pt</xsl:when>
|
|
908
|
-
<xsl:when test="$doctype = 'technical-report' and $level = 3">12pt</xsl:when>
|
|
909
|
-
<xsl:when test="$doctype = 'technical-report' and $level >= 4">10pt</xsl:when>
|
|
910
|
-
<xsl:when test="ancestor::mn:sections">12pt</xsl:when>
|
|
911
|
-
<xsl:when test="ancestor::mn:annex and $level = 1">14pt</xsl:when>
|
|
912
|
-
<xsl:when test="ancestor::mn:annex">12pt</xsl:when>
|
|
913
|
-
<xsl:otherwise>10pt</xsl:otherwise>
|
|
914
|
-
</xsl:choose>
|
|
915
|
-
</xsl:variable>
|
|
916
|
-
|
|
917
|
-
<xsl:variable name="font-weight">bold</xsl:variable>
|
|
918
|
-
<!-- <xsl:choose>
|
|
919
|
-
<xsl:when test="@parent = 'preface'">bold</xsl:when>
|
|
920
|
-
<xsl:when test="@parent = 'annex'">bold</xsl:when>
|
|
921
|
-
<xsl:when test="@parent = 'bibliography'">bold</xsl:when>
|
|
922
|
-
<xsl:otherwise>normal</xsl:otherwise>
|
|
923
|
-
</xsl:choose>
|
|
924
|
-
</xsl:variable> -->
|
|
925
|
-
|
|
926
|
-
<xsl:variable name="text-align">
|
|
927
|
-
<xsl:choose>
|
|
928
|
-
<xsl:when test="ancestor::mn:foreword and $level = 1">center</xsl:when>
|
|
929
|
-
<xsl:when test="ancestor::mn:annex and $level = 1">center</xsl:when>
|
|
930
|
-
<xsl:otherwise>left</xsl:otherwise>
|
|
931
|
-
</xsl:choose>
|
|
932
|
-
</xsl:variable>
|
|
933
|
-
|
|
934
|
-
<xsl:variable name="margin-top">
|
|
935
|
-
<xsl:choose>
|
|
936
|
-
<xsl:when test="ancestor::mn:foreword and $level = 1">9mm</xsl:when>
|
|
937
|
-
<!-- <xsl:when test="ancestor::mn:annex and $level = '1' and ancestor::mn:annex[1][@commentary = 'true']">1mm</xsl:when> -->
|
|
938
|
-
<xsl:when test="ancestor::mn:annex and $level = 1">0mm</xsl:when>
|
|
939
|
-
<xsl:when test="$level = 1 and not(ancestor::mn:preface)">6.5mm</xsl:when>
|
|
940
|
-
<xsl:when test="ancestor::mn:foreword and $level = 2">0mm</xsl:when>
|
|
941
|
-
<!-- <xsl:when test="ancestor::mn:annex and $level = 2">4.5mm</xsl:when> -->
|
|
942
|
-
<xsl:when test="ancestor::mn:bibliography and $level = 2">0mm</xsl:when>
|
|
943
|
-
<xsl:when test="$doctype = 'technical-report' and $level = 2 and preceding-sibling::*[2][self::mn:fmt-title]">0mm</xsl:when>
|
|
944
|
-
<xsl:when test="$doctype = 'technical-report' and $level = 3 and preceding-sibling::*[2][self::mn:fmt-title]">0mm</xsl:when>
|
|
945
|
-
<xsl:when test="$level = 2">2mm</xsl:when>
|
|
946
|
-
<xsl:when test="$level >= 3">2mm</xsl:when>
|
|
947
|
-
<xsl:otherwise>0mm</xsl:otherwise>
|
|
948
|
-
</xsl:choose>
|
|
949
|
-
</xsl:variable>
|
|
950
|
-
|
|
951
910
|
<xsl:variable name="element-name">
|
|
952
911
|
<xsl:choose>
|
|
953
912
|
<xsl:when test="@inline-header = 'true'">fo:inline</xsl:when>
|
|
@@ -955,36 +914,13 @@
|
|
|
955
914
|
</xsl:choose>
|
|
956
915
|
</xsl:variable>
|
|
957
916
|
|
|
958
|
-
<xsl:variable name="margin-bottom">
|
|
959
|
-
<xsl:choose>
|
|
960
|
-
<xsl:when test="$doctype = 'technical-report'">
|
|
961
|
-
<xsl:choose>
|
|
962
|
-
<xsl:when test="following-sibling::*[1][self::mn:clause]">0</xsl:when>
|
|
963
|
-
<xsl:when test="following-sibling::*[1][self::mn:p]">16pt</xsl:when>
|
|
964
|
-
<xsl:otherwise>12pt</xsl:otherwise>
|
|
965
|
-
</xsl:choose>
|
|
966
|
-
</xsl:when>
|
|
967
|
-
<xsl:otherwise>
|
|
968
|
-
<xsl:choose>
|
|
969
|
-
<xsl:when test="ancestor::mn:preface">6pt</xsl:when>
|
|
970
|
-
<xsl:when test="ancestor::mn:foreword and $level = 1">9mm</xsl:when>
|
|
971
|
-
<!-- <xsl:when test="ancestor::mn:annex and $level = '1' and ancestor::mn:annex[1][@commentary = 'true']">7mm</xsl:when> -->
|
|
972
|
-
<!-- <xsl:when test="ancestor::mn:annex and $level = 1">1mm</xsl:when> -->
|
|
973
|
-
<xsl:when test="$level = 1 and following-sibling::*[1][self::mn:clause]">8pt</xsl:when>
|
|
974
|
-
<xsl:when test="$level = 1">12pt</xsl:when>
|
|
975
|
-
<xsl:when test="$level = 2 and following-sibling::*[1][self::mn:clause]">8pt</xsl:when>
|
|
976
|
-
<xsl:when test="$level >= 2">12pt</xsl:when>
|
|
977
|
-
<xsl:when test="@type = 'section-title'">6mm</xsl:when>
|
|
978
|
-
<xsl:when test="@inline-header = 'true'">0pt</xsl:when>
|
|
979
|
-
<xsl:otherwise>0mm</xsl:otherwise>
|
|
980
|
-
</xsl:choose>
|
|
981
|
-
</xsl:otherwise>
|
|
982
|
-
</xsl:choose>
|
|
983
|
-
</xsl:variable>
|
|
984
|
-
|
|
985
917
|
<!-- to space-before Foreword -->
|
|
986
918
|
<xsl:if test="ancestor::mn:foreword and $level = '1'"><fo:block/></xsl:if>
|
|
987
919
|
|
|
920
|
+
<xsl:variable name="title_styles">
|
|
921
|
+
<styles xsl:use-attribute-sets="title-style"><xsl:call-template name="refine_title-style"/></styles>
|
|
922
|
+
</xsl:variable>
|
|
923
|
+
|
|
988
924
|
<xsl:choose>
|
|
989
925
|
<xsl:when test="@inline-header = 'true' and following-sibling::*[1][self::mn:p]">
|
|
990
926
|
<fo:block role="H{$level}">
|
|
@@ -997,34 +933,7 @@
|
|
|
997
933
|
</xsl:when>
|
|
998
934
|
<xsl:otherwise>
|
|
999
935
|
<xsl:element name="{$element-name}">
|
|
1000
|
-
<xsl:
|
|
1001
|
-
<xsl:attribute name="font-weight"><xsl:value-of select="$font-weight"/></xsl:attribute>
|
|
1002
|
-
<xsl:attribute name="text-align"><xsl:value-of select="$text-align"/></xsl:attribute>
|
|
1003
|
-
<xsl:attribute name="space-before"><xsl:value-of select="$margin-top"/></xsl:attribute>
|
|
1004
|
-
<xsl:attribute name="margin-bottom"><xsl:value-of select="$margin-bottom"/></xsl:attribute>
|
|
1005
|
-
<xsl:attribute name="keep-with-next">always</xsl:attribute>
|
|
1006
|
-
<xsl:attribute name="role">H<xsl:value-of select="$level"/></xsl:attribute>
|
|
1007
|
-
|
|
1008
|
-
<xsl:if test="@type = 'floating-title' or @type = 'section-title'">
|
|
1009
|
-
<xsl:copy-of select="@id"/>
|
|
1010
|
-
</xsl:if>
|
|
1011
|
-
|
|
1012
|
-
<!-- <xsl:if test="$level = '3'">
|
|
1013
|
-
<xsl:attribute name="margin-left">7.5mm</xsl:attribute>
|
|
1014
|
-
</xsl:if> -->
|
|
1015
|
-
|
|
1016
|
-
<xsl:if test="$doctype = 'technical-report'">
|
|
1017
|
-
<xsl:choose>
|
|
1018
|
-
<xsl:when test="$level = 2">
|
|
1019
|
-
<xsl:attribute name="background-color">rgb(229,229,229)</xsl:attribute>
|
|
1020
|
-
<xsl:attribute name="padding-top">2mm</xsl:attribute>
|
|
1021
|
-
<xsl:attribute name="padding-bottom">2mm</xsl:attribute>
|
|
1022
|
-
</xsl:when>
|
|
1023
|
-
<xsl:when test="$level = 3">
|
|
1024
|
-
<xsl:attribute name="background-color">rgb(204,204,204)</xsl:attribute>
|
|
1025
|
-
</xsl:when>
|
|
1026
|
-
</xsl:choose>
|
|
1027
|
-
</xsl:if>
|
|
936
|
+
<xsl:copy-of select="xalan:nodeset($title_styles)/styles/@*"/>
|
|
1028
937
|
|
|
1029
938
|
<!-- if first and last childs are `add` ace-tag, then move start ace-tag before title -->
|
|
1030
939
|
<xsl:if test="mn:tab[1]/following-sibling::node()[last()][self::mn:add][starts-with(text(), $ace_tag)]">
|
|
@@ -1127,88 +1036,17 @@
|
|
|
1127
1036
|
</xsl:choose>
|
|
1128
1037
|
</xsl:variable>
|
|
1129
1038
|
|
|
1130
|
-
<xsl:
|
|
1131
|
-
<xsl:
|
|
1132
|
-
<xsl:with-param name="
|
|
1133
|
-
</
|
|
1134
|
-
|
|
1135
|
-
<xsl:if test="$doctype = 'technical-report'">
|
|
1136
|
-
<xsl:attribute name="margin-bottom">18pt</xsl:attribute>
|
|
1137
|
-
</xsl:if>
|
|
1138
|
-
|
|
1139
|
-
<!--
|
|
1140
|
-
<xsl:if test="not(parent::mn:note or parent::mn:li or ancestor::mn:table)">
|
|
1141
|
-
<xsl:attribute name="text-indent"><xsl:value-of select="$text_indent"/>mm</xsl:attribute>
|
|
1142
|
-
</xsl:if>
|
|
1143
|
-
-->
|
|
1144
|
-
|
|
1145
|
-
<xsl:copy-of select="@id"/>
|
|
1146
|
-
|
|
1147
|
-
<xsl:if test="$doctype = 'technical-report'">
|
|
1148
|
-
<xsl:attribute name="line-height">1.8</xsl:attribute>
|
|
1149
|
-
</xsl:if>
|
|
1150
|
-
|
|
1151
|
-
<!-- bookmarks only in paragraph -->
|
|
1152
|
-
<xsl:if test="count(mn:bookmark) != 0 and count(*) = count(mn:bookmark) and normalize-space() = ''">
|
|
1153
|
-
<xsl:attribute name="font-size">0</xsl:attribute>
|
|
1154
|
-
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
|
1155
|
-
<xsl:attribute name="line-height">0</xsl:attribute>
|
|
1156
|
-
</xsl:if>
|
|
1157
|
-
|
|
1158
|
-
<xsl:if test="ancestor::*[@key = 'true']">
|
|
1159
|
-
<xsl:attribute name="margin-bottom">2pt</xsl:attribute>
|
|
1160
|
-
</xsl:if>
|
|
1161
|
-
|
|
1162
|
-
<xsl:if test="parent::mn:fmt-definition">
|
|
1163
|
-
<xsl:attribute name="margin-bottom">2pt</xsl:attribute>
|
|
1164
|
-
</xsl:if>
|
|
1165
|
-
|
|
1166
|
-
<xsl:if test="parent::mn:li or parent::mn:quote">
|
|
1167
|
-
<xsl:attribute name="margin-bottom">8pt</xsl:attribute>
|
|
1168
|
-
</xsl:if>
|
|
1169
|
-
|
|
1170
|
-
<xsl:if test="parent::mn:li and following-sibling::*[1][self::mn:ol or self::mn:ul or self::mn:note or self::mn:example]">
|
|
1171
|
-
<xsl:attribute name="margin-bottom">4pt</xsl:attribute>
|
|
1172
|
-
</xsl:if>
|
|
1173
|
-
|
|
1174
|
-
<xsl:if test="ancestor::mn:td or ancestor::mn:th">
|
|
1175
|
-
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
|
1176
|
-
</xsl:if>
|
|
1177
|
-
|
|
1178
|
-
<xsl:if test="parent::mn:dd">
|
|
1179
|
-
<xsl:attribute name="margin-bottom">5pt</xsl:attribute>
|
|
1180
|
-
</xsl:if>
|
|
1181
|
-
|
|
1182
|
-
<xsl:if test="parent::mn:dd and ancestor::mn:dl[@key = 'true'] and (ancestor::mn:tfoot or ancestor::mn:figure)">
|
|
1183
|
-
<xsl:attribute name="margin-bottom">2pt</xsl:attribute>
|
|
1184
|
-
</xsl:if>
|
|
1185
|
-
|
|
1186
|
-
<xsl:if test="parent::mn:clause[@type = 'inner-cover-note'] or ancestor::mn:boilerplate">
|
|
1187
|
-
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
|
1188
|
-
</xsl:if>
|
|
1189
|
-
|
|
1190
|
-
<xsl:if test="parent::mn:note and not(following-sibling::*)">
|
|
1191
|
-
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
|
1192
|
-
</xsl:if>
|
|
1193
|
-
|
|
1194
|
-
<xsl:if test="(ancestor::*[local-name() = 'td' or local-name() = 'th']) and (.//*[local-name() = 'font_en' or local-name() = 'font_en_bold'])">
|
|
1195
|
-
<xsl:if test="$isGenerateTableIF = 'false'">
|
|
1196
|
-
<xsl:attribute name="language">en</xsl:attribute>
|
|
1197
|
-
<xsl:attribute name="hyphenate">true</xsl:attribute>
|
|
1198
|
-
</xsl:if>
|
|
1199
|
-
</xsl:if>
|
|
1200
|
-
|
|
1201
|
-
<xsl:if test="ancestor::mn:note[@type = 'units']">
|
|
1202
|
-
<xsl:attribute name="text-align">right</xsl:attribute>
|
|
1203
|
-
</xsl:if>
|
|
1039
|
+
<xsl:variable name="p_styles">
|
|
1040
|
+
<styles xsl:use-attribute-sets="p-style">
|
|
1041
|
+
<xsl:call-template name="refine_p-style"><xsl:with-param name="element-name" select="$element-name"/></xsl:call-template>
|
|
1042
|
+
</styles>
|
|
1043
|
+
</xsl:variable>
|
|
1204
1044
|
|
|
1205
|
-
|
|
1206
|
-
<xsl:
|
|
1207
|
-
<xsl:attribute name="margin-left"><xsl:value-of select="$tableAnnotationIndent"/></xsl:attribute>
|
|
1208
|
-
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
|
1209
|
-
</xsl:if>
|
|
1045
|
+
<xsl:element name="{$element-name}">
|
|
1046
|
+
<xsl:copy-of select="xalan:nodeset($p_styles)/styles/@*"/>
|
|
1210
1047
|
|
|
1211
1048
|
<xsl:if test="parent::mn:clause or (ancestor::mn:note and not(ancestor::mn:table))">
|
|
1049
|
+
<!-- Ideographic Space -->
|
|
1212
1050
|
<xsl:text> </xsl:text>
|
|
1213
1051
|
</xsl:if>
|
|
1214
1052
|
|
|
@@ -1237,7 +1075,7 @@
|
|
|
1237
1075
|
|
|
1238
1076
|
<xsl:call-template name="refine_note-style"/>
|
|
1239
1077
|
|
|
1240
|
-
<fo:block-container
|
|
1078
|
+
<fo:block-container xsl:use-attribute-sets="reset-margins-style">
|
|
1241
1079
|
|
|
1242
1080
|
<fo:table table-layout="fixed" width="99%" border="1pt solid black">
|
|
1243
1081
|
<fo:table-body>
|
|
@@ -1397,7 +1235,7 @@
|
|
|
1397
1235
|
<xsl:if test="position() = last()">
|
|
1398
1236
|
<xsl:attribute name="margin-bottom">10pt</xsl:attribute>
|
|
1399
1237
|
</xsl:if>
|
|
1400
|
-
<fo:block-container
|
|
1238
|
+
<fo:block-container xsl:use-attribute-sets="reset-margins-style">
|
|
1401
1239
|
<fo:list-block provisional-distance-between-starts="10mm">
|
|
1402
1240
|
<fo:list-item>
|
|
1403
1241
|
<fo:list-item-label end-indent="label-end()">
|
|
@@ -1800,7 +1638,7 @@
|
|
|
1800
1638
|
<xsl:if test="not(following-sibling::*[1][self::mn:p[@class = 'dl']])"> <!-- last dl -->
|
|
1801
1639
|
<xsl:attribute name="margin-bottom">2pt</xsl:attribute>
|
|
1802
1640
|
</xsl:if>
|
|
1803
|
-
<fo:block-container
|
|
1641
|
+
<fo:block-container xsl:use-attribute-sets="reset-margins-style">
|
|
1804
1642
|
<fo:block>
|
|
1805
1643
|
<xsl:if test="parent::mn:table">
|
|
1806
1644
|
<xsl:attribute name="font-size">10pt</xsl:attribute>
|
|
@@ -1844,32 +1682,7 @@
|
|
|
1844
1682
|
|
|
1845
1683
|
<xsl:template name="insertHeaderFooter">
|
|
1846
1684
|
<xsl:call-template name="insertHeader"/>
|
|
1847
|
-
<
|
|
1848
|
-
<xsl:choose>
|
|
1849
|
-
<xsl:when test="$doctype = 'technical-report'">
|
|
1850
|
-
<fo:block-container height="23mm" display-align="after">
|
|
1851
|
-
<fo:block text-align="center" margin-bottom="16mm">
|
|
1852
|
-
<xsl:if test="$vertical_layout = 'true'">
|
|
1853
|
-
<xsl:attribute name="margin-bottom">0mm</xsl:attribute>
|
|
1854
|
-
</xsl:if>
|
|
1855
|
-
<xsl:text>- </xsl:text>
|
|
1856
|
-
<fo:page-number/>
|
|
1857
|
-
<xsl:text> -</xsl:text>
|
|
1858
|
-
</fo:block>
|
|
1859
|
-
</fo:block-container>
|
|
1860
|
-
</xsl:when>
|
|
1861
|
-
<xsl:otherwise>
|
|
1862
|
-
<fo:block-container height="24mm" display-align="after">
|
|
1863
|
-
<fo:block text-align="center" margin-bottom="16mm">
|
|
1864
|
-
<xsl:if test="$vertical_layout = 'true'">
|
|
1865
|
-
<xsl:attribute name="margin-bottom">0mm</xsl:attribute>
|
|
1866
|
-
</xsl:if>
|
|
1867
|
-
<fo:page-number/>
|
|
1868
|
-
</fo:block>
|
|
1869
|
-
</fo:block-container>
|
|
1870
|
-
</xsl:otherwise>
|
|
1871
|
-
</xsl:choose>
|
|
1872
|
-
</fo:static-content>
|
|
1685
|
+
<xsl:call-template name="insertFooter"/>
|
|
1873
1686
|
</xsl:template>
|
|
1874
1687
|
|
|
1875
1688
|
<xsl:template name="insertHeader">
|
|
@@ -1884,6 +1697,24 @@
|
|
|
1884
1697
|
</xsl:if>
|
|
1885
1698
|
</xsl:template>
|
|
1886
1699
|
|
|
1700
|
+
<xsl:template name="insertFooter">
|
|
1701
|
+
<fo:static-content flow-name="footer">
|
|
1702
|
+
<fo:block-container height="24mm" display-align="after">
|
|
1703
|
+
<xsl:if test="$doctype = 'technical-report'">
|
|
1704
|
+
<xsl:attribute name="height">23mm</xsl:attribute>
|
|
1705
|
+
</xsl:if>
|
|
1706
|
+
<fo:block text-align="center" margin-bottom="16mm">
|
|
1707
|
+
<xsl:if test="$vertical_layout = 'true'">
|
|
1708
|
+
<xsl:attribute name="margin-bottom">0mm</xsl:attribute>
|
|
1709
|
+
</xsl:if>
|
|
1710
|
+
<xsl:if test="$doctype = 'technical-report'"><xsl:text>- </xsl:text></xsl:if>
|
|
1711
|
+
<fo:page-number/>
|
|
1712
|
+
<xsl:if test="$doctype = 'technical-report'"><xsl:text> -</xsl:text></xsl:if>
|
|
1713
|
+
</fo:block>
|
|
1714
|
+
</fo:block-container>
|
|
1715
|
+
</fo:static-content>
|
|
1716
|
+
</xsl:template>
|
|
1717
|
+
|
|
1887
1718
|
<xsl:template name="back-page">
|
|
1888
1719
|
<xsl:choose>
|
|
1889
1720
|
<xsl:when test="$doctype = 'technical-report'">
|
|
@@ -4106,6 +3937,10 @@
|
|
|
4106
3937
|
</xsl:element>
|
|
4107
3938
|
</xsl:template>
|
|
4108
3939
|
|
|
3940
|
+
<!-- show sourcecode's name 'before' or 'after' source code -->
|
|
3941
|
+
<xsl:variable name="sourcecode-name-position"><xsl:text>after</xsl:text>
|
|
3942
|
+
</xsl:variable>
|
|
3943
|
+
|
|
4109
3944
|
<xsl:template match="mn:sourcecode" name="sourcecode">
|
|
4110
3945
|
|
|
4111
3946
|
<xsl:variable name="sourcecode_attributes">
|
|
@@ -4129,7 +3964,12 @@
|
|
|
4129
3964
|
|
|
4130
3965
|
<xsl:call-template name="refine_sourcecode-container-style"/>
|
|
4131
3966
|
|
|
4132
|
-
<fo:block-container margin-left="0mm" role="SKIP">
|
|
3967
|
+
<fo:block-container margin-left="0mm" margin-right="0mm" role="SKIP">
|
|
3968
|
+
|
|
3969
|
+
<!-- <xsl:if test="$namespace = 'rsd'"> -->
|
|
3970
|
+
<xsl:if test="$sourcecode-name-position = 'before'">
|
|
3971
|
+
<xsl:apply-templates select="mn:fmt-name"/> <!-- show sourcecode's name BEFORE content -->
|
|
3972
|
+
</xsl:if>
|
|
4133
3973
|
|
|
4134
3974
|
<fo:block xsl:use-attribute-sets="sourcecode-style">
|
|
4135
3975
|
|
|
@@ -4151,7 +3991,16 @@
|
|
|
4151
3991
|
</fo:block>
|
|
4152
3992
|
|
|
4153
3993
|
<xsl:apply-templates select="mn:dl"/> <!-- Key table -->
|
|
4154
|
-
|
|
3994
|
+
|
|
3995
|
+
<!-- <xsl:choose>
|
|
3996
|
+
<xsl:when test="$namespace = 'rsd'"></xsl:when>
|
|
3997
|
+
<xsl:otherwise>
|
|
3998
|
+
<xsl:apply-templates select="mn:fmt-name" /> --><!-- show sourcecode's name AFTER content -->
|
|
3999
|
+
<!-- </xsl:otherwise>
|
|
4000
|
+
</xsl:choose> -->
|
|
4001
|
+
<xsl:if test="$sourcecode-name-position = 'after'">
|
|
4002
|
+
<xsl:apply-templates select="mn:fmt-name"/> <!-- show sourcecode's name AFTER content -->
|
|
4003
|
+
</xsl:if>
|
|
4155
4004
|
|
|
4156
4005
|
</fo:block-container>
|
|
4157
4006
|
</fo:block-container>
|
|
@@ -5406,91 +5255,85 @@
|
|
|
5406
5255
|
<xsl:template name="refine_term-style">
|
|
5407
5256
|
</xsl:template>
|
|
5408
5257
|
|
|
5409
|
-
<xsl:attribute-set name="term-
|
|
5258
|
+
<xsl:attribute-set name="term-number-style">
|
|
5410
5259
|
<xsl:attribute name="keep-with-next">always</xsl:attribute>
|
|
5411
5260
|
<xsl:attribute name="font-weight">bold</xsl:attribute>
|
|
5412
5261
|
<xsl:attribute name="font-weight">normal</xsl:attribute>
|
|
5413
5262
|
<xsl:attribute name="space-after">2pt</xsl:attribute>
|
|
5414
5263
|
</xsl:attribute-set> <!-- term-name-style -->
|
|
5415
5264
|
|
|
5416
|
-
<xsl:template name="refine_term-
|
|
5417
|
-
</xsl:template>
|
|
5418
|
-
|
|
5419
|
-
<xsl:attribute-set name="preferred-style">
|
|
5420
|
-
</xsl:attribute-set> <!-- preferred-style -->
|
|
5421
|
-
|
|
5422
|
-
<xsl:template name="refine_preferred-style">
|
|
5265
|
+
<xsl:template name="refine_term-number-style">
|
|
5423
5266
|
</xsl:template>
|
|
5424
5267
|
|
|
5425
|
-
<xsl:attribute-set name="preferred-block-style">
|
|
5268
|
+
<xsl:attribute-set name="term-preferred-block-style">
|
|
5426
5269
|
</xsl:attribute-set> <!-- preferred-block-style -->
|
|
5427
5270
|
|
|
5428
|
-
<xsl:template name="
|
|
5271
|
+
<xsl:template name="refine_term-preferred-block-style">
|
|
5429
5272
|
</xsl:template>
|
|
5430
5273
|
|
|
5431
|
-
<xsl:attribute-set name="preferred-
|
|
5274
|
+
<xsl:attribute-set name="term-preferred-style">
|
|
5432
5275
|
<xsl:attribute name="keep-with-next">always</xsl:attribute>
|
|
5433
5276
|
<xsl:attribute name="font-weight">bold</xsl:attribute>
|
|
5434
5277
|
<xsl:attribute name="font-weight">normal</xsl:attribute>
|
|
5435
5278
|
</xsl:attribute-set> <!-- preferred-term-style -->
|
|
5436
5279
|
|
|
5437
|
-
<xsl:template name="
|
|
5280
|
+
<xsl:template name="refine_term-preferred-style">
|
|
5438
5281
|
<xsl:if test="mn:strong">
|
|
5439
5282
|
<xsl:attribute name="font-weight">normal</xsl:attribute>
|
|
5440
5283
|
</xsl:if>
|
|
5441
5284
|
</xsl:template>
|
|
5442
5285
|
|
|
5443
|
-
<xsl:attribute-set name="domain-style">
|
|
5444
|
-
</xsl:attribute-set> <!-- domain-style -->
|
|
5286
|
+
<xsl:attribute-set name="term-domain-style">
|
|
5287
|
+
</xsl:attribute-set> <!-- term-domain-style -->
|
|
5445
5288
|
|
|
5446
|
-
<xsl:template name="
|
|
5289
|
+
<xsl:template name="refine_term-domain-style">
|
|
5447
5290
|
</xsl:template>
|
|
5448
5291
|
|
|
5449
|
-
<xsl:attribute-set name="admitted-style">
|
|
5450
|
-
</xsl:attribute-set> <!-- admitted-style -->
|
|
5292
|
+
<xsl:attribute-set name="term-admitted-style">
|
|
5293
|
+
</xsl:attribute-set> <!-- term-admitted-style -->
|
|
5451
5294
|
|
|
5452
|
-
<xsl:template name="
|
|
5295
|
+
<xsl:template name="refine_term-admitted-style">
|
|
5453
5296
|
</xsl:template>
|
|
5454
5297
|
|
|
5455
|
-
<xsl:attribute-set name="deprecates-style">
|
|
5456
|
-
</xsl:attribute-set> <!-- deprecates-style -->
|
|
5298
|
+
<xsl:attribute-set name="term-deprecates-style">
|
|
5299
|
+
</xsl:attribute-set> <!-- term-deprecates-style -->
|
|
5457
5300
|
|
|
5458
|
-
<xsl:template name="
|
|
5301
|
+
<xsl:template name="refine_term-deprecates-style">
|
|
5459
5302
|
</xsl:template>
|
|
5460
5303
|
|
|
5461
|
-
<xsl:attribute-set name="related-block-style" use-attribute-sets="preferred-block-style">
|
|
5304
|
+
<xsl:attribute-set name="term-related-block-style" use-attribute-sets="term-preferred-block-style">
|
|
5462
5305
|
</xsl:attribute-set>
|
|
5463
5306
|
|
|
5464
|
-
<xsl:template name="
|
|
5307
|
+
<xsl:template name="refine_term-related-block-style">
|
|
5465
5308
|
</xsl:template>
|
|
5466
5309
|
|
|
5467
|
-
<xsl:attribute-set name="definition-style">
|
|
5310
|
+
<xsl:attribute-set name="term-definition-style">
|
|
5468
5311
|
<xsl:attribute name="space-before">2pt</xsl:attribute>
|
|
5469
5312
|
<xsl:attribute name="space-after">2pt</xsl:attribute>
|
|
5470
|
-
</xsl:attribute-set> <!-- definition-style -->
|
|
5313
|
+
</xsl:attribute-set> <!-- term-definition-style -->
|
|
5471
5314
|
|
|
5472
|
-
<xsl:template name="
|
|
5315
|
+
<xsl:template name="refine_term-definition-style">
|
|
5473
5316
|
</xsl:template>
|
|
5474
5317
|
|
|
5475
|
-
<xsl:attribute-set name="termsource-style">
|
|
5476
|
-
</xsl:attribute-set> <!-- termsource-style -->
|
|
5318
|
+
<xsl:attribute-set name="term-termsource-style">
|
|
5319
|
+
</xsl:attribute-set> <!-- term-termsource-style -->
|
|
5477
5320
|
|
|
5478
|
-
<xsl:template name="
|
|
5321
|
+
<xsl:template name="refine_term-termsource-style">
|
|
5479
5322
|
<xsl:if test="ancestor::mn:table">
|
|
5480
5323
|
<xsl:attribute name="margin-bottom">1pt</xsl:attribute>
|
|
5481
5324
|
</xsl:if>
|
|
5482
|
-
</xsl:template> <!--
|
|
5325
|
+
</xsl:template> <!-- refine_term-termsource-style -->
|
|
5483
5326
|
|
|
5484
|
-
<xsl:attribute-set name="termsource-text-style">
|
|
5485
|
-
</xsl:attribute-set> <!-- termsource-text-style -->
|
|
5327
|
+
<xsl:attribute-set name="term-termsource-text-style">
|
|
5328
|
+
</xsl:attribute-set> <!-- term-termsource-text-style -->
|
|
5486
5329
|
|
|
5487
|
-
<xsl:template name="
|
|
5330
|
+
<xsl:template name="refine_term-termsource-text-style">
|
|
5488
5331
|
</xsl:template>
|
|
5489
5332
|
|
|
5490
|
-
<xsl:attribute-set name="origin-style">
|
|
5491
|
-
</xsl:attribute-set> <!-- origin-style -->
|
|
5333
|
+
<xsl:attribute-set name="term-origin-style">
|
|
5334
|
+
</xsl:attribute-set> <!-- term-origin-style -->
|
|
5492
5335
|
|
|
5493
|
-
<xsl:template name="
|
|
5336
|
+
<xsl:template name="refine_term-origin-style">
|
|
5494
5337
|
</xsl:template>
|
|
5495
5338
|
|
|
5496
5339
|
<!-- ====== -->
|
|
@@ -5534,9 +5377,9 @@
|
|
|
5534
5377
|
<!-- modification -->
|
|
5535
5378
|
<!-- ====== -->
|
|
5536
5379
|
<xsl:template match="mn:fmt-termsource" name="termsource">
|
|
5537
|
-
<fo:block xsl:use-attribute-sets="termsource-style">
|
|
5380
|
+
<fo:block xsl:use-attribute-sets="term-termsource-style">
|
|
5538
5381
|
|
|
5539
|
-
<xsl:call-template name="
|
|
5382
|
+
<xsl:call-template name="refine_term-termsource-style"/>
|
|
5540
5383
|
|
|
5541
5384
|
<!-- Example: [SOURCE: ISO 5127:2017, 3.1.6.02] -->
|
|
5542
5385
|
<xsl:variable name="termsource_text">
|
|
@@ -5584,8 +5427,8 @@
|
|
|
5584
5427
|
|
|
5585
5428
|
<!-- text SOURCE: -->
|
|
5586
5429
|
<xsl:template match="mn:fmt-termsource/mn:strong[1][following-sibling::*[1][self::mn:fmt-origin]]/text()">
|
|
5587
|
-
<fo:inline xsl:use-attribute-sets="termsource-text-style">
|
|
5588
|
-
<xsl:call-template name="
|
|
5430
|
+
<fo:inline xsl:use-attribute-sets="term-termsource-text-style">
|
|
5431
|
+
<xsl:call-template name="refine_term-termsource-text-style"/>
|
|
5589
5432
|
<xsl:value-of select="."/>
|
|
5590
5433
|
</fo:inline>
|
|
5591
5434
|
</xsl:template>
|
|
@@ -5597,8 +5440,8 @@
|
|
|
5597
5440
|
<xsl:if test="normalize-space(@citeas) = ''">
|
|
5598
5441
|
<xsl:attribute name="fox:alt-text"><xsl:value-of select="@bibitemid"/></xsl:attribute>
|
|
5599
5442
|
</xsl:if>
|
|
5600
|
-
<fo:inline xsl:use-attribute-sets="origin-style">
|
|
5601
|
-
<xsl:call-template name="
|
|
5443
|
+
<fo:inline xsl:use-attribute-sets="term-origin-style">
|
|
5444
|
+
<xsl:call-template name="refine_term-origin-style"/>
|
|
5602
5445
|
<xsl:apply-templates/>
|
|
5603
5446
|
</fo:inline>
|
|
5604
5447
|
</fo:basic-link>
|
|
@@ -5646,14 +5489,14 @@
|
|
|
5646
5489
|
<xsl:variable name="levelTerm">
|
|
5647
5490
|
<xsl:call-template name="getLevelTermName"/>
|
|
5648
5491
|
</xsl:variable>
|
|
5649
|
-
<fo:block font-size="{normalize-space($font-size)}" role="H{$levelTerm}" xsl:use-attribute-sets="preferred-block-style">
|
|
5492
|
+
<fo:block font-size="{normalize-space($font-size)}" role="H{$levelTerm}" xsl:use-attribute-sets="term-preferred-block-style">
|
|
5650
5493
|
|
|
5651
|
-
<xsl:call-template name="
|
|
5494
|
+
<xsl:call-template name="refine_term-preferred-block-style"/>
|
|
5652
5495
|
|
|
5653
5496
|
<xsl:if test="parent::mn:term and not(preceding-sibling::mn:fmt-preferred)"> <!-- if first preffered in term, then display term's name -->
|
|
5654
5497
|
|
|
5655
|
-
<fo:block xsl:use-attribute-sets="term-
|
|
5656
|
-
<xsl:call-template name="refine_term-
|
|
5498
|
+
<fo:block xsl:use-attribute-sets="term-number-style" role="SKIP">
|
|
5499
|
+
<xsl:call-template name="refine_term-number-style"/>
|
|
5657
5500
|
|
|
5658
5501
|
<xsl:for-each select="ancestor::mn:term[1]/mn:fmt-name"><!-- change context -->
|
|
5659
5502
|
<xsl:call-template name="setIDforNamedDestination"/>
|
|
@@ -5663,8 +5506,8 @@
|
|
|
5663
5506
|
</fo:block>
|
|
5664
5507
|
</xsl:if>
|
|
5665
5508
|
|
|
5666
|
-
<fo:block xsl:use-attribute-sets="preferred-
|
|
5667
|
-
<xsl:call-template name="
|
|
5509
|
+
<fo:block xsl:use-attribute-sets="term-preferred-style" role="SKIP">
|
|
5510
|
+
<xsl:call-template name="refine_term-preferred-style"/>
|
|
5668
5511
|
|
|
5669
5512
|
<xsl:apply-templates/>
|
|
5670
5513
|
</fo:block>
|
|
@@ -5684,15 +5527,15 @@
|
|
|
5684
5527
|
<xsl:template match="mn:domain"/>
|
|
5685
5528
|
|
|
5686
5529
|
<xsl:template match="mn:fmt-admitted">
|
|
5687
|
-
<fo:block xsl:use-attribute-sets="admitted-style">
|
|
5688
|
-
<xsl:call-template name="
|
|
5530
|
+
<fo:block xsl:use-attribute-sets="term-admitted-style">
|
|
5531
|
+
<xsl:call-template name="refine_term-admitted-style"/>
|
|
5689
5532
|
<xsl:apply-templates/>
|
|
5690
5533
|
</fo:block>
|
|
5691
5534
|
</xsl:template>
|
|
5692
5535
|
|
|
5693
5536
|
<xsl:template match="mn:fmt-deprecates">
|
|
5694
|
-
<fo:block xsl:use-attribute-sets="deprecates-style">
|
|
5695
|
-
<xsl:call-template name="
|
|
5537
|
+
<fo:block xsl:use-attribute-sets="term-deprecates-style">
|
|
5538
|
+
<xsl:call-template name="refine_term-deprecates-style"/>
|
|
5696
5539
|
<xsl:apply-templates/>
|
|
5697
5540
|
</fo:block>
|
|
5698
5541
|
</xsl:template>
|
|
@@ -5705,8 +5548,8 @@
|
|
|
5705
5548
|
<!-- End Preferred, admitted, deprecated -->
|
|
5706
5549
|
|
|
5707
5550
|
<xsl:template match="mn:fmt-related">
|
|
5708
|
-
<fo:block role="SKIP" xsl:use-attribute-sets="related-block-style">
|
|
5709
|
-
<xsl:call-template name="
|
|
5551
|
+
<fo:block role="SKIP" xsl:use-attribute-sets="term-related-block-style">
|
|
5552
|
+
<xsl:call-template name="refine_term-related-block-style"/>
|
|
5710
5553
|
<xsl:apply-templates/>
|
|
5711
5554
|
</fo:block>
|
|
5712
5555
|
</xsl:template>
|
|
@@ -5720,8 +5563,8 @@
|
|
|
5720
5563
|
<!-- definition -->
|
|
5721
5564
|
<!-- ========== -->
|
|
5722
5565
|
<xsl:template match="mn:fmt-definition">
|
|
5723
|
-
<fo:block xsl:use-attribute-sets="definition-style" role="SKIP">
|
|
5724
|
-
<xsl:call-template name="
|
|
5566
|
+
<fo:block xsl:use-attribute-sets="term-definition-style" role="SKIP">
|
|
5567
|
+
<xsl:call-template name="refine_term-definition-style"/>
|
|
5725
5568
|
<xsl:apply-templates/>
|
|
5726
5569
|
</fo:block>
|
|
5727
5570
|
</xsl:template>
|
|
@@ -9989,6 +9832,10 @@
|
|
|
9989
9832
|
<!-- image -->
|
|
9990
9833
|
<!-- ====== -->
|
|
9991
9834
|
|
|
9835
|
+
<!-- show figure's name 'before' or 'after' image -->
|
|
9836
|
+
<xsl:variable name="figure-name-position"><xsl:text>after</xsl:text>
|
|
9837
|
+
</xsl:variable>
|
|
9838
|
+
|
|
9992
9839
|
<xsl:template match="mn:figure" name="figure">
|
|
9993
9840
|
<xsl:variable name="isAdded" select="@added"/>
|
|
9994
9841
|
<xsl:variable name="isDeleted" select="@deleted"/>
|
|
@@ -10001,6 +9848,10 @@
|
|
|
10001
9848
|
<xsl:with-param name="isDeleted" select="$isDeleted"/>
|
|
10002
9849
|
</xsl:call-template>
|
|
10003
9850
|
|
|
9851
|
+
<xsl:if test="$figure-name-position = 'before'"> <!-- show figure's name BEFORE image -->
|
|
9852
|
+
<xsl:apply-templates select="mn:fmt-name"/>
|
|
9853
|
+
</xsl:if>
|
|
9854
|
+
|
|
10004
9855
|
<!-- Example: Dimensions in millimeters -->
|
|
10005
9856
|
<xsl:apply-templates select="mn:note[@type = 'units']"/>
|
|
10006
9857
|
|
|
@@ -10021,7 +9872,16 @@
|
|
|
10021
9872
|
<xsl:if test="normalize-space($show_figure_key_in_block_container) = 'true'">
|
|
10022
9873
|
<xsl:call-template name="showFigureKey"/>
|
|
10023
9874
|
</xsl:if>
|
|
10024
|
-
|
|
9875
|
+
|
|
9876
|
+
<!-- <xsl:choose>
|
|
9877
|
+
<xsl:when test="$namespace = 'bsi' or $namespace = 'pas' or $namespace = 'rsd'"></xsl:when>
|
|
9878
|
+
<xsl:otherwise>
|
|
9879
|
+
<xsl:apply-templates select="mn:fmt-name" /> --> <!-- show figure's name AFTER image -->
|
|
9880
|
+
<!-- </xsl:otherwise>
|
|
9881
|
+
</xsl:choose> -->
|
|
9882
|
+
<xsl:if test="$figure-name-position = 'after'">
|
|
9883
|
+
<xsl:apply-templates select="mn:fmt-name"/> <!-- show figure's name AFTER image -->
|
|
9884
|
+
</xsl:if>
|
|
10025
9885
|
|
|
10026
9886
|
</fo:block-container>
|
|
10027
9887
|
</xsl:template>
|
|
@@ -12103,7 +11963,6 @@
|
|
|
12103
11963
|
</xsl:attribute-set>
|
|
12104
11964
|
|
|
12105
11965
|
<xsl:template name="refine_references-non-normative-title-style">
|
|
12106
|
-
|
|
12107
11966
|
</xsl:template>
|
|
12108
11967
|
|
|
12109
11968
|
<!-- bibitem in Normative References (references/@normative="true") -->
|
|
@@ -14157,7 +14016,7 @@
|
|
|
14157
14016
|
<!-- ===================================== -->
|
|
14158
14017
|
|
|
14159
14018
|
<xsl:attribute-set name="annex-title-style">
|
|
14160
|
-
</xsl:attribute-set>
|
|
14019
|
+
</xsl:attribute-set> <!-- annex-title-style -->
|
|
14161
14020
|
|
|
14162
14021
|
<xsl:template name="refine_annex-title-style">
|
|
14163
14022
|
</xsl:template>
|
|
@@ -14168,6 +14027,211 @@
|
|
|
14168
14027
|
<xsl:template name="refine_p-zzSTDTitle1-style">
|
|
14169
14028
|
</xsl:template>
|
|
14170
14029
|
|
|
14030
|
+
<xsl:attribute-set name="p-style">
|
|
14031
|
+
<xsl:attribute name="margin-bottom">10pt</xsl:attribute>
|
|
14032
|
+
</xsl:attribute-set> <!-- p-style -->
|
|
14033
|
+
|
|
14034
|
+
<xsl:template name="refine_p-style">
|
|
14035
|
+
<xsl:param name="element-name"/>
|
|
14036
|
+
<xsl:param name="margin"/>
|
|
14037
|
+
<xsl:call-template name="setBlockAttributes">
|
|
14038
|
+
<xsl:with-param name="text_align_default">justify</xsl:with-param>
|
|
14039
|
+
</xsl:call-template>
|
|
14040
|
+
|
|
14041
|
+
<xsl:if test="$doctype = 'technical-report'">
|
|
14042
|
+
<xsl:attribute name="margin-bottom">18pt</xsl:attribute>
|
|
14043
|
+
</xsl:if>
|
|
14044
|
+
|
|
14045
|
+
<!--
|
|
14046
|
+
<xsl:if test="not(parent::mn:note or parent::mn:li or ancestor::mn:table)">
|
|
14047
|
+
<xsl:attribute name="text-indent"><xsl:value-of select="$text_indent"/>mm</xsl:attribute>
|
|
14048
|
+
</xsl:if>
|
|
14049
|
+
-->
|
|
14050
|
+
|
|
14051
|
+
<xsl:copy-of select="@id"/>
|
|
14052
|
+
|
|
14053
|
+
<xsl:if test="$doctype = 'technical-report'">
|
|
14054
|
+
<xsl:attribute name="line-height">1.8</xsl:attribute>
|
|
14055
|
+
</xsl:if>
|
|
14056
|
+
|
|
14057
|
+
<!-- bookmarks only in paragraph -->
|
|
14058
|
+
<xsl:if test="count(mn:bookmark) != 0 and count(*) = count(mn:bookmark) and normalize-space() = ''">
|
|
14059
|
+
<xsl:attribute name="font-size">0</xsl:attribute>
|
|
14060
|
+
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
|
14061
|
+
<xsl:attribute name="line-height">0</xsl:attribute>
|
|
14062
|
+
</xsl:if>
|
|
14063
|
+
|
|
14064
|
+
<xsl:if test="ancestor::*[@key = 'true']">
|
|
14065
|
+
<xsl:attribute name="margin-bottom">2pt</xsl:attribute>
|
|
14066
|
+
</xsl:if>
|
|
14067
|
+
|
|
14068
|
+
<xsl:if test="parent::mn:fmt-definition">
|
|
14069
|
+
<xsl:attribute name="margin-bottom">2pt</xsl:attribute>
|
|
14070
|
+
</xsl:if>
|
|
14071
|
+
|
|
14072
|
+
<xsl:if test="parent::mn:li or parent::mn:quote">
|
|
14073
|
+
<xsl:attribute name="margin-bottom">8pt</xsl:attribute>
|
|
14074
|
+
</xsl:if>
|
|
14075
|
+
|
|
14076
|
+
<xsl:if test="parent::mn:li and following-sibling::*[1][self::mn:ol or self::mn:ul or self::mn:note or self::mn:example]">
|
|
14077
|
+
<xsl:attribute name="margin-bottom">4pt</xsl:attribute>
|
|
14078
|
+
</xsl:if>
|
|
14079
|
+
|
|
14080
|
+
<xsl:if test="ancestor::mn:td or ancestor::mn:th">
|
|
14081
|
+
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
|
14082
|
+
</xsl:if>
|
|
14083
|
+
|
|
14084
|
+
<xsl:if test="parent::mn:dd">
|
|
14085
|
+
<xsl:attribute name="margin-bottom">5pt</xsl:attribute>
|
|
14086
|
+
</xsl:if>
|
|
14087
|
+
|
|
14088
|
+
<xsl:if test="parent::mn:dd and ancestor::mn:dl[@key = 'true'] and (ancestor::mn:tfoot or ancestor::mn:figure)">
|
|
14089
|
+
<xsl:attribute name="margin-bottom">2pt</xsl:attribute>
|
|
14090
|
+
</xsl:if>
|
|
14091
|
+
|
|
14092
|
+
<xsl:if test="parent::mn:clause[@type = 'inner-cover-note'] or ancestor::mn:boilerplate">
|
|
14093
|
+
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
|
14094
|
+
</xsl:if>
|
|
14095
|
+
|
|
14096
|
+
<xsl:if test="parent::mn:note and not(following-sibling::*)">
|
|
14097
|
+
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
|
14098
|
+
</xsl:if>
|
|
14099
|
+
|
|
14100
|
+
<xsl:if test="(ancestor::*[local-name() = 'td' or local-name() = 'th']) and (.//*[local-name() = 'font_en' or local-name() = 'font_en_bold'])">
|
|
14101
|
+
<xsl:if test="$isGenerateTableIF = 'false'">
|
|
14102
|
+
<xsl:attribute name="language">en</xsl:attribute>
|
|
14103
|
+
<xsl:attribute name="hyphenate">true</xsl:attribute>
|
|
14104
|
+
</xsl:if>
|
|
14105
|
+
</xsl:if>
|
|
14106
|
+
|
|
14107
|
+
<xsl:if test="ancestor::mn:note[@type = 'units']">
|
|
14108
|
+
<xsl:attribute name="text-align">right</xsl:attribute>
|
|
14109
|
+
</xsl:if>
|
|
14110
|
+
|
|
14111
|
+
<!-- paragraph in table or figure footer -->
|
|
14112
|
+
<xsl:if test="parent::mn:table or parent::mn:figure or (ancestor::mn:tfoot and ancestor::mn:td[1]/@colspan and not(parent::mn:dd))">
|
|
14113
|
+
<xsl:attribute name="margin-left"><xsl:value-of select="$tableAnnotationIndent"/></xsl:attribute>
|
|
14114
|
+
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
|
14115
|
+
</xsl:if>
|
|
14116
|
+
<!-- namespace = 'plateau' -->
|
|
14117
|
+
|
|
14118
|
+
</xsl:template> <!-- refine_p-style -->
|
|
14119
|
+
|
|
14120
|
+
<xsl:attribute-set name="title-style">
|
|
14121
|
+
<!-- Note: font-size for level 1 title -->
|
|
14122
|
+
<xsl:attribute name="font-size">10pt</xsl:attribute>
|
|
14123
|
+
<xsl:attribute name="font-weight">bold</xsl:attribute>
|
|
14124
|
+
<xsl:attribute name="text-align">left</xsl:attribute>
|
|
14125
|
+
<xsl:attribute name="space-before">0mm</xsl:attribute>
|
|
14126
|
+
<xsl:attribute name="margin-bottom">12pt</xsl:attribute>
|
|
14127
|
+
<xsl:attribute name="keep-with-next">always</xsl:attribute>
|
|
14128
|
+
</xsl:attribute-set> <!-- title-style -->
|
|
14129
|
+
|
|
14130
|
+
<xsl:template name="refine_title-style">
|
|
14131
|
+
<xsl:param name="element-name"/>
|
|
14132
|
+
<xsl:variable name="level">
|
|
14133
|
+
<xsl:call-template name="getLevel"/>
|
|
14134
|
+
</xsl:variable>
|
|
14135
|
+
<!-- <xsl:attribute name="font-size">10pt</xsl:attribute> -->
|
|
14136
|
+
<xsl:if test="ancestor::mn:sections">
|
|
14137
|
+
<xsl:attribute name="font-size">12pt</xsl:attribute>
|
|
14138
|
+
</xsl:if>
|
|
14139
|
+
<xsl:if test="ancestor::mn:annex">
|
|
14140
|
+
<xsl:attribute name="font-size">12pt</xsl:attribute>
|
|
14141
|
+
</xsl:if>
|
|
14142
|
+
|
|
14143
|
+
<xsl:if test="@inline-header = 'true'">
|
|
14144
|
+
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
|
14145
|
+
</xsl:if>
|
|
14146
|
+
|
|
14147
|
+
<xsl:if test="@type = 'section-title'">
|
|
14148
|
+
<xsl:attribute name="margin-bottom">6mm</xsl:attribute>
|
|
14149
|
+
</xsl:if>
|
|
14150
|
+
|
|
14151
|
+
<xsl:if test="$level = 1">
|
|
14152
|
+
<xsl:if test="not(ancestor::mn:preface)">
|
|
14153
|
+
<xsl:attribute name="space-before">6.5mm</xsl:attribute>
|
|
14154
|
+
</xsl:if>
|
|
14155
|
+
<xsl:if test="following-sibling::*[1][self::mn:clause]">
|
|
14156
|
+
<xsl:attribute name="margin-bottom">8pt</xsl:attribute>
|
|
14157
|
+
</xsl:if>
|
|
14158
|
+
<xsl:if test="ancestor::mn:foreword">
|
|
14159
|
+
<xsl:attribute name="text-align">center</xsl:attribute>
|
|
14160
|
+
<xsl:attribute name="space-before">9mm</xsl:attribute>
|
|
14161
|
+
<xsl:attribute name="margin-bottom">9mm</xsl:attribute>
|
|
14162
|
+
</xsl:if>
|
|
14163
|
+
<xsl:if test="ancestor::mn:annex">
|
|
14164
|
+
<xsl:attribute name="font-size">14pt</xsl:attribute>
|
|
14165
|
+
<xsl:attribute name="text-align">center</xsl:attribute>
|
|
14166
|
+
<xsl:attribute name="space-before">0mm</xsl:attribute>
|
|
14167
|
+
</xsl:if>
|
|
14168
|
+
<xsl:if test="$doctype = 'technical-report'">
|
|
14169
|
+
<xsl:attribute name="font-size">16pt</xsl:attribute>
|
|
14170
|
+
</xsl:if>
|
|
14171
|
+
</xsl:if>
|
|
14172
|
+
<xsl:if test="$level >= 2">
|
|
14173
|
+
<xsl:attribute name="margin-bottom">12pt</xsl:attribute>
|
|
14174
|
+
</xsl:if>
|
|
14175
|
+
<xsl:if test="$level = 2">
|
|
14176
|
+
<xsl:attribute name="space-before">2mm</xsl:attribute>
|
|
14177
|
+
<xsl:if test="ancestor::mn:foreword">
|
|
14178
|
+
<xsl:attribute name="space-before">0mm</xsl:attribute>
|
|
14179
|
+
</xsl:if>
|
|
14180
|
+
<xsl:if test="ancestor::mn:bibliography">
|
|
14181
|
+
<xsl:attribute name="space-before">0mm</xsl:attribute>
|
|
14182
|
+
</xsl:if>
|
|
14183
|
+
|
|
14184
|
+
<xsl:if test="following-sibling::*[1][self::mn:clause]">
|
|
14185
|
+
<xsl:attribute name="margin-bottom">8pt</xsl:attribute>
|
|
14186
|
+
</xsl:if>
|
|
14187
|
+
|
|
14188
|
+
<xsl:if test="$doctype = 'technical-report'">
|
|
14189
|
+
<xsl:attribute name="font-size">14pt</xsl:attribute>
|
|
14190
|
+
<xsl:attribute name="background-color">rgb(229,229,229)</xsl:attribute>
|
|
14191
|
+
<xsl:attribute name="padding-top">2mm</xsl:attribute>
|
|
14192
|
+
<xsl:attribute name="padding-bottom">2mm</xsl:attribute>
|
|
14193
|
+
<xsl:if test="preceding-sibling::*[2][self::mn:fmt-title]">
|
|
14194
|
+
<xsl:attribute name="space-before">0mm</xsl:attribute>
|
|
14195
|
+
</xsl:if>
|
|
14196
|
+
</xsl:if>
|
|
14197
|
+
</xsl:if>
|
|
14198
|
+
<xsl:if test="$level = 3">
|
|
14199
|
+
<xsl:attribute name="space-before">2mm</xsl:attribute>
|
|
14200
|
+
<xsl:if test="$doctype = 'technical-report'">
|
|
14201
|
+
<xsl:attribute name="font-size">12pt</xsl:attribute>
|
|
14202
|
+
<xsl:attribute name="background-color">rgb(204,204,204)</xsl:attribute>
|
|
14203
|
+
<xsl:if test="preceding-sibling::*[2][self::mn:fmt-title]">
|
|
14204
|
+
<xsl:attribute name="space-before">0mm</xsl:attribute>
|
|
14205
|
+
</xsl:if>
|
|
14206
|
+
</xsl:if>
|
|
14207
|
+
</xsl:if>
|
|
14208
|
+
<xsl:if test="$level >= 4">
|
|
14209
|
+
<xsl:attribute name="space-before">2mm</xsl:attribute>
|
|
14210
|
+
<xsl:if test="$doctype = 'technical-report'">
|
|
14211
|
+
<xsl:attribute name="font-size">10pt</xsl:attribute>
|
|
14212
|
+
</xsl:if>
|
|
14213
|
+
</xsl:if>
|
|
14214
|
+
|
|
14215
|
+
<xsl:if test="ancestor::mn:preface">
|
|
14216
|
+
<xsl:attribute name="margin-bottom">6pt</xsl:attribute>
|
|
14217
|
+
</xsl:if>
|
|
14218
|
+
|
|
14219
|
+
<xsl:if test="$doctype = 'technical-report'">
|
|
14220
|
+
<xsl:if test="following-sibling::*[1][self::mn:clause]">
|
|
14221
|
+
<xsl:attribute name="margin-bottom">0</xsl:attribute>
|
|
14222
|
+
</xsl:if>
|
|
14223
|
+
<xsl:if test="following-sibling::*[1][self::mn:p]">
|
|
14224
|
+
<xsl:attribute name="margin-bottom">16pt</xsl:attribute>
|
|
14225
|
+
</xsl:if>
|
|
14226
|
+
</xsl:if>
|
|
14227
|
+
|
|
14228
|
+
<xsl:if test="@type = 'floating-title' or @type = 'section-title'">
|
|
14229
|
+
<xsl:copy-of select="@id"/>
|
|
14230
|
+
</xsl:if>
|
|
14231
|
+
<!-- $namespace = 'plateau' -->
|
|
14232
|
+
<xsl:attribute name="role">H<xsl:value-of select="$level"/></xsl:attribute>
|
|
14233
|
+
</xsl:template> <!-- refine_title-style -->
|
|
14234
|
+
|
|
14171
14235
|
<xsl:template name="processPrefaceSectionsDefault">
|
|
14172
14236
|
<xsl:for-each select="/*/mn:preface/*[not(self::mn:note or self::mn:admonition)]">
|
|
14173
14237
|
<xsl:sort select="@displayorder" data-type="number"/>
|
|
@@ -14506,6 +14570,12 @@
|
|
|
14506
14570
|
</xsl:choose>
|
|
14507
14571
|
</xsl:template>
|
|
14508
14572
|
|
|
14573
|
+
<xsl:attribute-set name="reset-margins-style">
|
|
14574
|
+
<xsl:attribute name="margin-left">0mm</xsl:attribute>
|
|
14575
|
+
<xsl:attribute name="margin-right">0mm</xsl:attribute>
|
|
14576
|
+
<xsl:attribute name="role">SKIP</xsl:attribute>
|
|
14577
|
+
</xsl:attribute-set>
|
|
14578
|
+
|
|
14509
14579
|
<xsl:attribute-set name="clause-style">
|
|
14510
14580
|
|
|
14511
14581
|
</xsl:attribute-set>
|
|
@@ -15541,8 +15611,9 @@
|
|
|
15541
15611
|
|
|
15542
15612
|
<xsl:template name="setTextAlignment">
|
|
15543
15613
|
<xsl:param name="default">left</xsl:param>
|
|
15614
|
+
<xsl:param name="skip_default">false</xsl:param>
|
|
15544
15615
|
<xsl:variable name="align" select="normalize-space(@align)"/>
|
|
15545
|
-
<xsl:
|
|
15616
|
+
<xsl:variable name="text_align">
|
|
15546
15617
|
<xsl:choose>
|
|
15547
15618
|
<xsl:when test="$lang = 'ar' and $align = 'left'">start</xsl:when>
|
|
15548
15619
|
<xsl:when test="$lang = 'ar' and $align = 'right'">end</xsl:when>
|
|
@@ -15550,9 +15621,13 @@
|
|
|
15550
15621
|
<xsl:when test="$align != '' and not($align = 'indent')"><xsl:value-of select="$align"/></xsl:when>
|
|
15551
15622
|
<xsl:when test="ancestor::mn:td/@align"><xsl:value-of select="ancestor::mn:td/@align"/></xsl:when>
|
|
15552
15623
|
<xsl:when test="ancestor::mn:th/@align"><xsl:value-of select="ancestor::mn:th/@align"/></xsl:when>
|
|
15624
|
+
<xsl:when test="$skip_default = 'true'"/>
|
|
15553
15625
|
<xsl:otherwise><xsl:value-of select="$default"/></xsl:otherwise>
|
|
15554
15626
|
</xsl:choose>
|
|
15555
|
-
</xsl:
|
|
15627
|
+
</xsl:variable>
|
|
15628
|
+
<xsl:if test="normalize-space($text_align) != ''">
|
|
15629
|
+
<xsl:attribute name="text-align"><xsl:value-of select="$text_align"/></xsl:attribute>
|
|
15630
|
+
</xsl:if>
|
|
15556
15631
|
<xsl:if test="$align = 'indent'">
|
|
15557
15632
|
<xsl:attribute name="margin-left">7mm</xsl:attribute>
|
|
15558
15633
|
</xsl:if>
|
|
@@ -15560,8 +15635,10 @@
|
|
|
15560
15635
|
|
|
15561
15636
|
<xsl:template name="setBlockAttributes">
|
|
15562
15637
|
<xsl:param name="text_align_default">left</xsl:param>
|
|
15638
|
+
<xsl:param name="skip_text_align_default">false</xsl:param>
|
|
15563
15639
|
<xsl:call-template name="setTextAlignment">
|
|
15564
15640
|
<xsl:with-param name="default" select="$text_align_default"/>
|
|
15641
|
+
<xsl:with-param name="skip_default" select="$skip_text_align_default"/>
|
|
15565
15642
|
</xsl:call-template>
|
|
15566
15643
|
<xsl:call-template name="setKeepAttributes"/>
|
|
15567
15644
|
<xsl:if test="node()[1][self::mn:span][contains(@style, 'line-height')]">
|
|
@@ -15604,6 +15681,20 @@
|
|
|
15604
15681
|
</fo:block-container>
|
|
15605
15682
|
</xsl:template>
|
|
15606
15683
|
|
|
15684
|
+
<!-- for https://github.com/metanorma/mn-native-pdf/issues/845 -->
|
|
15685
|
+
<xsl:template name="insertCoverPageFullImage">
|
|
15686
|
+
<xsl:param name="name">coverpage-image</xsl:param>
|
|
15687
|
+
<xsl:for-each select="//mn:metanorma/mn:metanorma-extension/mn:presentation-metadata[mn:name = $name][1]/mn:value/mn:image">
|
|
15688
|
+
<fo:page-sequence master-reference="cover-page" force-page-count="no-force">
|
|
15689
|
+
<fo:flow flow-name="xsl-region-body">
|
|
15690
|
+
<xsl:call-template name="insertBackgroundPageImage">
|
|
15691
|
+
<xsl:with-param name="number" select="position()"/>
|
|
15692
|
+
</xsl:call-template>
|
|
15693
|
+
</fo:flow>
|
|
15694
|
+
</fo:page-sequence>
|
|
15695
|
+
</xsl:for-each>
|
|
15696
|
+
</xsl:template>
|
|
15697
|
+
|
|
15607
15698
|
<xsl:template name="insertPageImage">
|
|
15608
15699
|
<xsl:param name="svg_content_height" select="$pageHeight"/>
|
|
15609
15700
|
<xsl:param name="bitmap_width" select="$pageWidth"/>
|