metanorma-bipm 2.4.4 → 2.4.6

Sign up to get free protection for your applications and to get access to all the features.
@@ -1744,17 +1744,30 @@
1744
1744
  <xsl:param name="add_math_as_text">true</xsl:param> <!-- add math in text behind svg formula, to copy-paste formula from PDF as text -->
1745
1745
 
1746
1746
  <xsl:param name="table_if">false</xsl:param> <!-- generate extended table in IF for autolayout-algorithm -->
1747
- <xsl:param name="table_widths"/> <!-- path to xml with table's widths, generated on 1st pass, based on FOP Intermediate Format -->
1747
+ <xsl:param name="table_widths"/> <!-- (debug: path to) xml with table's widths, generated on 1st pass, based on FOP Intermediate Format -->
1748
1748
  <!-- Example: <tables>
1749
- <table id="table_if_tab-symdu" page-width="75"> - table id prefixed by 'table_if_' to simple search in IF
1750
- <tbody>
1751
- <tr>
1752
- <td id="tab-symdu_1_1">
1753
- <p_len>6</p_len>
1754
- <p_len>100</p_len> for 2nd paragraph
1755
- <word_len>6</word_len>
1756
- <word_len>20</word_len>
1757
- ...
1749
+ <table page-width="509103" id="table1" width_max="223561" width_min="223560">
1750
+ <column width_max="39354" width_min="39354"/>
1751
+ <column width_max="75394" width_min="75394"/>
1752
+ <column width_max="108813" width_min="108813"/>
1753
+ <tbody>
1754
+ <tr>
1755
+ <td width_max="39354" width_min="39354">
1756
+ <p_len>39354</p_len>
1757
+ <word_len>39354</word_len>
1758
+ </td>
1759
+
1760
+ OLD:
1761
+ <tables>
1762
+ <table id="table_if_tab-symdu" page-width="75"> - table id prefixed by 'table_if_' to simple search in IF
1763
+ <tbody>
1764
+ <tr>
1765
+ <td id="tab-symdu_1_1">
1766
+ <p_len>6</p_len>
1767
+ <p_len>100</p_len> for 2nd paragraph
1768
+ <word_len>6</word_len>
1769
+ <word_len>20</word_len>
1770
+ ...
1758
1771
  -->
1759
1772
 
1760
1773
  <!-- for command line debug: <xsl:variable name="table_widths_from_if" select="document($table_widths)"/> -->
@@ -1973,6 +1986,10 @@
1973
1986
  <xsl:variable name="zero_width_space">​</xsl:variable>
1974
1987
  <xsl:variable name="hair_space"> </xsl:variable>
1975
1988
  <xsl:variable name="en_dash">–</xsl:variable>
1989
+ <xsl:variable name="em_dash">—</xsl:variable>
1990
+ <xsl:variable name="cr">&#13;</xsl:variable>
1991
+ <xsl:variable name="lf">
1992
+ </xsl:variable>
1976
1993
 
1977
1994
  <xsl:template name="getTitle">
1978
1995
  <xsl:param name="name"/>
@@ -2288,6 +2305,10 @@
2288
2305
 
2289
2306
  </xsl:attribute-set> <!-- example-name-style -->
2290
2307
 
2308
+ <xsl:template name="refine_example-name-style">
2309
+
2310
+ </xsl:template>
2311
+
2291
2312
  <xsl:attribute-set name="example-p-style">
2292
2313
 
2293
2314
  <xsl:attribute name="font-size">10pt</xsl:attribute>
@@ -2306,6 +2327,10 @@
2306
2327
 
2307
2328
  </xsl:attribute-set> <!-- termexample-name-style -->
2308
2329
 
2330
+ <xsl:template name="refine_termexample-name-style">
2331
+
2332
+ </xsl:template>
2333
+
2309
2334
  <!-- ========================== -->
2310
2335
  <!-- Table styles -->
2311
2336
  <!-- ========================== -->
