1. 19 Jan, 2016 3 commits
    • Benjamin Otte's avatar
      widget: Call gdk_window_mark_paint_from_clip() again · a50baba1
      Benjamin Otte authored
      The proper window to call it is the event window, as the call itself
      ignores non-native windows anyway.
      a50baba1
    • Benjamin Otte's avatar
      widget: Add forgotten push_group code · ab5dbfd1
      Benjamin Otte authored
      ... and remove the also forgotten void function that lingered around
      with it.
      
      Fixes opacity=0 parts like inactive spinners or sort indicators in
      treeview headers being drawn since last commit.
      
      Oops.
      ab5dbfd1
    • Benjamin Otte's avatar
      widget: Redo drawing code · 580ea227
      Benjamin Otte authored
      Previously, we had a special cae to draw subwindows of widgets.
      
      This is not necessary as conformant widgets should be able to properly
      render themselves when all windows need to be painted.
      From now on assume that is the case.
      
      We therefore paint nonnative GDK windows "inline" by just returning TRUE
      for gtk_cairo_should_draw_window() for those windows.
      
      This speeds up hilighting different rows in the listbox gtk-demo example
      tremendously (by a factor of 10 or more) as the previous code was
      O(<number of non-window subwidgets> *
      <number of subwindows>) which in the listbox example were ~15,000 and
      ~2,000 respectively.
      580ea227
  2. 18 Jan, 2016 1 commit
  3. 15 Jan, 2016 1 commit
  4. 11 Jan, 2016 1 commit
    • Carlos Garnacho's avatar
      GtkWidget: Fix motion event consumption detection for touch-only gestures · 0167f7c6
      Carlos Garnacho authored
      If a GtkGestureSingle is set as touch-only, pointer events would be
      discarded without giving an opportunity to the regular GtkGesture
      handler to manage those.
      
      Because the pointer events weren't actually managed by the gesture,
      gtk_gesture_get_sequence_state() (rather unhelpfully here) will resort
      to returning GTK_EVENT_SEQUENCE_NONE, which is in turn interpreted
      by _gtk_widget_consumes_motion() as "may be handling the events for
      this sequence", because gestures in this state presumably handle
      the events, just that it's not "claimed" yet.
      
      Instead, use gtk_gesture_handles_sequence(), which will perform the
      expected check on the event sequence being managed, as we expect
      here.
      0167f7c6
  5. 08 Jan, 2016 2 commits
    • Matthias Clasen's avatar
      Deprecate cursor-color style properties · 9f247e11
      Matthias Clasen authored
      These have been replaced by CSS properties.
      9f247e11
    • Alberto Ruiz's avatar
      introspection: This patch fixes nullable return values fixes for the following symbols in gtk · 496f0892
      Alberto Ruiz authored
        gtk_accel_group_query
        gtk_accel_group_from_accel_closure
        gtk_accel_label_get_accel_widget
        gtk_accessible_get_widget
        gtk_actionable_get_action_name
        gtk_app_chooser_get_app_info
        gtk_app_chooser_button_get_heading
        gtk_app_chooser_dialog_get_heading
        gtk_application_get_window_by_id
        gtk_assistant_get_nth_page
        gtk_binding_set_find
        gtk_builder_get_object
        gtk_builder_lookup_callback_symbol
        gtk_builder_get_application
        gtk_button_get_image
        gtk_cell_area_get_focus_from_sibling
        gtk_cell_renderer_start_editing
        gtk_cell_view_get_model
        gtk_cell_view_get_displayed_row
        gtk_clipboard_get_owner
        gtk_container_get_focus_child
        gtk_container_get_focus_vadjustment
        gtk_container_get_focus_hadjustment
        gtk_dialog_get_widget_for_response
        gtk_drag_get_source_widget
        gtk_drag_dest_get_target_list
        gtk_drag_source_get_target_list
        gtk_entry_completion_get_model
        gtk_entry_completion_compute...
      496f0892
  6. 05 Jan, 2016 1 commit
  7. 04 Jan, 2016 1 commit
  8. 03 Jan, 2016 1 commit
  9. 29 Dec, 2015 1 commit
    • Matthias Clasen's avatar
      Set ID on css node right away · 31e97b33
      Matthias Clasen authored
      Previously, the ID was only set on the CSS node as a side-effect
      of calling gtk_widget_get_style_context. This was showing up
      in CSS style tests as nodes lacking their IDs.
      31e97b33
  10. 23 Dec, 2015 1 commit
  11. 18 Dec, 2015 2 commits
  12. 16 Dec, 2015 3 commits
  13. 15 Dec, 2015 3 commits
  14. 13 Dec, 2015 1 commit
  15. 02 Dec, 2015 1 commit
  16. 01 Dec, 2015 1 commit
  17. 24 Nov, 2015 1 commit
  18. 22 Nov, 2015 1 commit
  19. 05 Nov, 2015 1 commit
  20. 03 Nov, 2015 3 commits
    • Benjamin Otte's avatar
      widget: Queue resize on parent, not self · d65ba7cf
      Benjamin Otte authored
      When setting the parent of a widget, queue_resize() on the widget will
      be optimized away if the widget already had a resize queued.
      
      Plus, we do not need to resize the widget as its size request is not
      going to change.
      d65ba7cf
    • Benjamin Otte's avatar
      widget: Queue an allocate on hide · 1f01b8d5
      Benjamin Otte authored
      This makes sure that hidden widgets always have priv->alloc_needed set
      on them.
      
      The constructor sets that flag, so we want to have it back when we
      revert to this state.
      
      This fixes GtkWindow skipping a size_allocate() when reshowing a
      previously hidden window and thereby not updating its allocation and
      clip. And that in turn would lead to draws not happening and us beig
      left with a black window.
      1f01b8d5
    • Florian Müllner's avatar
      widget: Add :focus-on-click property · ebdf5f58
      Florian Müllner authored
      There are currently three widget that implement such a property, and
      there are other widgets for which the behavior can make sense. It
      seems like a good time to add the property to GtkWidget itself so
      subclasses can choose to respect it without adding their own property.
      
      https://bugzilla.gnome.org/show_bug.cgi?id=757269
      ebdf5f58
  21. 30 Oct, 2015 1 commit
    • Benjamin Otte's avatar
      widget: Queue redraw on gtk_widget_queue_allocate() · e39b8611
      Benjamin Otte authored
      Mirror the behavior of gtk_widget_queue_resize() and always queue a
      redraw. If we ever want to cause allocates without redraws we can add
      gtk_widget_queue_allocate_no_redraw() then.
      
      I had initially assumed gtk_widget_size_allocate() would take care of
      queueing redraws, but it does not do that when neither size nor position
      change. And that is obviously what's happening after
      gtk_widget_queue_allocate().
      
      Fixes buttons sometimes not redrawing (the record button in
      widget-factory after locking it, all buttons when switching to the dark
      theme).
      e39b8611
  22. 29 Oct, 2015 1 commit
    • Benjamin Otte's avatar
      widget: Queue resize on parent on show/hide · 44836360
      Benjamin Otte authored
      When gtk_widget_show() or gtk_widget_hide() is called, don't queue a
      resize on the widget itself but on the parent.
      
      The widget itself may already be marked as in need of a resize and
      the call would be optimized out and never reach the parent.
      The parent size will change though because a child widget just changed
      its visibility.
      
      Fixes a bunch of issues with menus appearing black, toolbas not hiding
      in widget-factory and also various reftests.
      44836360
  23. 28 Oct, 2015 8 commits