Commit Graph

1277 Commits

Author SHA1 Message Date
Emmanuele Bassi
c9d8ff21d2 testsuite/css: Change the active RadioButton
The `buttons` test for CSS nodes sets the second RadioButton as the
active one, whereas the first RadioButton is not set as active.
Nevertheless, the reference output says that the first radio button
should match the `:checked` selector, whereas the second radio button
should not.

The fact that the test currently passes is a mystery.
2019-04-05 01:42:37 +01:00
Emmanuele Bassi
824743a395 testsuite/css: Update UI files
Run the UI files through `gtk-builder-tool simplify --3to4` to update
the layout properties.
2019-04-05 01:01:40 +01:00
Emmanuele Bassi
5d778175ee testsuite/reftests: Update UI files
Run the UI files through `gtk-builder-tool simplify --3to4` to update
the layout properties.
2019-04-05 00:33:12 +01:00
Emmanuele Bassi
358ad227d5 testsuite/a11y: Update GtkGrid definitions in UI files 2019-04-05 00:24:49 +01:00
Emmanuele Bassi
b79220ca19 tests: Update the GtkGrid suite
We don't use child properties any more.
2019-04-04 22:43:07 +01:00
Emmanuele Bassi
447dfc029f Remove GtkLayout
The need of a specialised fixed layout container that can be placed into
a GtkScrolledWindow ceased to exist once GtkScrolledWindow gained the
ability to automatically interpose a GtkViewport when adding a child
that does not implement GtkScrollable.

All the other justifications that led to the existence of GtkLayout as a
separate widget from GtkFixed have been largely made irrelevant in the
20 years since its inception.
2019-04-02 15:29:20 +01:00
Chun-wei Fan
68af572ba4 test/reftests: Fix build on Visual Studio
As we are building the gtkreftestprivate and reftest test libraries as
DLLs, we need to export the symbols in there so that things will link.

Decorate the symbols with G_MODULE_EXPORT for this purpose.
2019-04-01 12:14:45 +08:00
Timm Bäder
fb4ffa468c build: Don't use 'continue'
It does not exist in meson 0.48 apparently.
2019-03-31 06:37:10 +02:00
Emmanuele Bassi
ba3a502079 build: Do not use install argument for configure_file()
The `install` argument for configure_file() was introduced in Meson
0.50, and was ignored in earlier versions.

Since we're still using Meson 0.48 as a baseline, and since it doesn't
cost us nothing to use a conditional in the only place where we used the
`install` argument, let's drop it. This avoids a warning in newer
releases of Meson.
2019-03-29 14:30:57 +00:00
Benjamin Otte
a8dccef507 build: The private reftest library needs to be shared
Otherwise the module and gtk-reftest will each have their own copy and
that'll mean all symbols - and inhibiting the shutdown - will exist
twice. Not good.
2019-03-29 09:56:52 +01:00
Benjamin Otte
90f460c236 reftests: Remove notebook-childproperties test
Notebooks have no child properties anymore.
2019-03-29 09:56:52 +01:00
Benjamin Otte
e5e516468a reftests: Fix textview-tags test
The test was timeouting on X11.

I'm still not sure it does what it should do, but at least that
problem's gone.
2019-03-29 09:56:52 +01:00
Benjamin Otte
b88c9439aa reftests: Fix label-sizing test
Set border, padding and margin to 0, not just padding.
2019-03-29 09:56:52 +01:00
Benjamin Otte
95f9c8a5eb reftests: Remove box-packing test
Boxes have no packing flags anymore.
2019-03-29 09:56:52 +01:00
Benjamin Otte
fbc8bb979d reftests: Fix grid-empty-with-spacing test
Widgets are visible by default now, so make sure the ones that should be
invisible are marked as such.
2019-03-29 09:56:52 +01:00
Benjamin Otte
e861b0d6c1 reftests: Fix grid-spacing2 test
The expand flag needs to be set on widgets when previously it was a
packing property.
2019-03-29 09:56:52 +01:00
Benjamin Otte
7918eaf677 picture: Don't cause warnings on load failures
When a file set via gtk_picture_set_file() can't be loaded, just
silently don't load it.

Reftest picture-load-invalid-file added for that case.
2019-03-29 09:56:52 +01:00
Benjamin Otte
bf2a93ca0e reftests: Fix image-load-from-file test
- Images are always correctly sized
- Use a GtkPicture for the large file
2019-03-29 09:56:52 +01:00
Benjamin Otte
606aea2302 reftests: Fix iconview-empty test
Images have a static size now, use a GtkPicture instead.
2019-03-29 09:56:52 +01:00
Benjamin Otte
fee8f6b9be reftests: Fix shorthand-entry-border test
We weren't setting CSS back to defaults, so the border highlight
transition would be at different stages when the 2 snapshots happened.
2019-03-29 09:56:52 +01:00
Benjamin Otte
3a8a9fc2bd reftests: Remove style-properties-nth-child test
Style properties don't exist anymore.
2019-03-29 09:56:52 +01:00
Benjamin Otte
866bc13557 reftests: Fix statusbar-remove-all test 2019-03-29 09:56:52 +01:00
Benjamin Otte
3c44f83909 Fix textview-margins reftest
Draw something, otherwise the test will timeout
2019-03-29 09:56:52 +01:00
Benjamin Otte
9ca5495380 reftests: Fix inherit-and-initial test
Run gtk-builder-tool --3to4 over it. As the test cares about the
"initial" and "inherit" CSS keywords, the actual widgets aren't that
important. It's just important to have many of them.
2019-03-29 09:56:52 +01:00
Benjamin Otte
822791d8a9 reftests: Remove info-bar-message-types test
- The test doesn't properly test infobars. An infobar is not a box.

- Infobar message types aren't styled anymore.
2019-03-29 09:56:52 +01:00
Benjamin Otte
f070872b36 reftests: Fix notebook-tab-position test
The tab-fill child property is gone, don't use it.
2019-03-29 09:56:52 +01:00
Benjamin Otte
f3e47ee92e reftests: Fix icon-style-basics test
Add a type-func to the GThemedIcon and GEmeblemedIcon usages so
GtkBuilder finds them.
2019-03-29 09:56:52 +01:00
Benjamin Otte
e612b55bd4 reftests: Fix css-match-name test
- Replace GtkImage::pixbuf with GtkImage::paintable
- Use a GtkPicture so the sizing is correct
2019-03-29 09:56:52 +01:00
Benjamin Otte
6d38f1dcb5 reftests: Fix css-match-type test
- Replace GtkImage::pixbuf with GtkImage::paintable
- Use a GtkPicture so the sizing is correct
2019-03-29 09:56:52 +01:00
Benjamin Otte
d4df5211f3 reftests: Fix border-image-excess-size.ui test
The old reftests drew an opaque image, the new image is transparent.

