Re: Another case of gettext with Gtk2::GladeXML

Ahh, I see your problem.
When you load the glade you use

  $xml_root = Gtk2::GladeXML->new( $glade_dir."/" );

To get gettext to handle the glade you need to add the DOMAIN option.
Change the line to

  $xml_root = Gtk2::GladeXML->new( $glade_dir."/", 'gui',

and give it another try.
I'm not sure if you need the 'gui' bit, you may be able to leave this as


On Thu, 2006-08-17 at 01:00 -0400, Pascal wrote:  $xml_root = 
 i'd like to came back on the email:

I can get the translation working no problem for the code part
(, but not the glade file.
Including Chris' code (see EXPERIMENTAL section in, i
get an error at runtime:
 Subroutine main::gettext redefined at /usr/share/perl/5.8/ line 65.
 at ./ line 40

And the interface part doesn't get translated.
You can reproduce by running in fr_CA, type hoax, click search and
look if the button Ignore is Ignorer.

My translations are in po/ .
I update them with a small Makefile for the moment.
Use "make" to see the different possibilities.
"make all" will update the .pot, update the po file, convert to mo
file, install mo file in ../LocaleData .

thanks for any tips/help,

Homepage (
Debian GNU/Linux (

Attachment: signature.asc
Description: This is a digitally signed message part

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