@@ -2508,6 +2533,10 @@
2508
2533
 
2509
2534
  </xsl:attribute-set> <!-- table-fn-style -->
2510
2535
 
2536
+ <xsl:template name="refine_table-fn-style">
2537
+
2538
+ </xsl:template>
2539
+
2511
2540
  <xsl:attribute-set name="table-fn-number-style">
2512
2541
  <xsl:attribute name="font-size">80%</xsl:attribute>
2513
2542
  <xsl:attribute name="padding-right">5mm</xsl:attribute>
@@ -2516,6 +2545,10 @@
2516
2545
 
2517
2546
  </xsl:attribute-set> <!-- table-fn-number-style -->
2518
2547
 
2548
+ <xsl:template name="refine_table-fn-number-style">
2549
+
2550
+ </xsl:template>
2551
+
2519
2552
  <xsl:attribute-set name="fn-container-body-style">
2520
2553
  <xsl:attribute name="text-indent">0</xsl:attribute>
2521
2554
  <xsl:attribute name="start-indent">0</xsl:attribute>
@@ -3651,6 +3684,20 @@
3651
3684
  </xsl:for-each>
3652
3685
  </xsl:template>
3653
3686
 
3687
+ <xsl:param name="table_only_with_id"/><!-- Example: table1, for table auto-layout algorithm -->
3688
+
3689
+ <xsl:template match="*[local-name()='table']" priority="2">
3690
+ <xsl:choose>
3691
+ <xsl:when test="$table_only_with_id != '' and @id = $table_only_with_id">
3692
+ <xsl:call-template name="table"/>
3693
+ </xsl:when>
3694
+ <xsl:when test="$table_only_with_id != ''"><fo:block/><!-- to prevent empty fo:block-container --></xsl:when>
3695
+ <xsl:otherwise>
3696
+ <xsl:call-template name="table"/>
3697
+ </xsl:otherwise>
3698
+ </xsl:choose>
3699
+ </xsl:template>
3700
+
3654
3701
  <xsl:template match="*[local-name()='table']" name="table">
3655
3702
 
3656
3703
  <xsl:variable name="table-preamble">
@@ -3660,9 +3707,11 @@
3660
3707
  <xsl:variable name="table">
3661
3708
 
3662
3709
  <xsl:variable name="simple-table">
3663
- <xsl:call-template name="getSimpleTable">
3664
- <xsl:with-param name="id" select="@id"/>
3665
- </xsl:call-template>
3710
+ <xsl:if test="$isGenerateTableIF = 'true' and $isApplyAutolayoutAlgorithm = 'true'">
3711
+ <xsl:call-template name="getSimpleTable">
3712
+ <xsl:with-param name="id" select="@id"/>
3713
+ </xsl:call-template>
3714
+ </xsl:if>
3666
3715
  </xsl:variable>
3667
3716
  <!-- <xsl:variable name="simple-table" select="xalan:nodeset($simple-table_)"/> -->
3668
3717
 
@@ -3754,9 +3803,9 @@
3754
3803
  </xsl:attribute>
3755
3804
  </xsl:for-each>
3756
3805
 
3757
- <xsl:variable name="isNoteOrFnExist" select="./*[local-name()='note'] or ./*[local-name()='example'] or .//*[local-name()='fn'][local-name(..) != 'name'] or ./*[local-name()='source']"/>
3806
+ <xsl:variable name="isNoteOrFnExist" select="./*[local-name()='note'][not(@type = 'units')] or ./*[local-name()='example'] or .//*[local-name()='fn'][local-name(..) != 'name'] or ./*[local-name()='source']"/>
3758
3807
  <xsl:if test="$isNoteOrFnExist = 'true'">
3759
- <xsl:attribute name="border-bottom">0pt solid black</xsl:attribute> <!-- set 0pt border, because there is a separete table below for footer -->
3808
+ <xsl:attribute name="border-bottom">0pt solid black</xsl:attribute><!-- set 0pt border, because there is a separete table below for footer -->
3760
3809
  </xsl:if>
