*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->FreeBSD man pages -> nl_langinfo (3)              
Title
Content
Arch
Section
 

NL_LANGINFO(3)

Contents


NAME    [Toc]    [Back]

     nl_langinfo -- language information

LIBRARY    [Toc]    [Back]

     Standard C Library (libc, -lc)

SYNOPSIS    [Toc]    [Back]

     #include <langinfo.h>

     char *
     nl_langinfo(nl_item item);

DESCRIPTION    [Toc]    [Back]

     The nl_langinfo() function returns a pointer to a string containing
     information relevant to the particular language or cultural area defined
     in the program's locale.  The manifest constant names and values of item
     are defined in <langinfo.h>.

     Calls to setlocale() with a category corresponding to the category of
     item, or to the category LC_ALL, may overwrite buffer pointed by the
     return value.

EXAMPLES    [Toc]    [Back]

     For example:

	   nl_langinfo(ABDAY_1)

     would return a pointer to the string "Dom" if the identified language was
     Portuguese, and "Sun" if the identified language was English.

RETURN VALUES    [Toc]    [Back]

     In a locale where langinfo data is not defined, nl_langinfo() returns a
     pointer to the corresponding string in the POSIX locale.  In all locales,
     nl_langinfo() returns a pointer to an empty string if item contains an
     invalid setting.

SEE ALSO    [Toc]    [Back]

      
      
     setlocale(3)

STANDARDS    [Toc]    [Back]

     The nl_langinfo() function conforms to Version 2 of the Single UNIX
     Specification (``SUSv2'').

HISTORY    [Toc]    [Back]

     The nl_langinfo() function first appeared in FreeBSD 4.6.


FreeBSD 5.2.1			  May 3, 2001			 FreeBSD 5.2.1
[ Back ]
 Similar pages
Name OS Title
langinfo HP-UX language information constants
langinfo IRIX language information constants
nl_langinfo Linux query language and locale information
geocustoms HP-UX configure system language on multi-language systems
cpp IRIX the C language preprocessor
cpp Tru64 the C language preprocessor
wishx IRIX Tcl language interpreter with Tk
cpp HP-UX the C language preprocessor
setlocale FreeBSD natural language formatting for C
c89 FreeBSD POSIX.2 C language compiler
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service