Re: second patch to gtktreeview.overrides
| From: | Markus Fischer | Date: | Mon, 09 May 2005 20:29:42 +0000 |
| Subject: | Re: second patch to gtktreeview.overrides | ||
| References: | 1 2 3 | Groups: | php.gtk.dev |
| Request: | Send a blank email to php-gtk-dev+get-1236@lists.php.net to get a copy of this message | ||
Hi,
in addition to gtk_tree_store* I've added
gtk_tree_model_get_iter_from_string which allowed me to implement
editable cells in a tree:
[...]
$cell = new GtkCellRendererText;
$cell->set_data("column", 1);
$cell->connect("edited", "cell_edited", $store);
[...]
function cell_edited($cell, $path, $newText, $store) {
$column = $cell->get_data("column");
$iter = $store->get_iter_from_string($path);
$store->set($iter, $column, $newText);
}
[...]
Since the whole GtkTreePath support is missing, get_iter_from_string
seems the way of least ressistance to me.
- Markus