Re: tooltips for each row with GtkTreeView?



On Mon, 2004-10-25 at 15:40, fwmiller cornfed com wrote:
Thanks for the reply.

I will take it from this response that it does not exist in the current versions of GTK.

I'm curious tho, I see such functionality in Gaim for example.  I guess I need to look at the source for 
that app to see what they are doing.

There're some ways to achieve this goal, but you must code some bits
yourself.

As example, you can track the mouse event in the tree, get the path from
the mouse position to know the row it's on, and show any tooltip you
want for this row.

The bits to track the mouse ( "event" signal with type GDK_ENTER_NOTIFY
should work ), to get the mouse position ( gdk_event_get_coords() ), to
know the path from position (  gtk_tree_view_get_path_at_pos, this could
need some coversions as gtk_tree_view_widget_to_tree_coords ), and to
build the tooltips are in place.

All other functionality should be implemented.

Regards.
-- 
Iago Rubio         
- GPG Keyserv  * pgp.rediris.es id=0x909BD4DD



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