This test drew the reference image as black and the test as transparent
black, and those are now different.
2019-03-29 09:56:52 +01:00
Benjamin Otte
2e67c2eb8f reftests: Delete removed tests from testdata 2019-03-29 09:56:52 +01:00
Benjamin Otte
47d4b06eca reftests: Fix css-currentcolor-alpha.ui test
The test did not draw anything, which fails now.
2019-03-29 09:56:52 +01:00
Benjamin Otte
5ddce32e1a reftests: Fix css-match-class test
- Replace GtkImage::pixbuf with GtkImage::paintable
- Use a GtkPicture so the sizing is correct
2019-03-29 09:56:52 +01:00
Benjamin Otte
8846f28369 reftests: Fix background-size-zero test
We were drawing nothing, causing a timeout.
2019-03-29 09:56:52 +01:00
Benjamin Otte
62d0bd7153 reftests: Fix nth-child test
Box children no longer have a "position" child property.
2019-03-29 09:56:52 +01:00
Benjamin Otte
d5175526f9 reftests: Fix treeview-fixed-height test
Convert -gtk-gradient() to linear-gradient in the CSS.
2019-03-29 09:56:52 +01:00
Benjamin Otte
7935f9d3b8 reftests: Actually build a module
Reftests are expecting a module called libreftest.so, so don't build a
static libgtkreftest.a but what they expect.
2019-03-29 09:56:52 +01:00
Benjamin Otte
7cc5e51a92 reftests: Fix actionbar test
Boxes have no pack-type anymore.
2019-03-29 09:56:52 +01:00
Benjamin Otte
8542ac2c42 reftests: Fix window-height-for-width test
The dialog's vbox internal child is now called content_area
2019-03-29 09:56:52 +01:00
Benjamin Otte
b3eddbb45d reftests: Fix grid-spacing1 test 2019-03-29 09:56:52 +01:00
Benjamin Otte
e3dbf8d524 reftests: Fix unresolvable.ui test
- Make sure we draw something
- Don't use -gtk-gradient() but linear-gradient instead
2019-03-29 09:56:52 +01:00
Benjamin Otte
d3be32f8ea reftest: Be more careful about snapshotting
Instead of waiting for the first invalidate-contents signal, wait until
we get a render node. This will break spectacularly for reftests not
drawing anything at all, but we just hope that won't happen.
2019-03-29 09:56:52 +01:00
Benjamin Otte
0c81ea2f28 reftests: Make meson run every test separately
This way, we don't get an abort once the first test gets a warning.

We also can use meson test to run individual tests.

Unfortunately, only ~60% of tests pass.
2019-03-29 09:56:52 +01:00
Benjamin Otte
c564a349e5 testsuite: Make reftests work again
Well, the testrunner works again, the tests don't all succeed.

So exclude them from CI.
2019-03-29 09:56:52 +01:00
Benjamin Otte
42d580dc07 reftests: Remove image-recording-surface test
It's no longer possible to set surfaces on a GtkImage, so we don't need
to test that setting a recording surface works.
2019-03-29 09:56:52 +01:00
Matthias Clasen
700183e5b6 Convert ui files
Run gtk4-builder-tool simplify --3to4 over all ui files.
2019-03-28 16:37:21 -04:00
Matthias Clasen
396deb44fa Convert ui files
Run gtk4-builder-tool simplify --3to4 over all ui files.
2019-03-27 21:48:12 -04:00
Matthias Clasen
e5722367b3 Merge branch 'fixed-layout' into 'master'
Add GtkFixedLayout

See merge request GNOME/gtk!668
2019-03-27 18:51:04 +00:00
Matthias Clasen
7ac250dea7 Convert all ui files
Run gtk4-builder-tool simplify --3to4 over all ui files.
2019-03-27 13:36:24 -04:00
Matthias Clasen
27c286773c tests: Stop using gtk_window_move
It is going away.
2019-03-26 17:55:29 -04:00
Emmanuele Bassi
fc33bf2d1f Skip all LayoutChild when testing
GtkLayoutChild instances are created on demand once we have a widget, a
GtkLayoutManager, and a child widget. This makes testing their creation
fairly tricky.

Let's skip them, for the time being.
2019-03-26 18:46:55 +00:00
Benjamin Otte
799cb39e08 Remove win32 themeing support
It was unused through all of GTK 3, so it is not worth supporting.

The best Windows themes do not make use of it at all.
2019-03-22 22:30:01 +01:00
Matthias Clasen
898728fb2d a11y tests: Clean up the placeholder-text test
This was relying on setting has-focus for initial focus.
2019-03-16 22:46:34 -04:00
Matthias Clasen
ad3773b2e1 a11y tests: Update expected results
The changes here are all related to initial focus.
2019-03-16 21:49:24 -04:00
Matthias Clasen
8619b109cc Update the focus test
Check that we get the expected sequences of focus
change events for the nonlinear, inferior and ancestor
cases.

It would be nice to do the same checks for crossing
events, but we have no gtk_window_set_hover().
2019-03-16 21:31:56 -04:00
Matthias Clasen
7c19ab66ee single selection: Skip tests properly
Do runtime checks for the GLib version,
instead of compiling out tests.
This avoids compiler warnings.
2019-03-16 21:23:28 -04:00
Benjamin Otte
3a3b325f8e transform: Add perspective()
This commit adds gsk_transform_perspective(), gtk_snapshot_perspective()
and support for perspective() in the CSS syntax.
2019-03-05 20:46:00 +01:00
Benjamin Otte
bd113aa85c transform: Redo querying API
Make the API expect a tranform of the proper category instead of
doing the check ourselves and returning TRUE/FALSE.

The benefit is that the mai use case is switch (transform->category)
statements and in those we know the category and don't need to check
TRUE/FALSE.

Using the wrong matrix will now cause a g_warning().
2019-03-04 23:41:51 +01:00
Benjamin Otte
3545abc7a1 transform: Implement gsk_transform_invert()
And use it.

And test it.
2019-03-04 23:41:51 +01:00
Benjamin Otte
979e9bec27 testsuite: Add a transforms test
In particular, check that to_matrix() and to_2d(), to_affine() and
to_translate() return the same values.

This also requires a recent Graphene version or the tests will fail.
2019-03-04 23:41:27 +01:00
Benjamin Otte
3a3c2d14ab rendernode: Make the transform node take a GskTransform
This is an attempt to push GskTransform deeper into the stack.
2019-03-04 23:15:07 +01:00
Matthias Clasen
9e0c471b03 entry, spin button: Drop redundant API
Avoid duplicating GtkEditable APIs. Port existing users.
2019-02-28 16:34:00 -05:00
Matthias Clasen
1469d01e2e testsuite: Stop using grab-focus as a keybinding signal
We don't have that signal anymore.
2019-02-26 08:16:48 -05:00
Timm Bäder
74ab3cdf75 compare-render: Assert that no error has been set
Much better error message than just the one from the node != NULL
assertion in the next line.
2019-02-25 08:37:06 +01:00
Matthias Clasen
69b1a348c6 a11y tests: Update output for entries 2019-02-23 22:24:50 -05:00
Matthias Clasen
837d9bf39e Remove css test for key bindings 2019-02-21 12:29:46 -05:00
Matthias Clasen
f95ed63b88 Merge branch 'nbpage' into 'master'
Notebook child metas

