gtk+ r20795 - in trunk/docs/reference: . gtk



Author: matthiasc
Date: Sun Jul  6 23:38:41 2008
New Revision: 20795
URL: http://svn.gnome.org/viewvc/gtk+?rev=20795&view=rev

Log:
Mention bind_textdomain_codeset in faq


Modified:
   trunk/docs/reference/ChangeLog
   trunk/docs/reference/gtk/question_index.sgml

Modified: trunk/docs/reference/gtk/question_index.sgml
==============================================================================
--- trunk/docs/reference/gtk/question_index.sgml	(original)
+++ trunk/docs/reference/gtk/question_index.sgml	Sun Jul  6 23:38:41 2008
@@ -190,9 +190,10 @@
 <para>
 The short checklist on how to use gettext is: call bindtextdomain() so gettext 
 can find the files containing your translations, call textdomain() to set the 
-default translation domain, then call gettext() to look up each string to be 
-translated in the default domain. Conventionally, people define macros as
-follows for convenience:
+default translation domain, call bind_textdomain_codeset() to request that
+all translated strings are returned in UTF-8, then call gettext() to look up 
+each string to be translated in the default domain. 
+Conventionally, people define macros as follows for convenience:
 <informalexample>
 <programlisting>
   #define  _(x)  gettext (x)
@@ -354,6 +355,11 @@
 g_free (text);
 </programlisting></informalexample>
 </para>
+<para>
+If you are using gettext() to localize your application, you need to
+call bind_textdomain_codeset() to ensure that translated strings are
+returned in UTF-8 encoding.
+</para>
 </answer>
 </qandaentry>
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]