mml 2.3.1 → 2.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (38) hide show
  1. checksums.yaml +4 -4
  2. data/.rubocop_todo.yml +61 -5
  3. data/lib/mml/base/common_attributes.rb +44 -0
  4. data/lib/mml/base/content/annotation.rb +0 -2
  5. data/lib/mml/base/content/share.rb +0 -2
  6. data/lib/mml/base/math.rb +10 -4
  7. data/lib/mml/base/mfrac.rb +0 -2
  8. data/lib/mml/base/mglyph.rb +0 -2
  9. data/lib/mml/base/mi.rb +4 -6
  10. data/lib/mml/base/mlabeledtr.rb +2 -2
  11. data/lib/mml/base/mn.rb +0 -2
  12. data/lib/mml/base/mo.rb +3 -1
  13. data/lib/mml/base/ms.rb +2 -2
  14. data/lib/mml/base/mspace.rb +0 -2
  15. data/lib/mml/base/mstyle.rb +2 -2
  16. data/lib/mml/base/universal_presentation_attributes.rb +4 -0
  17. data/lib/mml/base.rb +1 -0
  18. data/lib/mml/common_elements.rb +2 -0
  19. data/lib/mml/v4/a.rb +4 -2
  20. data/lib/mml/version.rb +1 -1
  21. data/schemas/README.adoc +10 -8
  22. data/schemas/mathml4/mathml4-content.rnc +382 -0
  23. data/schemas/mathml4/mathml4-core.rnc +361 -0
  24. data/schemas/mathml4/mathml4-presentation.rnc +358 -0
  25. data/schemas/mathml4/mathml4-strict-content.rnc +86 -0
  26. data/schemas/mathml4/mathml4.rnc +21 -0
  27. data/schemas/mathml4/mathml4.rnc.1 +21 -0
  28. data/schemas/mathml4/mathml4.rng +37 -0
  29. metadata +10 -11
  30. data/schemas/mathml2/CVS/Entries +0 -4
  31. data/schemas/mathml2/CVS/Repository +0 -1
  32. data/schemas/mathml2/CVS/Root +0 -1
  33. data/schemas/mathml2/common/CVS/Entries +0 -4
  34. data/schemas/mathml2/common/CVS/Repository +0 -1
  35. data/schemas/mathml2/common/CVS/Root +0 -1
  36. data/schemas/mathml2/presentation/CVS/Entries +0 -12
  37. data/schemas/mathml2/presentation/CVS/Repository +0 -1
  38. data/schemas/mathml2/presentation/CVS/Root +0 -1
