Merge branch 'win7-taskbar'
[TortoiseGit.git] / ext / hunspell / atypes.hxx
blob4f6c1ea97865a6aea9d0604f9d8504556c138f7d
1 #ifndef _ATYPES_HXX_
2 #define _ATYPES_HXX_
4 #ifndef HUNSPELL_WARNING
5 #ifdef HUNSPELL_WARNING_ON
6 #define HUNSPELL_WARNING fprintf
7 #else
8 #define HUNSPELL_WARNING
9 #endif
10 #endif
12 // HUNSTEM def.
13 #define HUNSTEM
15 #include "csutil.hxx"
16 #include "hashmgr.hxx"
18 #define SETSIZE 256
19 #define CONTSIZE 65536
20 #define MAXWORDLEN 100
21 #define MAXWORDUTF8LEN (MAXWORDLEN * 4)
23 // affentry options
24 #define aeXPRODUCT (1 << 0)
25 #define aeUTF8 (1 << 1)
26 #define aeALIASF (1 << 2)
27 #define aeALIASM (1 << 3)
28 #define aeINFIX (1 << 4)
30 // compound options
31 #define IN_CPD_NOT 0
32 #define IN_CPD_BEGIN 1
33 #define IN_CPD_END 2
34 #define IN_CPD_OTHER 3
36 #define MAXLNLEN 8192 * 4
38 #define MINCPDLEN 3
39 #define MAXCOMPOUND 10
41 #define MAXACC 1000
43 #define FLAG unsigned short
44 #define FLAG_NULL 0x00
45 #define FREE_FLAG(a) a = 0
47 #define TESTAFF( a, b , c ) flag_bsearch((unsigned short *) a, (unsigned short) b, c)
49 struct affentry
51 char * strip;
52 char * appnd;
53 unsigned char stripl;
54 unsigned char appndl;
55 char numconds;
56 char opts;
57 unsigned short aflag;
58 union {
59 char base[SETSIZE];
60 struct {
61 char ascii[SETSIZE/2];
62 char neg[8];
63 char all[8];
64 w_char * wchars[8];
65 int wlen[8];
66 } utf8;
67 } conds;
68 #ifdef HUNSPELL_EXPERIMENTAL
69 char * morphcode;
70 #endif
71 unsigned short * contclass;
72 short contclasslen;
75 struct replentry {
76 char * pattern;
77 char * pattern2;
80 struct mapentry {
81 char * set;
82 w_char * set_utf16;
83 int len;
86 struct flagentry {
87 FLAG * def;
88 int len;
91 struct guessword {
92 char * word;
93 bool allow;
96 #endif