metanorma-un 0.5.12 → 0.5.13
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/asciidoctor/un/isodoc.rng +63 -0
- data/lib/isodoc/un/un.plenary-attachment.xsl +245 -182
- data/lib/isodoc/un/un.plenary.xsl +245 -182
- data/lib/isodoc/un/un.recommendation.xsl +250 -187
- data/lib/metanorma/un/version.rb +1 -1
- metadata +3 -3
@@ -1700,198 +1700,226 @@
|
|
1700
1700
|
<xsl:call-template name="add-zero-spaces-java"/>
|
1701
1701
|
</xsl:template><xsl:template match="*[local-name()='table']" name="table">
|
1702
1702
|
|
1703
|
-
<xsl:variable name="
|
1704
|
-
<xsl:call-template name="getSimpleTable"/>
|
1705
|
-
</xsl:variable>
|
1703
|
+
<xsl:variable name="table">
|
1706
1704
|
|
1707
|
-
|
1708
|
-
|
1709
|
-
|
1710
|
-
|
1711
|
-
<!-- <xsl:if test="$namespace = 'bipm'">
|
1712
|
-
<fo:block> </fo:block>
|
1713
|
-
</xsl:if> -->
|
1714
|
-
|
1715
|
-
<!-- $namespace = 'iso' or -->
|
1716
|
-
|
1717
|
-
<xsl:apply-templates select="*[local-name()='name']" mode="presentation"/>
|
1718
|
-
|
1719
|
-
|
1720
|
-
|
1721
|
-
<xsl:call-template name="fn_name_display"/>
|
1705
|
+
<xsl:variable name="simple-table">
|
1706
|
+
<xsl:call-template name="getSimpleTable"/>
|
1707
|
+
</xsl:variable>
|
1722
1708
|
|
1723
1709
|
|
1724
|
-
|
1725
|
-
<xsl:variable name="cols-count" select="count(xalan:nodeset($simple-table)//tr[1]/td)"/>
|
1726
|
-
|
1727
|
-
<!-- <xsl:variable name="cols-count">
|
1728
|
-
<xsl:choose>
|
1729
|
-
<xsl:when test="*[local-name()='thead']">
|
1730
|
-
<xsl:call-template name="calculate-columns-numbers">
|
1731
|
-
<xsl:with-param name="table-row" select="*[local-name()='thead']/*[local-name()='tr'][1]"/>
|
1732
|
-
</xsl:call-template>
|
1733
|
-
</xsl:when>
|
1734
|
-
<xsl:otherwise>
|
1735
|
-
<xsl:call-template name="calculate-columns-numbers">
|
1736
|
-
<xsl:with-param name="table-row" select="*[local-name()='tbody']/*[local-name()='tr'][1]"/>
|
1737
|
-
</xsl:call-template>
|
1738
|
-
</xsl:otherwise>
|
1739
|
-
</xsl:choose>
|
1740
|
-
</xsl:variable> -->
|
1741
|
-
<!-- cols-count=<xsl:copy-of select="$cols-count"/> -->
|
1742
|
-
<!-- cols-count2=<xsl:copy-of select="$cols-count2"/> -->
|
1743
|
-
|
1744
|
-
|
1745
|
-
|
1746
|
-
<xsl:variable name="colwidths">
|
1747
|
-
<xsl:if test="not(*[local-name()='colgroup']/*[local-name()='col'])">
|
1748
|
-
<xsl:call-template name="calculate-column-widths">
|
1749
|
-
<xsl:with-param name="cols-count" select="$cols-count"/>
|
1750
|
-
<xsl:with-param name="table" select="$simple-table"/>
|
1751
|
-
</xsl:call-template>
|
1752
|
-
</xsl:if>
|
1753
|
-
</xsl:variable>
|
1754
|
-
<!-- colwidths=<xsl:copy-of select="$colwidths"/> -->
|
1755
|
-
|
1756
|
-
<!-- <xsl:variable name="colwidths2">
|
1757
|
-
<xsl:call-template name="calculate-column-widths">
|
1758
|
-
<xsl:with-param name="cols-count" select="$cols-count"/>
|
1759
|
-
</xsl:call-template>
|
1760
|
-
</xsl:variable> -->
|
1761
|
-
|
1762
|
-
<!-- cols-count=<xsl:copy-of select="$cols-count"/>
|
1763
|
-
colwidthsNew=<xsl:copy-of select="$colwidths"/>
|
1764
|
-
colwidthsOld=<xsl:copy-of select="$colwidths2"/>z -->
|
1765
|
-
|
1766
|
-
<xsl:variable name="margin-left">
|
1767
|
-
<xsl:choose>
|
1768
|
-
<xsl:when test="sum(xalan:nodeset($colwidths)//column) > 75">15</xsl:when>
|
1769
|
-
<xsl:otherwise>0</xsl:otherwise>
|
1770
|
-
</xsl:choose>
|
1771
|
-
</xsl:variable>
|
1772
|
-
|
1773
|
-
<fo:block-container margin-left="-{$margin-left}mm" margin-right="-{$margin-left}mm">
|
1774
1710
|
|
1775
1711
|
|
1776
|
-
|
1777
|
-
|
1778
1712
|
|
1779
|
-
|
1780
|
-
<
|
1781
|
-
|
1713
|
+
<!-- <xsl:if test="$namespace = 'bipm'">
|
1714
|
+
<fo:block> </fo:block>
|
1715
|
+
</xsl:if> -->
|
1782
1716
|
|
1717
|
+
<!-- $namespace = 'iso' or -->
|
1783
1718
|
|
1784
|
-
|
1719
|
+
<xsl:apply-templates select="*[local-name()='name']" mode="presentation"/>
|
1785
1720
|
|
1721
|
+
|
1786
1722
|
|
1723
|
+
<xsl:call-template name="fn_name_display"/>
|
1787
1724
|
|
1725
|
+
|
1788
1726
|
|
1727
|
+
<xsl:variable name="cols-count" select="count(xalan:nodeset($simple-table)//tr[1]/td)"/>
|
1789
1728
|
|
1729
|
+
<!-- <xsl:variable name="cols-count">
|
1730
|
+
<xsl:choose>
|
1731
|
+
<xsl:when test="*[local-name()='thead']">
|
1732
|
+
<xsl:call-template name="calculate-columns-numbers">
|
1733
|
+
<xsl:with-param name="table-row" select="*[local-name()='thead']/*[local-name()='tr'][1]"/>
|
1734
|
+
</xsl:call-template>
|
1735
|
+
</xsl:when>
|
1736
|
+
<xsl:otherwise>
|
1737
|
+
<xsl:call-template name="calculate-columns-numbers">
|
1738
|
+
<xsl:with-param name="table-row" select="*[local-name()='tbody']/*[local-name()='tr'][1]"/>
|
1739
|
+
</xsl:call-template>
|
1740
|
+
</xsl:otherwise>
|
1741
|
+
</xsl:choose>
|
1742
|
+
</xsl:variable> -->
|
1743
|
+
<!-- cols-count=<xsl:copy-of select="$cols-count"/> -->
|
1744
|
+
<!-- cols-count2=<xsl:copy-of select="$cols-count2"/> -->
|
1790
1745
|
|
1791
1746
|
|
1792
|
-
|
1793
|
-
|
1794
|
-
<
|
1795
|
-
<xsl:
|
1796
|
-
<xsl:
|
1797
|
-
<xsl:
|
1798
|
-
</xsl:
|
1799
|
-
</
|
1800
|
-
|
1801
|
-
|
1747
|
+
|
1748
|
+
<xsl:variable name="colwidths">
|
1749
|
+
<xsl:if test="not(*[local-name()='colgroup']/*[local-name()='col'])">
|
1750
|
+
<xsl:call-template name="calculate-column-widths">
|
1751
|
+
<xsl:with-param name="cols-count" select="$cols-count"/>
|
1752
|
+
<xsl:with-param name="table" select="$simple-table"/>
|
1753
|
+
</xsl:call-template>
|
1754
|
+
</xsl:if>
|
1755
|
+
</xsl:variable>
|
1756
|
+
<!-- colwidths=<xsl:copy-of select="$colwidths"/> -->
|
1757
|
+
|
1758
|
+
<!-- <xsl:variable name="colwidths2">
|
1759
|
+
<xsl:call-template name="calculate-column-widths">
|
1760
|
+
<xsl:with-param name="cols-count" select="$cols-count"/>
|
1761
|
+
</xsl:call-template>
|
1762
|
+
</xsl:variable> -->
|
1763
|
+
|
1764
|
+
<!-- cols-count=<xsl:copy-of select="$cols-count"/>
|
1765
|
+
colwidthsNew=<xsl:copy-of select="$colwidths"/>
|
1766
|
+
colwidthsOld=<xsl:copy-of select="$colwidths2"/>z -->
|
1767
|
+
|
1768
|
+
<xsl:variable name="margin-left">
|
1769
|
+
<xsl:choose>
|
1770
|
+
<xsl:when test="sum(xalan:nodeset($colwidths)//column) > 75">15</xsl:when>
|
1771
|
+
<xsl:otherwise>0</xsl:otherwise>
|
1772
|
+
</xsl:choose>
|
1773
|
+
</xsl:variable>
|
1774
|
+
|
1775
|
+
<fo:block-container margin-left="-{$margin-left}mm" margin-right="-{$margin-left}mm">
|
1802
1776
|
|
1803
1777
|
|
1778
|
+
|
1779
|
+
|
1804
1780
|
|
1781
|
+
<xsl:attribute name="margin-bottom">18pt</xsl:attribute>
|
1782
|
+
<xsl:attribute name="font-size">8pt</xsl:attribute>
|
1783
|
+
|
1805
1784
|
|
1806
|
-
|
1807
|
-
|
1808
1785
|
|
1809
|
-
|
1810
|
-
|
1786
|
+
|
1811
1787
|
|
1812
|
-
|
1813
1788
|
|
1814
|
-
</xsl:variable>
|
1815
|
-
|
1816
|
-
|
1817
|
-
<fo:table id="{@id}" table-omit-footer-at-break="true">
|
1818
1789
|
|
1819
|
-
<xsl:for-each select="xalan:nodeset($table_attributes)/attribute">
|
1820
|
-
<xsl:attribute name="{@name}">
|
1821
|
-
<xsl:value-of select="."/>
|
1822
|
-
</xsl:attribute>
|
1823
|
-
</xsl:for-each>
|
1824
1790
|
|
1825
|
-
<xsl:variable name="isNoteOrFnExist" select="./*[local-name()='note'] or .//*[local-name()='fn'][local-name(..) != 'name']"/>
|
1826
|
-
<xsl:if test="$isNoteOrFnExist = 'true'">
|
1827
|
-
<xsl:attribute name="border-bottom">0pt solid black</xsl:attribute> <!-- set 0pt border, because there is a separete table below for footer -->
|
1828
|
-
</xsl:if>
|
1829
1791
|
|
1830
|
-
<xsl:choose>
|
1831
|
-
<xsl:when test="*[local-name()='colgroup']/*[local-name()='col']">
|
1832
|
-
<xsl:for-each select="*[local-name()='colgroup']/*[local-name()='col']">
|
1833
|
-
<fo:table-column column-width="{@width}"/>
|
1834
|
-
</xsl:for-each>
|
1835
|
-
</xsl:when>
|
1836
|
-
<xsl:otherwise>
|
1837
|
-
<xsl:for-each select="xalan:nodeset($colwidths)//column">
|
1838
|
-
<xsl:choose>
|
1839
|
-
<xsl:when test=". = 1 or . = 0">
|
1840
|
-
<fo:table-column column-width="proportional-column-width(2)"/>
|
1841
|
-
</xsl:when>
|
1842
|
-
<xsl:otherwise>
|
1843
|
-
<fo:table-column column-width="proportional-column-width({.})"/>
|
1844
|
-
</xsl:otherwise>
|
1845
|
-
</xsl:choose>
|
1846
|
-
</xsl:for-each>
|
1847
|
-
</xsl:otherwise>
|
1848
|
-
</xsl:choose>
|
1849
1792
|
|
1850
|
-
<xsl:
|
1851
|
-
|
1852
|
-
|
1853
|
-
|
1854
|
-
|
1855
|
-
<xsl:
|
1856
|
-
|
1857
|
-
|
1793
|
+
<xsl:variable name="table_width">
|
1794
|
+
<!-- for centered table always 100% (@width will be set for middle/second cell of outer table) -->
|
1795
|
+
|
1796
|
+
|
1797
|
+
|
1798
|
+
<xsl:choose>
|
1799
|
+
<xsl:when test="@width"><xsl:value-of select="@width"/></xsl:when>
|
1800
|
+
<xsl:otherwise>100%</xsl:otherwise>
|
1801
|
+
</xsl:choose>
|
1802
|
+
|
1803
|
+
</xsl:variable>
|
1804
|
+
|
1805
|
+
<xsl:variable name="table_attributes">
|
1806
|
+
<attribute name="table-layout">fixed</attribute>
|
1807
|
+
<attribute name="width"><xsl:value-of select="normalize-space($table_width)"/></attribute>
|
1808
|
+
<attribute name="margin-left"><xsl:value-of select="$margin-left"/>mm</attribute>
|
1809
|
+
<attribute name="margin-right"><xsl:value-of select="$margin-left"/>mm</attribute>
|
1810
|
+
|
1811
|
+
|
1812
|
+
|
1813
|
+
|
1814
|
+
|
1815
|
+
|
1816
|
+
|
1817
|
+
<attribute name="border-top">0.5pt solid black</attribute>
|
1818
|
+
|
1819
|
+
|
1820
|
+
|
1821
|
+
|
1822
|
+
</xsl:variable>
|
1858
1823
|
|
1859
|
-
</fo:table>
|
1860
|
-
|
1861
|
-
<xsl:variable name="colgroup" select="*[local-name()='colgroup']"/>
|
1862
|
-
<xsl:for-each select="*[local-name()='tbody']"><!-- select context to tbody -->
|
1863
|
-
<xsl:call-template name="insertTableFooterInSeparateTable">
|
1864
|
-
<xsl:with-param name="table_attributes" select="$table_attributes"/>
|
1865
|
-
<xsl:with-param name="colwidths" select="$colwidths"/>
|
1866
|
-
<xsl:with-param name="colgroup" select="$colgroup"/>
|
1867
|
-
</xsl:call-template>
|
1868
|
-
</xsl:for-each>
|
1869
|
-
|
1870
|
-
<!-- insert footer as table -->
|
1871
|
-
<!-- <fo:table>
|
1872
|
-
<xsl:for-each select="xalan::nodeset($table_attributes)/attribute">
|
1873
|
-
<xsl:attribute name="{@name}">
|
1874
|
-
<xsl:value-of select="."/>
|
1875
|
-
</xsl:attribute>
|
1876
|
-
</xsl:for-each>
|
1877
1824
|
|
1878
|
-
<
|
1825
|
+
<fo:table id="{@id}" table-omit-footer-at-break="true">
|
1826
|
+
|
1827
|
+
<xsl:for-each select="xalan:nodeset($table_attributes)/attribute">
|
1828
|
+
<xsl:attribute name="{@name}">
|
1829
|
+
<xsl:value-of select="."/>
|
1830
|
+
</xsl:attribute>
|
1831
|
+
</xsl:for-each>
|
1832
|
+
|
1833
|
+
<xsl:variable name="isNoteOrFnExist" select="./*[local-name()='note'] or .//*[local-name()='fn'][local-name(..) != 'name']"/>
|
1834
|
+
<xsl:if test="$isNoteOrFnExist = 'true'">
|
1835
|
+
<xsl:attribute name="border-bottom">0pt solid black</xsl:attribute> <!-- set 0pt border, because there is a separete table below for footer -->
|
1836
|
+
</xsl:if>
|
1837
|
+
|
1838
|
+
<xsl:choose>
|
1839
|
+
<xsl:when test="*[local-name()='colgroup']/*[local-name()='col']">
|
1840
|
+
<xsl:for-each select="*[local-name()='colgroup']/*[local-name()='col']">
|
1841
|
+
<fo:table-column column-width="{@width}"/>
|
1842
|
+
</xsl:for-each>
|
1843
|
+
</xsl:when>
|
1844
|
+
<xsl:otherwise>
|
1845
|
+
<xsl:for-each select="xalan:nodeset($colwidths)//column">
|
1846
|
+
<xsl:choose>
|
1847
|
+
<xsl:when test=". = 1 or . = 0">
|
1848
|
+
<fo:table-column column-width="proportional-column-width(2)"/>
|
1849
|
+
</xsl:when>
|
1850
|
+
<xsl:otherwise>
|
1851
|
+
<fo:table-column column-width="proportional-column-width({.})"/>
|
1852
|
+
</xsl:otherwise>
|
1853
|
+
</xsl:choose>
|
1854
|
+
</xsl:for-each>
|
1855
|
+
</xsl:otherwise>
|
1856
|
+
</xsl:choose>
|
1857
|
+
|
1879
1858
|
<xsl:choose>
|
1880
|
-
<xsl:when test="
|
1881
|
-
<
|
1859
|
+
<xsl:when test="not(*[local-name()='tbody']) and *[local-name()='thead']">
|
1860
|
+
<xsl:apply-templates select="*[local-name()='thead']" mode="process_tbody"/>
|
1882
1861
|
</xsl:when>
|
1883
1862
|
<xsl:otherwise>
|
1884
|
-
<
|
1863
|
+
<xsl:apply-templates/>
|
1885
1864
|
</xsl:otherwise>
|
1886
1865
|
</xsl:choose>
|
1866
|
+
|
1867
|
+
</fo:table>
|
1868
|
+
|
1869
|
+
<xsl:variable name="colgroup" select="*[local-name()='colgroup']"/>
|
1870
|
+
<xsl:for-each select="*[local-name()='tbody']"><!-- select context to tbody -->
|
1871
|
+
<xsl:call-template name="insertTableFooterInSeparateTable">
|
1872
|
+
<xsl:with-param name="table_attributes" select="$table_attributes"/>
|
1873
|
+
<xsl:with-param name="colwidths" select="$colwidths"/>
|
1874
|
+
<xsl:with-param name="colgroup" select="$colgroup"/>
|
1875
|
+
</xsl:call-template>
|
1887
1876
|
</xsl:for-each>
|
1888
|
-
|
1889
|
-
|
1890
|
-
|
1891
|
-
|
1892
|
-
|
1893
|
-
|
1894
|
-
|
1877
|
+
|
1878
|
+
<!-- insert footer as table -->
|
1879
|
+
<!-- <fo:table>
|
1880
|
+
<xsl:for-each select="xalan::nodeset($table_attributes)/attribute">
|
1881
|
+
<xsl:attribute name="{@name}">
|
1882
|
+
<xsl:value-of select="."/>
|
1883
|
+
</xsl:attribute>
|
1884
|
+
</xsl:for-each>
|
1885
|
+
|
1886
|
+
<xsl:for-each select="xalan:nodeset($colwidths)//column">
|
1887
|
+
<xsl:choose>
|
1888
|
+
<xsl:when test=". = 1 or . = 0">
|
1889
|
+
<fo:table-column column-width="proportional-column-width(2)"/>
|
1890
|
+
</xsl:when>
|
1891
|
+
<xsl:otherwise>
|
1892
|
+
<fo:table-column column-width="proportional-column-width({.})"/>
|
1893
|
+
</xsl:otherwise>
|
1894
|
+
</xsl:choose>
|
1895
|
+
</xsl:for-each>
|
1896
|
+
</fo:table>-->
|
1897
|
+
|
1898
|
+
|
1899
|
+
|
1900
|
+
|
1901
|
+
|
1902
|
+
</fo:block-container>
|
1903
|
+
</xsl:variable>
|
1904
|
+
|
1905
|
+
|
1906
|
+
|
1907
|
+
<xsl:choose>
|
1908
|
+
<xsl:when test="@width">
|
1909
|
+
|
1910
|
+
<!-- centered table when table name is centered (see table-name-style) -->
|
1911
|
+
|
1912
|
+
|
1913
|
+
|
1914
|
+
<xsl:copy-of select="$table"/>
|
1915
|
+
|
1916
|
+
|
1917
|
+
</xsl:when>
|
1918
|
+
<xsl:otherwise>
|
1919
|
+
<xsl:copy-of select="$table"/>
|
1920
|
+
</xsl:otherwise>
|
1921
|
+
</xsl:choose>
|
1922
|
+
|
1895
1923
|
</xsl:template><xsl:template match="*[local-name()='table']/*[local-name() = 'name']"/><xsl:template match="*[local-name()='table']/*[local-name() = 'name']" mode="presentation">
|
1896
1924
|
<xsl:if test="normalize-space() != ''">
|
1897
1925
|
<fo:block xsl:use-attribute-sets="table-name-style">
|
@@ -2736,7 +2764,7 @@
|
|
2736
2764
|
<xsl:with-param name="table" select="$html-table"/>
|
2737
2765
|
</xsl:call-template>
|
2738
2766
|
</xsl:variable>
|
2739
|
-
<!-- colwidths=<xsl:
|
2767
|
+
<!-- colwidths=<xsl:copy-of select="$colwidths"/> -->
|
2740
2768
|
<xsl:variable name="maxlength_dt">
|
2741
2769
|
<xsl:call-template name="getMaxLength_dt"/>
|
2742
2770
|
</xsl:variable>
|
@@ -2765,13 +2793,22 @@
|
|
2765
2793
|
</xsl:when>
|
2766
2794
|
<xsl:otherwise>
|
2767
2795
|
<xsl:choose>
|
2796
|
+
<!-- to set width check most wide chars like `W` -->
|
2768
2797
|
<xsl:when test="normalize-space($maxlength_dt) != '' and number($maxlength_dt) <= 2"> <!-- if dt contains short text like t90, a, etc -->
|
2769
|
-
<fo:table-column column-width="
|
2770
|
-
<fo:table-column column-width="
|
2798
|
+
<fo:table-column column-width="7%"/>
|
2799
|
+
<fo:table-column column-width="93%"/>
|
2800
|
+
</xsl:when>
|
2801
|
+
<xsl:when test="normalize-space($maxlength_dt) != '' and number($maxlength_dt) <= 5"> <!-- if dt contains short text like ABC, etc -->
|
2802
|
+
<fo:table-column column-width="15%"/>
|
2803
|
+
<fo:table-column column-width="85%"/>
|
2804
|
+
</xsl:when>
|
2805
|
+
<xsl:when test="normalize-space($maxlength_dt) != '' and number($maxlength_dt) <= 7"> <!-- if dt contains short text like ABCDEF, etc -->
|
2806
|
+
<fo:table-column column-width="20%"/>
|
2807
|
+
<fo:table-column column-width="80%"/>
|
2771
2808
|
</xsl:when>
|
2772
|
-
<xsl:when test="normalize-space($maxlength_dt) != '' and number($maxlength_dt) <=
|
2773
|
-
<fo:table-column column-width="
|
2774
|
-
<fo:table-column column-width="
|
2809
|
+
<xsl:when test="normalize-space($maxlength_dt) != '' and number($maxlength_dt) <= 10"> <!-- if dt contains short text like ABCDEFEF, etc -->
|
2810
|
+
<fo:table-column column-width="25%"/>
|
2811
|
+
<fo:table-column column-width="75%"/>
|
2775
2812
|
</xsl:when>
|
2776
2813
|
<!-- <xsl:when test="xalan:nodeset($colwidths)/column[1] div xalan:nodeset($colwidths)/column[2] > 1.7">
|
2777
2814
|
<fo:table-column column-width="60%"/>
|
@@ -3078,6 +3115,10 @@
|
|
3078
3115
|
<xsl:param name="text" select="."/>
|
3079
3116
|
<!-- add zero-width space (#x200B) after characters: dash, dot, colon, equal, underscore, em dash, thin space -->
|
3080
3117
|
<xsl:value-of select="java:replaceAll(java:java.lang.String.new($text),'(-|\.|:|=|_|—| )','$1')"/>
|
3118
|
+
</xsl:template><xsl:template name="add-zero-spaces-link-java">
|
3119
|
+
<xsl:param name="text" select="."/>
|
3120
|
+
<!-- add zero-width space (#x200B) after characters: dash, dot, colon, equal, underscore, em dash, thin space -->
|
3121
|
+
<xsl:value-of select="java:replaceAll(java:java.lang.String.new($text),'(-|\.|:|=|_|—| |,)','$1')"/>
|
3081
3122
|
</xsl:template><xsl:template name="add-zero-spaces">
|
3082
3123
|
<xsl:param name="text" select="."/>
|
3083
3124
|
<xsl:variable name="zero-space-after-chars">-</xsl:variable>
|
@@ -3338,6 +3379,11 @@
|
|
3338
3379
|
<!-- replace start and end spaces to non-break space -->
|
3339
3380
|
<xsl:value-of select="java:replaceAll(java:java.lang.String.new(.),'(^ )|( $)',' ')"/>
|
3340
3381
|
</xsl:copy>
|
3382
|
+
</xsl:template><xsl:template match="mathml:mi[. = ',' and not(following-sibling::*[1][local-name() = 'mtext' and text() = ' '])]" mode="mathml">
|
3383
|
+
<xsl:copy>
|
3384
|
+
<xsl:apply-templates select="@*|node()" mode="mathml"/>
|
3385
|
+
</xsl:copy>
|
3386
|
+
<mathml:mspace width="0.5ex"/>
|
3341
3387
|
</xsl:template><xsl:template match="*[local-name()='localityStack']"/><xsl:template match="*[local-name()='link']" name="link">
|
3342
3388
|
<xsl:variable name="target">
|
3343
3389
|
<xsl:choose>
|
@@ -3359,7 +3405,10 @@
|
|
3359
3405
|
<fo:basic-link external-destination="{@target}" fox:alt-text="{@target}">
|
3360
3406
|
<xsl:choose>
|
3361
3407
|
<xsl:when test="normalize-space(.) = ''">
|
3362
|
-
<xsl:value-of select="$target"/>
|
3408
|
+
<!-- <xsl:value-of select="$target"/> -->
|
3409
|
+
<xsl:call-template name="add-zero-spaces-link-java">
|
3410
|
+
<xsl:with-param name="text" select="$target"/>
|
3411
|
+
</xsl:call-template>
|
3363
3412
|
</xsl:when>
|
3364
3413
|
<xsl:otherwise>
|
3365
3414
|
<xsl:apply-templates/>
|
@@ -3843,6 +3892,8 @@
|
|
3843
3892
|
<xsl:copy>
|
3844
3893
|
<xsl:apply-templates mode="contents_item"/>
|
3845
3894
|
</xsl:copy>
|
3895
|
+
</xsl:template><xsl:template match="*[local-name() = 'stem']" mode="contents_item">
|
3896
|
+
<xsl:copy-of select="."/>
|
3846
3897
|
</xsl:template><xsl:template match="*[local-name() = 'br']" mode="contents_item">
|
3847
3898
|
<xsl:text> </xsl:text>
|
3848
3899
|
</xsl:template><xsl:template match="*[local-name()='sourcecode']" name="sourcecode">
|
@@ -4241,11 +4292,13 @@
|
|
4241
4292
|
</xsl:if>
|
4242
4293
|
</xsl:if>
|
4243
4294
|
|
4295
|
+
|
4244
4296
|
<fo:block-container margin-left="0mm">
|
4245
4297
|
|
4246
4298
|
<fo:block xsl:use-attribute-sets="quote-style">
|
4247
4299
|
<!-- <xsl:apply-templates select=".//*[local-name() = 'p']"/> -->
|
4248
|
-
|
4300
|
+
|
4301
|
+
<xsl:apply-templates select="./node()[not(local-name() = 'author') and not(local-name() = 'source')]"/> <!-- process all nested nodes, except author and source -->
|
4249
4302
|
</fo:block>
|
4250
4303
|
<xsl:if test="*[local-name() = 'author'] or *[local-name() = 'source']">
|
4251
4304
|
<fo:block xsl:use-attribute-sets="quote-source-style">
|
@@ -4667,7 +4720,7 @@
|
|
4667
4720
|
<xsl:param name="charDelim" select="', '"/>
|
4668
4721
|
<xsl:choose>
|
4669
4722
|
<xsl:when test="$sorting = 'true' or $sorting = 'yes'">
|
4670
|
-
<xsl:for-each select="
|
4723
|
+
<xsl:for-each select="//*[contains(local-name(), '-standard')]/*[local-name() = 'bibdata']//*[local-name() = 'keyword']">
|
4671
4724
|
<xsl:sort data-type="text" order="ascending"/>
|
4672
4725
|
<xsl:call-template name="insertKeyword">
|
4673
4726
|
<xsl:with-param name="charAtEnd" select="$charAtEnd"/>
|
@@ -4676,7 +4729,7 @@
|
|
4676
4729
|
</xsl:for-each>
|
4677
4730
|
</xsl:when>
|
4678
4731
|
<xsl:otherwise>
|
4679
|
-
<xsl:for-each select="
|
4732
|
+
<xsl:for-each select="//*[contains(local-name(), '-standard')]/*[local-name() = 'bibdata']//*[local-name() = 'keyword']">
|
4680
4733
|
<xsl:call-template name="insertKeyword">
|
4681
4734
|
<xsl:with-param name="charAtEnd" select="$charAtEnd"/>
|
4682
4735
|
<xsl:with-param name="charDelim" select="$charDelim"/>
|
@@ -4693,6 +4746,9 @@
|
|
4693
4746
|
<xsl:otherwise><xsl:value-of select="$charAtEnd"/></xsl:otherwise>
|
4694
4747
|
</xsl:choose>
|
4695
4748
|
</xsl:template><xsl:template name="addPDFUAmeta">
|
4749
|
+
<xsl:variable name="lang">
|
4750
|
+
<xsl:call-template name="getLang"/>
|
4751
|
+
</xsl:variable>
|
4696
4752
|
<fo:declarations>
|
4697
4753
|
<pdf:catalog xmlns:pdf="http://xmlgraphics.apache.org/fop/extensions/pdf">
|
4698
4754
|
<pdf:dictionary type="normal" key="ViewerPreferences">
|
@@ -4705,13 +4761,16 @@
|
|
4705
4761
|
<!-- Dublin Core properties go here -->
|
4706
4762
|
<dc:title>
|
4707
4763
|
<xsl:variable name="title">
|
4708
|
-
|
4709
|
-
|
4710
|
-
|
4711
|
-
|
4712
|
-
|
4713
|
-
|
4714
|
-
|
4764
|
+
<xsl:for-each select="(//*[contains(local-name(), '-standard')])[1]/*[local-name() = 'bibdata']">
|
4765
|
+
|
4766
|
+
<xsl:value-of select="*[local-name() = 'title'][@language = $lang and @type = 'main']"/>
|
4767
|
+
|
4768
|
+
|
4769
|
+
|
4770
|
+
|
4771
|
+
|
4772
|
+
|
4773
|
+
</xsl:for-each>
|
4715
4774
|
</xsl:variable>
|
4716
4775
|
<xsl:choose>
|
4717
4776
|
<xsl:when test="normalize-space($title) != ''">
|
@@ -4723,17 +4782,21 @@
|
|
4723
4782
|
</xsl:choose>
|
4724
4783
|
</dc:title>
|
4725
4784
|
<dc:creator>
|
4726
|
-
|
4727
|
-
|
4728
|
-
|
4729
|
-
|
4730
|
-
|
4731
|
-
|
4785
|
+
<xsl:for-each select="(//*[contains(local-name(), '-standard')])[1]/*[local-name() = 'bibdata']">
|
4786
|
+
|
4787
|
+
<xsl:for-each select="*[local-name() = 'contributor'][*[local-name() = 'role']/@type='author']">
|
4788
|
+
<xsl:value-of select="*[local-name() = 'organization']/*[local-name() = 'name']"/>
|
4789
|
+
<xsl:if test="position() != last()">; </xsl:if>
|
4790
|
+
</xsl:for-each>
|
4732
4791
|
|
4733
4792
|
|
4734
4793
|
|
4735
|
-
|
4794
|
+
</xsl:for-each>
|
4795
|
+
</dc:creator>
|
4796
|
+
<dc:description>
|
4797
|
+
<xsl:variable name="abstract">
|
4736
4798
|
|
4799
|
+
<xsl:copy-of select="//*[contains(local-name(), '-standard')]/*[local-name() = 'preface']/*[local-name() = 'abstract']//text()"/>
|
4737
4800
|
|
4738
4801
|
|
4739
4802
|
</xsl:variable>
|