@@ -0,0 +1,358 @@
1
+ # MathML 4 (Presentation)
2
+ # #######################
3
+
4
+ # Copyright 1998-2024 W3C (MIT, ERCIM, Keio, Beihang)
5
+ #
6
+ # Use and distribution of this code are permitted under the terms
7
+ # W3C Software Notice and License
8
+ # http://www.w3.org/Consortium/Legal/2002/copyright-software-20021231
9
+
10
+ default namespace m = "http://www.w3.org/1998/Math/MathML"
11
+ namespace local = ""
12
+
13
+
14
+ # MathML Core
15
+ include "mathml4-core.rnc" {
16
+
17
+ # named lengths
18
+ length-percentage = xsd:string {
19
+ pattern = '\s*((-?[0-9]*([0-9]\.?|\.[0-9])[0-9]*(r?em|ex|in|cm|mm|p[xtc]|Q|v[hw]|vmin|vmax|%))|0|(negative)?((very){0,2}thi(n|ck)|medium)mathspace)\s*'
20
+ }
21
+
22
+ mpadded-length-percentage = xsd:string {
23
+ pattern = '\s*([\+\-]?[0-9]*([0-9]\.?|\.[0-9])[0-9]*\s*((%?\s*(height|depth|width)?)|r?em|ex|in|cm|mm|p[xtc]|Q|v[hw]|vmin|vmax|%|((negative)?((very){0,2}thi(n|ck)|medium)mathspace))?)\s*'
24
+ }
25
+
26
+
27
+ }
28
+
29
+ NonMathMLAtt = attribute (* - (local:* | m:*)) {xsd:string}
30
+
31
+ MathMLPGlobalAttributes &=
32
+ NonMathMLAtt*,
33
+ attribute xref {text}?,
34
+ attribute href {xsd:anyURI}?
35
+
36
+ MathMalignExpression |= MalignExpression
37
+
38
+ MathExpression |= PresentationExpression
39
+
40
+ MstackExpression = MathMalignExpression|mscarries|msline|msrow|msgroup
41
+
42
+ MsrowExpression = MathMalignExpression|none
43
+
44
+
45
+ linestyle = "none" | "solid" | "dashed"
46
+
47
+ verticalalign =
48
+ "top" |
49
+ "bottom" |
50
+ "center" |
51
+ "baseline" |
52
+ "axis"
53
+
54
+ columnalignstyle = "left" | "center" | "right"
55
+
56
+ notationstyle =
57
+ "longdiv" |
58
+ "actuarial" |
59
+ "radical" |
60
+ "box" |
61
+ "roundedbox" |
62
+ "circle" |
63
+ "left" |
64
+ "right" |
65
+ "top" |
66
+ "bottom" |
67
+ "updiagonalstrike" |
68
+ "downdiagonalstrike" |
69
+ "verticalstrike" |
70
+ "horizontalstrike" |
71
+ "madruwb"
72
+
73
+ idref = text
74
+ unsigned-integer = xsd:unsignedLong
75
+ integer = xsd:integer
76
+ number = xsd:decimal
77
+
78
+ character = xsd:string {
79
+ pattern = '\s*\S\s*'}
80
+
81
+
82
+ positive-integer = xsd:positiveInteger
83
+
84
+
85
+ token.content |= mglyph|text
86
+
87
+
88
+
89
+ mo.attributes &=
90
+ attribute linebreak {"auto" | "newline" | "nobreak" | "goodbreak" | "badbreak"}?,
91
+ attribute lineleading {length-percentage}?,
92
+ attribute linebreakstyle {"before" | "after" | "duplicate" | "infixlinebreakstyle"}?,
93
+ attribute linebreakmultchar {text}?,
94
+ attribute indentalign {"left" | "center" | "right" | "auto" | "id"}?,
95
+ attribute indentshift {length-percentage}?,
96
+ attribute indenttarget {idref}?,
97
+ attribute indentalignfirst {"left" | "center" | "right" | "auto" | "id" | "indentalign"}?,
98
+ attribute indentshiftfirst {length-percentage | "indentshift"}?,
99
+ attribute indentalignlast {"left" | "center" | "right" | "auto" | "id" | "indentalign"}?,
100
+ attribute indentshiftlast {length-percentage | "indentshift"}?,
101
+ attribute accent {mathml-boolean}?,
102
+ attribute maxsize {"infinity"}?
103
+
104
+
105
+ mspace.attributes &=
106
+ attribute linebreak {"auto" | "newline" | "nobreak" | "goodbreak" | "badbreak" | "indentingnewline"}?,
107
+ attribute indentalign {"left" | "center" | "right" | "auto" | "id"}?,
108
+ attribute indentshift {length-percentage}?,
109
+ attribute indenttarget {idref}?,
110
+ attribute indentalignfirst {"left" | "center" | "right" | "auto" | "id" | "indentalign"}?,
111
+ attribute indentshiftfirst {length-percentage | "indentshift"}?,
112
+ attribute indentalignlast {"left" | "center" | "right" | "auto" | "id" | "indentalign"}?,
113
+ attribute indentshiftlast {length-percentage | "indentshift"}?
114
+
115
+
116
+ ms.attributes &=
117
+ attribute lquote {text}?,
118
+ attribute rquote {text}?
119
+
120
+
121
+ mglyph = element mglyph {mglyph.attributes,empty}
122
+ mglyph.attributes =
123
+ MathMLPGlobalAttributes,
124
+ attribute src {xsd:anyURI}?,
125
+ attribute width {length-percentage}?,
126
+ attribute height {length-percentage}?,
127
+ attribute valign {length-percentage}?,
128
+ attribute alt {text}?
129
+
130
+ msline = element msline {msline.attributes,empty}
131
+ msline.attributes =
132
+ MathMLPGlobalAttributes,
133
+ attribute position {integer}?,
134
+ attribute length {unsigned-integer}?,
135
+ attribute leftoverhang {length-percentage}?,
136
+ attribute rightoverhang {length-percentage}?,
137
+ attribute mslinethickness {length-percentage | "thin" | "medium" | "thick"}?
138
+
139
+ MalignExpression = maligngroup|malignmark
140
+
141
+ malignmark = element malignmark {malignmark.attributes, empty}
142
+ malignmark.attributes = MathMLPGlobalAttributes
143
+
144
+
145
+ maligngroup = element maligngroup {maligngroup.attributes, empty}
146
+ maligngroup.attributes = MathMLPGlobalAttributes
147
+
148
+
149
+ PresentationExpression = TokenExpression|
150
+ mrow|mfrac|msqrt|mroot|mstyle|merror|mpadded|mphantom|
151
+ mfenced|menclose|msub|msup|msubsup|munder|mover|munderover|
152
+ mmultiscripts|mtable|mstack|mlongdiv|maction
153
+
154
+
155
+ mrow.attributes &=
156
+ MathMLlink.attributes
157
+
158
+
159
+ mfrac.attributes &=
160
+ attribute numalign {"left" | "center" | "right"}?,
161
+ attribute denomalign {"left" | "center" | "right"}?,
162
+ attribute bevelled {mathml-boolean}?
163
+
164
+
165
+
166
+ mstyle.attributes &=
167
+ mstyle.specificattributes,
168
+ mstyle.generalattributes
169
+
170
+ mstyle.specificattributes =
171
+ attribute scriptsizemultiplier {number}?,
172
+ attribute scriptminsize {length-percentage}?,
173
+ attribute infixlinebreakstyle {"before" | "after" | "duplicate"}?,
174
+ attribute decimalpoint {character}?
175
+
176
+ mstyle.generalattributes =
177
+ attribute accent {mathml-boolean}?,
178
+ attribute accentunder {mathml-boolean}?,
179
+ attribute align {"left" | "right" | "center"}?,
180
+ attribute bevelled {mathml-boolean}?,
181
+ attribute charalign {"left" | "center" | "right"}?,
182
+ attribute charspacing {length-percentage | "loose" | "medium" | "tight"}?,
183
+ attribute close {text}?,
184
+ attribute columnalign {list {columnalignstyle+} }?,
185
+ attribute columnlines {list {linestyle +}}?,
186
+ attribute columnspacing {list {(length-percentage) +}}?,
187
+ attribute columnspan {positive-integer}?,
188
+ attribute columnwidth {list {("auto" | length-percentage | "fit") +}}?,
189
+ attribute crossout {list {("none" | "updiagonalstrike" | "downdiagonalstrike" | "verticalstrike" | "horizontalstrike")*}}?,
190
+ attribute denomalign {"left" | "center" | "right"}?,
191
+ attribute depth {length-percentage}?,
192
+ attribute dir {"ltr" | "rtl"}?,
193
+ attribute equalcolumns {mathml-boolean}?,
194
+ attribute equalrows {mathml-boolean}?,
195
+ attribute form {"prefix" | "infix" | "postfix"}?,
196
+ attribute frame {linestyle}?,
197
+ attribute framespacing {list {length-percentage, length-percentage}}?,
198
+ attribute height {length-percentage}?,
199
+ attribute indentalign {"left" | "center" | "right" | "auto" | "id"}?,
200
+ attribute indentalignfirst {"left" | "center" | "right" | "auto" | "id" | "indentalign"}?,
201
+ attribute indentalignlast {"left" | "center" | "right" | "auto" | "id" | "indentalign"}?,
202
+ attribute indentshift {length-percentage}?,
203
+ attribute indentshiftfirst {length-percentage | "indentshift"}?,
204
+ attribute indentshiftlast {length-percentage | "indentshift"}?,
205
+ attribute indenttarget {idref}?,
206
+ attribute largeop {mathml-boolean}?,
207
+ attribute leftoverhang {length-percentage}?,
208
+ attribute length {unsigned-integer}?,
209
+ attribute linebreak {"auto" | "newline" | "nobreak" | "goodbreak" | "badbreak"}?,
210
+ attribute linebreakmultchar {text}?,
211
+ attribute linebreakstyle {"before" | "after" | "duplicate" | "infixlinebreakstyle"}?,
212
+ attribute lineleading {length-percentage}?,
213
+ attribute linethickness {length-percentage | "thin" | "medium" | "thick"}?,
214
+ attribute location {"w" | "nw" | "n" | "ne" | "e" | "se" | "s" | "sw"}?,
215
+ attribute longdivstyle {"lefttop" | "stackedrightright" | "mediumstackedrightright" | "shortstackedrightright" | "righttop" | "left/\right" | "left)(right" | ":right=right" | "stackedleftleft" | "stackedleftlinetop"}?,
216
+ attribute lquote {text}?,
217
+ attribute lspace {length-percentage}?,
218
+ attribute mathsize {"small" | "normal" | "big" | length-percentage}?,
219
+ attribute mathvariant {"normal" | "bold" | "italic" | "bold-italic" | "double-struck" | "bold-fraktur" | "script" | "bold-script" | "fraktur" | "sans-serif" | "bold-sans-serif" | "sans-serif-italic" | "sans-serif-bold-italic" | "monospace" | "initial" | "tailed" | "looped" | "stretched"}?,
220
+ attribute minlabelspacing {length-percentage}?,
221
+ attribute minsize {length-percentage}?,
222
+ attribute movablelimits {mathml-boolean}?,
223
+ attribute mslinethickness {length-percentage | "thin" | "medium" | "thick"}?,
224
+ attribute notation {text}?,
225
+ attribute numalign {"left" | "center" | "right"}?,
226
+ attribute open {text}?,
227
+ attribute position {integer}?,
228
+ attribute rightoverhang {length-percentage}?,
229
+ attribute rowalign {list {verticalalign+} }?,
230
+ attribute rowlines {list {linestyle +}}?,
231
+ attribute rowspacing {list {(length-percentage) +}}?,
232
+ attribute rowspan {positive-integer}?,
233
+ attribute rquote {text}?,
234
+ attribute rspace {length-percentage}?,
235
+ attribute selection {positive-integer}?,
236
+ attribute separators {text}?,
237
+ attribute shift {integer}?,
238
+ attribute side {"left" | "right" | "leftoverlap" | "rightoverlap"}?,
239
+ attribute stackalign {"left" | "center" | "right" | "decimalpoint"}?,
240
+ attribute stretchy {mathml-boolean}?,
241
+ attribute subscriptshift {length-percentage}?,
242
+ attribute superscriptshift {length-percentage}?,
243
+ attribute symmetric {mathml-boolean}?,
244
+ attribute valign {length-percentage}?,
245
+ attribute width {length-percentage}?
246
+
247
+
248
+ math.attributes &= mstyle.specificattributes
249
+ math.attributes &= mstyle.generalattributes
250
+ math.attributes &= attribute overflow {"linebreak" | "scroll" | "elide" | "truncate" | "scale"}?
251
+
252
+ mfenced = element mfenced {mfenced.attributes, ImpliedMrow}
253
+ mfenced.attributes =
254
+ MathMLPGlobalAttributes,
255
+ attribute open {text}?,
256
+ attribute close {text}?,
257
+ attribute separators {text}?
258
+
259
+
260
+ menclose = element menclose {menclose.attributes, ImpliedMrow}
261
+ menclose.attributes =
262
+ MathMLPGlobalAttributes,
263
+ attribute notation {text}?
264
+
265
+
266
+ munder.attributes &=
267
+ attribute align {"left" | "right" | "center"}?
268
+
269
+ mover.attributes &=
270
+ attribute align {"left" | "right" | "center"}?
271
+
272
+ munderover.attributes &=
273
+ attribute align {"left" | "right" | "center"}?
274
+
275
+ msub.attributes &=
276
+ attribute subscriptshift {length-percentage}?
277
+
278
+ msup.attributes &=
279
+ attribute superscriptshift {length-percentage}?
280
+
281
+ msubsup.attributes &=
282
+ attribute subscriptshift {length-percentage}?,
283
+ attribute superscriptshift {length-percentage}?
284
+
285
+
286
+ mtable.attributes &=
287
+ attribute align {xsd:string {
288
+ pattern ='\s*(top|bottom|center|baseline|axis)(\s+-?[0-9]+)?\s*'}}?,
289
+ attribute rowalign {list {verticalalign+} }?,
290
+ attribute columnalign {list {columnalignstyle+} }?,
291
+ attribute columnwidth {list {("auto" | length-percentage | "fit") +}}?,
292
+ attribute width {"auto" | length-percentage}?,
293
+ attribute rowspacing {list {(length-percentage) +}}?,
294
+ attribute columnspacing {list {(length-percentage) +}}?,
295
+ attribute rowlines {list {linestyle +}}?,
296
+ attribute columnlines {list {linestyle +}}?,
297
+ attribute frame {linestyle}?,
298
+ attribute framespacing {list {length-percentage, length-percentage}}?,
299
+ attribute equalrows {mathml-boolean}?,
300
+ attribute equalcolumns {mathml-boolean}?,
301
+ attribute displaystyle {mathml-boolean}?
302
+
303
+
304
+ mtr.attributes &=
305
+ attribute rowalign {"top" | "bottom" | "center" | "baseline" | "axis"}?,
306
+ attribute columnalign {list {columnalignstyle+} }?
307
+
308
+
309
+ mtd.attributes &=
310
+ attribute rowalign {"top" | "bottom" | "center" | "baseline" | "axis"}?,
311
+ attribute columnalign {columnalignstyle}?
312
+
313
+
314
+ mstack = element mstack {mstack.attributes, MstackExpression*}
315
+ mstack.attributes =
316
+ MathMLPGlobalAttributes,
317
+ attribute align {xsd:string {
318
+ pattern ='\s*(top|bottom|center|baseline|axis)(\s+-?[0-9]+)?\s*'}}?,
319
+ attribute stackalign {"left" | "center" | "right" | "decimalpoint"}?,
320
+ attribute charalign {"left" | "center" | "right"}?,
321
+ attribute charspacing {length-percentage | "loose" | "medium" | "tight"}?
322
+
323
+
324
+ mlongdiv = element mlongdiv {mlongdiv.attributes, MstackExpression,MstackExpression,MstackExpression+}
325
+ mlongdiv.attributes =
326
+ msgroup.attributes,
327
+ attribute longdivstyle {"lefttop" | "stackedrightright" | "mediumstackedrightright" | "shortstackedrightright" | "righttop" | "left/\right" | "left)(right" | ":right=right" | "stackedleftleft" | "stackedleftlinetop"}?
328
+
329
+
330
+ msgroup = element msgroup {msgroup.attributes, MstackExpression*}
331
+ msgroup.attributes =
332
+ MathMLPGlobalAttributes,
333
+ attribute position {integer}?,
334
+ attribute shift {integer}?
335
+
336
+
337
+ msrow = element msrow {msrow.attributes, MsrowExpression*}
338
+ msrow.attributes =
339
+ MathMLPGlobalAttributes,
340
+ attribute position {integer}?
341
+
342
+
343
+ mscarries = element mscarries {mscarries.attributes, (MsrowExpression|mscarry)*}
344
+ mscarries.attributes =
345
+ MathMLPGlobalAttributes,
346
+ attribute position {integer}?,
347
+ attribute location {"w" | "nw" | "n" | "ne" | "e" | "se" | "s" | "sw"}?,
348
+ attribute crossout {list {("none" | "updiagonalstrike" | "downdiagonalstrike" | "verticalstrike" | "horizontalstrike")*}}?,
349
+ attribute scriptsizemultiplier {number}?
350
+
351
+
352
+ mscarry = element mscarry {mscarry.attributes, MsrowExpression*}
353
+ mscarry.attributes =
354
+ MathMLPGlobalAttributes,
355
+ attribute location {"w" | "nw" | "n" | "ne" | "e" | "se" | "s" | "sw"}?,
356
+ attribute crossout {list {("none" | "updiagonalstrike" | "downdiagonalstrike" | "verticalstrike" | "horizontalstrike")*}}?
357
+
358
+
@@ -0,0 +1,86 @@
1
+ # MathML 4 (Strict Content)
2
+ # #########################
3
+
4
+ # Copyright 1998-2024 W3C (MIT, ERCIM, Keio, Beihang)
5
+ #
6
+ # Use and distribution of this code are permitted under the terms
7
+ # W3C Software Notice and License
8
+ # http://www.w3.org/Consortium/Legal/2002/copyright-software-20021231
9
+
10
+
11
+ default namespace m = "http://www.w3.org/1998/Math/MathML"
12
+
13
+ start |= math.strict
14
+
15
+ CommonAtt =
16
+ attribute id {xsd:ID}?,
17
+ attribute xref {text}?
18
+
19
+ math.strict = element math {math.attributes,ContExp*}
20
+
21
+ math.attributes &= CommonAtt
22
+
23
+ ContExp = semantics-contexp | cn | ci | csymbol | apply | bind | share | cerror | cbytes | cs
24
+
25
+ cn = element cn {cn.attributes,cn.content}
26
+ cn.content = text
27
+ cn.attributes = CommonAtt, attribute type {"integer" | "real" | "double" | "hexdouble"}
28
+
29
+ semantics-ci = element semantics {CommonAtt,(ci|semantics-ci),
30
+ (annotation|annotation-xml)*}
31
+
32
+ semantics-contexp = element semantics {CommonAtt,MathExpression,
33
+ (annotation|annotation-xml)*}
34
+
35
+ annotation |= element annotation {CommonAtt,text}
36
+
37
+ anyElement |= element (* - m:*) {(attribute * {text}|text| anyElement)*}
38
+
39
+ annotation-xml |= element annotation-xml {annotation-xml.attributes,
40
+ (MathExpression*|anyElement*)}
41
+
42
+ annotation-xml.attributes &= CommonAtt, cd?, encoding?
43
+
44
+ encoding &= attribute encoding {xsd:string}
45
+
46
+
47
+
48
+
49
+ ci = element ci {ci.attributes, ci.content}
50
+ ci.attributes = CommonAtt, ci.type?
51
+ ci.type = attribute type {"integer" | "rational" | "real" | "complex" | "complex-polar" | "complex-cartesian" | "constant" | "function" | "vector" | "list" | "set" | "matrix"}
52
+ ci.content = text
53
+
54
+
55
+ csymbol = element csymbol {csymbol.attributes,csymbol.content}
56
+
57
+ SymbolName = xsd:NCName
58
+ csymbol.attributes = CommonAtt, cd
59
+ csymbol.content = SymbolName
60
+ cd = attribute cd {xsd:NCName}
61
+ name = attribute name {xsd:NCName}
62
+ src = attribute src {xsd:anyURI}?
63
+
64
+ BvarQ = bvar*
65
+ bvar = element bvar {CommonAtt, (ci | semantics-ci)}
66
+
67
+ apply = element apply {CommonAtt,apply.content}
68
+ apply.content = ContExp+
69
+
70
+
71
+ bind = element bind {CommonAtt,bind.content}
72
+ bind.content = ContExp,bvar*,ContExp
73
+
74
+ share = element share {CommonAtt, src, empty}
75
+
76
+ cerror = element cerror {cerror.attributes, csymbol, ContExp*}
77
+ cerror.attributes = CommonAtt
78
+
79
+ cbytes = element cbytes {cbytes.attributes, base64}
80
+ cbytes.attributes = CommonAtt
81
+ base64 = xsd:base64Binary
82
+
83
+ cs = element cs {cs.attributes, text}
84
+ cs.attributes = CommonAtt
85
+
86
+ MathExpression |= ContExp
@@ -0,0 +1,21 @@
1
+ # MathML 4 (full)
2
+ # ##############
3
+
4
+ # Copyright 1998-2024 W3C (MIT, ERCIM, Keio)
5
+ #
6
+ # Use and distribution of this code are permitted under the terms
7
+ # W3C Software Notice and License
8
+ # http://www.w3.org/Consortium/Legal/2002/copyright-software-20021231
9
+
10
+ default namespace m = "http://www.w3.org/1998/Math/MathML"
11
+
12
+ # Presentation MathML
13
+ include "mathml4-presentation.rnc" {
14
+ anyElement = element (* - m:*) {(attribute * {text}|text| anyElement)*}
15
+ }
16
+
17
+
18
+ # Content MathML
19
+ include "mathml4-content.rnc"
20
+
21
+
@@ -0,0 +1,21 @@
1
+ # MathML 4 (full)
2
+ # ##############
3
+
4
+ # Copyright 1998-2024 W3C (MIT, ERCIM, Keio)
5
+ #
6
+ # Use and distribution of this code are permitted under the terms
7
+ # W3C Software Notice and License
8
+ # http://www.w3.org/Consortium/Legal/2002/copyright-software-20021231
9
+
10
+ default namespace m = "http://www.w3.org/1998/Math/MathML"
11
+
12
+ # Presentation MathML
13
+ include "mathml4-presentation.rnc" {
14
+ anyElement = element (* - m:*) {(attribute * {text}|text| anyElement)*}
15
+ }
16
+
17
+
18
+ # Content MathML
19
+ include "mathml4-content.rnc"
20
+
21
+
@@ -0,0 +1,37 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <!--
3
+ MathML 4 (full)
4
+ ##############
5
+ -->
6
+ <!--
7
+ Copyright 1998-2024 W3C (MIT, ERCIM, Keio)
8
+
9
+ Use and distribution of this code are permitted under the terms
10
+ W3C Software Notice and License
11
+ http://www.w3.org/Consortium/Legal/2002/copyright-software-20021231
12
+ -->
13
+ <grammar ns="http://www.w3.org/1998/Math/MathML" xmlns="http://relaxng.org/ns/structure/1.0">
14
+ <!-- Presentation MathML -->
15
+ <include href="mathml4-presentation.rng">
16
+ <define name="anyElement">
17
+ <element>
18
+ <anyName>
19
+ <except>
20
+ <nsName/>
21
+ </except>
22
+ </anyName>
23
+ <zeroOrMore>
24
+ <choice>
25
+ <attribute>
26
+ <anyName/>
27
+ </attribute>
28
+ <text/>
29
+ <ref name="anyElement"/>
30
+ </choice>
31
+ </zeroOrMore>
32
+ </element>
33
+ </define>
34
+ </include>
35
+ <!-- Content MathML -->
36
+ <include href="mathml4-content.rng"/>
37
+ </grammar>
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mml
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.3.1
4
+ version: 2.3.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: 2026-04-11 00:00:00.000000000 Z
11
+ date: 2026-04-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: lutaml-model
@@ -63,6 +63,7 @@ files:
63
63
  - bin/setup
