I have a global set of values, e.g. ["Foo", "Bar", "Baz", "Quux"]. Each row in my TreeView represents an entity that can only deal with a subset of these values. For example, the first row might deal with "Foo" and "Bar", and the second, "Bar" and "Quux". I want a ComboBox column to allow each row to select one of the values it can deal with.
However, from the code I have now, the entire column can only have one model for the ComboBox:
crc = gtk.CellRendererCombo()
crc.set_property('model', fooValuesModel)
crc.set_property('text-column', 0)
crc.set_property('editable', True)
crc.set_property('has_entry', False)
cl = gtk.TreeViewColumn(ctitle, crc, text=i)
treeView.append_column(cl)
I have only one opportunity to set a model for the entire column. Is there any way to have different stores for each row, or to filter values somehow?