6 #define UNKNCHAR '\001'
8 #define CHARSETS_INDEX "mc.charsets"
10 extern int n_codepages
;
12 extern unsigned char conv_displ
[256];
13 extern unsigned char conv_input
[256];
15 struct codepage_desc
{
20 extern struct codepage_desc
*codepages
;
22 char *get_codepage_id (int n
);
23 int get_codepage_index (const char *id
);
24 int load_codepages_list (void);
25 void free_codepages_list (void);
26 char *init_translation_table (int cpsource
, int cpdisplay
);
27 void convert_to_display (char *str
);
28 void convert_from_input (char *str
);
29 void convert_string (unsigned char *str
);
31 /* Convert single characters */
33 convert_to_display_c (int c
)
35 if (c
< 0 || c
>= 256)
41 convert_from_input_c (int c
)
43 if (c
< 0 || c
>= 256)
48 #else /* !HAVE_CHARSET */
50 #define convert_to_display_c(c) (c)
51 #define convert_from_input_c(c) (c)
52 #define convert_to_display(str) do {} while (0)
53 #define convert_from_input(str) do {} while (0)
55 #endif /* HAVE_CHARSET */
57 #endif /* __CHARSETS_H__ */