3761
3810
 
3762
3811
  <xsl:choose>
@@ -3841,6 +3890,7 @@
3841
3890
  <!-- centered table when table name is centered (see table-name-style) -->
3842
3891
 
3843
3892
  <fo:table table-layout="fixed" width="100%" xsl:use-attribute-sets="table-container-style">
3893
+
3844
3894
  <fo:table-column column-width="proportional-column-width(1)"/>
3845
3895
  <fo:table-column column-width="{@width}"/>
3846
3896
  <fo:table-column column-width="proportional-column-width(1)"/>
@@ -3910,9 +3960,28 @@
3910
3960
 
3911
3961
  </fo:block>
3912
3962
 
3963
+ <!-- <xsl:if test="$namespace = 'bsi' or $namespace = 'iec' or $namespace = 'iso'"> -->
3964
+ <xsl:if test="$continued = 'true'">
3965
+ <fo:block text-align="right">
3966
+ <xsl:apply-templates select="../*[local-name() = 'note'][@type = 'units']/node()"/>
3967
+ </fo:block>
3968
+ </xsl:if>
3969
+ <!-- </xsl:if> -->
3970
+
3913
3971
  </xsl:if>
3914
3972
  </xsl:template> <!-- table/name -->
3915
3973
 
3974
+ <!-- workaround solution for https://github.com/metanorma/metanorma-iso/issues/1151#issuecomment-2033087938 -->
3975
+ <xsl:template match="*[local-name()='table']/*[local-name() = 'note'][@type = 'units']/*[local-name() = 'p']/text()" priority="4">
3976
+ <xsl:choose>
3977
+ <xsl:when test="preceding-sibling::*[local-name() = 'br']">
3978
+ <!-- remove CR or LF at start -->
3979
+ <xsl:value-of select="java:replaceAll(java:java.lang.String.new(.),'^(&#13;&#10;|&#13;|&#10;)', '')"/>
3980
+ </xsl:when>
3981
+ <xsl:otherwise><xsl:value-of select="."/></xsl:otherwise>
3982
+ </xsl:choose>
3983
+ </xsl:template>
3984
+
3916
3985
  <!-- SOURCE: ... -->
3917
3986
  <xsl:template match="*[local-name()='table']/*[local-name() = 'source']" priority="2">
3918
3987
  <xsl:call-template name="termsource"/>
@@ -4336,7 +4405,7 @@
4336
4405
  <xsl:param name="colwidths"/>
4337
4406
  <xsl:param name="colgroup"/>
4338
4407
 
4339
- <xsl:variable name="isNoteOrFnExist" select="../*[local-name()='note'] or ../*[local-name()='example'] or ../*[local-name()='dl'] or ..//*[local-name()='fn'][local-name(..) != 'name'] or ../*[local-name()='source'] or ../*[local-name()='p']"/>
4408
+ <xsl:variable name="isNoteOrFnExist" select="../*[local-name()='note'][not(@type = 'units')] or ../*[local-name()='example'] or ../*[local-name()='dl'] or ..//*[local-name()='fn'][local-name(..) != 'name'] or ../*[local-name()='source'] or ../*[local-name()='p']"/>
4340
4409
 
4341
4410
  <xsl:variable name="isNoteOrFnExistShowAfterTable">
4342
4411
 
@@ -4408,7 +4477,7 @@
4408
4477
 
4409
4478
  <xsl:apply-templates select="../*[local-name()='p']"/>
4410
4479
  <xsl:apply-templates select="../*[local-name()='dl']"/>
4411
- <xsl:apply-templates select="../*[local-name()='note']"/>
4480
+ <xsl:apply-templates select="../*[local-name()='note'][not(@type = 'units')]"/>
4412
4481
  <xsl:apply-templates select="../*[local-name()='example']"/>
