RE: gtktreeview with expanded row

The first is to not have another row for the description 
and make the
description part of the user row (just CR it to make it 
appear on the line
but I want the description to be scaled to 0.7 of others rows.

The second is to just make is a child of the "user" row and 
simply catch the
"row-expanded" or "row-collapsed" signal for the 
GtkTreeView for the parent
(the user row) and automatically expand the description 
row.  The problem
is, I dont think there is a way to hide the expander arrow 
- atleast not
easily with the current API.
hm, I don't want the arrow, if it will not be used. so I will create
another row for each user in the same parent.

To make a row unselectable you might have to intercept the 
signal for the GtkTreeModel when items are selected.  You 
should be able to
do this and return TRUE or FALSE based on if you want the row to be
I have a callback to GtkTreeSelection of this treeview, but 
which is of
on_treeview_select_row(GtkTreeSelection *selection,
                        gpointer user_data)

so, what to do now, if the type of return is void ?

This is how to set the function:

NOTE: I have used this method before and each time the selection changes,
you do not get just ONE event (if memory serves).  You get events to state
that selection has changed for each item, for example, if you select item 2,
and item 1 was selected, you receive an event to state item 1 is now NOT
selected and item 2 now IS selected. 

This can be tricky, but should do what you want.


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