Editable cells on gtk_list_store
- From: Gustavo Noronha Silva <kov debian org>
- To: Gtk App <gtk-app-devel-list gnome org>
- Subject: Editable cells on gtk_list_store
- Date: Sun, 19 May 2002 19:52:03 -0300
Hello,
I would like to have one column of cells of my list editable...
I have:
toggle (finished) | text (description) | text (filename - not shown!)
I would like to have 'description' editable... following gtk-demo's
code I've done:
[...]
enum
{
FINISHED_COLUMN,
DESCRIPTION_COLUMN,
EDITABLE_COLUMN,
FILENAME_COLUMN,
NUM_COLUMNS
};
[...]
/* column for description */
cr = gtk_cell_renderer_text_new ();
g_signal_connect (G_OBJECT(cr), "edited",
G_CALLBACK(edit_description_cb),
tree_model);
g_object_set_data (G_OBJECT (cr), "column", (gint *)1);
gtk_tree_view_insert_column_with_attributes (tview,
-1,
_("Description"),
cr,
"text", DESCRIPTION_COLUMN,
"editable", EDITABLE_COLUMN,
NULL);
[...]
But when I run the program, add a new line in the list and click it, then
click it again (to edit) nothing happens... This is what is done when adding
the new line:
[...]
gtk_list_store_set (tree_model, &ti,
FINISHED_COLUMN, FALSE,
DESCRIPTION_COLUMN, description,
FILENAME_COLUMN, "teste",
EDITABLE_COLUMN, TRUE
-1);
[...]
Any hints?
[]s!
--
kov debian org: Gustavo Noronha <http://people.debian.org/~kov>
Debian: <http://www.debian.org> * <http://debian-br.cipsga.org.br>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]