PyMuPDF 1.24.11__cp38-abi3-win_amd64.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (99) hide show
  1. PyMuPDF-1.24.11.dist-info/COPYING +1 -0
  2. PyMuPDF-1.24.11.dist-info/METADATA +83 -0
  3. PyMuPDF-1.24.11.dist-info/README.md +60 -0
  4. PyMuPDF-1.24.11.dist-info/RECORD +99 -0
  5. PyMuPDF-1.24.11.dist-info/WHEEL +4 -0
  6. PyMuPDF-1.24.11.dist-info/entry_points.txt +3 -0
  7. fitz/__init__.py +11 -0
  8. fitz/table.py +2 -0
  9. fitz/utils.py +2 -0
  10. pymupdf/__init__.py +22122 -0
  11. pymupdf/__main__.py +1146 -0
  12. pymupdf/_apply_pages.py +253 -0
  13. pymupdf/_build.py +1 -0
  14. pymupdf/_extra.pyd +0 -0
  15. pymupdf/_mupdf.pyd +0 -0
  16. pymupdf/extra.py +214 -0
  17. pymupdf/mupdf-devel/include/mupdf/fitz/archive.h +444 -0
  18. pymupdf/mupdf-devel/include/mupdf/fitz/band-writer.h +117 -0
  19. pymupdf/mupdf-devel/include/mupdf/fitz/bidi.h +90 -0
  20. pymupdf/mupdf-devel/include/mupdf/fitz/bitmap.h +175 -0
  21. pymupdf/mupdf-devel/include/mupdf/fitz/buffer.h +250 -0
  22. pymupdf/mupdf-devel/include/mupdf/fitz/color.h +427 -0
  23. pymupdf/mupdf-devel/include/mupdf/fitz/compress.h +88 -0
  24. pymupdf/mupdf-devel/include/mupdf/fitz/compressed-buffer.h +185 -0
  25. pymupdf/mupdf-devel/include/mupdf/fitz/config.h +223 -0
  26. pymupdf/mupdf-devel/include/mupdf/fitz/context.h +1006 -0
  27. pymupdf/mupdf-devel/include/mupdf/fitz/crypt.h +270 -0
  28. pymupdf/mupdf-devel/include/mupdf/fitz/device.h +654 -0
  29. pymupdf/mupdf-devel/include/mupdf/fitz/display-list.h +142 -0
  30. pymupdf/mupdf-devel/include/mupdf/fitz/document.h +1108 -0
  31. pymupdf/mupdf-devel/include/mupdf/fitz/export.h +52 -0
  32. pymupdf/mupdf-devel/include/mupdf/fitz/filter.h +263 -0
  33. pymupdf/mupdf-devel/include/mupdf/fitz/font.h +815 -0
  34. pymupdf/mupdf-devel/include/mupdf/fitz/geometry.h +818 -0
  35. pymupdf/mupdf-devel/include/mupdf/fitz/getopt.h +128 -0
  36. pymupdf/mupdf-devel/include/mupdf/fitz/glyph-cache.h +96 -0
  37. pymupdf/mupdf-devel/include/mupdf/fitz/glyph.h +81 -0
  38. pymupdf/mupdf-devel/include/mupdf/fitz/hash.h +126 -0
  39. pymupdf/mupdf-devel/include/mupdf/fitz/heap-imp.h +163 -0
  40. pymupdf/mupdf-devel/include/mupdf/fitz/heap.h +140 -0
  41. pymupdf/mupdf-devel/include/mupdf/fitz/image.h +443 -0
  42. pymupdf/mupdf-devel/include/mupdf/fitz/link.h +130 -0
  43. pymupdf/mupdf-devel/include/mupdf/fitz/log.h +61 -0
  44. pymupdf/mupdf-devel/include/mupdf/fitz/outline.h +228 -0
  45. pymupdf/mupdf-devel/include/mupdf/fitz/output-svg.h +64 -0
  46. pymupdf/mupdf-devel/include/mupdf/fitz/output.h +415 -0
  47. pymupdf/mupdf-devel/include/mupdf/fitz/path.h +447 -0
  48. pymupdf/mupdf-devel/include/mupdf/fitz/pixmap.h +501 -0
  49. pymupdf/mupdf-devel/include/mupdf/fitz/pool.h +68 -0
  50. pymupdf/mupdf-devel/include/mupdf/fitz/separation.h +138 -0
  51. pymupdf/mupdf-devel/include/mupdf/fitz/shade.h +233 -0
  52. pymupdf/mupdf-devel/include/mupdf/fitz/store.h +456 -0
  53. pymupdf/mupdf-devel/include/mupdf/fitz/story-writer.h +209 -0
  54. pymupdf/mupdf-devel/include/mupdf/fitz/story.h +232 -0
  55. pymupdf/mupdf-devel/include/mupdf/fitz/stream.h +646 -0
  56. pymupdf/mupdf-devel/include/mupdf/fitz/string-util.h +286 -0
  57. pymupdf/mupdf-devel/include/mupdf/fitz/structured-text.h +365 -0
  58. pymupdf/mupdf-devel/include/mupdf/fitz/system.h +459 -0
  59. pymupdf/mupdf-devel/include/mupdf/fitz/text.h +209 -0
  60. pymupdf/mupdf-devel/include/mupdf/fitz/track-usage.h +57 -0
  61. pymupdf/mupdf-devel/include/mupdf/fitz/transition.h +76 -0
  62. pymupdf/mupdf-devel/include/mupdf/fitz/tree.h +62 -0
  63. pymupdf/mupdf-devel/include/mupdf/fitz/types.h +41 -0
  64. pymupdf/mupdf-devel/include/mupdf/fitz/util.h +151 -0
  65. pymupdf/mupdf-devel/include/mupdf/fitz/version.h +31 -0
  66. pymupdf/mupdf-devel/include/mupdf/fitz/write-pixmap.h +499 -0
  67. pymupdf/mupdf-devel/include/mupdf/fitz/writer.h +266 -0
  68. pymupdf/mupdf-devel/include/mupdf/fitz/xml.h +397 -0
  69. pymupdf/mupdf-devel/include/mupdf/fitz.h +97 -0
  70. pymupdf/mupdf-devel/include/mupdf/helpers/mu-office-lib.h +666 -0
  71. pymupdf/mupdf-devel/include/mupdf/helpers/mu-threads.h +280 -0
  72. pymupdf/mupdf-devel/include/mupdf/helpers/pkcs7-openssl.h +48 -0
  73. pymupdf/mupdf-devel/include/mupdf/html.h +53 -0
  74. pymupdf/mupdf-devel/include/mupdf/memento.h +423 -0
  75. pymupdf/mupdf-devel/include/mupdf/pdf/annot.h +965 -0
  76. pymupdf/mupdf-devel/include/mupdf/pdf/clean.h +48 -0
  77. pymupdf/mupdf-devel/include/mupdf/pdf/cmap.h +145 -0
  78. pymupdf/mupdf-devel/include/mupdf/pdf/crypt.h +107 -0
  79. pymupdf/mupdf-devel/include/mupdf/pdf/document.h +842 -0
  80. pymupdf/mupdf-devel/include/mupdf/pdf/event.h +167 -0
  81. pymupdf/mupdf-devel/include/mupdf/pdf/font.h +168 -0
  82. pymupdf/mupdf-devel/include/mupdf/pdf/form.h +380 -0
  83. pymupdf/mupdf-devel/include/mupdf/pdf/image-rewriter.h +78 -0
  84. pymupdf/mupdf-devel/include/mupdf/pdf/interpret.h +492 -0
  85. pymupdf/mupdf-devel/include/mupdf/pdf/javascript.h +43 -0
  86. pymupdf/mupdf-devel/include/mupdf/pdf/name-table.h +596 -0
  87. pymupdf/mupdf-devel/include/mupdf/pdf/object.h +435 -0
  88. pymupdf/mupdf-devel/include/mupdf/pdf/page.h +316 -0
  89. pymupdf/mupdf-devel/include/mupdf/pdf/parse.h +61 -0
  90. pymupdf/mupdf-devel/include/mupdf/pdf/resource.h +133 -0
  91. pymupdf/mupdf-devel/include/mupdf/pdf/xref.h +300 -0
  92. pymupdf/mupdf-devel/include/mupdf/pdf.h +57 -0
  93. pymupdf/mupdf-devel/include/mupdf/ucdn.h +452 -0
  94. pymupdf/mupdf-devel/lib/mupdfcpp64.lib +0 -0
  95. pymupdf/mupdf.py +58506 -0
  96. pymupdf/mupdfcpp64.dll +0 -0
  97. pymupdf/pymupdf.py +2 -0
  98. pymupdf/table.py +2355 -0
  99. pymupdf/utils.py +5880 -0
