Gtk Perl: Removing an item from a Gtk2::ComboBox by its name, rather than index -
while working perl , gtk2, have programmatically remove option drop-down (combobox). while i'm aware $combo_box->remove_text ($position)
trick in 1 shot, need remove option based on name (entered user).
i'm unable find method can return index of item name. out?
it's bit unclear mean "name"; combo box items don't have names. if combo box textual, each item made of text, text isn't name. have same string in items instance, make unclear 1 want delete.
i think you're going have implement youself, iterating on combo box's underlying tree model. it's if want delete first match, continue searching find of them.
Comments
Post a Comment