4413
4482
  <xsl:apply-templates select="../*[local-name()='source']"/>
4414
4483
 
@@ -4418,7 +4487,7 @@
4418
4487
 
4419
4488
  <!-- horizontal row separator -->
4420
4489
  <xsl:if test="normalize-space($isDisplayRowSeparator) = 'true'">
4421
- <xsl:if test="(../*[local-name()='note'] or ../*[local-name()='example']) and normalize-space($table_fn_block) != ''">
4490
+ <xsl:if test="(../*[local-name()='note'][not(@type = 'units')] or ../*[local-name()='example']) and normalize-space($table_fn_block) != ''">
4422
4491
  <fo:block-container border-top="0.5pt solid black" padding-left="1mm" padding-right="1mm">
4423
4492
 
4424
4493
  <xsl:call-template name="setBordersTableArray"/>
@@ -4938,8 +5007,9 @@
4938
5007
  <xsl:if test="not(preceding-sibling::*[@reference = $reference])"> <!-- only unique reference puts in note-->
4939
5008
 
4940
5009
  <fo:block xsl:use-attribute-sets="table-fn-style">
4941
-
5010
+ <xsl:call-template name="refine_table-fn-style"/>
4942
5011
  <fo:inline id="{@id}" xsl:use-attribute-sets="table-fn-number-style">
5012
+ <xsl:call-template name="refine_table-fn-number-style"/>
4943
5013
 
4944
5014
  <xsl:value-of select="@reference"/>
4945
5015
 
@@ -5123,7 +5193,20 @@
5123
5193
  <!-- Definition List -->
5124
5194
  <!-- ===================== -->
5125
5195
 
5126
- <xsl:template match="*[local-name()='dl']">
5196
+ <!-- for table auto-layout algorithm -->
5197
+ <xsl:template match="*[local-name()='dl']" priority="2">
5198
+ <xsl:choose>
5199
+ <xsl:when test="$table_only_with_id != '' and @id = $table_only_with_id">
5200
+ <xsl:call-template name="dl"/>
5201
+ </xsl:when>
5202
+ <xsl:when test="$table_only_with_id != ''"><fo:block/><!-- to prevent empty fo:block-container --></xsl:when>
5203
+ <xsl:otherwise>
5204
+ <xsl:call-template name="dl"/>
5205
+ </xsl:otherwise>
5206
+ </xsl:choose>
5207
+ </xsl:template>
5208
+
5209
+ <xsl:template match="*[local-name()='dl']" name="dl">
5127
5210
  <xsl:variable name="isAdded" select="@added"/>
5128
5211
  <xsl:variable name="isDeleted" select="@deleted"/>
5129
5212
  <!-- <dl><xsl:copy-of select="."/></dl> -->
@@ -6094,11 +6177,16 @@
6094
6177
  <xsl:template match="text()[ancestor::*[local-name()='smallcap']]">
6095
6178
  <!-- <xsl:variable name="text" select="normalize-space(.)"/> --> <!-- https://github.com/metanorma/metanorma-iso/issues/1115 -->
6096
6179
  <xsl:variable name="text" select="."/>
6097
- <fo:inline font-size="75%" role="SKIP">
6180
+ <xsl:variable name="ratio_">
6181
+ 0.75
6182
+ </xsl:variable>
6183
+ <xsl:variable name="ratio" select="number(normalize-space($ratio_))"/>
6184
+ <fo:inline font-size="{$ratio * 100}%" role="SKIP">
6098
6185
  <xsl:if test="string-length($text) &gt; 0">
6099
6186
  <xsl:variable name="smallCapsText">
6100
6187
  <xsl:call-template name="recursiveSmallCaps">
6101
6188
  <xsl:with-param name="text" select="$text"/>
6189
+ <xsl:with-param name="ratio" select="$ratio"/>
6102
6190
  </xsl:call-template>
6103
6191
  </xsl:variable>
6104
6192
  <!-- merge neighboring fo:inline -->
