[Glade-users] glade: how to create a "gtk_combo_box_new_text()" instance?

Damon Chaplin damon@karuna.uklinux.net
Mon, 25 Oct 2004 14:35:11 +0100


On Mon, 2004-10-25 at 07:05, Neil Zanella wrote:
> Hello,
> 
> I have defined a GTK+ combo box with Glade. I would like to
> start adding character strings to it with:
> 
> gtk_combo_box_append_text ()
> 
> However, glade does not give me the option it seems to instantiate the
> combo box with gtk_combo_box_new_text() instead of with gtk_combo_box_new ()
> and according to the docs the combo box needs be instantiated with the former
> for things to work.
> 
> Any ideas? Is there some way to get round this restriction?

Look at the code for gtk_combo_box_new_text(). You just have to set up
the combo in a similar way and append_text() will work fine.

Damon