## gnome-i18n gnome-i18n — Support for localization and internationalization. |

## Synopsis

    #include <libgnome/libgnome.h>

    const GList *	      gnome_i18n_get_language_list        (const gchar *category_name);
    void                gnome_i18n_push_c_numeric_locale    (void);
    void                gnome_i18n_pop_c_numeric_locale     (void);

## Description

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.

### Note

A lot of the internationalization functions which were in this module in GNOME 1 have now moved to libbonobo for GNOME 2 (`_()`, `textdomain()`, `gettext()`, etc).

## Details

### gnome_i18n_get_language_list ()

    const GList *	      gnome_i18n_get_language_list        (const gchar *category_name);

### Warning

`gnome_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 gnome-i18n.

### gnome_i18n_push_c_numeric_locale ()

    void                gnome_i18n_push_c_numeric_locale    (void);

### Warning

`gnome_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 `gnome_i18n_push_c_numeric_locale()` and `gnome_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.

### gnome_i18n_pop_c_numeric_locale ()

    void                gnome_i18n_pop_c_numeric_locale     (void);

### Warning

`gnome_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 `gnome_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.