See merge request GNOME/gtk!594
2019-02-21 05:50:05 +00:00
Matthias Clasen
3eda783d0a tests: Update property tests
The pages property must be skipped.
2019-02-21 00:31:17 -05:00
Matthias Clasen
27f008de44 builder test: Update notebooks 2019-02-21 00:31:17 -05:00
Matthias Clasen
7d69430ebd css tests: Update ui files for notebooks 2019-02-21 00:31:17 -05:00
Matthias Clasen
05f8319270 a11y tests: Update ui files
Notebooks have changed.
2019-02-21 00:31:17 -05:00
Matthias Clasen
572142b950 css tests: Update expected output for entries
Flat is gone.
2019-02-21 00:30:48 -05:00
Chun-wei Fan
a339a5d617 testsuite/gtk/singleselection.c: Avoid VLA usage
It is unfortunate that Visual Studio is unlikely to support VLA usage,
so replace it with g_newa().
2019-02-21 10:37:27 +08:00
Matthias Clasen
ac445229d0 a11y text test: Use a GtkText instead 2019-02-19 00:25:59 -05:00
Matthias Clasen
3422edff6c a11y tests: Update expected output
GtkText makes an appearance in many places now.
2019-02-19 00:25:59 -05:00
Matthias Clasen
102c0ce696 focus test: Use a GtkText instead
Thats where the focus is nowadays.
2019-02-19 00:25:59 -05:00
Matthias Clasen
996a4246fb defaultvalue test: Exempt GtkText::buffer
It gets created on-demand, so isn't NULL.
2019-02-19 00:25:59 -05:00
Matthias Clasen
613f8ceacf testsuite: update css node tests
The entries have changed. Reflect that.
2019-02-19 00:25:59 -05:00
Matthias Clasen
76be7a5025 a11y: Update assistant test output
This changed as part of the recent cleanup that removed
some internal boxing.
2019-02-17 15:54:24 -05:00
Matthias Clasen
74d6d81db9 Merge branch 'assistant-cleanup' into 'master'
Assistant cleanup

See merge request GNOME/gtk!581
2019-02-15 15:54:53 +00:00
Matthias Clasen
aa552229c9 singleselection: Make tests build without warnings 2019-02-15 10:23:48 -05:00
Benjamin Otte
07722582ef simpleselection: Improve items-changed
Make items-changed never emit 2 signals, instead, always emit only one,
potentially by extending the range reported in items-changed.

And be a lot more exhaustive about autoselect tests.
2019-02-15 06:46:04 +01:00
Benjamin Otte
1f56f5c2e9 selectionmodel: Change prototype of query_range()
1. Do not make position an inout variable
The function is meant to return a range for a given position, not modify
a position. So it makes no conceptual sense to use an inout variable.
2. Pass the selected state as an out variable
Using a boolean return value - in particular in an interface full of
boolean return values - makes the return value intuitively feel like a
success/failure return. Using an out variable clarifies the usage.
3. Allow passing every position value
Define what happens when position >= list.n_items
4. Clarify the docs about how this function should behave
In particular, mention the case from point (3)
5. Add more tests
Again, (3) needs testing.
2019-02-15 06:28:35 +01:00
Matthias Clasen
ae9a29f8ce Exempt "pages" properties from defaultvalue test
Ironically, these properties are too good - they always
give you a proper value, which is unfortunately different
from the declared default value, which is NULL. So, don't
check these.
2019-02-13 18:14:48 -05:00
Matthias Clasen
4fb342fb03 Update check-icon-names tests
Drop icons that are only used by demos, and check for ones
that are actually used in gtk.
2019-02-12 21:37:02 -05:00
Matthias Clasen
ec6458db16 testsuite: Consider bookmark-new as required icon
This was missing from the list.
2019-02-12 17:34:07 -05:00
Matthias Clasen
78da8e4dc5 Exclude some tests on too-old glib
I'm coming to the conclusion that the ci test
failures are due to a recently fixed bug in
GListStore.
2019-02-10 23:14:59 -05:00
Matthias Clasen
f496b4c072 add more autoselect tests 2019-02-10 22:19:28 -05:00
Matthias Clasen
2e1a204c49 Reorder tests
Trying to get to the bottom of a ci failure
2019-02-10 21:28:53 -05:00
Matthias Clasen
cdb729441e selection tests: Plug a memory leak 2019-02-10 21:08:44 -05:00
Matthias Clasen
976664c004 a11y tests: Adapt to changes
The buttons in the stack switcher are now toggle buttons, no
longer radio buttons. Update expected output for that.
2019-02-10 18:43:59 -05:00
Matthias Clasen
ccb0a0fdfe testsuite: omit some selection properties
The selected property of GtkSingleSelection is not
freely settable, so omit it from notification tests.
2019-02-10 18:43:59 -05:00
Matthias Clasen
dcdec4bf96 testsuite: Add selection model tests 2019-02-10 18:43:59 -05:00
Matthias Clasen
ed6a6d30a6 Merge branch 'idle-test-recentmanager' into 'master'
tests: Bulk add recent items in an idle

See merge request GNOME/gtk!568
2019-02-08 15:01:22 +00:00
Matthias Clasen
7384cc7e70 a11y tests: Update actionbar output
This changed with box packing changes.
2019-02-08 09:56:14 -05:00
Matthias Clasen
3fcfd734f4 a11y tests: Update dialog-related output
There was a change in internal dialog structure that
is reflected in this output.
2019-02-08 09:51:45 -05:00
Matthias Clasen
4dc3595e2c a11y tests: Update assistant ui file
The conversion was done with gtk-builder-tool simplify --3to4.
2019-02-08 09:51:45 -05:00
Matthias Clasen
f05932811b a11y tests: Update stack ui file
The conversion was done with gtk-builder-tool simplify --3to4.
2019-02-08 09:51:45 -05:00
Emmanuele Bassi
257bd4f63f tests: Bulk add recent items in an idle
Instead of adding them and waiting for the changed signal to be emitted
in the main loop, there might be a race where the change signal is
emitted before we have a chance of spinning the loop.
2019-02-08 14:37:21 +00:00
Matthias Clasen
038a9b2b84 notify test: Omit GtkStackPage::position
We can't change positions without a stack.
2019-02-08 09:04:08 -05:00
Matthias Clasen
e91144f6c9 Make GtkInvisible private
We can't quite get rid of its use in the inspector,
but we can make it private.
2019-02-06 02:06:19 -05:00
Matthias Clasen
de4703ebfa Drop buttonbox from tests 2019-02-05 07:40:43 -05:00
Matthias Clasen
5120748981 Drop GtkButtonBox
This widget does not seem worth keeping,
and we want to get rid of child properties.
2019-02-04 12:44:55 -05:00
Matthias Clasen
a3801299f5 Merge branch 'tabular-menus' into 'master'
Drop tabular menus

