metanorma-bipm 1.2.2 → 1.2.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 2f9652ed0417da543c2ac78f8b3c1f07523d3263955edd4ebb56ed7d6ad62acd
4
- data.tar.gz: 253e9177d7beb3a0607b486ea0be4a44551cb3b22804a2211f10906d2ddc063d
3
+ metadata.gz: 9b22db789ba7361ec7dc5d0c1da31726d0c76bfb48b15f0ff0d3fe4dc823c1a6
4
+ data.tar.gz: b37ed78f5b86b7712ec3b07847a379db481c8661c3a877634c0af0cd928da810
5
5
  SHA512:
6
- metadata.gz: c070212a333befb8e336548e30f914d2f8197bdda5691735fb51d0d589190dd3ea761f05de0b6acd809f3b31f7809e84232bf577238a400fa6e2d5a6c4b7a44b
7
- data.tar.gz: 3803393ec0101d70da575bfafa9af9a2aa3a5d56deea989561fd9d2f77d51b92cce0293f0cd49bf1863f347063438f9508efcf72e4e16a230b3b4a2676428672
6
+ metadata.gz: c110387336896dc5a738217756adb3b181ab5f8e734aaec1d38bbd45749b02df9436d7ff69d9e056470b9d68536949eb6ec0f4a61b6d19764ce351d8d0e77a76
7
+ data.tar.gz: bd044fa43de831b8ba85f4b49ac096ea487ea927693a89d074276511b730dcd978e2c8cf3922d680b8254a6ea6d5c04c239435cb222ef93eaa67e5fc93c1988c
@@ -58,7 +58,7 @@
58
58
  <attribute name="alt"/>
59
59
  </optional>
60
60
  <optional>
61
- <attribute name="updatetype">
61
+ <attribute name="update-type">
62
62
  <data type="boolean"/>
63
63
  </attribute>
64
64
  </optional>
@@ -1814,9 +1814,6 @@
1814
1814
  <optional>
1815
1815
  <ref name="termsubject"/>
1816
1816
  </optional>
1817
- <optional>
1818
- <ref name="termusage"/>
1819
- </optional>
1820
1817
  <oneOrMore>
1821
1818
  <ref name="termdefinition"/>
1822
1819
  </oneOrMore>
@@ -1880,17 +1877,37 @@
1880
1877
  </attribute>
1881
1878
  </optional>
1882
1879
  <optional>
1883
- <attribute name="geographicArea"/>
1880
+ <attribute name="geographic-area"/>
1884
1881
  </optional>
1885
1882
  <choice>
1886
1883
  <ref name="expression_designation"/>
1887
1884
  <ref name="letter_symbol_designation"/>
1888
1885
  <ref name="graphical_symbol_designation"/>
1889
1886
  </choice>
1887
+ <optional>
1888
+ <ref name="fieldofapplication"/>
1889
+ </optional>
1890
+ <optional>
1891
+ <ref name="usageinfo"/>
1892
+ </optional>
1890
1893
  <zeroOrMore>
1891
1894
  <ref name="termsource"/>
1892
1895
  </zeroOrMore>
1893
1896
  </define>
1897
+ <define name="fieldofapplication">
1898
+ <element name="field-of-application">
1899
+ <oneOrMore>
1900
+ <ref name="PureTextElement"/>
1901
+ </oneOrMore>
1902
+ </element>
1903
+ </define>
1904
+ <define name="usageinfo">
1905
+ <element name="usage-info">
1906
+ <oneOrMore>
1907
+ <ref name="PureTextElement"/>
1908
+ </oneOrMore>
1909
+ </element>
1910
+ </define>
1894
1911
  <define name="letter_symbol_designation">
1895
1912
  <element name="letter-symbol">
1896
1913
  <optional>
@@ -1946,7 +1963,7 @@
1946
1963
  </zeroOrMore>
1947
1964
  </element>
1948
1965
  <optional>
1949
- <element name="abbreviationType">
1966
+ <element name="abbreviation-type">
1950
1967
  <ref name="AbbreviationType"/>
1951
1968
  </element>
1952
1969
  </optional>
@@ -1956,7 +1973,7 @@
1956
1973
  </element>
1957
1974
  </optional>
1958
1975
  <optional>
1959
- <element name="grammarInfo">
1976
+ <element name="grammar-info">
1960
1977
  <ref name="Grammar"/>
1961
1978
  </element>
1962
1979
  </optional>
@@ -1983,6 +2000,11 @@
1983
2000
  <ref name="GrammarGender"/>
1984
2001
  </element>
1985
2002
  </zeroOrMore>
