[pygtk] Inconsistent format for "path" in TreeView callbacks
Jason Heeris
jason.heeris at gmail.com
Fri May 6 16:31:46 WST 2011
Say I have a TreeView with a CellRendererToggle in one of the columns.
If I double-click on a row, it will emit a 'row-activated' signal,
passing the path as one of the parameters. If I select one of the
CellRendererToggle checkboxes, it will emit a 'toggled' signal, also
passing the path as one of the parameters. However, in the first case
it is passed as a tuple (eg. "(0,)"), but in the second case it is
given as a string (eg. "0").
Is there a canonical way to convert between these two formats? I don't
want to just use a simple line of code that turns out to be wrong at
some point in the future...
— Jason
More information about the pygtk
mailing list