File: Ficonv.h

package info (click to toggle)
fvwm 1:2.6.8-1
  • links: PTS
  • area: main
  • in suites: bullseye, buster, sid
  • size: 15,804 kB
  • sloc: ansic: 145,770; xml: 17,093; perl: 7,302; sh: 4,921; makefile: 1,094; yacc: 688; lex: 187; sed: 11
file content (52 lines) | stat: -rw-r--r-- 1,348 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
/* -*-c-*- */
/* Copyright (C) 2002  Olivier Chapuis */

#ifndef FICONV_H
#define FICONV_H

/* ---------------------------- included header files ---------------------- */

#include "config.h"

/* ---------------------------- global definitions ------------------------- */

#ifdef HAVE_ICONV
#define FiconvSupport 1
#else
#define FiconvSupport 0
#endif

#if FiconvSupport

#define Ficonv_open(a,b)    iconv_open(a,b)
#define Ficonv_close(a)     iconv_close(a)
#define Ficonv(a,b,c,d,e)   iconv(a,b,c,d,e)

#else

#define Ficonv_open(a,b)    (Ficonv_t)-1
#define Ficonv_close(a)     -1
#define Ficonv(a,b,c,d,e)   -1

#endif

/* ---------------------------- global macros ------------------------------ */

#define FICONV_CONVERSION_MAX_NUMBER_OF_WARNING 10

/* ---------------------------- type definitions --------------------------- */

typedef void* Ficonv_t;

/* ---------------------------- interface functions ------------------------ */
void FiconvSetTransliterateUtf8(int toggle);
char *FiconvUtf8ToCharset(
	Display *dpy, FlocaleCharset *fc, const char *in,
	unsigned int in_size);
char *FiconvCharsetToUtf8(
	Display *dpy, FlocaleCharset *fc, const char *in,
	unsigned int in_size);
char *FiconvCharsetToCharset(
	Display *dpy, FlocaleCharset *in_fc, FlocaleCharset *out_fc,
	const char *in, unsigned int in_size);
#endif /* FICONV_H */