2003
+ <zeroOrMore>
2004
+ <element name="number">
2005
+ <ref name="GrammarNumber"/>
2006
+ </element>
2007
+ </zeroOrMore>
1986
2008
  <optional>
1987
2009
  <element name="isPreposition">
1988
2010
  <data type="boolean"/>
@@ -2014,7 +2036,7 @@
2014
2036
  </element>
2015
2037
  </optional>
2016
2038
  <zeroOrMore>
2017
- <element name="grammarvalue">
2039
+ <element name="grammar-value">
2018
2040
  <text/>
2019
2041
  </element>
2020
2042
  </zeroOrMore>
@@ -2027,6 +2049,13 @@
2027
2049
  <value>common</value>
2028
2050
  </choice>
2029
2051
  </define>
2052
+ <define name="GrammarNumber">
2053
+ <choice>
2054
+ <value>singular</value>
2055
+ <value>dual</value>
2056
+ <value>plural</value>
2057
+ </choice>
2058
+ </define>
2030
2059
  <define name="termdomain">
2031
2060
  <element name="domain">
2032
2061
  <oneOrMore>
@@ -2041,13 +2070,6 @@
2041
2070
  </oneOrMore>
2042
2071
  </element>
2043
2072
  </define>
2044
- <define name="termusage">
2045
- <element name="usageinfo">
2046
- <oneOrMore>
2047
- <ref name="BasicBlock"/>
2048
- </oneOrMore>
2049
- </element>
2050
- </define>
2051
2073
  <define name="termdefinition">
2052
2074
  <element name="definition">
2053
2075
  <choice>
@@ -2061,13 +2083,16 @@
2061
2083
  </element>
2062
2084
  </define>
2063
2085
  <define name="verbaldefinition">
2064
- <element name="verbaldefinition">
2086
+ <element name="verbal-definition">
2065
2087
  <oneOrMore>
2066
2088
  <choice>
2067
2089
  <ref name="paragraph"/>
2068
2090
  <ref name="dl"/>
2069
2091
  <ref name="ol"/>
2070
2092
  <ref name="ul"/>
2093
+ <ref name="table"/>
2094
+ <ref name="figure"/>
2095
+ <ref name="formula"/>
2071
2096
  </choice>
2072
2097
  </oneOrMore>
2073
2098
  <zeroOrMore>
@@ -2076,7 +2101,7 @@
2076
2101
  </element>
2077
2102
  </define>
2078
2103
  <define name="nonverbalrep">
2079
- <element name="nonverbalrepresentation">
2104
+ <element name="non-verbal-representation">
2080
2105
  <oneOrMore>
2081
2106
  <choice>
2082
2107
  <ref name="table"/>
@@ -8,7 +8,8 @@ module IsoDoc
8
8
  end
9
9
 
10
10
  def convert1(docxml, filename, dir)
11
- @jcgm = docxml&.at(ns("//bibdata/ext/editorialgroup/committee/@acronym"))&.value == "JCGM"
11
+ @jcgm = docxml&.at(ns("//bibdata/ext/editorialgroup/committee/"\
12
+ "@acronym"))&.value == "JCGM"
12
13
  super
13
14
  end
14
15
 
@@ -45,7 +46,7 @@ module IsoDoc
45
46
  identifiers = render_identifier(ids)
46
47
  if biblio then ref_entry_code(ref, ordinal, identifiers, ids)
47
48
  else
48
- ref << identifiers[0] || identifiers[1]
49
+ ref << (identifiers[0] || identifiers[1])
49
50
  ref << " #{identifiers[1]}" if identifiers[0] && identifiers[1]
50
51
  end
51
52
  ref << " " unless biblio && !identifiers[1]
@@ -58,7 +59,7 @@ module IsoDoc
58
59
  identifiers = render_identifier(bibitem_ref_code(bibitem))
59
60
  if biblio then ref_entry_code(ref, ordinal, identifiers, nil)
60
61
  else
61
- ref << identifiers[0] || identifiers[1]
62
+ ref << (identifiers[0] || identifiers[1])
62
63
  ref << " #{identifiers[1]}" if identifiers[0] && identifiers[1]
63
64
  end
64
65
  date_note_process(bibitem, ref)
@@ -247,33 +247,68 @@
247
247
  <xsl:template match="/">
248
248
  <fo:root xsl:use-attribute-sets="root-style" xml:lang="{$lang}">
249
249
  <fo:layout-master-set>
