Index of Section 3 Manual Pages

Interix / SUAsetlocale.3Interix / SUA

setlocale(3)                                               setlocale(3)

  setlocale()

  NAME

    setlocale() - set or query the program's locale

  SYNOPSIS

    #include 

    char * setlocale(int category, const char *locale)

  DESCRIPTION

    The setlocale(3) function changes or queries the program's locale. The
    category is used to specify part of the locale. It can have any one of
    these values (defined in ):
    LC_ALL          The entire locale

    LC_COLLATE      Character collating sequence

    LC_CTYPE        Character handling and multibyte functions

    LC_MESSAGES     Message catalogs, see catopen(3) function.

    LC_MONETARY     Monetary formatting information

    LC_NUMERIC      Decimal point character in I/O and string conversions

    LC_TIME         Time formatting -- see strftime()

    The locale argument is a string naming a particular locale. All POSIX-
    conforming systems support the locales "C" and "POSIX". The Interix
    subsystem supports the C and POSIX locales (which are identical),
    ja_JP.EUC-JP and ja_JP.eucJP locales (which are identical), and win-
    ja_JP.windows-932 and ja_JP.SJIS locales (which are identical).

    To query the current locale, use a null pointer as the locale;
    setlocale(3) returns the name of the current locale for that category.

    The return value may be overwritten by a subsequent call to setlocale(3),
    so your program shouldn't modify it.

  RETURN VALUE

    On success, the setlocale(3) function returns a string that corresponds to
    the locale specified by locale. If the function fails, it returns NULL.

  NOTES

    Use setlocale(3) function with care in multithreaded applications. To set
    the locale in a multithreaded application, be sure to call setlocale(3)
    before calling any locale-sensitive functions. You can safely use
    setlocale(3) to query the current locale at any time, however.

  SEE ALSO

    isalnum(3)

    isalpha(3)

    iscntrl(3)

    isgraph(3)

    islower(3)

    isprint(3)

    ispunct(3)

    isspace(3)

    isupper(3)

    localeconv(3)

    nl_langinfo(3)

    strcoll(3)

    strftime(3)

    strxfrm(3)

  USAGE NOTES

    The setlocale function is not thread safe.

    The setlocale function is not async-signal safe.


Interix / SUAHosted at SUA Community for Interix, SUA and SFUInterix / SUA