2007-03-28 Kristian Rietveld <kris@imendio.com>
* gtk/gtkwidget.c (gtk_widget_set_tooltip_window): don't unref
tooltip_window, since this is handled by set_qdata_full() already.
(#412001, Torsten Schoenfeld).
svn path=/trunk/; revision=17566
2007-03-14 Michael Natterer <mitch@imendio.com>
Make gtk_widget_set_extension_events() work on already realized
widgets (bug #379550, Tommi Komulainen)
* gdk/x11/gdkinput.c (gdk_input_set_extension_events): allow to be
called multiple times without leaking and work correctly when
already realized (don't rely on a configure event following).
* gtk/gtkwidget.c (gtk_widget_set_extension_events_internal): new
internal function which walks the GdkWindow tree and sets the
extension events on all windows that belong to the widget.
(gtk_widget_realize)
(gtk_widget_set_extension_events): use the new function.
svn path=/trunk/; revision=17515
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
2007-01-24 Michael Natterer <mitch@imendio.com>
* gtk/gtkwidget.c (gtk_widget_set_state): revert generic disabling
of PRELIGHT state for the reasons given in bug #135666. Widget
states are sometimes abused or otherwise used wrongly for historic
reasons, causing this part of the patch to break e.g. menu items.
svn path=/trunk/; revision=17211
2006-11-16 Michael Natterer <mitch@imendio.com>
Add new infrastructure for notifications of failed keyboard
navigation and navigation with restricted set of keys.
The patch handles configurable beeping, navigating the GUI with
cursor keys only (as in phone environments), and configurable
wrap-around. Fixes bugs #322640, #70986, #318827, #334726, #334742
and #309291.
* gtk/gtksettings.c: added properties gtk-keynav-cursor-only,
gtk-keynav-wrap-around and gtk-error-bell.
* gtk/gtkwidget.[ch]: added new signal "keynav-failed" and public
API to emit it. Added New function gtk_widget_error_bell() which
looks at the gtk-error-bell setting and calls gdk_window_beep()
accordingly.
* gtk/gtk.symbols: add the new widget symbols.
* gtk/gtkcellrendereraccel.c
* gtk/gtkimcontextsimple.c
* gtk/gtkmenu.c
* gtk/gtknotebook.c: use gtk_widget_error_bell() or look at the
gtk-error-bell setting instead of calling gdk_display_beep()
unconditionally.
* gtk/gtkcombobox.c
* gtk/gtkentry.c
* gtk/gtkiconview.c
* gtk/gtklabel.c
* gtk/gtkmenushell.c
* gtk/gtkspinbutton.c
* gtk/gtktextview.c
* gtk/gtktreeview.c: call gtk_widget_error_bell() on failed keynav.
* gtk/gtkentry.c
* gtk/gtklabel.c
* gtk/gtkrange.c
* gtk/gtktextview.c: consult gtk_widget_keynav_failed() on failed
cursor navigation and leave the widget if it returns FALSE.
* gtk/gtkmenushell.c
* gtk/gtknotebook.c: only wrap around if gtk-keynav-wrap-around
is TRUE.
* gtk/gtkradiobutton.c: ask gtk_widget_keynav_failed() to decide
whether to to wrap-around, and don't select active items on cursor
navigation if gtk-keynav-cursor-only is TRUE. Should look at
gtk-keynav-wrap-around too, will look into that.
Wed May 10 15:57:53 2006 Tim Janik <timj@imendio.com>
* applied unified patch for configurable scroll arrow sizes from
bug #333632 and bug #325282.
* gtk/gtkwidget.c (gtk_widget_class_init): added ::scroll-arrow-hlength
and ::scroll-arrow-vlength style properties. fixed upper limit for
::separator-width and ::separator-height to be MAXINT.
* gtk/gtkmenu.c: use GtkWidget::scroll-arrow-vlength to determine the
scroll arrow size, instead of using a hard coded constant.
* gtk/gtknotebook.c: use GtkWidget::scroll-arrow-vlength and
GtkWidget::scroll-arrow-hlength to determine scroll arrow sizes.
added GtkNotebook::arrow-spacing style property to configure the
spacing between scroll arrows.
Tue Apr 25 10:25:28 2006 Søren Sandmann <sandmann@redhat.com>
* tests/testgtk.c (create_alpha_window): Create 'composited' label.
* tests/testgtk.c (on_composited_changed): New function, change
the label to say whether the screen is composited or not.
* gtk/gtkwindow.c (gtk_window_on_composited_changed): When
composited status change, invalidate the window and propagate the signal;.
* gtk/gtkwindow.c (gtk_window_map): Set the appropriate type hint
if reset_type_hint is TRUE.
* gtk/gtkwindow.c (gtk_window_set_type_hint): If hint is one of
the old hints, store a shadow copy in the public window->type_hint
bitfield, otherwise set this field to normal. Set the private
field to the type hint.
* gtk/gtkwindow.c (gtk_window_init): Initialize priv->type_hint.
* gtk/gtkwindow.c (struct _GtkWindowPrivate): New field
"reset_type_hint" indicating whether the type hint needs to be
reset. New field type_hint containing a GdkWindowTypeHint.
* gtk/gtkwidget.c (propagate_composited_changed): New function to
propagate changes in composited status.
(gtk_widget_class_init): Add composited_changed signal.
* gtk/gtkwidget.h (struct _GtkWidgetClass): New signal composited-changed.
* gtk/gtkwidget.c (gtk_widget_is_composited): New function.
* gtk/gtktooltips.c (gtk_tooltips_draw_tips): Set transient for.
* gtk/gtktooltips.c (gtk_tooltips_force_window): Set the type hint
* gtk/gtkmenuitem.c (gtk_menu_item_position_menu): Compute whether
the item belongs to a menubar. Set the type_hint appropriately
depending on the outcome.
* gtk/gtkmenu.c (gtk_menu_position): Set the default type hint here.
* gtk/gtkmenu.c (gtk_menu_attach_to_widget): connect to hierarchy
changed on the attach widget.
* gtk/gtkmenu.c (attach_widget_hierarchy_changed): New function to
set the transient_for property for menus.
* gtk/gtkdnd.c (set_icon_stock_pixbuf): Set the appropriate type hint.
* gtk/gtkcombo.c (gtk_combo_popup_list): Make the popup window
transient for the toplevel.
* gtk/gtkcombobox.c (gtk_combo_box_set_popup_widget): Set
transient-for, for the popup window.
* gdk/x11/gdkwindow-x11.c (gdk_window_get_type_hint): Support for
new window types.
* gdk/x11/gdkwindow-x11.c (gdk_window_set_type_hint): Add support
for new window types.
* gdk/x11/gdkscreen-x11.c (_gdk_x11_screen_process_owner_change):
New function called whenever the compositing manager comes and goes.
* gdk/x11/gdkscreen-x11.c (gdk_screen_is_composited): New function.
* gdk/x11/gdkscreen-x11.c
(_gdk_x11_screen_request_cm_notification, make_cm_atom,
check_is_composited): New functions
* gdk/x11/gdkevents-x11.c (gdk_event_translate): Call
_gdk_x11_screen_process_owner_change when an
XFixesSelectionNotifyEvent is received.
* gdk/x11/gdkdisplay-x11.c (gdk_display_open): Call
_gdk_x11_screen_request_cm_notification() on all screens.
* gdk/quartz/gdkscreen-quartz.c (gdk_screen_is_composited): Dummy
implementation.
* gdk/gdkscreen.c (gdk_screen_class_init): New signal,
'composited-changed'.
* gdk/gdkwindow.h: Add new EWMH window types.
* gdk/win32/gdkscreen-win32.c (gdk_screen_is_composited)
2006-04-05 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkmain.c (gtk_grab_add, gtk_grab_remove, gtk_grab_notify)
(gtk_grab_notify_foreach): Rework the code which emits ::grab-notify
signals to ensure that we emit enough signals. Also optimize the
code to not do unnecessary tree walking.
* gtk/gtkwidget.c (gtk_widget_class_init): Document ::grab-notify.
2006-03-09 Ross Burton <ross@openedhand.com>
* gtk/gtkwidget.c:
* gtk/gtkrange.c:
* gtk/gtktogglebutton.c:
Turn off prelighting when gtk-touchscreen-mode is enabled (#135666)
2006-03-03 Michael Natterer <mitch@imendio.com>
Applied modified patch from maemo-gtk which makes separators more
themeable. Fixes bug #332022.
* gtk/gtkwidget.c: added style properties "wide-separators",
"separator-width" and "separator-height".
* gtk/gtkhseparator.c
* gtk/gtkvseparator.c
* gtk/gtkmenuitem.c
* gtk/gtktoolbar.c: honor the new settings and paint separators
using gtk_paint_box() if wide-separators is true.
2006-02-19 Matthias Clasen <mclasen@redhat.com>
Support input shapes: (#331070)
* gdk/gdk.symbols:
* gdk/gdkdisplay.h:
* gdk/gdkwindow.h:
* gdk/x11/gdkdisplay-x11.c (gdk_display_supports_shapes)
(gdk_display_supports_input_shapes): Functions to determine
if a display supports shaped windows or input shapes.
* gdk/x11/gdkwindow-x11.c (gdk_window_input_shape_combine_region):
(gdk_window_input_shape_combine_mask):
(gdk_window_set_child_input_shapes):
(gdk_window_merge_child_input_shapes): Input shape versions
of the window shape API.
* gtk/gtk.symbols:
* gtk/gtkwidget.h:
* gtk/gtkwidget.c (gtk_widget_input_shape_combine_mask):
New function to set an input shape on a widget.
2006-01-23 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkwidget.c: Add link-color and visited-link-color style
properties. (#113649, Leena Gunda)
* gtk/gtkaboutdialog.c: Use the new style properties here instead
of the about dialogs own link-color property.
2005-09-22 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkwidget.c (gtk_widget_class_init): Fix the documentation
for the grab-broken-event signal, noticed by Damon Chaplin.
2005-09-01 Matthias Clasen <mclasen@redhat.com>
* gdk/*.c: Intern some more strings.
* gtk/gtkintl.h:
* gtk/*.c: Define an I_() macro and use it instead of the
bulky g_intern_static_string().
2005-08-31 Matthias Clasen <mclasen@redhat.com>
* gdk/Makefile.am:
* gtk/Makefile.am: Intern type names in code generated by
glib-mkenums, too.
* gtk/*.c:
* gdk/x11/*.c:
* gdk/*.c: Intern type names before registering the type to avoid
unnecessary copies.
2005-08-26 Matthias Clasen <mclasen@redhat.com>
* gdk/gdk.symbols:
* gdk/gdkscreen.h:
* gdk/gdkscreen.c: Make the GdkScreen font options api
public, and add properties GdkScreen::font-options and
GdkScreen::resolution. (#314004)
* gdk/gdkpango.c:
* gtk/gtksettings.c:
* gtk/gtkwidget.c: Adjust all callers.
* gdk/gdkintl.h: Simplify and use glib/gi18n-lib.h.
* gdk/gdkpango.c: Include gdkintl.h, not gtkintl.h.
* gdk/gdkscreen.c: Include gdkintl.h.
2005-08-23 Owen Taylor <otaylor@redhat.com>
Fix for #314004, reported by Michael Reinsch:
* gdk/gdk.symbols:
* gdk/gdkscreen.[ch]: Add gdk_screen_get/set_font_options_libgtk_only()
Add gdk_screen_get/set_resolution_libgtk_only()
* gdk/gdkpango.c (gdk_pango_context_get_for_screen): Set
the options for the screen on the newly created context.
* gtk/gtksettings.c (settings_update_font_options/dpi) gtkwidget.c:
Move font options and dpi code from gtkwidget.c to gtksettings.c, set
the font options on the screen.
* gtk/gtkwidget.c (gtk_widget_update_pango_context): Just get
the font options from the screen and set them on the context.
2005-07-19 Owen Taylor <otaylor@redhat.com>
* gtk/gtksettings.c gtk/gtkwidget.c: Change machinery for
following font rendering xsettings to set cairo font
options on PangoContext
* gdk/x11/gdkxftdefaults.c gdk/x11/gdkevents-x11.c gdkscreen-x11.h
gdkprivate-x11.h: Get default values for rendering options
(such as antialiasing, dpi) from the Xft resources for the
display, borrowing a bit of code from Xft.
* gtk/gtksettings.c (gtk_settings_class_init): Fix docs for
values of gtk-xft-hintstyle.
2005-07-21 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkwidget.c (gtk_widget_modify_bg, gtk_widget_modify_base):
Add hints on how to handle "no window" widgets. (#136347)
2005-07-18 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkwidget.c (gtk_widget_set_double_buffered): Add a note
about the need to handle expose events. We really need a chapter
on the GTK+ drawing model that we can refer to here... (#310765,
Steve Chaplin)