rpdf2txt 0.8.2
Sign up to get free protection for your applications and to get access to all the features.
- data/History.txt +5 -0
- data/LICENCE +515 -0
- data/Manifest.txt +126 -0
- data/README.txt +30 -0
- data/Rakefile +24 -0
- data/bin/rpdf2txt +58 -0
- data/config.save +12 -0
- data/install.rb +1098 -0
- data/lib/rpdf2txt-rockit/base_extensions.rb +73 -0
- data/lib/rpdf2txt-rockit/bootstrap.rb +120 -0
- data/lib/rpdf2txt-rockit/bounded_lru_cache.rb +43 -0
- data/lib/rpdf2txt-rockit/conflict_resolution.rb +302 -0
- data/lib/rpdf2txt-rockit/directed_graph.rb +401 -0
- data/lib/rpdf2txt-rockit/glr_parser.rb +393 -0
- data/lib/rpdf2txt-rockit/grammar.rb +644 -0
- data/lib/rpdf2txt-rockit/graphdrawing.rb +107 -0
- data/lib/rpdf2txt-rockit/graphviz_dot.rb +63 -0
- data/lib/rpdf2txt-rockit/indexable.rb +53 -0
- data/lib/rpdf2txt-rockit/lalr_parsetable_generator.rb +144 -0
- data/lib/rpdf2txt-rockit/parse_table.rb +273 -0
- data/lib/rpdf2txt-rockit/parsetable_generation.rb +164 -0
- data/lib/rpdf2txt-rockit/parsing_ambiguities.rb +84 -0
- data/lib/rpdf2txt-rockit/profiler.rb +168 -0
- data/lib/rpdf2txt-rockit/reduce_actions_generator.rb +523 -0
- data/lib/rpdf2txt-rockit/rockit.rb +76 -0
- data/lib/rpdf2txt-rockit/rockit_grammar_ast_eval.rb +187 -0
- data/lib/rpdf2txt-rockit/rockit_grammars_parser.rb +126 -0
- data/lib/rpdf2txt-rockit/sourcecode_dumpable.rb +181 -0
- data/lib/rpdf2txt-rockit/stringscanner.rb +54 -0
- data/lib/rpdf2txt-rockit/syntax_tree.rb +452 -0
- data/lib/rpdf2txt-rockit/token.rb +364 -0
- data/lib/rpdf2txt-rockit/version.rb +3 -0
- data/lib/rpdf2txt/attributesparser.rb +42 -0
- data/lib/rpdf2txt/cmapparser.rb +65 -0
- data/lib/rpdf2txt/data/_cmap.grammar +11 -0
- data/lib/rpdf2txt/data/_cmap_range.grammar +15 -0
- data/lib/rpdf2txt/data/_pdfattributes.grammar +32 -0
- data/lib/rpdf2txt/data/cmap.grammar +11 -0
- data/lib/rpdf2txt/data/cmap.rb +37 -0
- data/lib/rpdf2txt/data/cmap_range.grammar +15 -0
- data/lib/rpdf2txt/data/cmap_range.rb +43 -0
- data/lib/rpdf2txt/data/fonts/Courier-Bold.afm +342 -0
- data/lib/rpdf2txt/data/fonts/Courier-BoldOblique.afm +342 -0
- data/lib/rpdf2txt/data/fonts/Courier-Oblique.afm +342 -0
- data/lib/rpdf2txt/data/fonts/Courier.afm +342 -0
- data/lib/rpdf2txt/data/fonts/Helvetica-Bold.afm +2827 -0
- data/lib/rpdf2txt/data/fonts/Helvetica-BoldOblique.afm +2827 -0
- data/lib/rpdf2txt/data/fonts/Helvetica-Oblique.afm +3051 -0
- data/lib/rpdf2txt/data/fonts/Helvetica.afm +3051 -0
- data/lib/rpdf2txt/data/fonts/License-Adobe.txt +65 -0
- data/lib/rpdf2txt/data/fonts/Symbol.afm +213 -0
- data/lib/rpdf2txt/data/fonts/Times-Bold.afm +2588 -0
- data/lib/rpdf2txt/data/fonts/Times-BoldItalic.afm +2384 -0
- data/lib/rpdf2txt/data/fonts/Times-Italic.afm +2667 -0
- data/lib/rpdf2txt/data/fonts/Times-Roman.afm +2419 -0
- data/lib/rpdf2txt/data/fonts/ZapfDingbats.afm +225 -0
- data/lib/rpdf2txt/data/pdfattributes.grammar +32 -0
- data/lib/rpdf2txt/data/pdfattributes.rb +71 -0
- data/lib/rpdf2txt/data/pdftext.grammar +102 -0
- data/lib/rpdf2txt/data/pdftext.rb +146 -0
- data/lib/rpdf2txt/default_handler.rb +352 -0
- data/lib/rpdf2txt/lzw.rb +69 -0
- data/lib/rpdf2txt/object.rb +1114 -0
- data/lib/rpdf2txt/parser.rb +169 -0
- data/lib/rpdf2txt/symbol.rb +408 -0
- data/lib/rpdf2txt/text.rb +182 -0
- data/lib/rpdf2txt/text_state.rb +434 -0
- data/lib/rpdf2txt/textparser.rb +42 -0
- data/test/data/3392_obj +0 -0
- data/test/data/397_decrypted +15 -0
- data/test/data/450_decrypted +153 -0
- data/test/data/450_obj +0 -0
- data/test/data/452_decrypted +125 -0
- data/test/data/454_decrypted +108 -0
- data/test/data/456_decrypted +106 -0
- data/test/data/458_decrypted +111 -0
- data/test/data/458_obj +0 -0
- data/test/data/460_decrypted +118 -0
- data/test/data/460_obj +0 -0
- data/test/data/463_decrypted +117 -0
- data/test/data/465_decrypted +107 -0
- data/test/data/465_obj +0 -0
- data/test/data/90_obj +0 -0
- data/test/data/90_obj_comp +1 -0
- data/test/data/decrypted +0 -0
- data/test/data/encrypt_obj +0 -0
- data/test/data/encrypt_string +0 -0
- data/test/data/encrypt_string_128bit +0 -0
- data/test/data/encrypted_object_stream.pdf +0 -0
- data/test/data/firststream +1 -0
- data/test/data/index.pdfobj +0 -0
- data/test/data/index_2bit.pdfobj +0 -0
- data/test/data/index_masked.pdfobj +0 -0
- data/test/data/indexed.pdfobj +0 -0
- data/test/data/indexed_2bit.pdfobj +0 -0
- data/test/data/indexed_masked.pdfobj +0 -0
- data/test/data/inline.png +0 -0
- data/test/data/logo.png +0 -0
- data/test/data/lzw.pdfobj +0 -0
- data/test/data/lzw_index.pdfobj +0 -0
- data/test/data/page_tree.pdf +148 -0
- data/test/data/pdf_20.png +0 -0
- data/test/data/pdf_21.png +0 -0
- data/test/data/pdf_22.png +0 -0
- data/test/data/pdf_50.png +0 -0
- data/test/data/png.pdfobj +0 -0
- data/test/data/space_bug_stream.txt +119 -0
- data/test/data/stream.txt +292 -0
- data/test/data/stream_kerning_bug.txt +13 -0
- data/test/data/stream_kerning_bug2.txt +6 -0
- data/test/data/test.pdf +0 -0
- data/test/data/test.txt +8 -0
- data/test/data/test_text.txt +42 -0
- data/test/data/working_obj +0 -0
- data/test/data/working_obj2 +0 -0
- data/test/mock.rb +149 -0
- data/test/suite.rb +30 -0
- data/test/test_pdf_object.rb +1802 -0
- data/test/test_pdf_parser.rb +1340 -0
- data/test/test_pdf_text.rb +789 -0
- data/test/test_space_bug_05_2004.rb +87 -0
- data/test/test_stream.rb +194 -0
- data/test/test_text_state.rb +315 -0
- data/usage-en.txt +112 -0
- data/user-stories/UserStories_Rpdf2Txt.txt +34 -0
- data/user-stories/documents/swissmedicjournal/04_2004.pdf +0 -0
- metadata +220 -0
@@ -0,0 +1,225 @@
|
|
1
|
+
StartFontMetrics 4.1
|
2
|
+
Comment Copyright (c) 1985, 1987, 1988, 1989, 1997 Adobe Systems Incorporated. All Rights Reserved.
|
3
|
+
Comment Creation Date: Thu May 1 15:14:13 1997
|
4
|
+
Comment UniqueID 43082
|
5
|
+
Comment VMusage 45775 55535
|
6
|
+
FontName ZapfDingbats
|
7
|
+
FullName ITC Zapf Dingbats
|
8
|
+
FamilyName ZapfDingbats
|
9
|
+
Weight Medium
|
10
|
+
ItalicAngle 0
|
11
|
+
IsFixedPitch false
|
12
|
+
CharacterSet Special
|
13
|
+
FontBBox -1 -143 981 820
|
14
|
+
UnderlinePosition -100
|
15
|
+
UnderlineThickness 50
|
16
|
+
Version 002.000
|
17
|
+
Notice Copyright (c) 1985, 1987, 1988, 1989, 1997 Adobe Systems Incorporated. All Rights Reserved.ITC Zapf Dingbats is a registered trademark of International Typeface Corporation.
|
18
|
+
EncodingScheme FontSpecific
|
19
|
+
StdHW 28
|
20
|
+
StdVW 90
|
21
|
+
StartCharMetrics 202
|
22
|
+
C 32 ; WX 278 ; N space ; B 0 0 0 0 ;
|
23
|
+
C 33 ; WX 974 ; N a1 ; B 35 72 939 621 ;
|
24
|
+
C 34 ; WX 961 ; N a2 ; B 35 81 927 611 ;
|
25
|
+
C 35 ; WX 974 ; N a202 ; B 35 72 939 621 ;
|
26
|
+
C 36 ; WX 980 ; N a3 ; B 35 0 945 692 ;
|
27
|
+
C 37 ; WX 719 ; N a4 ; B 34 139 685 566 ;
|
28
|
+
C 38 ; WX 789 ; N a5 ; B 35 -14 755 705 ;
|
29
|
+
C 39 ; WX 790 ; N a119 ; B 35 -14 755 705 ;
|
30
|
+
C 40 ; WX 791 ; N a118 ; B 35 -13 761 705 ;
|
31
|
+
C 41 ; WX 690 ; N a117 ; B 34 138 655 553 ;
|
32
|
+
C 42 ; WX 960 ; N a11 ; B 35 123 925 568 ;
|
33
|
+
C 43 ; WX 939 ; N a12 ; B 35 134 904 559 ;
|
34
|
+
C 44 ; WX 549 ; N a13 ; B 29 -11 516 705 ;
|
35
|
+
C 45 ; WX 855 ; N a14 ; B 34 59 820 632 ;
|
36
|
+
C 46 ; WX 911 ; N a15 ; B 35 50 876 642 ;
|
37
|
+
C 47 ; WX 933 ; N a16 ; B 35 139 899 550 ;
|
38
|
+
C 48 ; WX 911 ; N a105 ; B 35 50 876 642 ;
|
39
|
+
C 49 ; WX 945 ; N a17 ; B 35 139 909 553 ;
|
40
|
+
C 50 ; WX 974 ; N a18 ; B 35 104 938 587 ;
|
41
|
+
C 51 ; WX 755 ; N a19 ; B 34 -13 721 705 ;
|
42
|
+
C 52 ; WX 846 ; N a20 ; B 36 -14 811 705 ;
|
43
|
+
C 53 ; WX 762 ; N a21 ; B 35 0 727 692 ;
|
44
|
+
C 54 ; WX 761 ; N a22 ; B 35 0 727 692 ;
|
45
|
+
C 55 ; WX 571 ; N a23 ; B -1 -68 571 661 ;
|
46
|
+
C 56 ; WX 677 ; N a24 ; B 36 -13 642 705 ;
|
47
|
+
C 57 ; WX 763 ; N a25 ; B 35 0 728 692 ;
|
48
|
+
C 58 ; WX 760 ; N a26 ; B 35 0 726 692 ;
|
49
|
+
C 59 ; WX 759 ; N a27 ; B 35 0 725 692 ;
|
50
|
+
C 60 ; WX 754 ; N a28 ; B 35 0 720 692 ;
|
51
|
+
C 61 ; WX 494 ; N a6 ; B 35 0 460 692 ;
|
52
|
+
C 62 ; WX 552 ; N a7 ; B 35 0 517 692 ;
|
53
|
+
C 63 ; WX 537 ; N a8 ; B 35 0 503 692 ;
|
54
|
+
C 64 ; WX 577 ; N a9 ; B 35 96 542 596 ;
|
55
|
+
C 65 ; WX 692 ; N a10 ; B 35 -14 657 705 ;
|
56
|
+
C 66 ; WX 786 ; N a29 ; B 35 -14 751 705 ;
|
57
|
+
C 67 ; WX 788 ; N a30 ; B 35 -14 752 705 ;
|
58
|
+
C 68 ; WX 788 ; N a31 ; B 35 -14 753 705 ;
|
59
|
+
C 69 ; WX 790 ; N a32 ; B 35 -14 756 705 ;
|
60
|
+
C 70 ; WX 793 ; N a33 ; B 35 -13 759 705 ;
|
61
|
+
C 71 ; WX 794 ; N a34 ; B 35 -13 759 705 ;
|
62
|
+
C 72 ; WX 816 ; N a35 ; B 35 -14 782 705 ;
|
63
|
+
C 73 ; WX 823 ; N a36 ; B 35 -14 787 705 ;
|
64
|
+
C 74 ; WX 789 ; N a37 ; B 35 -14 754 705 ;
|
65
|
+
C 75 ; WX 841 ; N a38 ; B 35 -14 807 705 ;
|
66
|
+
C 76 ; WX 823 ; N a39 ; B 35 -14 789 705 ;
|
67
|
+
C 77 ; WX 833 ; N a40 ; B 35 -14 798 705 ;
|
68
|
+
C 78 ; WX 816 ; N a41 ; B 35 -13 782 705 ;
|
69
|
+
C 79 ; WX 831 ; N a42 ; B 35 -14 796 705 ;
|
70
|
+
C 80 ; WX 923 ; N a43 ; B 35 -14 888 705 ;
|
71
|
+
C 81 ; WX 744 ; N a44 ; B 35 0 710 692 ;
|
72
|
+
C 82 ; WX 723 ; N a45 ; B 35 0 688 692 ;
|
73
|
+
C 83 ; WX 749 ; N a46 ; B 35 0 714 692 ;
|
74
|
+
C 84 ; WX 790 ; N a47 ; B 34 -14 756 705 ;
|
75
|
+
C 85 ; WX 792 ; N a48 ; B 35 -14 758 705 ;
|
76
|
+
C 86 ; WX 695 ; N a49 ; B 35 -14 661 706 ;
|
77
|
+
C 87 ; WX 776 ; N a50 ; B 35 -6 741 699 ;
|
78
|
+
C 88 ; WX 768 ; N a51 ; B 35 -7 734 699 ;
|
79
|
+
C 89 ; WX 792 ; N a52 ; B 35 -14 757 705 ;
|
80
|
+
C 90 ; WX 759 ; N a53 ; B 35 0 725 692 ;
|
81
|
+
C 91 ; WX 707 ; N a54 ; B 35 -13 672 704 ;
|
82
|
+
C 92 ; WX 708 ; N a55 ; B 35 -14 672 705 ;
|
83
|
+
C 93 ; WX 682 ; N a56 ; B 35 -14 647 705 ;
|
84
|
+
C 94 ; WX 701 ; N a57 ; B 35 -14 666 705 ;
|
85
|
+
C 95 ; WX 826 ; N a58 ; B 35 -14 791 705 ;
|
86
|
+
C 96 ; WX 815 ; N a59 ; B 35 -14 780 705 ;
|
87
|
+
C 97 ; WX 789 ; N a60 ; B 35 -14 754 705 ;
|
88
|
+
C 98 ; WX 789 ; N a61 ; B 35 -14 754 705 ;
|
89
|
+
C 99 ; WX 707 ; N a62 ; B 34 -14 673 705 ;
|
90
|
+
C 100 ; WX 687 ; N a63 ; B 36 0 651 692 ;
|
91
|
+
C 101 ; WX 696 ; N a64 ; B 35 0 661 691 ;
|
92
|
+
C 102 ; WX 689 ; N a65 ; B 35 0 655 692 ;
|
93
|
+
C 103 ; WX 786 ; N a66 ; B 34 -14 751 705 ;
|
94
|
+
C 104 ; WX 787 ; N a67 ; B 35 -14 752 705 ;
|
95
|
+
C 105 ; WX 713 ; N a68 ; B 35 -14 678 705 ;
|
96
|
+
C 106 ; WX 791 ; N a69 ; B 35 -14 756 705 ;
|
97
|
+
C 107 ; WX 785 ; N a70 ; B 36 -14 751 705 ;
|
98
|
+
C 108 ; WX 791 ; N a71 ; B 35 -14 757 705 ;
|
99
|
+
C 109 ; WX 873 ; N a72 ; B 35 -14 838 705 ;
|
100
|
+
C 110 ; WX 761 ; N a73 ; B 35 0 726 692 ;
|
101
|
+
C 111 ; WX 762 ; N a74 ; B 35 0 727 692 ;
|
102
|
+
C 112 ; WX 762 ; N a203 ; B 35 0 727 692 ;
|
103
|
+
C 113 ; WX 759 ; N a75 ; B 35 0 725 692 ;
|
104
|
+
C 114 ; WX 759 ; N a204 ; B 35 0 725 692 ;
|
105
|
+
C 115 ; WX 892 ; N a76 ; B 35 0 858 705 ;
|
106
|
+
C 116 ; WX 892 ; N a77 ; B 35 -14 858 692 ;
|
107
|
+
C 117 ; WX 788 ; N a78 ; B 35 -14 754 705 ;
|
108
|
+
C 118 ; WX 784 ; N a79 ; B 35 -14 749 705 ;
|
109
|
+
C 119 ; WX 438 ; N a81 ; B 35 -14 403 705 ;
|
110
|
+
C 120 ; WX 138 ; N a82 ; B 35 0 104 692 ;
|
111
|
+
C 121 ; WX 277 ; N a83 ; B 35 0 242 692 ;
|
112
|
+
C 122 ; WX 415 ; N a84 ; B 35 0 380 692 ;
|
113
|
+
C 123 ; WX 392 ; N a97 ; B 35 263 357 705 ;
|
114
|
+
C 124 ; WX 392 ; N a98 ; B 34 263 357 705 ;
|
115
|
+
C 125 ; WX 668 ; N a99 ; B 35 263 633 705 ;
|
116
|
+
C 126 ; WX 668 ; N a100 ; B 36 263 634 705 ;
|
117
|
+
C 128 ; WX 390 ; N a89 ; B 35 -14 356 705 ;
|
118
|
+
C 129 ; WX 390 ; N a90 ; B 35 -14 355 705 ;
|
119
|
+
C 130 ; WX 317 ; N a93 ; B 35 0 283 692 ;
|
120
|
+
C 131 ; WX 317 ; N a94 ; B 35 0 283 692 ;
|
121
|
+
C 132 ; WX 276 ; N a91 ; B 35 0 242 692 ;
|
122
|
+
C 133 ; WX 276 ; N a92 ; B 35 0 242 692 ;
|
123
|
+
C 134 ; WX 509 ; N a205 ; B 35 0 475 692 ;
|
124
|
+
C 135 ; WX 509 ; N a85 ; B 35 0 475 692 ;
|
125
|
+
C 136 ; WX 410 ; N a206 ; B 35 0 375 692 ;
|
126
|
+
C 137 ; WX 410 ; N a86 ; B 35 0 375 692 ;
|
127
|
+
C 138 ; WX 234 ; N a87 ; B 35 -14 199 705 ;
|
128
|
+
C 139 ; WX 234 ; N a88 ; B 35 -14 199 705 ;
|
129
|
+
C 140 ; WX 334 ; N a95 ; B 35 0 299 692 ;
|
130
|
+
C 141 ; WX 334 ; N a96 ; B 35 0 299 692 ;
|
131
|
+
C 161 ; WX 732 ; N a101 ; B 35 -143 697 806 ;
|
132
|
+
C 162 ; WX 544 ; N a102 ; B 56 -14 488 706 ;
|
133
|
+
C 163 ; WX 544 ; N a103 ; B 34 -14 508 705 ;
|
134
|
+
C 164 ; WX 910 ; N a104 ; B 35 40 875 651 ;
|
135
|
+
C 165 ; WX 667 ; N a106 ; B 35 -14 633 705 ;
|
136
|
+
C 166 ; WX 760 ; N a107 ; B 35 -14 726 705 ;
|
137
|
+
C 167 ; WX 760 ; N a108 ; B 0 121 758 569 ;
|
138
|
+
C 168 ; WX 776 ; N a112 ; B 35 0 741 705 ;
|
139
|
+
C 169 ; WX 595 ; N a111 ; B 34 -14 560 705 ;
|
140
|
+
C 170 ; WX 694 ; N a110 ; B 35 -14 659 705 ;
|
141
|
+
C 171 ; WX 626 ; N a109 ; B 34 0 591 705 ;
|
142
|
+
C 172 ; WX 788 ; N a120 ; B 35 -14 754 705 ;
|
143
|
+
C 173 ; WX 788 ; N a121 ; B 35 -14 754 705 ;
|
144
|
+
C 174 ; WX 788 ; N a122 ; B 35 -14 754 705 ;
|
145
|
+
C 175 ; WX 788 ; N a123 ; B 35 -14 754 705 ;
|
146
|
+
C 176 ; WX 788 ; N a124 ; B 35 -14 754 705 ;
|
147
|
+
C 177 ; WX 788 ; N a125 ; B 35 -14 754 705 ;
|
148
|
+
C 178 ; WX 788 ; N a126 ; B 35 -14 754 705 ;
|
149
|
+
C 179 ; WX 788 ; N a127 ; B 35 -14 754 705 ;
|
150
|
+
C 180 ; WX 788 ; N a128 ; B 35 -14 754 705 ;
|
151
|
+
C 181 ; WX 788 ; N a129 ; B 35 -14 754 705 ;
|
152
|
+
C 182 ; WX 788 ; N a130 ; B 35 -14 754 705 ;
|
153
|
+
C 183 ; WX 788 ; N a131 ; B 35 -14 754 705 ;
|
154
|
+
C 184 ; WX 788 ; N a132 ; B 35 -14 754 705 ;
|
155
|
+
C 185 ; WX 788 ; N a133 ; B 35 -14 754 705 ;
|
156
|
+
C 186 ; WX 788 ; N a134 ; B 35 -14 754 705 ;
|
157
|
+
C 187 ; WX 788 ; N a135 ; B 35 -14 754 705 ;
|
158
|
+
C 188 ; WX 788 ; N a136 ; B 35 -14 754 705 ;
|
159
|
+
C 189 ; WX 788 ; N a137 ; B 35 -14 754 705 ;
|
160
|
+
C 190 ; WX 788 ; N a138 ; B 35 -14 754 705 ;
|
161
|
+
C 191 ; WX 788 ; N a139 ; B 35 -14 754 705 ;
|
162
|
+
C 192 ; WX 788 ; N a140 ; B 35 -14 754 705 ;
|
163
|
+
C 193 ; WX 788 ; N a141 ; B 35 -14 754 705 ;
|
164
|
+
C 194 ; WX 788 ; N a142 ; B 35 -14 754 705 ;
|
165
|
+
C 195 ; WX 788 ; N a143 ; B 35 -14 754 705 ;
|
166
|
+
C 196 ; WX 788 ; N a144 ; B 35 -14 754 705 ;
|
167
|
+
C 197 ; WX 788 ; N a145 ; B 35 -14 754 705 ;
|
168
|
+
C 198 ; WX 788 ; N a146 ; B 35 -14 754 705 ;
|
169
|
+
C 199 ; WX 788 ; N a147 ; B 35 -14 754 705 ;
|
170
|
+
C 200 ; WX 788 ; N a148 ; B 35 -14 754 705 ;
|
171
|
+
C 201 ; WX 788 ; N a149 ; B 35 -14 754 705 ;
|
172
|
+
C 202 ; WX 788 ; N a150 ; B 35 -14 754 705 ;
|
173
|
+
C 203 ; WX 788 ; N a151 ; B 35 -14 754 705 ;
|
174
|
+
C 204 ; WX 788 ; N a152 ; B 35 -14 754 705 ;
|
175
|
+
C 205 ; WX 788 ; N a153 ; B 35 -14 754 705 ;
|
176
|
+
C 206 ; WX 788 ; N a154 ; B 35 -14 754 705 ;
|
177
|
+
C 207 ; WX 788 ; N a155 ; B 35 -14 754 705 ;
|
178
|
+
C 208 ; WX 788 ; N a156 ; B 35 -14 754 705 ;
|
179
|
+
C 209 ; WX 788 ; N a157 ; B 35 -14 754 705 ;
|
180
|
+
C 210 ; WX 788 ; N a158 ; B 35 -14 754 705 ;
|
181
|
+
C 211 ; WX 788 ; N a159 ; B 35 -14 754 705 ;
|
182
|
+
C 212 ; WX 894 ; N a160 ; B 35 58 860 634 ;
|
183
|
+
C 213 ; WX 838 ; N a161 ; B 35 152 803 540 ;
|
184
|
+
C 214 ; WX 1016 ; N a163 ; B 34 152 981 540 ;
|
185
|
+
C 215 ; WX 458 ; N a164 ; B 35 -127 422 820 ;
|
186
|
+
C 216 ; WX 748 ; N a196 ; B 35 94 698 597 ;
|
187
|
+
C 217 ; WX 924 ; N a165 ; B 35 140 890 552 ;
|
188
|
+
C 218 ; WX 748 ; N a192 ; B 35 94 698 597 ;
|
189
|
+
C 219 ; WX 918 ; N a166 ; B 35 166 884 526 ;
|
190
|
+
C 220 ; WX 927 ; N a167 ; B 35 32 892 660 ;
|
191
|
+
C 221 ; WX 928 ; N a168 ; B 35 129 891 562 ;
|
192
|
+
C 222 ; WX 928 ; N a169 ; B 35 128 893 563 ;
|
193
|
+
C 223 ; WX 834 ; N a170 ; B 35 155 799 537 ;
|
194
|
+
C 224 ; WX 873 ; N a171 ; B 35 93 838 599 ;
|
195
|
+
C 225 ; WX 828 ; N a172 ; B 35 104 791 588 ;
|
196
|
+
C 226 ; WX 924 ; N a173 ; B 35 98 889 594 ;
|
197
|
+
C 227 ; WX 924 ; N a162 ; B 35 98 889 594 ;
|
198
|
+
C 228 ; WX 917 ; N a174 ; B 35 0 882 692 ;
|
199
|
+
C 229 ; WX 930 ; N a175 ; B 35 84 896 608 ;
|
200
|
+
C 230 ; WX 931 ; N a176 ; B 35 84 896 608 ;
|
201
|
+
C 231 ; WX 463 ; N a177 ; B 35 -99 429 791 ;
|
202
|
+
C 232 ; WX 883 ; N a178 ; B 35 71 848 623 ;
|
203
|
+
C 233 ; WX 836 ; N a179 ; B 35 44 802 648 ;
|
204
|
+
C 234 ; WX 836 ; N a193 ; B 35 44 802 648 ;
|
205
|
+
C 235 ; WX 867 ; N a180 ; B 35 101 832 591 ;
|
206
|
+
C 236 ; WX 867 ; N a199 ; B 35 101 832 591 ;
|
207
|
+
C 237 ; WX 696 ; N a181 ; B 35 44 661 648 ;
|
208
|
+
C 238 ; WX 696 ; N a200 ; B 35 44 661 648 ;
|
209
|
+
C 239 ; WX 874 ; N a182 ; B 35 77 840 619 ;
|
210
|
+
C 241 ; WX 874 ; N a201 ; B 35 73 840 615 ;
|
211
|
+
C 242 ; WX 760 ; N a183 ; B 35 0 725 692 ;
|
212
|
+
C 243 ; WX 946 ; N a184 ; B 35 160 911 533 ;
|
213
|
+
C 244 ; WX 771 ; N a197 ; B 34 37 736 655 ;
|
214
|
+
C 245 ; WX 865 ; N a185 ; B 35 207 830 481 ;
|
215
|
+
C 246 ; WX 771 ; N a194 ; B 34 37 736 655 ;
|
216
|
+
C 247 ; WX 888 ; N a198 ; B 34 -19 853 712 ;
|
217
|
+
C 248 ; WX 967 ; N a186 ; B 35 124 932 568 ;
|
218
|
+
C 249 ; WX 888 ; N a195 ; B 34 -19 853 712 ;
|
219
|
+
C 250 ; WX 831 ; N a187 ; B 35 113 796 579 ;
|
220
|
+
C 251 ; WX 873 ; N a188 ; B 36 118 838 578 ;
|
221
|
+
C 252 ; WX 927 ; N a189 ; B 35 150 891 542 ;
|
222
|
+
C 253 ; WX 970 ; N a190 ; B 35 76 931 616 ;
|
223
|
+
C 254 ; WX 918 ; N a191 ; B 34 99 884 593 ;
|
224
|
+
EndCharMetrics
|
225
|
+
EndFontMetrics
|
@@ -0,0 +1,32 @@
|
|
1
|
+
Grammar PdfAttributes
|
2
|
+
Tokens
|
3
|
+
IDENTIFIER = /^\/[\w:+\#\-\.]*(, ?[\w:+\#\-\.]*)*/n
|
4
|
+
NUMERIC = /-?[0-9]+([.,][0-9]+)?/n
|
5
|
+
REFERENCE = /[0-9]+\s+[0-9]+\s+R/n
|
6
|
+
WORD = /[a-z\.]{2,}/in
|
7
|
+
SPACE = /\s+/mn [:Skip]
|
8
|
+
COMMENT = /%[^%]*%/mn [:Skip]
|
9
|
+
FILEIDENTIFIER = /<[a-zA-Z0-9\n]+>/n
|
10
|
+
Productions
|
11
|
+
Expr -> IDENTIFIER [^: val]
|
12
|
+
| Hash [^: val]
|
13
|
+
| Array [^: val]
|
14
|
+
| REFERENCE [^: val]
|
15
|
+
| NUMERIC [^: val]
|
16
|
+
| Text [^: val]
|
17
|
+
| Date [^: val]
|
18
|
+
| WORD [^: val]
|
19
|
+
| FILEIDENTIFIER [^: val]
|
20
|
+
Array -> '[' ArrayElements ']'
|
21
|
+
[: _, values, _]
|
22
|
+
| '[' ']'
|
23
|
+
[: _, _]
|
24
|
+
ArrayElements -> ArrayElement+
|
25
|
+
[^: values]
|
26
|
+
ArrayElement -> (Array|Hash|NUMERIC|IDENTIFIER|REFERENCE|WORD|FILEIDENTIFIER|Text)
|
27
|
+
[^: _]
|
28
|
+
Hash -> '<<' (IDENTIFIER Expr)* '>>'
|
29
|
+
[: _, pairs, _]
|
30
|
+
Date -> '(D:' /[\d+']+/n ')'
|
31
|
+
Text -> /\(([^\)\\]|\\[\(\)\\]?)*?\)/n
|
32
|
+
[: text]
|
@@ -0,0 +1,71 @@
|
|
1
|
+
require 'rpdf2txt-rockit/rockit'
|
2
|
+
module Rpdf2txt
|
3
|
+
# Parser for PdfAttributes
|
4
|
+
# created by Rockit version 0.3.8 on Tue Dec 14 18:03:10 +0100 2010
|
5
|
+
# Rockit is copyright (c) 2001 Robert Feldt, feldt@ce.chalmers.se
|
6
|
+
# and licensed under GPL
|
7
|
+
# but this parser is under LGPL
|
8
|
+
tokens = [
|
9
|
+
t1 = EofToken.new("EOF",/^(�~~��~^^~1499757680)/),
|
10
|
+
t2 = Token.new("IDENTIFIER",/^\/[\w:+\#\-\.]*(, ?[\w:+\#\-\.]*)*/n),
|
11
|
+
t3 = Token.new("NUMERIC",/^(-?[0-9]+([.,][0-9]+)?)/n),
|
12
|
+
t4 = Token.new("REFERENCE",/^([0-9]+\s+[0-9]+\s+R)/n),
|
13
|
+
t5 = Token.new("WORD",/^([a-z\.]{2,})/in),
|
14
|
+
t6 = Token.new("SPACE",/^(\s+)/n,:Skip),
|
15
|
+
t7 = Token.new("COMMENT",/^(%[^%]*%)/n,:Skip),
|
16
|
+
t8 = Token.new("FILEIDENTIFIER",/^(<[a-zA-Z0-9\n]+>)/n),
|
17
|
+
t9 = StringToken.new("StrToken93","["),
|
18
|
+
t10 = StringToken.new("StrToken95","]"),
|
19
|
+
t11 = StringToken.new("StrToken4059000","<<"),
|
20
|
+
t12 = StringToken.new("StrToken4194300",">>"),
|
21
|
+
t13 = StringToken.new("StrToken345387270","(D:"),
|
22
|
+
t14 = RegexpToken.new("RegexpToken1015925646",/[\d+']+/n),
|
23
|
+
t15 = StringToken.new("StrToken42",")"),
|
24
|
+
t16 = RegexpToken.new("RegexpToken-1047402015",/\(([^\)\\]|\\[\(\)\\]?)*?\)/n)
|
25
|
+
]
|
26
|
+
productions = [
|
27
|
+
p1 = Production.new("Expr'".intern,[:Expr],SyntaxTreeBuilder.new("Expr'",["expr"],[])),
|
28
|
+
p2 = Production.new(:Expr,[t2],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
29
|
+
p3 = Production.new(:Expr,[:Hash],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
30
|
+
p4 = Production.new(:Expr,[:Array],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
31
|
+
p5 = Production.new(:Expr,[t4],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
32
|
+
p6 = Production.new(:Expr,[t3],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
33
|
+
p7 = Production.new(:Expr,[:Text],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
34
|
+
p8 = Production.new(:Expr,[:Date],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
35
|
+
p9 = Production.new(:Expr,[t5],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
36
|
+
p10 = Production.new(:Expr,[t8],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
37
|
+
p11 = Production.new(:Array,[t9, :ArrayElements, t10],SyntaxTreeBuilder.new("Array",["_", "values", "_"],[])),
|
38
|
+
p12 = Production.new(:Array,[t9, t10],SyntaxTreeBuilder.new("Array",["_", "_"],[])),
|
39
|
+
p13 = Production.new(:ArrayElements,[:"Plus-611837548"],LiftingSyntaxTreeBuilder.new(["values"],[])),
|
40
|
+
p14 = Production.new(:"Plus-611837548",[:"Plus-611837548", :ArrayElement],ArrayNodeBuilder.new([1],0,nil,nil,[],true)),
|
41
|
+
p15 = Production.new(:"Plus-611837548",[:ArrayElement],ArrayNodeBuilder.new([0],nil,nil,nil,[],true)),
|
42
|
+
p16 = Production.new(:ArrayElement,[:Array],LiftingSyntaxTreeBuilder.new(["_"],[])),
|
43
|
+
p17 = Production.new(:ArrayElement,[:Hash],LiftingSyntaxTreeBuilder.new(["_"],[])),
|
44
|
+
p18 = Production.new(:ArrayElement,[t3],LiftingSyntaxTreeBuilder.new(["_"],[])),
|
45
|
+
p19 = Production.new(:ArrayElement,[t2],LiftingSyntaxTreeBuilder.new(["_"],[])),
|
46
|
+
p20 = Production.new(:ArrayElement,[t4],LiftingSyntaxTreeBuilder.new(["_"],[])),
|
47
|
+
p21 = Production.new(:ArrayElement,[t5],LiftingSyntaxTreeBuilder.new(["_"],[])),
|
48
|
+
p22 = Production.new(:ArrayElement,[t8],LiftingSyntaxTreeBuilder.new(["_"],[])),
|
49
|
+
p23 = Production.new(:ArrayElement,[:Text],LiftingSyntaxTreeBuilder.new(["_"],[])),
|
50
|
+
p24 = Production.new(:Hash,[t11, :"Mult-611844478", t12],SyntaxTreeBuilder.new("Hash",["_", "pairs", "_"],[])),
|
51
|
+
p25 = Production.new(:Hash,[t11, t12],ArrayNodeBuilder.new([],nil,SyntaxTreeBuilder.new("Hash",["_", "pairs", "_"],[]),1,[],true)),
|
52
|
+
p26 = Production.new(:"Mult-611844478",[:"Mult-611844478", t2, :Expr],ArrayNodeBuilder.new([1, 2],0,nil,nil,[],true)),
|
53
|
+
p27 = Production.new(:"Mult-611844478",[t2, :Expr],ArrayNodeBuilder.new([0, 1],nil,nil,nil,[],true)),
|
54
|
+
p28 = Production.new(:Date,[t13, t14, t15],SyntaxTreeBuilder.new("Date",["c1", "regexptoken1015925646", "c3"],[])),
|
55
|
+
p29 = Production.new(:Text,[t16],SyntaxTreeBuilder.new("Text",["text"],[]))
|
56
|
+
]
|
57
|
+
relations = [
|
58
|
+
|
59
|
+
]
|
60
|
+
priorities = ProductionPriorities.new(relations)
|
61
|
+
action_table = [[5, 4, 9, 1024, 13, 16, 37, 2, 41, 4096, 45, 256, 49, 8, 53, 128, 57, 32768], [20, 2051], [65, 2048, 69, 2], [32, 2051], [12, 2051], [2, 1], [24, 2051], [28, 2051], [8, 2051], [4, 2051], [73, 8192], [77, 512, 81, 4, 9, 1024, 85, 16, 101, 2, 45, 256, 109, 8, 117, 128, 57, 32768], [16, 2051], [36, 2051], [112, 65439], [125, 2048, 129, 2], [96, 65439], [5, 4, 9, 1024, 13, 16, 37, 2, 41, 4096, 45, 256, 49, 8, 53, 128, 57, 32768], [137, 16384], [44, 65439], [68, 65438], [80, 65438], [81, 4, 9, 1024, 85, 16, 101, 2, 45, 256, 109, 8, 117, 128, 57, 32768, 48, 512], [60, 65438], [88, 65438], [72, 65438], [64, 65438], [76, 65438], [56, 65438], [84, 65438], [145, 512], [92, 65439], [5, 4, 9, 1024, 13, 16, 37, 2, 41, 4096, 45, 256, 49, 8, 53, 128, 57, 32768], [104, 2050], [108, 2051], [52, 65438], [40, 65439], [100, 2050]]
|
62
|
+
goto_hash = {22 => {5 => 35, 6 => 26, 2 => 23, 9 => 24}, 11 => {5 => 28, 6 => 26, 2 => 23, 3 => 30, 9 => 24, 4 => 22}, 0 => {6 => 8, 1 => 5, 2 => 4, 8 => 7, 9 => 6}, 17 => {6 => 8, 1 => 33, 2 => 4, 8 => 7, 9 => 6}, 2 => {7 => 15}, 32 => {6 => 8, 1 => 37, 2 => 4, 8 => 7, 9 => 6}}
|
63
|
+
@@parse_table_611955958 = ParseTable.new(productions,tokens,priorities,action_table,goto_hash,2,[
|
64
|
+
:REDUCE,
|
65
|
+
:SHIFT,
|
66
|
+
:ACCEPT
|
67
|
+
])
|
68
|
+
def Rpdf2txt._attr_parser
|
69
|
+
GeneralizedLrParser.new(@@parse_table_611955958)
|
70
|
+
end
|
71
|
+
end
|
@@ -0,0 +1,102 @@
|
|
1
|
+
Grammar PdfText
|
2
|
+
Tokens
|
3
|
+
NUMERIC = /-?(([0-9]*[.,_][0-9]+)|([0-9]+))/n
|
4
|
+
SPACE = /\s+/n [:Skip]
|
5
|
+
HEXSNIPPET = /[0-9A-F]+/in
|
6
|
+
ALPHANUMERIC = /[A-Z0-9\-_?\.]+/in
|
7
|
+
TEXTSNIPPET = /\(([^\)\\]|\\[\)\\]?)+\)/n
|
8
|
+
TJSNIPPET = /\((\\\(|\([^\(\)]*\)|[^\)\\]|\\[\)\\]?)*\)/n
|
9
|
+
IDENTIFIER = /^\/[\w:+\#\-\.]*(, ?[\w:+\#\-\.]*)*/n
|
10
|
+
WORD = /[a-z\.]{2,}/in
|
11
|
+
Productions
|
12
|
+
Target -> 'BT' Exprs 'ET' [: _, values, _]
|
13
|
+
Exprs -> Expr+ [^: values]
|
14
|
+
Expr -> TmElement [^: val]
|
15
|
+
| Array [^: val]
|
16
|
+
| TDElement [^: val]
|
17
|
+
| TdElement [^: val]
|
18
|
+
| TcElement [^: val]
|
19
|
+
| TWElement [^: val]
|
20
|
+
| TfElement [^: val]
|
21
|
+
| TjElement [^: val]
|
22
|
+
| TrElement [^: val]
|
23
|
+
| TjHex [^: val]
|
24
|
+
| TStarElement [^: val]
|
25
|
+
| TSElement [^: val]
|
26
|
+
| TLElement [^: val]
|
27
|
+
| TZElement [^: val]
|
28
|
+
| RgElement[^: val]
|
29
|
+
| Apostroph [^: val]
|
30
|
+
| Quotes [^: val]
|
31
|
+
| LineWidth [^: val]
|
32
|
+
| UElement [^: val]
|
33
|
+
Array -> '[' TJArrayElements /\]\s*TJ/n
|
34
|
+
[: _, values, _]
|
35
|
+
TmElement -> NUMERIC NUMERIC NUMERIC NUMERIC
|
36
|
+
NUMERIC NUMERIC 'Tm'
|
37
|
+
[Tm: xscale, alpha, beta, yscale, tmx, tmy, _]
|
38
|
+
TDElement -> NUMERIC NUMERIC 'TD'
|
39
|
+
[TD: tdleadx, tdleady,_]
|
40
|
+
TdElement -> NUMERIC NUMERIC 'Td'
|
41
|
+
[Td: xpos, ypos,_]
|
42
|
+
TcElement -> NUMERIC 'Tc'
|
43
|
+
[Tc: charspace, _]
|
44
|
+
TWElement -> NUMERIC 'Tw'
|
45
|
+
[TW: wordspace, _]
|
46
|
+
TfElement -> '/' ALPHANUMERIC NUMERIC 'Tf'
|
47
|
+
[Tf: _, fontname, fontsize, _]
|
48
|
+
TLElement -> NUMERIC 'TL'
|
49
|
+
[TL: lead, _]
|
50
|
+
TjElement -> TJSNIPPET 'Tj'
|
51
|
+
[Tj: snippet, _ ]
|
52
|
+
HexElement -> '<' HEXSNIPPET '>'
|
53
|
+
[^: _, hex, _ ]
|
54
|
+
| '<' '>'
|
55
|
+
[^: _, _ ]
|
56
|
+
TjHex -> HexElement 'Tj'
|
57
|
+
[Tjhex: hexsnippet, _ ]
|
58
|
+
TJArrayElements -> TJSingleElement+
|
59
|
+
[^: values ]
|
60
|
+
TJSingleElement -> TJSNIPPET
|
61
|
+
[: snippet ]
|
62
|
+
| NUMERIC
|
63
|
+
[: kerning ]
|
64
|
+
| HexElement
|
65
|
+
[: hexsnippet ]
|
66
|
+
| '())'
|
67
|
+
TSElement -> NUMERIC 'Ts'
|
68
|
+
[Ts: textrise]
|
69
|
+
TStarElement -> 'T*'
|
70
|
+
[TStar: linebreak ]
|
71
|
+
TZElement -> NUMERIC 'Tz'
|
72
|
+
[Tz: hscaling]
|
73
|
+
RgElement -> NUMERIC NUMERIC NUMERIC 'rg'
|
74
|
+
[Rg: _, _, _, _]
|
75
|
+
TrElement -> NUMERIC 'Tr'
|
76
|
+
[Tr: render]
|
77
|
+
Apostroph -> TJSNIPPET "'"
|
78
|
+
[Apo: aposnippet, _]
|
79
|
+
Quotes -> NUMERIC NUMERIC TJSNIPPET '"'
|
80
|
+
[Quo: wordspace, charspace, aposnippet, _]
|
81
|
+
LineWidth -> NUMERIC 'w'
|
82
|
+
[Width: width, _]
|
83
|
+
BTElement -> /^BT$/n
|
84
|
+
[BT: _]
|
85
|
+
ETElement -> /^ET$/n
|
86
|
+
[ET: _]
|
87
|
+
Hash -> '<<' (IDENTIFIER HashExpr)* '>>'
|
88
|
+
[: _, pairs, _]
|
89
|
+
HashExpr -> IDENTIFIER [^: val]
|
90
|
+
| NUMERIC [^: val]
|
91
|
+
| WORD [^: val]
|
92
|
+
UElement -> NUMERIC NUMERIC NUMERIC NUMERIC 'k'
|
93
|
+
| '/' ALPHANUMERIC /[gc]s/in
|
94
|
+
| '/' ALPHANUMERIC Hash /BDC|BMC/
|
95
|
+
| 'EMC'
|
96
|
+
| CNElements /scn?/in
|
97
|
+
| NUMERIC /[gijJMG]/n
|
98
|
+
| NUMERIC NUMERIC NUMERIC 'RG'
|
99
|
+
| '[]' NUMERIC 'd'
|
100
|
+
CNElements -> CNElement+
|
101
|
+
CNElement -> ALPHANUMERIC
|
102
|
+
| '/' ALPHANUMERIC ALPHANUMERIC?
|
@@ -0,0 +1,146 @@
|
|
1
|
+
require 'rpdf2txt-rockit/rockit'
|
2
|
+
module Rpdf2txt
|
3
|
+
# Parser for PdfText
|
4
|
+
# created by Rockit version 0.3.8 on Thu Oct 01 11:19:33 +0200 2009
|
5
|
+
# Rockit is copyright (c) 2001 Robert Feldt, feldt@ce.chalmers.se
|
6
|
+
# and licensed under GPL
|
7
|
+
# but this parser is under LGPL
|
8
|
+
tokens = [
|
9
|
+
t1 = EofToken.new("EOF",/^(�~~��~^^~5511964093)/),
|
10
|
+
t2 = Token.new("NUMERIC",/^(-?(([0-9]*[.,_][0-9]+)|([0-9]+)))/n),
|
11
|
+
t3 = Token.new("SPACE",/^(\s+)/n,:Skip),
|
12
|
+
t4 = Token.new("HEXSNIPPET",/^([0-9A-F]+)/in),
|
13
|
+
t5 = Token.new("ALPHANUMERIC",/^([A-Z0-9\-_?\.]+)/in),
|
14
|
+
t6 = Token.new("TEXTSNIPPET",/^(\(([^\)\\]|\\[\)\\]?)+\))/n),
|
15
|
+
t7 = Token.new("TJSNIPPET",/^(\((\\\(|\([^\(\)]*\)|[^\)\\]|\\[\)\\]?)*\))/n),
|
16
|
+
t8 = Token.new("IDENTIFIER",/^\/[\w:+\#\-\.]*(, ?[\w:+\#\-\.]*)*/n),
|
17
|
+
t9 = Token.new("WORD",/^([a-z\.]{2,})/in),
|
18
|
+
t10 = StringToken.new("StrToken4464918","BT"),
|
19
|
+
t11 = StringToken.new("StrToken4667865","ET"),
|
20
|
+
t12 = StringToken.new("StrToken93","["),
|
21
|
+
t13 = RegexpToken.new("RegexpToken-2048187092",/\]\s*TJ/n),
|
22
|
+
t14 = StringToken.new("StrToken5682625","Tm"),
|
23
|
+
t15 = StringToken.new("StrToken5682583","TD"),
|
24
|
+
t16 = StringToken.new("StrToken5682616","Td"),
|
25
|
+
t17 = StringToken.new("StrToken5682615","Tc"),
|
26
|
+
t18 = StringToken.new("StrToken5682636","Tw"),
|
27
|
+
t19 = StringToken.new("StrToken48","/"),
|
28
|
+
t20 = StringToken.new("StrToken5682618","Tf"),
|
29
|
+
t21 = StringToken.new("StrToken5682591","TL"),
|
30
|
+
t22 = StringToken.new("StrToken5682622","Tj"),
|
31
|
+
t23 = StringToken.new("StrToken61","<"),
|
32
|
+
t24 = StringToken.new("StrToken63",">"),
|
33
|
+
t25 = StringToken.new("StrToken343560731","())"),
|
34
|
+
t26 = StringToken.new("StrToken5682631","Ts"),
|
35
|
+
t27 = StringToken.new("StrToken5682556","T*"),
|
36
|
+
t28 = StringToken.new("StrToken5682639","Tz"),
|
37
|
+
t29 = StringToken.new("StrToken7712088","rg"),
|
38
|
+
t30 = StringToken.new("StrToken5682630","Tr"),
|
39
|
+
t31 = StringToken.new("StrToken40","'"),
|
40
|
+
t32 = StringToken.new("StrToken35","\""),
|
41
|
+
t33 = StringToken.new("StrToken122","w"),
|
42
|
+
t34 = RegexpToken.new("RegexpToken3560658",/^BT$/n),
|
43
|
+
t35 = RegexpToken.new("RegexpToken3564027",/^ET$/n),
|
44
|
+
t36 = StringToken.new("StrToken4059000","<<"),
|
45
|
+
t37 = StringToken.new("StrToken4194300",">>"),
|
46
|
+
t38 = StringToken.new("StrToken110","k"),
|
47
|
+
t39 = RegexpToken.new("RegexpToken155581294",/[gc]s/in),
|
48
|
+
t40 = RegexpToken.new("RegexpToken-2147147720",/BDC|BMC/),
|
49
|
+
t41 = StringToken.new("StrToken593066754","EMC"),
|
50
|
+
t42 = RegexpToken.new("RegexpToken5599873",/scn?/in),
|
51
|
+
t43 = RegexpToken.new("RegexpToken-265279295",/[gijJMG]/n),
|
52
|
+
t44 = StringToken.new("StrToken5547288","RG"),
|
53
|
+
t45 = StringToken.new("StrToken6156152","[]"),
|
54
|
+
t46 = StringToken.new("StrToken103","d")
|
55
|
+
]
|
56
|
+
productions = [
|
57
|
+
p1 = Production.new("Target'".intern,[:Target],SyntaxTreeBuilder.new("Target'",["target"],[])),
|
58
|
+
p2 = Production.new(:Target,[t10, :Exprs, t11],SyntaxTreeBuilder.new("Target",["_", "values", "_"],[])),
|
59
|
+
p3 = Production.new(:Exprs,[:Plus70032186462260],LiftingSyntaxTreeBuilder.new(["values"],[])),
|
60
|
+
p4 = Production.new(:Plus70032186462260,[:Plus70032186462260, :Expr],ArrayNodeBuilder.new([1],0,nil,nil,[],true)),
|
61
|
+
p5 = Production.new(:Plus70032186462260,[:Expr],ArrayNodeBuilder.new([0],nil,nil,nil,[],true)),
|
62
|
+
p6 = Production.new(:Expr,[:TmElement],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
63
|
+
p7 = Production.new(:Expr,[:Array],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
64
|
+
p8 = Production.new(:Expr,[:TDElement],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
65
|
+
p9 = Production.new(:Expr,[:TdElement],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
66
|
+
p10 = Production.new(:Expr,[:TcElement],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
67
|
+
p11 = Production.new(:Expr,[:TWElement],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
68
|
+
p12 = Production.new(:Expr,[:TfElement],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
69
|
+
p13 = Production.new(:Expr,[:TjElement],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
70
|
+
p14 = Production.new(:Expr,[:TrElement],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
71
|
+
p15 = Production.new(:Expr,[:TjHex],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
72
|
+
p16 = Production.new(:Expr,[:TStarElement],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
73
|
+
p17 = Production.new(:Expr,[:TSElement],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
74
|
+
p18 = Production.new(:Expr,[:TLElement],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
75
|
+
p19 = Production.new(:Expr,[:TZElement],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
76
|
+
p20 = Production.new(:Expr,[:RgElement],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
77
|
+
p21 = Production.new(:Expr,[:Apostroph],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
78
|
+
p22 = Production.new(:Expr,[:Quotes],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
79
|
+
p23 = Production.new(:Expr,[:LineWidth],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
80
|
+
p24 = Production.new(:Expr,[:UElement],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
81
|
+
p25 = Production.new(:Array,[t12, :TJArrayElements, t13],SyntaxTreeBuilder.new("Array",["_", "values", "_"],[])),
|
82
|
+
p26 = Production.new(:TmElement,[t2, t2, t2, t2, t2, t2, t14],SyntaxTreeBuilder.new("Tm",["xscale", "alpha", "beta", "yscale", "tmx", "tmy", "_"],[])),
|
83
|
+
p27 = Production.new(:TDElement,[t2, t2, t15],SyntaxTreeBuilder.new("TD",["tdleadx", "tdleady", "_"],[])),
|
84
|
+
p28 = Production.new(:TdElement,[t2, t2, t16],SyntaxTreeBuilder.new("Td",["xpos", "ypos", "_"],[])),
|
85
|
+
p29 = Production.new(:TcElement,[t2, t17],SyntaxTreeBuilder.new("Tc",["charspace", "_"],[])),
|
86
|
+
p30 = Production.new(:TWElement,[t2, t18],SyntaxTreeBuilder.new("TW",["wordspace", "_"],[])),
|
87
|
+
p31 = Production.new(:TfElement,[t19, t5, t2, t20],SyntaxTreeBuilder.new("Tf",["_", "fontname", "fontsize", "_"],[])),
|
88
|
+
p32 = Production.new(:TLElement,[t2, t21],SyntaxTreeBuilder.new("TL",["lead", "_"],[])),
|
89
|
+
p33 = Production.new(:TjElement,[t7, t22],SyntaxTreeBuilder.new("Tj",["snippet", "_"],[])),
|
90
|
+
p34 = Production.new(:HexElement,[t23, t4, t24],LiftingSyntaxTreeBuilder.new(["_", "hex", "_"],[])),
|
91
|
+
p35 = Production.new(:HexElement,[t23, t24],LiftingSyntaxTreeBuilder.new(["_", "_"],[])),
|
92
|
+
p36 = Production.new(:TjHex,[:HexElement, t22],SyntaxTreeBuilder.new("Tjhex",["hexsnippet", "_"],[])),
|
93
|
+
p37 = Production.new(:TJArrayElements,[:Plus70032186325260],LiftingSyntaxTreeBuilder.new(["values"],[])),
|
94
|
+
p38 = Production.new(:Plus70032186325260,[:Plus70032186325260, :TJSingleElement],ArrayNodeBuilder.new([1],0,nil,nil,[],true)),
|
95
|
+
p39 = Production.new(:Plus70032186325260,[:TJSingleElement],ArrayNodeBuilder.new([0],nil,nil,nil,[],true)),
|
96
|
+
p40 = Production.new(:TJSingleElement,[t7],SyntaxTreeBuilder.new("TJSingleElement",["snippet"],[])),
|
97
|
+
p41 = Production.new(:TJSingleElement,[t2],SyntaxTreeBuilder.new("TJSingleElement",["kerning"],[])),
|
98
|
+
p42 = Production.new(:TJSingleElement,[:HexElement],SyntaxTreeBuilder.new("TJSingleElement",["hexsnippet"],[])),
|
99
|
+
p43 = Production.new(:TJSingleElement,[t25],SyntaxTreeBuilder.new("TJSingleElement",["c1"],[])),
|
100
|
+
p44 = Production.new(:TSElement,[t2, t26],SyntaxTreeBuilder.new("Ts",["textrise"],[])),
|
101
|
+
p45 = Production.new(:TStarElement,[t27],SyntaxTreeBuilder.new("TStar",["linebreak"],[])),
|
102
|
+
p46 = Production.new(:TZElement,[t2, t28],SyntaxTreeBuilder.new("Tz",["hscaling"],[])),
|
103
|
+
p47 = Production.new(:RgElement,[t2, t2, t2, t29],SyntaxTreeBuilder.new("Rg",["_", "_", "_", "_"],[])),
|
104
|
+
p48 = Production.new(:TrElement,[t2, t30],SyntaxTreeBuilder.new("Tr",["render"],[])),
|
105
|
+
p49 = Production.new(:Apostroph,[t7, t31],SyntaxTreeBuilder.new("Apo",["aposnippet", "_"],[])),
|
106
|
+
p50 = Production.new(:Quotes,[t2, t2, t7, t32],SyntaxTreeBuilder.new("Quo",["wordspace", "charspace", "aposnippet", "_"],[])),
|
107
|
+
p51 = Production.new(:LineWidth,[t2, t33],SyntaxTreeBuilder.new("Width",["width", "_"],[])),
|
108
|
+
p52 = Production.new(:BTElement,[t34],SyntaxTreeBuilder.new("BT",["_"],[])),
|
109
|
+
p53 = Production.new(:ETElement,[t35],SyntaxTreeBuilder.new("ET",["_"],[])),
|
110
|
+
p54 = Production.new(:Hash,[t36, :Mult70032186252840, t37],SyntaxTreeBuilder.new("Hash",["_", "pairs", "_"],[])),
|
111
|
+
p55 = Production.new(:Hash,[t36, t37],ArrayNodeBuilder.new([],nil,SyntaxTreeBuilder.new("Hash",["_", "pairs", "_"],[]),1,[],true)),
|
112
|
+
p56 = Production.new(:Mult70032186252840,[:Mult70032186252840, t8, :HashExpr],ArrayNodeBuilder.new([1, 2],0,nil,nil,[],true)),
|
113
|
+
p57 = Production.new(:Mult70032186252840,[t8, :HashExpr],ArrayNodeBuilder.new([0, 1],nil,nil,nil,[],true)),
|
114
|
+
p58 = Production.new(:HashExpr,[t8],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
115
|
+
p59 = Production.new(:HashExpr,[t2],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
116
|
+
p60 = Production.new(:HashExpr,[t9],LiftingSyntaxTreeBuilder.new(["val"],[])),
|
117
|
+
p61 = Production.new(:UElement,[t2, t2, t2, t2, t38],SyntaxTreeBuilder.new("UElement",["c1", "numeric2", "numeric3", "numeric4", "c5"],[])),
|
118
|
+
p62 = Production.new(:UElement,[t19, t5, t39],SyntaxTreeBuilder.new("UElement",["c1", "alphanumeric", "regexptoken155581294"],[])),
|
119
|
+
p63 = Production.new(:UElement,[t19, t5, :Hash, t40],SyntaxTreeBuilder.new("UElement",["c1", "alphanumeric", "hash", "regexptoken-2147147720"],[])),
|
120
|
+
p64 = Production.new(:UElement,[t41],SyntaxTreeBuilder.new("UElement",["c1"],[])),
|
121
|
+
p65 = Production.new(:UElement,[:CNElements, t42],SyntaxTreeBuilder.new("UElement",["cnelements", "regexptoken5599873"],[])),
|
122
|
+
p66 = Production.new(:UElement,[t2, t43],SyntaxTreeBuilder.new("UElement",["c1", "regexptoken-265279295"],[])),
|
123
|
+
p67 = Production.new(:UElement,[t2, t2, t2, t44],SyntaxTreeBuilder.new("UElement",["c1", "numeric2", "numeric3", "c4"],[])),
|
124
|
+
p68 = Production.new(:UElement,[t45, t2, t46],SyntaxTreeBuilder.new("UElement",["c1", "numeric", "c3"],[])),
|
125
|
+
p69 = Production.new(:CNElements,[:Plus70032186212980],SyntaxTreeBuilder.new("CNElements",["plus"],[])),
|
126
|
+
p70 = Production.new(:Plus70032186212980,[:Plus70032186212980, :CNElement],ArrayNodeBuilder.new([1],0,nil,nil,[],true)),
|
127
|
+
p71 = Production.new(:Plus70032186212980,[:CNElement],ArrayNodeBuilder.new([0],nil,nil,nil,[],true)),
|
128
|
+
p72 = Production.new(:CNElement,[t5],SyntaxTreeBuilder.new("CNElement",["c1"],[])),
|
129
|
+
p73 = Production.new(:CNElement,[t19, t5, t5],SyntaxTreeBuilder.new("CNElement",["c1", "alphanumeric", "maybe"],[])),
|
130
|
+
p74 = Production.new(:CNElement,[t19, t5],SyntaxTreeBuilder.new("CNElement",["c1", "alphanumeric", "maybe"],[2]))
|
131
|
+
]
|
132
|
+
relations = [
|
133
|
+
|
134
|
+
]
|
135
|
+
priorities = ProductionPriorities.new(relations)
|
136
|
+
action_table = [[5, 512], [13, 16, 57, 2, 69, 4194304, 73, 262144, 85, 64, 89, 2048, 125, 1099511627776, 129, 67108864, 141, 17592186044416], [2, 1], [284, 2199023517712], [88, 70342974373338], [80, 70342974373338], [72, 70342974373338], [60, 70342974373338], [153, 2097152], [84, 70342974373338], [52, 70342974373338], [28, 70342974373338], [157, 2199023255552], [36, 70342974373338], [161, 4294967296, 165, 33554432, 169, 65536, 173, 536870912, 177, 4398046511104, 181, 2, 185, 134217728, 189, 1048576, 193, 131072], [24, 70342974373338], [16, 70342974373338], [197, 8, 201, 8388608], [205, 16], [32, 70342974373338], [13, 16, 209, 262144, 272, 2199023255552], [217, 2097152, 221, 1073741824], [233, 2, 69, 4194304, 237, 16777216, 241, 64], [92, 70342974373338], [76, 70342974373338], [64, 70342974373338], [40, 70342974373338], [20, 70342974373338], [68, 70342974373338], [13, 16, 57, 2, 69, 4194304, 73, 262144, 85, 64, 89, 2048, 125, 1099511627776, 129, 67108864, 141, 17592186044416, 8, 1024], [257, 1024], [252, 70342974373338], [176, 70342974373338], [56, 70342974373338], [280, 2199023517712], [261, 2], [48, 70342974373338], [44, 70342974373338], [140, 70342974373338], [256, 70342974373338], [200, 70342974373338], [172, 70342974373338], [112, 70342974373338], [188, 70342974373338], [260, 70342974373338], [265, 2, 269, 64, 273, 16384, 277, 32768], [180, 70342974373338], [124, 70342974373338], [116, 70342974373338], [281, 8388608], [136, 31461450], [285, 16, 289, 34359738368, 297, 2, 301, 274877906944, 292, 2199023517712], [305, 16], [276, 2199023517712], [128, 70342974373338], [192, 70342974373338], [164, 29364298], [233, 2, 69, 4194304, 237, 16777216, 241, 64, 144, 4096], [160, 29364298], [168, 29364298], [156, 29364298], [152, 29364298], [313, 4096], [12, 70342974373338], [4, 1], [317, 35184372088832], [321, 8796093022208, 325, 268435456, 329, 2], [333, 2147483648], [104, 70342974373338], [108, 70342974373338], [132, 31461450], [288, 2199023517712], [341, 68719476736, 345, 128], [349, 549755813888], [353, 524288], [244, 70342974373338], [285, 16, 292, 2199023517712], [148, 29364298], [96, 70342974373338], [268, 70342974373338], [264, 70342974373338], [184, 70342974373338], [357, 137438953472, 361, 2], [196, 70342974373338], [365, 68719476736, 369, 128], [216, 549755813888], [373, 2, 381, 128, 385, 256], [248, 70342974373338], [120, 70342974373338], [240, 70342974373338], [389, 2], [212, 549755813888], [373, 2, 381, 128, 385, 256], [232, 68719476864], [224, 68719476864], [228, 68719476864], [236, 68719476864], [397, 8192], [220, 68719476864], [100, 70342974373338]]
|
137
|
+
goto_hash = {22 => {16 => 62, 17 => 57, 18 => 61, 14 => 56}, 0 => {1 => 2}, 72 => {30 => 84}, 1 => {5 => 15, 11 => 37, 22 => 24, 33 => 12, 6 => 27, 12 => 28, 34 => 20, 23 => 10, 7 => 11, 13 => 36, 35 => 34, 2 => 30, 24 => 5, 19 => 25, 8 => 19, 3 => 29, 25 => 9, 14 => 8, 9 => 13, 20 => 7, 15 => 33, 4 => 16, 26 => 4, 10 => 26, 32 => 23, 21 => 6}, 51 => {29 => 73}, 29 => {5 => 15, 11 => 37, 22 => 24, 33 => 12, 6 => 27, 12 => 28, 34 => 20, 23 => 10, 7 => 11, 13 => 36, 35 => 34, 24 => 5, 19 => 25, 8 => 19, 25 => 9, 14 => 8, 9 => 13, 20 => 7, 15 => 33, 4 => 63, 26 => 4, 10 => 26, 32 => 23, 21 => 6}, 57 => {18 => 77, 14 => 56}, 86 => {31 => 94}, 20 => {35 => 53}, 92 => {31 => 98}}
|
138
|
+
@@parse_table70032185719080 = ParseTable.new(productions,tokens,priorities,action_table,goto_hash,2,[
|
139
|
+
:REDUCE,
|
140
|
+
:SHIFT,
|
141
|
+
:ACCEPT
|
142
|
+
])
|
143
|
+
def Rpdf2txt._text_parser
|
144
|
+
GeneralizedLrParser.new(@@parse_table70032185719080)
|
145
|
+
end
|
146
|
+
end
|