250
+
251
+ <!-- blank page -->
252
+ <fo:simple-page-master master-name="blankpage" page-width="{$pageWidth}mm" page-height="{$pageHeight}mm">
253
+ <fo:region-body margin-top="{$marginTop}mm" margin-bottom="{$marginBottom}mm" margin-left="{$marginLeftRight1}mm" margin-right="{$marginLeftRight2}mm"/>
254
+ <fo:region-before region-name="header-blank" extent="{$marginTop}mm"/>
255
+ <fo:region-after region-name="footer-blank" extent="{$marginBottom}mm"/>
256
+ <fo:region-start region-name="left-region" extent="17mm"/>
257
+ <fo:region-end region-name="right-region" extent="26.5mm"/>
258
+ </fo:simple-page-master>
259
+
250
260
  <!-- Cover page -->
251
- <fo:simple-page-master master-name="cover-page" page-width="{$pageWidth}mm" page-height="{$pageHeight}mm">
261
+ <fo:simple-page-master master-name="simple-cover-page" page-width="{$pageWidth}mm" page-height="{$pageHeight}mm">
252
262
  <fo:region-body margin-top="36mm" margin-bottom="43mm" margin-left="49mm" margin-right="48mm"/>
253
- <fo:region-before extent="36mm"/>
263
+ <fo:region-before region-name="header" extent="36mm"/>
254
264
  <fo:region-after extent="43mm"/>
255
265
  <fo:region-start extent="49mm"/>
256
266
  <fo:region-end extent="48mm"/>
257
267
  </fo:simple-page-master>
258
268
 
269
+ <fo:page-sequence-master master-name="cover-page">
270
+ <fo:repeatable-page-master-alternatives>
271
+ <fo:conditional-page-master-reference master-reference="blankpage" blank-or-not-blank="blank"/>
272
+ <fo:conditional-page-master-reference master-reference="simple-cover-page" odd-or-even="odd"/>
273
+ <fo:conditional-page-master-reference master-reference="simple-cover-page" odd-or-even="even"/>
274
+ </fo:repeatable-page-master-alternatives>
275
+ </fo:page-sequence-master>
276
+
259
277
  <!-- Cover page -->
260
- <fo:simple-page-master master-name="cover-page-appendix" page-width="{$pageWidth}mm" page-height="{$pageHeight}mm">
278
+ <fo:simple-page-master master-name="simple-cover-page-appendix" page-width="{$pageWidth}mm" page-height="{$pageHeight}mm">
261
279
  <fo:region-body margin-top="90mm" margin-bottom="40mm" margin-left="12.5mm" margin-right="53mm"/>
262
- <fo:region-before extent="60mm"/>
280
+ <fo:region-before region-name="header" extent="60mm"/>
263
281
  <fo:region-after extent="40mm"/>
264
282
  <fo:region-start extent="12.5mm"/>
265
283
  <fo:region-end extent="53mm"/>
266
284
  </fo:simple-page-master>
267
285
 
286
+ <fo:page-sequence-master master-name="cover-page-appendix">
287
+ <fo:repeatable-page-master-alternatives>
288
+ <fo:conditional-page-master-reference master-reference="blankpage" blank-or-not-blank="blank"/>
289
+ <fo:conditional-page-master-reference master-reference="simple-cover-page-appendix" odd-or-even="odd"/>
290
+ <fo:conditional-page-master-reference master-reference="simple-cover-page-appendix" odd-or-even="even"/>
291
+ </fo:repeatable-page-master-alternatives>
292
+ </fo:page-sequence-master>
293
+
294
+
268
295
  <!-- Title page -->
269
- <fo:simple-page-master master-name="title-page" page-width="{$pageWidth}mm" page-height="{$pageHeight}mm">
296
+ <fo:simple-page-master master-name="simple-title-page" page-width="{$pageWidth}mm" page-height="{$pageHeight}mm">
270
297
  <fo:region-body margin-top="38mm" margin-bottom="25mm" margin-left="95mm" margin-right="12mm"/>
271
- <fo:region-before extent="38mm"/>
298
+ <fo:region-before region-name="header" extent="38mm"/>
272
299
  <fo:region-after extent="25mm"/>
273
300
  <fo:region-start extent="95mm"/>
274
301
  <fo:region-end extent="12mm"/>
275
302
  </fo:simple-page-master>
276
303
 
304
+ <fo:page-sequence-master master-name="title-page">
305
+ <fo:repeatable-page-master-alternatives>
306
+ <fo:conditional-page-master-reference master-reference="blankpage" blank-or-not-blank="blank"/>
307
+ <fo:conditional-page-master-reference master-reference="simple-title-page" odd-or-even="odd"/>
308
+ <fo:conditional-page-master-reference master-reference="simple-title-page" odd-or-even="even"/>
309
+ </fo:repeatable-page-master-alternatives>
310
+ </fo:page-sequence-master>
311
+
277
312
  <!-- Document pages -->
