Retrieving Column Data from a ListStore?
Mike Wey
mike-wey at example.com
Wed Apr 24 15:13:29 UTC 2019
On 24-04-2019 16:38, Ron Tarrant wrote:
> Another thing I've been struggling with is fetching data from a
> TreeIter. Getting the iter itself is no problem, but when it comes to
> getting the contents of a specific column within the iter, none of the
> methods I've tried have worked. In fact, it almost seems like none of
> them are implemented.
>
> I've written a callback function named onChanged() in the MyComboBox
> class that gets the TreeIter, but that's all I can get working. If
> anyone knows how to grab data from column 2 of the iter (see the
> MyListStore class at the bottom for the structure of the store) I'd be
> ever so grateful if you could fill in whatever else would be needed in
> that callback.
>
> Here's the code:
>
> ```
> ...
>
> ```
The ListStore/TreeModel provides functions to retrieve the data,
`gtk.TreeModelIF.TreeModelIF.getValue`.
A TreeIter indicates the row these kind of function apply to.
--
Mike Wey
More information about the Digitalmars-d-learn
mailing list