Christian Hergert
002e48c469
imwayland: fix potential leak of attr list
...
This fixes a potential leak of a PangoAttrList that is set when chaining
up to the parent get_preedit_string(). We check to see if the attr list
was created and reuse it instead of leaking the previous value.
2018-07-28 10:54:14 -07:00
Matthias Clasen
f3f32b47cc
Merge branch 'wip/gtk-menu-popup-no-more' into 'master'
...
Remove legacy GtkMenu popup APIs
See merge request GNOME/gtk!270
2018-07-27 18:57:24 +00:00
Matthias Clasen
16171a232a
Add a color picker implementation for gnome-shell
...
This adds a GtkColorPicker implementation that talks
to gnome-shell to get a color.
2018-07-27 14:23:20 -04:00
Matthias Clasen
031b5cad46
Add a color picker implementation for portals
...
This adds a GtkColorPicker implementation that talks
to the screnshot portal to get a color.
2018-07-27 14:23:20 -04:00
Matthias Clasen
984274497d
color editor: Add a color picker button
...
The button is shown if we have a GtkColorPicker implemenation.
Currently, there are none, so the button is never shown.
2018-07-27 14:23:20 -04:00
Matthias Clasen
0cc0714312
Add a color picker interface
...
This will be used in the color chooser, in subsequent commits.
2018-07-27 14:23:19 -04:00
Matthias Clasen
c8be597b7f
Bring back gtk-orientation icons
...
These are used in the page setup dialog, so we can't
just drop them.
2018-07-27 13:35:29 -04:00
Jonas Ådahl
4497ac7d75
menu: Remove legacy popup APIs
...
Remove gtk_menu_popup_for_device() and gtk_menu_popup(), as they cannot
be implemented in a portable manner by all backends. They have been
deprecated for proper alternative APIs for some time, so lets remove
them now before its too late.
While at it, fix the example documentation for mapping a menu.
2018-07-27 17:16:44 +02:00
Matthias Clasen
d398c00d20
Fix up the resource generation for icons
...
The script was looking in the wrong subdirectories.
2018-07-27 09:08:27 -04:00
Matthias Clasen
cb247276f5
Add emoji category icons
...
This is a temporary measure to make the check-icon-names
test not fail in ci. We still have to figure out the best
way to include a core icontheme with GTK+.
2018-07-27 08:05:55 -04:00
Matthias Clasen
c6141dffd2
Keep picking up icons as resources
...
We may need to revisit this at some point. For now,
keep the mechanism in place.
This is a partial revert of 806c659efe
.
2018-07-27 08:05:55 -04:00
Alcaro
a1a6e6a36a
doc: Fix there/their typo
2018-07-27 02:28:45 +00:00
Ernestas Kulik
6adaf7c33d
Remove GDestroyNotify casts in g_clear_pointer() uses
...
GLib master propagates argument types in g_clear_pointer(), which causes
the usual function pointer casts to GDestroyNotify to trip compiler
warnings. Additionally, this commit changes some cleanup functions where
appropriate (wl_data_source_destroy ->
gtk_primary_selection_source_destroy for struct
gtk_primary_selection_source).
2018-07-25 10:05:39 +03:00
Benjamin Otte
95a4eff6ba
render: Make gtk_render_icon() use the snapshot API
...
This removes a lot of duplicated code.
2018-07-24 20:55:45 +02:00
Benjamin Otte
9675c99043
render: Make gtk_render_frame() and gtk_render_focus() use the snapshot API
...
This removes a lot of duplicated code.
2018-07-24 20:55:45 +02:00
Benjamin Otte
76d0e1e398
API: Remove gtk_render_frame_gap()
...
That function does not make sense at all in a CSS world. So better don't
support it anymore.
2018-07-24 20:55:45 +02:00
Benjamin Otte
14408b7485
render: Make gtk_render_background() use the snapshot API
...
This removes a lot of duplicated code.
2018-07-24 20:55:45 +02:00
Benjamin Otte
2a11baf6ea
render: Make gtk_render_check/arrow/handle() use the snapshot API
...
This removes a lot of duplicated code.
2018-07-24 20:55:45 +02:00
Benjamin Otte
51d40ca023
render: Make gtk_render_layout() use the snapshot API
...
This removes a lot of duplicated code.
2018-07-24 20:55:45 +02:00
Benjamin Otte
5f7e093168
gtk: Move GtkGesture declaration to gtktypes.h
...
That way, headers can use the gesture type without having to include
gtkgesture.h
2018-07-24 20:55:45 +02:00
Ernestas Kulik
d88268c142
gtkpopovermenu: Conditionally chain up in gtk_popover_menu_add()
...
Otherwise the stack gets parented to the wrong widget and the contents
are never drawn.
2018-07-23 13:01:01 +03:00
Ernestas Kulik
49ae68c2c7
gtkpopovermenu: Drop call to gtk_widget_show()
...
The stack is already visible.
2018-07-23 13:00:11 +03:00
Benjamin Otte
447b166ed3
Merge branch 'wip/muktupavels/remove-gtk-css-provider-get-default' into 'master'
...
gtkcssprovider: remove gtk_css_provider_get_default
See merge request GNOME/gtk!256
2018-07-20 14:03:51 +00:00
Matthias Clasen
806c659efe
Drop unused old icons
...
We don't need to ship the deprecated old stock-id named
icons and the drag cursors - we don't use them from resources
anyway.
2018-07-20 08:06:07 -04:00
Matthias Clasen
827219e214
Emoji chooser: Also check for hex boxes
...
We don't want to see those either.
2018-07-19 17:57:19 -04:00
Matthias Clasen
5c9b25c66e
moji chooser: Try harder to avoid fallback
...
We don't want to see any fallback rendering.
The current check was still letting some fallback
combinations through.
Based on work by Julian Sparber.
2018-07-19 17:50:54 -04:00
Matthias Clasen
37e4ae2fbd
Quiet a compiler warning
...
We don't need to handle GDK_CONFIGURE here, so make the
compiler not warn about it.
2018-07-19 17:48:06 -04:00
Matthias Clasen
849ffebc21
Emoji chooser: Use icons for sections
...
This is more reliable than using text-style Emoji
which may not be present.
Based on work by Julian Sparber.
2018-07-19 17:47:50 -04:00
Alberts Muktupāvels
7a8f5ca970
gtkcssprovider: remove gtk_css_provider_get_default
...
This function is unused since cdc6e82720
commit and does not
contain fallback style.
https://gitlab.gnome.org/GNOME/gtk/issues/1226
2018-07-19 19:25:17 +03:00
Ernestas Kulik
4b2d63167e
placessidebar: Take a GdkDrag in _set_drop_targets_visible()
...
Since the function is usually called from GtkWidget::drag-{begin,end} handlers,
taking a GdkDrop does not work, especially given that
::drag-action-requested is emitted without checking the type.
Fixes https://gitlab.gnome.org/GNOME/gtk/issues/1220
2018-07-17 19:19:14 +03:00
Timm Bäder
6fe0a8c6b3
gesturestylus: Clarify a documentation comment
...
Use the proper gtkdoc syntax for signals.
2018-07-17 17:33:47 +02:00
Timm Bäder
04eb7eef29
Remove icon extents API
2018-07-17 17:33:47 +02:00
Timm Bäder
480a2c2770
widget: Remove another ->priv usage
2018-07-17 17:33:47 +02:00
Timm Bäder
f699fff6e0
sizerequest: Pull locals into closest scope
2018-07-17 17:33:47 +02:00
Timm Bäder
4bc145549d
Correctly mark an enum value in a doc comment
2018-07-17 17:33:47 +02:00
Timm Bäder
cf7fa931d3
sizerequest: Only check reported baselines if requested
...
If the passed-in store locations for the baselines are NULL anyway, we
don't need to check the reported baselines for correctness.
2018-07-17 17:33:47 +02:00
Timm Bäder
3f126c7fc8
Remove GTK_CSS_AFFECTS_CLIP
...
Clips don't exist anymore and this flag is unused outside of the style
property definitions in gtkcssstylepropertyimpl.c
2018-07-17 17:33:47 +02:00
Timm Bäder
960717b273
window: Don't queue an allocate if the css clip changes
...
clips don't exist anymore.
2018-07-17 17:33:47 +02:00
Matthias Clasen
bf5f27c6d5
Handle configure events in gdk
...
The previous attempt at removing configure events entirely
was causing some dialogs not to show up under Wayland.
Presumably due to ordering issues with emitting ::size-change
out of the backend.
Instead, keep configure events in the event queue, but handle
them on the gdk side. This keeps the ordering intact, while
still removing configure events from the api. The dialogs
show up now.
2018-07-15 20:23:45 -04:00
Matthias Clasen
7a1073c3ae
Revert "gdk: Drop configure events"
...
This reverts commit a8926c9d87
.
2018-07-15 20:23:45 -04:00
Matthias Clasen
d148f26658
Drop gdk_surface_withdraw
...
'withdrawn' is an X11-centric concept, and the function
can just as well be replaced by gdk_surface_hide.
2018-07-15 15:29:58 -04:00
Matthias Clasen
7ca6440f4d
gdk: Drop map events
...
We are really inconsistent about generating these,
and they are not actually used in GTK+. Instead,
add a boolean GdkSurface::mapped property.
2018-07-15 15:10:56 -04:00
Matthias Clasen
da3aaf39b9
gdk: Drop expose events
...
Replace expose events with a GdkSurface::expose signal.
This is part of the move to use events only for input.
2018-07-15 13:13:07 -04:00
Matthias Clasen
a8926c9d87
gdk: Drop configure events
...
Replace configure events with a GdkSurface::size-changed signal.
This is part of the move to use events only for input.
2018-07-15 11:51:09 -04:00
Matthias Clasen
443f8ddf6b
popover: Drop some dead code
...
This will be done differently, using xdg-popup instead
of subsurfaces, so no point in keeping this.
2018-07-15 08:18:08 -04:00
Matthias Clasen
6a7de806dd
text display: correct a comment
2018-07-14 13:50:14 -04:00
Benjamin Otte
cbb1e74bb5
textview: Only create cairo context in gtktextdisplay.c
...
Everything else is done using GtkSnapshot now, including renaming the
draw_layer vfunc to snapshot_layer.
2018-07-14 05:27:54 +02:00
Benjamin Otte
4456b06853
window: Update opaque region if background-color changes
...
The opaque region is only set when the background color is opaque. So
we need to do something about it when the background color changes.
However, in the case where a size allocation is going to happen, we
already do this update in size_allocate(), so in that case avoid doing
it twice.
2018-07-13 14:56:04 +02:00
Benjamin Otte
88af7b44aa
textview: Use snapshot on the sidebars
2018-07-13 14:56:04 +02:00
Benjamin Otte
a7cd1918a8
widgetpaintable: Add a hack to make recursion not infloop
...
Makes the GUADEC talk not crash that I'm supposed to give in 20 minutes.
2018-07-13 14:56:04 +02:00