Remove all text elements from GtkComboBox
Hi, I've started migrating from GtkCombo to GtkComboBox. My old GtkCombo contains only text, so I use gtk_combo_box_new_text() At some point I have to 're-build' the text in the combobox which is done by first removing all existing text 'entries' and insert all the new text 'entries'. I haven't stored information about how many text elements I have appended. I've planed to use gtk_combo_box_remove_text(), but I can't see how I can know when I have removed all text 'entries'. (I the old GtkCombo, I just ran through the glist.) Anyone able to help me on this one - it is probably simple when you know how to do it... Best regards Egon Andersen ___ gtk-list mailing list [EMAIL PROTECTED] http://mail.gnome.org/mailman/listinfo/gtk-list
Re: Remove all text elements from GtkComboBox
Hi, Egon Andersen [EMAIL PROTECTED] writes: I've started migrating from GtkCombo to GtkComboBox. My old GtkCombo contains only text, so I use gtk_combo_box_new_text() At some point I have to 're-build' the text in the combobox which is done by first removing all existing text 'entries' and insert all the new text 'entries'. I haven't stored information about how many text elements I have appended. I've planed to use gtk_combo_box_remove_text(), but I can't see how I can know when I have removed all text 'entries'. I haven't tried myself, but the following call should do the trick: gtk_list_store_clear (GTK_LIST_STORE (gtk_combo_box_get_model (combo))); Sven ___ gtk-list mailing list [EMAIL PROTECTED] http://mail.gnome.org/mailman/listinfo/gtk-list