See merge request GNOME/gtk!527
2019-01-25 17:32:41 +00:00
Matthias Clasen
f03fe74369 Update css tests results
These now show images as children of the switch,
as expected.
2019-01-24 21:10:12 -05:00
Matthias Clasen
b3dbdcdf77 fixup notify tests 2019-01-23 22:51:48 -05:00
Matthias Clasen
19dbc831c5 Drop row/column-span-column from tests 2019-01-23 22:42:51 -05:00
Matthias Clasen
883d5d8584 box: Remove the position child property
The position child property is problematic, since it
requires us to emit notification for all children when
inserting a child early in the list of children.

Remove the property from all ui files.
2019-01-23 19:30:47 -05:00
Timm Bäder
c47abb5f68 testsuite: Remove box packing css node tests
Testing the correct css order for mixed pack-start/pack-end cases
doesn't make sense if boxes don't have a notion of pack-type anymore.
2019-01-23 19:30:46 -05:00
Timm Bäder
494e9d750a dialog: Expose the content area as a separate GtkBox child
This way, the "vbox" internal child does not contain anything by
default. It previously did contain "internal" widgetry like the action
area.
2019-01-23 19:30:46 -05:00
Timm Bäder
3a13515777 Stop using GtkBox's pack-type child prop in UI files 2019-01-23 19:30:46 -05:00
Matthias Clasen
afaac98442 Update a11y tests
Working towards a passing testsuite.
2019-01-23 19:27:35 -05:00
Chun-wei Fan
a0e8cd5bac testsuite/gtk/slicelistmodel.c: Avoid VLAs
Unfortunately VLA's are unlikely to be supported on any Visual Studio
versions, although it is C99, so replace it with g_newa() calls.
2019-01-21 13:49:20 +08:00
Matthias Clasen
9430b0b6ee testsuite: Add slice model tests
Do the same style of tests we do for all the
other list models. These tests found the issue
fixed in the previous commit.
2019-01-20 06:14:21 +01:00
Benjamin Otte
af56f06b7b rbtree: Fix a crash in insertion fixup
This got broken in commit a33ff4c6ab.

Testcase included.
2019-01-20 06:09:40 +01:00
Benjamin Otte
8a7706f2b5 rbtree: Make node getters not require tree argument
The tree is not needed to walk around the nodes.

It is however still needed for anything that requires modifying the
tree.

There is no immediate benefit in changing this API, but there might be
situations in the future where we can avoid looking up the tree when we
just want to check some details about the node.
2019-01-14 02:14:11 +01:00
Matthias Clasen
25bca27bfe Rename GtkCssRBTree to GtkRBTree
This is a generally usable red-black tree api,
and it is not used in css at all.
2019-01-14 02:14:11 +01:00
Matthias Clasen
e269f43afc Rename GtkRBTree to GtkTreeRBTree
This frees up the generic name for a more
generic rbtree implementation.
2019-01-14 02:14:11 +01:00
Emmanuele Bassi
e458ea2f3d build: Avoid a Meson deprecation warning
Using an empty `configuration_data` object to copy a configuration file
is deprecated since Meson 0.47 (released July 2018); the equivalent
behaviour is available by using `copy: true`.
2019-01-08 14:46:46 +00:00
Mike Gorse
8f29a0633b A11y: Add support for AtkTableCell 2018-12-14 19:25:27 +00:00
Timm Bäder
e0a7d28339 testuite Add translucent offscreen rendering test case 2018-12-02 16:15:17 +01:00
Carlos Garnacho
21d0e30903 testsuite: Fix gestures tests for the legacy controller
Let it create one with the right propagation phase, so the event propagation
chain stays the same.
2018-10-15 17:39:04 +02:00
Carlos Garnacho
bb0e964f56 testsuite: Fix gestures test
Was broken by the removal of the default GtkEventControllerLegacy.
2018-10-15 17:39:04 +02:00
Chun-wei Fan
cebf5ed46c testsuite/gtk/filterlistmodel.c: Avoid GCCism
Pointer arithmetic on gpointers (void *) is a GCCism, so avoid that by
being more explicit with things.
2018-10-09 16:26:36 +08:00
Chun-wei Fan
1ca906008e testsuite/gtk/[flatten|sort]listmodel.c: Avoid VLA usage
Visual Studio is unlikely to support VLAs at any point, so avoid using
them and use g_newa() instead.
2018-10-09 16:26:21 +08:00
Timm Bäder
26302cada5 Update expected node files
We don't technically hide the arrow nodes anymore.
2018-09-24 21:05:07 +02:00
Simon McVittie
a0d83bdfa7 testsuite: Install accessibility-dump executable alongside tests
The installed-tests want to run this.

Signed-off-by: Simon McVittie <smcv@debian.org>
2018-09-19 09:41:49 +01:00
Simon McVittie
fa8190328d testsuite: Fix installed-test metadata for autotestkeywords
The executable is called autotestkeywords, so we shouldn't try to run
an executable named keywords. Also rename the metadata file to match.

Signed-off-by: Simon McVittie <smcv@debian.org>
2018-09-19 09:40:37 +01:00
Simon McVittie
d19cba429d reftests: Fix path to installed-tests in .test metadata
The installed-tests are now namespaced as gtk-4.0 to avoid colliding
with GTK+ 3, but these files weren't updated.

Signed-off-by: Simon McVittie <smcv@debian.org>
2018-09-19 09:37:06 +01:00
Benjamin Otte
5bf009a203 cssrbtree: Fix a crasher
After removing elements, there were a few cases where the tree wasn't
properly balanced which could further down violate assumptions about the
layout.

Attached is the original testcase that triggered it. I didn't bother
simplifying it.
2018-09-19 04:31:29 +02:00
Benjamin Otte
545c5f18b2 testsuite: Disable some tests for older glib 2018-09-17 04:30:28 +02:00
Benjamin Otte
5571217218 testsuite: Add tests for GtkSortListModel 2018-09-17 03:57:37 +02:00
Benjamin Otte
b6acc31d44 GtkMapListModel: add 2018-09-16 18:50:17 +02:00
Benjamin Otte
6d0fe46cba propertylookuplistmodel: Add
This model just takes an object and a property name and recursively
looks it up. In particular, I want it for:

