---------- Forwarded message ---------- From: Michael Thomsen <[EMAIL PROTECTED]> Date: May 14, 2005 2:54 PM Subject: Re: [Gtk-sharp-list] Re: Some questions about layout management in Gtk# 2.0 To: Eric Butler <[EMAIL PROTECTED]>
The error message is: C:\project1>C:\mono\bin\mono Test.exe (<unknown>:1620): GLib-CRITICAL **: g_convert: assertion `str != NULL' failed Unhandled Exception: System.ArgumentException: Object type cannot be converted t o target type. Parameter name: val in <0x000ba> System.Reflection.MonoField:SetValue (System.Object obj, System.Obj ect val, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Global ization.CultureInfo culture) in <0x0017c> Glade.XML:BindFields (System.Object target, System.Type type) in <0x00019> Glade.XML:BindFields (System.Object target) in <0x00016> Glade.XML:Autoconnect (System.Object handler) in <0x00047> Test:.ctor () in <0x00016> Test:Main (System.String[] args) C:\project1> On 5/14/05, Eric Butler <[EMAIL PROTECTED]> wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > Michael Thomsen wrote: > > 1) How do you put two elements such as a label and a combobox in a 2 > > element VBox and have them set to be variable sizes? Let's say I want > > the label to take up 20% of the space and the comobox to take up 80% > > of the space. Is this even possible with Gtk#'s layout management? > > I do not believe Gtk supports percentage widths, but I think you will > find that it's generally not something you need. You can place your > label and widget in either a GtkTable or GtkHBox to have it size them > properly. > > If you do not believe this will work for you, please reply with a more > specific explination of what you wish to achieve. > > > 2) When I try to reference a ComboBox object marked with a [Widget] > > attribute from a Glade file, my test program crashes. Could someone > > explain why this happens? Below is the code in question: > > I am assuming you are getting a type cast exception. If I am wrong, you > should post the error!!! In glade, select the widget and look in the > Properties window under "Class". You are probably using a > GtkComboBoxEntry (Gtk.ComboBoxEntry) instead of a GtkComboBox, or > something to that effect. > > Regards, > Eric > -----BEGIN PGP SIGNATURE----- > Version: GnuPG v1.2.5 (GNU/Linux) > Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org > > iD8DBQFChkB6sSPwEOmqwCIRAoqrAJ9DxUIdw2Gz5c49+KGsA8bheDHDgwCfVhlP > TQ9jN/+LwT+ZggQUbECDLeg= > =LWdO > -----END PGP SIGNATURE----- > _______________________________________________ > Gtk-sharp-list maillist - [email protected] > http://lists.ximian.com/mailman/listinfo/gtk-sharp-list >
project1.glade
Description: Binary data
Test.cs
Description: Binary data
_______________________________________________ Gtk-sharp-list maillist - [email protected] http://lists.ximian.com/mailman/listinfo/gtk-sharp-list
