1 /* i18n stuff for vips.
2  */
3 
4 #ifndef VIPS_INTL_H
5 #define VIPS_INTL_H
6 
7 #ifdef __cplusplus
8 extern "C" {
9 #endif /*__cplusplus*/
10 
11 const char *vips__gettext( const char *msgid );
12 const char *vips__ngettext( const char *msgid,
13 	const char *plural, unsigned long int n );
14 
15 #ifdef ENABLE_NLS
16 
17 #include <libintl.h>
18 #define _(String) vips__gettext(String)
19 /* ngettext may be defined as a macro if we're optimised.
20  */
21 #ifdef ngettext
22 #undef ngettext
23 #endif /*ngettext*/
24 #define ngettext(String,Plural,number) vips__ngettext(String,Plural,number)
25 #ifdef gettext_noop
26 #define N_(String) gettext_noop(String)
27 #else
28 #define N_(String) (String)
29 #endif
30 
31 #else /*!ENABLE_NLS*/
32 
33 #define _(String) (String)
34 #define N_(String) (String)
35 #define textdomain(String) (String)
36 #define gettext(String) (String)
37 #define dgettext(Domain,String) (String)
38 #define dcgettext(Domain,String,Type) (String)
39 #define bindtextdomain(Domain,Directory) (Domain)
40 #define bind_textdomain_codeset(Domain,Codeset) (Codeset)
41 #define ngettext(S, P, N) ((N) == 1 ? (S) : (P))
42 #define dngettext(D, S, P, N) ngettext(S, P, N)
43 
44 #endif /* ENABLE_NLS */
45 
46 #ifdef __cplusplus
47 }
48 #endif /*__cplusplus*/
49 
50 #endif /* VIPS_INTL_H */
51