widget, widget.parent, widget.parent.parent, ...
2018-09-16 18:50:17 +02:00
Benjamin Otte
2237009983 testsuite: Disable some tests with older glib
Fixes CI.
2018-09-16 18:50:17 +02:00
Benjamin Otte
32ec7dec61 gtk: Add GtkFlattenListModel
We can flatten lists of lists into lists now!
2018-09-16 18:50:17 +02:00
Benjamin Otte
4b5fb5ec79 treelistmodel: Refactor to add GtkTreeListRow
This patch does multiple things:

1. Add a custom persistent per-row object.
2. Move all per-row API to that object. This means notifications are now
   possible.
3. Add a "passthrough" construct-only property to the TreeListModel that
   influences if the model returns these new object or passes through
   the ones from the model.

This greatly simplifies the code needed to be written for widgetry,
because one can just connect the per-row object to the expanders that
expand and collapse rows.

As an added power feature, these objects can also be passed through
further models (like filter models).

It also adds kind of a hack to Adwaita to make the test look neat.
2018-09-16 18:50:17 +02:00
Benjamin Otte
4f70f72349 gtk: Add GtkFilterListModel
This is a GListModel implementation that filters the given source model.
2018-09-16 18:50:17 +02:00
Benjamin Otte
573c63973a gtk: Add GtkTreeListModel
This is a GListModel implementation with a neat API that can be used to
implement trees inside GtkListBox.
2018-09-16 18:50:17 +02:00
Matthias Clasen
099b967885 Don't fail the build if c++ isn't found
The intention of this check was to skip the keyword
test if no c++ compiler is found. But the meson
docs say that add_languages() will abort unless we
pass required: false.
2018-08-18 02:14:56 +00:00
Benjamin Otte
50d5666db0 container: Remove focus chains
They're prectically unused.

Widgets who want to influcence the focus chain behavior should implement
GtkWidgetClass::focus and deal with focus there.
2018-07-31 22:34:27 +02:00
Carlos Garnacho
1570c41efa testsuite: Update window test to use gestures when interactive 2018-07-30 13:14:12 +02:00
Matthias Clasen
b6d990af25 tests: Update a11y tests
Some things changed.
2018-07-27 14:23:20 -04:00
Matthias Clasen
766e2b1e63 testsuite: Update the list of used icons
We use some more now...
2018-07-27 13:37:00 -04:00
Matthias Clasen
32de29bb68 testsuite: Sort icon names
This is easier to keep track of.
2018-07-27 07:12:23 -04:00
Benjamin Otte
5d9d73b090 testsuite: Fix DragContext => Drag renaming 2018-07-24 20:55:45 +02:00
Matthias Clasen
1d72e3e193 Drop builtin icon test
We don't have these icons anymore.
2018-07-22 17:16:20 +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
14f86ae24d testsuite: Add emoji icon names
We check for all icon names that are used in gtk.
2018-07-19 17:48:06 -04:00
Daniel Boles
ca94ff10ce testsuite/gtk/defaultvalue: Actually build...& fix
It looks like this got dropped during the move from autotools and never
restored. I can see why, since making it work wasn't a hugely fun task!

Notes on some less then obvious details:
 * PlacesSidebar is private now and didn't seem to be to be particularly
   easy to adapt to, so this moves to checking for it by name, not TYPE.
   I couldn't find a (fast) better way; if you know how, please clean up
 * added 2 casts to avoid warnings from the new type-propagating ref()
 * GdkClipboard and GdkContentProvider need some properties dodged
 * GtkToolItemGroup is gone
 * fixed indentation and used TypeName:property-name syntax in a print()
2018-06-29 20:05:21 +01:00
Daniel Boles
8aa4b5150e notify test: Remove more nonexistent properties 2018-06-27 17:17:05 +01:00
Timm Bäder
ecaa16c367 notify test: Remove some non-existant properties 2018-06-27 18:03:23 +02:00
Timm Bäder
2f8284a386 testsuite: Remove a GtkColorButton special case
The comment above explains neatly why subclassing GtkButton for
GtkColorButton was a bad idea. Nowadays it's a GtkWidget subclass
containing a GtkButton so let's remove the special case here.
2018-06-27 18:03:23 +02:00
Timm Bäder
73cad1e784 Remove some GtkRecentChooserMenu references
Doesn't exist anymore.
2018-06-27 18:03:23 +02:00
Benjamin Otte
0c76264953 reftests: Fix compilation
FOREIGN surfaces are gone.
2018-06-26 00:53:39 +02:00
Timm Bäder
33e113d607 testsuite: Print tested property name in notify test 2018-06-20 20:47:17 +02:00
Benjamin Otte
f247d268d4 dnd: Add GdkDrop base class for GdkDragContext
The ultimate goal of this patch series is to split GdkDragContext into
GdkDrop + GdkDrag classes for the destination and source side of a dnd
operation.

The refactoring is meant to work something like this:
1. Introduce GdkDrop as a base class
2. Make all drop related code (like GdkEvent) use GdkDrop instead of
   GdkDragContext. Move/duplicate APIs to allow that.
3. Port all drop contexts in the backends from GdkDragContext to GdkDrop
4. Delete all APIs in GdkDragContext that aren't needed anymore.
5. Make GdkDragContext no longer a GdkDrop subclass
6. Rename GdkDragContext to GdkDrag
2018-06-18 23:49:19 +02:00
Timm Bäder
fffb3161bc notebook: Stop reversing tabs based on text direction 2018-06-18 17:35:02 +02:00
Timm Bäder
01d4538223 box: Don't reorder children based on text direction
Make :first-child always be the first child, i.e. the leftest one in LTR
and the rightest one in RTL.
2018-06-18 17:35:02 +02:00
Timm Bäder
da27627696 paned: Don't reorder css nodes based on text direction 2018-06-18 17:35:02 +02:00
Philippe Normand
2f181df1cf gtkmain: Add gtk_get_main_thread()
This utility function can be useful to know which thread was initialized for
GTK+.
2018-06-08 18:41:54 +01:00
Philippe Normand
542ad4fdc5 gtkmain: Add gtk_is_initialized()
This utility function can be useful to check whether GTK+ was already
initialized or not.
2018-06-08 18:39:38 +01:00
Benjamin Otte
7e574fa98c gdk: Get rid of gdk_event_free()
Events are objects, so use g_object_unref().
2018-05-29 21:53:44 +02:00
Timm Bäder
5c339f2844 Add basic searchbar set_key_capture_widget tests
Make sure we're correctly resetting the internal key capture widget
pointer when the widget goes away.
2018-05-19 10:18:50 +02:00
Benjamin Otte
34d1ebc562 dnd: Make "formats" a construct-only property
... and hide the member variable inside the DragContextPrivate.
2018-05-07 18:55:09 +02:00
Matthias Clasen
1dcb76bc26 Merge branch 'wip/carlosg/controller' into 'master'
carlosg/controller

