Re: gtktreeview API request



On Fri, 2004-11-26 at 23:07 -0500, Allin Cottrell wrote:
I would find it very useful (and I think some others might too) if 
there were a means of getting a pointer to the current GtkEntry (if 
any) in a treeview containing editable text cells: say

GtkWidget *gtk_tree_view_get_entry (GtkTreeView *tree_view)

which would return NULL if there's no active editable entry, and the 
appropriate widget pointer otherwise.

Without this, it's very difficult if not impossible to get a 
treeview to act like a simple spreadsheet, where the user can move 
to a given cell and simply start typing to fill out the cell's data. 
The GTK programmer can arrange that, e.g., typing a number starts 
the cell editing process, but then the first number typed is "eaten" 
and there's no way (that I can see) to pass it into the GtkEntry 
that is created as part of the cell editing process: this widget is 
private and inaccessible.


In 2.6, GtkCellRenderer has an editing-started signal, which gives you
access to the GtkCellEditable (ie the widget which is used for editing
the cell). Not sure if that will help you, but it shows that the widget
is no longer totally private and somewhat accessible.

Matthias




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