@@ -6135,12 +6223,13 @@
6135
6223
 
6136
6224
  <xsl:template name="recursiveSmallCaps">
6137
6225
  <xsl:param name="text"/>
6226
+ <xsl:param name="ratio"/>
6138
6227
  <xsl:variable name="char" select="substring($text,1,1)"/>
6139
6228
  <!-- <xsl:variable name="upperCase" select="translate($char, $lower, $upper)"/> -->
6140
6229
  <xsl:variable name="upperCase" select="java:toUpperCase(java:java.lang.String.new($char))"/>
6141
6230
  <xsl:choose>
6142
6231
  <xsl:when test="$char=$upperCase">
6143
- <fo:inline font-size="{100 div 0.75}%" role="SKIP">
6232
+ <fo:inline font-size="{100 div $ratio}%" role="SKIP">
6144
6233
  <xsl:value-of select="$upperCase"/>
6145
6234
  </fo:inline>
6146
6235
  </xsl:when>
@@ -6151,6 +6240,7 @@
6151
6240
  <xsl:if test="string-length($text) &gt; 1">
6152
6241
  <xsl:call-template name="recursiveSmallCaps">
6153
6242
  <xsl:with-param name="text" select="substring($text,2)"/>
6243
+ <xsl:with-param name="ratio" select="$ratio"/>
6154
6244
  </xsl:call-template>
6155
6245
  </xsl:if>
6156
6246
  </xsl:template>
@@ -6187,6 +6277,9 @@
6187
6277
  <xsl:if test="$key = 'font-family' or $key = 'font-size' or $key = 'color'">
6188
6278
  <style name="{$key}"><xsl:value-of select="$value"/></style>
6189
6279
  </xsl:if>
6280
+ <xsl:if test="$key = 'text-indent'">
6281
+ <style name="padding-left"><xsl:value-of select="$value"/></style>
6282
+ </xsl:if>
6190
6283
  </xsl:for-each>
6191
6284
  </xsl:variable>
6192
6285
  <xsl:variable name="styles" select="xalan:nodeset($styles_)"/>
@@ -7059,7 +7152,13 @@
7059
7152
  <xsl:value-of select="$language_current_2"/>
7060
7153
  </xsl:when>
7061
7154
  <xsl:otherwise>
7062
- <xsl:value-of select="//*[local-name()='bibdata']//*[local-name()='language']"/>
7155
+ <xsl:variable name="language_current_3" select="normalize-space(//*[local-name()='bibdata']//*[local-name()='language'])"/>
7156
+ <xsl:choose>
7157
+ <xsl:when test="$language_current_3 != ''">
7158
+ <xsl:value-of select="$language_current_3"/>
7159
+ </xsl:when>
7160
+ <xsl:otherwise>en</xsl:otherwise>
7161
+ </xsl:choose>
7063
7162
  </xsl:otherwise>
7064
7163
  </xsl:choose>
7065
7164
  </xsl:otherwise>
@@ -7596,6 +7695,11 @@
7596
7695
  </xsl:call-template>
7597
7696
  </xsl:template>
7598
7697
 
7698
+ <!-- command between two xref points to non-standard bibitem -->
7699
+ <xsl:template match="text()[. = ','][preceding-sibling::node()[1][local-name() = 'sup'][*[local-name() = 'xref'][@type = 'footnote']] and following-sibling::node()[1][local-name() = 'sup'][*[local-name() = 'xref'][@type = 'footnote']]]">
7700
+ <xsl:value-of select="."/>
7701
+ </xsl:template>
7702
+
7599
7703
  <!-- ====== -->
7600
7704
  <!-- formula -->
7601
7705
  <!-- ====== -->
@@ -7964,7 +8068,7 @@
7964
8068
  </xsl:when>
7965
8069
  <xsl:otherwise>
7966
8070
  <fo:external-graphic src="{$src}" fox:alt-text="Image {@alt}" xsl:use-attribute-sets="image-graphic-style">
