Hey guys, gals,and others, My first post here, please let me know if there is something wrong with how this email appears, don't want to be guilty of top-posting or such, so kind words of advice appreciated. I have been a lurker here for a while and noticed a number of other posts drawing attention to difficulties getting signals from glade-3(.ui xml files) to work with handlers defined in ones source code. This problem is now official. Signals are not getting properly connected. I use the word official because I have tried this on multiple different machines, real and vms, with different versions of vala and glade-3 (including git current vala and glade-3). And in no combination does build.connect_signals actually result in a working program- in most cases error message just reports 'cannot find blah-blah-on-button-clicked signal', but in other case there is just an abrupt segmentaion fault. I have no idea where the problem actually is located(whether in vala, or in the ui generation from glade-3, or gtk+ itself or wherever else). Now I may be doing this entirely wrong, I may be making some simple mistake-but I get the sneaky suspicion that a) I am not alone in these problems b) that regardless of whatever errors I may be guilty of something in vala+gtk+glade-3 is not right. So please kindly point out my mistake if any-my goal in complaining to to shed some light-if it my bad, so be it, let's just get The Proper Way(tm) out and spread the word and if not I am more than willing to devote several hours to trying to chase this potential bug down, find him, and deliver him for execution by coders more capable than me. I have been forced to manually override each signal definition when trying to work with glade ui files. So I use builder.get_object to assign the ui widget from the ui file to some local variable(var) and just write my own signal handler to get it to work. The net effect of which is that using glade to create the ui is basically crippled because I end up having override anything I define in glade-3 anyway. I include the sample test from GTk+Sample here(the attached file fail to run under : Fedora 12, Ubuntu 9.10, Gnome-Developer-Kit(conary-based distro running in VM). And although this is a separate and totally unrelated issue, I will mention it here: the dbus integration in vala leaves something to be desired: namely quit mangling the signals that dbus sends. I attempted to implement a tiny dbus client for rhythmbox, modeled after a widely used python tutorial. Spend at least 10 hours pulling what little hair I have left on my head out until I realized that the next() signal, defined by rhythmbox dbus to fetch the next song from list of songs in the current queue, was never getting called because by the time vala got done mangling the singal the only thing which came out was "Next"-lol, for what ever reasons dbus via vala means you cannot access signals tha do not follow CamelCaseConventions. I "solved" this problem by editing the rhythmbox rb-shell-player.xml and changing "next" to "Next" and recompiling. So there, that's my way of saying hello to this mailing list, the awesome vala developers and hackers, who aside from causing me some lost hair have actually rekindled my interest in programming for the first time in over 20 years. And despite the problems I mentioned above I have written about 2000 lines of code in the past 10 days that actually work ;) Karl Zollner ps. If some solutions can be offered to the problems I would love to dish out a series of extremely verbose and well-worded tutorials showing step for step how to do lots of different things in vala(I already rewrote half of the genie examples from valaide in vala). I am positively in LOVE with vala right now and wish to be able to contribute to it at some point in the not too distant future.
Attachment:
text-file-viewer.vala
Description: Binary data
Attachment:
text-file-viewer.ui
Description: application/designer