Commit Graph

2805 Commits

Author SHA1 Message Date
Benjamin Otte
723bf44887 calendar: Fix for GTK4 changes 2017-11-10 14:56:42 +01:00
Benjamin Otte
f4e1a2b849 testgtk: Draw the right area in alpha window test
Even broken stuff is easier now.
2017-11-10 14:56:42 +01:00
Benjamin Otte
2ff5038b09 testgtk: Fix some more old drawing area uses 2017-11-10 14:56:42 +01:00
Benjamin Otte
2620323fac tests: After 20 years, update the simple test to modern GTK
It's 3 lines shorter!
And it works again!
2017-11-10 14:56:42 +01:00
Benjamin Otte
93c42bcbe0 testgtk: Fix rotated text demo
Use proper DrawingArea APIs here.
2017-11-10 14:56:42 +01:00
Benjamin Otte
22472c1924 entry: Remove surface icons
We have texture icons.
2017-11-05 06:45:01 +01:00
Benjamin Otte
a409320cda gtk: Use gtk_widget_set_cursor()
... and gtk_widget_set_cursor_from_name() instead of setting cursors on
GdkWindows.
2017-11-04 01:37:03 +01:00
Benjamin Otte
9323d098a6 gdk: Cursors no longer have a display
Change constructors to reflect that.

While doing so, also add a fallback argument to the cursor constructors,
so it is now possible to create cursors with fallback.
2017-11-04 00:07:13 +01:00
Benjamin Otte
ca3c23662c GskTexture => GdkTexture
We want this thing to replace GdkPixbuf, so it has to live in GDK.
2017-11-04 00:07:13 +01:00
Timm Bäder
8fa20f87e4 testwidgetfocus: Make focused button more obvious 2017-11-02 11:25:41 +01:00
Matthias Clasen
47fb329279 tests: Stop using gdk_cursor_new_for_display
The name-based api is the one we prefer.
2017-11-01 21:22:21 -04:00
Matthias Clasen
1641ef4799 tests: Stop using gdk_pango_get_context_for_display
This api is going away.
2017-10-31 18:14:08 -04:00
Benjamin Otte
e78402ec94 tests: Remove completely outdated test
The test was fiddling with screens and trying crazy stuff. We don't do
things like that anymore.
2017-10-31 19:03:55 +01:00
Benjamin Otte
07164e098a window: Turn gtk_window_set_screen() into gtk_window_set_display()
And have a priv->display instead of a priv->screen.

Includes turning gtk_menu_set_screen() into gtk_menu_set_display(),
because that function just forwards to its window.
2017-10-31 08:25:37 +01:00
Benjamin Otte
ecd5b399a4 icontheme: Use GdkDisplay instead of GdkScreen 2017-10-31 03:05:55 +01:00
Benjamin Otte
9151e0b9f5 stylecontext: Port to use display instead of screen 2017-10-31 03:05:54 +01:00
Benjamin Otte
a2e625692e gtk-demo: Remove calls to gtk_style_context_reset_widgets()
Those calls have been unneeded for a long time - since we gained the
changed signal on the StyleProvider in fact.
2017-10-31 03:05:54 +01:00
Matthias Clasen
ffb3bc438e tests: Stop using gdk_pango_context_get.
We can just as well get the display ourselves.
2017-10-30 21:35:48 -04:00
Alexander Larsson
96b04836d8 Drop all uses of GdkPixbufAnimation in the gtk APIs
These are basically animated gifs, and don't fit well in how
modern things animate.
2017-10-23 16:56:49 +02:00
Alexander Larsson
2b194089dd GtkImage: Drop support for storing pixbufs
This drops the pixbuf property and the pixbuf getters. We keep
gtk_image_new/set_from_pixbuf, but these are small helpers that
immediately convert to a surface, and there is no way to later get
back the pixbuf you passed in.

The from file/resource codepaths are also changed to load a surface
instead of a pixbuf.
2017-10-23 15:28:33 +02:00
Alexander Larsson
d3fc937b4d GtkWindow/GdkWindow: Finish converting icons to surfaces
There were some parts left, for instance gdk_window_set_icon_list.
2017-10-23 13:45:25 +02:00
Alexander Larsson
6f8644ad25 GtkEntry: Use surfaces, not pixbufs for bitmapped icons 2017-10-23 13:45:25 +02:00
Matthias Clasen
b72cda47fa Use surface apis in testnotebookdnd
Stop using gtk_drag_set_icon_pixbuf.
This api is going away.
2017-10-23 05:58:54 +02:00
Matthias Clasen
89ad359628 tests: Use surface apis in testimage
Stop using gtk_drag_set_icon_pixbuf.
This api is going away.
2017-10-23 05:58:54 +02:00
Matthias Clasen
a783470491 tests: Convert dnd test to surface apis
Stop using gtk_drag_set_icon_pixbuf in testdnd2.
This api is going away.
2017-10-23 05:58:54 +02:00
Matthias Clasen
243bd4f0c8 gsk: Tweak cairo node apis
Rename the surface getter to peek, following other render
node getters, and make the surface-based constructor private,
since it is not something we want to encourage.