7967
- <xsl:if test="not(@mimetype = 'image/svg+xml') and ../*[local-name() = 'name'] and not(ancestor::*[local-name() = 'table'])">
8071
+ <xsl:if test="not(@mimetype = 'image/svg+xml') and (../*[local-name() = 'name'] or parent::*[local-name() = 'figure'][@unnumbered = 'true']) and not(ancestor::*[local-name() = 'table'])">
7968
8072
 
7969
8073
  <xsl:if test="@width != '' and @width != 'auto' and @width != 'text-width' and @width != 'full-page-width' and @width != 'narrow'">
7970
8074
  <xsl:attribute name="width">
@@ -8299,6 +8403,8 @@
8299
8403
  </xsl:attribute>
8300
8404
  </xsl:template>
8301
8405
 
8406
+ <xsl:variable name="regex_starts_with_digit">^[0-9].*</xsl:variable>
8407
+
8302
8408
  <xsl:template match="*[local-name() = 'svg'][not(@width and @height)]" mode="svg_update">
8303
8409
  <xsl:copy>
8304
8410
  <xsl:apply-templates select="@*" mode="svg_update"/>
@@ -8317,7 +8423,8 @@
8317
8423
 
8318
8424
  <xsl:attribute name="width">
8319
8425
  <xsl:choose>
8320
- <xsl:when test="$parent_image_width != '' and $parent_image_width != 'auto'"><xsl:value-of select="$parent_image_width"/></xsl:when>
8426
+ <!-- width is non 'auto', 'text-width', 'full-page-width' or 'narrow' -->
8427
+ <xsl:when test="$parent_image_width != '' and normalize-space(java:matches(java:java.lang.String.new($parent_image_width), $regex_starts_with_digit)) = 'true'"><xsl:value-of select="$parent_image_width"/></xsl:when>
8321
8428
  <xsl:when test="$width != ''">
8322
8429
  <xsl:value-of select="round($width)"/>
8323
8430
  </xsl:when>
@@ -8326,7 +8433,8 @@
8326
8433
  </xsl:attribute>
8327
8434
  <xsl:attribute name="height">
8328
8435
  <xsl:choose>
8329
- <xsl:when test="$parent_image_height != '' and $parent_image_height != 'auto'"><xsl:value-of select="$parent_image_height"/></xsl:when>
8436
+ <!-- height non 'auto', 'text-width', 'full-page-width' or 'narrow' -->
8437
+ <xsl:when test="$parent_image_height != '' and normalize-space(java:matches(java:java.lang.String.new($parent_image_height), $regex_starts_with_digit)) = 'true'"><xsl:value-of select="$parent_image_height"/></xsl:when>
8330
8438
  <xsl:when test="$height != ''">
8331
8439
  <xsl:value-of select="round($height)"/>
8332
8440
  </xsl:when>
@@ -8343,7 +8451,7 @@
8343
8451
  <xsl:variable name="parent_image_width" select="normalize-space(ancestor::*[2][local-name() = 'image']/@width)"/>
8344
8452
  <xsl:attribute name="width">
8345
8453
  <xsl:choose>
8346
- <xsl:when test="$parent_image_width != '' and $parent_image_width != 'auto'"><xsl:value-of select="$parent_image_width"/></xsl:when>
8454
+ <xsl:when test="$parent_image_width != '' and normalize-space(java:matches(java:java.lang.String.new($parent_image_width), $regex_starts_with_digit)) = 'true'"><xsl:value-of select="$parent_image_width"/></xsl:when>
8347
8455
  <xsl:otherwise><xsl:value-of select="."/></xsl:otherwise>
8348
8456
  </xsl:choose>
8349
8457
  </xsl:attribute>
@@ -8354,7 +8462,7 @@
8354
8462
  <xsl:variable name="parent_image_height" select="normalize-space(ancestor::*[2][local-name() = 'image']/@height)"/>
