mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-07-24 19:07:52 +02:00
Add gettext support.
Mon Jan 15 21:12:49 2001 Owen Taylor <otaylor@redhat.com> * configure.in acconfig.h glibintl.h gutils.c po/{Makefile.in.in,POTFILES.in,po2tbl.in}: Add gettext support. * glib-gettext.m4 acinclude.m4: Clean up the GTK+ gettext macros some more and put them in this file, though they also need to be included in acinclude.m4 due to the brokeness of aclocal. * gspawn.c gspawn-win32.c gutf8.c gconvert.c gfileutils.c gshell.c: Remove dummy _() #defines, include glibintl.m4.
This commit is contained in:
@@ -1001,3 +1001,20 @@ g_get_codeset (void)
|
||||
#endif
|
||||
#endif
|
||||
}
|
||||
|
||||
#ifdef ENABLE_NLS
|
||||
|
||||
#include <libintl.h>
|
||||
|
||||
int _glib_gettext_initialized = 0;
|
||||
|
||||
char *_glib_gettext_init (const char *str)
|
||||
{
|
||||
bindtextdomain(GETTEXT_PACKAGE, GLIB_LOCALE_DIR);
|
||||
|
||||
return dgettext (GETTEXT_PACKAGE, str);
|
||||
}
|
||||
|
||||
#endif /* ENABLE_NLS */
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user