On Tue, Oct 03, 2006 at 10:34:39AM -0300, j.romildo@gmail.com wrote: > Hello. > > I am using lablgtk to write the GUI for an application I am > developing. Currently I want to set the image associated with a button, > but it seems that lablgtk does not have support for the Gtk API function > gtk_button_set_image. So I am writing to request this support in the > next version of lablgtk. I have written the attached to add the methos image and set_image to class Button of gtklabel. But I did not get the types correct for the GtkWidget* from the Gtk+ API. Maybe someone has a clue on how those methods should be typed. In Gtk+ the functions have the prototypes: GtkWidget* gtk_button_get_image (GtkButton *button); void gtk_button_set_image (GtkButton *button, GtkWidget *image); The idea is to have two new methods in the class button (files gButton.mli and gButton.ml): image : option set_image : -> unit and two extern functions in module Button of file gtkButton.ml: external set_image : [>`button] obj -> -> unit = "ml_gtk_button_set_image" external image : [>`button] obj -> option = "ml_gtk_button_get_image" Any help is welcome. Romildo