278
313
  <fo:simple-page-master master-name="document-odd" page-width="{$pageWidth}mm" page-height="{$pageHeight}mm">
279
314
  <fo:region-body margin-top="{$marginTop}mm" margin-bottom="{$marginBottom}mm" margin-left="{$marginLeftRight1}mm" margin-right="{$marginLeftRight2}mm"/>
@@ -291,6 +326,7 @@
291
326
  </fo:simple-page-master>
292
327
  <fo:page-sequence-master master-name="document">
293
328
  <fo:repeatable-page-master-alternatives>
329
+ <fo:conditional-page-master-reference master-reference="blankpage" blank-or-not-blank="blank"/>
294
330
  <fo:conditional-page-master-reference odd-or-even="even" master-reference="document-even"/>
295
331
  <fo:conditional-page-master-reference odd-or-even="odd" master-reference="document-odd"/>
296
332
  </fo:repeatable-page-master-alternatives>
@@ -312,7 +348,8 @@
312
348
  <fo:region-end region-name="right-region" extent="26.5mm"/>
313
349
  </fo:simple-page-master>
314
350
  <fo:page-sequence-master master-name="document-landscape">
315
- <fo:repeatable-page-master-alternatives>
351
+ <fo:repeatable-page-master-alternatives>
352
+ <fo:conditional-page-master-reference master-reference="blankpage" blank-or-not-blank="blank"/>
316
353
  <fo:conditional-page-master-reference odd-or-even="even" master-reference="document-landscape-even"/>
317
354
  <fo:conditional-page-master-reference odd-or-even="odd" master-reference="document-landscape-odd"/>
318
355
  </fo:repeatable-page-master-alternatives>
@@ -334,7 +371,8 @@
334
371
  <fo:region-end region-name="right-region" extent="26.5mm"/>
335
372
  </fo:simple-page-master>
336
373
  <fo:page-sequence-master master-name="index">
337
- <fo:repeatable-page-master-alternatives>
374
+ <fo:repeatable-page-master-alternatives>
375
+ <fo:conditional-page-master-reference master-reference="blankpage" blank-or-not-blank="blank"/>
338
376
  <fo:conditional-page-master-reference odd-or-even="even" master-reference="index-even"/>
339
377
  <fo:conditional-page-master-reference odd-or-even="odd" master-reference="index-odd"/>
340
378
  </fo:repeatable-page-master-alternatives>
@@ -1106,6 +1144,9 @@
1106
1144
  </xsl:if>
1107
1145
 
1108
1146
  <xsl:call-template name="insertFootnoteSeparator"/>
1147
+
1148
+ <xsl:call-template name="insertHeaderDraftWatermark"/>
1149
+
1109
1150
  <fo:flow flow-name="xsl-region-body" font-family="Arial">
1110
1151
 
1111
1152
  <fo:block-container font-size="12pt" font-weight="bold" border-top="1pt solid black" width="82mm" margin-top="2mm" padding-top="2mm">
@@ -1303,7 +1344,9 @@
1303
1344
 
1304
1345
  <!-- Index -->
1305
1346
  <!-- <xsl:apply-templates select="xalan:nodeset($indexes)/doc[@id = $docid]//bipm:clause[@type = 'index']" mode="index" /> -->
1306
- <xsl:apply-templates select="xalan:nodeset($indexes)/doc[@id = $docid]//bipm:indexsect" mode="index"/>
1347
+ <xsl:apply-templates select="xalan:nodeset($indexes)/doc[@id = $docid]//bipm:indexsect" mode="index">
1348
+ <xsl:with-param name="isDraft" select="normalize-space(//bipm:bipm-standard/bipm:bibdata/bipm:version/bipm:draft or contains(//bipm:bipm-standard/bipm:bibdata/bipm:status/bipm:stage, 'draft') or contains(//bipm:bipm-standard/bipm:bibdata/bipm:status/bipm:stage, 'projet'))"/>
1349
+ </xsl:apply-templates>
1307
1350
 
1308
1351
  <!-- End Document Pages -->
1309
1352
 
@@ -1322,6 +1365,8 @@
1322
1365
 
1323
1366
  <fo:page-sequence master-reference="document" force-page-count="no-force">
1324
1367
 
1368
+ <xsl:call-template name="insertHeaderDraftWatermark"/>
1369
+
1325
1370
  <fo:flow flow-name="xsl-region-body" font-family="Arial">
1326
1371
 
1327
1372
  <fo:block-container font-size="12pt" font-weight="bold" border-top="1pt solid black" width="82mm" margin-top="2mm" padding-top="2mm">
