MATE Library Reference Manual | ||||
---|---|---|---|---|
Top | Description |
#include <libmate/libmate.h> const GList * mate_i18n_get_language_list (const gchar *category_name
); void mate_i18n_push_c_numeric_locale (void
); void mate_i18n_pop_c_numeric_locale (void
);
This module allows the programmer to internationalize his application by providing functions to retrieve the preferred languages of the user as well as temporarily move back to the C locale for performing locale independent operations.
A lot of the internationalization functions which were in this module in
MATE 1 have now moved to libmatecomponent for MATE 2 (_()
, textdomain()
,
gettext()
, etc).
const GList * mate_i18n_get_language_list (const gchar *category_name
);
mate_i18n_get_language_list
is deprecated and should not be used in newly-written code.
This function is deprecated. You should be using g_get_language_names()
instead.
This computes a list of language strings that the user wants. It searches in the standard environment variables to find the list, which is sorted in order from most desirable to least desirable. The `C' locale is appended to the list if it does not already appear (other routines depend on this behaviour).
The ignored
argument used to be the category name to use, but this was
removed since there is only one useful thing to pass here. For further
details, see http://bugzilla.gnome.org/show_bug.cgi?id=168948
|
|
Returns : |
the list of languages, this list should not be freed as it is owned by mate-i18n. |
void mate_i18n_push_c_numeric_locale (void
);
mate_i18n_push_c_numeric_locale
is deprecated and should not be used in newly-written code.
Saves the current LC_NUMERIC locale and sets it to "C"
This way you can safely read write floating point numbers all in the
same format. You should make sure that code between
mate_i18n_push_c_numeric_locale()
and mate_i18n_pop_c_numeric_locale()
doesn't do any setlocale calls or locale may end up in a strange setting.
Also make sure to always pop the c numeric locale after you've pushed it.
The calls can be nested.
void mate_i18n_pop_c_numeric_locale (void
);
mate_i18n_pop_c_numeric_locale
is deprecated and should not be used in newly-written code.
Restores the LC_NUMERIC locale to what it was
before the matching mate_i18n_push_c_numeric_locale()
. If these calls
were nested, then this is a no-op until we get to the most outermost
layer. Code in between these should not do any setlocale calls
to change the LC_NUMERIC locale or things may come out very strange.