TEST=Linux desktop
Review URL: https://codereview.appspot.com/5876049
AC_SUBST(GETTEXT_PACKAGE)
AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GETTEXT_PACKAGE",
[The prefix for out gettext translation domains.])
+GLIB_DEFINE_LOCALEDIR(GLIB_LOCALE_DIR)
+GLIB_LOCALE_DIR=$localedir
+AC_SUBST(GLIB_LOCALE_DIR)
# For dislpay date.
m4_define(ibus_datedisplay,
@X11_CFLAGS@ \
$(INCLUDES) \
-DGETTEXT_PACKAGE=\"@GETTEXT_PACKAGE@\" \
+ -DGLIB_LOCALE_DIR=\"@GLIB_LOCALE_DIR@\" \
-DG_LOG_DOMAIN=\"IBUS\" \
-DPKGDATADIR=\"$(pkgdatadir)\" \
-DLIBEXECDIR=\"$(libexecdir)\" \
using GLib;
using Gtk;
+public extern const string GETTEXT_PACKAGE;
+public extern const string GLIB_LOCALE_DIR;
+
class Application {
private IBus.Bus m_bus;
private Panel m_panel;
private IBus.Config m_config;
public Application(string[] argv) {
+ GLib.Intl.bindtextdomain(GETTEXT_PACKAGE, GLIB_LOCALE_DIR);
+ GLib.Intl.bind_textdomain_codeset(GETTEXT_PACKAGE, "UTF-8");
IBus.init();
Gtk.init(ref argv);