* gtk/gtktooltip.c (gtk_tooltip_trigger_query): Set the root
coordinates in the event correctly. Patch by Kristian Rietveld.
svn path=/trunk/; revision=22277
2008-05-28 Kristian Rietveld <kris@imendio.com>
Bug 504087 - make gtk_tooltip_set_custom a no-op for setting the
current widget again.
* gtk/gtktooltip.c (gtk_tooltip_set_custom),
(gtk_tooltip_reset), (gtk_tooltip_run_requery): use a
custom_was_reset field to check if the custom widget is set again in
the query-tooltip callback; if not, we set it to NULL. Based on a
patch by Xavier Claessens, insightful comments from Jean-Yves Lefort
and Christian Persch.
svn path=/trunk/; revision=20215
2008-02-15 Matthias Clasen <mclasen@redhat.com>
* configure.in: Go back to 2.13.0 as version for now,
as there was no consensus to do the jump.
* many other places: Update Since: tags.
svn path=/trunk/; revision=19586
2007-12-17 Kristian Rietveld <kris@imendio.com>
* gtk/gtktooltip.c (gtk_tooltip_finalize),
(gtk_tooltip_set_last_window): use a weak pointer to set last_window
to NULL as soon as it's destroyed. (#496546, patch from
Benjamin Berg).
svn path=/trunk/; revision=19189
2007-10-08 Kristian Rietveld <kris@imendio.com>
Fix#482841, patch by Karl Tomlinson.
* gtk/gtktooltip.c (gtk_tooltip_display_closed): use g_object_set_data
instead of g_object_set ...
(_gtk_tooltip_toggle_keyboard_mode),
(_gtk_tooltip_handle_event): connect to GdkDisplay::closed after
creating tooltip.
svn path=/trunk/; revision=18890
2007-08-21 Kristian Rietveld <kris@imendio.com>
* gtk/gtktooltip.c (_gtk_tooltip_handle_event): always set
hide_tooltip to TRUE if we are handling a leave notify event. (Fixes
#468245, reported by Dennis Jacobfeuerborn).
svn path=/trunk/; revision=18666
2007-08-21 Kristian Rietveld <kris@imendio.com>
Fix#457642, reported by Christian Persch.
* gtk/gtktooltip.c: added debugging output which can be compiled
in with a #define, annotated all coordinate translations in the
source code,
(find_widget_under_pointer): remove the "no-window correction";
always convert the coordinates from window relative to allocation
relative; after recursing through a container, translate the
coordinates from container allocation relative to child widget
allocation relative;
(find_topmost_widget_from_event): now we get allocation relative
coordinates here we do not have to distinguish no-window and window
widgets.
svn path=/trunk/; revision=18663
2007-07-31 Matthias Clasen <mclasen@redhat.com>
* gtk/gtktooltip.c (gtk_tooltip_init): Make the label
wrap, for compatibility with the old tooltips code. This
fixes absurdly long tooltips in the color selector.
svn path=/trunk/; revision=18558
2007-07-25 Matthias Clasen <mclasen@redhat.com>
* gtk/gtktooltip.c (_gtk_tooltip_handle_event): Call
gtk_tooltip_hide_tooltip() even if the tooltip is not
visible yet. This fixes annoying dangling tooltips
on systray icons.
svn path=/trunk/; revision=18544
2007-07-20 Matthias Clasen <mclasen@redhat.com>
* gtk/gtktooltip.c (gtk_tooltip_position): Don't pop up
under the cursor.
svn path=/trunk/; revision=18512
2007-07-17 Kristian Rietveld <kris@imendio.com>
* gtk/gtktooltip.c (find_widget_under_pointer): only do the
coordinate check if tmp is not NULL.
svn path=/trunk/; revision=18486
2007-07-16 Kristian Rietveld <kris@imendio.com>
* gtk/gtktooltip.c (find_topmost_widget_coords_from_event): check
if the pointer is really over the returned widget, since the
coordinate check may not always be hit in find_widget_under_pointer().
svn path=/trunk/; revision=18478
2007-07-13 Kristian Rietveld <kris@imendio.com>
#408327, improve tooltip positioning.
* gtk/gtk.symbols: updated.
* gtk/gtktooltip.[ch] (gtk_tooltip_position): factor out
positioning code in here,
(gtk_tooltip_set_tip_area): new function to set the tooltip
area,
(gtk_tooltip_reset), (_gtk_tooltip_handle_event): hide tooltip
once the pointer leaves the tip area.
* gtk/gtktreeview.[ch] (gtk_tree_view_set_tooltip_row),
(gtk_tree_view_set_tooltip_cell): convenience functions to set
tip area for row/column/cell.
* tests/testtooltips.c (query_tooltip_tree_view_cb): use
gtk_tree_view_set_tooltip_row.
svn path=/trunk/; revision=18464
2007-07-10 Kristian Rietveld <kris@imendio.com>
* gtk/gtktooltip.c (find_widget_under_pointer),
(child_location_foreach): use gtk_container_forall, instead of
gtk_container_foreach(). Makes tooltips on notebook tabs work. (Fixes
bug reported by Christian Persch).
svn path=/trunk/; revision=18436
2007-07-09 Johan Dahlin <jdahlin@async.com.br>
* gtk/gtktooltip.c:
* gtk/gtktooltip.h: Make the GTK_TOOLTIP and GTK_IS_TOOLTIP macros public.
svn path=/trunk/; revision=18410
2007-06-15 Mathias Hasselmann <mathias.hasselmann@gmx.de>
* docs/reference/gtk/gtk-sections.txt, gtk/gtk.symbols,
gtk/gtkwidget.c, gtk/gtkwidget.h, tests/testtooltips.c: Introduce
convenience property "GtkWidget:tooltip-text" taking care of escaping
it for unwanted markup entities. Add functions to set tooltip text:
gtk_widget_set_tooltip_text(), gtk_widget_set_tooltip_markup(),
gtk_widget_get_tooltip_text(), gtk_widget_get_tooltip_markup().
* gtk/gtktooltip.c, gtk/gtktooltip.h: Add gtk_tooltip_set_text()
to set the tooltip text without using markup.
Patches from Emmanuele Bassi (#447643).
svn path=/trunk/; revision=18142
2007-06-06 Kristian Rietveld <kris@imendio.com>
* gtk/gtktooltip.c (gtk_tooltip_paint_window): remove unused
call to gtk_widget_size_request(). (Reported by Carlos
Garnacho).
svn path=/trunk/; revision=18052
2007-06-06 Kristian Rietveld <kris@imendio.com>
* gtk/gtktooltip.c (gtk_tooltip_show_tooltip): bail out if
last_window is not a GdkWindow anymore. (Fixes#434021, several
reporters).
svn path=/trunk/; revision=18051
2007-05-24 Michael Natterer <mitch@imendio.com>
* gtk/gtktooltip.c (find_widget_under_pointer): apply patch from
Bogdan Nicula which fixes a crash on GdkWindows which have no
GtkWidget as user_data (bug #440890).
svn path=/trunk/; revision=17906
2007-05-23 Kristian Rietveld <kris@imendio.com>
* gtk/gtktooltip.c (find_widget_under_pointer): translate coordinates
from the window they were received on to the event widget's window;
correct for no-window widgets after that, bail out on failure. This
makes the coordinates given by GtkWidget::query-tooltip truly relative
to widget->window. (#435188).
* gtk/gtkwidget.c (gtk_widget_class_init): update docs for
GtkWidget::query-tooltip.
svn path=/trunk/; revision=17896
2007-02-14 Kristian Rietveld <kris@imendio.com>
* gtk/gtktooltip.c (child_location_foreach): check return value
of gtk_widget_translate_coordinates() so we cannot end up
using uninitialized x, y values. (#407863, patch from Carlos
Garnacho).
svn path=/trunk/; revision=17293
2007-02-06 Kristian Rietveld <kris@imendio.com>
* gtk/gtktooltip.c (find_topmost_widget_coords_from_event):
remove unused get of has_tooltip.
* tests/testtooltips.c (query_tooltip_tree_view_cb): use the
portable g_snprintf instead of snprintf.
svn path=/trunk/; revision=17266
2007-02-06 Kristian Rietveld <kris@imendio.com>
New tooltips API.
* gtk/Makefile.am
* gtk/gtk.h
* gtk/gtk.symbols: build system foo.
* gtk/gtkmain.c (gtk_main_do_event): call tooltip event handler
hook for appropriate events.
* gtk/gtkmarshalers.list: add BOOLEAN:INT,INT,BOOLEAN,OBJECT.
* gtk/gtkrc.c: add style for gtk-tooltip.
* gtk/gtksettings.c (gtk_settings_class_init): make the
different tooltip timeouts configurable.
* gtk/gtkwidget.[ch]: add new properties, signals, make sure
tooltips are hidden on unmap, destroy, update window event
mask on realize, hook into focus change and show help
handlers.
* gtk/gtkwindow.h: move GtkWindow typdef to gtkwidget.h ...
* gtk/gtktooltip.[ch]: new files.
* tests/Makefile.am
* tests/testtooltips.c: add test application.
svn path=/trunk/; revision=17264