Matthias Clasen
7644a9cd72
entry: Stop using ::key-press-event
...
Use a generic ::event handler instead.
2018-05-21 20:20:06 -04:00
Timm Bäder
5ff4ef14e6
widget: Directly notify gestures of grab
...
Since each widget has a list of event controllers now, we don't need to
connect to ::grab-notify of the widget for every controller.
2018-05-19 10:18:50 +02:00
Carlos Garnacho
15e00759c7
eventcontrollerkey: Port to new API model
2018-04-26 17:59:42 +02:00
Benjamin Otte
4f3058f195
eventcontrollermotion: Port to new API model
2018-04-26 17:59:42 +02:00
Benjamin Otte
1e6eb1f8b9
draggesture: Port to new API model
2018-04-26 17:59:42 +02:00
Benjamin Otte
4ddc94b293
multipressgesture: Port to new API model
2018-04-26 17:59:42 +02:00
Benjamin Otte
73b4a62f51
snapshot: Redo debug messages
...
Instead of every snapshot function having debug messages, have an
explicit gtk_snapshot_push_debug() function that appends a debug node.
2018-04-24 04:06:58 +02:00
Matthias Clasen
5d80086470
entry: Add emoji completion
...
Pop up completions when the text in the entry matches :word:
This functionality has to be enabled using the enable-emoji-completion
property.
2018-04-23 18:54:43 -04:00
Matthias Clasen
e283ed5523
Export some entry functions privately
...
This will be used in the following commits.
2018-04-23 18:54:43 -04:00
Daniel Boles
1d636dc8d4
Entry: Show optional style classes in node diagram
2018-04-22 16:11:09 +01:00
Timm Bäder
3ce6355bf4
widget: Remove _get_own_allocation
...
Replace all usages of it with _compute_bounds
2018-04-10 09:43:47 +02:00
Benjamin Otte
78a9b5d1ed
entry: Stop being activatable
...
Activating entries does not do anything.
Activate the default widget instead.
2018-04-09 20:20:55 +02:00
Carlos Garnacho
362a6ca469
gtkentry: Use key controller to track focus changes
2018-04-05 19:26:55 +02:00
Carlos Garnacho
568054a034
gtkentry: Stop using ::key-press-event
...
Use GtkEventControllerKey for the task
2018-04-05 19:26:53 +02:00
Benjamin Otte
169203951b
widget: Remove clip from size-allocate vfunc
...
As the clip is no longer needed, get rid of it.
2018-04-05 14:56:38 +02:00
Benjamin Otte
c0db4091cf
magnifier: Redo with GtkWidgetPaintable
2018-04-05 14:56:38 +02:00
Timm Bäder
81d19154a3
entry: Remove useless queue_draw call
...
This is already taken care of by the add_class/remove_class.
2018-03-26 20:03:00 +02:00
Benjamin Otte
60719bb67c
textutil: Make gtk_text_util_create_drag_icon() return a paintable
2018-03-26 18:16:36 +02:00
Alexander Larsson
63e060a21d
GtkWidget: Start renaming widget->window
...
This is an automated change doing these command:
git sed -f g gtk_widget_set_has_window gtk_widget_set_has_surface
git sed -f g gtk_widget_get_has_window gtk_widget_get_has_surface
git sed -f g gtk_widget_set_parent_window gtk_widget_set_parent_surface
git sed -f g gtk_widget_get_parent_window gtk_widget_get_parent_surface
git sed -f g gtk_widget_set_window gtk_widget_set_surface
git sed -f g gtk_widget_get_window gtk_widget_get_surface
git sed -f g gtk_widget_register_window gtk_widget_register_surface
git sed -f g gtk_widget_unregister_window gtk_widget_unregister_surface
git checkout NEWS*
2018-03-20 15:21:12 +01:00
Benjamin Otte
12409ee075
cellrendererpixbuf: Store the texture in the iconhelper paintable
...
That's kinda weird but allows us to delete the texture case from
GtkIconHelper and GTK_IMAGE_TEXTURE from the GtkImageType enum.
And it doesn't cause any other problems because the cell renderer
can't deal with paintables - otherwise it would mirror GtkImage and have
a "paintable" property instead.
2018-03-16 06:04:45 +01:00
Benjamin Otte
9e54c22c49
image: Don't handle surfaces anymore
...
Lots of special cases that are no longer needed because no code uses
surfaces.
Also remove the GdkCellRendererPixbuf:surface property.
2018-03-16 06:04:45 +01:00
Benjamin Otte
d1be2b29cf
entry: Make icons a paintable
2018-03-16 06:04:44 +01:00
Benjamin Otte
9fa1e68151
image: Implement support for paintables
...
This includes adding support to GtkImageDefintion and GtkIconHelper.
Only GtkImage handles support for signals from the paintable.
2018-03-16 06:04:44 +01:00
Timm Bäder
de537a0755
entry: Fix invisible cursors
2018-03-06 20:04:30 +01:00
Timm Bäder
8ebec46db5
entry: Remove priv pointer
2018-03-04 19:12:04 +01:00
Benjamin Otte
88de098711
entry: Remove cursor adjustment APIs
2018-03-02 02:00:25 +01:00
Timm Bäder
881046b46e
entry: Simplify cursor management
...
Since cursors are per-widget now and the icons are widgets, we can just
set the cursors once.
2018-02-28 10:35:31 +01:00
Timm Bäder
3c33e541cd
entry: Add motion controller
...
Do the mouse cursor un-obscuring in the ::motion handler instead of in
the ->event handler. We don't get rid of the GtkWidgetClass::event
handler altogether that way, but it's a step in the right direction.
2018-02-27 11:05:04 +01:00
Timm Bäder
9db76cebb4
entry: Check gdk_event_get_coords return value
...
We use the x/y values later on to decide what to do with the event.
2018-02-26 12:57:17 +01:00
Timm Bäder
354eab70da
entry: Allocate icons at full height
...
Makes for a larger hit area for pointing devices. If vertical centering
is still desired, GtkWidget:halign can be set on the icon widgets.
2018-02-26 12:53:49 +01:00
Benjamin Otte
f08bc40fbb
a11y: Don't include gtk.h
...
Also add missing includes and sort them for all the widgets that relied
on that before.
2018-02-08 15:25:53 +01:00
Matthias Clasen
4c150d8eb5
The big versioning cleanup
...
Remove all the old 2.x and 3.x version annotations.
GTK+ 4 is a new start, and from the perspective of a
GTK+ 4 developer all these APIs have been around since
the beginning.
2018-02-06 01:16:32 -05:00
Emmanuele Bassi
c655759cef
Replace gdk_threads_add_timeout* with g_timeout_add()
...
The main GDK thread lock is not portable and deprecated.
The only reason why gdk_threads_add_timeout() and
gdk_threads_add_timeout_full() exist is to allow invoking a callback
with the GDK lock held, in case 3rd party libraries still use the
deprecated gdk_threads_enter()/gdk_threads_leave() API.
Since we're removing the GDK lock, and we're releasing a new major API,
such code cannot exist any more; this means we can use the GLib API for
installing timeout callbacks.
https://bugzilla.gnome.org/show_bug.cgi?id=793124
2018-02-03 12:06:58 +01:00
Timm Bäder
60fdeda599
entry: Remove unused struct members
2018-01-26 17:29:30 +01:00
Matthias Clasen
8c6c2be316
entry: Stop using ::focus-in/out-event
...
We can just use the generic ::event signal.
2018-01-16 14:14:10 -05:00
Timm Bäder
60d3378dd1
entry: Fix text clipping
...
Clipping the text to the entire widget allocation is wrong if there are
icons involved.
2018-01-10 11:02:10 +01:00
Timm Bäder
6235b12ca4
entry: Fix get_text_allocation
...
These should be reported in GtkEntry coordinates, so relative to the
entry's origin. This fixes entrys with top/bottom padding applied.
2018-01-10 10:49:13 +01:00
Timm Bäder
5cd138f0f2
entry: Remove some questionable code examples
2018-01-03 17:11:32 +01:00
Matthias Clasen
1293209d23
Don't place dnd cursor in placeholder text
...
That is just misleading - the entire placeholder text is going
to be replaced by the drop.
2017-12-17 10:52:33 -05:00
Matthias Clasen
e92c0e85ec
Replace gdk_keymap_get_for_display by gdk_display_get_keymap
...
Replace all uses of the old function by the new one.
No functional change.
2017-12-15 07:44:58 -05:00
Carlos Garnacho
d491e49fd6
gtk: s/gdk_event_free/g_object_unref/
2017-12-14 01:05:48 +01:00
Carlos Garnacho
0c8c9f59fc
gtk: Adapt marshallers to GdkEvent as GObject
2017-12-14 01:05:48 +01:00
Benjamin Otte
04ac4c66ae
dnd: Pass device, not event
...
You don't start a dnd operation with a device, you start it with an
event.
2017-12-12 00:31:49 +01:00
Benjamin Otte
756b276070
dnd: Remove button argument from drag_begin()
...
It was unused.
2017-12-12 00:29:51 +01:00
Matthias Clasen
c35cb0eb1b
entry: Allocate the progress bar only what it needs
...
We were allocating the progress bar to the full size
of the entry. This made entry icons loose their cursors,
since they were 'covered' by the progress bar, even though
it doesn't draw anything there.
2017-12-09 23:48:35 -05:00
Benjamin Otte
7a17865b22
dnd: Remove "delete" argument from gtk_drag_finish()
...
The argument is ignored by anything but X11.
It's treated like suggested_action == MOVE.
So do that in gtk_drag_finish(), too.
2017-12-10 01:33:38 +01:00
Benjamin Otte
4658d7ea54
dnd: Remove x/y coordinates from drag-data-received
...
This is in preparation of using input streams to show that these
coordinates aren't needed most of the time and can otherwise be saved
during GtkWidget::drag-drop.
2017-12-05 05:29:00 +01:00
Timm Bäder
93df23d962
Remove some more gtk_widget_get_content_size uses
2017-12-04 12:42:52 +01:00
Benjamin Otte
24c934f8c0
entry: Port to GdkClipboard
2017-12-03 05:46:49 +01:00
Benjamin Otte
a59572f96d
widget: gtk_widget_get_clipboard => gtk_widget_get_old_clipboard
...
Just rename the function, so the previous one can be used for the
new clipboard.
2017-12-03 05:46:47 +01:00