annotate nt/inc/gettext.h @ 61763:ce71dc9ea46f

(easy-menu-do-define): Use defalias, not fset.
author Richard M. Stallman <rms@gnu.org>
date Sat, 23 Apr 2005 16:38:03 +0000
parents 695cf19ef79e
children 23a17af379b1 375f2633d815
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
48664
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
1 /* Convenience header for conditional use of GNU <libintl.h>.
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
2 Copyright (C) 1995-1998, 2000-2002 Free Software Foundation, Inc.
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
3
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
4 This program is free software; you can redistribute it and/or modify it
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
5 under the terms of the GNU Library General Public License as published
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
6 by the Free Software Foundation; either version 2, or (at your option)
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
7 any later version.
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
8
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
9 This program is distributed in the hope that it will be useful,
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
12 Library General Public License for more details.
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
13
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
14 You should have received a copy of the GNU Library General Public
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
15 License along with this program; if not, write to the Free Software
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
16 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
17 USA. */
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
18
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
19 #ifndef _LIBGETTEXT_H
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
20 #define _LIBGETTEXT_H 1
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
21
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
22 /* NLS can be disabled through the configure --disable-nls option. */
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
23 #if ENABLE_NLS
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
24
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
25 /* Get declarations of GNU message catalog functions. */
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
26 # include <libintl.h>
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
27
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
28 #else
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
29
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
30 /* Solaris /usr/include/locale.h includes /usr/include/libintl.h, which
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
31 chokes if dcgettext is defined as a macro. So include it now, to make
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
32 later inclusions of <locale.h> a NOP. We don't include <libintl.h>
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
33 as well because people using "gettext.h" will not include <libintl.h>,
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
34 and also including <libintl.h> would fail on SunOS 4, whereas <locale.h>
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
35 is OK. */
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
36 #if defined(__sun)
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
37 # include <locale.h>
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
38 #endif
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
39
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
40 /* Disabled NLS.
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
41 The casts to 'const char *' serve the purpose of producing warnings
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
42 for invalid uses of the value returned from these functions.
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
43 On pre-ANSI systems without 'const', the config.h file is supposed to
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
44 contain "#define const". */
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
45 # define gettext(Msgid) ((const char *) (Msgid))
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
46 # define dgettext(Domainname, Msgid) ((const char *) (Msgid))
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
47 # define dcgettext(Domainname, Msgid, Category) ((const char *) (Msgid))
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
48 # define ngettext(Msgid1, Msgid2, N) \
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
49 ((N) == 1 ? (const char *) (Msgid1) : (const char *) (Msgid2))
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
50 # define dngettext(Domainname, Msgid1, Msgid2, N) \
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
51 ((N) == 1 ? (const char *) (Msgid1) : (const char *) (Msgid2))
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
52 # define dcngettext(Domainname, Msgid1, Msgid2, N, Category) \
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
53 ((N) == 1 ? (const char *) (Msgid1) : (const char *) (Msgid2))
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
54 # define textdomain(Domainname) ((const char *) (Domainname))
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
55 # define bindtextdomain(Domainname, Dirname) ((const char *) (Dirname))
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
56 # define bind_textdomain_codeset(Domainname, Codeset) ((const char *) (Codeset))
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
57
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
58 #endif
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
59
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
60 /* A pseudo function call that serves as a marker for the automated
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
61 extraction of messages, but does not call gettext(). The run-time
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
62 translation is done at a different place in the code.
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
63 The argument, String, should be a literal string. Concatenated strings
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
64 and other string expressions won't work.
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
65 The macro's expansion is not parenthesized, so that it is suitable as
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
66 initializer for static 'char[]' or 'const char[]' variables. */
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
67 #define gettext_noop(String) String
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
68
b4f6b37bfec4 Added /nt/inc/gettext.h
Ben Key <bkey1@tampabay.rr.com>
parents:
diff changeset
69 #endif /* _LIBGETTEXT_H */
52401
695cf19ef79e Add arch taglines
Miles Bader <miles@gnu.org>
parents: 48664
diff changeset
70
695cf19ef79e Add arch taglines
Miles Bader <miles@gnu.org>
parents: 48664
diff changeset
71 /* arch-tag: 07b35a70-3531-4cda-9674-2968467143ec
695cf19ef79e Add arch taglines
Miles Bader <miles@gnu.org>
parents: 48664
diff changeset
72 (do not change this comment) */