@@ -1471,7 +1516,9 @@
1471
1516
 
1472
1517
  <!-- Index -->
1473
1518
  <!-- <xsl:apply-templates select="xalan:nodeset($indexes)/doc[@id = $docid]//bipm:clause[@type = 'index']" mode="index" /> -->
1474
- <xsl:apply-templates select="xalan:nodeset($indexes)/doc[@id = $docid]//bipm:indexsect" mode="index"/>
1519
+ <xsl:apply-templates select="xalan:nodeset($indexes)/doc[@id = $docid]//bipm:indexsect" mode="index">
1520
+ <xsl:with-param name="isDraft" select="normalize-space(//bipm:bipm-standard/bipm:bibdata/bipm:version/bipm:draft or contains(//bipm:bipm-standard/bipm:bibdata/bipm:status/bipm:stage, 'draft') or contains(//bipm:bipm-standard/bipm:bibdata/bipm:status/bipm:stage, 'projet'))"/>
1521
+ </xsl:apply-templates>
1475
1522
 
1476
1523
  </xsl:otherwise>
1477
1524
  </xsl:choose>
@@ -1485,6 +1532,8 @@
1485
1532
 
1486
1533
  <fo:page-sequence master-reference="cover-page" force-page-count="even">
1487
1534
 
1535
+ <xsl:call-template name="insertHeaderDraftWatermark"/>
1536
+
1488
1537
  <fo:flow flow-name="xsl-region-body">
1489
1538
 
1490
1539
  <xsl:call-template name="insertCoverPageCommon"/>
@@ -1820,6 +1869,8 @@
1820
1869
  </fo:block>
1821
1870
  </fo:block-container>
1822
1871
 
1872
+ <xsl:call-template name="insertDraftWatermark"/>
1873
+
1823
1874
  <!-- BIPM logo -->
1824
1875
  <fo:block-container absolute-position="fixed" left="12.8mm" top="12.2mm">
1825
1876
  <fo:block>
@@ -1844,6 +1895,8 @@
1844
1895
 
1845
1896
  <fo:page-sequence master-reference="title-page" format="1" initial-page-number="1" force-page-count="even">
1846
1897
 
1898
+ <xsl:call-template name="insertHeaderDraftWatermark"/>
1899
+
1847
1900
  <fo:flow flow-name="xsl-region-body" font-family="Arial">
1848
1901
 
1849
1902
  <xsl:variable name="languages">
@@ -3326,11 +3379,12 @@
3326
3379
 
3327
3380
  <xsl:template match="bipm:preferred">
3328
3381
  <fo:block font-weight="bold" keep-with-next="always" space-before="8pt" margin-bottom="6pt">
3382
+ <xsl:call-template name="setStyle_preferred"/>
3329
3383
  <xsl:if test="ancestor::bipm:term[1]/bipm:name">
3330
3384
  <xsl:variable name="level">
3331
3385
  <xsl:call-template name="getLevelTermName"/>
3332
3386
  </xsl:variable>
3333
- <fo:inline role="H{$level}">
3387
+ <fo:inline role="H{$level}" font-weight="bold">
3334
3388
  <xsl:attribute name="padding-right">2mm</xsl:attribute>
3335
3389
  <xsl:apply-templates select="ancestor::bipm:term[1]/bipm:name" mode="presentation"/>
3336
3390
  </fo:inline>
@@ -3908,7 +3962,11 @@
3908
3962
  <xsl:template name="insertHeaderFooter">
3909
3963
  <xsl:param name="header-title"/>
3910
3964
  <xsl:param name="orientation"/>
3965
+ <xsl:param name="isDraft"/>
3911
3966
  <fo:static-content flow-name="header-odd" role="artifact">
3967
+ <xsl:call-template name="insertDraftWatermark">
3968
+ <xsl:with-param name="isDraft" select="$isDraft"/>
3969
+ </xsl:call-template>
3912
3970
  <fo:block-container font-family="Arial" font-size="8pt" padding-top="12.5mm">
3913
3971
  <fo:block text-align="right">
3914
3972
  <xsl:copy-of select="$header-title"/>
@@ -3929,6 +3987,9 @@
3929
3987
  </fo:block-container>
3930
3988
  </fo:static-content>
3931
3989
  <fo:static-content flow-name="header-even" role="artifact">
3990
+ <xsl:call-template name="insertDraftWatermark">
3991
+ <xsl:with-param name="isDraft" select="$isDraft"/>
3992
+ </xsl:call-template>
3932
3993
  <fo:block-container font-family="Arial" font-size="8pt" padding-top="12.5mm">
