[Glade-users] gtk-builder-convert

Ian Chapman ichapman at videotron.ca
Fri Apr 11 17:16:22 UTC 2014


Thanks Tristan,
     I am new to Glade though I have written and run a couple of dot.c 
programs using gtk+  I have both gtk2.0 and gtk3.0 on my machine.

     I guess I did not explain that I was following a tutorial 
http://www.micahcarrick.com/gtk-glade-tutorial-part-3.html and it is 
stated as "GTK+ and Glade3 GUI Programming Tutorial" but looking more 
closely there are a few loose ends.  After generating tutorial.glade, 
run builder then generate the file main.c and compile.  It compiled best 
with gtk+3.0 and generated an executable that could not find gtkObject.  
If I save a new glade fileas tutorial.xml and recompile the new 
executable gives the same error. I think that I am nearly there.

     I have at the moment not succeeded in doing useful work with glade 
but It looks like it will be really good once I get the process of what 
to do with the glade file that I have generated. I'm sure all that I 
need is a push in the right direction? Regards Ian.

On 04/11/2014 03:51 PM, Tristan Van Berkom wrote:
> On Thu, 2014-04-10 at 14:57 -0400, Ian Chapman wrote:
>> Hi,
>>       I am using glade 3.14.2 and gtk-builder-convert --version option is
>> not supported.  Working through the glade 3 tutorial and I run
>>
> Why are you using gtk-builder-convert ?
>
> gtk-builder-convert is a script which was distributed by GTK+ to help
> migrate from libglade -> GtkBuilder - if your Glade file did not
> have <glade-interface> to begin with, then it was NOT a libglade file
> to start out with.
>
> I have to guess that you are trying to convert something that is
> already a GtkBuilder UI file.
>
> Furthermore, I should note that I would not recommend using the
> gtk-builder-convert script, Glade 3.8 provides a migration path
> for libglade format to GTK+2 GtkBuilder files - if you must
> convert from libglade I would recommend using Glade 3.8 to do
> it, and try to ensure that your project only uses widgets that
> are not deprecated in GTK+ 2.24. After this you can use a newer
> version of Glade on your GtkBuilder XML which was targeting
> GTK+2... newer versions of Glade will then give you access to
> newer widgets/properties/signals introduced in GTK+3
>
> Cheers,
>      -Tristan
>
>>    gtk-builder-convert tutorial.glade tutorial.xml
>> Traceback (most recent call last):
>>     File "/usr/bin/gtk-builder-convert", line 799, in <module>
>>       sys.exit(main(sys.argv))
>>     File "/usr/bin/gtk-builder-convert", line 787, in main
>>       conv.parse_file(input_filename)
>>     File "/usr/bin/gtk-builder-convert", line 162, in parse_file
>>       self._parse()
>>     File "/usr/bin/gtk-builder-convert", line 234, in _parse
>>       assert glade_iface, ("Badly formed XML, there is "
>> AssertionError: Badly formed XML, there is no <glade-interface> tag.
>>
>>       the above is what I get!  Tristan did send me Glade 16 and I was
>> having a similar difficulty.  Once I generate a glade file what do I do
>> with it???  The tutorial runs out of steam with the above and I think
>> it's all compatibility issues.  I do not know what version the tutorial
>> was based on but Glade 3.14.2 seems to have improved on the way bits
>> drop into place.  I hope that you can help.  Regards Ian.
>> _______________________________________________
>> Glade-users maillist  -  Glade-users at lists.ximian.com
>> http://lists.ximian.com/mailman/listinfo/glade-users
>
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ximian.com/pipermail/glade-users/attachments/20140411/062987c9/attachment.html>


More information about the Glade-users mailing list