metanorma-ogc 1.2.7 → 1.2.12
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/rake.yml +7 -5
- data/lib/asciidoctor/ogc/basicdoc.rng +52 -3
- data/lib/asciidoctor/ogc/converter.rb +0 -1
- data/lib/asciidoctor/ogc/isodoc.rng +51 -3
- data/lib/isodoc/ogc/base_convert.rb +2 -2
- data/lib/isodoc/ogc/html/htmlstyle.css +206 -206
- data/lib/isodoc/ogc/html/htmlstyle.scss +4 -4
- data/lib/isodoc/ogc/html/ogc.css +21 -21
- data/lib/isodoc/ogc/html/ogc.scss +21 -21
- data/lib/isodoc/ogc/html/ogc_wp.css +35 -35
- data/lib/isodoc/ogc/html/ogc_wp.scss +35 -35
- data/lib/isodoc/ogc/html/wordstyle.css +19 -19
- data/lib/isodoc/ogc/html/wordstyle.scss +19 -19
- data/lib/isodoc/ogc/html/wordstyle_wp.css +23 -23
- data/lib/isodoc/ogc/html/wordstyle_wp.scss +23 -23
- data/lib/isodoc/ogc/html_convert.rb +6 -3
- data/lib/isodoc/ogc/ogc.abstract-specification-topic.xsl +263 -55
- data/lib/isodoc/ogc/ogc.best-practice.xsl +263 -55
- data/lib/isodoc/ogc/ogc.change-request-supporting-document.xsl +263 -55
- data/lib/isodoc/ogc/ogc.community-practice.xsl +263 -55
- data/lib/isodoc/ogc/ogc.community-standard.xsl +263 -55
- data/lib/isodoc/ogc/ogc.discussion-paper.xsl +263 -55
- data/lib/isodoc/ogc/ogc.engineering-report.xsl +263 -55
- data/lib/isodoc/ogc/ogc.other.xsl +263 -55
- data/lib/isodoc/ogc/ogc.policy.xsl +263 -55
- data/lib/isodoc/ogc/ogc.reference-model.xsl +263 -55
- data/lib/isodoc/ogc/ogc.release-notes.xsl +263 -55
- data/lib/isodoc/ogc/ogc.standard.xsl +263 -55
- data/lib/isodoc/ogc/ogc.test-suite.xsl +263 -55
- data/lib/isodoc/ogc/ogc.user-guide.xsl +263 -55
- data/lib/isodoc/ogc/ogc.white-paper.xsl +255 -47
- data/lib/isodoc/ogc/presentation_xml_convert.rb +13 -0
- data/lib/isodoc/ogc/word_convert.rb +9 -5
- data/lib/isodoc/ogc/xref.rb +8 -4
- data/lib/metanorma/ogc.rb +7 -0
- data/lib/metanorma/ogc/processor.rb +16 -8
- data/lib/metanorma/ogc/version.rb +1 -1
- data/metanorma-ogc.gemspec +2 -2
- metadata +6 -6
@@ -91,7 +91,7 @@
|
|
91
91
|
|
92
92
|
<xsl:template match="/">
|
93
93
|
<xsl:call-template name="namespaceCheck"/>
|
94
|
-
<fo:root font-family="Arial, STIX Two Math,
|
94
|
+
<fo:root font-family="Arial, STIX Two Math, Source Han Sans" font-size="11pt" xml:lang="{$lang}">
|
95
95
|
<fo:layout-master-set>
|
96
96
|
|
97
97
|
<!-- Document pages -->
|
@@ -124,7 +124,7 @@
|
|
124
124
|
</fo:block-container>
|
125
125
|
</fo:block-container>
|
126
126
|
|
127
|
-
<fo:block font-family="Lato
|
127
|
+
<fo:block font-family="Lato" font-weight="300" font-size="14pt" font-style="italic" margin-top="6pt" color="rgb(21, 43, 77)">
|
128
128
|
<xsl:text>Additional context, inspirational quote, etc. fits into this subheading area</xsl:text>
|
129
129
|
</fo:block>
|
130
130
|
|
@@ -651,13 +651,13 @@
|
|
651
651
|
<xsl:otherwise> <!-- for ordered lists -->
|
652
652
|
<xsl:choose>
|
653
653
|
<xsl:when test="../@type = 'arabic'">
|
654
|
-
<xsl:number format="a)"/>
|
654
|
+
<xsl:number format="a)" lang="en"/>
|
655
655
|
</xsl:when>
|
656
656
|
<xsl:when test="../@type = 'alphabet'">
|
657
657
|
<xsl:number format="1)"/>
|
658
658
|
</xsl:when>
|
659
659
|
<xsl:when test="../@type = 'alphabet_upper'">
|
660
|
-
<xsl:number format="A)"/>
|
660
|
+
<xsl:number format="A)" lang="en"/>
|
661
661
|
</xsl:when>
|
662
662
|
|
663
663
|
<xsl:when test="../@type = 'roman'">
|
@@ -1291,6 +1291,7 @@
|
|
1291
1291
|
|
1292
1292
|
</xsl:attribute-set><xsl:attribute-set name="termnote-name-style">
|
1293
1293
|
|
1294
|
+
|
1294
1295
|
</xsl:attribute-set><xsl:attribute-set name="quote-style">
|
1295
1296
|
|
1296
1297
|
<xsl:attribute name="margin-top">12pt</xsl:attribute>
|
@@ -1302,6 +1303,7 @@
|
|
1302
1303
|
|
1303
1304
|
|
1304
1305
|
|
1306
|
+
|
1305
1307
|
</xsl:attribute-set><xsl:attribute-set name="quote-source-style">
|
1306
1308
|
|
1307
1309
|
<xsl:attribute name="text-align">right</xsl:attribute>
|
@@ -1328,6 +1330,7 @@
|
|
1328
1330
|
</xsl:attribute-set><xsl:attribute-set name="term-style">
|
1329
1331
|
|
1330
1332
|
</xsl:attribute-set><xsl:attribute-set name="figure-name-style">
|
1333
|
+
|
1331
1334
|
|
1332
1335
|
|
1333
1336
|
|
@@ -1448,7 +1451,7 @@
|
|
1448
1451
|
</xsl:template><xsl:template match="*[local-name()='td']//text() | *[local-name()='th']//text() | *[local-name()='dt']//text() | *[local-name()='dd']//text()" priority="1">
|
1449
1452
|
<!-- <xsl:call-template name="add-zero-spaces"/> -->
|
1450
1453
|
<xsl:call-template name="add-zero-spaces-java"/>
|
1451
|
-
</xsl:template><xsl:template match="*[local-name()='table']">
|
1454
|
+
</xsl:template><xsl:template match="*[local-name()='table']" name="table">
|
1452
1455
|
|
1453
1456
|
<xsl:variable name="simple-table">
|
1454
1457
|
<xsl:call-template name="getSimpleTable"/>
|
@@ -1492,10 +1495,12 @@
|
|
1492
1495
|
|
1493
1496
|
|
1494
1497
|
<xsl:variable name="colwidths">
|
1495
|
-
<xsl:
|
1496
|
-
<xsl:
|
1497
|
-
|
1498
|
-
|
1498
|
+
<xsl:if test="not(*[local-name()='colgroup']/*[local-name()='col'])">
|
1499
|
+
<xsl:call-template name="calculate-column-widths">
|
1500
|
+
<xsl:with-param name="cols-count" select="$cols-count"/>
|
1501
|
+
<xsl:with-param name="table" select="$simple-table"/>
|
1502
|
+
</xsl:call-template>
|
1503
|
+
</xsl:if>
|
1499
1504
|
</xsl:variable>
|
1500
1505
|
<!-- colwidths=<xsl:copy-of select="$colwidths"/> -->
|
1501
1506
|
|
@@ -1540,7 +1545,12 @@
|
|
1540
1545
|
|
1541
1546
|
<xsl:variable name="table_attributes">
|
1542
1547
|
<attribute name="table-layout">fixed</attribute>
|
1543
|
-
<attribute name="width">
|
1548
|
+
<attribute name="width">
|
1549
|
+
<xsl:choose>
|
1550
|
+
<xsl:when test="@width"><xsl:value-of select="@width"/></xsl:when>
|
1551
|
+
<xsl:otherwise>100%</xsl:otherwise>
|
1552
|
+
</xsl:choose>
|
1553
|
+
</attribute>
|
1544
1554
|
<attribute name="margin-left"><xsl:value-of select="$margin-left"/>mm</attribute>
|
1545
1555
|
<attribute name="margin-right"><xsl:value-of select="$margin-left"/>mm</attribute>
|
1546
1556
|
|
@@ -1572,16 +1582,25 @@
|
|
1572
1582
|
<xsl:attribute name="border-bottom">0pt solid black</xsl:attribute> <!-- set 0pt border, because there is a separete table below for footer -->
|
1573
1583
|
</xsl:if>
|
1574
1584
|
|
1575
|
-
<xsl:
|
1576
|
-
<xsl:
|
1577
|
-
<xsl:
|
1578
|
-
<fo:table-column column-width="
|
1579
|
-
</xsl:
|
1580
|
-
|
1581
|
-
|
1582
|
-
|
1583
|
-
|
1584
|
-
|
1585
|
+
<xsl:choose>
|
1586
|
+
<xsl:when test="*[local-name()='colgroup']/*[local-name()='col']">
|
1587
|
+
<xsl:for-each select="*[local-name()='colgroup']/*[local-name()='col']">
|
1588
|
+
<fo:table-column column-width="{@width}"/>
|
1589
|
+
</xsl:for-each>
|
1590
|
+
</xsl:when>
|
1591
|
+
<xsl:otherwise>
|
1592
|
+
<xsl:for-each select="xalan:nodeset($colwidths)//column">
|
1593
|
+
<xsl:choose>
|
1594
|
+
<xsl:when test=". = 1 or . = 0">
|
1595
|
+
<fo:table-column column-width="proportional-column-width(2)"/>
|
1596
|
+
</xsl:when>
|
1597
|
+
<xsl:otherwise>
|
1598
|
+
<fo:table-column column-width="proportional-column-width({.})"/>
|
1599
|
+
</xsl:otherwise>
|
1600
|
+
</xsl:choose>
|
1601
|
+
</xsl:for-each>
|
1602
|
+
</xsl:otherwise>
|
1603
|
+
</xsl:choose>
|
1585
1604
|
|
1586
1605
|
<xsl:choose>
|
1587
1606
|
<xsl:when test="not(*[local-name()='tbody']) and *[local-name()='thead']">
|
@@ -1594,10 +1613,12 @@
|
|
1594
1613
|
|
1595
1614
|
</fo:table>
|
1596
1615
|
|
1616
|
+
<xsl:variable name="colgroup" select="*[local-name()='colgroup']"/>
|
1597
1617
|
<xsl:for-each select="*[local-name()='tbody']"><!-- select context to tbody -->
|
1598
1618
|
<xsl:call-template name="insertTableFooterInSeparateTable">
|
1599
1619
|
<xsl:with-param name="table_attributes" select="$table_attributes"/>
|
1600
1620
|
<xsl:with-param name="colwidths" select="$colwidths"/>
|
1621
|
+
<xsl:with-param name="colgroup" select="$colgroup"/>
|
1601
1622
|
</xsl:call-template>
|
1602
1623
|
</xsl:for-each>
|
1603
1624
|
|
@@ -1853,12 +1874,22 @@
|
|
1853
1874
|
</xsl:template><xsl:template name="insertTableFooterInSeparateTable">
|
1854
1875
|
<xsl:param name="table_attributes"/>
|
1855
1876
|
<xsl:param name="colwidths"/>
|
1877
|
+
<xsl:param name="colgroup"/>
|
1856
1878
|
|
1857
1879
|
<xsl:variable name="isNoteOrFnExist" select="../*[local-name()='note'] or ..//*[local-name()='fn'][local-name(..) != 'name']"/>
|
1858
1880
|
|
1859
1881
|
<xsl:if test="$isNoteOrFnExist = 'true'">
|
1860
1882
|
|
1861
|
-
<xsl:variable name="cols-count"
|
1883
|
+
<xsl:variable name="cols-count">
|
1884
|
+
<xsl:choose>
|
1885
|
+
<xsl:when test="xalan:nodeset($colgroup)//*[local-name()='col']">
|
1886
|
+
<xsl:value-of select="count(xalan:nodeset($colgroup)//*[local-name()='col'])"/>
|
1887
|
+
</xsl:when>
|
1888
|
+
<xsl:otherwise>
|
1889
|
+
<xsl:value-of select="count(xalan:nodeset($colwidths)//column)"/>
|
1890
|
+
</xsl:otherwise>
|
1891
|
+
</xsl:choose>
|
1892
|
+
</xsl:variable>
|
1862
1893
|
|
1863
1894
|
<fo:table keep-with-previous="always">
|
1864
1895
|
<xsl:for-each select="xalan:nodeset($table_attributes)/attribute">
|
@@ -1876,16 +1907,25 @@
|
|
1876
1907
|
</xsl:choose>
|
1877
1908
|
</xsl:for-each>
|
1878
1909
|
|
1879
|
-
<xsl:
|
1880
|
-
<xsl:
|
1881
|
-
<xsl:
|
1882
|
-
<fo:table-column column-width="
|
1883
|
-
</xsl:
|
1884
|
-
|
1885
|
-
|
1886
|
-
|
1887
|
-
|
1888
|
-
|
1910
|
+
<xsl:choose>
|
1911
|
+
<xsl:when test="xalan:nodeset($colgroup)//*[local-name()='col']">
|
1912
|
+
<xsl:for-each select="xalan:nodeset($colgroup)//*[local-name()='col']">
|
1913
|
+
<fo:table-column column-width="{@width}"/>
|
1914
|
+
</xsl:for-each>
|
1915
|
+
</xsl:when>
|
1916
|
+
<xsl:otherwise>
|
1917
|
+
<xsl:for-each select="xalan:nodeset($colwidths)//column">
|
1918
|
+
<xsl:choose>
|
1919
|
+
<xsl:when test=". = 1 or . = 0">
|
1920
|
+
<fo:table-column column-width="proportional-column-width(2)"/>
|
1921
|
+
</xsl:when>
|
1922
|
+
<xsl:otherwise>
|
1923
|
+
<fo:table-column column-width="proportional-column-width({.})"/>
|
1924
|
+
</xsl:otherwise>
|
1925
|
+
</xsl:choose>
|
1926
|
+
</xsl:for-each>
|
1927
|
+
</xsl:otherwise>
|
1928
|
+
</xsl:choose>
|
1889
1929
|
|
1890
1930
|
<fo:table-body>
|
1891
1931
|
<fo:table-row>
|
@@ -2313,7 +2353,9 @@
|
|
2313
2353
|
</xsl:template><xsl:template match="*[local-name()='dl']">
|
2314
2354
|
<fo:block-container>
|
2315
2355
|
|
2316
|
-
<xsl:
|
2356
|
+
<xsl:if test="not(ancestor::*[local-name() = 'quote'])">
|
2357
|
+
<xsl:attribute name="margin-left">0mm</xsl:attribute>
|
2358
|
+
</xsl:if>
|
2317
2359
|
|
2318
2360
|
|
2319
2361
|
<xsl:if test="parent::*[local-name() = 'note']">
|
@@ -2328,6 +2370,7 @@
|
|
2328
2370
|
<fo:block-container>
|
2329
2371
|
|
2330
2372
|
<xsl:attribute name="margin-left">0mm</xsl:attribute>
|
2373
|
+
<xsl:attribute name="margin-right">0mm</xsl:attribute>
|
2331
2374
|
|
2332
2375
|
|
2333
2376
|
<xsl:variable name="parent" select="local-name(..)"/>
|
@@ -2511,12 +2554,32 @@
|
|
2511
2554
|
</xsl:otherwise>
|
2512
2555
|
</xsl:choose>
|
2513
2556
|
</xsl:template><xsl:template name="getMaxLength_dt">
|
2514
|
-
<xsl:
|
2515
|
-
<xsl:
|
2516
|
-
|
2517
|
-
<xsl:
|
2518
|
-
|
2519
|
-
|
2557
|
+
<xsl:variable name="lengths">
|
2558
|
+
<xsl:for-each select="*[local-name()='dt']">
|
2559
|
+
<xsl:variable name="maintext_length" select="string-length(normalize-space(.))"/>
|
2560
|
+
<xsl:variable name="attributes">
|
2561
|
+
<xsl:for-each select=".//@open"><xsl:value-of select="."/></xsl:for-each>
|
2562
|
+
<xsl:for-each select=".//@close"><xsl:value-of select="."/></xsl:for-each>
|
2563
|
+
</xsl:variable>
|
2564
|
+
<length><xsl:value-of select="string-length(normalize-space(.)) + string-length($attributes)"/></length>
|
2565
|
+
</xsl:for-each>
|
2566
|
+
</xsl:variable>
|
2567
|
+
<xsl:variable name="maxLength">
|
2568
|
+
<!-- <xsl:for-each select="*[local-name()='dt']">
|
2569
|
+
<xsl:sort select="string-length(normalize-space(.))" data-type="number" order="descending"/>
|
2570
|
+
<xsl:if test="position() = 1">
|
2571
|
+
<xsl:value-of select="string-length(normalize-space(.))"/>
|
2572
|
+
</xsl:if>
|
2573
|
+
</xsl:for-each> -->
|
2574
|
+
<xsl:for-each select="xalan:nodeset($lengths)/length">
|
2575
|
+
<xsl:sort select="." data-type="number" order="descending"/>
|
2576
|
+
<xsl:if test="position() = 1">
|
2577
|
+
<xsl:value-of select="."/>
|
2578
|
+
</xsl:if>
|
2579
|
+
</xsl:for-each>
|
2580
|
+
</xsl:variable>
|
2581
|
+
<!-- <xsl:message>DEBUG:<xsl:value-of select="$maxLength"/></xsl:message> -->
|
2582
|
+
<xsl:value-of select="$maxLength"/>
|
2520
2583
|
</xsl:template><xsl:template match="*[local-name()='dl']/*[local-name()='note']" priority="2">
|
2521
2584
|
<xsl:param name="key_iso"/>
|
2522
2585
|
|
@@ -2631,6 +2694,7 @@
|
|
2631
2694
|
</fo:inline>
|
2632
2695
|
</xsl:template><xsl:template match="*[local-name()='strong'] | *[local-name()='b']">
|
2633
2696
|
<fo:inline font-weight="bold">
|
2697
|
+
|
2634
2698
|
<xsl:apply-templates/>
|
2635
2699
|
</fo:inline>
|
2636
2700
|
</xsl:template><xsl:template match="*[local-name()='sup']">
|
@@ -2655,6 +2719,7 @@
|
|
2655
2719
|
|
2656
2720
|
|
2657
2721
|
|
2722
|
+
|
2658
2723
|
10
|
2659
2724
|
|
2660
2725
|
|
@@ -2670,6 +2735,10 @@
|
|
2670
2735
|
</xsl:if>
|
2671
2736
|
<xsl:apply-templates/>
|
2672
2737
|
</fo:inline>
|
2738
|
+
</xsl:template><xsl:template match="*[local-name()='underline']">
|
2739
|
+
<fo:inline text-decoration="underline">
|
2740
|
+
<xsl:apply-templates/>
|
2741
|
+
</fo:inline>
|
2673
2742
|
</xsl:template><xsl:template match="*[local-name()='del']">
|
2674
2743
|
<fo:inline font-size="10pt" color="red" text-decoration="line-through">
|
2675
2744
|
<xsl:apply-templates/>
|
@@ -3035,6 +3104,7 @@
|
|
3035
3104
|
</xsl:choose>
|
3036
3105
|
</xsl:variable>
|
3037
3106
|
<fo:inline xsl:use-attribute-sets="link-style">
|
3107
|
+
|
3038
3108
|
<xsl:choose>
|
3039
3109
|
<xsl:when test="$target = ''">
|
3040
3110
|
<xsl:apply-templates/>
|
@@ -3251,8 +3321,9 @@
|
|
3251
3321
|
</xsl:if> -->
|
3252
3322
|
</fo:inline>
|
3253
3323
|
</xsl:if>
|
3254
|
-
</xsl:template><xsl:template match="*[local-name() = 'figure']">
|
3255
|
-
<fo:block-container id="{@id}">
|
3324
|
+
</xsl:template><xsl:template match="*[local-name() = 'figure']" name="figure">
|
3325
|
+
<fo:block-container id="{@id}">
|
3326
|
+
|
3256
3327
|
<fo:block>
|
3257
3328
|
<xsl:apply-templates/>
|
3258
3329
|
</fo:block>
|
@@ -3303,7 +3374,7 @@
|
|
3303
3374
|
<xsl:apply-templates mode="bookmarks"/>
|
3304
3375
|
</xsl:template><xsl:template match="*[local-name() = 'stem']" mode="contents">
|
3305
3376
|
<xsl:apply-templates select="."/>
|
3306
|
-
</xsl:template><xsl:template match="*[local-name() = 'stem']" mode="bookmarks">
|
3377
|
+
</xsl:template><xsl:template match="*[local-name() = 'references'][@hidden='true']" mode="contents" priority="3"/><xsl:template match="*[local-name() = 'stem']" mode="bookmarks">
|
3307
3378
|
<xsl:apply-templates mode="bookmarks"/>
|
3308
3379
|
</xsl:template><xsl:template name="addBookmarks">
|
3309
3380
|
<xsl:param name="contents"/>
|
@@ -3319,6 +3390,8 @@
|
|
3319
3390
|
<xsl:variable name="bookmark-title_">
|
3320
3391
|
<xsl:call-template name="getLangVersion">
|
3321
3392
|
<xsl:with-param name="lang" select="@lang"/>
|
3393
|
+
<xsl:with-param name="doctype" select="@doctype"/>
|
3394
|
+
<xsl:with-param name="title" select="@title-part"/>
|
3322
3395
|
</xsl:call-template>
|
3323
3396
|
</xsl:variable>
|
3324
3397
|
<xsl:choose>
|
@@ -3336,13 +3409,34 @@
|
|
3336
3409
|
</xsl:choose>
|
3337
3410
|
</fo:bookmark-title>
|
3338
3411
|
<xsl:apply-templates select="contents/item" mode="bookmark"/>
|
3412
|
+
|
3413
|
+
<xsl:call-template name="insertFigureBookmarks">
|
3414
|
+
<xsl:with-param name="contents" select="contents"/>
|
3415
|
+
</xsl:call-template>
|
3416
|
+
|
3417
|
+
<xsl:call-template name="insertTableBookmarks">
|
3418
|
+
<xsl:with-param name="contents" select="contents"/>
|
3419
|
+
<xsl:with-param name="lang" select="@lang"/>
|
3420
|
+
</xsl:call-template>
|
3421
|
+
|
3339
3422
|
</fo:bookmark>
|
3340
3423
|
|
3341
3424
|
</xsl:for-each>
|
3342
3425
|
</xsl:when>
|
3343
3426
|
<xsl:otherwise>
|
3344
3427
|
<xsl:for-each select="xalan:nodeset($contents)/doc">
|
3428
|
+
|
3345
3429
|
<xsl:apply-templates select="contents/item" mode="bookmark"/>
|
3430
|
+
|
3431
|
+
<xsl:call-template name="insertFigureBookmarks">
|
3432
|
+
<xsl:with-param name="contents" select="contents"/>
|
3433
|
+
</xsl:call-template>
|
3434
|
+
|
3435
|
+
<xsl:call-template name="insertTableBookmarks">
|
3436
|
+
<xsl:with-param name="contents" select="contents"/>
|
3437
|
+
<xsl:with-param name="lang" select="@lang"/>
|
3438
|
+
</xsl:call-template>
|
3439
|
+
|
3346
3440
|
</xsl:for-each>
|
3347
3441
|
</xsl:otherwise>
|
3348
3442
|
</xsl:choose>
|
@@ -3372,8 +3466,44 @@
|
|
3372
3466
|
|
3373
3467
|
</fo:bookmark-tree>
|
3374
3468
|
</xsl:if>
|
3469
|
+
</xsl:template><xsl:template name="insertFigureBookmarks">
|
3470
|
+
<xsl:param name="contents"/>
|
3471
|
+
<xsl:if test="xalan:nodeset($contents)/figure">
|
3472
|
+
<fo:bookmark internal-destination="{xalan:nodeset($contents)/figure[1]/@id}" starting-state="hide">
|
3473
|
+
<fo:bookmark-title>Figures</fo:bookmark-title>
|
3474
|
+
<xsl:for-each select="xalan:nodeset($contents)/figure">
|
3475
|
+
<fo:bookmark internal-destination="{@id}">
|
3476
|
+
<fo:bookmark-title>
|
3477
|
+
<xsl:value-of select="normalize-space(title)"/>
|
3478
|
+
</fo:bookmark-title>
|
3479
|
+
</fo:bookmark>
|
3480
|
+
</xsl:for-each>
|
3481
|
+
</fo:bookmark>
|
3482
|
+
</xsl:if>
|
3483
|
+
</xsl:template><xsl:template name="insertTableBookmarks">
|
3484
|
+
<xsl:param name="contents"/>
|
3485
|
+
<xsl:param name="lang"/>
|
3486
|
+
<xsl:if test="xalan:nodeset($contents)/table">
|
3487
|
+
<fo:bookmark internal-destination="{xalan:nodeset($contents)/table[1]/@id}" starting-state="hide">
|
3488
|
+
<fo:bookmark-title>
|
3489
|
+
<xsl:choose>
|
3490
|
+
<xsl:when test="$lang = 'fr'">Tableaux</xsl:when>
|
3491
|
+
<xsl:otherwise>Tables</xsl:otherwise>
|
3492
|
+
</xsl:choose>
|
3493
|
+
</fo:bookmark-title>
|
3494
|
+
<xsl:for-each select="xalan:nodeset($contents)/table">
|
3495
|
+
<fo:bookmark internal-destination="{@id}">
|
3496
|
+
<fo:bookmark-title>
|
3497
|
+
<xsl:value-of select="normalize-space(title)"/>
|
3498
|
+
</fo:bookmark-title>
|
3499
|
+
</fo:bookmark>
|
3500
|
+
</xsl:for-each>
|
3501
|
+
</fo:bookmark>
|
3502
|
+
</xsl:if>
|
3375
3503
|
</xsl:template><xsl:template name="getLangVersion">
|
3376
3504
|
<xsl:param name="lang"/>
|
3505
|
+
<xsl:param name="doctype" select="''"/>
|
3506
|
+
<xsl:param name="title" select="''"/>
|
3377
3507
|
<xsl:choose>
|
3378
3508
|
<xsl:when test="$lang = 'en'">
|
3379
3509
|
|
@@ -3409,6 +3539,12 @@
|
|
3409
3539
|
<!-- <xsl:text> </xsl:text> -->
|
3410
3540
|
</xsl:template><xsl:template name="getSection">
|
3411
3541
|
<xsl:value-of select="*[local-name() = 'title']/*[local-name() = 'tab'][1]/preceding-sibling::node()"/>
|
3542
|
+
<!--
|
3543
|
+
<xsl:for-each select="*[local-name() = 'title']/*[local-name() = 'tab'][1]/preceding-sibling::node()">
|
3544
|
+
<xsl:value-of select="."/>
|
3545
|
+
</xsl:for-each>
|
3546
|
+
-->
|
3547
|
+
|
3412
3548
|
</xsl:template><xsl:template name="getName">
|
3413
3549
|
<xsl:choose>
|
3414
3550
|
<xsl:when test="*[local-name() = 'title']/*[local-name() = 'tab']">
|
@@ -3461,6 +3597,10 @@
|
|
3461
3597
|
<xsl:copy>
|
3462
3598
|
<xsl:apply-templates mode="contents_item"/>
|
3463
3599
|
</xsl:copy>
|
3600
|
+
</xsl:template><xsl:template match="*[local-name() = 'em']" mode="contents_item">
|
3601
|
+
<xsl:copy>
|
3602
|
+
<xsl:apply-templates mode="contents_item"/>
|
3603
|
+
</xsl:copy>
|
3464
3604
|
</xsl:template><xsl:template match="*[local-name() = 'br']" mode="contents_item">
|
3465
3605
|
<xsl:text> </xsl:text>
|
3466
3606
|
</xsl:template><xsl:template match="*[local-name()='sourcecode']" name="sourcecode">
|
@@ -3486,6 +3626,7 @@
|
|
3486
3626
|
|
3487
3627
|
|
3488
3628
|
|
3629
|
+
|
3489
3630
|
|
3490
3631
|
|
3491
3632
|
|
@@ -3877,7 +4018,8 @@
|
|
3877
4018
|
<fo:block-container margin-left="0mm">
|
3878
4019
|
|
3879
4020
|
<fo:block xsl:use-attribute-sets="quote-style">
|
3880
|
-
<xsl:apply-templates select=".//*[local-name() = 'p']"/>
|
4021
|
+
<!-- <xsl:apply-templates select=".//*[local-name() = 'p']"/> -->
|
4022
|
+
<xsl:apply-templates select="./*[not(local-name() = 'author') and not(local-name() = 'source')]"/> <!-- process all nested nodes, except author and source -->
|
3881
4023
|
</fo:block>
|
3882
4024
|
<xsl:if test="*[local-name() = 'author'] or *[local-name() = 'source']">
|
3883
4025
|
<fo:block xsl:use-attribute-sets="quote-source-style">
|
@@ -4035,6 +4177,7 @@
|
|
4035
4177
|
|
4036
4178
|
|
4037
4179
|
|
4180
|
+
|
4038
4181
|
|
4039
4182
|
|
4040
4183
|
|
@@ -4051,7 +4194,7 @@
|
|
4051
4194
|
|
4052
4195
|
|
4053
4196
|
|
4054
|
-
</xsl:template><xsl:template match="
|
4197
|
+
</xsl:template><xsl:template match="//*[contains(local-name(), '-standard')]/*[local-name() = 'preface']/*" priority="2"> <!-- /*/*[local-name() = 'preface']/* -->
|
4055
4198
|
<fo:block break-after="page"/>
|
4056
4199
|
<fo:block>
|
4057
4200
|
<xsl:call-template name="setId"/>
|
@@ -4059,7 +4202,8 @@
|
|
4059
4202
|
</fo:block>
|
4060
4203
|
</xsl:template><xsl:template match="*[local-name() = 'clause']">
|
4061
4204
|
<fo:block>
|
4062
|
-
<xsl:call-template name="setId"/>
|
4205
|
+
<xsl:call-template name="setId"/>
|
4206
|
+
|
4063
4207
|
|
4064
4208
|
<xsl:apply-templates/>
|
4065
4209
|
</fo:block>
|
@@ -4067,7 +4211,7 @@
|
|
4067
4211
|
<fo:block id="{@id}">
|
4068
4212
|
<xsl:apply-templates/>
|
4069
4213
|
</fo:block>
|
4070
|
-
</xsl:template><xsl:template match="/*/*[local-name() = 'bibliography']/*[local-name() = 'references'][@normative='true']">
|
4214
|
+
</xsl:template><xsl:template match="*[local-name() = 'references'][@hidden='true']" priority="3"/><xsl:template match="*[local-name() = 'bibitem'][@hidden='true']" priority="3"/><xsl:template match="/*/*[local-name() = 'bibliography']/*[local-name() = 'references'][@normative='true']">
|
4071
4215
|
|
4072
4216
|
<fo:block id="{@id}">
|
4073
4217
|
<xsl:apply-templates/>
|
@@ -4124,7 +4268,8 @@
|
|
4124
4268
|
<fo:table-column column-width="107mm"/>
|
4125
4269
|
<fo:table-column column-width="15mm"/>
|
4126
4270
|
<fo:table-body>
|
4127
|
-
<fo:table-row
|
4271
|
+
<fo:table-row text-align="center" font-weight="bold" background-color="black" color="white">
|
4272
|
+
|
4128
4273
|
<fo:table-cell border="1pt solid black"><fo:block>Date</fo:block></fo:table-cell>
|
4129
4274
|
<fo:table-cell border="1pt solid black"><fo:block>Type</fo:block></fo:table-cell>
|
4130
4275
|
<fo:table-cell border="1pt solid black"><fo:block>Change</fo:block></fo:table-cell>
|
@@ -4143,6 +4288,10 @@
|
|
4143
4288
|
</fo:table-cell>
|
4144
4289
|
</xsl:template><xsl:template name="processBibitem">
|
4145
4290
|
|
4291
|
+
|
4292
|
+
<!-- end BIPM bibitem processing-->
|
4293
|
+
|
4294
|
+
|
4146
4295
|
<!-- start OGC bibtem processing -->
|
4147
4296
|
<xsl:choose>
|
4148
4297
|
<xsl:when test="*[local-name() = 'formattedref']">
|
@@ -4340,6 +4489,8 @@
|
|
4340
4489
|
<xsl:value-of select="translate(.,'. ','')"/>
|
4341
4490
|
</xsl:template><xsl:template match="*[local-name() = 'name']/*[local-name() = 'forename']/text()" mode="strip">
|
4342
4491
|
<xsl:value-of select="substring(.,1,1)"/>
|
4492
|
+
</xsl:template><xsl:template match="*[local-name() = 'title']" mode="title">
|
4493
|
+
<fo:inline><xsl:apply-templates/></fo:inline>
|
4343
4494
|
</xsl:template><xsl:template name="convertDate">
|
4344
4495
|
<xsl:param name="date"/>
|
4345
4496
|
<xsl:param name="format" select="'short'"/>
|
@@ -4364,6 +4515,57 @@
|
|
4364
4515
|
</xsl:variable>
|
4365
4516
|
<xsl:variable name="result">
|
4366
4517
|
<xsl:choose>
|
4518
|
+
<xsl:when test="$format = 'ddMMyyyy'">
|
4519
|
+
<xsl:if test="$day != ''"><xsl:value-of select="number($day)"/></xsl:if>
|
4520
|
+
<xsl:text> </xsl:text>
|
4521
|
+
<xsl:value-of select="normalize-space(concat($monthStr, ' ' , $year))"/>
|
4522
|
+
</xsl:when>
|
4523
|
+
<xsl:when test="$format = 'ddMM'">
|
4524
|
+
<xsl:if test="$day != ''"><xsl:value-of select="number($day)"/></xsl:if>
|
4525
|
+
<xsl:text> </xsl:text><xsl:value-of select="$monthStr"/>
|
4526
|
+
</xsl:when>
|
4527
|
+
<xsl:when test="$format = 'short' or $day = ''">
|
4528
|
+
<xsl:value-of select="normalize-space(concat($monthStr, ' ', $year))"/>
|
4529
|
+
</xsl:when>
|
4530
|
+
<xsl:otherwise>
|
4531
|
+
<xsl:value-of select="normalize-space(concat($monthStr, ' ', $day, ', ' , $year))"/>
|
4532
|
+
</xsl:otherwise>
|
4533
|
+
</xsl:choose>
|
4534
|
+
</xsl:variable>
|
4535
|
+
<xsl:value-of select="$result"/>
|
4536
|
+
</xsl:template><xsl:template name="convertDateLocalized">
|
4537
|
+
<xsl:param name="date"/>
|
4538
|
+
<xsl:param name="format" select="'short'"/>
|
4539
|
+
<xsl:variable name="year" select="substring($date, 1, 4)"/>
|
4540
|
+
<xsl:variable name="month" select="substring($date, 6, 2)"/>
|
4541
|
+
<xsl:variable name="day" select="substring($date, 9, 2)"/>
|
4542
|
+
<xsl:variable name="monthStr">
|
4543
|
+
<xsl:choose>
|
4544
|
+
<xsl:when test="$month = '01'"><xsl:call-template name="getLocalizedString"><xsl:with-param name="key">month_january</xsl:with-param></xsl:call-template></xsl:when>
|
4545
|
+
<xsl:when test="$month = '02'"><xsl:call-template name="getLocalizedString"><xsl:with-param name="key">month_february</xsl:with-param></xsl:call-template></xsl:when>
|
4546
|
+
<xsl:when test="$month = '03'"><xsl:call-template name="getLocalizedString"><xsl:with-param name="key">month_march</xsl:with-param></xsl:call-template></xsl:when>
|
4547
|
+
<xsl:when test="$month = '04'"><xsl:call-template name="getLocalizedString"><xsl:with-param name="key">month_april</xsl:with-param></xsl:call-template></xsl:when>
|
4548
|
+
<xsl:when test="$month = '05'"><xsl:call-template name="getLocalizedString"><xsl:with-param name="key">month_may</xsl:with-param></xsl:call-template></xsl:when>
|
4549
|
+
<xsl:when test="$month = '06'"><xsl:call-template name="getLocalizedString"><xsl:with-param name="key">month_june</xsl:with-param></xsl:call-template></xsl:when>
|
4550
|
+
<xsl:when test="$month = '07'"><xsl:call-template name="getLocalizedString"><xsl:with-param name="key">month_july</xsl:with-param></xsl:call-template></xsl:when>
|
4551
|
+
<xsl:when test="$month = '08'"><xsl:call-template name="getLocalizedString"><xsl:with-param name="key">month_august</xsl:with-param></xsl:call-template></xsl:when>
|
4552
|
+
<xsl:when test="$month = '09'"><xsl:call-template name="getLocalizedString"><xsl:with-param name="key">month_september</xsl:with-param></xsl:call-template></xsl:when>
|
4553
|
+
<xsl:when test="$month = '10'"><xsl:call-template name="getLocalizedString"><xsl:with-param name="key">month_october</xsl:with-param></xsl:call-template></xsl:when>
|
4554
|
+
<xsl:when test="$month = '11'"><xsl:call-template name="getLocalizedString"><xsl:with-param name="key">month_november</xsl:with-param></xsl:call-template></xsl:when>
|
4555
|
+
<xsl:when test="$month = '12'"><xsl:call-template name="getLocalizedString"><xsl:with-param name="key">month_december</xsl:with-param></xsl:call-template></xsl:when>
|
4556
|
+
</xsl:choose>
|
4557
|
+
</xsl:variable>
|
4558
|
+
<xsl:variable name="result">
|
4559
|
+
<xsl:choose>
|
4560
|
+
<xsl:when test="$format = 'ddMMyyyy'">
|
4561
|
+
<xsl:if test="$day != ''"><xsl:value-of select="number($day)"/></xsl:if>
|
4562
|
+
<xsl:text> </xsl:text>
|
4563
|
+
<xsl:value-of select="normalize-space(concat($monthStr, ' ' , $year))"/>
|
4564
|
+
</xsl:when>
|
4565
|
+
<xsl:when test="$format = 'ddMM'">
|
4566
|
+
<xsl:if test="$day != ''"><xsl:value-of select="number($day)"/></xsl:if>
|
4567
|
+
<xsl:text> </xsl:text><xsl:value-of select="$monthStr"/>
|
4568
|
+
</xsl:when>
|
4367
4569
|
<xsl:when test="$format = 'short' or $day = ''">
|
4368
4570
|
<xsl:value-of select="normalize-space(concat($monthStr, ' ', $year))"/>
|
4369
4571
|
</xsl:when>
|
@@ -4558,6 +4760,7 @@
|
|
4558
4760
|
|
4559
4761
|
|
4560
4762
|
|
4763
|
+
|
4561
4764
|
</xsl:variable>
|
4562
4765
|
<xsl:if test="$documentNS != $XSLNS">
|
4563
4766
|
<xsl:message>[WARNING]: Document namespace: '<xsl:value-of select="$documentNS"/>' doesn't equal to xslt namespace '<xsl:value-of select="$XSLNS"/>'</xsl:message>
|
@@ -4617,6 +4820,11 @@
|
|
4617
4820
|
<xsl:call-template name="getLang"/>
|
4618
4821
|
</xsl:variable>
|
4619
4822
|
|
4620
|
-
<xsl:
|
4823
|
+
<xsl:choose>
|
4824
|
+
<xsl:when test="/*/*[local-name() = 'localized-strings']/*[local-name() = 'localized-string'][@key = $key and @language = $curr_lang]">
|
4825
|
+
<xsl:value-of select="/*/*[local-name() = 'localized-strings']/*[local-name() = 'localized-string'][@key = $key and @language = $curr_lang]"/>
|
4826
|
+
</xsl:when>
|
4827
|
+
<xsl:otherwise><xsl:value-of select="$key"/></xsl:otherwise>
|
4828
|
+
</xsl:choose>
|
4621
4829
|
|
4622
4830
|
</xsl:template></xsl:stylesheet>
|