Update all callers.
2017-10-20 13:54:01 +02:00
Timm Bäder
ac7e1081b5 tests: Add testgridbaseline
Which shows that GtkGrid currently computes baselines for all rows even
though not all of them might request a baseline.
2017-10-11 08:50:18 +02:00
Umang Jain
74a677a79d Create tests for cairo node
https://bugzilla.gnome.org/show_bug.cgi?id=788534
2017-10-08 18:22:34 +05:30
Daniel Boles
6cafb62e9b testmenubutton: Fix inverted keynav in the GtkMenu
GtkMenu’s own keynav code, which actually bothers to account for the
layout of items, only happens if columns > 1. So, adding items to 1
column using a reverse loop meant they were placed in the Menu’s list of
children in that order, and because we only have 1 column, Menu passes
keynav up to MenuShell, which doesn’t adjust for the items’ positions.

‘Fix’ that here by adding items in the same order they’ll have when laid
out in the Menu, so keynav does what you’d expect, not the opposite. For
that, it’s simpler just to use gtk_container_add().

Let’s presume users are using add(), attach() with a non-inverted loop,
or attach() with arguments that create 2+ columns and so GtkMenu keynav.
2017-10-08 13:17:04 +01:00
Daniel Boles
06941c593d testcombo: Test grid :row- and :column-span-column
Ditch two items that were white and so weren’t visible on our standard
theme anyway, and use the new space to test extra grid-mode properties.

Note that if we do this then, as before, we set the ListStore on the
ComboBox before appending to it, that produced runtime warnings like:

Gtk-CRITICAL **: gtk_menu_attach: assertion 'left_attach < right_attach' failed

I didn’t look into that yet, but it may indicate that attaching items
vs. recognising their spans don’t occur in the correct order. For the
purposes of testing this, I just create the CB after filling its model.
2017-10-04 11:17:57 +01:00
Matthias Clasen
47464ce4da Create tests for gsk box shadows 2017-10-01 22:55:32 -04:00
Matthias Clasen
a4d984fb18 Create tests for GskTextNode 2017-10-01 22:09:43 -04:00
Matthias Clasen
e1ea408161 tests: Use GdkEvent API 2017-09-19 18:39:03 +02:00
Carlos Garnacho
8a26fd3308 tests: Update testoverlay "Chase" testcase to gtk4 crossing events
The intent is detecting enter events into the overlayed label, so just
connect to ::enter-notify-event on the label with no GdkWindow checks.
2017-09-15 21:11:22 +02:00
Matthias Clasen
93c67eaf6d Add a test for overlay blur 2017-09-04 14:28:16 -04:00
Timm Bäder
98281bc60a testcenterbox: Properly quit on window close 2017-09-03 09:17:35 +02:00
Daniel Boles
1e832b2e16 testpopover: Use HeaderBar to get CSD decorations
This helps test whether the Popover positioning gets messed up by the
presence of CSD shadow or other accessories around the content area.

https://bugzilla.gnome.org/show_bug.cgi?id=786209
2017-08-24 21:32:05 +01:00
Timm Bäder
86c294b952 testgtk: Remove some invalid css 2017-08-23 11:05:37 +02:00
Daniel Boles
fb66f539ae testpopover: Sync initial vals of controls & props
The ComboBoxes were initially empty, rather than reflecting the initial
values of the properties. The CheckButtons were only correct by chance.
Fix this by setting the initial values on the widgets and binding them
to the properties using SYNC_CREATE, so the two are always synced up.

https://bugzilla.gnome.org/show_bug.cgi?id=786209
2017-08-14 23:15:11 +01:00
Emmanuele Bassi
6240082e12 Drop old MSC makefiles 2017-08-14 22:23:09 +01:00
Emmanuele Bassi
391d1a04ec Drop Autotools build
We are officially switching to Meson as the default build system for
GTK+.
2017-08-14 22:23:09 +01:00
Matthias Clasen
e24ffbbc21 Add a testcase for the new Emoji chooser
For now, add it in testentryicons.
2017-08-12 18:48:14 -04:00
Matthias Clasen
535e604b91 Drop the shape window example in testgtk
Not sure this can be rescued without root window coordinates.
It is also somewhat inherently X11-specific.
2017-08-11 15:46:00 -04:00
Benjamin Otte
29b0954c45 testgtk: Actually expand the scrolled window 2017-08-02 00:23:43 +01:00
Benjamin Otte
7297aeb54c testgtk: Get rid of GtkEventBox 2017-08-02 00:23:30 +01:00
Benjamin Otte
69da7836f9 tests: Get rid of GtkEventBox 2017-08-02 00:15:10 +01:00
Daniel Boles
e74be1728e testentryicons: Set tooltips on all icons
Just to test tooltips in all cases; what was already here
should have been sufficient, but this doesn't hurt.

While here, also add some instructive placeholder text.

https://bugzilla.gnome.org/show_bug.cgi?id=780938
2017-07-31 20:01:30 +01:00
Timm Bäder
b71f644cf5 eventbox: Remove visible-window property
The GdkWindow that was supposed to back it is gone.
2017-07-27 21:53:42 +02:00
Timm Bäder
b838cc0d65 testflowbox: hexpand the flowbox 2017-07-22 06:52:46 +02:00
Chun-wei Fan
171ff43340 tests: Include system headers appropriately
Don't include unistd.h on Windows, and include the appropriate headers on
Windows as necessary.

https://bugzilla.gnome.org/show_bug.cgi?id=773299
2017-07-21 23:36:03 +08:00