Re: Re: GTK+ Tooltip and clist rows
| From: | Scott Mattocks | Date: | Mon, 06 Feb 2006 13:48:59 +0000 |
| Subject: | Re: Re: GTK+ Tooltip and clist rows | ||
| References: | 1 2 | Groups: | php.gtk.general |
| Request: | Send a blank email to php-gtk-general+get-6656@lists.php.net to get a copy of this message | ||
Hi Nathan,
This is an interesting solution, thanks. I haven't given it a try yet, but it looks to me like the tool tip will appear the instant the user moves the mouse over the row. That could slow things down a little when the user just moves the mouse across the list to get to the menu. Is that what happens or am I missing something. That behavior also isn't consistent with other tool tips. They normally have a delay before they are shown. You might want to try something like this to get a more realistic tool tip feel:
$this->connect_object('enter-notify-event', array(&$this, '_startTTDelay'));
$this->connect_object('leave-notify-event', array(&$this, '_stopTTDelay'));
function _startTTDelay()
{
$this->timeoutId = Gtk::timeout_add(1000, array(&$this, '_show_row_tooltip'));} function _stopTTDelay() {
Gtk::timeout_remove($this->timeoutId);} Also, when you get a chance, can you post your code to the wiki? Thanks, Scott