Re: Gettext & Gtk1.3.12



Andreas Scherf <scherfa web de> writes:
> Hello, i am porting my little app to Gtk2
> and i have the problem the the gettext Strings such as (_("xyz")
> On some String it shows me:
> Gtk-WARNING **: Invalid input string
> and some are just empty.
> On normal String i got the message :
>  Invalid UTF8 string passed to pango_layout_set_text()
> What am i doing wrong here ?

GTK 2 only understands UTF-8. You can't give it Latin-1 for example.

> Do i have to tell Pango which Sort of language im talking about and hoe
> do i do that ?

You may want to tell gettext to convert to UTF-8:

 bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8");

Alternatively, change your po files to contain UTF-8.

Havoc




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