Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

locale::gettext_xs(3pm) [debian man page]

Locale::gettext_xs(3pm) 				User Contributed Perl Documentation				   Locale::gettext_xs(3pm)

NAME
Locale::gettext_xs - XS Implementation of Uniforum Message Translation SYNOPSIS
use gettext_xs (:locale_h :libintl_h); gettext $msgid; dgettext $domainname, $msgid; dcgettext $domainname, $msgid, LC_MESSAGES; ngettext $msgid, $msgid_plural, $count; dngettext $domainname, $msgid, $msgid_plural, $count; dcngettext $domainname, $msgid, $msgid_plural, $count, LC_MESSAGES; pgettext $msgctxt, $msgid; dpgettext $domainname, $msgctxt, $msgid; dcpgettext $domainname, $msgctxt, $msgid, LC_MESSAGES; npgettext $msgctxt, $msgid, $msgid_plural, $count; dnpgettext $domainname, $msgctxt, $msgid, $msgid_plural, $count; dcnpgettext $domainname, $msgctxt, $msgid, $msgid_plural, $count, LC_MESSAGES; textdomain $domainname; bindtextdomain $domainname, $directory; bind_textdomain_codeset $domainname, $encoding; my $category = LC_CTYPE; my $category = LC_NUMERIC; my $category = LC_TIME; my $category = LC_COLLATE; my $category = LC_MONETARY; my $category = LC_MESSAGES; my $category = LC_ALL; DESCRIPTION
The module Locale::gettext_xs is the low-level interface to message translation according to the Uniforum approach that is for example used in GNU gettext and Sun's Solaris. The module does not necessarily work on your system. It depends on the presence of shared libraries that are not always available. The higher-level modules Locale::TextDomain::(3), resp. Locale::Messages(3) will fall back to a pure Perl version if boostrapping Locale::gettext_xs fails. The interface of Locale::gettext_xs is mostly identical to the pure Perl version as described in Locale::gettext_pp(3), see there for details. Differences are outlined below. Locale::gettext_xs is downwards compatible to Locale::gettext(3) by Phillip Vandry <vandry@Mlink.NET>. You can use it as replacement for Locale::gettext(3). Please note that directory names passed to the function bindtextdomain() are automatically converted from Perl semantics (slash as directory separator) to local semantics (for example the backslash for MS-DOS). AUTHOR
Copyright (C) 2002-2009, Guido Flohr <guido@imperia.net>, all rights reserved. See the source code for details. The module is based on the work of Phillip Vandry <vandry@Mlink.NET> in Locale::gettext(3). This software is contributed to the Perl community by Imperia (<http://www.imperia.net/>). SEE ALSO
Locale::TextDomain(3pm), Locale::gettext_pp(3pm), Locale::gettext(3pm), Locale::Messages(3pm), File::Spec(3), perl(1) POD ERRORS
Hey! The above document had some coding errors, which are explained below: Around line 109: =cut found outside a pod block. Skipping to next block. perl v5.14.2 2009-06-23 Locale::gettext_xs(3pm)

Check Out this Related Man Page

NGETTEXT(3)						     Library Functions Manual						       NGETTEXT(3)

NAME
ngettext, dngettext, dcngettext - translate message and choose plural form SYNOPSIS
#include <libintl.h> char * ngettext (const char * msgid, const char * msgid_plural, unsigned long int n); char * dngettext (const char * domainname, const char * msgid, const char * msgid_plural, unsigned long int n); char * dcngettext (const char * domainname, const char * msgid, const char * msgid_plural, unsigned long int n, int category); DESCRIPTION
The ngettext, dngettext and dcngettext functions attempt to translate a text string into the user's native language, by looking up the appropriate plural form of the translation in a message catalog. Plural forms are grammatical variants depending on the a number. Some languages have two forms, called singular and plural. Other languages have three forms, called singular, dual and plural. There are also languages with four forms. The ngettext, dngettext and dcngettext functions work like the gettext, dgettext and dcgettext functions, respectively. Additionally, they choose the appropriate plural form, which depends on the number n and the language of the message catalog where the translation was found. In the "C" locale, or if none of the used catalogs contain a translation for msgid, the ngettext, dngettext and dcngettext functions return msgid if n == 1, or msgid_plural if n != 1. RETURN VALUE
If a translation was found in one of the specified catalogs, the appropriate plural form is converted to the locale's codeset and returned. The resulting string is statically allocated and must not be modified or freed. Otherwise msgid or msgid_plural is returned, as described above. ERRORS
errno is not modified. BUGS
The return type ought to be const char *, but is char * to avoid warnings in C code predating ANSI C. SEE ALSO
gettext(3), dgettext(3), dcgettext(3) GNU gettext 0.11.4 May 2001 NGETTEXT(3)
Man Page