8355
8463
  <xsl:attribute name="height">
8356
8464
  <xsl:choose>
8357
- <xsl:when test="$parent_image_height != '' and $parent_image_height != 'auto'"><xsl:value-of select="$parent_image_height"/></xsl:when>
8465
+ <xsl:when test="$parent_image_height != '' and normalize-space(java:matches(java:java.lang.String.new($parent_image_height), $regex_starts_with_digit)) = 'true'"><xsl:value-of select="$parent_image_height"/></xsl:when>
8358
8466
  <xsl:otherwise><xsl:value-of select="."/></xsl:otherwise>
8359
8467
  </xsl:choose>
8360
8468
  </xsl:attribute>
@@ -9816,6 +9924,7 @@
9816
9924
  <xsl:template match="*[local-name() = 'termexample']/*[local-name() = 'name']">
9817
9925
  <xsl:if test="normalize-space() != ''">
9818
9926
  <fo:inline xsl:use-attribute-sets="termexample-name-style">
9927
+ <xsl:call-template name="refine_termexample-name-style"/>
9819
9928
  <xsl:apply-templates/>
9820
9929
  </fo:inline>
9821
9930
  </xsl:if>
@@ -9966,6 +10075,7 @@
9966
10075
  </xsl:when>
9967
10076
  <xsl:otherwise>
9968
10077
  <fo:inline xsl:use-attribute-sets="example-name-style">
10078
+ <xsl:call-template name="refine_example-name-style"/>
9969
10079
  <xsl:apply-templates/>
9970
10080
  </fo:inline>
9971
10081
  </xsl:otherwise>
@@ -11183,6 +11293,7 @@
11183
11293
  <xsl:template match="*[local-name() = 'references'][@normative='true']/*[local-name() = 'bibitem']" name="bibitem" priority="2">
11184
11294
 
11185
11295
  <fo:block id="{@id}" xsl:use-attribute-sets="bibitem-normative-style">
11296
+
11186
11297
  <xsl:call-template name="processBibitem"/>
11187
11298
  </fo:block>
11188
11299
 
@@ -11224,6 +11335,7 @@
11224
11335
  <xsl:when test="@hidden = 'true'"><!-- skip --></xsl:when>
11225
11336
  <xsl:otherwise>
11226
11337
  <fo:list-item id="{@id}" xsl:use-attribute-sets="bibitem-non-normative-list-item-style">
11338
+
11227
11339
  <fo:list-item-label end-indent="label-end()">
11228
11340
  <fo:block role="SKIP">
11229
11341
  <fo:inline role="SKIP">
@@ -208,7 +208,9 @@
208
208
  </define>
209
209
  <define name="roledescription">
210
210
  <element name="description">
211
- <ref name="FormattedString"/>
211
+ <oneOrMore>
212
+ <ref name="TextElement"/>
213
+ </oneOrMore>
212
214
  </element>
213
215
  </define>
214
216
  <define name="person">
@@ -333,7 +335,9 @@
333
335
  </define>
334
336
  <define name="affiliationdescription">
335
337
  <element name="description">
336
- <ref name="FormattedString"/>
338
+ <oneOrMore>
339
+ <ref name="TextElement"/>
340
+ </oneOrMore>
337
341
  </element>
338
342
  </define>
339
343
  <define name="organization">
@@ -897,7 +901,9 @@
897
901
  </define>
898
902
  <define name="formattedref">
899
903
  <element name="formattedref">
900
- <ref name="FormattedString"/>
904
+ <oneOrMore>
905
+ <ref name="TextElement"/>
906
+ </oneOrMore>
901
907
  </element>
902
908
  </define>
903
909
  <define name="license">
@@ -942,7 +948,9 @@
942
948
  <optional>
943
949
  <attribute name="type"/>
944
950
  </optional>
