Re: Questions on Combo inside TreeView




Murray Cumming wrote:
On Mon, 2005-03-14 at 18:13 -0300, Leandro Fanzone wrote:
  
Hello. I'm using Gtk::CellRendererCombo to provide a combobox inside a 
TreeView. I have two questions:

1) The Combo is built from a TreeModel. The field selected with 
property_text_column() is the one to be shown in the combo. How to 
access the other columns for the selected item in the TreeModel? I mean, 
if one item is selected, how to access the values entered in the other 
fields for that item, without having to go through all the children 
comparing strings?
    

If you have the TreeModel::iterator then you can use TreeModel::Row[]
just as you would for a TreeView.
  

That's clear; te question is, how to get that iterator? The path you get with on_edited deals with the main tree, not with the internal tree used to build the combo. Where's the iterator that points to the selection?

Leandro.


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]