metanorma-ogc 1.2.8 → 1.2.13
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 +3 -0
- data/.rubocop.yml +0 -4
- data/lib/asciidoctor/ogc/basicdoc.rng +52 -3
- data/lib/asciidoctor/ogc/converter.rb +5 -6
- data/lib/asciidoctor/ogc/isodoc.rng +114 -3
- data/lib/isodoc/ogc/base_convert.rb +2 -2
- data/lib/isodoc/ogc/html_convert.rb +2 -2
- data/lib/isodoc/ogc/i18n-en.yaml +1 -1
- data/lib/isodoc/ogc/ogc.abstract-specification-topic.xsl +253 -49
- data/lib/isodoc/ogc/ogc.best-practice.xsl +253 -49
- data/lib/isodoc/ogc/ogc.change-request-supporting-document.xsl +253 -49
- data/lib/isodoc/ogc/ogc.community-practice.xsl +253 -49
- data/lib/isodoc/ogc/ogc.community-standard.xsl +253 -49
- data/lib/isodoc/ogc/ogc.discussion-paper.xsl +253 -49
- data/lib/isodoc/ogc/ogc.engineering-report.xsl +253 -49
- data/lib/isodoc/ogc/ogc.other.xsl +253 -49
- data/lib/isodoc/ogc/ogc.policy.xsl +253 -49
- data/lib/isodoc/ogc/ogc.reference-model.xsl +253 -49
- data/lib/isodoc/ogc/ogc.release-notes.xsl +253 -49
- data/lib/isodoc/ogc/ogc.standard.xsl +253 -49
- data/lib/isodoc/ogc/ogc.test-suite.xsl +253 -49
- data/lib/isodoc/ogc/ogc.user-guide.xsl +253 -49
- data/lib/isodoc/ogc/ogc.white-paper.xsl +246 -42
- data/lib/isodoc/ogc/word_convert.rb +7 -9
- data/lib/isodoc/ogc/xref.rb +8 -4
- data/lib/metanorma/ogc/processor.rb +16 -0
- data/lib/metanorma/ogc/version.rb +1 -1
- data/metanorma-ogc.gemspec +2 -2
- metadata +7 -8
- data/lib/metanorma/ogc/fonts_manifest.yaml +0 -6
@@ -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>
|
@@ -1449,7 +1451,7 @@
|
|
1449
1451
|
</xsl:template><xsl:template match="*[local-name()='td']//text() | *[local-name()='th']//text() | *[local-name()='dt']//text() | *[local-name()='dd']//text()" priority="1">
|
1450
1452
|
<!-- <xsl:call-template name="add-zero-spaces"/> -->
|
1451
1453
|
<xsl:call-template name="add-zero-spaces-java"/>
|
1452
|
-
</xsl:template><xsl:template match="*[local-name()='table']">
|
1454
|
+
</xsl:template><xsl:template match="*[local-name()='table']" name="table">
|
1453
1455
|
|
1454
1456
|
<xsl:variable name="simple-table">
|
1455
1457
|
<xsl:call-template name="getSimpleTable"/>
|
@@ -1493,10 +1495,12 @@
|
|
1493
1495
|
|
1494
1496
|
|
1495
1497
|
<xsl:variable name="colwidths">
|
1496
|
-
<xsl:
|
1497
|
-
<xsl:
|
1498
|
-
|
1499
|
-
|
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>
|
1500
1504
|
</xsl:variable>
|
1501
1505
|
<!-- colwidths=<xsl:copy-of select="$colwidths"/> -->
|
1502
1506
|
|
@@ -1541,7 +1545,12 @@
|
|
1541
1545
|
|
1542
1546
|
<xsl:variable name="table_attributes">
|
1543
1547
|
<attribute name="table-layout">fixed</attribute>
|
1544
|
-
<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>
|
1545
1554
|
<attribute name="margin-left"><xsl:value-of select="$margin-left"/>mm</attribute>
|
1546
1555
|
<attribute name="margin-right"><xsl:value-of select="$margin-left"/>mm</attribute>
|
1547
1556
|
|
@@ -1573,16 +1582,25 @@
|
|
1573
1582
|
<xsl:attribute name="border-bottom">0pt solid black</xsl:attribute> <!-- set 0pt border, because there is a separete table below for footer -->
|
1574
1583
|
</xsl:if>
|
1575
1584
|
|
1576
|
-
<xsl:
|
1577
|
-
<xsl:
|
1578
|
-
<xsl:
|
1579
|
-
<fo:table-column column-width="
|
1580
|
-
</xsl:
|
1581
|
-
|
1582
|
-
|
1583
|
-
|
1584
|
-
|
1585
|
-
|
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>
|
1586
1604
|
|
1587
1605
|
<xsl:choose>
|
1588
1606
|
<xsl:when test="not(*[local-name()='tbody']) and *[local-name()='thead']">
|
@@ -1595,10 +1613,12 @@
|
|
1595
1613
|
|
1596
1614
|
</fo:table>
|
1597
1615
|
|
1616
|
+
<xsl:variable name="colgroup" select="*[local-name()='colgroup']"/>
|
1598
1617
|
<xsl:for-each select="*[local-name()='tbody']"><!-- select context to tbody -->
|
1599
1618
|
<xsl:call-template name="insertTableFooterInSeparateTable">
|
1600
1619
|
<xsl:with-param name="table_attributes" select="$table_attributes"/>
|
1601
1620
|
<xsl:with-param name="colwidths" select="$colwidths"/>
|
1621
|
+
<xsl:with-param name="colgroup" select="$colgroup"/>
|
1602
1622
|
</xsl:call-template>
|
1603
1623
|
</xsl:for-each>
|
1604
1624
|
|
@@ -1854,12 +1874,22 @@
|
|
1854
1874
|
</xsl:template><xsl:template name="insertTableFooterInSeparateTable">
|
1855
1875
|
<xsl:param name="table_attributes"/>
|
1856
1876
|
<xsl:param name="colwidths"/>
|
1877
|
+
<xsl:param name="colgroup"/>
|
1857
1878
|
|
1858
1879
|
<xsl:variable name="isNoteOrFnExist" select="../*[local-name()='note'] or ..//*[local-name()='fn'][local-name(..) != 'name']"/>
|
1859
1880
|
|
1860
1881
|
<xsl:if test="$isNoteOrFnExist = 'true'">
|
1861
1882
|
|
1862
|
-
<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>
|
1863
1893
|
|
1864
1894
|
<fo:table keep-with-previous="always">
|
1865
1895
|
<xsl:for-each select="xalan:nodeset($table_attributes)/attribute">
|
@@ -1877,16 +1907,25 @@
|
|
1877
1907
|
</xsl:choose>
|
1878
1908
|
</xsl:for-each>
|
1879
1909
|
|
1880
|
-
<xsl:
|
1881
|
-
<xsl:
|
1882
|
-
<xsl:
|
1883
|
-
<fo:table-column column-width="
|
1884
|
-
</xsl:
|
1885
|
-
|
1886
|
-
|
1887
|
-
|
1888
|
-
|
1889
|
-
|
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>
|
1890
1929
|
|
1891
1930
|
<fo:table-body>
|
1892
1931
|
<fo:table-row>
|
@@ -2314,7 +2353,9 @@
|
|
2314
2353
|
</xsl:template><xsl:template match="*[local-name()='dl']">
|
2315
2354
|
<fo:block-container>
|
2316
2355
|
|
2317
|
-
<xsl:
|
2356
|
+
<xsl:if test="not(ancestor::*[local-name() = 'quote'])">
|
2357
|
+
<xsl:attribute name="margin-left">0mm</xsl:attribute>
|
2358
|
+
</xsl:if>
|
2318
2359
|
|
2319
2360
|
|
2320
2361
|
<xsl:if test="parent::*[local-name() = 'note']">
|
@@ -2329,6 +2370,7 @@
|
|
2329
2370
|
<fo:block-container>
|
2330
2371
|
|
2331
2372
|
<xsl:attribute name="margin-left">0mm</xsl:attribute>
|
2373
|
+
<xsl:attribute name="margin-right">0mm</xsl:attribute>
|
2332
2374
|
|
2333
2375
|
|
2334
2376
|
<xsl:variable name="parent" select="local-name(..)"/>
|
@@ -2512,12 +2554,32 @@
|
|
2512
2554
|
</xsl:otherwise>
|
2513
2555
|
</xsl:choose>
|
2514
2556
|
</xsl:template><xsl:template name="getMaxLength_dt">
|
2515
|
-
<xsl:
|
2516
|
-
<xsl:
|
2517
|
-
|
2518
|
-
<xsl:
|
2519
|
-
|
2520
|
-
|
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"/>
|
2521
2583
|
</xsl:template><xsl:template match="*[local-name()='dl']/*[local-name()='note']" priority="2">
|
2522
2584
|
<xsl:param name="key_iso"/>
|
2523
2585
|
|
@@ -2657,6 +2719,7 @@
|
|
2657
2719
|
|
2658
2720
|
|
2659
2721
|
|
2722
|
+
|
2660
2723
|
10
|
2661
2724
|
|
2662
2725
|
|
@@ -2672,6 +2735,10 @@
|
|
2672
2735
|
</xsl:if>
|
2673
2736
|
<xsl:apply-templates/>
|
2674
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>
|
2675
2742
|
</xsl:template><xsl:template match="*[local-name()='del']">
|
2676
2743
|
<fo:inline font-size="10pt" color="red" text-decoration="line-through">
|
2677
2744
|
<xsl:apply-templates/>
|
@@ -3254,7 +3321,7 @@
|
|
3254
3321
|
</xsl:if> -->
|
3255
3322
|
</fo:inline>
|
3256
3323
|
</xsl:if>
|
3257
|
-
</xsl:template><xsl:template match="*[local-name() = 'figure']">
|
3324
|
+
</xsl:template><xsl:template match="*[local-name() = 'figure']" name="figure">
|
3258
3325
|
<fo:block-container id="{@id}">
|
3259
3326
|
|
3260
3327
|
<fo:block>
|
@@ -3323,6 +3390,8 @@
|
|
3323
3390
|
<xsl:variable name="bookmark-title_">
|
3324
3391
|
<xsl:call-template name="getLangVersion">
|
3325
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"/>
|
3326
3395
|
</xsl:call-template>
|
3327
3396
|
</xsl:variable>
|
3328
3397
|
<xsl:choose>
|
@@ -3340,13 +3409,34 @@
|
|
3340
3409
|
</xsl:choose>
|
3341
3410
|
</fo:bookmark-title>
|
3342
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
|
+
|
3343
3422
|
</fo:bookmark>
|
3344
3423
|
|
3345
3424
|
</xsl:for-each>
|
3346
3425
|
</xsl:when>
|
3347
3426
|
<xsl:otherwise>
|
3348
3427
|
<xsl:for-each select="xalan:nodeset($contents)/doc">
|
3428
|
+
|
3349
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
|
+
|
3350
3440
|
</xsl:for-each>
|
3351
3441
|
</xsl:otherwise>
|
3352
3442
|
</xsl:choose>
|
@@ -3376,8 +3466,44 @@
|
|
3376
3466
|
|
3377
3467
|
</fo:bookmark-tree>
|
3378
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>
|
3379
3503
|
</xsl:template><xsl:template name="getLangVersion">
|
3380
3504
|
<xsl:param name="lang"/>
|
3505
|
+
<xsl:param name="doctype" select="''"/>
|
3506
|
+
<xsl:param name="title" select="''"/>
|
3381
3507
|
<xsl:choose>
|
3382
3508
|
<xsl:when test="$lang = 'en'">
|
3383
3509
|
|
@@ -3413,6 +3539,12 @@
|
|
3413
3539
|
<!-- <xsl:text> </xsl:text> -->
|
3414
3540
|
</xsl:template><xsl:template name="getSection">
|
3415
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
|
+
|
3416
3548
|
</xsl:template><xsl:template name="getName">
|
3417
3549
|
<xsl:choose>
|
3418
3550
|
<xsl:when test="*[local-name() = 'title']/*[local-name() = 'tab']">
|
@@ -3465,6 +3597,10 @@
|
|
3465
3597
|
<xsl:copy>
|
3466
3598
|
<xsl:apply-templates mode="contents_item"/>
|
3467
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>
|
3468
3604
|
</xsl:template><xsl:template match="*[local-name() = 'br']" mode="contents_item">
|
3469
3605
|
<xsl:text> </xsl:text>
|
3470
3606
|
</xsl:template><xsl:template match="*[local-name()='sourcecode']" name="sourcecode">
|
@@ -3490,6 +3626,7 @@
|
|
3490
3626
|
|
3491
3627
|
|
3492
3628
|
|
3629
|
+
|
3493
3630
|
|
3494
3631
|
|
3495
3632
|
|
@@ -3881,7 +4018,8 @@
|
|
3881
4018
|
<fo:block-container margin-left="0mm">
|
3882
4019
|
|
3883
4020
|
<fo:block xsl:use-attribute-sets="quote-style">
|
3884
|
-
<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 -->
|
3885
4023
|
</fo:block>
|
3886
4024
|
<xsl:if test="*[local-name() = 'author'] or *[local-name() = 'source']">
|
3887
4025
|
<fo:block xsl:use-attribute-sets="quote-source-style">
|
@@ -4039,6 +4177,7 @@
|
|
4039
4177
|
|
4040
4178
|
|
4041
4179
|
|
4180
|
+
|
4042
4181
|
|
4043
4182
|
|
4044
4183
|
|
@@ -4055,7 +4194,7 @@
|
|
4055
4194
|
|
4056
4195
|
|
4057
4196
|
|
4058
|
-
</xsl:template><xsl:template match="
|
4197
|
+
</xsl:template><xsl:template match="//*[contains(local-name(), '-standard')]/*[local-name() = 'preface']/*" priority="2"> <!-- /*/*[local-name() = 'preface']/* -->
|
4059
4198
|
<fo:block break-after="page"/>
|
4060
4199
|
<fo:block>
|
4061
4200
|
<xsl:call-template name="setId"/>
|
@@ -4063,7 +4202,8 @@
|
|
4063
4202
|
</fo:block>
|
4064
4203
|
</xsl:template><xsl:template match="*[local-name() = 'clause']">
|
4065
4204
|
<fo:block>
|
4066
|
-
<xsl:call-template name="setId"/>
|
4205
|
+
<xsl:call-template name="setId"/>
|
4206
|
+
|
4067
4207
|
|
4068
4208
|
<xsl:apply-templates/>
|
4069
4209
|
</fo:block>
|
@@ -4128,7 +4268,8 @@
|
|
4128
4268
|
<fo:table-column column-width="107mm"/>
|
4129
4269
|
<fo:table-column column-width="15mm"/>
|
4130
4270
|
<fo:table-body>
|
4131
|
-
<fo:table-row
|
4271
|
+
<fo:table-row text-align="center" font-weight="bold" background-color="black" color="white">
|
4272
|
+
|
4132
4273
|
<fo:table-cell border="1pt solid black"><fo:block>Date</fo:block></fo:table-cell>
|
4133
4274
|
<fo:table-cell border="1pt solid black"><fo:block>Type</fo:block></fo:table-cell>
|
4134
4275
|
<fo:table-cell border="1pt solid black"><fo:block>Change</fo:block></fo:table-cell>
|
@@ -4147,6 +4288,10 @@
|
|
4147
4288
|
</fo:table-cell>
|
4148
4289
|
</xsl:template><xsl:template name="processBibitem">
|
4149
4290
|
|
4291
|
+
|
4292
|
+
<!-- end BIPM bibitem processing-->
|
4293
|
+
|
4294
|
+
|
4150
4295
|
<!-- start OGC bibtem processing -->
|
4151
4296
|
<xsl:choose>
|
4152
4297
|
<xsl:when test="*[local-name() = 'formattedref']">
|
@@ -4344,6 +4489,8 @@
|
|
4344
4489
|
<xsl:value-of select="translate(.,'. ','')"/>
|
4345
4490
|
</xsl:template><xsl:template match="*[local-name() = 'name']/*[local-name() = 'forename']/text()" mode="strip">
|
4346
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>
|
4347
4494
|
</xsl:template><xsl:template name="convertDate">
|
4348
4495
|
<xsl:param name="date"/>
|
4349
4496
|
<xsl:param name="format" select="'short'"/>
|
@@ -4368,6 +4515,57 @@
|
|
4368
4515
|
</xsl:variable>
|
4369
4516
|
<xsl:variable name="result">
|
4370
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>
|
4371
4569
|
<xsl:when test="$format = 'short' or $day = ''">
|
4372
4570
|
<xsl:value-of select="normalize-space(concat($monthStr, ' ', $year))"/>
|
4373
4571
|
</xsl:when>
|
@@ -4562,6 +4760,7 @@
|
|
4562
4760
|
|
4563
4761
|
|
4564
4762
|
|
4763
|
+
|
4565
4764
|
</xsl:variable>
|
4566
4765
|
<xsl:if test="$documentNS != $XSLNS">
|
4567
4766
|
<xsl:message>[WARNING]: Document namespace: '<xsl:value-of select="$documentNS"/>' doesn't equal to xslt namespace '<xsl:value-of select="$XSLNS"/>'</xsl:message>
|
@@ -4621,6 +4820,11 @@
|
|
4621
4820
|
<xsl:call-template name="getLang"/>
|
4622
4821
|
</xsl:variable>
|
4623
4822
|
|
4624
|
-
<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>
|
4625
4829
|
|
4626
4830
|
</xsl:template></xsl:stylesheet>
|