mathematical 0.0.2 → 0.0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +52 -10
- data/Rakefile +42 -3
- data/lib/mathematical.rb +5 -4
- data/lib/mathematical/mathematical.bundle +0 -0
- data/lib/mathematical/render.rb +6 -5
- data/lib/mathematical/version.rb +1 -1
- data/mathematical.gemspec +5 -5
- metadata +14 -296
- data/.gitignore +0 -24
- data/.gitmodules +0 -0
- data/Gemfile +0 -4
- data/ext/mathematical/README.itex2MML.md +0 -11
- data/ext/mathematical/README.lasem.md +0 -11
- data/ext/mathematical/extconf.rb +0 -51
- data/ext/mathematical/itex2MML.h +0 -63
- data/ext/mathematical/lasemrender.c +0 -257
- data/ext/mathematical/lex.yy.c +0 -6548
- data/ext/mathematical/lsm.c +0 -30
- data/ext/mathematical/lsm.h +0 -36
- data/ext/mathematical/lsmattributes.c +0 -279
- data/ext/mathematical/lsmattributes.h +0 -75
- data/ext/mathematical/lsmcairo.c +0 -598
- data/ext/mathematical/lsmcairo.h +0 -51
- data/ext/mathematical/lsmdebug.c +0 -179
- data/ext/mathematical/lsmdebug.h +0 -76
- data/ext/mathematical/lsmdom.h +0 -43
- data/ext/mathematical/lsmdomcharacterdata.c +0 -114
- data/ext/mathematical/lsmdomcharacterdata.h +0 -59
- data/ext/mathematical/lsmdomdocument.c +0 -292
- data/ext/mathematical/lsmdomdocument.h +0 -82
- data/ext/mathematical/lsmdomdocumentfragment.c +0 -81
- data/ext/mathematical/lsmdomdocumentfragment.h +0 -55
- data/ext/mathematical/lsmdomelement.c +0 -148
- data/ext/mathematical/lsmdomelement.h +0 -62
- data/ext/mathematical/lsmdomentities.c +0 -2155
- data/ext/mathematical/lsmdomentities.h +0 -35
- data/ext/mathematical/lsmdomenumtypes.c +0 -99
- data/ext/mathematical/lsmdomenumtypes.c.template +0 -39
- data/ext/mathematical/lsmdomenumtypes.h +0 -26
- data/ext/mathematical/lsmdomenumtypes.h.template +0 -26
- data/ext/mathematical/lsmdomimplementation.c +0 -82
- data/ext/mathematical/lsmdomimplementation.h +0 -41
- data/ext/mathematical/lsmdomnamednodemap.c +0 -118
- data/ext/mathematical/lsmdomnamednodemap.h +0 -64
- data/ext/mathematical/lsmdomnode.c +0 -725
- data/ext/mathematical/lsmdomnode.h +0 -120
- data/ext/mathematical/lsmdomnodelist.c +0 -70
- data/ext/mathematical/lsmdomnodelist.h +0 -58
- data/ext/mathematical/lsmdomparser.c +0 -461
- data/ext/mathematical/lsmdomparser.h +0 -54
- data/ext/mathematical/lsmdomtext.c +0 -82
- data/ext/mathematical/lsmdomtext.h +0 -55
- data/ext/mathematical/lsmdomtypes.h +0 -44
- data/ext/mathematical/lsmdomview.c +0 -422
- data/ext/mathematical/lsmdomview.h +0 -94
- data/ext/mathematical/lsmmathml.h +0 -66
- data/ext/mathematical/lsmmathmlactionelement.c +0 -93
- data/ext/mathematical/lsmmathmlactionelement.h +0 -57
- data/ext/mathematical/lsmmathmlaligngroupelement.c +0 -102
- data/ext/mathematical/lsmmathmlaligngroupelement.h +0 -56
- data/ext/mathematical/lsmmathmlalignmarkelement.c +0 -102
- data/ext/mathematical/lsmmathmlalignmarkelement.h +0 -56
- data/ext/mathematical/lsmmathmlattributes.c +0 -197
- data/ext/mathematical/lsmmathmlattributes.h +0 -126
- data/ext/mathematical/lsmmathmldocument.c +0 -306
- data/ext/mathematical/lsmmathmldocument.h +0 -61
- data/ext/mathematical/lsmmathmlelement.c +0 -491
- data/ext/mathematical/lsmmathmlelement.h +0 -107
- data/ext/mathematical/lsmmathmlenums.c +0 -429
- data/ext/mathematical/lsmmathmlenums.h +0 -182
- data/ext/mathematical/lsmmathmlenumtypes.c +0 -666
- data/ext/mathematical/lsmmathmlenumtypes.c.template +0 -39
- data/ext/mathematical/lsmmathmlenumtypes.h +0 -90
- data/ext/mathematical/lsmmathmlenumtypes.h.template +0 -26
- data/ext/mathematical/lsmmathmlerrorelement.c +0 -58
- data/ext/mathematical/lsmmathmlerrorelement.h +0 -56
- data/ext/mathematical/lsmmathmlfencedelement.c +0 -178
- data/ext/mathematical/lsmmathmlfencedelement.h +0 -65
- data/ext/mathematical/lsmmathmlfractionelement.c +0 -253
- data/ext/mathematical/lsmmathmlfractionelement.h +0 -62
- data/ext/mathematical/lsmmathmlglyphtableams.c +0 -597
- data/ext/mathematical/lsmmathmlglyphtableams.h +0 -45
- data/ext/mathematical/lsmmathmlitexelement.c +0 -187
- data/ext/mathematical/lsmmathmlitexelement.h +0 -60
- data/ext/mathematical/lsmmathmllayoututils.c +0 -191
- data/ext/mathematical/lsmmathmllayoututils.h +0 -58
- data/ext/mathematical/lsmmathmlmathelement.c +0 -204
- data/ext/mathematical/lsmmathmlmathelement.h +0 -81
- data/ext/mathematical/lsmmathmloperatordictionary.c +0 -3332
- data/ext/mathematical/lsmmathmloperatordictionary.h +0 -54
- data/ext/mathematical/lsmmathmloperatorelement.c +0 -307
- data/ext/mathematical/lsmmathmloperatorelement.h +0 -73
- data/ext/mathematical/lsmmathmlpaddedelement.c +0 -58
- data/ext/mathematical/lsmmathmlpaddedelement.h +0 -56
- data/ext/mathematical/lsmmathmlphantomelement.c +0 -71
- data/ext/mathematical/lsmmathmlphantomelement.h +0 -56
- data/ext/mathematical/lsmmathmlpresentationcontainer.c +0 -43
- data/ext/mathematical/lsmmathmlpresentationcontainer.h +0 -54
- data/ext/mathematical/lsmmathmlpresentationtoken.c +0 -303
- data/ext/mathematical/lsmmathmlpresentationtoken.h +0 -83
- data/ext/mathematical/lsmmathmlradicalelement.c +0 -266
- data/ext/mathematical/lsmmathmlradicalelement.h +0 -71
- data/ext/mathematical/lsmmathmlrowelement.c +0 -58
- data/ext/mathematical/lsmmathmlrowelement.h +0 -56
- data/ext/mathematical/lsmmathmlscriptelement.c +0 -282
- data/ext/mathematical/lsmmathmlscriptelement.h +0 -78
- data/ext/mathematical/lsmmathmlsemanticselement.c +0 -82
- data/ext/mathematical/lsmmathmlsemanticselement.h +0 -56
- data/ext/mathematical/lsmmathmlspaceelement.c +0 -142
- data/ext/mathematical/lsmmathmlspaceelement.h +0 -60
- data/ext/mathematical/lsmmathmlstringelement.c +0 -123
- data/ext/mathematical/lsmmathmlstringelement.h +0 -58
- data/ext/mathematical/lsmmathmlstyle.c +0 -130
- data/ext/mathematical/lsmmathmlstyle.h +0 -81
- data/ext/mathematical/lsmmathmlstyleelement.c +0 -307
- data/ext/mathematical/lsmmathmlstyleelement.h +0 -87
- data/ext/mathematical/lsmmathmltablecellelement.c +0 -122
- data/ext/mathematical/lsmmathmltablecellelement.h +0 -62
- data/ext/mathematical/lsmmathmltableelement.c +0 -545
- data/ext/mathematical/lsmmathmltableelement.h +0 -78
- data/ext/mathematical/lsmmathmltablerowelement.c +0 -120
- data/ext/mathematical/lsmmathmltablerowelement.h +0 -64
- data/ext/mathematical/lsmmathmltraits.c +0 -819
- data/ext/mathematical/lsmmathmltraits.h +0 -119
- data/ext/mathematical/lsmmathmltypes.h +0 -66
- data/ext/mathematical/lsmmathmlunderoverelement.c +0 -485
- data/ext/mathematical/lsmmathmlunderoverelement.h +0 -82
- data/ext/mathematical/lsmmathmlutils.c +0 -170
- data/ext/mathematical/lsmmathmlutils.h +0 -50
- data/ext/mathematical/lsmmathmlview.c +0 -1048
- data/ext/mathematical/lsmmathmlview.h +0 -164
- data/ext/mathematical/lsmproperties.c +0 -418
- data/ext/mathematical/lsmproperties.h +0 -85
- data/ext/mathematical/lsmstr.c +0 -231
- data/ext/mathematical/lsmstr.h +0 -114
- data/ext/mathematical/lsmsvg.h +0 -67
- data/ext/mathematical/lsmsvgaelement.c +0 -73
- data/ext/mathematical/lsmsvgaelement.h +0 -55
- data/ext/mathematical/lsmsvgattributes.h +0 -113
- data/ext/mathematical/lsmsvgcircleelement.c +0 -153
- data/ext/mathematical/lsmsvgcircleelement.h +0 -59
- data/ext/mathematical/lsmsvgclippathelement.c +0 -134
- data/ext/mathematical/lsmsvgclippathelement.h +0 -59
- data/ext/mathematical/lsmsvgcolors.c +0 -212
- data/ext/mathematical/lsmsvgcolors.h +0 -39
- data/ext/mathematical/lsmsvgdefselement.c +0 -74
- data/ext/mathematical/lsmsvgdefselement.h +0 -55
- data/ext/mathematical/lsmsvgdocument.c +0 -230
- data/ext/mathematical/lsmsvgdocument.h +0 -58
- data/ext/mathematical/lsmsvgelement.c +0 -367
- data/ext/mathematical/lsmsvgelement.h +0 -81
- data/ext/mathematical/lsmsvgellipseelement.c +0 -158
- data/ext/mathematical/lsmsvgellipseelement.h +0 -60
- data/ext/mathematical/lsmsvgenums.c +0 -544
- data/ext/mathematical/lsmsvgenums.h +0 -357
- data/ext/mathematical/lsmsvgenumtypes.c +0 -1083
- data/ext/mathematical/lsmsvgenumtypes.c.template +0 -39
- data/ext/mathematical/lsmsvgenumtypes.h +0 -111
- data/ext/mathematical/lsmsvgenumtypes.h.template +0 -26
- data/ext/mathematical/lsmsvgfilterblend.c +0 -105
- data/ext/mathematical/lsmsvgfilterblend.h +0 -58
- data/ext/mathematical/lsmsvgfiltercomposite.c +0 -109
- data/ext/mathematical/lsmsvgfiltercomposite.h +0 -58
- data/ext/mathematical/lsmsvgfilterelement.c +0 -266
- data/ext/mathematical/lsmsvgfilterelement.h +0 -66
- data/ext/mathematical/lsmsvgfilterflood.c +0 -86
- data/ext/mathematical/lsmsvgfilterflood.h +0 -55
- data/ext/mathematical/lsmsvgfiltergaussianblur.c +0 -114
- data/ext/mathematical/lsmsvgfiltergaussianblur.h +0 -57
- data/ext/mathematical/lsmsvgfiltermerge.c +0 -98
- data/ext/mathematical/lsmsvgfiltermerge.h +0 -55
- data/ext/mathematical/lsmsvgfiltermergenode.c +0 -87
- data/ext/mathematical/lsmsvgfiltermergenode.h +0 -57
- data/ext/mathematical/lsmsvgfilteroffset.c +0 -112
- data/ext/mathematical/lsmsvgfilteroffset.h +0 -58
- data/ext/mathematical/lsmsvgfilterprimitive.c +0 -168
- data/ext/mathematical/lsmsvgfilterprimitive.h +0 -66
- data/ext/mathematical/lsmsvgfilterspecularlighting.c +0 -127
- data/ext/mathematical/lsmsvgfilterspecularlighting.h +0 -60
- data/ext/mathematical/lsmsvgfiltersurface.c +0 -455
- data/ext/mathematical/lsmsvgfiltersurface.h +0 -66
- data/ext/mathematical/lsmsvgfiltertile.c +0 -102
- data/ext/mathematical/lsmsvgfiltertile.h +0 -57
- data/ext/mathematical/lsmsvggelement.c +0 -73
- data/ext/mathematical/lsmsvggelement.h +0 -55
- data/ext/mathematical/lsmsvggradientelement.c +0 -151
- data/ext/mathematical/lsmsvggradientelement.h +0 -68
- data/ext/mathematical/lsmsvgimageelement.c +0 -261
- data/ext/mathematical/lsmsvgimageelement.h +0 -67
- data/ext/mathematical/lsmsvglength.c +0 -93
- data/ext/mathematical/lsmsvglength.h +0 -59
- data/ext/mathematical/lsmsvglineargradientelement.c +0 -271
- data/ext/mathematical/lsmsvglineargradientelement.h +0 -60
- data/ext/mathematical/lsmsvglineelement.c +0 -153
- data/ext/mathematical/lsmsvglineelement.h +0 -60
- data/ext/mathematical/lsmsvgmarkerelement.c +0 -266
- data/ext/mathematical/lsmsvgmarkerelement.h +0 -74
- data/ext/mathematical/lsmsvgmaskelement.c +0 -232
- data/ext/mathematical/lsmsvgmaskelement.h +0 -64
- data/ext/mathematical/lsmsvgmatrix.c +0 -205
- data/ext/mathematical/lsmsvgmatrix.h +0 -59
- data/ext/mathematical/lsmsvgpathelement.c +0 -115
- data/ext/mathematical/lsmsvgpathelement.h +0 -59
- data/ext/mathematical/lsmsvgpatternelement.c +0 -398
- data/ext/mathematical/lsmsvgpatternelement.h +0 -69
- data/ext/mathematical/lsmsvgpolygonelement.c +0 -106
- data/ext/mathematical/lsmsvgpolygonelement.h +0 -57
- data/ext/mathematical/lsmsvgpolylineelement.c +0 -106
- data/ext/mathematical/lsmsvgpolylineelement.h +0 -57
- data/ext/mathematical/lsmsvgradialgradientelement.c +0 -323
- data/ext/mathematical/lsmsvgradialgradientelement.h +0 -61
- data/ext/mathematical/lsmsvgrectelement.c +0 -184
- data/ext/mathematical/lsmsvgrectelement.h +0 -62
- data/ext/mathematical/lsmsvgstopelement.c +0 -106
- data/ext/mathematical/lsmsvgstopelement.h +0 -57
- data/ext/mathematical/lsmsvgstyle.c +0 -558
- data/ext/mathematical/lsmsvgstyle.h +0 -217
- data/ext/mathematical/lsmsvgsvgelement.c +0 -260
- data/ext/mathematical/lsmsvgsvgelement.h +0 -71
- data/ext/mathematical/lsmsvgswitchelement.c +0 -103
- data/ext/mathematical/lsmsvgswitchelement.h +0 -55
- data/ext/mathematical/lsmsvgsymbolelement.c +0 -74
- data/ext/mathematical/lsmsvgsymbolelement.h +0 -55
- data/ext/mathematical/lsmsvgtextelement.c +0 -170
- data/ext/mathematical/lsmsvgtextelement.h +0 -58
- data/ext/mathematical/lsmsvgtraits.c +0 -1158
- data/ext/mathematical/lsmsvgtraits.h +0 -103
- data/ext/mathematical/lsmsvgtransformable.c +0 -106
- data/ext/mathematical/lsmsvgtransformable.h +0 -54
- data/ext/mathematical/lsmsvgtspanelement.c +0 -143
- data/ext/mathematical/lsmsvgtspanelement.h +0 -58
- data/ext/mathematical/lsmsvgtypes.h +0 -77
- data/ext/mathematical/lsmsvguseelement.c +0 -237
- data/ext/mathematical/lsmsvguseelement.h +0 -69
- data/ext/mathematical/lsmsvgview.c +0 -2400
- data/ext/mathematical/lsmsvgview.h +0 -168
- data/ext/mathematical/lsmtraits.c +0 -119
- data/ext/mathematical/lsmtraits.h +0 -49
- data/ext/mathematical/lsmtypes.h +0 -36
- data/ext/mathematical/lsmutils.c +0 -54
- data/ext/mathematical/lsmutils.h +0 -56
- data/ext/mathematical/mathematical.c +0 -122
- data/ext/mathematical/y.tab.c +0 -6179
- data/ext/mathematical/y.tab.h +0 -389
- data/script/bench +0 -21
- data/script/bootstrap +0 -9
- data/script/single_test +0 -7
- data/test/mathematical/basic_test.rb +0 -38
- data/test/mathematical/fixtures/after/brackets_display.html +0 -1
- data/test/mathematical/fixtures/after/dollar_sign_inline.html +0 -1
- data/test/mathematical/fixtures/after/equation_display.html +0 -1
- data/test/mathematical/fixtures/after/multiple_dollar_inline.html +0 -1
- data/test/mathematical/fixtures/after/parens_inline.html +0 -1
- data/test/mathematical/fixtures/before/brackets_display.text +0 -1
- data/test/mathematical/fixtures/before/dollar_sign_inline.text +0 -1
- data/test/mathematical/fixtures/before/equation_display.text +0 -1
- data/test/mathematical/fixtures/before/multiple_dollar_inline.text +0 -1
- data/test/mathematical/fixtures/before/parens_inline.text +0 -1
- data/test/mathematical/fixtures/performance/big_file.text +0 -1767
- data/test/mathematical/fixtures_test.rb +0 -31
- data/test/mathematical/performance_test.rb +0 -13
- data/test/test_helper.rb +0 -4
data/ext/mathematical/y.tab.h
DELETED
@@ -1,389 +0,0 @@
|
|
1
|
-
/* A Bison parser, made by GNU Bison 2.3. */
|
2
|
-
|
3
|
-
/* Skeleton interface for Bison's Yacc-like parsers in C
|
4
|
-
|
5
|
-
Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006
|
6
|
-
Free Software Foundation, Inc.
|
7
|
-
|
8
|
-
This program is free software; you can redistribute it and/or modify
|
9
|
-
it under the terms of the GNU General Public License as published by
|
10
|
-
the Free Software Foundation; either version 2, or (at your option)
|
11
|
-
any later version.
|
12
|
-
|
13
|
-
This program is distributed in the hope that it will be useful,
|
14
|
-
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
15
|
-
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
16
|
-
GNU General Public License for more details.
|
17
|
-
|
18
|
-
You should have received a copy of the GNU General Public License
|
19
|
-
along with this program; if not, write to the Free Software
|
20
|
-
Foundation, Inc., 51 Franklin Street, Fifth Floor,
|
21
|
-
Boston, MA 02110-1301, USA. */
|
22
|
-
|
23
|
-
/* As a special exception, you may create a larger work that contains
|
24
|
-
part or all of the Bison parser skeleton and distribute that work
|
25
|
-
under terms of your choice, so long as that work isn't itself a
|
26
|
-
parser generator using the skeleton or a modified version thereof
|
27
|
-
as a parser skeleton. Alternatively, if you modify or redistribute
|
28
|
-
the parser skeleton itself, you may (at your option) remove this
|
29
|
-
special exception, which will cause the skeleton and the resulting
|
30
|
-
Bison output files to be licensed under the GNU General Public
|
31
|
-
License without this special exception.
|
32
|
-
|
33
|
-
This special exception was added by the Free Software Foundation in
|
34
|
-
version 2.2 of Bison. */
|
35
|
-
|
36
|
-
/* Tokens. */
|
37
|
-
#ifndef YYTOKENTYPE
|
38
|
-
# define YYTOKENTYPE
|
39
|
-
/* Put the tokens into the symbol table, so that GDB and other debuggers
|
40
|
-
know about them. */
|
41
|
-
enum yytokentype {
|
42
|
-
TEXATOP = 258,
|
43
|
-
TEXOVER = 259,
|
44
|
-
CHAR = 260,
|
45
|
-
STARTMATH = 261,
|
46
|
-
STARTDMATH = 262,
|
47
|
-
ENDMATH = 263,
|
48
|
-
MI = 264,
|
49
|
-
MIB = 265,
|
50
|
-
MN = 266,
|
51
|
-
MO = 267,
|
52
|
-
SUP = 268,
|
53
|
-
SUB = 269,
|
54
|
-
MROWOPEN = 270,
|
55
|
-
MROWCLOSE = 271,
|
56
|
-
LEFT = 272,
|
57
|
-
RIGHT = 273,
|
58
|
-
BIG = 274,
|
59
|
-
BBIG = 275,
|
60
|
-
BIGG = 276,
|
61
|
-
BBIGG = 277,
|
62
|
-
BIGL = 278,
|
63
|
-
BBIGL = 279,
|
64
|
-
BIGGL = 280,
|
65
|
-
BBIGGL = 281,
|
66
|
-
FRAC = 282,
|
67
|
-
TFRAC = 283,
|
68
|
-
OPERATORNAME = 284,
|
69
|
-
MATHOP = 285,
|
70
|
-
MATHBIN = 286,
|
71
|
-
MATHREL = 287,
|
72
|
-
MOP = 288,
|
73
|
-
MOL = 289,
|
74
|
-
MOLL = 290,
|
75
|
-
MOF = 291,
|
76
|
-
MOR = 292,
|
77
|
-
PERIODDELIM = 293,
|
78
|
-
OTHERDELIM = 294,
|
79
|
-
LEFTDELIM = 295,
|
80
|
-
RIGHTDELIM = 296,
|
81
|
-
MOS = 297,
|
82
|
-
MOB = 298,
|
83
|
-
SQRT = 299,
|
84
|
-
ROOT = 300,
|
85
|
-
BINOM = 301,
|
86
|
-
TBINOM = 302,
|
87
|
-
UNDER = 303,
|
88
|
-
OVER = 304,
|
89
|
-
OVERBRACE = 305,
|
90
|
-
UNDERLINE = 306,
|
91
|
-
UNDERBRACE = 307,
|
92
|
-
UNDEROVER = 308,
|
93
|
-
TENSOR = 309,
|
94
|
-
MULTI = 310,
|
95
|
-
ARRAYALIGN = 311,
|
96
|
-
COLUMNALIGN = 312,
|
97
|
-
ARRAY = 313,
|
98
|
-
COLSEP = 314,
|
99
|
-
ROWSEP = 315,
|
100
|
-
ARRAYOPTS = 316,
|
101
|
-
COLLAYOUT = 317,
|
102
|
-
COLALIGN = 318,
|
103
|
-
ROWALIGN = 319,
|
104
|
-
ALIGN = 320,
|
105
|
-
EQROWS = 321,
|
106
|
-
EQCOLS = 322,
|
107
|
-
ROWLINES = 323,
|
108
|
-
COLLINES = 324,
|
109
|
-
FRAME = 325,
|
110
|
-
PADDING = 326,
|
111
|
-
ATTRLIST = 327,
|
112
|
-
ITALICS = 328,
|
113
|
-
SANS = 329,
|
114
|
-
TT = 330,
|
115
|
-
BOLD = 331,
|
116
|
-
BOXED = 332,
|
117
|
-
SLASHED = 333,
|
118
|
-
RM = 334,
|
119
|
-
BB = 335,
|
120
|
-
ST = 336,
|
121
|
-
END = 337,
|
122
|
-
BBLOWERCHAR = 338,
|
123
|
-
BBUPPERCHAR = 339,
|
124
|
-
BBDIGIT = 340,
|
125
|
-
CALCHAR = 341,
|
126
|
-
FRAKCHAR = 342,
|
127
|
-
CAL = 343,
|
128
|
-
FRAK = 344,
|
129
|
-
CLAP = 345,
|
130
|
-
LLAP = 346,
|
131
|
-
RLAP = 347,
|
132
|
-
ROWOPTS = 348,
|
133
|
-
TEXTSIZE = 349,
|
134
|
-
SCSIZE = 350,
|
135
|
-
SCSCSIZE = 351,
|
136
|
-
DISPLAY = 352,
|
137
|
-
TEXTSTY = 353,
|
138
|
-
TEXTBOX = 354,
|
139
|
-
TEXTSTRING = 355,
|
140
|
-
XMLSTRING = 356,
|
141
|
-
CELLOPTS = 357,
|
142
|
-
ROWSPAN = 358,
|
143
|
-
COLSPAN = 359,
|
144
|
-
THINSPACE = 360,
|
145
|
-
MEDSPACE = 361,
|
146
|
-
THICKSPACE = 362,
|
147
|
-
QUAD = 363,
|
148
|
-
QQUAD = 364,
|
149
|
-
NEGSPACE = 365,
|
150
|
-
NEGMEDSPACE = 366,
|
151
|
-
NEGTHICKSPACE = 367,
|
152
|
-
PHANTOM = 368,
|
153
|
-
HREF = 369,
|
154
|
-
UNKNOWNCHAR = 370,
|
155
|
-
EMPTYMROW = 371,
|
156
|
-
STATLINE = 372,
|
157
|
-
TOOLTIP = 373,
|
158
|
-
TOGGLE = 374,
|
159
|
-
TOGGLESTART = 375,
|
160
|
-
TOGGLEEND = 376,
|
161
|
-
FGHIGHLIGHT = 377,
|
162
|
-
BGHIGHLIGHT = 378,
|
163
|
-
SPACE = 379,
|
164
|
-
INTONE = 380,
|
165
|
-
INTTWO = 381,
|
166
|
-
INTTHREE = 382,
|
167
|
-
BAR = 383,
|
168
|
-
WIDEBAR = 384,
|
169
|
-
VEC = 385,
|
170
|
-
WIDEVEC = 386,
|
171
|
-
HAT = 387,
|
172
|
-
WIDEHAT = 388,
|
173
|
-
CHECK = 389,
|
174
|
-
WIDECHECK = 390,
|
175
|
-
TILDE = 391,
|
176
|
-
WIDETILDE = 392,
|
177
|
-
DOT = 393,
|
178
|
-
DDOT = 394,
|
179
|
-
DDDOT = 395,
|
180
|
-
DDDDOT = 396,
|
181
|
-
UNARYMINUS = 397,
|
182
|
-
UNARYPLUS = 398,
|
183
|
-
BEGINENV = 399,
|
184
|
-
ENDENV = 400,
|
185
|
-
MATRIX = 401,
|
186
|
-
PMATRIX = 402,
|
187
|
-
BMATRIX = 403,
|
188
|
-
BBMATRIX = 404,
|
189
|
-
VMATRIX = 405,
|
190
|
-
VVMATRIX = 406,
|
191
|
-
SVG = 407,
|
192
|
-
ENDSVG = 408,
|
193
|
-
SMALLMATRIX = 409,
|
194
|
-
CASES = 410,
|
195
|
-
ALIGNED = 411,
|
196
|
-
GATHERED = 412,
|
197
|
-
SUBSTACK = 413,
|
198
|
-
PMOD = 414,
|
199
|
-
RMCHAR = 415,
|
200
|
-
COLOR = 416,
|
201
|
-
BGCOLOR = 417,
|
202
|
-
XARROW = 418,
|
203
|
-
OPTARGOPEN = 419,
|
204
|
-
OPTARGCLOSE = 420,
|
205
|
-
ITEXNUM = 421,
|
206
|
-
RAISEBOX = 422,
|
207
|
-
NEG = 423
|
208
|
-
};
|
209
|
-
#endif
|
210
|
-
/* Tokens. */
|
211
|
-
#define TEXATOP 258
|
212
|
-
#define TEXOVER 259
|
213
|
-
#define CHAR 260
|
214
|
-
#define STARTMATH 261
|
215
|
-
#define STARTDMATH 262
|
216
|
-
#define ENDMATH 263
|
217
|
-
#define MI 264
|
218
|
-
#define MIB 265
|
219
|
-
#define MN 266
|
220
|
-
#define MO 267
|
221
|
-
#define SUP 268
|
222
|
-
#define SUB 269
|
223
|
-
#define MROWOPEN 270
|
224
|
-
#define MROWCLOSE 271
|
225
|
-
#define LEFT 272
|
226
|
-
#define RIGHT 273
|
227
|
-
#define BIG 274
|
228
|
-
#define BBIG 275
|
229
|
-
#define BIGG 276
|
230
|
-
#define BBIGG 277
|
231
|
-
#define BIGL 278
|
232
|
-
#define BBIGL 279
|
233
|
-
#define BIGGL 280
|
234
|
-
#define BBIGGL 281
|
235
|
-
#define FRAC 282
|
236
|
-
#define TFRAC 283
|
237
|
-
#define OPERATORNAME 284
|
238
|
-
#define MATHOP 285
|
239
|
-
#define MATHBIN 286
|
240
|
-
#define MATHREL 287
|
241
|
-
#define MOP 288
|
242
|
-
#define MOL 289
|
243
|
-
#define MOLL 290
|
244
|
-
#define MOF 291
|
245
|
-
#define MOR 292
|
246
|
-
#define PERIODDELIM 293
|
247
|
-
#define OTHERDELIM 294
|
248
|
-
#define LEFTDELIM 295
|
249
|
-
#define RIGHTDELIM 296
|
250
|
-
#define MOS 297
|
251
|
-
#define MOB 298
|
252
|
-
#define SQRT 299
|
253
|
-
#define ROOT 300
|
254
|
-
#define BINOM 301
|
255
|
-
#define TBINOM 302
|
256
|
-
#define UNDER 303
|
257
|
-
#define OVER 304
|
258
|
-
#define OVERBRACE 305
|
259
|
-
#define UNDERLINE 306
|
260
|
-
#define UNDERBRACE 307
|
261
|
-
#define UNDEROVER 308
|
262
|
-
#define TENSOR 309
|
263
|
-
#define MULTI 310
|
264
|
-
#define ARRAYALIGN 311
|
265
|
-
#define COLUMNALIGN 312
|
266
|
-
#define ARRAY 313
|
267
|
-
#define COLSEP 314
|
268
|
-
#define ROWSEP 315
|
269
|
-
#define ARRAYOPTS 316
|
270
|
-
#define COLLAYOUT 317
|
271
|
-
#define COLALIGN 318
|
272
|
-
#define ROWALIGN 319
|
273
|
-
#define ALIGN 320
|
274
|
-
#define EQROWS 321
|
275
|
-
#define EQCOLS 322
|
276
|
-
#define ROWLINES 323
|
277
|
-
#define COLLINES 324
|
278
|
-
#define FRAME 325
|
279
|
-
#define PADDING 326
|
280
|
-
#define ATTRLIST 327
|
281
|
-
#define ITALICS 328
|
282
|
-
#define SANS 329
|
283
|
-
#define TT 330
|
284
|
-
#define BOLD 331
|
285
|
-
#define BOXED 332
|
286
|
-
#define SLASHED 333
|
287
|
-
#define RM 334
|
288
|
-
#define BB 335
|
289
|
-
#define ST 336
|
290
|
-
#define END 337
|
291
|
-
#define BBLOWERCHAR 338
|
292
|
-
#define BBUPPERCHAR 339
|
293
|
-
#define BBDIGIT 340
|
294
|
-
#define CALCHAR 341
|
295
|
-
#define FRAKCHAR 342
|
296
|
-
#define CAL 343
|
297
|
-
#define FRAK 344
|
298
|
-
#define CLAP 345
|
299
|
-
#define LLAP 346
|
300
|
-
#define RLAP 347
|
301
|
-
#define ROWOPTS 348
|
302
|
-
#define TEXTSIZE 349
|
303
|
-
#define SCSIZE 350
|
304
|
-
#define SCSCSIZE 351
|
305
|
-
#define DISPLAY 352
|
306
|
-
#define TEXTSTY 353
|
307
|
-
#define TEXTBOX 354
|
308
|
-
#define TEXTSTRING 355
|
309
|
-
#define XMLSTRING 356
|
310
|
-
#define CELLOPTS 357
|
311
|
-
#define ROWSPAN 358
|
312
|
-
#define COLSPAN 359
|
313
|
-
#define THINSPACE 360
|
314
|
-
#define MEDSPACE 361
|
315
|
-
#define THICKSPACE 362
|
316
|
-
#define QUAD 363
|
317
|
-
#define QQUAD 364
|
318
|
-
#define NEGSPACE 365
|
319
|
-
#define NEGMEDSPACE 366
|
320
|
-
#define NEGTHICKSPACE 367
|
321
|
-
#define PHANTOM 368
|
322
|
-
#define HREF 369
|
323
|
-
#define UNKNOWNCHAR 370
|
324
|
-
#define EMPTYMROW 371
|
325
|
-
#define STATLINE 372
|
326
|
-
#define TOOLTIP 373
|
327
|
-
#define TOGGLE 374
|
328
|
-
#define TOGGLESTART 375
|
329
|
-
#define TOGGLEEND 376
|
330
|
-
#define FGHIGHLIGHT 377
|
331
|
-
#define BGHIGHLIGHT 378
|
332
|
-
#define SPACE 379
|
333
|
-
#define INTONE 380
|
334
|
-
#define INTTWO 381
|
335
|
-
#define INTTHREE 382
|
336
|
-
#define BAR 383
|
337
|
-
#define WIDEBAR 384
|
338
|
-
#define VEC 385
|
339
|
-
#define WIDEVEC 386
|
340
|
-
#define HAT 387
|
341
|
-
#define WIDEHAT 388
|
342
|
-
#define CHECK 389
|
343
|
-
#define WIDECHECK 390
|
344
|
-
#define TILDE 391
|
345
|
-
#define WIDETILDE 392
|
346
|
-
#define DOT 393
|
347
|
-
#define DDOT 394
|
348
|
-
#define DDDOT 395
|
349
|
-
#define DDDDOT 396
|
350
|
-
#define UNARYMINUS 397
|
351
|
-
#define UNARYPLUS 398
|
352
|
-
#define BEGINENV 399
|
353
|
-
#define ENDENV 400
|
354
|
-
#define MATRIX 401
|
355
|
-
#define PMATRIX 402
|
356
|
-
#define BMATRIX 403
|
357
|
-
#define BBMATRIX 404
|
358
|
-
#define VMATRIX 405
|
359
|
-
#define VVMATRIX 406
|
360
|
-
#define SVG 407
|
361
|
-
#define ENDSVG 408
|
362
|
-
#define SMALLMATRIX 409
|
363
|
-
#define CASES 410
|
364
|
-
#define ALIGNED 411
|
365
|
-
#define GATHERED 412
|
366
|
-
#define SUBSTACK 413
|
367
|
-
#define PMOD 414
|
368
|
-
#define RMCHAR 415
|
369
|
-
#define COLOR 416
|
370
|
-
#define BGCOLOR 417
|
371
|
-
#define XARROW 418
|
372
|
-
#define OPTARGOPEN 419
|
373
|
-
#define OPTARGCLOSE 420
|
374
|
-
#define ITEXNUM 421
|
375
|
-
#define RAISEBOX 422
|
376
|
-
#define NEG 423
|
377
|
-
|
378
|
-
|
379
|
-
|
380
|
-
|
381
|
-
#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
|
382
|
-
typedef int YYSTYPE;
|
383
|
-
# define yystype YYSTYPE /* obsolescent; will be withdrawn */
|
384
|
-
# define YYSTYPE_IS_DECLARED 1
|
385
|
-
# define YYSTYPE_IS_TRIVIAL 1
|
386
|
-
#endif
|
387
|
-
|
388
|
-
extern YYSTYPE itex2MML_yylval;
|
389
|
-
|
data/script/bench
DELETED
@@ -1,21 +0,0 @@
|
|
1
|
-
#!/usr/bin/ruby
|
2
|
-
|
3
|
-
require './lib/mathematical.rb'
|
4
|
-
require 'benchmark'
|
5
|
-
|
6
|
-
include Benchmark
|
7
|
-
# number of iterations
|
8
|
-
num = ARGV[0] ? ARGV[0].to_i : 10
|
9
|
-
|
10
|
-
# we can also repeat the code itself
|
11
|
-
repeats = ARGV[1] ? ARGV[1].to_i : 1
|
12
|
-
|
13
|
-
file = File.open('test/mathematical/fixtures/performance/big_file.text').read.to_s * repeats
|
14
|
-
|
15
|
-
puts "Benchmarking....\n"
|
16
|
-
puts "Size: " + file.bytesize.to_s + " bytes\n"
|
17
|
-
puts "Iterations: " + num.to_s + "\n"
|
18
|
-
|
19
|
-
Benchmark.bm(40) do |x|
|
20
|
-
x.report("Rendering... ") { for i in 1..num; Mathematical::Render.new.render(file); end }
|
21
|
-
end
|
data/script/bootstrap
DELETED
data/script/single_test
DELETED
@@ -1,38 +0,0 @@
|
|
1
|
-
require "test_helper"
|
2
|
-
|
3
|
-
class Mathematical::BasicTest < Test::Unit::TestCase
|
4
|
-
|
5
|
-
def test_it_has_a_version
|
6
|
-
assert Mathematical::VERSION
|
7
|
-
end
|
8
|
-
|
9
|
-
def test_it_does_not_error_on_unrecognized_commands
|
10
|
-
render = Mathematical::Render.new
|
11
|
-
output = nil
|
12
|
-
assert_nothing_raised { output = render.render('$\align$') }
|
13
|
-
assert_equal output, '$\align$'
|
14
|
-
end
|
15
|
-
|
16
|
-
def test_it_does_not_blow_up_on_bad_arguments
|
17
|
-
# need to pass a hash here
|
18
|
-
assert_raise TypeError do
|
19
|
-
render = Mathematical::Render.new("not a hash")
|
20
|
-
end
|
21
|
-
|
22
|
-
# need to pass a string here
|
23
|
-
render = Mathematical::Render.new
|
24
|
-
assert_raise TypeError do
|
25
|
-
Mathematical::Render.new.render(123)
|
26
|
-
end
|
27
|
-
end
|
28
|
-
|
29
|
-
def test_it_does_not_blow_up_on_bad_options
|
30
|
-
assert_raise TypeError do
|
31
|
-
render = Mathematical::Render.new({:ppi => "not a number"})
|
32
|
-
end
|
33
|
-
|
34
|
-
assert_raise TypeError do
|
35
|
-
render = Mathematical::Render.new({:zoom => "not a number"})
|
36
|
-
end
|
37
|
-
end
|
38
|
-
end
|