[gtkada] Dynamically Changing the Toggle Button Label
Arnaud Charlet
charlet at ACT-Europe.FR
Thu Oct 12 17:46:06 CEST 2000
> I tried the above, it compiles but when I execute it I get a Contraint Error
> at the Set_Text Line.
Emmanuel explained that with GtkAda 1.2.8, you do need Gtk.Type_Conversion.
> Maybe I did something wrong, I don't know. When I withed in
> Gtk.Type_Conversion the compiler said no entities from it were being used.
It sounds like you didn't read the GtkAda documentation, nor the
GNAT documentation for that matter ;-)
What the compiler said was a warning, not an error, what you forgot to do
is to call Gtk.Type_Conversion.Init, I am not sure how the GtkAda documentation
could make it clearer (any suggestion is welcome btw):
<<
@example
@b{with} Gtk.Type_Conversion;
@b{begin}
Gtk.Main.Init;
Gtk.Type_Conversion.Init;
...
@b{end}
@end example
>>
> Also, when will there be a set_text procedure that takes a button and text
> entry to directly set the text on a button.
I fail to see the necessity of such a procedure when it is as simple
as Set_Text (Gtk_Label (Get_Child (Button)), "label").
Note that if you are developping with GtkAda for a serious project, you
might find useful to buy support from Ada Core Technologies or ACT Europe,
depending on your geographic location.
Best,
Arno
More information about the gtkada
mailing list