X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Fui%2Fgui%2Fvar-sheet.c;h=7936144951e15070fb0e1dd828ea20df53399cd0;hb=efad80c9e538d0be3cfd766fd2db20e958b684da;hp=d8e6f6f7195e0a15dd1bd7ddbf961278b4afedbb;hpb=11d2ffde279bad43d0c271f7fbfad383969e063f;p=pspp-builds.git diff --git a/src/ui/gui/var-sheet.c b/src/ui/gui/var-sheet.c index d8e6f6f7..79361449 100644 --- a/src/ui/gui/var-sheet.c +++ b/src/ui/gui/var-sheet.c @@ -33,9 +33,6 @@ #include #include -#if HAVE_LANGINFO_H -#include -#endif #include @@ -43,6 +40,7 @@ #include #include +#include "localcharset.h" #include "psppire-var-store.h" #include "helper.h" #include "psppire-dict.h" @@ -446,12 +444,11 @@ psppire_variable_sheet_create (gchar *widget_name, gtk_sheet_set_model (GTK_SHEET (sheet), G_SHEET_MODEL (the_var_store)); -#if HAVE_LANGINFO_H /* Since this happens inside glade_xml_new, we must prevent strings from * being re-encoded twice */ codeset = bind_textdomain_codeset (PACKAGE, 0); - bind_textdomain_codeset (PACKAGE, nl_langinfo (CODESET)); -#endif + bind_textdomain_codeset (PACKAGE, locale_charset ()); + for (i = 0 ; i < n_COLS ; ++i ) { g_sheet_hetero_column_set_button_label (G_SHEET_HETERO_COLUMN (geo), i, @@ -460,9 +457,8 @@ psppire_variable_sheet_create (gchar *widget_name, g_sheet_hetero_column_set_width (G_SHEET_HETERO_COLUMN (geo), i, column_def[i].width); } -#if HAVE_LANGINFO_H + bind_textdomain_codeset (PACKAGE, codeset); -#endif gtk_widget_show (sheet);