64
64
  - lib/mml.rb
65
65
  - lib/mml/base.rb
66
+ - lib/mml/base/common_attributes.rb
66
67
  - lib/mml/base/content/annotation.rb
67
68
  - lib/mml/base/content/annotation_xml.rb
68
69
  - lib/mml/base/content/apply.rb
@@ -417,12 +418,6 @@ files:
417
418
  - reference-docs/mathml-source/xml/references.xml
418
419
  - reference-docs/mathml-source/xml/validation-grammar.xml
419
420
  - schemas/README.adoc
420
- - schemas/mathml2/CVS/Entries
421
- - schemas/mathml2/CVS/Repository
422
- - schemas/mathml2/CVS/Root
423
- - schemas/mathml2/common/CVS/Entries
424
- - schemas/mathml2/common/CVS/Repository
425
- - schemas/mathml2/common/CVS/Root
426
421
  - schemas/mathml2/common/common-attribs.xsd
427
422
  - schemas/mathml2/common/math.xsd
428
423
  - schemas/mathml2/common/xlink-href.xsd
@@ -446,9 +441,6 @@ files:
446
441
  - schemas/mathml2/content/tokens.xsd.~1.3.~
447
442
  - schemas/mathml2/content/vector-calculus.xsd
448
443
  - schemas/mathml2/mathml2.xsd