See merge request GNOME/gtk!131
2018-05-01 12:35:53 +00:00
Benjamin Otte
4aaeb7de19 dnd: Make GdkDragContext::device a (construct-only) property
Also remove gdk_drag_context_set_device() and insist on backends using
the property.
2018-04-27 14:32:28 +02:00
Benjamin Otte
4ddc94b293 multipressgesture: Port to new API model 2018-04-26 17:59:42 +02:00
Benjamin Otte
703d5340f1 rotategesture: Port to new API model 2018-04-26 17:59:41 +02:00
Benjamin Otte
48fc18c37b gdk: Get rid of GdkDrawingContext
All information is kept in GdkDrawContext these days, so use that one.
2018-04-24 23:16:58 +02:00
Emmanuele Bassi
e36adbac04 tests: Update the expected a11y dump results
Keep in sync with the current tree.

The changes are mostly caused by updates in the internal hierarchy of
composite widgets, and the fact that the order in which the widget tree
is traversed is not exactly stable.
2018-04-14 16:14:36 +01:00
Emmanuele Bassi
7bd5f8f69c tests: Split out the accessibility dump tests
Instead of having a single massive test running through the a11y
directory, we can split off each individual file into its own unit.

Having individual units has several advantages:

 - units are executed in parallel
 - it's easier to identify the failing units
 - logs for failed units are easier to read
2018-04-14 16:14:10 +01:00
Timm Bäder
d7af16c8e4 gl renderer: Render everyhing according to MV scale
And not the surface's scale factor. This way the magnifier works.
2018-04-11 15:31:22 +02:00
Matthias Clasen
8d396991db testsuite: Don't use ::key-press-event
We don't need it here.
2018-04-05 19:26:53 +02:00
Benjamin Otte
4a513b7800 reftests: Port from gtk_widget_draw() to snapshots 2018-04-05 14:56:39 +02:00
Chun-wei Fan
bca4a78f07 testsuite/gsk/test-render-nodes.c: Avoid VLA usage
Just #define N as 5, instead of using a const int, which is not enough
to justify that as non-VLA usage.

https://bugzilla.gnome.org/show_bug.cgi?id=773299
2018-04-02 19:14:55 +08:00
Benjamin Otte
5415d05359 tests: Remove references to long-deleted property 2018-03-26 18:16:36 +02:00
Benjamin Otte
e84c6acc4f rendernode: Remove renderer argument
It's not needed to create Cairo nodes anymore.
2018-03-24 21:57:20 +01:00
Alexander Larsson
695d141f32 Merge branch 'rename-window-to-surface' into 'master'
Rename window to surface

See merge request GNOME/gtk!72
2018-03-20 16:16:57 +00: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
Alexander Larsson
3dce0dcca7 GdkSurface: Rename lots of stuff from window->surface
Mostly these are internal things, but the major public change is
that event.window is now event.surface.
2018-03-20 15:14:10 +01:00
Alexander Larsson
9a7e721181 GdkSurface: Rename various functions and variables
This is an automatic rename of various things related
to the window->surface rename.

Public symbols changed by this is:
 GDK_MODE_WINDOW
 gdk_device_get_window_at_position
 gdk_device_get_window_at_position_double
 gdk_device_get_last_event_window
 gdk_display_get_monitor_at_window
 gdk_drag_context_get_source_window
 gdk_drag_context_get_dest_window
 gdk_drag_context_get_drag_window
 gdk_draw_context_get_window
 gdk_drawing_context_get_window
 gdk_gl_context_get_window
 gdk_synthesize_window_state
 gdk_surface_get_window_type
 gdk_x11_display_set_window_scale
 gsk_renderer_new_for_window
 gsk_renderer_get_window
 gtk_text_view_buffer_to_window_coords
 gtk_tree_view_convert_widget_to_bin_window_coords
 gtk_tree_view_convert_tree_to_bin_window_coords

The commands that generated this are:

git sed -f g "GDK window" "GDK surface"
git sed -f g window_impl surface_impl
(cd gdk; git sed -f g impl_window impl_surface)
git sed -f g WINDOW_IMPL SURFACE_IMPL
git sed -f g GDK_MODE_WINDOW GDK_MODE_SURFACE
git sed -f g gdk_draw_context_get_window gdk_draw_context_get_surface
git sed -f g gdk_drawing_context_get_window gdk_drawing_context_get_surface
git sed -f g gdk_gl_context_get_window gdk_gl_context_get_surface
git sed -f g gsk_renderer_get_window gsk_renderer_get_surface
git sed -f g gsk_renderer_new_for_window gsk_renderer_new_for_surface

(cd gdk; git sed -f g window_type surface_type)
git sed -f g gdk_surface_get_window_type gdk_surface_get_surface_type

git sed -f g window_at_position surface_at_position
git sed -f g event_window event_surface
git sed -f g window_coord surface_coord
git sed -f g window_state surface_state
git sed -f g window_cursor surface_cursor
git sed -f g window_scale surface_scale
git sed -f g window_events surface_events
git sed -f g monitor_at_window monitor_at_surface
git sed -f g window_under_pointer surface_under_pointer
(cd gdk; git sed -f g for_window for_surface)
git sed -f g window_anchor surface_anchor
git sed -f g WINDOW_IS_TOPLEVEL SURFACE_IS_TOPLEVEL
git sed -f g native_window native_surface
git sed -f g source_window source_surface
git sed -f g dest_window dest_surface
git sed -f g drag_window drag_surface
git sed -f g input_window input_surface

git checkout NEWS* po-properties po docs/reference/gtk/migrating-3to4.xml
2018-03-20 12:05:26 +01:00
Alexander Larsson
391727bd0d GdkWindow -> GdkSurface initial type rename
This renames the GdkWindow class and related classes (impl, backend
subclasses) to surface. Additionally it renames related types:
GdkWindowAttr, GdkWindowPaint, GdkWindowWindowClass, GdkWindowType,
GdkWindowTypeHint, GdkWindowHints, GdkWindowState, GdkWindowEdge

This is an automatic conversion using the below commands:

git sed -f g GdkWindowWindowClass GdkSurfaceSurfaceClass

git sed -f g GdkWindow GdkSurface
git sed -f g "gdk_window\([ _\(\),;]\|$\)" "gdk_surface\1" # Avoid hitting gdk_windowing
git sed -f g "GDK_WINDOW\([ _\(]\|$\)" "GDK_SURFACE\1" # Avoid hitting GDK_WINDOWING
git sed "GDK_\([A-Z]*\)IS_WINDOW\([_ (]\|$\)" "GDK_\1IS_SURFACE\2"
git sed GDK_TYPE_WINDOW GDK_TYPE_SURFACE
git sed -f g GdkPointerWindowInfo GdkPointerSurfaceInfo

