Re: Proposal for new tooltips API
- From: Matthias Clasen <matthias clasen gmail com>
- To: Kristian Rietveld <kris gtk org>
- Cc: gtk-devel-list gnome org
- Subject: Re: Proposal for new tooltips API
- Date: Wed, 25 Jan 2006 15:29:27 -0500
On 1/25/06, Kristian Rietveld <kris gtk org> wrote:
Thanks for picking up this ball, kris.
>
> void gtk_tooltips_window_set_text (GtkTooltipsWindow *window,
> GtkTooltipsContext context,
> GObject *owner,
> const char *text);
> void gtk_tooltips_window_set_markup (GtkTooltipsWindow *window,
> GtkTooltipsContext context,
> GObject *owner,
> const char *markup);
>
> The widget can use these functions to update the contents on the tooltip.
> For example when the mouse pointer changes position. These functions would
> only be used for the complex tooltips case (b).
One extension to keep in mind that was mentioned in the thread you cite is
allowing widget content in tooltips. While interaction with tooltips
is seriously
limited, I can see this being useful at least for embedding images or
animations. An implementation idea mentioned back then was to have
a populate-tooltip signal that would be emitted on the tooltipswindow object
before showing it.
> void gtk_tooltips_window_set_area (GtkTooltipsWindow *window,
> GtkTooltipsContext context,
> GObject *owner,
> GdkWindow *relative_to,
> int x,
> int y,
> int width,
> int height);
>
> The window, x, y, width, height arguments indicate the area of the object to
> which the tooltip refers. The tooltip would be placed completely
> clear of this area. (As it is placed to avoid widgets today).
I think an example would make it much clearer how this is supposed to be
used. So, complex widgets are supposed to call begin/end when the pointer
enters/leaves, and then keep track of the pointer position and call
set_area() as appropriate ?
Matthias
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]