3933
3994
  <fo:block>
3934
3995
  <fo:inline font-weight="bold"><fo:page-number/></fo:inline>
@@ -3944,7 +4005,74 @@
3944
4005
  <fo:block> </fo:block>
3945
4006
  </fo:block-container>
3946
4007
  </fo:block-container>
3947
- </fo:static-content>
4008
+ </fo:static-content>
4009
+ <fo:static-content flow-name="header-blank" role="artifact">
4010
+ <xsl:call-template name="insertDraftWatermark">
4011
+ <xsl:with-param name="isDraft" select="$isDraft"/>
4012
+ </xsl:call-template>
4013
+ <fo:block/>
4014
+ </fo:static-content>
4015
+ </xsl:template>
4016
+
4017
+ <xsl:template name="insertDraftWatermark">
4018
+ <xsl:param name="isDraft"/>
4019
+ <xsl:if test="$isDraft = 'true' or normalize-space(//bipm:bipm-standard/bipm:bibdata/bipm:version/bipm:draft or contains(//bipm:bipm-standard/bipm:bibdata/bipm:status/bipm:stage, 'draft') or contains(//bipm:bipm-standard/bipm:bibdata/bipm:status/bipm:stage, 'projet')) = 'true'">
4020
+ <!-- DRAFT -->
4021
+ <xsl:variable name="draft_label">
4022
+ <xsl:call-template name="getLocalizedString">
4023
+ <xsl:with-param name="key">draft_label</xsl:with-param>
4024
+ </xsl:call-template>
4025
+ </xsl:variable>
4026
+ <fo:block-container absolute-position="fixed" left="0mm" top="30mm">
4027
+ <fo:block line-height="0">
4028
+ <fo:instream-foreign-object fox:alt-text="DRAFT">
4029
+ <svg:svg xmlns:svg="http://www.w3.org/2000/svg" width="200mm" height="250mm">
4030
+ <svg:g transform="rotate(-45) scale(0.6, 1)">
4031
+ <xsl:variable name="font-size">
4032
+ <xsl:choose>
4033
+ <xsl:when test="string-length($draft_label) &gt; 5">150</xsl:when>
4034
+ <xsl:otherwise>260</xsl:otherwise>
4035
+ </xsl:choose>
4036
+ </xsl:variable>
4037
+ <svg:text x="-175mm" y="205mm" style="font-family:Arial;font-size:{$font-size}pt;font-weight:normal;fill:rgb(223, 223, 223);">
4038
+ <xsl:if test="string-length($draft_label) &gt; 5">
4039
+ <xsl:attribute name="x">-175mm</xsl:attribute>
4040
+ <xsl:attribute name="y">180mm</xsl:attribute>
4041
+ </xsl:if>
4042
+ <xsl:value-of select="java:toUpperCase(java:java.lang.String.new($draft_label))"/>
4043
+ </svg:text>
4044
+ </svg:g>
4045
+ </svg:svg>
4046
+ </fo:instream-foreign-object>
4047
+ </fo:block>
4048
+ </fo:block-container>
4049
+ </xsl:if>
4050
+ </xsl:template>
4051
+
4052
+ <xsl:template name="insertHeaderDraftWatermark">
4053
+ <xsl:variable name="isDraft" select="normalize-space(//bipm:bipm-standard/bipm:bibdata/bipm:version/bipm:draft or contains(//bipm:bipm-standard/bipm:bibdata/bipm:status/bipm:stage, 'draft') or contains(//bipm:bipm-standard/bipm:bibdata/bipm:status/bipm:stage, 'projet'))"/>
4054
+ <xsl:if test="$isDraft = 'true'">
4055
+ <fo:static-content flow-name="header-blank" role="artifact">
4056
+ <xsl:call-template name="insertDraftWatermark">
4057
+ <xsl:with-param name="isDraft" select="$isDraft"/>
4058
+ </xsl:call-template>
4059
+ </fo:static-content>
4060
+ <fo:static-content flow-name="header" role="artifact">
4061
+ <xsl:call-template name="insertDraftWatermark">
4062
+ <xsl:with-param name="isDraft" select="$isDraft"/>
4063
+ </xsl:call-template>
4064
+ </fo:static-content>
4065
+ <fo:static-content flow-name="header-odd" role="artifact">
4066
+ <xsl:call-template name="insertDraftWatermark">
4067
+ <xsl:with-param name="isDraft" select="$isDraft"/>
4068
+ </xsl:call-template>
4069
+ </fo:static-content>
4070
+ <fo:static-content flow-name="header-even" role="artifact">
4071
+ <xsl:call-template name="insertDraftWatermark">
4072
+ <xsl:with-param name="isDraft" select="$isDraft"/>
4073
+ </xsl:call-template>
4074
+ </fo:static-content>
4075
+ </xsl:if>
3948
4076
  </xsl:template>