git sed -f g "BROADWAY_WINDOW" "BROADWAY_SURFACE"
git sed -f g "broadway_window" "broadway_surface"
git sed -f g "BroadwayWindow" "BroadwaySurface"
git sed -f g "WAYLAND_WINDOW" "WAYLAND_SURFACE"
git sed -f g "wayland_window" "wayland_surface"
git sed -f g "WaylandWindow" "WaylandSurface"
git sed -f g "X11_WINDOW" "X11_SURFACE"
git sed -f g "x11_window" "x11_surface"
git sed -f g "X11Window" "X11Surface"
git sed -f g "WIN32_WINDOW" "WIN32_SURFACE"
git sed -f g "win32_window" "win32_surface"
git sed -f g "Win32Window" "Win32Surface"
git sed -f g "QUARTZ_WINDOW" "QUARTZ_SURFACE"
git sed -f g "quartz_window" "quartz_surface"
git sed -f g "QuartzWindow" "QuartzSurface"

git checkout NEWS* po-properties
2018-03-20 11:40:08 +01:00
Samuel Thibault
bd986f9534 gtkbuilder: add accessibility role declaration
This allows to override the role declared to the atk stack.  For
instance,

<accessibility>
  <role type="static"/>
</accessibility>

allows to tell the accessibility stack that a label is just a message in
a message box.

Fixes #109
2018-03-19 18:07:06 +01:00
Benjamin Otte
abc9b944f9 testsuite: Update C++ keywords test to GTK 3.0.0 2018-03-18 19:20:46 +01:00
Benjamin Otte
d54ca3c74f gdk: Add GDK_MEMORY_DEFAULT
This is the default memory format.

I added it because it is way better than including a private header and
using GDK_MEMORY_CAIRO_FORMAT_ARGB32.
2018-03-18 05:57:07 +01:00
Matthias Clasen
454814c6b4 Merge branch 'css-image-scaled' into 'master'
Css image scaled

See merge request GNOME/gtk!62
2018-03-15 23:58:40 +00:00
Matthias Clasen
55d35dd13e Update the expected results in the testsuite
the -gtk-scaled() change in the previous commit makes it so
that we now print out the scale factors. Update the expected
output of affected tests to take that into account.
2018-03-15 13:38:41 -04:00
Timm Bäder
65e3dda065 testsuite: Add more gl renderer tests 2018-03-15 12:58:51 +01:00
Timm Bäder
f82b3fdb90 gl tests: Update clipped cross fade output 2018-03-15 12:41:11 +01:00
Timm Bäder
d66bfb1a9a testsuite: Add a GL gradient test 2018-03-15 11:15:35 +01:00
Timm Bäder
8b800fa775 testsuite: Simplify GL test definition 2018-03-14 17:28:41 +01:00
Timm Bäder
d978d4af59 testsuite: Add a GL tests for clipped rounded clipped nodes 2018-03-14 17:28:41 +01:00
Benjamin Otte
e5813b3ae7 texture: Export gdk_memory_texture_new() and GdkMemoryFormat
Also add tests for all these newfangled formats.
2018-03-12 17:21:45 +01:00
Timm Bäder
1596c61003 testsuite: Remove GL text test case
This was just testing that text nodes do alpha correctly, but the test
even breaks if the default font is different from the one that was used
to create the reference image, so drop it for now.
2018-03-04 19:12:04 +01:00
Benjamin Otte
4ac3f916d0 css: Parse hex colors with alpha value
The CSS color spec version 4 introduces this, support has hit Safari,
Chrome and Firefox, so this looks like a feature that's here to stay.

https://drafts.csswg.org/css-color/#hex-notation
2018-03-02 02:00:24 +01:00
Christoph Reiter
1253e7bfcb tests: Make GSETTINGS_SCHEMA_DIR point to the compiled schemas in the build dir
With autotools the schemas were compiled into each test suite directory
and the tests set GSETTINGS_SCHEMA_DIR to the test build directory.

With meson's gnome.compile_schemas() we can not define a target directory
so just make sure it is built in the gtk directory and set GSETTINGS_SCHEMA_DIR
to the gtk build directory when running the tests.

This makes the gtk+:gtk suite pass when no gtk is installed on the system.
2018-02-17 09:48:12 +01:00
Matthias Clasen
8891967f2b gtk testsuite: Stop using gtk_widget_show_now
If this is a problem, it needs to be handled explicitly.
2018-02-04 23:23:15 +01:00
Matthias Clasen
4ad658f91e a11y testsuite: Stop using gtk_widget_show_now
On non-windows, this doesn't do anything anyway.
2018-02-04 23:23:15 +01:00
Benjamin Otte
cf030e9ffc rbtree: Privatize header
According to meson it's the only private header that doesn't conform to
the *private.h naming.

Fix that.
2018-02-03 16:24:13 +01:00
Emmanuele Bassi
334acbfc39 Replace gdk_threads_add_idle* with g_idle_add()
The main GDK thread lock is not portable and deprecated.

The only reason why gdk_threads_add_idle() and
gdk_threads_add_idle_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 idle callbacks.

https://bugzilla.gnome.org/show_bug.cgi?id=793124
2018-02-03 12:06:58 +01:00
Benjamin Otte
55874470ff gtk: Remove GtkRecentChooser
It's not used any more, recent files are only used by the filtchooser
and that one uses GtkRecentManager directly.
2018-02-02 23:01:31 +01:00
Timm Bäder
228b35c111 gl: Add test case for clipped cross fade nodes 2018-01-27 12:19:22 +01:00
Timm Bäder
6806c28b1e gsk: Add test case for last commit 2018-01-23 21:46:31 +01:00
Matthias Clasen
f942d6f53c Add a test for ::row-changed vs node refs
Test that filter models propagate ::row-changed if there is
an external reference on the node, and not otherwise. This
is showing up in buggy icon view behaviour, where the icon
view is not redrawing if the content changes in a model that
is below a filter model.
2018-01-19 23:29:13 +03:00
Timm Bäder
87bdfbb02c testsuite: Add another gl renderer test case 2018-01-19 14:59:31 +01:00
Matthias Clasen
e2f3b9b1cc tree model sort: Fix set_sort_column
We were failing to change the sort order for the
default sort column in some cases. Fix that, and
add a testcase for this issue.

https://bugzilla.gnome.org/show_bug.cgi?id=792459

