// ComboBoxTextNewWithEntry is a wrapper around gtk_combo_box_text_new_with_entry(). func ComboBoxTextNewWithEntry() (*ComboBoxText, error) { c := C.gtk_combo_box_text_new_with_entry() if c == nil { return nil, nilPtrErr } obj := wrapObject(unsafe.Pointer(c)) return wrapComboBoxText(obj), nil }
func gtk_combo_box_text_new_with_entry() *C.GtkWidget { w := C.gtk_combo_box_text_new_with_entry() // we need to set the entry's width-chars to achieve the arbitrary sizing we want // thanks to tristan in irc.gimp.net/#gtk+ // in my tests, this is sufficient to get the effect we want; setting the cell renderer isn't necessary like it is with an entry-less combobox entry := togtkentry(C.gtk_bin_get_child((*C.GtkBin)(unsafe.Pointer(w)))) C.gtk_entry_set_width_chars(entry, 0) return w }