00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00044 #ifndef DKTYPES_INC
00045
00047 #define DKTYPES_INC 1
00048
00049 #ifndef DKCONFIG_INC
00050 #include <dkconfig.h>
00051 #endif
00052
00053 #include <stdio.h>
00054
00055 #if DK_HAVE_LIMITS_H
00056 #include <limits.h>
00057 #endif
00058 #if DK_HAVE_SYS_PARAM_H
00059 #include <sys/param.h>
00060 #endif
00061
00062 #if DK_HAVE_SYS_TYPES_H
00063 #include <sys/types.h>
00064 #endif
00065
00066 #if DK_HAVE_SYS_STAT_H
00067 #include <sys/stat.h>
00068 #endif
00069
00070 #if DK_HAVE_SYS_SOCKET_H
00071 #include <sys/socket.h>
00072 #else
00073 #if DK_HAVE_WINSOCK2_H
00074 #ifndef WINSOCK2_INCLUDED
00075 #include <winsock2.h>
00076 #define WINSOCK2_INCLUDED 1
00077 #endif
00078 #endif
00079 #endif
00080
00081 #if DK_TIME_WITH_SYS_TIME
00082 #include <sys/time.h>
00083 #include <time.h>
00084 #else
00085 #if DK_HAVE_SYS_TIME_H
00086 #include <sys/time.h>
00087 #else
00088 #if DK_HAVE_TIME_H
00089 #include <time.h>
00090 #endif
00091 #endif
00092 #endif
00093 #if DK_HAVE_STDDEF_H
00094 #include <stddef.h>
00095 #endif
00096 #if DK_HAVE_UNISTD_H
00097 #include <unistd.h>
00098 #endif
00099 #if DK_HAVE_DIRECT_H
00100 #include <direct.h>
00101 #endif
00102 #if DK_HAVE_DIRENT_H
00103 #include <dirent.h>
00104 #endif
00105 #if DK_HAVE_DIR_H
00106 #include <dir.h>
00107 #endif
00108 #if DK_HAVE_IO_H
00109 #include <io.h>
00110 #endif
00111 #if DK_HAVE_NETINET_IN_H
00112 #include <netinet/in.h>
00113 #endif
00114 #if DK_HAVE_FCNTL_H
00115 #include <fcntl.h>
00116 #endif
00117 #if DK_HAVE_TERMIOS_H
00118 #include <termios.h>
00119 #endif
00120 #if DK_HAVE_SYS_TERMIOS_H
00121 #include <sys/termios.h>
00122 #endif
00123 #if DK_HAVE_SYS_TTOLD_H
00124 #include <sys/ttold.h>
00125 #endif
00126 #if DK_HAVE_WINCON_H
00127 #include <wincon.h>
00128 #endif
00129 #if DK_HAVE_WCHAR_H
00130 #include <wchar.h>
00131 #endif
00132 #if DK_HAVE_ZLIB_H
00133 #include <zlib.h>
00134 #endif
00135
00136 #include <dkwin.h>
00137
00138 #if defined(PATH_MAX)
00139
00140 #define DK_MAX_PATH (PATH_MAX + 1)
00141 #else
00142 #if defined(MAXPATHLEN)
00143
00144 #define DK_MAX_PATH (MAXPATHLEN + 1)
00145 #else
00146
00147 #define DK_MAX_PATH 1025
00148 #endif
00149 #endif
00150
00152 #define DK_MAX_DOUBLE 1.7e308
00153
00154 #if defined(__BORLANDC__)
00155
00156 typedef int mode_t;
00157 #endif
00158
00159 #if !DK_HAVE_WCHAR_T
00160 #if !DK_HAVE_WCHAR_H
00161 #if !WCHAR_T_DEFINED
00162
00163 #define WCHAR_T_DEFINED 1
00164
00165 typedef unsigned short wchar_t;
00166 #endif
00167 #endif
00168 #endif
00169
00170
00171
00172
00173
00175 typedef char *dk_str;
00176
00178 typedef dk_str *dk_str_ptr;
00179
00181 typedef char dk_byte;
00182
00184 typedef unsigned char dk_ubyte;
00185
00187 typedef short dk_word;
00188
00190 typedef unsigned short dk_uword;
00191
00193 typedef long dk_dword;
00194
00196 typedef unsigned long dk_udword;
00197
00198
00199
00201 typedef void dk_signal_ret_t;
00202
00204 typedef dk_signal_ret_t dk_signal_fct_t DK_PR((int));
00205
00207 typedef dk_signal_fct_t *dk_signal_disp_t;
00208
00209
00210
00211 #if defined(__cplusplus)
00212 extern "C" {
00213 #endif
00214
00215 typedef dk_signal_ret_t dk_extc_signal_fct_t DK_PR((int));
00216 #if defined(__cplusplus)
00217 }
00218 #endif
00219
00220 typedef dk_extc_signal_fct_t *dk_extc_signal_disp_t;
00221
00222
00223
00225 typedef char * dk_fct_type_ss DK_PR((\
00226 void *obj, char *table, char *key, char *def\
00227 ));
00228
00229
00230
00232 typedef void dk_fct_type_log DK_PR((void *obj, int level, char **ptr, int num));
00233
00234
00235
00237 #if DK_HAVE_LONG_LONG_INT
00238 typedef long long unsigned dk_long_long_unsigned_t;
00239 #else
00240 typedef long unsigned dk_long_long_unsigned_t;
00241 #endif
00242
00244 #if DK_HAVE_LONG_LONG_INT
00245 typedef long long dk_long_long_int_t;
00246 #else
00247 typedef long dk_long_long_int_t;
00248 #endif
00249
00250
00252 #if DK_HAVE_SOCKLEN_T
00253 #define dk_socklen_t socklen_t
00254 #else
00255 #if DK_HAVE_SIZE_T
00256 #define dk_socklen_t size_t
00257 #else
00258 #define dk_socklen_t unsigned int
00259 #endif
00260 #endif
00261
00262
00264 #ifdef _WIN32
00265 #define dk_read_write_t int
00266 #else
00267 #define dk_read_write_t ssize_t
00268 #endif
00269
00270
00275 typedef struct {
00276 char *key;
00277 char *value;
00278 } dk_key_value_t ;
00279
00280
00281
00285 #define DK_KEY_VALUE_ARRAY_SIZE(x) (sizeof(x)/sizeof(dk_key_value_t))
00286
00287
00288
00289
00290
00291
00292
00293
00294
00295
00296
00301 typedef struct _dk_font_ {
00302 char *texname;
00303 char *psname;
00304 int features;
00305 char *svgFontFamily;
00306 char *gs_alias;
00307 char *gs_actual;
00308 char *svgFontId;
00309 } dk_font_t;
00310
00311
00312
00316 typedef struct {
00317 char *key;
00318 char **value_pointer;
00319 char *default_value;
00320 } dk_string_finder_t;
00321
00322
00323
00327 typedef struct {
00328 unsigned char *data;
00329 size_t bits;
00330 } dk_bitfield_t ;
00331
00332
00333
00337 typedef struct {
00338 unsigned char **data;
00339 size_t c;
00340 size_t r;
00341 } dk_bitmatrix_t;
00342
00343
00344
00349 typedef struct {
00350
00351 #if VERSION_BEFORE_2009_01_27
00352
00353 #if DK_HAVE_SYS_STAT_H
00354 #if DK_HAVE_STAT
00355 struct stat st;
00356 #else
00357 #if DK_HAVE__STAT
00358 struct _stat st;
00359 #endif
00360 #endif
00361 #if DK_HAVE_LSTAT
00362 struct stat lst;
00363 #endif
00364 #endif
00365
00366 #endif
00367
00368 int permissions;
00369 int filetype;
00370 unsigned long inode_number;
00371 unsigned long device_number;
00372 unsigned long rdevice_number;
00373 unsigned long number_of_links;
00374 dk_long_long_unsigned_t size;
00375 int size_math_error;
00376 long uid;
00377 long gid;
00378 char ctime[24];
00379 char atime[24];
00380 char mtime[24];
00381 short is_far_link;
00382 struct tm ori_ctime;
00383 struct tm ori_atime;
00384 struct tm ori_mtime;
00385 unsigned char ud;
00386 unsigned char gd;
00387 } dk_stat_t;
00388
00389
00390
00395 typedef struct {
00396 char *dirname;
00397 char *shortname;
00398 char *fullname;
00399 dk_stat_t stbuf;
00400 int state;
00401 long maxpathlen;
00402 int error_code;
00403 #if defined(WIN32) || defined(_WIN32)
00404
00405 #if DK_HAVE__FINDFIRST64
00406
00407 long hFile64;
00408 struct __finddata64_t fdt64;
00409 #else
00410 #if DK_HAVE__FINDFIRST32
00411
00412 long hFile32;
00413 struct __finddata32_t fdt32;
00414 #else
00415 #if DK_HAVE__FINDFIRST
00416
00417 long hFile;
00418 struct _finddata_t fdt;
00419 #endif
00420 #endif
00421 #endif
00422
00423 #else
00424 #if DK_HAVE_FINDFIRST
00425
00426 struct ffblk ffblk;
00427 #else
00428 #if DK_HAVE_DIRENT_H
00429
00430 DIR *dir;
00431 #else
00432
00433 #endif
00434 #endif
00435 #endif
00436
00437 } dk_dir_t;
00438
00439
00440
00445 typedef dk_dir_t dk_fne_t ;
00446
00447
00448
00450 typedef struct {
00451 void *obj;
00452 dk_fct_type_log *fct;
00453 int level;
00454 int maxlevel;
00455 } dk_log_t;
00456
00457
00458
00460 typedef struct {
00461 void *obj;
00462 dk_fct_type_ss *fct;
00463 } dk_ss_t;
00464
00465
00466
00471 typedef struct {
00472 int cmd;
00474 struct {
00475 char *buffer;
00476 size_t length;
00477 int cmd;
00478 } params;
00480 struct {
00481 char *buffer;
00482 size_t length;
00483 size_t used;
00484 } results;
00485 int return_value;
00486 int error_code;
00487 void *strm;
00488 } dk_stream_api_t;
00489
00490
00491
00494 typedef void dk_stream_fct_t DK_PR((dk_stream_api_t *api));
00495
00496
00497
00501 typedef struct {
00502 dk_stream_api_t api;
00503 void *data;
00504 dk_stream_fct_t *fct;
00505 unsigned long bytes;
00506 int flags;
00507 int opt;
00508 } dk_stream_t;
00509
00510
00511
00516 typedef struct {
00517 dk_stream_t *s;
00518 int flags;
00519 } dk_stream_wrapper_t;
00520
00521
00522
00523 #if 0
00524
00526 typedef struct {
00527 dk_stream_t *target;
00528 char *rlbuffer;
00529 char *flate_inbuffer;
00530 char *flate_outbuffer;
00531 int flags;
00532 size_t rlb_size;
00533 size_t fib_size;
00534 size_t fob_size;
00535 } dk_output_encoder_t;
00536 #endif
00537
00538
00540 typedef dk_stream_t *
00541 dk_stream_open_fct_t DK_PR((char *name, char *mode, int ign, int *reason));
00542
00543
00544
00549 typedef struct {
00550 char *suffix;
00551 dk_stream_open_fct_t *fct;
00552 } dk_stream_suffix_t;
00553
00554
00555
00559 struct _dk_storage_node {
00560 struct _dk_storage_node *p;
00561 struct _dk_storage_node *l;
00562 struct _dk_storage_node *r;
00563 short b;
00564 short w;
00565 void *o;
00567 union {
00568 char c;
00569 unsigned char uc;
00570 short s;
00571 unsigned short us;
00572 int i;
00573 unsigned int ui;
00574 long l;
00575 unsigned long ul;
00576 float f;
00577 double d;
00578 } v;
00579 };
00580
00582 typedef struct _dk_storage_node dk_storage_node_t;
00583
00585 typedef dk_storage_node_t *dk_storage_node_p;
00586
00587
00588
00595 typedef char dk_fct_eval_c_t(void *obj, int crit);
00596
00598 typedef unsigned char dk_fct_eval_uc_t(void *obj, int crit);
00599
00601 typedef short dk_fct_eval_s_t(void *obj, int crit);
00602
00604 typedef unsigned short dk_fct_eval_us_t(void *obj, int crit);
00605
00607 typedef int dk_fct_eval_i_t(void *obj, int crit);
00608
00610 typedef unsigned int dk_fct_eval_ui_t(void *obj, int crit);
00611
00613 typedef long dk_fct_eval_l_t(void *obj, int crit);
00614
00616 typedef unsigned long dk_fct_eval_ul_t(void *obj, int crit);
00617
00619 typedef float dk_fct_eval_f_t(void *obj, int crit);
00620
00622 typedef double dk_fct_eval_d_t(void *obj, int crit);
00623
00625 typedef int dk_fct_comp_t(void *o1, void *o2, int crit);
00626
00627
00628
00632 typedef struct {
00633 dk_storage_node_p *d;
00634 short l;
00635 dk_storage_node_t *r;
00636 int h;
00637 int c;
00638 int t;
00640 union {
00641 dk_fct_eval_c_t *c;
00642 dk_fct_eval_uc_t *uc;
00643 dk_fct_eval_s_t *s;
00644 dk_fct_eval_us_t *us;
00645 dk_fct_eval_i_t *i;
00646 dk_fct_eval_ui_t *ui;
00647 dk_fct_eval_l_t *l;
00648 dk_fct_eval_ul_t*ul;
00649 dk_fct_eval_f_t *f;
00650 dk_fct_eval_d_t *d;
00651 dk_fct_comp_t *comp;
00652 } e;
00653 void *i;
00654 } dk_storage_t;
00655
00656
00657
00661 struct _dk_storage_iterator {
00662 struct _dk_storage_iterator *l;
00663 struct _dk_storage_iterator *r;
00664 dk_storage_t *s;
00665 dk_storage_node_t *c;
00666 };
00668 typedef struct _dk_storage_iterator dk_storage_iterator_t;
00669
00670
00671
00675 typedef struct {
00676 dk_uword vers_major;
00677 dk_uword vers_minor;
00678 dk_uword elems;
00679 char **keys;
00680 char **values;
00681 } dk_stt_t;
00682
00683
00684
00688 typedef struct {
00689 char *n;
00690 char *v;
00691 int p;
00692 } dk_preference_t;
00693
00694
00695
00696
00700 typedef struct {
00701 struct {
00702 struct {
00703 int argc;
00704 char **argv;
00705 } o;
00706 struct {
00707 int argc;
00708 char **argv;
00709 } a;
00710 } a;
00711 struct {
00712 char *u;
00713 char *a;
00714 char *h;
00715 char *g;
00716 } n;
00717 struct {
00718 char *h;
00719 char *t;
00720 char *a;
00721 char *s;
00722 char *pt;
00723 char *etc;
00724 } d;
00725 struct {
00727 dk_storage_t *c;
00728 dk_storage_iterator_t *ci;
00730 dk_storage_t *a;
00731 dk_storage_iterator_t *ai;
00732 #if DK_HAVE_WINREG_H
00733
00734 int what;
00735 HKEY hklm_all;
00736 HKEY hklm_app;
00737 HKEY hkcu_all;
00738 HKEY hkcu_app;
00739 #else
00740
00741 dk_storage_t *s;
00743 dk_storage_iterator_t *si;
00745 dk_storage_t *u;
00747 dk_storage_iterator_t *ui;
00748 #endif
00749 int unc;
00750 int prf;
00751 } p;
00752 struct {
00753 char *f;
00754 char *d;
00755 } x;
00756 struct {
00757 int max;
00758 int nostdio;
00759 struct {
00760 int m;
00761 int f;
00762 unsigned char *c;
00763 int ide_type;
00764 } o;
00765 struct {
00766 int m;
00767 int f;
00768 unsigned char *c;
00769 int ide_type;
00770 } e;
00771 struct {
00772 int m;
00773 int k;
00774 int f;
00775 FILE *t;
00776 char *n;
00777 unsigned char *c;
00778 int ide_type;
00779 } f;
00780 #if DK_HAVE_SYSLOG
00781 struct {
00782 int m;
00783 char *i;
00784 int f;
00785 int o;
00786 } s;
00787 #endif
00788 struct {
00789 char *n;
00790 unsigned long lineno;
00791 } ef;
00792 } l;
00793 struct {
00794 char *l;
00795 char *r;
00796 char *e;
00797 dk_storage_t *s;
00798 dk_storage_iterator_t *si;
00799 int es;
00800 } loc;
00801 struct {
00802 unsigned long l;
00803 } td;
00804 struct {
00805 int prng_type;
00806 char *seed_file_name;
00807 } random;
00808 int relaxed_fopen_check;
00809 int relaxed_fopen_reason;
00810 int keep_temp_dir;
00811 } dk_app_t;
00812
00813
00817 #if DK_HAVE_PROTOTYPES
00818 typedef int dk_fct_tokenizer(void *data, void *tok, char *s, int *err);
00819 #else
00820 typedef int dk_fct_tokenizer();
00821 #endif
00822
00823
00824
00829 typedef struct {
00830 char *token_buffer;
00831 size_t buffer_size;
00832 size_t buffer_used;
00833 char **quotes;
00834 char *sct;
00835 char *whsp;
00836 char *nl;
00837 char comment;
00838 char *endquote;
00839 int error_code;
00840 dk_fct_tokenizer *fct;
00841 void *user_data;
00842 int state;
00843 unsigned long lineno;
00844 } dk_tokenizer_t ;
00845
00846
00847
00851 typedef struct {
00852 int what;
00853 union {
00854 struct {
00855 char *buffer;
00856 size_t lgt;
00857 size_t used;
00858 } b;
00859 struct {
00860 unsigned long a85val;
00861 size_t used;
00862 size_t linepos;
00863 size_t maxlinepos;
00864 int fl;
00865 } a85;
00866 struct {
00867 size_t linepos;
00868 size_t maxlinepos;
00869 int fl;
00870 } ah;
00871 struct {
00872 char *buffer;
00873 char lc;
00874 size_t used;
00875 int st;
00876 } rl;
00877 #if DK_HAVE_ZLIB_H
00878 struct {
00879 z_stream *zs;
00880 Bytef *ibuffer;
00881 uLong i_length;
00882 Bytef *obuffer;
00883 uLong o_length;
00884 uLong used;
00885 int stillok;
00886 } flate;
00887 #endif
00888 } c;
00889 } dk_of_cell_t;
00890
00891
00892
00897 typedef struct {
00898 int flags;
00899 dk_stream_t *target;
00900 dk_of_cell_t *cells;
00901 int n_of_cells;
00902 int have_data;
00903 } dk_of_t;
00904
00905
00906
00910 typedef struct {
00911 dk_stream_t *t;
00912 unsigned char c;
00913 unsigned short b;
00914 } dk_bitshift_t;
00915
00916
00917
00922 typedef struct {
00923 dk_bitshift_t *t;
00924 int flags;
00925 } dk_bitshift_wrapper_t;
00926
00927
00928
00931 typedef struct {
00932 char *t;
00933 char *m;
00934 char *a;
00935 } dk_le_ct_t;
00936
00937
00938
00941 typedef struct {
00942 char *dirname;
00943 char *filename;
00944 int flags;
00945 int error_code;
00946 unsigned long error_line;
00947 unsigned long cache_element;
00948 dk_le_ct_t *cache_ptr;
00949 void *data;
00950 } dk_le_t;
00951
00952
00953
00958 typedef struct {
00959 dk_le_t *l;
00960 int flags;
00961 } dk_le_wrapper_t;
00962
00963 #if DK_HAVE_SYS_SOCKET_H || DK_HAVE_WINSOCK2_H
00964
00965
00966
00969 typedef struct {
00970 int what;
00971 struct {
00972 struct sockaddr_in sin;
00973 unsigned short portmin;
00974 unsigned short portmax;
00975 } ip4;
00976 } dk_ip_addr_t;
00977
00978
00979
00982 typedef struct {
00983 int state;
00984 int flags;
00985 #if DK_HAVE_WINSOCK2_H
00986 SOCKET s;
00987 #else
00988 int s;
00989 #endif
00990 struct {
00991 struct {
00992 dk_ip_addr_t w;
00993 dk_ip_addr_t f;
00994 } l;
00995 struct {
00996 dk_ip_addr_t w;
00997 dk_ip_addr_t f;
00998 } r;
00999 } a;
01000 struct {
01001 time_t seconds;
01002 long usecs;
01003 } to;
01004 int error_code;
01005 } dk_tcpip_t;
01006
01007
01010 typedef struct {
01011 int is_tty;
01012 #if DK_HAVE_TCGETATTR
01013 struct termios ori;
01014 #else
01015 #if defined(TCGETS)
01016 struct termios ori;
01017 #else
01018 #if DK_HAVE_GETSTDHANDLE
01019 HANDLE consoleHandle;
01020 DWORD ori;
01021 #else
01022 unsigned long dummy;
01023 #endif
01024 #endif
01025 #endif
01026 } dk_echo_t;
01027
01028
01029
01032 typedef struct _font_replacement_ {
01033 char *n;
01034 char *f;
01035 char *l;
01036 char *s;
01037 char *ft;
01038 char *tn;
01039 dk_storage_t *d;
01040 dk_storage_iterator_t *di;
01041 int ff;
01042 int t;
01043 unsigned long num;
01044 } dk_font_replacement_t;
01045
01046
01047
01050 typedef struct _one_font_mapping {
01051 dk_storage_t *r;
01052 dk_storage_iterator_t *ri;
01053 dk_storage_t *byname;
01054 dk_storage_iterator_t *bynamei;
01055 unsigned char used;
01056 size_t noe;
01057 } dk_one_font_mapping_t;
01058
01059
01060
01063 typedef struct _font_mapping_ {
01064 dk_one_font_mapping_t *m;
01065 dk_storage_t *d;
01066 dk_storage_iterator_t *di;
01067 int error_code;
01068 unsigned long err_lineno;
01069 } dk_font_mapping_t;
01070
01071
01072
01073
01074
01075
01077 typedef dk_bitfield_t *DKrause__BitField;
01079 typedef dk_bitmatrix_t *DKrause__BitMatrix;
01081 typedef dk_stream_wrapper_t *DKrause__Stream;
01083 typedef dk_bitshift_wrapper_t *DKrause__BitStream;
01085 typedef dk_stt_t *DKrause__StringTable;
01087 typedef dk_app_t *DKrause__Application;
01089 typedef dk_tokenizer_t *DKrause__Tokenizer;
01091 typedef dk_le_wrapper_t *DKrause__LaTeXEncoder;
01092
01093 #endif
01094
01095 #if DK_HAVE_LONG_LONG_INT
01096
01097 #define DK_MAX_LONG_LONG_UNSIGNED 0xFFFFFFFFFFFFFFFFULL
01098
01099 #define DK_MAX_LONG_LONG_INT 0x7FFFFFFFFFFFFFFFLL
01100
01101 #define DK_ZERO_LONG_LONG_UNSIGNED 0ULL
01102
01103 #define DK_ZERO_LONG_LONG_INT 0LL
01104
01105 #define DK_ONE_LONG_LONG_UNSIGNED 1ULL
01106
01107 #define DK_ONE_LONG_LONG_INT 1LL
01108 #else
01109
01110 #define DK_MAX_LONG_LONG_UNSIGNED 0xFFFFFFFFUL
01111
01112 #define DK_MAX_LONG_LONG_INT 0x7FFFFFFFL
01113
01114 #define DK_ZERO_LONG_LONG_UNSIGNED 0UL
01115
01116 #define DK_ZERO_LONG_LONG_INT 0L
01117
01118 #define DK_ONE_LONG_LONG_UNSIGNED 1UL
01119
01120 #define DK_ONE_LONG_LONG_INT 1L
01121 #endif
01122
01123 #if SIZEOF_LONG == 8
01124
01125 #define DK_MAX_ULONG (0xFFFFFFFFFFFFFFFFUL)
01126
01127 #define DK_MAX_LONG (0x7FFFFFFFFFFFFFFFL)
01128 #else
01129
01130 #define DK_MAX_ULONG (0xFFFFFFFFUL)
01131
01132 #define DK_MAX_LONG (0x7FFFFFFFL)
01133 #endif
01134
01135 #if SIZEOF_INT == 4
01136
01137 #define DK_MAX_UNSIGNED (0xFFFFFFFFU)
01138
01139 #define DK_MAX_INT (0x7FFFFFFF)
01140 #else
01141
01142 #define DK_MAX_UNSIGNED (0xFFFFU)
01143
01144 #define DK_MAX_INT (0x7FFF)
01145 #endif
01146
01147 #if SIZEOF_SHORT == 4
01148
01149 #define DK_MAX_USHORT (0xFFFFFFFFU)
01150
01151 #define DK_MAX_SHORT (0x7FFFFFFF)
01152 #else
01153
01154 #define DK_MAX_USHORT (0xFFFFU)
01155
01156 #define DK_MAX_SHORT (0x7FFF)
01157 #endif
01158
01159 #if SIZEOF_SIZE_T == 2
01160
01161 #define DK_MAX_SIZE_T 0xFFFFU
01162 #else
01163 #if SIZEOF_SIZE_T == 4
01164
01165 #define DK_MAX_SIZE_T 0xFFFFFFFFUL
01166 #else
01167 #if SIZEOF_SIZE_T == 8
01168
01169 #define DK_MAX_SIZE_T 0xFFFFFFFFFFFFFFFFULL
01170 #endif
01171 #endif
01172 #endif
01173
01175 #define DK_APP_ENCODING_DEFAULT 0
01176
01178 #define DK_APP_ENCODING_UTF8 1
01179
01180 #endif
01181