| 1 |
<refentry id="refi18n"> |
| 2 |
|
| 3 |
<refmeta> |
| 4 |
<refentrytitle>ne_i18n_init</refentrytitle> |
| 5 |
<manvolnum>3</manvolnum> |
| 6 |
</refmeta> |
| 7 |
|
| 8 |
<refnamediv> |
| 9 |
<refname id="ne_i18n_init">ne_i18n_init</refname> |
| 10 |
<refpurpose>functions to initialize internationalization support</refpurpose> |
| 11 |
</refnamediv> |
| 12 |
|
| 13 |
<refsynopsisdiv> |
| 14 |
|
| 15 |
<funcsynopsis> |
| 16 |
|
| 17 |
<funcsynopsisinfo>#include <ne_i18n.h></funcsynopsisinfo> |
| 18 |
|
| 19 |
<funcprototype> |
| 20 |
<funcdef>void <function>ne_i18n_init</function></funcdef> |
| 21 |
<paramdef>const char *<parameter>encoding</parameter></paramdef> |
| 22 |
</funcprototype> |
| 23 |
|
| 24 |
</funcsynopsis> |
| 25 |
|
| 26 |
</refsynopsisdiv> |
| 27 |
|
| 28 |
<refsect1> |
| 29 |
<title>Description</title> |
| 30 |
|
| 31 |
<para>The <function>ne_i18n_init</function> function can be used |
| 32 |
to enable support for translated messages in the &neon; library. |
| 33 |
The <parameter>encoding</parameter> parameter, if non-&null;, |
| 34 |
specifies the character encoding required for generated translated |
| 35 |
string. If it is &null;, the appropriate character encoding for |
| 36 |
the process locale will be used.</para> |
| 37 |
|
| 38 |
<para>This call is only strictly necessary if either: |
| 39 |
|
| 40 |
<orderedlist numeration="loweralpha"> |
| 41 |
|
| 42 |
<listitem><simpara>&neon; has been installed into a different |
| 43 |
prefix than the <literal>gettext</literal> implementation on |
| 44 |
which it depends for i18n purposes, or</simpara></listitem> |
| 45 |
|
| 46 |
<listitem><simpara>the caller requires that translated messages |
| 47 |
are in a particular character encoding.</simpara></listitem> |
| 48 |
|
| 49 |
</orderedlist></para> |
| 50 |
|
| 51 |
<para>If <function>ne_i18n_init</function> is never called, the |
| 52 |
message catalogs will not be found if case (a) applies (and so |
| 53 |
English error messages will be used), and will use the default |
| 54 |
character encoding specified by the process locale. The library |
| 55 |
will otherwise operate correctly.</para> |
| 56 |
|
| 57 |
<para>Note that the encoding used is a process-global setting and |
| 58 |
so results may be unexpected if other users of &neon; within the |
| 59 |
process call <function>ne_i18n_init</function> with a different |
| 60 |
encoding parameter.</para> |
| 61 |
|
| 62 |
</refsect1> |
| 63 |
|
| 64 |
<refsect1> |
| 65 |
<title>See also</title> |
| 66 |
|
| 67 |
<para><xref linkend="ne_sock_init"/></para> |
| 68 |
</refsect1> |
| 69 |
|
| 70 |
</refentry> |
| 71 |
|