945
- <ref name="FormattedString"/>
951
+ <zeroOrMore>
952
+ <ref name="TextElement"/>
953
+ </zeroOrMore>
946
954
  </define>
947
955
  <!-- TitleType = ( "alternative" | "original" | "unofficial" | "subtitle" | "main" ) -->
948
956
  <define name="TypedUri">
@@ -1042,7 +1050,9 @@
1042
1050
  <optional>
1043
1051
  <attribute name="script"/>
1044
1052
  </optional>
1045
- <text/>
1053
+ <oneOrMore>
1054
+ <ref name="TextElement"/>
1055
+ </oneOrMore>
1046
1056
  </element>
1047
1057
  </define>
1048
1058
  <define name="docnumber">
@@ -1267,12 +1277,16 @@
1267
1277
  <optional>
1268
1278
  <attribute name="type"/>
1269
1279
  </optional>
1270
- <ref name="FormattedString"/>
1280
+ <oneOrMore>
1281
+ <ref name="TextElement"/>
1282
+ </oneOrMore>
1271
1283
  </element>
1272
1284
  </define>
1273
1285
  <define name="bibabstract">
1274
1286
  <element name="abstract">
1275
- <ref name="FormattedString"/>
1287
+ <oneOrMore>
1288
+ <ref name="TextElement"/>
1289
+ </oneOrMore>
1276
1290
  </element>
1277
1291
  </define>
1278
1292
  <define name="copyright">
@@ -1377,7 +1391,9 @@
1377
1391
  </attribute>
1378
1392
  <optional>
1379
1393
  <element name="description">
1380
- <ref name="FormattedString"/>
1394
+ <oneOrMore>
1395
+ <ref name="TextElement"/>
1396
+ </oneOrMore>
1381
1397
  </element>
1382
1398
  </optional>
1383
1399
  <element name="bibitem">
@@ -11,58 +11,22 @@
11
11
  <start>
12
12
  <ref name="bipm-standard"/>
13
13
  </start>
14
- <define name="xref">
15
- <element name="xref">
16
- <attribute name="target">
17
- <data type="string">
18
- <param name="pattern">\i\c*|\c+#\c+</param>
19
- </data>
14
+ <define name="XrefAttributes" combine="interleave">
15
+ <optional>
16
+ <attribute name="pagenumber">
17
+ <data type="boolean"/>
20
18
  </attribute>
21
- <optional>
22
- <attribute name="to">
23
- <data type="string">
24
- <param name="pattern">\i\c*|\c+#\c+</param>
25
- </data>
26
- </attribute>
27
- </optional>
28
- <optional>
29
- <attribute name="type">
30
- <ref name="ReferenceFormat"/>
31
- </attribute>
32
- </optional>
33
- <optional>
34
- <attribute name="alt"/>
35
- </optional>
36
- <optional>
37
- <attribute name="case">
38
- <choice>
39
- <value>capital</value>
40
- <value>lowercase</value>
41
- </choice>
42
- </attribute>
43
- </optional>
44
- <optional>
45
- <attribute name="droploc">
46
- <data type="boolean"/>
47
- </attribute>
48
- </optional>
49
- <optional>
50
- <attribute name="pagenumber">
51
- <data type="boolean"/>
52
- </attribute>
53
- </optional>
54
- <optional>
55
- <attribute name="nosee">
56
- <data type="boolean"/>
57
- </attribute>
58
- </optional>
59
- <optional>
60
- <attribute name="nopage">
61
- <data type="boolean"/>
62
- </attribute>
63
- </optional>
64
- <ref name="XrefBody"/>
65
- </element>
19
+ </optional>
20
+ <optional>
21
+ <attribute name="nosee">
22
+ <data type="boolean"/>
23
+ </attribute>
24
+ </optional>
25
+ <optional>
26
+ <attribute name="nopage">
27
+ <data type="boolean"/>
28
+ </attribute>
29
+ </optional>
66
30
  </define>
67
31
  <define name="Clause-Section">
68
32
  <optional>