metanorma-bipm 2.2.1 → 2.2.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/isodoc/bipm/bipm.brochure.xsl +38 -12
- data/lib/isodoc/bipm/bipm.guide.xsl +38 -12
- data/lib/isodoc/bipm/bipm.mise-en-pratique.xsl +38 -12
- data/lib/isodoc/bipm/bipm.rapport.xsl +38 -12
- data/lib/isodoc/bipm/html/htmlstyle.css +30 -1
- data/lib/isodoc/bipm/jcgm.standard.xsl +38 -12
- data/lib/metanorma/bipm/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f0b609b5b83c535799d98aad50e967a429954a173a612235fdbf9d6a09535029
|
4
|
+
data.tar.gz: ab072e5704c0e4d872d8a7ecc3bf8e8074abbc6c1939f61b72df0189767d0f5a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1e90aafe53eb531a4f10d8f76a1bf8718ff22f7b246f3ea29263d3f2d6b425b8f5a99d4f9a94f3ef28f730a84e1abf7528bcf3e381bf43162f4c87e70886bc15
|
7
|
+
data.tar.gz: 3cc243957aa7bf48a192d91a0cb9390fe9893fc9647760d31e712534b0111b154f72e692ecf48ddc58224451aa631d907c5cc2ca960fd3afc09263d0e64c6bcb
|
@@ -8,7 +8,7 @@
|
|
8
8
|
<xsl:param name="add_math_as_attachment">true</xsl:param>
|
9
9
|
<xsl:param name="final_transform">true</xsl:param>
|
10
10
|
|
11
|
-
<xsl:key name="kfn" match="*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure') and not(ancestor::*[local-name() = 'name'])
|
11
|
+
<xsl:key name="kfn" match="*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure' or local-name() = 'localized-strings')] and not(ancestor::*[local-name() = 'name']))]" use="@reference"/>
|
12
12
|
|
13
13
|
<xsl:variable name="first_pass" select="count($index//item) = 0"/>
|
14
14
|
|
@@ -6502,7 +6502,7 @@
|
|
6502
6502
|
</fn>
|
6503
6503
|
-->
|
6504
6504
|
<!-- footnotes in text (title, bibliography, main body, table's, figure's names), not for tables, figures -->
|
6505
|
-
<xsl:template match="*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure') and not(ancestor::*[local-name() = 'name'])
|
6505
|
+
<xsl:template match="*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure')] and not(ancestor::*[local-name() = 'name']))]" priority="2" name="fn">
|
6506
6506
|
|
6507
6507
|
<!-- list of footnotes to calculate actual footnotes number -->
|
6508
6508
|
<xsl:variable name="p_fn_">
|
@@ -6559,8 +6559,7 @@
|
|
6559
6559
|
</fo:basic-link>
|
6560
6560
|
</fo:inline>
|
6561
6561
|
</xsl:variable>
|
6562
|
-
|
6563
|
-
gen_id=<xsl:value-of select="$gen_id"/> -->
|
6562
|
+
|
6564
6563
|
<xsl:choose>
|
6565
6564
|
<xsl:when test="normalize-space(@skip_footnote_body) = 'true'">
|
6566
6565
|
<xsl:copy-of select="$footnote_inline"/>
|
@@ -6615,7 +6614,7 @@
|
|
6615
6614
|
<!-- commented:
|
6616
6615
|
.//*[local-name() = 'bibitem'][ancestor::*[local-name() = 'references']]/*[local-name() = 'note'] |
|
6617
6616
|
because 'fn' there is in biblio-tag -->
|
6618
|
-
<xsl:for-each select=".//*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure') and not(ancestor::*[local-name() = 'name'])
|
6617
|
+
<xsl:for-each select=".//*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure')] and not(ancestor::*[local-name() = 'name']))][generate-id(.)=generate-id(key('kfn',@reference)[1])]">
|
6619
6618
|
<!-- copy unique fn -->
|
6620
6619
|
<fn gen_id="{generate-id(.)}">
|
6621
6620
|
<xsl:copy-of select="@*"/>
|
@@ -9230,7 +9229,9 @@
|
|
9230
9229
|
|
9231
9230
|
<xsl:variable name="scale" select="java:org.metanorma.fop.Util.getImageScale($img_src, $width_effective, $height_effective)"/>
|
9232
9231
|
<xsl:if test="number($scale) < 100">
|
9233
|
-
|
9232
|
+
|
9233
|
+
<xsl:attribute name="content-width"><xsl:value-of select="$scale"/>%</xsl:attribute>
|
9234
|
+
|
9234
9235
|
</xsl:if>
|
9235
9236
|
|
9236
9237
|
</xsl:if>
|
@@ -10257,6 +10258,12 @@
|
|
10257
10258
|
</xsl:attribute>
|
10258
10259
|
</xsl:for-each>
|
10259
10260
|
|
10261
|
+
<!-- remove margin between rows in the table with sourcecode line numbers -->
|
10262
|
+
<xsl:if test="ancestor::*[local-name() = 'sourcecode'][@linenums = 'true'] and ancestor::*[local-name() = 'tr'][1]/following-sibling::*[local-name() = 'tr']">
|
10263
|
+
<xsl:attribute name="margin-top">0pt</xsl:attribute>
|
10264
|
+
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
10265
|
+
</xsl:if>
|
10266
|
+
|
10260
10267
|
<xsl:apply-templates select="node()[not(local-name() = 'name')]"/>
|
10261
10268
|
</fo:block>
|
10262
10269
|
|
@@ -10305,7 +10312,7 @@
|
|
10305
10312
|
</xsl:template>
|
10306
10313
|
|
10307
10314
|
<!-- outer table with line numbers for sourcecode -->
|
10308
|
-
<xsl:template match="*[local-name()='
|
10315
|
+
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode'] | -->
|
10309
10316
|
<fo:block>
|
10310
10317
|
<fo:table width="100%" table-layout="fixed">
|
10311
10318
|
<xsl:copy-of select="@id"/>
|
@@ -10317,16 +10324,16 @@
|
|
10317
10324
|
</fo:table>
|
10318
10325
|
</fo:block>
|
10319
10326
|
</xsl:template>
|
10320
|
-
<xsl:template match="*[local-name()='
|
10327
|
+
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']/*[local-name() = 'tbody']" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode']/*[local-name() = 'tbody'] | -->
|
10321
10328
|
<xsl:apply-templates/>
|
10322
10329
|
</xsl:template>
|
10323
|
-
<xsl:template match="*[local-name()='
|
10330
|
+
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']//*[local-name()='tr']" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode']//*[local-name()='tr'] | -->
|
10324
10331
|
<fo:table-row>
|
10325
10332
|
<xsl:apply-templates/>
|
10326
10333
|
</fo:table-row>
|
10327
10334
|
</xsl:template>
|
10328
10335
|
<!-- first td with line numbers -->
|
10329
|
-
<xsl:template match="*[local-name()='
|
10336
|
+
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']//*[local-name()='tr']/*[local-name()='td'][not(preceding-sibling::*)]" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode'] -->
|
10330
10337
|
<fo:table-cell>
|
10331
10338
|
<fo:block>
|
10332
10339
|
|
@@ -10346,8 +10353,9 @@
|
|
10346
10353
|
</fo:block>
|
10347
10354
|
</fo:table-cell>
|
10348
10355
|
</xsl:template>
|
10356
|
+
|
10349
10357
|
<!-- second td with sourcecode -->
|
10350
|
-
<xsl:template match="*[local-name()='
|
10358
|
+
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']//*[local-name()='tr']/*[local-name()='td'][preceding-sibling::*]" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode'] -->
|
10351
10359
|
<fo:table-cell>
|
10352
10360
|
<fo:block>
|
10353
10361
|
<xsl:apply-templates/>
|
@@ -10585,7 +10593,25 @@
|
|
10585
10593
|
<xsl:template match="*[local-name()='pre']" name="pre">
|
10586
10594
|
<fo:block xsl:use-attribute-sets="pre-style">
|
10587
10595
|
<xsl:copy-of select="@id"/>
|
10588
|
-
<xsl:
|
10596
|
+
<xsl:choose>
|
10597
|
+
|
10598
|
+
<xsl:when test="ancestor::*[local-name() = 'sourcecode'][@linenums = 'true'] and ancestor::*[local-name()='td'][1][not(preceding-sibling::*)]"> <!-- pre in the first td in the table with @linenums = 'true' -->
|
10599
|
+
<xsl:if test="ancestor::*[local-name() = 'tr'][1]/following-sibling::*[local-name() = 'tr']"> <!-- is current tr isn't last -->
|
10600
|
+
<xsl:attribute name="margin-top">0pt</xsl:attribute>
|
10601
|
+
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
10602
|
+
</xsl:if>
|
10603
|
+
<fo:instream-foreign-object fox:alt-text="{.}" content-width="95%">
|
10604
|
+
<math xmlns="http://www.w3.org/1998/Math/MathML">
|
10605
|
+
<mtext><xsl:value-of select="."/></mtext>
|
10606
|
+
</math>
|
10607
|
+
</fo:instream-foreign-object>
|
10608
|
+
</xsl:when>
|
10609
|
+
|
10610
|
+
<xsl:otherwise>
|
10611
|
+
<xsl:apply-templates/>
|
10612
|
+
</xsl:otherwise>
|
10613
|
+
|
10614
|
+
</xsl:choose>
|
10589
10615
|
</fo:block>
|
10590
10616
|
</xsl:template>
|
10591
10617
|
<!-- =============== -->
|
@@ -8,7 +8,7 @@
|
|
8
8
|
<xsl:param name="add_math_as_attachment">true</xsl:param>
|
9
9
|
<xsl:param name="final_transform">true</xsl:param>
|
10
10
|
|
11
|
-
<xsl:key name="kfn" match="*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure') and not(ancestor::*[local-name() = 'name'])
|
11
|
+
<xsl:key name="kfn" match="*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure' or local-name() = 'localized-strings')] and not(ancestor::*[local-name() = 'name']))]" use="@reference"/>
|
12
12
|
|
13
13
|
<xsl:variable name="first_pass" select="count($index//item) = 0"/>
|
14
14
|
|
@@ -6502,7 +6502,7 @@
|
|
6502
6502
|
</fn>
|
6503
6503
|
-->
|
6504
6504
|
<!-- footnotes in text (title, bibliography, main body, table's, figure's names), not for tables, figures -->
|
6505
|
-
<xsl:template match="*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure') and not(ancestor::*[local-name() = 'name'])
|
6505
|
+
<xsl:template match="*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure')] and not(ancestor::*[local-name() = 'name']))]" priority="2" name="fn">
|
6506
6506
|
|
6507
6507
|
<!-- list of footnotes to calculate actual footnotes number -->
|
6508
6508
|
<xsl:variable name="p_fn_">
|
@@ -6559,8 +6559,7 @@
|
|
6559
6559
|
</fo:basic-link>
|
6560
6560
|
</fo:inline>
|
6561
6561
|
</xsl:variable>
|
6562
|
-
|
6563
|
-
gen_id=<xsl:value-of select="$gen_id"/> -->
|
6562
|
+
|
6564
6563
|
<xsl:choose>
|
6565
6564
|
<xsl:when test="normalize-space(@skip_footnote_body) = 'true'">
|
6566
6565
|
<xsl:copy-of select="$footnote_inline"/>
|
@@ -6615,7 +6614,7 @@
|
|
6615
6614
|
<!-- commented:
|
6616
6615
|
.//*[local-name() = 'bibitem'][ancestor::*[local-name() = 'references']]/*[local-name() = 'note'] |
|
6617
6616
|
because 'fn' there is in biblio-tag -->
|
6618
|
-
<xsl:for-each select=".//*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure') and not(ancestor::*[local-name() = 'name'])
|
6617
|
+
<xsl:for-each select=".//*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure')] and not(ancestor::*[local-name() = 'name']))][generate-id(.)=generate-id(key('kfn',@reference)[1])]">
|
6619
6618
|
<!-- copy unique fn -->
|
6620
6619
|
<fn gen_id="{generate-id(.)}">
|
6621
6620
|
<xsl:copy-of select="@*"/>
|
@@ -9230,7 +9229,9 @@
|
|
9230
9229
|
|
9231
9230
|
<xsl:variable name="scale" select="java:org.metanorma.fop.Util.getImageScale($img_src, $width_effective, $height_effective)"/>
|
9232
9231
|
<xsl:if test="number($scale) < 100">
|
9233
|
-
|
9232
|
+
|
9233
|
+
<xsl:attribute name="content-width"><xsl:value-of select="$scale"/>%</xsl:attribute>
|
9234
|
+
|
9234
9235
|
</xsl:if>
|
9235
9236
|
|
9236
9237
|
</xsl:if>
|
@@ -10257,6 +10258,12 @@
|
|
10257
10258
|
</xsl:attribute>
|
10258
10259
|
</xsl:for-each>
|
10259
10260
|
|
10261
|
+
<!-- remove margin between rows in the table with sourcecode line numbers -->
|
10262
|
+
<xsl:if test="ancestor::*[local-name() = 'sourcecode'][@linenums = 'true'] and ancestor::*[local-name() = 'tr'][1]/following-sibling::*[local-name() = 'tr']">
|
10263
|
+
<xsl:attribute name="margin-top">0pt</xsl:attribute>
|
10264
|
+
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
10265
|
+
</xsl:if>
|
10266
|
+
|
10260
10267
|
<xsl:apply-templates select="node()[not(local-name() = 'name')]"/>
|
10261
10268
|
</fo:block>
|
10262
10269
|
|
@@ -10305,7 +10312,7 @@
|
|
10305
10312
|
</xsl:template>
|
10306
10313
|
|
10307
10314
|
<!-- outer table with line numbers for sourcecode -->
|
10308
|
-
<xsl:template match="*[local-name()='
|
10315
|
+
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode'] | -->
|
10309
10316
|
<fo:block>
|
10310
10317
|
<fo:table width="100%" table-layout="fixed">
|
10311
10318
|
<xsl:copy-of select="@id"/>
|
@@ -10317,16 +10324,16 @@
|
|
10317
10324
|
</fo:table>
|
10318
10325
|
</fo:block>
|
10319
10326
|
</xsl:template>
|
10320
|
-
<xsl:template match="*[local-name()='
|
10327
|
+
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']/*[local-name() = 'tbody']" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode']/*[local-name() = 'tbody'] | -->
|
10321
10328
|
<xsl:apply-templates/>
|
10322
10329
|
</xsl:template>
|
10323
|
-
<xsl:template match="*[local-name()='
|
10330
|
+
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']//*[local-name()='tr']" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode']//*[local-name()='tr'] | -->
|
10324
10331
|
<fo:table-row>
|
10325
10332
|
<xsl:apply-templates/>
|
10326
10333
|
</fo:table-row>
|
10327
10334
|
</xsl:template>
|
10328
10335
|
<!-- first td with line numbers -->
|
10329
|
-
<xsl:template match="*[local-name()='
|
10336
|
+
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']//*[local-name()='tr']/*[local-name()='td'][not(preceding-sibling::*)]" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode'] -->
|
10330
10337
|
<fo:table-cell>
|
10331
10338
|
<fo:block>
|
10332
10339
|
|
@@ -10346,8 +10353,9 @@
|
|
10346
10353
|
</fo:block>
|
10347
10354
|
</fo:table-cell>
|
10348
10355
|
</xsl:template>
|
10356
|
+
|
10349
10357
|
<!-- second td with sourcecode -->
|
10350
|
-
<xsl:template match="*[local-name()='
|
10358
|
+
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']//*[local-name()='tr']/*[local-name()='td'][preceding-sibling::*]" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode'] -->
|
10351
10359
|
<fo:table-cell>
|
10352
10360
|
<fo:block>
|
10353
10361
|
<xsl:apply-templates/>
|
@@ -10585,7 +10593,25 @@
|
|
10585
10593
|
<xsl:template match="*[local-name()='pre']" name="pre">
|
10586
10594
|
<fo:block xsl:use-attribute-sets="pre-style">
|
10587
10595
|
<xsl:copy-of select="@id"/>
|
10588
|
-
<xsl:
|
10596
|
+
<xsl:choose>
|
10597
|
+
|
10598
|
+
<xsl:when test="ancestor::*[local-name() = 'sourcecode'][@linenums = 'true'] and ancestor::*[local-name()='td'][1][not(preceding-sibling::*)]"> <!-- pre in the first td in the table with @linenums = 'true' -->
|
10599
|
+
<xsl:if test="ancestor::*[local-name() = 'tr'][1]/following-sibling::*[local-name() = 'tr']"> <!-- is current tr isn't last -->
|
10600
|
+
<xsl:attribute name="margin-top">0pt</xsl:attribute>
|
10601
|
+
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
10602
|
+
</xsl:if>
|
10603
|
+
<fo:instream-foreign-object fox:alt-text="{.}" content-width="95%">
|
10604
|
+
<math xmlns="http://www.w3.org/1998/Math/MathML">
|
10605
|
+
<mtext><xsl:value-of select="."/></mtext>
|
10606
|
+
</math>
|
10607
|
+
</fo:instream-foreign-object>
|
10608
|
+
</xsl:when>
|
10609
|
+
|
10610
|
+
<xsl:otherwise>
|
10611
|
+
<xsl:apply-templates/>
|
10612
|
+
</xsl:otherwise>
|
10613
|
+
|
10614
|
+
</xsl:choose>
|
10589
10615
|
</fo:block>
|
10590
10616
|
</xsl:template>
|
10591
10617
|
<!-- =============== -->
|
@@ -8,7 +8,7 @@
|
|
8
8
|
<xsl:param name="add_math_as_attachment">true</xsl:param>
|
9
9
|
<xsl:param name="final_transform">true</xsl:param>
|
10
10
|
|
11
|
-
<xsl:key name="kfn" match="*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure') and not(ancestor::*[local-name() = 'name'])
|
11
|
+
<xsl:key name="kfn" match="*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure' or local-name() = 'localized-strings')] and not(ancestor::*[local-name() = 'name']))]" use="@reference"/>
|
12
12
|
|
13
13
|
<xsl:variable name="first_pass" select="count($index//item) = 0"/>
|
14
14
|
|
@@ -6502,7 +6502,7 @@
|
|
6502
6502
|
</fn>
|
6503
6503
|
-->
|
6504
6504
|
<!-- footnotes in text (title, bibliography, main body, table's, figure's names), not for tables, figures -->
|
6505
|
-
<xsl:template match="*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure') and not(ancestor::*[local-name() = 'name'])
|
6505
|
+
<xsl:template match="*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure')] and not(ancestor::*[local-name() = 'name']))]" priority="2" name="fn">
|
6506
6506
|
|
6507
6507
|
<!-- list of footnotes to calculate actual footnotes number -->
|
6508
6508
|
<xsl:variable name="p_fn_">
|
@@ -6559,8 +6559,7 @@
|
|
6559
6559
|
</fo:basic-link>
|
6560
6560
|
</fo:inline>
|
6561
6561
|
</xsl:variable>
|
6562
|
-
|
6563
|
-
gen_id=<xsl:value-of select="$gen_id"/> -->
|
6562
|
+
|
6564
6563
|
<xsl:choose>
|
6565
6564
|
<xsl:when test="normalize-space(@skip_footnote_body) = 'true'">
|
6566
6565
|
<xsl:copy-of select="$footnote_inline"/>
|
@@ -6615,7 +6614,7 @@
|
|
6615
6614
|
<!-- commented:
|
6616
6615
|
.//*[local-name() = 'bibitem'][ancestor::*[local-name() = 'references']]/*[local-name() = 'note'] |
|
6617
6616
|
because 'fn' there is in biblio-tag -->
|
6618
|
-
<xsl:for-each select=".//*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure') and not(ancestor::*[local-name() = 'name'])
|
6617
|
+
<xsl:for-each select=".//*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure')] and not(ancestor::*[local-name() = 'name']))][generate-id(.)=generate-id(key('kfn',@reference)[1])]">
|
6619
6618
|
<!-- copy unique fn -->
|
6620
6619
|
<fn gen_id="{generate-id(.)}">
|
6621
6620
|
<xsl:copy-of select="@*"/>
|
@@ -9230,7 +9229,9 @@
|
|
9230
9229
|
|
9231
9230
|
<xsl:variable name="scale" select="java:org.metanorma.fop.Util.getImageScale($img_src, $width_effective, $height_effective)"/>
|
9232
9231
|
<xsl:if test="number($scale) < 100">
|
9233
|
-
|
9232
|
+
|
9233
|
+
<xsl:attribute name="content-width"><xsl:value-of select="$scale"/>%</xsl:attribute>
|
9234
|
+
|
9234
9235
|
</xsl:if>
|
9235
9236
|
|
9236
9237
|
</xsl:if>
|
@@ -10257,6 +10258,12 @@
|
|
10257
10258
|
</xsl:attribute>
|
10258
10259
|
</xsl:for-each>
|
10259
10260
|
|
10261
|
+
<!-- remove margin between rows in the table with sourcecode line numbers -->
|
10262
|
+
<xsl:if test="ancestor::*[local-name() = 'sourcecode'][@linenums = 'true'] and ancestor::*[local-name() = 'tr'][1]/following-sibling::*[local-name() = 'tr']">
|
10263
|
+
<xsl:attribute name="margin-top">0pt</xsl:attribute>
|
10264
|
+
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
10265
|
+
</xsl:if>
|
10266
|
+
|
10260
10267
|
<xsl:apply-templates select="node()[not(local-name() = 'name')]"/>
|
10261
10268
|
</fo:block>
|
10262
10269
|
|
@@ -10305,7 +10312,7 @@
|
|
10305
10312
|
</xsl:template>
|
10306
10313
|
|
10307
10314
|
<!-- outer table with line numbers for sourcecode -->
|
10308
|
-
<xsl:template match="*[local-name()='
|
10315
|
+
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode'] | -->
|
10309
10316
|
<fo:block>
|
10310
10317
|
<fo:table width="100%" table-layout="fixed">
|
10311
10318
|
<xsl:copy-of select="@id"/>
|
@@ -10317,16 +10324,16 @@
|
|
10317
10324
|
</fo:table>
|
10318
10325
|
</fo:block>
|
10319
10326
|
</xsl:template>
|
10320
|
-
<xsl:template match="*[local-name()='
|
10327
|
+
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']/*[local-name() = 'tbody']" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode']/*[local-name() = 'tbody'] | -->
|
10321
10328
|
<xsl:apply-templates/>
|
10322
10329
|
</xsl:template>
|
10323
|
-
<xsl:template match="*[local-name()='
|
10330
|
+
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']//*[local-name()='tr']" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode']//*[local-name()='tr'] | -->
|
10324
10331
|
<fo:table-row>
|
10325
10332
|
<xsl:apply-templates/>
|
10326
10333
|
</fo:table-row>
|
10327
10334
|
</xsl:template>
|
10328
10335
|
<!-- first td with line numbers -->
|
10329
|
-
<xsl:template match="*[local-name()='
|
10336
|
+
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']//*[local-name()='tr']/*[local-name()='td'][not(preceding-sibling::*)]" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode'] -->
|
10330
10337
|
<fo:table-cell>
|
10331
10338
|
<fo:block>
|
10332
10339
|
|
@@ -10346,8 +10353,9 @@
|
|
10346
10353
|
</fo:block>
|
10347
10354
|
</fo:table-cell>
|
10348
10355
|
</xsl:template>
|
10356
|
+
|
10349
10357
|
<!-- second td with sourcecode -->
|
10350
|
-
<xsl:template match="*[local-name()='
|
10358
|
+
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']//*[local-name()='tr']/*[local-name()='td'][preceding-sibling::*]" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode'] -->
|
10351
10359
|
<fo:table-cell>
|
10352
10360
|
<fo:block>
|
10353
10361
|
<xsl:apply-templates/>
|
@@ -10585,7 +10593,25 @@
|
|
10585
10593
|
<xsl:template match="*[local-name()='pre']" name="pre">
|
10586
10594
|
<fo:block xsl:use-attribute-sets="pre-style">
|
10587
10595
|
<xsl:copy-of select="@id"/>
|
10588
|
-
<xsl:
|
10596
|
+
<xsl:choose>
|
10597
|
+
|
10598
|
+
<xsl:when test="ancestor::*[local-name() = 'sourcecode'][@linenums = 'true'] and ancestor::*[local-name()='td'][1][not(preceding-sibling::*)]"> <!-- pre in the first td in the table with @linenums = 'true' -->
|
10599
|
+
<xsl:if test="ancestor::*[local-name() = 'tr'][1]/following-sibling::*[local-name() = 'tr']"> <!-- is current tr isn't last -->
|
10600
|
+
<xsl:attribute name="margin-top">0pt</xsl:attribute>
|
10601
|
+
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
10602
|
+
</xsl:if>
|
10603
|
+
<fo:instream-foreign-object fox:alt-text="{.}" content-width="95%">
|
10604
|
+
<math xmlns="http://www.w3.org/1998/Math/MathML">
|
10605
|
+
<mtext><xsl:value-of select="."/></mtext>
|
10606
|
+
</math>
|
10607
|
+
</fo:instream-foreign-object>
|
10608
|
+
</xsl:when>
|
10609
|
+
|
10610
|
+
<xsl:otherwise>
|
10611
|
+
<xsl:apply-templates/>
|
10612
|
+
</xsl:otherwise>
|
10613
|
+
|
10614
|
+
</xsl:choose>
|
10589
10615
|
</fo:block>
|
10590
10616
|
</xsl:template>
|
10591
10617
|
<!-- =============== -->
|
@@ -8,7 +8,7 @@
|
|
8
8
|
<xsl:param name="add_math_as_attachment">true</xsl:param>
|
9
9
|
<xsl:param name="final_transform">true</xsl:param>
|
10
10
|
|
11
|
-
<xsl:key name="kfn" match="*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure') and not(ancestor::*[local-name() = 'name'])
|
11
|
+
<xsl:key name="kfn" match="*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure' or local-name() = 'localized-strings')] and not(ancestor::*[local-name() = 'name']))]" use="@reference"/>
|
12
12
|
|
13
13
|
<xsl:variable name="first_pass" select="count($index//item) = 0"/>
|
14
14
|
|
@@ -6502,7 +6502,7 @@
|
|
6502
6502
|
</fn>
|
6503
6503
|
-->
|
6504
6504
|
<!-- footnotes in text (title, bibliography, main body, table's, figure's names), not for tables, figures -->
|
6505
|
-
<xsl:template match="*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure') and not(ancestor::*[local-name() = 'name'])
|
6505
|
+
<xsl:template match="*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure')] and not(ancestor::*[local-name() = 'name']))]" priority="2" name="fn">
|
6506
6506
|
|
6507
6507
|
<!-- list of footnotes to calculate actual footnotes number -->
|
6508
6508
|
<xsl:variable name="p_fn_">
|
@@ -6559,8 +6559,7 @@
|
|
6559
6559
|
</fo:basic-link>
|
6560
6560
|
</fo:inline>
|
6561
6561
|
</xsl:variable>
|
6562
|
-
|
6563
|
-
gen_id=<xsl:value-of select="$gen_id"/> -->
|
6562
|
+
|
6564
6563
|
<xsl:choose>
|
6565
6564
|
<xsl:when test="normalize-space(@skip_footnote_body) = 'true'">
|
6566
6565
|
<xsl:copy-of select="$footnote_inline"/>
|
@@ -6615,7 +6614,7 @@
|
|
6615
6614
|
<!-- commented:
|
6616
6615
|
.//*[local-name() = 'bibitem'][ancestor::*[local-name() = 'references']]/*[local-name() = 'note'] |
|
6617
6616
|
because 'fn' there is in biblio-tag -->
|
6618
|
-
<xsl:for-each select=".//*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure') and not(ancestor::*[local-name() = 'name'])
|
6617
|
+
<xsl:for-each select=".//*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure')] and not(ancestor::*[local-name() = 'name']))][generate-id(.)=generate-id(key('kfn',@reference)[1])]">
|
6619
6618
|
<!-- copy unique fn -->
|
6620
6619
|
<fn gen_id="{generate-id(.)}">
|
6621
6620
|
<xsl:copy-of select="@*"/>
|
@@ -9230,7 +9229,9 @@
|
|
9230
9229
|
|
9231
9230
|
<xsl:variable name="scale" select="java:org.metanorma.fop.Util.getImageScale($img_src, $width_effective, $height_effective)"/>
|
9232
9231
|
<xsl:if test="number($scale) < 100">
|
9233
|
-
|
9232
|
+
|
9233
|
+
<xsl:attribute name="content-width"><xsl:value-of select="$scale"/>%</xsl:attribute>
|
9234
|
+
|
9234
9235
|
</xsl:if>
|
9235
9236
|
|
9236
9237
|
</xsl:if>
|
@@ -10257,6 +10258,12 @@
|
|
10257
10258
|
</xsl:attribute>
|
10258
10259
|
</xsl:for-each>
|
10259
10260
|
|
10261
|
+
<!-- remove margin between rows in the table with sourcecode line numbers -->
|
10262
|
+
<xsl:if test="ancestor::*[local-name() = 'sourcecode'][@linenums = 'true'] and ancestor::*[local-name() = 'tr'][1]/following-sibling::*[local-name() = 'tr']">
|
10263
|
+
<xsl:attribute name="margin-top">0pt</xsl:attribute>
|
10264
|
+
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
10265
|
+
</xsl:if>
|
10266
|
+
|
10260
10267
|
<xsl:apply-templates select="node()[not(local-name() = 'name')]"/>
|
10261
10268
|
</fo:block>
|
10262
10269
|
|
@@ -10305,7 +10312,7 @@
|
|
10305
10312
|
</xsl:template>
|
10306
10313
|
|
10307
10314
|
<!-- outer table with line numbers for sourcecode -->
|
10308
|
-
<xsl:template match="*[local-name()='
|
10315
|
+
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode'] | -->
|
10309
10316
|
<fo:block>
|
10310
10317
|
<fo:table width="100%" table-layout="fixed">
|
10311
10318
|
<xsl:copy-of select="@id"/>
|
@@ -10317,16 +10324,16 @@
|
|
10317
10324
|
</fo:table>
|
10318
10325
|
</fo:block>
|
10319
10326
|
</xsl:template>
|
10320
|
-
<xsl:template match="*[local-name()='
|
10327
|
+
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']/*[local-name() = 'tbody']" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode']/*[local-name() = 'tbody'] | -->
|
10321
10328
|
<xsl:apply-templates/>
|
10322
10329
|
</xsl:template>
|
10323
|
-
<xsl:template match="*[local-name()='
|
10330
|
+
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']//*[local-name()='tr']" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode']//*[local-name()='tr'] | -->
|
10324
10331
|
<fo:table-row>
|
10325
10332
|
<xsl:apply-templates/>
|
10326
10333
|
</fo:table-row>
|
10327
10334
|
</xsl:template>
|
10328
10335
|
<!-- first td with line numbers -->
|
10329
|
-
<xsl:template match="*[local-name()='
|
10336
|
+
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']//*[local-name()='tr']/*[local-name()='td'][not(preceding-sibling::*)]" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode'] -->
|
10330
10337
|
<fo:table-cell>
|
10331
10338
|
<fo:block>
|
10332
10339
|
|
@@ -10346,8 +10353,9 @@
|
|
10346
10353
|
</fo:block>
|
10347
10354
|
</fo:table-cell>
|
10348
10355
|
</xsl:template>
|
10356
|
+
|
10349
10357
|
<!-- second td with sourcecode -->
|
10350
|
-
<xsl:template match="*[local-name()='
|
10358
|
+
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']//*[local-name()='tr']/*[local-name()='td'][preceding-sibling::*]" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode'] -->
|
10351
10359
|
<fo:table-cell>
|
10352
10360
|
<fo:block>
|
10353
10361
|
<xsl:apply-templates/>
|
@@ -10585,7 +10593,25 @@
|
|
10585
10593
|
<xsl:template match="*[local-name()='pre']" name="pre">
|
10586
10594
|
<fo:block xsl:use-attribute-sets="pre-style">
|
10587
10595
|
<xsl:copy-of select="@id"/>
|
10588
|
-
<xsl:
|
10596
|
+
<xsl:choose>
|
10597
|
+
|
10598
|
+
<xsl:when test="ancestor::*[local-name() = 'sourcecode'][@linenums = 'true'] and ancestor::*[local-name()='td'][1][not(preceding-sibling::*)]"> <!-- pre in the first td in the table with @linenums = 'true' -->
|
10599
|
+
<xsl:if test="ancestor::*[local-name() = 'tr'][1]/following-sibling::*[local-name() = 'tr']"> <!-- is current tr isn't last -->
|
10600
|
+
<xsl:attribute name="margin-top">0pt</xsl:attribute>
|
10601
|
+
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
10602
|
+
</xsl:if>
|
10603
|
+
<fo:instream-foreign-object fox:alt-text="{.}" content-width="95%">
|
10604
|
+
<math xmlns="http://www.w3.org/1998/Math/MathML">
|
10605
|
+
<mtext><xsl:value-of select="."/></mtext>
|
10606
|
+
</math>
|
10607
|
+
</fo:instream-foreign-object>
|
10608
|
+
</xsl:when>
|
10609
|
+
|
10610
|
+
<xsl:otherwise>
|
10611
|
+
<xsl:apply-templates/>
|
10612
|
+
</xsl:otherwise>
|
10613
|
+
|
10614
|
+
</xsl:choose>
|
10589
10615
|
</fo:block>
|
10590
10616
|
</xsl:template>
|
10591
10617
|
<!-- =============== -->
|
@@ -132,6 +132,35 @@ a.FootnoteRef + a.FootnoteRef:before {
|
|
132
132
|
color: red;
|
133
133
|
text-decoration: line-through; }
|
134
134
|
|
135
|
+
/* code highlighting with line numbers */
|
136
|
+
table.rouge-line-table td.rouge-gutter {
|
137
|
+
-moz-user-select: none;
|
138
|
+
-ms-user-select: none;
|
139
|
+
-webkit-user-select: none;
|
140
|
+
user-select: none;
|
141
|
+
padding-right: 1em; }
|
142
|
+
|
143
|
+
table.rouge-line-table td.rouge-code {
|
144
|
+
-moz-user-select: all;
|
145
|
+
-ms-user-select: all;
|
146
|
+
-webkit-user-select: all;
|
147
|
+
user-select: all; }
|
148
|
+
|
149
|
+
table.rouge-line-table,
|
150
|
+
table.rouge-line-table th,
|
151
|
+
table.rouge-line-table td {
|
152
|
+
width: auto;
|
153
|
+
border: none;
|
154
|
+
margin: 0;
|
155
|
+
padding: 0;
|
156
|
+
font-size: 100%; }
|
157
|
+
|
158
|
+
table.rouge-line-table pre {
|
159
|
+
margin: 0;
|
160
|
+
padding: 0;
|
161
|
+
overflow-x: visible;
|
162
|
+
font-size: 100%; }
|
163
|
+
|
135
164
|
#brochure-band {
|
136
165
|
background-color: #0AC442; }
|
137
166
|
|
@@ -752,7 +781,7 @@ table {
|
|
752
781
|
table th, table td {
|
753
782
|
padding: 1em; }
|
754
783
|
table td.header {
|
755
|
-
font-
|
784
|
+
font-weight: 400; }
|
756
785
|
|
757
786
|
p.TableTitle {
|
758
787
|
text-align: center;
|
@@ -4,7 +4,7 @@
|
|
4
4
|
|
5
5
|
<xsl:param name="align-cross-elements"/>
|
6
6
|
|
7
|
-
<xsl:key name="kfn" match="*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure') and not(ancestor::*[local-name() = 'name'])
|
7
|
+
<xsl:key name="kfn" match="*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure' or local-name() = 'localized-strings')] and not(ancestor::*[local-name() = 'name']))]" use="@reference"/>
|
8
8
|
|
9
9
|
<xsl:variable name="align_cross_elements_default">clause</xsl:variable>
|
10
10
|
<xsl:variable name="align_cross_elements_doc">
|
@@ -4348,7 +4348,7 @@
|
|
4348
4348
|
</fn>
|
4349
4349
|
-->
|
4350
4350
|
<!-- footnotes in text (title, bibliography, main body, table's, figure's names), not for tables, figures -->
|
4351
|
-
<xsl:template match="*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure') and not(ancestor::*[local-name() = 'name'])
|
4351
|
+
<xsl:template match="*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure')] and not(ancestor::*[local-name() = 'name']))]" priority="2" name="fn">
|
4352
4352
|
|
4353
4353
|
<!-- list of footnotes to calculate actual footnotes number -->
|
4354
4354
|
<xsl:variable name="p_fn_">
|
@@ -4405,8 +4405,7 @@
|
|
4405
4405
|
</fo:basic-link>
|
4406
4406
|
</fo:inline>
|
4407
4407
|
</xsl:variable>
|
4408
|
-
|
4409
|
-
gen_id=<xsl:value-of select="$gen_id"/> -->
|
4408
|
+
|
4410
4409
|
<xsl:choose>
|
4411
4410
|
<xsl:when test="normalize-space(@skip_footnote_body) = 'true'">
|
4412
4411
|
<xsl:copy-of select="$footnote_inline"/>
|
@@ -4461,7 +4460,7 @@
|
|
4461
4460
|
<!-- commented:
|
4462
4461
|
.//*[local-name() = 'bibitem'][ancestor::*[local-name() = 'references']]/*[local-name() = 'note'] |
|
4463
4462
|
because 'fn' there is in biblio-tag -->
|
4464
|
-
<xsl:for-each select=".//*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure') and not(ancestor::*[local-name() = 'name'])
|
4463
|
+
<xsl:for-each select=".//*[local-name() = 'fn'][not(ancestor::*[(local-name() = 'table' or local-name() = 'figure')] and not(ancestor::*[local-name() = 'name']))][generate-id(.)=generate-id(key('kfn',@reference)[1])]">
|
4465
4464
|
<!-- copy unique fn -->
|
4466
4465
|
<fn gen_id="{generate-id(.)}">
|
4467
4466
|
<xsl:copy-of select="@*"/>
|
@@ -7028,7 +7027,9 @@
|
|
7028
7027
|
|
7029
7028
|
<xsl:variable name="scale" select="java:org.metanorma.fop.Util.getImageScale($img_src, $width_effective, $height_effective)"/>
|
7030
7029
|
<xsl:if test="number($scale) < 100">
|
7031
|
-
|
7030
|
+
|
7031
|
+
<xsl:attribute name="content-width"><xsl:value-of select="$scale"/>%</xsl:attribute>
|
7032
|
+
|
7032
7033
|
</xsl:if>
|
7033
7034
|
|
7034
7035
|
</xsl:if>
|
@@ -8042,6 +8043,12 @@
|
|
8042
8043
|
</xsl:attribute>
|
8043
8044
|
</xsl:for-each>
|
8044
8045
|
|
8046
|
+
<!-- remove margin between rows in the table with sourcecode line numbers -->
|
8047
|
+
<xsl:if test="ancestor::*[local-name() = 'sourcecode'][@linenums = 'true'] and ancestor::*[local-name() = 'tr'][1]/following-sibling::*[local-name() = 'tr']">
|
8048
|
+
<xsl:attribute name="margin-top">0pt</xsl:attribute>
|
8049
|
+
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
8050
|
+
</xsl:if>
|
8051
|
+
|
8045
8052
|
<xsl:apply-templates select="node()[not(local-name() = 'name')]"/>
|
8046
8053
|
</fo:block>
|
8047
8054
|
|
@@ -8090,7 +8097,7 @@
|
|
8090
8097
|
</xsl:template>
|
8091
8098
|
|
8092
8099
|
<!-- outer table with line numbers for sourcecode -->
|
8093
|
-
<xsl:template match="*[local-name()='
|
8100
|
+
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode'] | -->
|
8094
8101
|
<fo:block>
|
8095
8102
|
<fo:table width="100%" table-layout="fixed">
|
8096
8103
|
<xsl:copy-of select="@id"/>
|
@@ -8102,16 +8109,16 @@
|
|
8102
8109
|
</fo:table>
|
8103
8110
|
</fo:block>
|
8104
8111
|
</xsl:template>
|
8105
|
-
<xsl:template match="*[local-name()='
|
8112
|
+
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']/*[local-name() = 'tbody']" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode']/*[local-name() = 'tbody'] | -->
|
8106
8113
|
<xsl:apply-templates/>
|
8107
8114
|
</xsl:template>
|
8108
|
-
<xsl:template match="*[local-name()='
|
8115
|
+
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']//*[local-name()='tr']" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode']//*[local-name()='tr'] | -->
|
8109
8116
|
<fo:table-row>
|
8110
8117
|
<xsl:apply-templates/>
|
8111
8118
|
</fo:table-row>
|
8112
8119
|
</xsl:template>
|
8113
8120
|
<!-- first td with line numbers -->
|
8114
|
-
<xsl:template match="*[local-name()='
|
8121
|
+
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']//*[local-name()='tr']/*[local-name()='td'][not(preceding-sibling::*)]" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode'] -->
|
8115
8122
|
<fo:table-cell>
|
8116
8123
|
<fo:block>
|
8117
8124
|
|
@@ -8131,8 +8138,9 @@
|
|
8131
8138
|
</fo:block>
|
8132
8139
|
</fo:table-cell>
|
8133
8140
|
</xsl:template>
|
8141
|
+
|
8134
8142
|
<!-- second td with sourcecode -->
|
8135
|
-
<xsl:template match="*[local-name()='
|
8143
|
+
<xsl:template match="*[local-name() = 'sourcecode'][@linenums = 'true']/*[local-name()='table']//*[local-name()='tr']/*[local-name()='td'][preceding-sibling::*]" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode'] -->
|
8136
8144
|
<fo:table-cell>
|
8137
8145
|
<fo:block>
|
8138
8146
|
<xsl:apply-templates/>
|
@@ -8370,7 +8378,25 @@
|
|
8370
8378
|
<xsl:template match="*[local-name()='pre']" name="pre">
|
8371
8379
|
<fo:block xsl:use-attribute-sets="pre-style">
|
8372
8380
|
<xsl:copy-of select="@id"/>
|
8373
|
-
<xsl:
|
8381
|
+
<xsl:choose>
|
8382
|
+
|
8383
|
+
<xsl:when test="ancestor::*[local-name() = 'sourcecode'][@linenums = 'true'] and ancestor::*[local-name()='td'][1][not(preceding-sibling::*)]"> <!-- pre in the first td in the table with @linenums = 'true' -->
|
8384
|
+
<xsl:if test="ancestor::*[local-name() = 'tr'][1]/following-sibling::*[local-name() = 'tr']"> <!-- is current tr isn't last -->
|
8385
|
+
<xsl:attribute name="margin-top">0pt</xsl:attribute>
|
8386
|
+
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
8387
|
+
</xsl:if>
|
8388
|
+
<fo:instream-foreign-object fox:alt-text="{.}" content-width="95%">
|
8389
|
+
<math xmlns="http://www.w3.org/1998/Math/MathML">
|
8390
|
+
<mtext><xsl:value-of select="."/></mtext>
|
8391
|
+
</math>
|
8392
|
+
</fo:instream-foreign-object>
|
8393
|
+
</xsl:when>
|
8394
|
+
|
8395
|
+
<xsl:otherwise>
|
8396
|
+
<xsl:apply-templates/>
|
8397
|
+
</xsl:otherwise>
|
8398
|
+
|
8399
|
+
</xsl:choose>
|
8374
8400
|
</fo:block>
|
8375
8401
|
</xsl:template>
|
8376
8402
|
<!-- =============== -->
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: metanorma-bipm
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.2.
|
4
|
+
version: 2.2.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ribose Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-12-
|
11
|
+
date: 2022-12-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: metanorma-generic
|