Add a testcase for the previous fix
2018-01-16 18:17:54 -05:00
Matthias Clasen
33ec75944f Fix the icontheme test
We rely on log messages here. Since logging is per-display
now, we need to set a display on our custom icontheme object
to get the expected log messages.
2018-01-16 15:42:28 -05:00
Matthias Clasen
0c1ac9add4 testsuite: Stop using ::button-press-event
We can use the generic ::event signal instead.
2018-01-16 14:14:10 -05:00
Timm Bäder
22c0a77ac5 tests: Update gl outset shadow tests
The results are slightly different for these now.
2018-01-15 10:57:25 +01:00
Matthias Clasen
9a3b61ec9d Drop GtkPlacesSidebar from public API
This is a bit of filechooser internals that gets shared with
nautilus, which is fine, but it shouldn't be part of our
public API. There are no other users than nautilus.
2018-01-08 14:38:55 -05:00
Timm Bäder
af6adb5bc0 gl renderer: Add test case for last commit 2018-01-04 12:20:27 +01:00
Matthias Clasen
ab256384b8 testsuite: Drop commented out and useless code
These two uses of ::delete-event were pointless.
2018-01-02 18:14:13 -05:00
Timm Bäder
767df913d1 testsuite: Move gl renderer nodes files into their own directory
Otherwise, they get picked up by the other node tests.
2017-12-28 16:48:35 +01:00
Timm Bäder
e1c120623b tests: Fix the unblurred gl renderer output images
Some of these were wrong or empty.
2017-12-28 16:48:35 +01:00
Timm Bäder
8312ee0ebe testsuite: Add selected gl renderer test node files 2017-12-28 16:48:35 +01:00
Matthias Clasen
3f012f6d01 Try again to make the a11y tests pass 2017-12-27 07:08:17 -05:00
Matthias Clasen
ed6992867e Fix the a11y tests 2017-12-26 23:16:18 -05:00
Matthias Clasen
90b016ef73 Fix the textbuffer test
The test was assuming that gtk_text_buffer_paste_clipboard is
synchronous, which is no longer the case.
2017-12-26 23:15:30 -05:00
Matthias Clasen
7be6d18f27 Fix objects-finalize test
This test needs similar fixes to the notify test to
pass a display to GDK objects when instantiating them.
2017-12-26 20:11:09 -05:00
Matthias Clasen
1b6750c1f1 Fix notify test
We need to pass a display when creating more GDK objects now.
2017-12-26 20:06:06 -05:00
Timm Bäder
e05b0ae9a4 test-render-nodes: Add transformed clip nodes test 2017-12-21 19:12:30 +01:00
Timm Bäder
4aa3f51016 test-render-nodes: Add color matrix test 2017-12-21 18:25:52 +01:00
Timm Bäder
8c8583d04f test-render-nodes: Print a warning if we didn't generate anything 2017-12-21 18:25:52 +01:00
Timm Bäder
04742f320e build: Remove unused variable 2017-12-21 18:25:52 +01: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
Matthias Clasen
fd85ff0c7a Drop gdk_keymap_get_default()
It is better to use the explicit keymap getter - the
default display may not even use the current gdk backend.
2017-12-14 23:57:54 -05:00
Matthias Clasen
54a6273191 Drop gdk_atom_intern
Atoms are just interned strings now, so we can just
use g_intern_string.
2017-12-13 23:39:03 -05:00
Timm Bäder
484e453780 Fix a few overlooked casts
glib warns about these now.
2017-12-09 13:14:00 +01:00
Timm Bäder
1c9e3af482 css node tests: Update expected output 2017-12-08 21:09:03 +01:00
Benjamin Otte
2d5c82b4ec gtk: Remove GtkClipboard 2017-12-03 05:46:49 +01:00
Benjamin Otte
f53848c360 textview: Redo clipboard handling
Instead of using GtkClipboard and handling everything ourselves, we now
put GtkTextBuffer into the GdkClipboard and register (de)serializers for
text/plain.
2017-12-03 05:46:48 +01:00
Matthias Clasen
0b39631464 textview: Replace pixbufs by textures
This affects a few apis, such as gtk_text_iter_get_pixbuf,
gtk_text_buffer_insert_pixbuf and GtkTextBuffer::insert-pixbuf,
which have all been replaced by texture equivalents.

Update all callers.
2017-11-29 23:22:13 -05:00
Benjamin Otte
138abdbc47 a11y: Remove AtkStreamableContent implementation
That is some old code that still uses IOChannels, and the only
pseudouser is at-spi-atk's commented out code that is still using
CORBA types.

So get rid of it now before I need to start adapting it to the new
clipboard.
2017-11-29 23:03:33 -05:00
Benjamin Otte
9a6ec4e959 contentformats: Rename GtkTargetList
It's now called GdkContentsFormat
2017-11-20 23:12:33 +01:00
Benjamin Otte
c863ac0f90 dnd: Remove GtkTargetEntry and GtkTargetFlags
warning: We don't do any same-app checks anymore so you currently can
copy local data into external apps.

This will be fixed later.
2017-11-20 23:12:33 +01:00
Matthias Clasen
95876cbc9c Remove gdk/gdkx.h
It was just a kludge.
2017-11-16 23:00:01 -05:00
Benjamin Otte
3f5178dc21 selection: Remove the info uint
Instead of allowing people to pass a uint user-data, insist on them
comparing mime types.

The user data was a uint instead of a pointer anyway, so uniqueness
could not be guaranteed and it caused more issues than it was worth.
And that's ignoring the fact that it basically wasn't used.
2017-11-16 22:59:43 +01:00
Matthias Clasen
2301d8d90b enums: Change GtkIconSize values
The new values are the ones we intend to keep. The old ones had
duplicated meanings and nobody knew which one to take.
2017-11-15 14:22:17 -05:00
Benjamin Otte
3da65ff233 scalebutton: Remove icon size 2017-11-15 14:22:16 -05:00
Benjamin Otte
a7754a14b5 toolbar: Remove icon sizes 2017-11-15 14:22:16 -05:00
Benjamin Otte
7efc5a1558 clipboard: Consistently use GtkTargetList
Some code was using GtkTargetList, some used GtkTargetEntry and some
GtkTargetPair.
2017-11-15 19:07:16 +01:00
Benjamin Otte
13ca03efb1 cellrendererpixbuf: Remove stock-detail property
GTK3 didn't use that property already...
2017-11-14 18:37:38 -05:00
Benjamin Otte
ed1b6a9bed gdkwindow: Remove event_mask arguments from constructors 2017-11-13 23:41:38 +01:00
Benjamin Otte
b3f69c130e testsuite: Update expected results for scale changes 2017-11-05 06:58:05 +01:00
Benjamin Otte
8900024697 testsuite: Unrealize renderers before unreffing
This is now necessary, because the GL renderer crashes if we don't
enforce it.
2017-11-05 06:55:01 +01:00
Benjamin Otte
e2996732b9 testsuite: Remove cursor tests
Cursors always exist now, it does not make sense to test that their
creation fails anymore.
2017-11-04 00:07:13 +01:00
Benjamin Otte
e294f71555 x11: Redo cursor handling completely
Instead of creating a GdkX11Cursor, create GdkCursors. Cache the XCursor
in a hash table instead.

Also, make use of the new fallback mechanism for fallback code: Make
sure to provide cursors for the names that are guaranteed to exist, but
do not do bad attempts at displaying texture surfaces.
Black/White/transparent is not a replacement for those.
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
Benjamin Otte
b4ad1a5618 testsuite: Remove unused test using long-gone API 2017-11-01 18:18:24 +01:00