mathematical 0.6.0 → 0.6.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/ext/mathematical/mathematical.c +2 -1
- data/ext/mathematical/mtex2MML/src/y.tab.c +109 -76
- data/lib/mathematical/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ac5af68f085f96a27603c0475ededcf889e96c2b
|
4
|
+
data.tar.gz: 625f1ac930f7818ac9fdab97a464ae4edcd44594
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e28aec6f29b1a3e2b8259da6defd57aca739cfe19be54915966aed0bfcfbb0209e823b04c258ec99af1746b929e9f94d5b73c67533b6c1b6c6724de930386b56
|
7
|
+
data.tar.gz: 2c52b5a3fddd6110ac56399f75d95fcf36db2a761410008e6f1636e32289f38ff29042165efea68dcbcdf441cab8e1a5efb7b402a0a917e77b8fd0e65f6ce9e6
|
@@ -191,7 +191,8 @@ static VALUE MATHEMATICAL_process(VALUE self, VALUE rb_LatexCode) {
|
|
191
191
|
LsmDomDocument *document;
|
192
192
|
document = lsm_dom_document_new_from_memory(mathml, mathml_size, NULL);
|
193
193
|
|
194
|
-
|
194
|
+
if (mathml != NULL)
|
195
|
+
mtex2MML_free_string(mathml);
|
195
196
|
|
196
197
|
if (document == NULL) rb_raise(rb_eDocumentCreationError, "Failed to create document");
|
197
198
|
|
@@ -1353,13 +1353,13 @@ static const yytype_uint16 yyrline[] =
|
|
1353
1353
|
1705, 1710, 1714, 1719, 1724, 1729, 1734, 1739, 1744, 1749,
|
1354
1354
|
1754, 1759, 1763, 1768, 1772, 1777, 1781, 1786, 1791, 1798,
|
1355
1355
|
1806, 1819, 1832, 1842, 1854, 1863, 1873, 1880, 1888, 1895,
|
1356
|
-
1903, 1913, 1922, 1926,
|
1357
|
-
|
1358
|
-
|
1359
|
-
|
1360
|
-
|
1361
|
-
|
1362
|
-
|
1356
|
+
1903, 1913, 1922, 1926, 1935, 1947, 1956, 1965, 1974, 1983,
|
1357
|
+
1992, 2001, 2010, 2019, 2031, 2040, 2049, 2071, 2090, 2094,
|
1358
|
+
2098, 2103, 2108, 2113, 2117, 2125, 2129, 2135, 2139, 2143,
|
1359
|
+
2147, 2151, 2155, 2159, 2163, 2167, 2171, 2176, 2181, 2186,
|
1360
|
+
2191, 2196, 2201, 2206, 2211, 2216, 2221, 2228, 2232, 2238,
|
1361
|
+
2242, 2247, 2251, 2257, 2265, 2269, 2275, 2279, 2284, 2287,
|
1362
|
+
2291, 2299, 2303, 2309, 2313, 2317, 2321, 2326, 2331
|
1363
1363
|
};
|
1364
1364
|
#endif
|
1365
1365
|
|
@@ -6527,11 +6527,12 @@ yyreduce:
|
|
6527
6527
|
(yyval) = mtex2MML_copy3(s1, (yyvsp[(3) - (5)]), "</mtable></mrow>");
|
6528
6528
|
mtex2MML_free_string((yyvsp[(3) - (5)]));
|
6529
6529
|
mtex2MML_free_string(s1);
|
6530
|
+
mtex2MML_free_string(row_data);
|
6530
6531
|
}
|
6531
6532
|
break;
|
6532
6533
|
|
6533
6534
|
case 364:
|
6534
|
-
#line
|
6535
|
+
#line 1935 "mtex2MML.y"
|
6535
6536
|
{
|
6536
6537
|
char *row_data = combine_row_data(&environment_data_stack);
|
6537
6538
|
|
@@ -6542,11 +6543,12 @@ yyreduce:
|
|
6542
6543
|
mtex2MML_free_string((yyvsp[(5) - (7)]));
|
6543
6544
|
mtex2MML_free_string(s1);
|
6544
6545
|
mtex2MML_free_string(s2);
|
6546
|
+
mtex2MML_free_string(row_data);
|
6545
6547
|
}
|
6546
6548
|
break;
|
6547
6549
|
|
6548
6550
|
case 365:
|
6549
|
-
#line
|
6551
|
+
#line 1947 "mtex2MML.y"
|
6550
6552
|
{
|
6551
6553
|
char *row_data = combine_row_data(&environment_data_stack);
|
6552
6554
|
|
@@ -6554,11 +6556,12 @@ yyreduce:
|
|
6554
6556
|
(yyval) = mtex2MML_copy3(s1, (yyvsp[(3) - (5)]), "</mtable></mrow>");
|
6555
6557
|
mtex2MML_free_string((yyvsp[(3) - (5)]));
|
6556
6558
|
mtex2MML_free_string(s1);
|
6559
|
+
mtex2MML_free_string(row_data);
|
6557
6560
|
}
|
6558
6561
|
break;
|
6559
6562
|
|
6560
6563
|
case 366:
|
6561
|
-
#line
|
6564
|
+
#line 1956 "mtex2MML.y"
|
6562
6565
|
{
|
6563
6566
|
char *row_data = combine_row_data(&environment_data_stack);
|
6564
6567
|
|
@@ -6566,11 +6569,12 @@ yyreduce:
|
|
6566
6569
|
(yyval) = mtex2MML_copy3(s1, (yyvsp[(3) - (5)]), "</mtable></mrow><mo>)</mo></mrow>");
|
6567
6570
|
mtex2MML_free_string((yyvsp[(3) - (5)]));
|
6568
6571
|
mtex2MML_free_string(s1);
|
6572
|
+
mtex2MML_free_string(row_data);
|
6569
6573
|
}
|
6570
6574
|
break;
|
6571
6575
|
|
6572
6576
|
case 367:
|
6573
|
-
#line
|
6577
|
+
#line 1965 "mtex2MML.y"
|
6574
6578
|
{
|
6575
6579
|
char *row_data = combine_row_data(&environment_data_stack);
|
6576
6580
|
|
@@ -6578,11 +6582,12 @@ yyreduce:
|
|
6578
6582
|
(yyval) = mtex2MML_copy3(s1, (yyvsp[(3) - (5)]), "</mtable></mrow><mo>]</mo></mrow>");
|
6579
6583
|
mtex2MML_free_string((yyvsp[(3) - (5)]));
|
6580
6584
|
mtex2MML_free_string(s1);
|
6585
|
+
mtex2MML_free_string(row_data);
|
6581
6586
|
}
|
6582
6587
|
break;
|
6583
6588
|
|
6584
6589
|
case 368:
|
6585
|
-
#line
|
6590
|
+
#line 1974 "mtex2MML.y"
|
6586
6591
|
{
|
6587
6592
|
char *row_data = combine_row_data(&environment_data_stack);
|
6588
6593
|
|
@@ -6590,11 +6595,12 @@ yyreduce:
|
|
6590
6595
|
(yyval) = mtex2MML_copy3(s1, (yyvsp[(3) - (5)]), "</mtable></mrow><mo>∣</mo></mrow>");
|
6591
6596
|
mtex2MML_free_string((yyvsp[(3) - (5)]));
|
6592
6597
|
mtex2MML_free_string(s1);
|
6598
|
+
mtex2MML_free_string(row_data);
|
6593
6599
|
}
|
6594
6600
|
break;
|
6595
6601
|
|
6596
6602
|
case 369:
|
6597
|
-
#line
|
6603
|
+
#line 1983 "mtex2MML.y"
|
6598
6604
|
{
|
6599
6605
|
char *row_data = combine_row_data(&environment_data_stack);
|
6600
6606
|
|
@@ -6602,11 +6608,12 @@ yyreduce:
|
|
6602
6608
|
(yyval) = mtex2MML_copy3(s1, (yyvsp[(3) - (5)]), "</mtable></mrow><mo>}</mo></mrow>");
|
6603
6609
|
mtex2MML_free_string((yyvsp[(3) - (5)]));
|
6604
6610
|
mtex2MML_free_string(s1);
|
6611
|
+
mtex2MML_free_string(row_data);
|
6605
6612
|
}
|
6606
6613
|
break;
|
6607
6614
|
|
6608
6615
|
case 370:
|
6609
|
-
#line
|
6616
|
+
#line 1992 "mtex2MML.y"
|
6610
6617
|
{
|
6611
6618
|
char *row_data = combine_row_data(&environment_data_stack);
|
6612
6619
|
|
@@ -6614,11 +6621,12 @@ yyreduce:
|
|
6614
6621
|
(yyval) = mtex2MML_copy3(s1, (yyvsp[(3) - (5)]), "</mtable></mrow><mo>∥</mo></mrow>");
|
6615
6622
|
mtex2MML_free_string((yyvsp[(3) - (5)]));
|
6616
6623
|
mtex2MML_free_string(s1);
|
6624
|
+
mtex2MML_free_string(row_data);
|
6617
6625
|
}
|
6618
6626
|
break;
|
6619
6627
|
|
6620
6628
|
case 371:
|
6621
|
-
#line
|
6629
|
+
#line 2001 "mtex2MML.y"
|
6622
6630
|
{
|
6623
6631
|
char *row_data = combine_row_data(&environment_data_stack);
|
6624
6632
|
|
@@ -6626,11 +6634,12 @@ yyreduce:
|
|
6626
6634
|
(yyval) = mtex2MML_copy3(s1, (yyvsp[(3) - (5)]), "</mtable></mrow>");
|
6627
6635
|
mtex2MML_free_string((yyvsp[(3) - (5)]));
|
6628
6636
|
mtex2MML_free_string(s1);
|
6637
|
+
mtex2MML_free_string(row_data);
|
6629
6638
|
}
|
6630
6639
|
break;
|
6631
6640
|
|
6632
6641
|
case 372:
|
6633
|
-
#line
|
6642
|
+
#line 2010 "mtex2MML.y"
|
6634
6643
|
{
|
6635
6644
|
char *row_data = combine_row_data(&environment_data_stack);
|
6636
6645
|
|
@@ -6638,11 +6647,12 @@ yyreduce:
|
|
6638
6647
|
(yyval) = mtex2MML_copy3(s1, (yyvsp[(3) - (5)]), "</mtable></mrow></mrow>");
|
6639
6648
|
mtex2MML_free_string((yyvsp[(3) - (5)]));
|
6640
6649
|
mtex2MML_free_string(s1);
|
6650
|
+
mtex2MML_free_string(row_data);
|
6641
6651
|
}
|
6642
6652
|
break;
|
6643
6653
|
|
6644
6654
|
case 373:
|
6645
|
-
#line
|
6655
|
+
#line 2019 "mtex2MML.y"
|
6646
6656
|
{
|
6647
6657
|
char *row_data = combine_row_data(&environment_data_stack);
|
6648
6658
|
|
@@ -6653,11 +6663,12 @@ yyreduce:
|
|
6653
6663
|
mtex2MML_free_string((yyvsp[(5) - (7)]));
|
6654
6664
|
mtex2MML_free_string(s1);
|
6655
6665
|
mtex2MML_free_string(s2);
|
6666
|
+
mtex2MML_free_string(row_data);
|
6656
6667
|
}
|
6657
6668
|
break;
|
6658
6669
|
|
6659
6670
|
case 374:
|
6660
|
-
#line
|
6671
|
+
#line 2031 "mtex2MML.y"
|
6661
6672
|
{
|
6662
6673
|
char *row_data = combine_row_data(&environment_data_stack);
|
6663
6674
|
|
@@ -6665,11 +6676,12 @@ yyreduce:
|
|
6665
6676
|
(yyval) = mtex2MML_copy3(s1, (yyvsp[(3) - (5)]), "</mtable></mrow>");
|
6666
6677
|
mtex2MML_free_string((yyvsp[(3) - (5)]));
|
6667
6678
|
mtex2MML_free_string(s1);
|
6679
|
+
mtex2MML_free_string(row_data);
|
6668
6680
|
}
|
6669
6681
|
break;
|
6670
6682
|
|
6671
6683
|
case 375:
|
6672
|
-
#line
|
6684
|
+
#line 2040 "mtex2MML.y"
|
6673
6685
|
{
|
6674
6686
|
char *row_data = combine_row_data(&environment_data_stack);
|
6675
6687
|
|
@@ -6677,11 +6689,12 @@ yyreduce:
|
|
6677
6689
|
(yyval) = mtex2MML_copy3(s1, (yyvsp[(5) - (7)]), "</mtable></mrow>");
|
6678
6690
|
mtex2MML_free_string((yyvsp[(5) - (7)]));
|
6679
6691
|
mtex2MML_free_string(s1);
|
6692
|
+
mtex2MML_free_string(row_data);
|
6680
6693
|
}
|
6681
6694
|
break;
|
6682
6695
|
|
6683
6696
|
case 376:
|
6684
|
-
#line
|
6697
|
+
#line 2049 "mtex2MML.y"
|
6685
6698
|
{
|
6686
6699
|
const char *pipe_chars = vertical_pipe_extract((yyvsp[(5) - (9)]));
|
6687
6700
|
const char *column_align = remove_excess_pipe_chars((yyvsp[(5) - (9)]));
|
@@ -6702,11 +6715,12 @@ yyreduce:
|
|
6702
6715
|
mtex2MML_free_string((yyvsp[(7) - (9)]));
|
6703
6716
|
mtex2MML_free_string(pipe_chars);
|
6704
6717
|
mtex2MML_free_string(column_align);
|
6718
|
+
mtex2MML_free_string(row_data);
|
6705
6719
|
}
|
6706
6720
|
break;
|
6707
6721
|
|
6708
6722
|
case 377:
|
6709
|
-
#line
|
6723
|
+
#line 2071 "mtex2MML.y"
|
6710
6724
|
{
|
6711
6725
|
char *pipe_chars = vertical_pipe_extract((yyvsp[(4) - (8)]));
|
6712
6726
|
char *column_align = remove_excess_pipe_chars((yyvsp[(4) - (8)]));
|
@@ -6722,13 +6736,14 @@ yyreduce:
|
|
6722
6736
|
mtex2MML_free_string(s3);
|
6723
6737
|
mtex2MML_free_string((yyvsp[(4) - (8)]));
|
6724
6738
|
mtex2MML_free_string((yyvsp[(6) - (8)]));
|
6725
|
-
|
6726
|
-
|
6739
|
+
mtex2MML_free_string(pipe_chars);
|
6740
|
+
mtex2MML_free_string(column_align);
|
6741
|
+
mtex2MML_free_string(row_data);
|
6727
6742
|
}
|
6728
6743
|
break;
|
6729
6744
|
|
6730
6745
|
case 378:
|
6731
|
-
#line
|
6746
|
+
#line 2090 "mtex2MML.y"
|
6732
6747
|
{
|
6733
6748
|
(yyval) = mtex2MML_copy3("<semantics><annotation-xml encoding=\"SVG1.1\">", (yyvsp[(3) - (4)]), "</annotation-xml></semantics>");
|
6734
6749
|
mtex2MML_free_string((yyvsp[(3) - (4)]));
|
@@ -6736,14 +6751,14 @@ yyreduce:
|
|
6736
6751
|
break;
|
6737
6752
|
|
6738
6753
|
case 379:
|
6739
|
-
#line
|
6754
|
+
#line 2094 "mtex2MML.y"
|
6740
6755
|
{
|
6741
6756
|
(yyval) = mtex2MML_copy_string(" ");
|
6742
6757
|
}
|
6743
6758
|
break;
|
6744
6759
|
|
6745
6760
|
case 380:
|
6746
|
-
#line
|
6761
|
+
#line 2098 "mtex2MML.y"
|
6747
6762
|
{
|
6748
6763
|
(yyval) = mtex2MML_copy3((yyvsp[(1) - (2)]), " ", (yyvsp[(2) - (2)]));
|
6749
6764
|
mtex2MML_free_string((yyvsp[(1) - (2)]));
|
@@ -6752,7 +6767,7 @@ yyreduce:
|
|
6752
6767
|
break;
|
6753
6768
|
|
6754
6769
|
case 381:
|
6755
|
-
#line
|
6770
|
+
#line 2103 "mtex2MML.y"
|
6756
6771
|
{
|
6757
6772
|
(yyval) = mtex2MML_copy_string((yyvsp[(1) - (1)]));
|
6758
6773
|
mtex2MML_free_string((yyvsp[(1) - (1)]));
|
@@ -6760,7 +6775,7 @@ yyreduce:
|
|
6760
6775
|
break;
|
6761
6776
|
|
6762
6777
|
case 382:
|
6763
|
-
#line
|
6778
|
+
#line 2108 "mtex2MML.y"
|
6764
6779
|
{
|
6765
6780
|
(yyval) = mtex2MML_copy3("<mrow><mtable columnalign=\"center\" rowspacing=\"0.5ex\">", (yyvsp[(3) - (4)]), "</mtable></mrow>");
|
6766
6781
|
mtex2MML_free_string((yyvsp[(3) - (4)]));
|
@@ -6768,7 +6783,7 @@ yyreduce:
|
|
6768
6783
|
break;
|
6769
6784
|
|
6770
6785
|
case 383:
|
6771
|
-
#line
|
6786
|
+
#line 2113 "mtex2MML.y"
|
6772
6787
|
{
|
6773
6788
|
(yyval) = mtex2MML_copy3("<mrow><mtable>", (yyvsp[(3) - (4)]), "</mtable></mrow>");
|
6774
6789
|
mtex2MML_free_string((yyvsp[(3) - (4)]));
|
@@ -6776,7 +6791,7 @@ yyreduce:
|
|
6776
6791
|
break;
|
6777
6792
|
|
6778
6793
|
case 384:
|
6779
|
-
#line
|
6794
|
+
#line 2117 "mtex2MML.y"
|
6780
6795
|
{
|
6781
6796
|
char * s1 = mtex2MML_copy3("<mrow><mtable ", (yyvsp[(5) - (8)]), ">");
|
6782
6797
|
(yyval) = mtex2MML_copy3(s1, (yyvsp[(7) - (8)]), "</mtable></mrow>");
|
@@ -6787,7 +6802,7 @@ yyreduce:
|
|
6787
6802
|
break;
|
6788
6803
|
|
6789
6804
|
case 385:
|
6790
|
-
#line
|
6805
|
+
#line 2125 "mtex2MML.y"
|
6791
6806
|
{
|
6792
6807
|
(yyval) = mtex2MML_copy_string((yyvsp[(1) - (1)]));
|
6793
6808
|
mtex2MML_free_string((yyvsp[(1) - (1)]));
|
@@ -6795,7 +6810,7 @@ yyreduce:
|
|
6795
6810
|
break;
|
6796
6811
|
|
6797
6812
|
case 386:
|
6798
|
-
#line
|
6813
|
+
#line 2129 "mtex2MML.y"
|
6799
6814
|
{
|
6800
6815
|
(yyval) = mtex2MML_copy3((yyvsp[(1) - (2)]), " ", (yyvsp[(2) - (2)]));
|
6801
6816
|
mtex2MML_free_string((yyvsp[(1) - (2)]));
|
@@ -6804,7 +6819,7 @@ yyreduce:
|
|
6804
6819
|
break;
|
6805
6820
|
|
6806
6821
|
case 387:
|
6807
|
-
#line
|
6822
|
+
#line 2135 "mtex2MML.y"
|
6808
6823
|
{
|
6809
6824
|
(yyval) = mtex2MML_copy_string((yyvsp[(1) - (1)]));
|
6810
6825
|
mtex2MML_free_string((yyvsp[(1) - (1)]));
|
@@ -6812,7 +6827,7 @@ yyreduce:
|
|
6812
6827
|
break;
|
6813
6828
|
|
6814
6829
|
case 388:
|
6815
|
-
#line
|
6830
|
+
#line 2139 "mtex2MML.y"
|
6816
6831
|
{
|
6817
6832
|
(yyval) = mtex2MML_copy_string((yyvsp[(1) - (1)]));
|
6818
6833
|
mtex2MML_free_string((yyvsp[(1) - (1)]));
|
@@ -6820,7 +6835,7 @@ yyreduce:
|
|
6820
6835
|
break;
|
6821
6836
|
|
6822
6837
|
case 389:
|
6823
|
-
#line
|
6838
|
+
#line 2143 "mtex2MML.y"
|
6824
6839
|
{
|
6825
6840
|
(yyval) = mtex2MML_copy_string((yyvsp[(1) - (1)]));
|
6826
6841
|
mtex2MML_free_string((yyvsp[(1) - (1)]));
|
@@ -6828,7 +6843,7 @@ yyreduce:
|
|
6828
6843
|
break;
|
6829
6844
|
|
6830
6845
|
case 390:
|
6831
|
-
#line
|
6846
|
+
#line 2147 "mtex2MML.y"
|
6832
6847
|
{
|
6833
6848
|
(yyval) = mtex2MML_copy_string((yyvsp[(1) - (1)]));
|
6834
6849
|
mtex2MML_free_string((yyvsp[(1) - (1)]));
|
@@ -6836,7 +6851,7 @@ yyreduce:
|
|
6836
6851
|
break;
|
6837
6852
|
|
6838
6853
|
case 391:
|
6839
|
-
#line
|
6854
|
+
#line 2151 "mtex2MML.y"
|
6840
6855
|
{
|
6841
6856
|
(yyval) = mtex2MML_copy_string((yyvsp[(1) - (1)]));
|
6842
6857
|
mtex2MML_free_string((yyvsp[(1) - (1)]));
|
@@ -6844,7 +6859,7 @@ yyreduce:
|
|
6844
6859
|
break;
|
6845
6860
|
|
6846
6861
|
case 392:
|
6847
|
-
#line
|
6862
|
+
#line 2155 "mtex2MML.y"
|
6848
6863
|
{
|
6849
6864
|
(yyval) = mtex2MML_copy_string((yyvsp[(1) - (1)]));
|
6850
6865
|
mtex2MML_free_string((yyvsp[(1) - (1)]));
|
@@ -6852,7 +6867,7 @@ yyreduce:
|
|
6852
6867
|
break;
|
6853
6868
|
|
6854
6869
|
case 393:
|
6855
|
-
#line
|
6870
|
+
#line 2159 "mtex2MML.y"
|
6856
6871
|
{
|
6857
6872
|
(yyval) = mtex2MML_copy_string((yyvsp[(1) - (1)]));
|
6858
6873
|
mtex2MML_free_string((yyvsp[(1) - (1)]));
|
@@ -6860,7 +6875,7 @@ yyreduce:
|
|
6860
6875
|
break;
|
6861
6876
|
|
6862
6877
|
case 394:
|
6863
|
-
#line
|
6878
|
+
#line 2163 "mtex2MML.y"
|
6864
6879
|
{
|
6865
6880
|
(yyval) = mtex2MML_copy_string((yyvsp[(1) - (1)]));
|
6866
6881
|
mtex2MML_free_string((yyvsp[(1) - (1)]));
|
@@ -6868,7 +6883,7 @@ yyreduce:
|
|
6868
6883
|
break;
|
6869
6884
|
|
6870
6885
|
case 395:
|
6871
|
-
#line
|
6886
|
+
#line 2167 "mtex2MML.y"
|
6872
6887
|
{
|
6873
6888
|
(yyval) = mtex2MML_copy_string((yyvsp[(1) - (1)]));
|
6874
6889
|
mtex2MML_free_string((yyvsp[(1) - (1)]));
|
@@ -6876,7 +6891,7 @@ yyreduce:
|
|
6876
6891
|
break;
|
6877
6892
|
|
6878
6893
|
case 396:
|
6879
|
-
#line
|
6894
|
+
#line 2171 "mtex2MML.y"
|
6880
6895
|
{
|
6881
6896
|
(yyval) = mtex2MML_copy_string((yyvsp[(1) - (1)]));
|
6882
6897
|
mtex2MML_free_string((yyvsp[(1) - (1)]));
|
@@ -6884,7 +6899,7 @@ yyreduce:
|
|
6884
6899
|
break;
|
6885
6900
|
|
6886
6901
|
case 397:
|
6887
|
-
#line
|
6902
|
+
#line 2176 "mtex2MML.y"
|
6888
6903
|
{
|
6889
6904
|
(yyval) = mtex2MML_copy2("columnalign=", (yyvsp[(2) - (2)]));
|
6890
6905
|
mtex2MML_free_string((yyvsp[(2) - (2)]));
|
@@ -6892,7 +6907,7 @@ yyreduce:
|
|
6892
6907
|
break;
|
6893
6908
|
|
6894
6909
|
case 398:
|
6895
|
-
#line
|
6910
|
+
#line 2181 "mtex2MML.y"
|
6896
6911
|
{
|
6897
6912
|
(yyval) = mtex2MML_copy2("columnalign=", (yyvsp[(2) - (2)]));
|
6898
6913
|
mtex2MML_free_string((yyvsp[(2) - (2)]));
|
@@ -6900,7 +6915,7 @@ yyreduce:
|
|
6900
6915
|
break;
|
6901
6916
|
|
6902
6917
|
case 399:
|
6903
|
-
#line
|
6918
|
+
#line 2186 "mtex2MML.y"
|
6904
6919
|
{
|
6905
6920
|
(yyval) = mtex2MML_copy2("rowalign=", (yyvsp[(2) - (2)]));
|
6906
6921
|
mtex2MML_free_string((yyvsp[(2) - (2)]));
|
@@ -6908,7 +6923,7 @@ yyreduce:
|
|
6908
6923
|
break;
|
6909
6924
|
|
6910
6925
|
case 400:
|
6911
|
-
#line
|
6926
|
+
#line 2191 "mtex2MML.y"
|
6912
6927
|
{
|
6913
6928
|
(yyval) = mtex2MML_copy2("align=", (yyvsp[(2) - (2)]));
|
6914
6929
|
mtex2MML_free_string((yyvsp[(2) - (2)]));
|
@@ -6916,7 +6931,7 @@ yyreduce:
|
|
6916
6931
|
break;
|
6917
6932
|
|
6918
6933
|
case 401:
|
6919
|
-
#line
|
6934
|
+
#line 2196 "mtex2MML.y"
|
6920
6935
|
{
|
6921
6936
|
(yyval) = mtex2MML_copy2("equalrows=", (yyvsp[(2) - (2)]));
|
6922
6937
|
mtex2MML_free_string((yyvsp[(2) - (2)]));
|
@@ -6924,7 +6939,7 @@ yyreduce:
|
|
6924
6939
|
break;
|
6925
6940
|
|
6926
6941
|
case 402:
|
6927
|
-
#line
|
6942
|
+
#line 2201 "mtex2MML.y"
|
6928
6943
|
{
|
6929
6944
|
(yyval) = mtex2MML_copy2("equalcolumns=", (yyvsp[(2) - (2)]));
|
6930
6945
|
mtex2MML_free_string((yyvsp[(2) - (2)]));
|
@@ -6932,7 +6947,7 @@ yyreduce:
|
|
6932
6947
|
break;
|
6933
6948
|
|
6934
6949
|
case 403:
|
6935
|
-
#line
|
6950
|
+
#line 2206 "mtex2MML.y"
|
6936
6951
|
{
|
6937
6952
|
(yyval) = mtex2MML_copy2("rowlines=", (yyvsp[(2) - (2)]));
|
6938
6953
|
mtex2MML_free_string((yyvsp[(2) - (2)]));
|
@@ -6940,7 +6955,7 @@ yyreduce:
|
|
6940
6955
|
break;
|
6941
6956
|
|
6942
6957
|
case 404:
|
6943
|
-
#line
|
6958
|
+
#line 2211 "mtex2MML.y"
|
6944
6959
|
{
|
6945
6960
|
(yyval) = mtex2MML_copy2("columnlines=", (yyvsp[(2) - (2)]));
|
6946
6961
|
mtex2MML_free_string((yyvsp[(2) - (2)]));
|
@@ -6948,7 +6963,7 @@ yyreduce:
|
|
6948
6963
|
break;
|
6949
6964
|
|
6950
6965
|
case 405:
|
6951
|
-
#line
|
6966
|
+
#line 2216 "mtex2MML.y"
|
6952
6967
|
{
|
6953
6968
|
(yyval) = mtex2MML_copy2("frame=", (yyvsp[(2) - (2)]));
|
6954
6969
|
mtex2MML_free_string((yyvsp[(2) - (2)]));
|
@@ -6956,7 +6971,7 @@ yyreduce:
|
|
6956
6971
|
break;
|
6957
6972
|
|
6958
6973
|
case 406:
|
6959
|
-
#line
|
6974
|
+
#line 2221 "mtex2MML.y"
|
6960
6975
|
{
|
6961
6976
|
char * s1 = mtex2MML_copy3("rowspacing=", (yyvsp[(2) - (2)]), " columnspacing=");
|
6962
6977
|
(yyval) = mtex2MML_copy2(s1, (yyvsp[(2) - (2)]));
|
@@ -6966,7 +6981,7 @@ yyreduce:
|
|
6966
6981
|
break;
|
6967
6982
|
|
6968
6983
|
case 407:
|
6969
|
-
#line
|
6984
|
+
#line 2228 "mtex2MML.y"
|
6970
6985
|
{
|
6971
6986
|
(yyval) = mtex2MML_copy_string((yyvsp[(1) - (1)]));
|
6972
6987
|
mtex2MML_free_string((yyvsp[(1) - (1)]));
|
@@ -6974,7 +6989,7 @@ yyreduce:
|
|
6974
6989
|
break;
|
6975
6990
|
|
6976
6991
|
case 408:
|
6977
|
-
#line
|
6992
|
+
#line 2232 "mtex2MML.y"
|
6978
6993
|
{
|
6979
6994
|
(yyval) = mtex2MML_copy3((yyvsp[(1) - (3)]), " ", (yyvsp[(3) - (3)]));
|
6980
6995
|
mtex2MML_free_string((yyvsp[(1) - (3)]));
|
@@ -6983,7 +6998,7 @@ yyreduce:
|
|
6983
6998
|
break;
|
6984
6999
|
|
6985
7000
|
case 409:
|
6986
|
-
#line
|
7001
|
+
#line 2238 "mtex2MML.y"
|
6987
7002
|
{
|
6988
7003
|
(yyval) = mtex2MML_copy3("<mtr>", (yyvsp[(1) - (1)]), "</mtr>");
|
6989
7004
|
mtex2MML_free_string((yyvsp[(1) - (1)]));
|
@@ -6991,7 +7006,7 @@ yyreduce:
|
|
6991
7006
|
break;
|
6992
7007
|
|
6993
7008
|
case 410:
|
6994
|
-
#line
|
7009
|
+
#line 2242 "mtex2MML.y"
|
6995
7010
|
{
|
6996
7011
|
(yyval) = mtex2MML_copy_string((yyvsp[(1) - (1)]));
|
6997
7012
|
mtex2MML_free_string((yyvsp[(1) - (1)]));
|
@@ -6999,7 +7014,7 @@ yyreduce:
|
|
6999
7014
|
break;
|
7000
7015
|
|
7001
7016
|
case 411:
|
7002
|
-
#line
|
7017
|
+
#line 2247 "mtex2MML.y"
|
7003
7018
|
{
|
7004
7019
|
(yyval) = mtex2MML_copy_string((yyvsp[(1) - (1)]));
|
7005
7020
|
mtex2MML_free_string((yyvsp[(1) - (1)]));
|
@@ -7007,7 +7022,7 @@ yyreduce:
|
|
7007
7022
|
break;
|
7008
7023
|
|
7009
7024
|
case 412:
|
7010
|
-
#line
|
7025
|
+
#line 2251 "mtex2MML.y"
|
7011
7026
|
{
|
7012
7027
|
(yyval) = mtex2MML_copy3((yyvsp[(1) - (3)]), " ", (yyvsp[(3) - (3)]));
|
7013
7028
|
mtex2MML_free_string((yyvsp[(1) - (3)]));
|
@@ -7016,7 +7031,7 @@ yyreduce:
|
|
7016
7031
|
break;
|
7017
7032
|
|
7018
7033
|
case 413:
|
7019
|
-
#line
|
7034
|
+
#line 2257 "mtex2MML.y"
|
7020
7035
|
{
|
7021
7036
|
char * s1 = mtex2MML_copy3("<mtr ", (yyvsp[(3) - (5)]), ">");
|
7022
7037
|
(yyval) = mtex2MML_copy3(s1, (yyvsp[(5) - (5)]), "</mtr>");
|
@@ -7027,7 +7042,7 @@ yyreduce:
|
|
7027
7042
|
break;
|
7028
7043
|
|
7029
7044
|
case 414:
|
7030
|
-
#line
|
7045
|
+
#line 2265 "mtex2MML.y"
|
7031
7046
|
{
|
7032
7047
|
(yyval) = mtex2MML_copy_string((yyvsp[(1) - (1)]));
|
7033
7048
|
mtex2MML_free_string((yyvsp[(1) - (1)]));
|
@@ -7035,7 +7050,7 @@ yyreduce:
|
|
7035
7050
|
break;
|
7036
7051
|
|
7037
7052
|
case 415:
|
7038
|
-
#line
|
7053
|
+
#line 2269 "mtex2MML.y"
|
7039
7054
|
{
|
7040
7055
|
(yyval) = mtex2MML_copy3((yyvsp[(1) - (2)]), " ", (yyvsp[(2) - (2)]));
|
7041
7056
|
mtex2MML_free_string((yyvsp[(1) - (2)]));
|
@@ -7044,7 +7059,7 @@ yyreduce:
|
|
7044
7059
|
break;
|
7045
7060
|
|
7046
7061
|
case 416:
|
7047
|
-
#line
|
7062
|
+
#line 2275 "mtex2MML.y"
|
7048
7063
|
{
|
7049
7064
|
(yyval) = mtex2MML_copy_string((yyvsp[(1) - (1)]));
|
7050
7065
|
mtex2MML_free_string((yyvsp[(1) - (1)]));
|
@@ -7052,7 +7067,7 @@ yyreduce:
|
|
7052
7067
|
break;
|
7053
7068
|
|
7054
7069
|
case 417:
|
7055
|
-
#line
|
7070
|
+
#line 2279 "mtex2MML.y"
|
7056
7071
|
{
|
7057
7072
|
(yyval) = mtex2MML_copy_string((yyvsp[(1) - (1)]));
|
7058
7073
|
mtex2MML_free_string((yyvsp[(1) - (1)]));
|
@@ -7060,14 +7075,14 @@ yyreduce:
|
|
7060
7075
|
break;
|
7061
7076
|
|
7062
7077
|
case 418:
|
7063
|
-
#line
|
7078
|
+
#line 2284 "mtex2MML.y"
|
7064
7079
|
{
|
7065
7080
|
(yyval) = mtex2MML_copy_string("<mtd/>");
|
7066
7081
|
}
|
7067
7082
|
break;
|
7068
7083
|
|
7069
7084
|
case 419:
|
7070
|
-
#line
|
7085
|
+
#line 2287 "mtex2MML.y"
|
7071
7086
|
{
|
7072
7087
|
(yyval) = mtex2MML_copy3("<mtd>", (yyvsp[(1) - (1)]), "</mtd>");
|
7073
7088
|
mtex2MML_free_string((yyvsp[(1) - (1)]));
|
@@ -7075,7 +7090,7 @@ yyreduce:
|
|
7075
7090
|
break;
|
7076
7091
|
|
7077
7092
|
case 420:
|
7078
|
-
#line
|
7093
|
+
#line 2291 "mtex2MML.y"
|
7079
7094
|
{
|
7080
7095
|
char * s1 = mtex2MML_copy3("<mtd ", (yyvsp[(3) - (5)]), ">");
|
7081
7096
|
(yyval) = mtex2MML_copy3(s1, (yyvsp[(5) - (5)]), "</mtd>");
|
@@ -7086,7 +7101,7 @@ yyreduce:
|
|
7086
7101
|
break;
|
7087
7102
|
|
7088
7103
|
case 421:
|
7089
|
-
#line
|
7104
|
+
#line 2299 "mtex2MML.y"
|
7090
7105
|
{
|
7091
7106
|
(yyval) = mtex2MML_copy_string((yyvsp[(1) - (1)]));
|
7092
7107
|
mtex2MML_free_string((yyvsp[(1) - (1)]));
|
@@ -7094,7 +7109,7 @@ yyreduce:
|
|
7094
7109
|
break;
|
7095
7110
|
|
7096
7111
|
case 422:
|
7097
|
-
#line
|
7112
|
+
#line 2303 "mtex2MML.y"
|
7098
7113
|
{
|
7099
7114
|
(yyval) = mtex2MML_copy3((yyvsp[(1) - (2)]), " ", (yyvsp[(2) - (2)]));
|
7100
7115
|
mtex2MML_free_string((yyvsp[(1) - (2)]));
|
@@ -7103,7 +7118,7 @@ yyreduce:
|
|
7103
7118
|
break;
|
7104
7119
|
|
7105
7120
|
case 423:
|
7106
|
-
#line
|
7121
|
+
#line 2309 "mtex2MML.y"
|
7107
7122
|
{
|
7108
7123
|
(yyval) = mtex2MML_copy_string((yyvsp[(1) - (1)]));
|
7109
7124
|
mtex2MML_free_string((yyvsp[(1) - (1)]));
|
@@ -7111,7 +7126,7 @@ yyreduce:
|
|
7111
7126
|
break;
|
7112
7127
|
|
7113
7128
|
case 424:
|
7114
|
-
#line
|
7129
|
+
#line 2313 "mtex2MML.y"
|
7115
7130
|
{
|
7116
7131
|
(yyval) = mtex2MML_copy_string((yyvsp[(1) - (1)]));
|
7117
7132
|
mtex2MML_free_string((yyvsp[(1) - (1)]));
|
@@ -7119,7 +7134,7 @@ yyreduce:
|
|
7119
7134
|
break;
|
7120
7135
|
|
7121
7136
|
case 425:
|
7122
|
-
#line
|
7137
|
+
#line 2317 "mtex2MML.y"
|
7123
7138
|
{
|
7124
7139
|
(yyval) = mtex2MML_copy_string((yyvsp[(1) - (1)]));
|
7125
7140
|
mtex2MML_free_string((yyvsp[(1) - (1)]));
|
@@ -7127,7 +7142,7 @@ yyreduce:
|
|
7127
7142
|
break;
|
7128
7143
|
|
7129
7144
|
case 426:
|
7130
|
-
#line
|
7145
|
+
#line 2321 "mtex2MML.y"
|
7131
7146
|
{
|
7132
7147
|
(yyval) = mtex2MML_copy_string((yyvsp[(1) - (1)]));
|
7133
7148
|
mtex2MML_free_string((yyvsp[(1) - (1)]));
|
@@ -7135,7 +7150,7 @@ yyreduce:
|
|
7135
7150
|
break;
|
7136
7151
|
|
7137
7152
|
case 427:
|
7138
|
-
#line
|
7153
|
+
#line 2326 "mtex2MML.y"
|
7139
7154
|
{
|
7140
7155
|
(yyval) = mtex2MML_copy2("rowspan=", (yyvsp[(2) - (2)]));
|
7141
7156
|
mtex2MML_free_string((yyvsp[(2) - (2)]));
|
@@ -7143,7 +7158,7 @@ yyreduce:
|
|
7143
7158
|
break;
|
7144
7159
|
|
7145
7160
|
case 428:
|
7146
|
-
#line
|
7161
|
+
#line 2331 "mtex2MML.y"
|
7147
7162
|
{
|
7148
7163
|
(yyval) = mtex2MML_copy2("columnspan=", (yyvsp[(2) - (2)]));
|
7149
7164
|
mtex2MML_free_string((yyvsp[(2) - (2)]));
|
@@ -7152,7 +7167,7 @@ yyreduce:
|
|
7152
7167
|
|
7153
7168
|
|
7154
7169
|
/* Line 1267 of yacc.c. */
|
7155
|
-
#line
|
7170
|
+
#line 7171 "y.tab.c"
|
7156
7171
|
default: break;
|
7157
7172
|
}
|
7158
7173
|
YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc);
|
@@ -7366,10 +7381,28 @@ yyreturn:
|
|
7366
7381
|
}
|
7367
7382
|
|
7368
7383
|
|
7369
|
-
#line
|
7384
|
+
#line 2336 "mtex2MML.y"
|
7385
|
+
|
7386
|
+
|
7387
|
+
void envdata_copy(void *_dst, const void *_src)
|
7388
|
+
{
|
7389
|
+
envdata_t *dst = (envdata_t*)_dst, *src = (envdata_t*)_src;
|
7390
|
+
dst->rowspacing = src->rowspacing ? strdup(src->rowspacing) : NULL;
|
7391
|
+
dst->rowlines = src->rowlines ? strdup(src->rowlines) : NULL;
|
7392
|
+
}
|
7370
7393
|
|
7394
|
+
void envdata_dtor(void *_elt)
|
7395
|
+
{
|
7396
|
+
envdata_t *elt = (envdata_t*)_elt;
|
7397
|
+
if (elt->rowspacing) { free(elt->rowspacing); }
|
7398
|
+
if (elt->rowlines) { free(elt->rowlines); }
|
7399
|
+
}
|
7400
|
+
|
7401
|
+
UT_icd envdata_icd = {sizeof(envdata_t), NULL, envdata_copy, envdata_dtor};
|
7371
7402
|
|
7372
7403
|
const char *format_additions(const char *buffer) {
|
7404
|
+
utarray_new(environment_data_stack, &envdata_icd);
|
7405
|
+
|
7373
7406
|
if (colors == NULL)
|
7374
7407
|
create_css_colors(&colors);
|
7375
7408
|
|
data/lib/mathematical/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mathematical
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.6.
|
4
|
+
version: 0.6.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Garen Torikian
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2015-01-08 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake-compiler
|