@@ -0,0 +1,452 @@
1
+ /*
2
+ * Copyright (C) 2012 Grigori Goronzy <greg@kinoho.net>
3
+ *
4
+ * Permission to use, copy, modify, and/or distribute this software for any
5
+ * purpose with or without fee is hereby granted, provided that the above
6
+ * copyright notice and this permission notice appear in all copies.
7
+ *
8
+ * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
9
+ * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
10
+ * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
11
+ * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
12
+ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
13
+ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
14
+ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
15
+ */
16
+
17
+ #ifndef UCDN_H
18
+ #define UCDN_H
19
+
20
+ #ifdef __cplusplus
21
+ extern "C" {
22
+ #endif
23
+
24
+ #include "fitz/system.h"
25
+
26
+ #define UCDN_EAST_ASIAN_F 0
27
+ #define UCDN_EAST_ASIAN_H 1
28
+ #define UCDN_EAST_ASIAN_W 2
29
+ #define UCDN_EAST_ASIAN_NA 3
30
+ #define UCDN_EAST_ASIAN_A 4
31
+ #define UCDN_EAST_ASIAN_N 5
32
+
33
+ #define UCDN_SCRIPT_COMMON 0
34
+ #define UCDN_SCRIPT_LATIN 1
35
+ #define UCDN_SCRIPT_GREEK 2
36
+ #define UCDN_SCRIPT_CYRILLIC 3
37
+ #define UCDN_SCRIPT_ARMENIAN 4
38
+ #define UCDN_SCRIPT_HEBREW 5
39
+ #define UCDN_SCRIPT_ARABIC 6
40
+ #define UCDN_SCRIPT_SYRIAC 7
41
+ #define UCDN_SCRIPT_THAANA 8
42
+ #define UCDN_SCRIPT_DEVANAGARI 9
43
+ #define UCDN_SCRIPT_BENGALI 10
44
+ #define UCDN_SCRIPT_GURMUKHI 11
45
+ #define UCDN_SCRIPT_GUJARATI 12
46
+ #define UCDN_SCRIPT_ORIYA 13
47
+ #define UCDN_SCRIPT_TAMIL 14
48
+ #define UCDN_SCRIPT_TELUGU 15
49
+ #define UCDN_SCRIPT_KANNADA 16
50
+ #define UCDN_SCRIPT_MALAYALAM 17
51
+ #define UCDN_SCRIPT_SINHALA 18
52
+ #define UCDN_SCRIPT_THAI 19
53
+ #define UCDN_SCRIPT_LAO 20
54
+ #define UCDN_SCRIPT_TIBETAN 21
55
+ #define UCDN_SCRIPT_MYANMAR 22
56
+ #define UCDN_SCRIPT_GEORGIAN 23
57
+ #define UCDN_SCRIPT_HANGUL 24
58
+ #define UCDN_SCRIPT_ETHIOPIC 25
59
+ #define UCDN_SCRIPT_CHEROKEE 26
60
+ #define UCDN_SCRIPT_CANADIAN_ABORIGINAL 27
61
+ #define UCDN_SCRIPT_OGHAM 28
62
+ #define UCDN_SCRIPT_RUNIC 29
63
+ #define UCDN_SCRIPT_KHMER 30
64
+ #define UCDN_SCRIPT_MONGOLIAN 31
65
+ #define UCDN_SCRIPT_HIRAGANA 32
66
+ #define UCDN_SCRIPT_KATAKANA 33
67
+ #define UCDN_SCRIPT_BOPOMOFO 34
68
+ #define UCDN_SCRIPT_HAN 35
69
+ #define UCDN_SCRIPT_YI 36
70
+ #define UCDN_SCRIPT_OLD_ITALIC 37
71
+ #define UCDN_SCRIPT_GOTHIC 38
72
+ #define UCDN_SCRIPT_DESERET 39
73
+ #define UCDN_SCRIPT_INHERITED 40
74
+ #define UCDN_SCRIPT_TAGALOG 41
75
+ #define UCDN_SCRIPT_HANUNOO 42
76
+ #define UCDN_SCRIPT_BUHID 43
77
+ #define UCDN_SCRIPT_TAGBANWA 44
78
+ #define UCDN_SCRIPT_LIMBU 45
79
+ #define UCDN_SCRIPT_TAI_LE 46
80
+ #define UCDN_SCRIPT_LINEAR_B 47
81
+ #define UCDN_SCRIPT_UGARITIC 48
82
+ #define UCDN_SCRIPT_SHAVIAN 49
83
+ #define UCDN_SCRIPT_OSMANYA 50
84
+ #define UCDN_SCRIPT_CYPRIOT 51
85
+ #define UCDN_SCRIPT_BRAILLE 52
86
+ #define UCDN_SCRIPT_BUGINESE 53
87
+ #define UCDN_SCRIPT_COPTIC 54
88
+ #define UCDN_SCRIPT_NEW_TAI_LUE 55
89
+ #define UCDN_SCRIPT_GLAGOLITIC 56
90
+ #define UCDN_SCRIPT_TIFINAGH 57
91
+ #define UCDN_SCRIPT_SYLOTI_NAGRI 58
92
+ #define UCDN_SCRIPT_OLD_PERSIAN 59
93
+ #define UCDN_SCRIPT_KHAROSHTHI 60
94
+ #define UCDN_SCRIPT_BALINESE 61
95
+ #define UCDN_SCRIPT_CUNEIFORM 62
96
+ #define UCDN_SCRIPT_PHOENICIAN 63
97
+ #define UCDN_SCRIPT_PHAGS_PA 64
98
+ #define UCDN_SCRIPT_NKO 65
99
+ #define UCDN_SCRIPT_SUNDANESE 66
100
+ #define UCDN_SCRIPT_LEPCHA 67
101
+ #define UCDN_SCRIPT_OL_CHIKI 68
102
+ #define UCDN_SCRIPT_VAI 69
103
+ #define UCDN_SCRIPT_SAURASHTRA 70
104
+ #define UCDN_SCRIPT_KAYAH_LI 71
105
+ #define UCDN_SCRIPT_REJANG 72
106
+ #define UCDN_SCRIPT_LYCIAN 73
107
+ #define UCDN_SCRIPT_CARIAN 74
108
+ #define UCDN_SCRIPT_LYDIAN 75
109
+ #define UCDN_SCRIPT_CHAM 76
110
+ #define UCDN_SCRIPT_TAI_THAM 77
111
+ #define UCDN_SCRIPT_TAI_VIET 78
112
+ #define UCDN_SCRIPT_AVESTAN 79
113
+ #define UCDN_SCRIPT_EGYPTIAN_HIEROGLYPHS 80
114
+ #define UCDN_SCRIPT_SAMARITAN 81
115
+ #define UCDN_SCRIPT_LISU 82
116
+ #define UCDN_SCRIPT_BAMUM 83
117
+ #define UCDN_SCRIPT_JAVANESE 84
118
+ #define UCDN_SCRIPT_MEETEI_MAYEK 85
119
+ #define UCDN_SCRIPT_IMPERIAL_ARAMAIC 86
120
+ #define UCDN_SCRIPT_OLD_SOUTH_ARABIAN 87
121
+ #define UCDN_SCRIPT_INSCRIPTIONAL_PARTHIAN 88
122
+ #define UCDN_SCRIPT_INSCRIPTIONAL_PAHLAVI 89
123
+ #define UCDN_SCRIPT_OLD_TURKIC 90
124
+ #define UCDN_SCRIPT_KAITHI 91
125
+ #define UCDN_SCRIPT_BATAK 92
126
+ #define UCDN_SCRIPT_BRAHMI 93
127
+ #define UCDN_SCRIPT_MANDAIC 94
128
+ #define UCDN_SCRIPT_CHAKMA 95
129
+ #define UCDN_SCRIPT_MEROITIC_CURSIVE 96
130
+ #define UCDN_SCRIPT_MEROITIC_HIEROGLYPHS 97
131
+ #define UCDN_SCRIPT_MIAO 98
132
+ #define UCDN_SCRIPT_SHARADA 99
133
+ #define UCDN_SCRIPT_SORA_SOMPENG 100
134
+ #define UCDN_SCRIPT_TAKRI 101
135
+ #define UCDN_SCRIPT_UNKNOWN 102
136
+ #define UCDN_SCRIPT_BASSA_VAH 103
137
+ #define UCDN_SCRIPT_CAUCASIAN_ALBANIAN 104
138
+ #define UCDN_SCRIPT_DUPLOYAN 105
139
+ #define UCDN_SCRIPT_ELBASAN 106
140
+ #define UCDN_SCRIPT_GRANTHA 107
141
+ #define UCDN_SCRIPT_KHOJKI 108
142
+ #define UCDN_SCRIPT_KHUDAWADI 109
143
+ #define UCDN_SCRIPT_LINEAR_A 110
144
+ #define UCDN_SCRIPT_MAHAJANI 111
145
+ #define UCDN_SCRIPT_MANICHAEAN 112
146
+ #define UCDN_SCRIPT_MENDE_KIKAKUI 113
147
+ #define UCDN_SCRIPT_MODI 114
148
+ #define UCDN_SCRIPT_MRO 115
149
+ #define UCDN_SCRIPT_NABATAEAN 116
150
+ #define UCDN_SCRIPT_OLD_NORTH_ARABIAN 117
151
+ #define UCDN_SCRIPT_OLD_PERMIC 118
152
+ #define UCDN_SCRIPT_PAHAWH_HMONG 119
153
+ #define UCDN_SCRIPT_PALMYRENE 120
154
+ #define UCDN_SCRIPT_PAU_CIN_HAU 121
155
+ #define UCDN_SCRIPT_PSALTER_PAHLAVI 122
156
+ #define UCDN_SCRIPT_SIDDHAM 123
157
+ #define UCDN_SCRIPT_TIRHUTA 124
158
+ #define UCDN_SCRIPT_WARANG_CITI 125
159
+ #define UCDN_SCRIPT_AHOM 126
160
+ #define UCDN_SCRIPT_ANATOLIAN_HIEROGLYPHS 127
161
+ #define UCDN_SCRIPT_HATRAN 128
162
+ #define UCDN_SCRIPT_MULTANI 129
163
+ #define UCDN_SCRIPT_OLD_HUNGARIAN 130
164
+ #define UCDN_SCRIPT_SIGNWRITING 131
165
+ #define UCDN_SCRIPT_ADLAM 132
166
+ #define UCDN_SCRIPT_BHAIKSUKI 133
167
+ #define UCDN_SCRIPT_MARCHEN 134
168
+ #define UCDN_SCRIPT_NEWA 135
169
+ #define UCDN_SCRIPT_OSAGE 136
170
+ #define UCDN_SCRIPT_TANGUT 137
171
+ #define UCDN_SCRIPT_MASARAM_GONDI 138
172
+ #define UCDN_SCRIPT_NUSHU 139
173
+ #define UCDN_SCRIPT_SOYOMBO 140
174
+ #define UCDN_SCRIPT_ZANABAZAR_SQUARE 141
175
+ #define UCDN_SCRIPT_DOGRA 142
176
+ #define UCDN_SCRIPT_GUNJALA_GONDI 143
177
+ #define UCDN_SCRIPT_HANIFI_ROHINGYA 144
178
+ #define UCDN_SCRIPT_MAKASAR 145
179
+ #define UCDN_SCRIPT_MEDEFAIDRIN 146
180
+ #define UCDN_SCRIPT_OLD_SOGDIAN 147
181
+ #define UCDN_SCRIPT_SOGDIAN 148
182
+ #define UCDN_SCRIPT_ELYMAIC 149
183
+ #define UCDN_SCRIPT_NANDINAGARI 150
184
+ #define UCDN_SCRIPT_NYIAKENG_PUACHUE_HMONG 151
185
+ #define UCDN_SCRIPT_WANCHO 152
186
+ #define UCDN_SCRIPT_CHORASMIAN 153
187
+ #define UCDN_SCRIPT_DIVES_AKURU 154
188
+ #define UCDN_SCRIPT_KHITAN_SMALL_SCRIPT 155
189
+ #define UCDN_SCRIPT_YEZIDI 156
190
+ #define UCDN_SCRIPT_VITHKUQI 157
191
+ #define UCDN_SCRIPT_OLD_UYGHUR 158
192
+ #define UCDN_SCRIPT_CYPRO_MINOAN 159
193
+ #define UCDN_SCRIPT_TANGSA 160
194
+ #define UCDN_SCRIPT_TOTO 161
195
+ #define UCDN_SCRIPT_KAWI 162
196
+ #define UCDN_SCRIPT_NAG_MUNDARI 163
197
+ #define UCDN_LAST_SCRIPT 163
198
+
199
+ #define UCDN_LINEBREAK_CLASS_OP 0
200
+ #define UCDN_LINEBREAK_CLASS_CL 1
201
+ #define UCDN_LINEBREAK_CLASS_CP 2
202
+ #define UCDN_LINEBREAK_CLASS_QU 3
203
+ #define UCDN_LINEBREAK_CLASS_GL 4
204
+ #define UCDN_LINEBREAK_CLASS_NS 5
205
+ #define UCDN_LINEBREAK_CLASS_EX 6
206
+ #define UCDN_LINEBREAK_CLASS_SY 7
207
+ #define UCDN_LINEBREAK_CLASS_IS 8
208
+ #define UCDN_LINEBREAK_CLASS_PR 9
209
+ #define UCDN_LINEBREAK_CLASS_PO 10
210
+ #define UCDN_LINEBREAK_CLASS_NU 11
211
+ #define UCDN_LINEBREAK_CLASS_AL 12
212
+ #define UCDN_LINEBREAK_CLASS_HL 13
213
+ #define UCDN_LINEBREAK_CLASS_ID 14
214
+ #define UCDN_LINEBREAK_CLASS_IN 15
215
+ #define UCDN_LINEBREAK_CLASS_HY 16
216
+ #define UCDN_LINEBREAK_CLASS_BA 17
217
+ #define UCDN_LINEBREAK_CLASS_BB 18
218
+ #define UCDN_LINEBREAK_CLASS_B2 19
219
+ #define UCDN_LINEBREAK_CLASS_ZW 20
220
+ #define UCDN_LINEBREAK_CLASS_CM 21
221
+ #define UCDN_LINEBREAK_CLASS_WJ 22
222
+ #define UCDN_LINEBREAK_CLASS_H2 23
223
+ #define UCDN_LINEBREAK_CLASS_H3 24
224
+ #define UCDN_LINEBREAK_CLASS_JL 25
225
+ #define UCDN_LINEBREAK_CLASS_JV 26
226
+ #define UCDN_LINEBREAK_CLASS_JT 27
227
+ #define UCDN_LINEBREAK_CLASS_RI 28
228
+ #define UCDN_LINEBREAK_CLASS_AI 29
229
+ #define UCDN_LINEBREAK_CLASS_BK 30
230
+ #define UCDN_LINEBREAK_CLASS_CB 31
231
+ #define UCDN_LINEBREAK_CLASS_CJ 32
232
+ #define UCDN_LINEBREAK_CLASS_CR 33
233
+ #define UCDN_LINEBREAK_CLASS_LF 34
234
+ #define UCDN_LINEBREAK_CLASS_NL 35
235
+ #define UCDN_LINEBREAK_CLASS_SA 36
236
+ #define UCDN_LINEBREAK_CLASS_SG 37
237
+ #define UCDN_LINEBREAK_CLASS_SP 38
238
+ #define UCDN_LINEBREAK_CLASS_XX 39
239
+ #define UCDN_LINEBREAK_CLASS_ZWJ 40
240
+ #define UCDN_LINEBREAK_CLASS_EB 41
241
+ #define UCDN_LINEBREAK_CLASS_EM 42
242
+
243
+ #define UCDN_GENERAL_CATEGORY_CC 0
244
+ #define UCDN_GENERAL_CATEGORY_CF 1
245
+ #define UCDN_GENERAL_CATEGORY_CN 2
246
+ #define UCDN_GENERAL_CATEGORY_CO 3
247
+ #define UCDN_GENERAL_CATEGORY_CS 4
248
+ #define UCDN_GENERAL_CATEGORY_LL 5
249
+ #define UCDN_GENERAL_CATEGORY_LM 6
250
+ #define UCDN_GENERAL_CATEGORY_LO 7
251
+ #define UCDN_GENERAL_CATEGORY_LT 8
252
+ #define UCDN_GENERAL_CATEGORY_LU 9
253
+ #define UCDN_GENERAL_CATEGORY_MC 10
254
+ #define UCDN_GENERAL_CATEGORY_ME 11
255
+ #define UCDN_GENERAL_CATEGORY_MN 12
256
+ #define UCDN_GENERAL_CATEGORY_ND 13
257
+ #define UCDN_GENERAL_CATEGORY_NL 14
258
+ #define UCDN_GENERAL_CATEGORY_NO 15
259
+ #define UCDN_GENERAL_CATEGORY_PC 16
260
+ #define UCDN_GENERAL_CATEGORY_PD 17
261
+ #define UCDN_GENERAL_CATEGORY_PE 18
262
+ #define UCDN_GENERAL_CATEGORY_PF 19
263
+ #define UCDN_GENERAL_CATEGORY_PI 20
264
+ #define UCDN_GENERAL_CATEGORY_PO 21
265
+ #define UCDN_GENERAL_CATEGORY_PS 22
266
+ #define UCDN_GENERAL_CATEGORY_SC 23
267
+ #define UCDN_GENERAL_CATEGORY_SK 24
268
+ #define UCDN_GENERAL_CATEGORY_SM 25
269
+ #define UCDN_GENERAL_CATEGORY_SO 26
270
+ #define UCDN_GENERAL_CATEGORY_ZL 27
271
+ #define UCDN_GENERAL_CATEGORY_ZP 28
272
+ #define UCDN_GENERAL_CATEGORY_ZS 29
273
+
274
+ #define UCDN_BIDI_CLASS_L 0
275
+ #define UCDN_BIDI_CLASS_LRE 1
276
+ #define UCDN_BIDI_CLASS_LRO 2
277
+ #define UCDN_BIDI_CLASS_R 3
278
+ #define UCDN_BIDI_CLASS_AL 4
279
+ #define UCDN_BIDI_CLASS_RLE 5
280
+ #define UCDN_BIDI_CLASS_RLO 6
281
+ #define UCDN_BIDI_CLASS_PDF 7
282
+ #define UCDN_BIDI_CLASS_EN 8
283
+ #define UCDN_BIDI_CLASS_ES 9
284
+ #define UCDN_BIDI_CLASS_ET 10
285
+ #define UCDN_BIDI_CLASS_AN 11
286
+ #define UCDN_BIDI_CLASS_CS 12
287
+ #define UCDN_BIDI_CLASS_NSM 13
288
+ #define UCDN_BIDI_CLASS_BN 14
289
+ #define UCDN_BIDI_CLASS_B 15
290
+ #define UCDN_BIDI_CLASS_S 16
291
+ #define UCDN_BIDI_CLASS_WS 17
292
+ #define UCDN_BIDI_CLASS_ON 18
293
+ #define UCDN_BIDI_CLASS_LRI 19
294
+ #define UCDN_BIDI_CLASS_RLI 20
295
+ #define UCDN_BIDI_CLASS_FSI 21
296
+ #define UCDN_BIDI_CLASS_PDI 22
297
+
298
+ #define UCDN_BIDI_PAIRED_BRACKET_TYPE_OPEN 0
299
+ #define UCDN_BIDI_PAIRED_BRACKET_TYPE_CLOSE 1
300
+ #define UCDN_BIDI_PAIRED_BRACKET_TYPE_NONE 2
301
+
302
+ /**
303
+ * Return version of the Unicode database.
304
+ *
305
+ * @return Unicode database version
306
+ */
307
+ const char *ucdn_get_unicode_version(void);
308
+
309
+ /**
310
+ * Get combining class of a codepoint.
311
+ *
312
+ * @param code Unicode codepoint
313
+ * @return combining class value, as defined in UAX#44
314
+ */
315
+ int ucdn_get_combining_class(uint32_t code);
316
+
317
+ /**
318
+ * Get east-asian width of a codepoint.
319
+ *
320
+ * @param code Unicode codepoint
321
+ * @return value according to UCDN_EAST_ASIAN_* and as defined in UAX#11.
322
+ */
323
+ int ucdn_get_east_asian_width(uint32_t code);
324
+
325
+ /**
326
+ * Get general category of a codepoint.
327
+ *
328
+ * @param code Unicode codepoint
329
+ * @return value according to UCDN_GENERAL_CATEGORY_* and as defined in
330
+ * UAX#44.
331
+ */
332
+ int ucdn_get_general_category(uint32_t code);
333
+
334
+ /**
335
+ * Get bidirectional class of a codepoint.
336
+ *
337
+ * @param code Unicode codepoint
338
+ * @return value according to UCDN_BIDI_CLASS_* and as defined in UAX#44.
339
+ */
340
+ int ucdn_get_bidi_class(uint32_t code);
341
+
342
+ /**
343
+ * Get script of a codepoint.
344
+ *
345
+ * @param code Unicode codepoint
346
+ * @return value according to UCDN_SCRIPT_* and as defined in UAX#24.
347
+ */
348
+ int ucdn_get_script(uint32_t code);
349
+
350
+ /**
351
+ * Get unresolved linebreak class of a codepoint. This does not take
352
+ * rule LB1 of UAX#14 into account. See ucdn_get_resolved_linebreak_class()
353
+ * for resolved linebreak classes.
354
+ *
355
+ * @param code Unicode codepoint
356
+ * @return value according to UCDN_LINEBREAK_* and as defined in UAX#14.
357
+ */
358
+ int ucdn_get_linebreak_class(uint32_t code);
359
+
360
+ /**
361
+ * Get resolved linebreak class of a codepoint. This resolves characters
362
+ * in the AI, SG, XX, SA and CJ classes according to rule LB1 of UAX#14.
363
+ * In addition the CB class is resolved as the equivalent B2 class and
364
+ * the NL class is resolved as the equivalent BK class.
365
+ *
366
+ * @param code Unicode codepoint
367
+ * @return value according to UCDN_LINEBREAK_* and as defined in UAX#14.
368
+ */
369
+ int ucdn_get_resolved_linebreak_class(uint32_t code);
370
+
371
+ /**
372
+ * Check if codepoint can be mirrored.
373
+ *
374
+ * @param code Unicode codepoint
375
+ * @return 1 if mirrored character exists, otherwise 0
376
+ */
377
+ int ucdn_get_mirrored(uint32_t code);
378
+
379
+ /**
380
+ * Mirror a codepoint.
381
+ *
382
+ * @param code Unicode codepoint
383
+ * @return mirrored codepoint or the original codepoint if no
384
+ * mirrored character exists
385
+ */
386
+ uint32_t ucdn_mirror(uint32_t code);
387
+
388
+ /**
389
+ * Get paired bracket for a codepoint.
390
+ *
391
+ * @param code Unicode codepoint
392
+ * @return paired bracket codepoint or the original codepoint if no
393
+ * paired bracket character exists
394
+ */
395
+ uint32_t ucdn_paired_bracket(uint32_t code);
396
+
397
+ /**
398
+ * Get paired bracket type for a codepoint.
399
+ *
400
+ * @param code Unicode codepoint
401
+ * @return value according to UCDN_BIDI_PAIRED_BRACKET_TYPE_* and as defined
402
+ * in UAX#9.
403
+ *
404
+ */
405
+ int ucdn_paired_bracket_type(uint32_t code);
406
+
407
+ /**
408
+ * Pairwise canonical decomposition of a codepoint. This includes
409
+ * Hangul Jamo decomposition (see chapter 3.12 of the Unicode core
410
+ * specification).
411
+ *
412
+ * Hangul is decomposed into L and V jamos for LV forms, and an
413
+ * LV precomposed syllable and a T jamo for LVT forms.
414
+ *
415
+ * @param code Unicode codepoint
416
+ * @param a filled with first codepoint of decomposition
417
+ * @param b filled with second codepoint of decomposition, or 0
418
+ * @return success
419
+ */
420
+ int ucdn_decompose(uint32_t code, uint32_t *a, uint32_t *b);
421
+
422
+ /**
423
+ * Compatibility decomposition of a codepoint.
424
+ *
425
+ * @param code Unicode codepoint
426
+ * @param decomposed filled with decomposition, must be able to hold 18
427
+ * characters
428
+ * @return length of decomposition or 0 in case none exists
429
+ */
430
+ int ucdn_compat_decompose(uint32_t code, uint32_t *decomposed);
431
+
432
+ /**
433
+ * Pairwise canonical composition of two codepoints. This includes
434
+ * Hangul Jamo composition (see chapter 3.12 of the Unicode core
435
+ * specification).
436
+ *
437
+ * Hangul composition expects either L and V jamos, or an LV
438
+ * precomposed syllable and a T jamo. This is exactly the inverse
439
+ * of pairwise Hangul decomposition.
440
+ *
441
+ * @param code filled with composition
442
+ * @param a first codepoint
443
+ * @param b second codepoint
444
+ * @return success
445
+ */
446
+ int ucdn_compose(uint32_t *code, uint32_t a, uint32_t b);
447
+
448
+ #ifdef __cplusplus
449
+ }
450
+ #endif
451
+
452
+ #endif
Binary file