449
- - schemas/mathml2/presentation/CVS/Entries
450
- - schemas/mathml2/presentation/CVS/Repository
451
- - schemas/mathml2/presentation/CVS/Root
452
444
  - schemas/mathml2/presentation/action.xsd
453
445
  - schemas/mathml2/presentation/characters.xsd
454
446
  - schemas/mathml2/presentation/common-attribs.xsd
@@ -465,6 +457,13 @@ files:
465
457
  - schemas/mathml3/mathml3-presentation.xsd
466
458
  - schemas/mathml3/mathml3-strict-content.xsd
467
459
  - schemas/mathml3/mathml3.xsd
460
+ - schemas/mathml4/mathml4-content.rnc
461
+ - schemas/mathml4/mathml4-core.rnc
462
+ - schemas/mathml4/mathml4-presentation.rnc
463
+ - schemas/mathml4/mathml4-strict-content.rnc
464
+ - schemas/mathml4/mathml4.rnc
465
+ - schemas/mathml4/mathml4.rnc.1
466
+ - schemas/mathml4/mathml4.rng
468
467
  - sig/mml.rbs
469
468
  homepage: https://github.com/plurimath/mml
470
469
  licenses:
@@ -1,4 +0,0 @@
1
- D/common////
2
- D/content////
3
- D/presentation////
4
- /mathml2.xsd/1.3/Wed May 12 16:10:20 2004//
@@ -1 +0,0 @@
1
- WWW/Math/XMLSchema/mathml2
@@ -1 +0,0 @@
1
- :ext:cvs.w3.org:/w3ccvs
@@ -1,4 +0,0 @@
1
- /xlink-href.xsd/1.2/Fri Dec 13 16:57:02 2002//
2
- /common-attribs.xsd/1.4/Wed May 12 16:10:20 2004//
3
- /math.xsd/1.4/Wed May 12 16:10:20 2004//
4
- D
@@ -1 +0,0 @@
1
- WWW/Math/XMLSchema/mathml2/common
@@ -1 +0,0 @@
1
- :ext:cvs.w3.org:/w3ccvs
@@ -1,12 +0,0 @@
1
- /action.xsd/1.4/Wed May 12 16:10:20 2004//
2
- /characters.xsd/1.3/Wed May 12 16:10:20 2004//
3
- /common-attribs.xsd/1.4/Wed May 12 16:10:20 2004//
4
- /common-types.xsd/1.3/Wed May 12 16:10:20 2004//
5
- /error.xsd/1.3/Wed May 12 16:10:20 2004//
6
- /layout.xsd/1.5/Wed May 12 16:10:20 2004//
7
- /scripts.xsd/1.5/Wed May 12 16:10:20 2004//
8
- /space.xsd/1.3/Wed May 12 16:10:20 2004//
9
- /style.xsd/1.3/Wed May 12 16:10:20 2004//
10
- /table.xsd/1.3/Wed May 12 16:10:20 2004//
11
- /tokens.xsd/1.3/Wed May 12 16:10:20 2004//
12
- D
@@ -1 +0,0 @@
1
- WWW/Math/XMLSchema/mathml2/presentation
@@ -1 +0,0 @@
1
- :ext:cvs.w3.org:/w3ccvs