diff options
author | Matthias Clasen <matthiasc@src.gnome.org> | 2008-07-06 23:38:41 +0000 |
---|---|---|
committer | Matthias Clasen <matthiasc@src.gnome.org> | 2008-07-06 23:38:41 +0000 |
commit | f53a77895b5d319f66164cd7a9ebae057478e2b3 (patch) | |
tree | f901bf2104f03a76fb4cd4656c59558bbd317fc8 | |
parent | 0950b2aa73093d1f95d24b55b95903be6b859168 (diff) | |
download | gtk+-f53a77895b5d319f66164cd7a9ebae057478e2b3.tar.gz |
Mention bind_textdomain_codeset in faq
svn path=/trunk/; revision=20795
-rw-r--r-- | docs/reference/ChangeLog | 6 | ||||
-rw-r--r-- | docs/reference/gtk/question_index.sgml | 12 |
2 files changed, 15 insertions, 3 deletions
diff --git a/docs/reference/ChangeLog b/docs/reference/ChangeLog index 5866135f15..d114924b1d 100644 --- a/docs/reference/ChangeLog +++ b/docs/reference/ChangeLog @@ -1,3 +1,9 @@ +2008-07-06 Matthias Clasen <mclasen@redhat.com> + + Bug 488019 - Mention bind_textdomain_codeset in gettext related FAQ + + * gtk/question_index.sgml: Mention bind_textdomain_codeset() + 2008-07-05 Matthias Clasen <mclasen@redhat.com> * === Released 2.13.4 === diff --git a/docs/reference/gtk/question_index.sgml b/docs/reference/gtk/question_index.sgml index 40923f174a..c8d638de67 100644 --- a/docs/reference/gtk/question_index.sgml +++ b/docs/reference/gtk/question_index.sgml @@ -190,9 +190,10 @@ to read the documentation. <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_print(text); 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> |