Retry only for https protocol
[elinks.git] / src / intl / gettext / libgnuintl.h
blob24ef5c65fc1a0849bd81a79f2475e309c493a5fa
1 /* Message catalogs for internationalization.
2 Copyright (C) 1995-1997, 2000, 2001 Free Software Foundation, Inc.
4 This program is free software; you can redistribute it and/or modify
5 it under the terms of the GNU General Public License as published by
6 the Free Software Foundation; either version 2, or (at your option)
7 any later version.
9 This program is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 GNU General Public License for more details.
14 You should have received a copy of the GNU General Public License
15 along with this program; if not, write to the Free Software Foundation,
16 Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
18 /* Never include system <libintl.h> */
19 #ifndef _LIBINTL_H
20 #define _LIBINTL_H 1
21 #endif
23 #ifndef EL__INTL_GETTEXT_LIBGNUINTL_H
24 #define EL__INTL_GETTEXT_LIBGNUINTL_H 1
26 #include <locale.h>
28 #ifndef LC_MESSAGES
29 #define LC_MESSAGES 1729
30 #endif
32 /* We define an additional symbol to signal that we use the GNU
33 implementation of gettext. */
34 #define __USE_GNU_GETTEXT 1
36 /* Resolve a platform specific conflict on DJGPP. GNU gettext takes
37 precedence over _conio_gettext. */
38 #ifdef __DJGPP__
39 #undef gettext
40 #define gettext gettext
41 #endif
43 /* Look up MSGID in the current default message catalog for the current
44 LC_MESSAGES locale. If not found, returns MSGID itself (the default
45 text). */
46 extern unsigned char *gettext(const unsigned char *__msgid);
48 /* Look up MSGID in the DOMAINNAME message catalog for the current
49 LC_MESSAGES locale. */
50 extern unsigned char *dgettext(const unsigned char *__domainname, const unsigned char *__msgid);
52 /* Look up MSGID in the DOMAINNAME message catalog for the current CATEGORY
53 locale. */
54 extern unsigned char *dcgettext(const unsigned char *__domainname, const unsigned char *__msgid,
55 int __category);
57 /* Similar to `gettext' but select the plural form corresponding to the
58 number N. */
59 extern unsigned char *ngettext(const unsigned char *__msgid1, const unsigned char *__msgid2,
60 unsigned long int __n);
62 /* Similar to `dgettext' but select the plural form corresponding to the
63 number N. */
64 extern unsigned char *dngettext(const unsigned char *__domainname, const unsigned char *__msgid1,
65 const unsigned char *__msgid2, unsigned long int __n);
67 /* Similar to `dcgettext' but select the plural form corresponding to the
68 number N. */
69 extern unsigned char *dcngettext(const unsigned char *__domainname, const unsigned char *__msgid1,
70 const unsigned char *__msgid2, unsigned long int __n,
71 int __category);
73 /* Set the current default message catalog to DOMAINNAME.
74 If DOMAINNAME is null, return the current default.
75 If DOMAINNAME is "", reset to the default of "messages". */
76 extern unsigned char *textdomain(const unsigned char *__domainname);
78 /* Specify that the DOMAINNAME message catalog will be found
79 in DIRNAME rather than in the system locale data base. */
80 extern unsigned char *bindtextdomain(const unsigned char *__domainname,
81 const unsigned char *__dirname);
83 /* Specify the character encoding in which the messages from the
84 DOMAINNAME message catalog will be returned. */
85 extern unsigned char *bind_textdomain_codeset(const unsigned char *__domainname,
86 const unsigned char *__codeset);
88 /* Optimized version of the functions above. */
89 #if defined __OPTIMIZED
90 /* These are macros, but could also be inline functions. */
92 #define gettext(msgid) \
93 dgettext(NULL, msgid)
95 #define dgettext(domainname, msgid) \
96 dcgettext(domainname, msgid, LC_MESSAGES)
98 #define ngettext(msgid1, msgid2, n) \
99 dngettext(NULL, msgid1, msgid2, n)
101 #define dngettext(domainname, msgid1, msgid2, n) \
102 dcngettext(domainname, msgid1, msgid2, n, LC_MESSAGES)
104 #endif /* Optimizing. */
106 #endif /* libintl.h */