rsyntaxtree 1.1.2 → 1.1.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +9 -5
- data/Rakefile +2 -0
- data/bin/rsyntaxtree +2 -2
- data/docs/_examples/000.md +25 -0
- data/docs/_examples/011.md +1 -1
- data/docs/_examples/012.md +1 -1
- data/docs/_examples/013.md +1 -1
- data/docs/_examples/014.md +1 -1
- data/docs/_examples/019.md +1 -1
- data/docs/_examples/022.md +1 -1
- data/docs/assets/img/000.png +0 -0
- data/docs/assets/img/019.png +0 -0
- data/docs/assets/img/022.png +0 -0
- data/docs/assets/svg/000.svg +64 -0
- data/docs/assets/svg/019.svg +183 -183
- data/docs/assets/svg/022.svg +73 -73
- data/docs/documentation.md +3 -2
- data/fonts/NotoSansMono_SemiCondensed-Bold.ttf +0 -0
- data/fonts/NotoSansMono_SemiCondensed-Regular.ttf +0 -0
- data/lib/rsyntaxtree/svg_graph.rb +6 -0
- data/lib/rsyntaxtree/version.rb +1 -1
- data/lib/rsyntaxtree.rb +9 -0
- data/test/example_verify_test.rb +2 -0
- metadata +7 -2
data/docs/assets/svg/022.svg
CHANGED
@@ -1,9 +1,9 @@
|
|
1
1
|
<?xml version="1.0" standalone="no"?>
|
2
2
|
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
|
3
|
-
<svg width="
|
3
|
+
<svg width="2810.8" height="2613.6" viewBox="-20, -20, 2830.8, 2633.6" version="1.1" xmlns="http://www.w3.org/2000/svg">
|
4
4
|
<defs>
|
5
|
-
<marker id="arrow" markerUnits="strokeWidth" markerWidth="
|
6
|
-
<polyline fill="none" stroke="black" stroke-width="1" points="0,
|
5
|
+
<marker id="arrow" markerUnits="strokeWidth" markerWidth="11.520000000000001" markerHeight="11.520000000000001" viewBox="0 0 11.520000000000001 11.520000000000001" refX="5.760000000000001" refY="0">
|
6
|
+
<polyline fill="none" stroke="black" stroke-width="1" points="0,11.520000000000001,5.760000000000001,0,11.520000000000001,11.520000000000001" />
|
7
7
|
</marker>
|
8
8
|
<pattern id="hatchBlack" x="10" y="10" width="10" height="10" patternUnits="userSpaceOnUse" patternTransform="rotate(45)">
|
9
9
|
<line x1="0" y="0" x2="0" y2="10" stroke="black" stroke-width="4"></line>
|
@@ -15,149 +15,149 @@
|
|
15
15
|
<line x1="0" y="0" x2="0" y2="10" stroke="black" stroke-width="4"></line>
|
16
16
|
</pattern>
|
17
17
|
</defs>
|
18
|
-
<rect x="-20" y="-20" width="
|
19
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
18
|
+
<rect x="-20" y="-20" width="2830.8" height="2633.6" stroke="none" fill="white" />"
|
19
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='1202.3' y='132.0'><tspan x='1202.3' y='132.0' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif"><expression></tspan>
|
20
20
|
</text>
|
21
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
21
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='1292.3' y='437.2'><tspan x='1292.3' y='437.2' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif"><term></tspan>
|
22
22
|
</text>
|
23
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
23
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='525.6999999999999' y='742.4'><tspan x='525.6999999999999' y='742.4' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif"><term></tspan>
|
24
24
|
</text>
|
25
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
25
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='508.19999999999993' y='1047.6'><tspan x='508.19999999999993' y='1047.6' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif"><factor></tspan>
|
26
26
|
</text>
|
27
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
27
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='28.799999999999955' y='1352.8'><tspan x='28.799999999999955' y='1352.8' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif">(</tspan>
|
28
28
|
</text>
|
29
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
29
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='480.70000000000016' y='1352.8'><tspan x='480.70000000000016' y='1352.8' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif"><expression></tspan>
|
30
30
|
</text>
|
31
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
31
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='166.00000000000023' y='1658.0'><tspan x='166.00000000000023' y='1658.0' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif"><expression></tspan>
|
32
32
|
</text>
|
33
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
33
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='256.0000000000001' y='1963.2'><tspan x='256.0000000000001' y='1963.2' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif"><term></tspan>
|
34
34
|
</text>
|
35
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
35
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='238.5000000000001' y='2268.4'><tspan x='238.5000000000001' y='2268.4' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif"><factor></tspan>
|
36
36
|
</text>
|
37
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
37
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='316.5000000000001' y='2573.6'><tspan x='344.0000000000001' y='2573.6' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif">A</tspan>
|
38
38
|
</text>
|
39
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
39
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='676.2000000000002' y='1658.0'><tspan x='691.2000000000002' y='1658.0' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif">+</tspan>
|
40
40
|
</text>
|
41
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
41
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='885.4000000000001' y='1658.0'><tspan x='885.4000000000001' y='1658.0' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif"><term></tspan>
|
42
42
|
</text>
|
43
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
43
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='867.9000000000001' y='1963.2'><tspan x='867.9000000000001' y='1963.2' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif"><factor></tspan>
|
44
44
|
</text>
|
45
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
45
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='945.9000000000001' y='2268.4'><tspan x='971.9000000000001' y='2268.4' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif">B</tspan>
|
46
46
|
</text>
|
47
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
47
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='1215.6' y='1352.8'><tspan x='1215.6' y='1352.8' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif">)</tspan>
|
48
48
|
</text>
|
49
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
49
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='1352.8' y='742.4'><tspan x='1367.8' y='742.4' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif">*</tspan>
|
50
50
|
</text>
|
51
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
51
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='2041.4' y='742.4'><tspan x='2041.4' y='742.4' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif"><factor></tspan>
|
52
52
|
</text>
|
53
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
53
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='1562.0' y='1047.6'><tspan x='1562.0' y='1047.6' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif">(</tspan>
|
54
54
|
</text>
|
55
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
55
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='2013.9' y='1047.6'><tspan x='2013.9' y='1047.6' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif"><expression></tspan>
|
56
56
|
</text>
|
57
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
57
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='1699.2000000000003' y='1352.8'><tspan x='1699.2000000000003' y='1352.8' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif"><expression></tspan>
|
58
58
|
</text>
|
59
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
59
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='1789.2000000000003' y='1658.0'><tspan x='1789.2000000000003' y='1658.0' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif"><term></tspan>
|
60
60
|
</text>
|
61
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
61
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='1771.7000000000003' y='1963.2'><tspan x='1771.7000000000003' y='1963.2' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif"><factor></tspan>
|
62
62
|
</text>
|
63
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
63
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='1849.7000000000003' y='2268.4'><tspan x='1876.2000000000003' y='2268.4' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif">C</tspan>
|
64
64
|
</text>
|
65
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
65
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='2209.4' y='1352.8'><tspan x='2224.4' y='1352.8' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif">+</tspan>
|
66
66
|
</text>
|
67
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
67
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='2418.6000000000004' y='1352.8'><tspan x='2418.6000000000004' y='1352.8' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif"><term></tspan>
|
68
68
|
</text>
|
69
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
69
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='2401.1000000000004' y='1658.0'><tspan x='2401.1000000000004' y='1658.0' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif"><factor></tspan>
|
70
70
|
</text>
|
71
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
71
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='2479.1000000000004' y='1963.2'><tspan x='2504.1000000000004' y='1963.2' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif">D</tspan>
|
72
72
|
</text>
|
73
|
-
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='
|
73
|
+
<text white-space='pre' alignment-baseline='text-top' style='fill: black; font-size: 64px;' x='2748.8' y='1047.6'><tspan x='2748.8' y='1047.6' style="" text-decoration="" font-family="'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif">)</tspan>
|
74
74
|
</text>
|
75
75
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
76
|
-
points='
|
76
|
+
points='1399.8 327.2 1399.8 257.1 1399.8 257.1 1399.8 187.0' />
|
77
77
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
78
|
-
points='
|
78
|
+
points='633.1999999999999 632.4 633.1999999999999 562.3 1399.8 562.3 1399.8 492.2' />
|
79
79
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
80
|
-
points='
|
80
|
+
points='1399.8 632.4 1399.8 562.3 1399.8 562.3 1399.8 492.2' />
|
81
81
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
82
|
-
points='
|
82
|
+
points='2166.4 632.4 2166.4 562.3 1399.8 562.3 1399.8 492.2' />
|
83
83
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
84
|
-
points='
|
84
|
+
points='633.1999999999999 937.5999999999999 633.1999999999999 867.5 633.1999999999999 867.5 633.1999999999999 797.4' />
|
85
85
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
86
|
-
points='
|
86
|
+
points='39.799999999999955 1242.8 39.799999999999955 1172.6999999999998 633.1999999999999 1172.6999999999998 633.1999999999999 1102.6' />
|
87
87
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
88
|
-
points='
|
88
|
+
points='678.2000000000002 1242.8 678.2000000000002 1172.6999999999998 633.1999999999999 1172.6999999999998 633.1999999999999 1102.6' />
|
89
89
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
90
|
-
points='
|
90
|
+
points='1226.6 1242.8 1226.6 1172.6999999999998 633.1999999999999 1172.6999999999998 633.1999999999999 1102.6' />
|
91
91
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
92
|
-
points='
|
92
|
+
points='363.5000000000002 1548.0 363.5000000000002 1477.9 678.2000000000002 1477.9 678.2000000000002 1407.8' />
|
93
93
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
94
|
-
points='
|
94
|
+
points='723.2000000000002 1548.0 723.2000000000002 1477.9 678.2000000000002 1477.9 678.2000000000002 1407.8' />
|
95
95
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
96
|
-
points='
|
96
|
+
points='992.9000000000001 1548.0 992.9000000000001 1477.9 678.2000000000002 1477.9 678.2000000000002 1407.8' />
|
97
97
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
98
|
-
points='
|
98
|
+
points='363.5000000000001 1853.2 363.5000000000001 1783.1 363.5000000000002 1783.1 363.5000000000002 1713.0' />
|
99
99
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
100
|
-
points='
|
100
|
+
points='363.5000000000001 2158.4 363.5000000000001 2088.3 363.5000000000001 2088.3 363.5000000000001 2018.2' />
|
101
101
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
102
|
-
points='
|
102
|
+
points='363.5000000000001 2463.6 363.5000000000001 2393.5 363.5000000000001 2393.5 363.5000000000001 2323.4' />
|
103
103
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
104
|
-
points='
|
104
|
+
points='992.9000000000001 1853.2 992.9000000000001 1783.1 992.9000000000001 1783.1 992.9000000000001 1713.0' />
|
105
105
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
106
|
-
points='
|
106
|
+
points='992.9000000000001 2158.4 992.9000000000001 2088.3 992.9000000000001 2088.3 992.9000000000001 2018.2' />
|
107
107
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
108
|
-
points='
|
108
|
+
points='1573.0 937.5999999999999 1573.0 867.5 2166.4 867.5 2166.4 797.4' />
|
109
109
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
110
|
-
points='
|
110
|
+
points='2211.4 937.5999999999999 2211.4 867.5 2166.4 867.5 2166.4 797.4' />
|
111
111
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
112
|
-
points='
|
112
|
+
points='2759.8 937.5999999999999 2759.8 867.5 2166.4 867.5 2166.4 797.4' />
|
113
113
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
114
|
-
points='
|
114
|
+
points='1896.7000000000003 1242.8 1896.7000000000003 1172.6999999999998 2211.4 1172.6999999999998 2211.4 1102.6' />
|
115
115
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
116
|
-
points='
|
116
|
+
points='2256.4 1242.8 2256.4 1172.6999999999998 2211.4 1172.6999999999998 2211.4 1102.6' />
|
117
117
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
118
|
-
points='
|
118
|
+
points='2526.1000000000004 1242.8 2526.1000000000004 1172.6999999999998 2211.4 1172.6999999999998 2211.4 1102.6' />
|
119
119
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
120
|
-
points='
|
120
|
+
points='1896.7000000000003 1548.0 1896.7000000000003 1477.9 1896.7000000000003 1477.9 1896.7000000000003 1407.8' />
|
121
121
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
122
|
-
points='
|
122
|
+
points='1896.7000000000003 1853.2 1896.7000000000003 1783.1 1896.7000000000003 1783.1 1896.7000000000003 1713.0' />
|
123
123
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
124
|
-
points='
|
124
|
+
points='1896.7000000000003 2158.4 1896.7000000000003 2088.3 1896.7000000000003 2088.3 1896.7000000000003 2018.2' />
|
125
125
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
126
|
-
points='
|
126
|
+
points='2526.1000000000004 1548.0 2526.1000000000004 1477.9 2526.1000000000004 1477.9 2526.1000000000004 1407.8' />
|
127
127
|
<polyline style='stroke:black; stroke-width:2; fill:none;'
|
128
|
-
points='
|
128
|
+
points='2526.1000000000004 1853.2 2526.1000000000004 1783.1 2526.1000000000004 1783.1 2526.1000000000004 1713.0' />
|
129
129
|
<rect style='stroke: black; stroke-width:2;'
|
130
|
-
x='
|
131
|
-
width='
|
130
|
+
x='316.5000000000001' y='2500.4' rx='47.0' ry='47.0'
|
131
|
+
width='94.0' height='94.0'
|
132
132
|
fill='none' />
|
133
133
|
|
134
134
|
<rect style='stroke: black; stroke-width:2;'
|
135
|
-
x='
|
136
|
-
width='
|
135
|
+
x='676.2000000000002' y='1584.8' rx='47.0' ry='47.0'
|
136
|
+
width='94.0' height='94.0'
|
137
137
|
fill='none' />
|
138
138
|
|
139
139
|
<rect style='stroke: black; stroke-width:2;'
|
140
|
-
x='
|
141
|
-
width='
|
140
|
+
x='945.9000000000001' y='2195.2000000000003' rx='47.0' ry='47.0'
|
141
|
+
width='94.0' height='94.0'
|
142
142
|
fill='none' />
|
143
143
|
|
144
144
|
<rect style='stroke: black; stroke-width:2;'
|
145
|
-
x='
|
146
|
-
width='
|
145
|
+
x='1352.8' y='669.1999999999999' rx='47.0' ry='47.0'
|
146
|
+
width='94.0' height='94.0'
|
147
147
|
fill='none' />
|
148
148
|
|
149
149
|
<rect style='stroke: black; stroke-width:2;'
|
150
|
-
x='
|
151
|
-
width='
|
150
|
+
x='1849.7000000000003' y='2195.2000000000003' rx='47.0' ry='47.0'
|
151
|
+
width='94.0' height='94.0'
|
152
152
|
fill='none' />
|
153
153
|
|
154
154
|
<rect style='stroke: black; stroke-width:2;'
|
155
|
-
x='
|
156
|
-
width='
|
155
|
+
x='2209.4' y='1279.6' rx='47.0' ry='47.0'
|
156
|
+
width='94.0' height='94.0'
|
157
157
|
fill='none' />
|
158
158
|
|
159
159
|
<rect style='stroke: black; stroke-width:2;'
|
160
|
-
x='
|
161
|
-
width='
|
160
|
+
x='2479.1000000000004' y='1890.0' rx='47.0' ry='47.0'
|
161
|
+
width='94.0' height='94.0'
|
162
162
|
fill='none' />
|
163
163
|
</svg>
|
data/docs/documentation.md
CHANGED
@@ -31,12 +31,12 @@ The `Radical symmetrization` option affects the way branch nodes are drawn. The
|
|
31
31
|
|
32
32
|
### Fonts Used to Generate PNG
|
33
33
|
|
34
|
-
Currently, you can choose
|
34
|
+
Currently, you can choose among the font styles `Noto Sans`, `Noto Serif`, `Noto Sans Mono` and `WQY Zen Hei`.
|
35
35
|
|
36
36
|
- `Noto Sans` can display basic Unicode characters (including Japanese hiragana/katakana/kanji).
|
37
37
|
- `Noto Serif` can display basic Unicode characters (including Japanese hiragana/katakana/kanji).
|
38
38
|
- `WQY Zen Hei` can display a wide range of Chinese/Japanese/Korean (CJK) characters.
|
39
|
-
|
39
|
+
- `Noto Sans Mono` can display basic Unicode characters in a mono-spaced typeface.
|
40
40
|
|
41
41
|
### Install Fonts for SVG
|
42
42
|
|
@@ -47,6 +47,7 @@ SVG images are dependent on the fonts installed locally on your computer. In ord
|
|
47
47
|
- [Noto Serif](https://fonts.google.com/noto/specimen/Noto+Serif): for latin and other basic Unicode characters in serif
|
48
48
|
- [Noto Serif JP](https://fonts.google.com/noto/specimen/Noto+Serif+JP): for Japanese characters in serif
|
49
49
|
- [WQY Zen Hei](https://packages.ubuntu.com/bionic/fonts/fonts-wqy-zenhei): for CJK characters
|
50
|
+
- [Noto Sans Mono](https://fonts.google.com/noto/specimen/Noto+Sans+Mono): for latin and other basic Unicode characters in sans serif mono (semi-condensed)
|
50
51
|
- [OpenMoji](https://openmoji.org/): for emoji characters.
|
51
52
|
|
52
53
|
|
Binary file
|
Binary file
|
@@ -218,6 +218,12 @@ module RSyntaxTree
|
|
218
218
|
case @fontstyle
|
219
219
|
when /(?:cjk)/
|
220
220
|
fontstyle = "'WenQuanYi Zen Hei', 'Noto Sans', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif"
|
221
|
+
when /(?:mono)/
|
222
|
+
fontstyle = if e[:cjk]
|
223
|
+
"'Noto Sans JP', 'Noto Sans Mono SemiCondensed', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif"
|
224
|
+
else
|
225
|
+
"'Noto Sans Mono SemiCondensed', 'Noto Sans JP', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif"
|
226
|
+
end
|
221
227
|
when /(?:sans)/
|
222
228
|
fontstyle = if e[:cjk]
|
223
229
|
"'Noto Sans JP', 'Noto Sans', OpenMoji, 'OpenMoji Color', 'OpenMoji Black', sans-serif"
|
data/lib/rsyntaxtree/version.rb
CHANGED
data/lib/rsyntaxtree.rb
CHANGED
@@ -63,6 +63,15 @@ module RSyntaxTree
|
|
63
63
|
new_params[key] = value.to_f
|
64
64
|
when :fontstyle
|
65
65
|
case value
|
66
|
+
when "noto-sans-mono", "mono"
|
67
|
+
fontset[:normal] = FONT_DIR + "/NotoSansMono_SemiCondensed-Regular.ttf"
|
68
|
+
fontset[:italic] = FONT_DIR + "/NotoSansMono_SemiCondensed-Regular.ttf"
|
69
|
+
fontset[:bold] = FONT_DIR + "/NotoSansMono_SemiCondensed-Bold.ttf"
|
70
|
+
fontset[:bolditalic] = FONT_DIR + "/NotoSansMono_SemiCondensed-Bold.ttf"
|
71
|
+
fontset[:math] = FONT_DIR + "/latinmodern-math.otf"
|
72
|
+
fontset[:cjk] = FONT_DIR + "/NotoSansJP-Regular.otf"
|
73
|
+
fontset[:emoji] = FONT_DIR + "/OpenMoji-Black.ttf"
|
74
|
+
new_params[:fontstyle] = "mono"
|
66
75
|
when "noto-sans", "sans"
|
67
76
|
fontset[:normal] = FONT_DIR + "/NotoSans-Regular.ttf"
|
68
77
|
fontset[:italic] = FONT_DIR + "/NotoSans-Italic.ttf"
|
data/test/example_verify_test.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rsyntaxtree
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Yoichiro Hasebe
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-01-
|
11
|
+
date: 2023-01-29 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: optimist
|
@@ -112,6 +112,7 @@ files:
|
|
112
112
|
- docs/404.html
|
113
113
|
- docs/Gemfile
|
114
114
|
- docs/_config.yml
|
115
|
+
- docs/_examples/000.md
|
115
116
|
- docs/_examples/001.md
|
116
117
|
- docs/_examples/002.md
|
117
118
|
- docs/_examples/003.md
|
@@ -145,6 +146,7 @@ files:
|
|
145
146
|
- docs/_includes/social_media_links.html
|
146
147
|
- docs/_layouts/default.html
|
147
148
|
- docs/assets/css/style.scss
|
149
|
+
- docs/assets/img/000.png
|
148
150
|
- docs/assets/img/001.png
|
149
151
|
- docs/assets/img/002.png
|
150
152
|
- docs/assets/img/003.png
|
@@ -189,6 +191,7 @@ files:
|
|
189
191
|
- docs/assets/img/favicon/favicon-16x16.png
|
190
192
|
- docs/assets/img/favicon/favicon-32x32.png
|
191
193
|
- docs/assets/img/favicon/favicon.ico
|
194
|
+
- docs/assets/svg/000.svg
|
192
195
|
- docs/assets/svg/001.svg
|
193
196
|
- docs/assets/svg/002.svg
|
194
197
|
- docs/assets/svg/003.svg
|
@@ -228,6 +231,8 @@ files:
|
|
228
231
|
- fonts/NotoSansJP-Bold.otf
|
229
232
|
- fonts/NotoSansJP-Regular.otf
|
230
233
|
- fonts/NotoSansMath-Regular.ttf
|
234
|
+
- fonts/NotoSansMono_SemiCondensed-Bold.ttf
|
235
|
+
- fonts/NotoSansMono_SemiCondensed-Regular.ttf
|
231
236
|
- fonts/NotoSerif-Bold.ttf
|
232
237
|
- fonts/NotoSerif-BoldItalic.ttf
|
233
238
|
- fonts/NotoSerif-Italic.ttf
|