3949
4077
 
3950
4078
  <!-- <xsl:template name="insertHeaderFooterAppendix">
@@ -4089,6 +4217,7 @@
4089
4217
  <!-- <xsl:template match="bipm:clause[@type = 'index']" mode="index"> -->
4090
4218
  <xsl:template match="bipm:indexsect"/>
4091
4219
  <xsl:template match="bipm:indexsect" mode="index">
4220
+ <xsl:param name="isDraft"/>
4092
4221
 
4093
4222
  <fo:page-sequence master-reference="index" force-page-count="no-force">
4094
4223
  <xsl:variable name="header-title">
@@ -4103,6 +4232,7 @@
4103
4232
  </xsl:variable>
4104
4233
  <xsl:call-template name="insertHeaderFooter">
4105
4234
  <xsl:with-param name="header-title" select="$header-title"/>
4235
+ <xsl:with-param name="isDraft" select="$isDraft"/>
4106
4236
  </xsl:call-template>
4107
4237
 
4108
4238
  <fo:flow flow-name="xsl-region-body">
@@ -5104,7 +5234,8 @@
5104
5234
  <xsl:apply-templates select="/*/*[local-name()='bibliography']/*[local-name()='references'][not(@normative='true')] | /*/*[local-name()='bibliography']/*[local-name()='clause'][*[local-name()='references'][not(@normative='true')]]" mode="contents"/>
5105
5235
 
5106
5236
  </xsl:template><xsl:template name="processMainSectionsDefault_Contents">
5107
- <xsl:for-each select="/*/*[local-name()='sections']/* | /*/*[local-name()='bibliography']/*[local-name()='references'][@normative='true']">
5237
+
5238
+ <xsl:for-each select="/*/*[local-name()='sections']/* | /*/*[local-name()='bibliography']/*[local-name()='references'][@normative='true'] | /*/*[local-name()='bibliography']/*[local-name()='clause'][*[local-name()='references'][@normative='true']]">
5108
5239
  <xsl:sort select="@displayorder" data-type="number"/>
5109
5240
  <xsl:apply-templates select="." mode="contents"/>
5110
5241
  </xsl:for-each>
@@ -5114,7 +5245,7 @@
5114
5245
  <xsl:apply-templates select="." mode="contents"/>
5115
5246
  </xsl:for-each>
5116
5247
 
5117
- <xsl:for-each select="/*/*[local-name()='bibliography']/*[not(@normative='true')] | /*/*[local-name()='bibliography']/*[local-name()='clause'][*[local-name()='references'][not(@normative='true')]]">
5248
+ <xsl:for-each select="/*/*[local-name()='bibliography']/*[not(@normative='true') and not(*[local-name()='references'][@normative='true'])] | /*/*[local-name()='bibliography']/*[local-name()='clause'][*[local-name()='references'][not(@normative='true')]]">
5118
5249
  <xsl:sort select="@displayorder" data-type="number"/>
5119
5250
  <xsl:apply-templates select="." mode="contents"/>
5120
5251
  </xsl:for-each>
@@ -7951,12 +8082,12 @@
7951
8082
  </xsl:template><xsl:template match="*[local-name() = 'emf']"/><xsl:template match="*[local-name() = 'figure']/*[local-name() = 'name']"/><xsl:template match="*[local-name() = 'figure']/*[local-name() = 'name'] | *[local-name() = 'table']/*[local-name() = 'name'] | *[local-name() = 'permission']/*[local-name() = 'name'] | *[local-name() = 'recommendation']/*[local-name() = 'name'] | *[local-name() = 'requirement']/*[local-name() = 'name']" mode="contents">
7952
8083
  <xsl:apply-templates mode="contents"/>
7953
8084
  <xsl:text> </xsl:text>
7954
- </xsl:template><xsl:template match="*[local-name() = 'figure']/*[local-name() = 'name'] | *[local-name() = 'table']/*[local-name() = 'name'] | *[local-name() = 'permission']/*[local-name() = 'name'] | *[local-name() = 'recommendation']/*[local-name() = 'name'] | *[local-name() = 'requirement']/*[local-name() = 'name']" mode="bookmarks">
8085
+ </xsl:template><xsl:template match="*[local-name() = 'figure']/*[local-name() = 'name'] | *[local-name() = 'table']/*[local-name() = 'name'] | *[local-name() = 'permission']/*[local-name() = 'name'] | *[local-name() = 'recommendation']/*[local-name() = 'name'] | *[local-name() = 'requirement']/*[local-name() = 'name'] | *[local-name() = 'sourcecode']/*[local-name() = 'name']" mode="bookmarks">
7955
8086
  <xsl:apply-templates mode="bookmarks"/>
7956
8087
  <xsl:text> </xsl:text>
7957
8088
  </xsl:template><xsl:template match="*[local-name() = 'figure' or local-name() = 'table' or local-name() = 'permission' or local-name() = 'recommendation' or local-name() = 'requirement']/*[local-name() = 'name']/text()" mode="contents" priority="2">
7958
8089
  <xsl:value-of select="."/>
7959
- </xsl:template><xsl:template match="*[local-name() = 'figure' or local-name() = 'table' or local-name() = 'permission' or local-name() = 'recommendation' or local-name() = 'requirement']/*[local-name() = 'name']//text()" mode="bookmarks" priority="2">
8090
+ </xsl:template><xsl:template match="*[local-name() = 'figure' or local-name() = 'table' or local-name() = 'permission' or local-name() = 'recommendation' or local-name() = 'requirement' or local-name() = 'sourcecode']/*[local-name() = 'name']//text()" mode="bookmarks" priority="2">
7960
8091
  <xsl:value-of select="."/>
7961
8092
  </xsl:template><xsl:template match="node()" mode="contents">
7962
8093
  <xsl:apply-templates mode="contents"/>
@@ -8240,6 +8371,8 @@
8240
8371
 
8241
8372
 
8242
8373
 
8374
+
8375
+
8243
8376
  <fo:block xsl:use-attribute-sets="sourcecode-style">
8244
8377
  <xsl:variable name="_font-size">
8245
8378
 
@@ -8273,13 +8406,17 @@
8273
8406
 
8274
8407
 
8275
8408
 
8409
+
8410
+
8276
8411
  <xsl:apply-templates/>
8277
8412
  </fo:block>
8278
-
8413
+
8279
8414
 
8280
8415
  <xsl:apply-templates select="*[local-name()='name']" mode="presentation"/>
8281
8416
 
8282
8417
 
8418
+
8419
+
8283
8420
  </fo:block-container>
8284
8421
  </fo:block-container>
8285
8422
  </xsl:template><xsl:template match="*[local-name()='sourcecode']/text()" priority="2">
@@ -8870,24 +9007,29 @@
8870
9007
  </xsl:template><xsl:template match="*[local-name() = 'deprecates']">
8871
9008
  <xsl:variable name="title-deprecated">
8872
9009
 
8873
-
8874
- <xsl:call-template name="getTitle">
8875
- <xsl:with-param name="name" select="'title-deprecated'"/>
9010
+ <xsl:call-template name="getLocalizedString">
9011
+ <xsl:with-param name="key">deprecated</xsl:with-param>
8876
9012
  </xsl:call-template>
8877
9013
 
9014
+
8878
9015
  </xsl:variable>
8879
9016
  <fo:block xsl:use-attribute-sets="deprecates-style">
8880
9017
  <xsl:value-of select="$title-deprecated"/>: <xsl:apply-templates/>
8881
9018
  </fo:block>
9019
+ </xsl:template><xsl:template name="setStyle_preferred">
9020
+ <xsl:if test="*[local-name() = 'strong']">
9021
+ <xsl:attribute name="font-weight">normal</xsl:attribute>
9022
+ </xsl:if>
8882
9023
  </xsl:template><xsl:template match="*[local-name() = 'definition']">
8883
9024
  <fo:block xsl:use-attribute-sets="definition-style">
8884
9025
  <xsl:apply-templates/>
8885
9026
  </fo:block>
8886
9027
  </xsl:template><xsl:template match="*[local-name() = 'definition'][preceding-sibling::*[local-name() = 'domain']]">
8887
9028
  <xsl:apply-templates/>
8888
- </xsl:template><xsl:template match="*[local-name() = 'definition'][preceding-sibling::*[local-name() = 'domain']]/*[local-name() = 'p']">
9029
+ </xsl:template><xsl:template match="*[local-name() = 'definition'][preceding-sibling::*[local-name() = 'domain']]/*[local-name() = 'p'][1]">
8889
9030
  <fo:inline> <xsl:apply-templates/></fo:inline>
8890
- <fo:block> </fo:block>
9031
+ <!-- <fo:block>&#xA0;</fo:block> -->
9032
+ <fo:block/>
8891
9033
  </xsl:template><xsl:template match="/*/*[local-name() = 'sections']/*" priority="2">
8892
9034
 
8893
9035
  <fo:block>