Commit Graph

277 Commits

Author SHA1 Message Date
Benjamin Otte
dd1cf1ac0f css: An opaque background does not allow omitting push_group
When the background-clip of the background is smaller than the
background-clip of blended images, not pushing a group is wrong.

Test testing exactly that included.
2016-12-20 18:01:10 +01:00
Benjamin Otte
196737a958 reftest: Make screenshot code work without GDK
GDK does not support taking images of GDK windows.
2016-11-20 11:20:34 +01:00
Benjamin Otte
dfd9150a82 build: Don't link against libgtk and libgdk
libgdk is statically linked these days, so if you link against it, all
of its symbols will exist twice: Once in libgtk.so and once in your
binary.
2016-11-20 11:19:32 +01:00
Benjamin Otte
46b9b07a11 reftests: Add reftest for the last 2 fixes
Makes sure that the clipping we do when pushing a group is at the
correct place and in particular doesn't influence shadows.
2016-11-08 02:32:39 +01:00
Alexander Larsson
723b588b5d Make gdk.la and gsk.la a noninst helper library
This merged gtk, gdk and gsk into one library, making it possible to
have internal private APIs between gtk them, as well as producing more
efficient code.

https://bugzilla.gnome.org/show_bug.cgi?id=773100
2016-10-26 16:34:15 +02:00
Alexander Larsson
70935f0952 Drop support for offscreen GdkWindows
These complicate a lot of GdkWindow internals to implement features
that not a lot of apps use, and will be better achieved using gsk.
So, we just drop it all.
2016-10-25 09:54:37 +02:00
Timm Bäder
ead36206a3 Remove GtkActionGroup 2016-10-18 00:34:41 +02:00
Timm Bäder
1bb3501ef7 Fix unittests 2016-10-18 00:34:41 +02:00
Timm Bäder
dece018994 Remove GtkAlignment 2016-10-18 00:29:19 +02:00
Benjamin Otte
4322b69528 cssprovider: Return void, not TRUE
Parsing a css file always succeeds as CSS can recover from parsing
errors.
2016-10-17 17:41:03 +02:00
Benjamin Otte
cda617df4d API: sizegroup: Remove gtk_size_group_set_ignore_hidden() 2016-10-16 18:18:58 +02:00
Benjamin Otte
4df6ddad54 API: container: Remove gtk_container_set_border_width() 2016-10-16 18:18:58 +02:00
Timm Bäder
878f2e4107 widget: Remove deprecated margin-left/right properties 2016-10-16 18:17:21 +02:00
Timm Bäder
040db1efcd Remove some deprecated GdkColor style properties 2016-10-16 18:17:21 +02:00
Timm Bäder
8a3595236d reftests: Remove GtkMisc tests 2016-10-16 18:17:21 +02:00
Timm Bäder
7088d9d294 reftests: Remove celldenderer-pixbuf-stock
The stock properties tested here don't exist anymore.
2016-10-16 18:17:21 +02:00
Timm Bäder
f37cb8f9d0 reftests: Remove GtkMisc properties from now non-misc widgets 2016-10-16 18:17:21 +02:00
Timm Bäder
f45dadadd0 box: Remove 'padding' child property 2016-10-16 18:17:21 +02:00
Benjamin Otte
eace2cf421 API: Remove gdk_window_set_background()
Backgrounds are always transparent black.
2016-10-16 18:17:21 +02:00
Matthias Clasen
d053d5c58f Rename Makefile references from 3.0 to 4.0
This is almost certainly incomplete.
Needs careful scrutiny
2016-10-07 10:34:50 -04:00
Emilio Pozuelo Monfort
ca6c928c5b Properly declare the font CSS property
https://bugzilla.gnome.org/show_bug.cgi?id=769004
2016-07-28 17:13:15 +02:00
Emilio Pozuelo Monfort
b9f61e3a8e Don't use one-stop gradients
They are deprecated, which causes a warning that makes
the test fail.

https://bugzilla.gnome.org/show_bug.cgi?id=769004
2016-07-28 17:12:25 +02:00
Matthias Clasen
0f32919503 Stop using one-stop gradients in reftests
This is causing warnings now that make the tests fail.
2016-07-26 07:25:01 -04:00
Cosimo Cecchi
d9dd7eb757 reftests: override GSETTINGS_SCHEMA_DIR when running tests
The reftest depends on a schema we install ourselves. Instruct GIO to
look in the build directory to avoid a cyclic dep.

https://bugzilla.gnome.org/show_bug.cgi?id=768930
2016-07-25 08:34:52 -04:00
Matt Watson
871b19f9dd reftests: test rem size 2016-04-12 16:59:40 -07:00
Matt Watson
92a496fdec reftests: test em size 2016-04-12 16:59:40 -07:00
Matthias Clasen
e44a87fe94 Fix the textview-margins reftest
This test has a word that wouldn't fit in the room we have with
a window width of 100, and then we get clipped in the one case
but not the other. Make the window a little wider, so it fits.
2016-03-11 16:46:52 -05:00
Benjamin Otte
b7285592f9 cssanimation: Compute progress correctly
We were computing the wrong progress, in particular when the iteration
count was non-integer.

Test included.
2016-03-11 16:39:34 +01:00
Matt Watson
d46d50b761 reftests: add a test for animated box shadow updating clip
This was just fixed by 3e06942847
2016-03-03 16:14:39 -08:00
Matt Watson
35d9702173 reftests: rename util file frame-inhibitor
We'll use the label-text-shadow-changes-modify-clip utils
more generically, lets name the file after its function.
2016-03-03 16:09:13 -08:00
Matthias Clasen
3446760060 reftests: Make separator-size test pass in HighContrastInverse
After neutralizing the stack background, the notebook itself
was peeking through.
2016-01-31 16:54:48 -05:00
Matthias Clasen
6e2c74aaad Trivial formatting fix 2016-01-31 14:11:01 -05:00
Matthias Clasen
1e0ca71eca reftests: Make label-text-shadow-changes-modify-clip test more reliable
This test was failing in continuous, where the tests are running
in a VM with disabled animations. Make the test adapt to that
situation by changing the rui on the fly if we find that animations
are disabled.
2016-01-31 14:11:01 -05:00
Matthias Clasen
2423eb11e3 reftests: Add a message to the test output
Emit a message that ends up in the test output if we are modifying
the test on the fly.
2016-01-31 14:11:01 -05:00
Matthias Clasen
a898dc6e9f reftests: Rename a source file
Easier to keep track of things if the sources are names after
the test they are used in.
2016-01-31 14:11:01 -05:00
Matthias Clasen
5a2feab8c0 reftests: Make animation-direction test more reliable
This test was failing in continuous, where the tests are running
in a VM with disabled animations. Make the test adapt to that
situation by changing the reference ui on the fly if we find
that animations are disabled.
2016-01-31 13:51:54 -05:00
Matthias Clasen
a66287a62e Fix the border-image-excess-size reftest
This was failing because the grid is now respecting border
width too. Making the selector more specific so it only
applies to the toolbars fixes this.
2016-01-30 21:50:00 -05:00
Matthias Clasen
27b4bfc1cf Fix another reftest
Make sure the notebook in the separator-size reftest does not
peek through, by giving it a transparent background.
2016-01-30 21:43:49 -05:00
Matthias Clasen
bbfc547b89 Fix some reftests under wayland
Tests need to use popup windows, in order to avoid differences
due to CSD.
2016-01-30 21:11:12 -05:00
Matthias Clasen
d400ecca14 Remove entry-progress-coloring reftest
We don't recolor text over progress anymore, so this
tests a no longer existing feature.
2016-01-30 11:32:06 -05:00
Matthias Clasen
586522d83c Use TAP output for installed tests 2016-01-30 11:04:22 -05:00
Matthias Clasen
f375b275c8 Run reftests with HighContrastInverse too
For installed tests, we run the reftests with all the builtin
themes (minus platform-specific ones). Add HighContrastInverse
to that list.
2016-01-30 10:10:39 -05:00
Matthias Clasen
8219a6b226 Use an GtkImage instead of GtkArrow
GtkArrow is deprecated, and the recommended replacement
is GtkImage.
2016-01-29 13:21:01 -05:00
Matthias Clasen
866193f6af reftests: get icon-vfuncs test almost working again
The remaining difference here is GtkArrow, which is deprecated
and has not been updated to the latest CSS rendering standards.
2016-01-29 13:10:03 -05:00
Benjamin Otte
f6757e0c0c reftests: Fix up for easy CSS changes
This is mostly search and replace ala
  GtkButton => button
  GtkWindow => window
  .button => button
or removing style properties that aren't used anymore like
  -GtkButton-default-border: 0
2016-01-18 05:05:35 +01:00
Benjamin Otte
b7f32ed451 reftests: Remove test
We no longer match subtypes, so remove the test for it.
2016-01-18 05:05:35 +01:00
Matthias Clasen
1eaf035a78 reftests: Drop deprecated style properties 2016-01-08 18:11:07 -05:00
Benjamin Otte
05bdecb2f8 reftests: Add test for missing-image handling
Add a test that ensures that missing images get the icon-effect properly
applied.
2015-12-04 17:44:51 +01:00
Benjamin Otte
2396265523 css: Rename -gtk-image-effect to -gtk-icon-effect
This is a property for icons, so we should name it as such.
2015-12-02 00:29:31 +01:00
Benjamin Otte
afd0e28437 iconhelper: Improve size determination for surfaces
Instead of just working for image surface, this should now work for all
bounded surfaces.

Test included.
2015-12-02 00:29:29 +01:00
Matthias Clasen
339cb1fe6b Fix reftests
Multiple reftests were damaged by the element name transition.
Repair them. The region reftests are no longer needed, since
we no longer do regions.
2015-10-27 20:06:24 -04:00
Bastien Nocera
3df565cbf7 reftests: Rename reftest
After figuring out what the actual problem is, name the reftest
properly.
The actual problem is that the use-fallback property is ignored when
using an icon-name on GtkImage.
2015-10-08 14:44:19 +02:00
Bastien Nocera
8bd98c08aa reftests: Add test for GtkImage use-fallback property
Fallback seems to be working in the GtkIconTheme test suite, but fails
in GtkImage itself.

This is a test for a bug in the Bluetooth settings. An icon named
"phone-apple-iphone" should fallback to "phone" if the
gnome-icon-theme-extras package isn't installed.
2015-10-08 14:05:35 +02:00
Benjamin Otte
99d4ec2676 reftests: Fix underlines in link-coloring reftest
Underlines now need to be manually specified in CSS since GTK got
text-decoration support.
2015-07-21 02:28:53 +02:00
Paolo Borelli
a19331f231 label: add support for CSS letter-spacing property
Support letter-spacing CSS property on GtkLabel.
Reftest is included.
2015-07-06 00:04:05 +02:00
Benjamin Otte
cd3f24d579 cssvalue: Change color transitions to run premultiplied
Previously, the unpremultiplied values from the GdkRGBA were taken. Now
we premultiply the color values as specified by the CSS specs.
This is only relevant when transitioning with translucent colors.

An example is the halfway transition between transparent (0, 0, 0, 0)
and white (1, 1, 1, 1). Previously, all 4 values where transitioned
separately and the result was semi-transparent gray (0.5, 0.5, 0.5,
0.5).
By depending on the alpha value, the result is now semi-transparent
white (1, 1, 1, 0.5) which is what one would naively expect.

New reftest: color-transition
2015-06-26 21:12:50 +02:00
Cosimo Cecchi
131abe28a4 reftests: fix style class syntax in CSS file
Fixes reftests.

https://bugzilla.gnome.org/show_bug.cgi?id=750605
2015-06-12 08:55:23 -07:00
Matthias Clasen
40bb2a1616 reftests: Add a way to compare different runs
gtk-reftest already had an --output=DIR option to tell it where
to save all the resulting images. Now you can combine this with
the --compare-with=DIR option in a second run to make gtk-reftest
compare the .out.png files from the first run with the .out.png
files of the current run, instead of producing .ref.png files.

The intended use for this is to verify that changes do not affect
the generated output.
2015-03-20 16:42:04 -04:00
Benjamin Otte
2670ae4436 reftests: Add a reftest for box sibling ordering 2015-03-18 15:23:31 +01:00
Benjamin Otte
2d013a739a reftests: Fix test on HighContrast theme
We are testing -gtk-icon-style and assume the theme doesn't touch it.
But HighContrast forces symbolic icons. And that breaks the reference
images.

So explicitly set "requested" for everything.
2015-03-16 15:44:42 +01:00
Matthias Clasen
8615a52ca3 Add some reftests related to textview tags
This test shows that a) tags override the text view style and
b) tags override each other in the expected way.
2015-03-11 22:04:29 -04:00
Benjamin Otte
7eecb16404 treeview: Don't create an overly large pixel cache
GPUs generally have problems when you create a 35000px wide surface.
Luckily X catches this and sends a BadAlloc. Which GTK immediately
abort()s on.

Testcase included.

https://bugzilla.redhat.com/show_bug.cgi?id=1163579
2015-02-05 18:57:29 +01:00
Benjamin Otte
7e5ac3a58d roundedbox: Treat path segments differently
If a side of the box is 0px wide, make the corners owned by the adjacent
sides. This avoids spilling over of unwanted colors from the 0-width
side into the corner.

New test for this case is included.
2015-01-22 16:25:54 +01:00
Benjamin Otte
f313a8235b reftests: Fix border-style-none reftest
Unset all CSS; Adwaita was messing up things.
2015-01-20 01:15:04 +01:00
Benjamin Otte
ad199e4cf9 stylecontext: Use correct parent style for lookups
After 3a337156d1 style lookups still used
the parent context's style as the parent style, even though after a
gtk_style_context_save() the root style of the style context is the
proper parent.

Testcase attached.
2015-01-07 14:26:48 +01:00
Ting-Wei Lan
ef57ac6bf1 reftests: Fix typo
It causes build failure on MinGW.

https://bugzilla.gnome.org/show_bug.cgi?id=741827
2014-12-22 11:14:17 +08:00
Matthias Clasen
c5f2f86ff9 Drop an unused function 2014-11-30 19:58:08 -05:00
Benjamin Otte
e683e915b8 css: Queue resize for properties that affect clip
This fixes shadows that are animated not updating the clip of the widget
they are drawn on. An example of this are the buttons in the CSS shadows
example in gtk-demo.

Reftest included
2014-10-03 06:18:04 +02:00
Benjamin Otte
7afac9670b image: Implement clipping support for icon-shadow
Testcase is attached.
2014-10-03 06:18:04 +02:00
Jasper St. Pierre
3b08ba24b3 reftests: Actually add a text-shadow to the text-shadow reftest
The reftest still passes, since the code still works, but we might as
well test what we claim to test.
2014-09-30 13:43:36 -06:00
Benjamin Otte
9d0ec409ff reftest: Build a shared lib on win32
Windows needs a shared library to link the modules against, otherwise
the undefined symbols make it not work.

So build a shared library on Windows.

We don't want a library elsewhere, as that just complicates things, so
we only make the library shared on Windows and keep it as a noinst
library otherwise.

https://bugzilla.gnome.org/show_bug.cgi?id=736338
2014-09-22 15:47:02 +02:00
Rico Tzschichholz
aa08b87ab6 reftest: Add missing include of reftest-snapshot.h 2014-09-22 15:19:51 +02:00
Benjamin Otte
ee9e708cf6 reftest: Build a private library for gtk-reftest
This is a noinst library for now, but the idea is to turn it into a
proper DLL on Windows, so that we can install it and properly link the
modules to it. Windows doesn't allow undefined symbols in modules.

https://bugzilla.gnome.org/show_bug.cgi?id=736338
2014-09-21 18:59:12 +02:00
Benjamin Otte
2e6dd4082f reftest: Split our more functionality
Split actually taking the snapshot into its own file.
2014-09-21 18:58:45 +02:00
Benjamin Otte
0182d1ed38 reftest: Split out some functionality into own file
Comparing two surfaces is something that can be nicely factored out.
2014-09-21 18:58:45 +02:00
Benjamin Otte
9a8a4a8b14 widget: Don't assume opacity is 100%
... just because there is no style context instantiated yet. Instead,
instantiate a style context during realize() and ask it.

Fixes problems with dim labels not being dimmed on first show.

Testcase included.

https://bugzilla.gnome.org/show_bug.cgi?id=735240
2014-09-07 01:57:10 +02:00
Benjamin Otte
95959ef470 overlay: Handle overlays when no main widget exists
Just pretend that the main widget is an empty widget the size of the
overlay.
Makes it possible to write testcases where no size requests are run on
overlay widgets before size_allocate() is called.

Testcase included.
2014-09-07 01:57:09 +02:00
Benjamin Otte
21d3701291 reftests: Fix Makefile
with non-installed tests the build would get an empty $(reftestdir)
which would screw up the LDFLAGS.

An rpath seems to be required to make libtool build a shared object.
Without an rpath line, it only builds a static object.

https://bugzilla.gnome.org/show_bug.cgi?id=735401
2014-08-27 18:02:52 +02:00
Benjamin Otte
0f0fc59fbd build: make reftests work without installed tests
The libreftest.so module needs to be built in all cases.
Without installed tests, it needs to not be installed though.

https://bugzilla.gnome.org/show_bug.cgi?id=735401
2014-08-26 20:05:49 -04:00
Benjamin Otte
2737c67cce css: Round shadow extents properly
Otherwise drawing will be clipped.

Testcase included
2014-08-21 00:54:07 +02:00
Benjamin Otte
67456304d4 roundedbox: Only grow border-radius if there is one
This is relevant for shadow spread and goes in line with the web.

Testcase included.
2014-08-21 00:54:07 +02:00
Benjamin Otte
1126a34353 label: Respect box-shadow when computing clip
Testclase included.

Also reorder headers to be alphabetic.
2014-08-21 00:54:07 +02:00
Benjamin Otte
b1ac4f91d3 reftests: Update for :active => :checked change 2014-08-16 20:41:32 +02:00
Benjamin Otte
9d2c3f5e68 reftests: Add reftest for statusbar fix
https://bugzilla.gnome.org/show_bug.cgi?id=724281
2014-08-14 19:52:59 +02:00
Benjamin Otte
2120ccfd5e reftests: Make gcc happy 2014-08-14 19:52:59 +02:00
Benjamin Otte
dff52f7a04 css: Match state in siblings properly
Previously, we always returned the state flags of the original widget
and did not consider the siblings' pseudoclasses.

Testcase is attached.
2014-08-13 16:51:16 +02:00
Alexander Larsson
f3b56261cb Fix symbolic-icon-translucent-color reftest
When using the pre-rendered png symbolics it seems that we're off a
tiny bit in a few of the pixels on the antialiased borders of a
stroke. To fix this we switch the icon to media-playback-stop-symbolic
which has no such antialiased borders.

I don't quite understand why the pixels are off, this needs more
research.

https://bugzilla.gnome.org/show_bug.cgi?id=734668
2014-08-12 15:51:36 +02:00
Matthias Clasen
80a8257302 Fix reftests for builddir != srcdir
Make gtk-reftest consult the REFTEST_MODULE_DIR environment
variable to find out where to look for modules, and fix the
libtool hack to construct the .libs subdirectory correctly.
2014-08-10 19:11:39 -04:00
Matthias Clasen
1185b9b29c Fix animation-direction reftest
This was another victim of clipping changes - the labels were
overdrawing each other, leading to test failure. Prevent this
by separating the grid columns.
2014-08-10 19:11:38 -04:00
Matthias Clasen
2d15c25d93 reftests: Make textview-margins pass in make check
I found that setting margins to zero makes the textview clip
away some overshooting pixels. So, instead of a 0/10 split,
do this test with a 2/8 split of margins, to avoid the clipping
issue.
2014-08-10 07:41:53 -04:00
Benjamin Otte
a3d1db608b label: Don't clip text shadows
The previous code for computing the clip rectangle forgot to respect
the text-shadow CSS property. This is usually not very visible because
text shadows usually don't extend the ink rectangle by very much.

See attached testcase for an example.
2014-07-31 17:50:24 +02:00
Benjamin Otte
386e59683a reftest: Add reftest for CSS sizing fix
The test uses a GtkBox for rendering the background, but it could use
any other widget that is not used in the reference.
2014-07-23 18:51:26 +02:00
Benjamin Otte
d66db441e3 reftests: Add a reftest for recent widget path fix
The widget path code copies elements only in gtk_widget_path_copy() -
which is essentially unused - and in
gtk_widget_path_append_with_siblings() - which is used by GtkBox.

So stuff the widget we are testing in a GtkBox to reroduce the problem.
2014-07-22 03:06:04 +02:00
Benjamin Otte
bed70f2bcf reftests: Add reftest for new pseudoclass support 2014-07-21 01:03:47 +02:00
Matthias Clasen
085fada849 Force the simple im module for reftests
I've seen reftests fail with IBus warnings. We should avoid that.
2014-07-14 18:22:40 -04:00
Benjamin Otte
9ae0b8ed27 reftests: Add test for latest fix
Ensure we draw the full backgorund on labels, not just where test
appears.
2014-07-12 07:13:28 +02:00
Benjamin Otte
e1112dce6d reftests: Add test for the recent label changes 2014-07-10 18:56:35 +02:00
Benjamin Otte
6a2ae1bb90 reftests: Improve workaround for GtkGrid bug
... so that it works with wide separators. Or rather: with separators
that don't request 1px size but any other number. Do that by making the
placeholder request the same size by indeed stuffing (hidden) separators
in it.
2014-07-10 18:56:34 +02:00
Benjamin Otte
a1bae4b389 reftests: Add a reftest for 'animation-direction'
It tests the latest two commits.
2014-07-07 20:06:47 +02:00
Jasper St. Pierre
ece9ae4bc5 gtkwindow: Remove resize grips
Resize grips were introduced for GNOME 3.0, before we had any of the
"new GNOME app" features like invisible borders and CSD. With OS X 10.6
and 10.7, Apple has replaced the classic grips in their applications
with invisible borders as well.

New GNOME app designs don't use resize grips anymore and the new
default theme for GTK+, Adwaita, disables them entirely by forcing their
width and height to 0.

They're past their time. Remove the code to support them. This can
always be reverted if some app relies on them.
2014-07-03 12:58:41 -04:00
Matthias Clasen
3da76c1e14 Disable deprecation warnings for installed reftests
Otherwise, these fail in continuous.
2014-06-28 11:13:17 -04:00
Matthias Clasen
b9bd7159c0 Disable deprecation warnings in tests
We want to test deprecated properties, so failing the tests with
warnings is not productive.
2014-06-25 16:29:08 -04:00
Richard Hughes
12e389dd3c Makefile: Actually dist the high-contrast and dark test files 2014-06-24 21:18:46 +01:00
Jasper St. Pierre
38a6a72a7f Makefile: Add a few more cleanfile / ignore rules 2014-06-16 14:03:53 -04:00
Paolo Borelli
715b8744f5 TextView: render the background of border windows
Set the .top, .left, etc css classes and render the background
of the border windows.
Change the reftest implementation accordingly.
2014-06-15 18:57:06 +02:00
Paolo Borelli
2eeff1eed6 Add a TextView reftests checking border-windows
TextView border windows are internal windows used to draw on the gutter
of the textview (e.g. line numbers). The test uses the gmodule hook to
programmatically draw on the border-windows at each side of the textview
and compares the result with 3x3 grid of labels.
2014-06-15 18:56:30 +02:00
Paolo Borelli
2c5be3b231 TextView margin reftest
add a reftest that checks GtkTextView text margin property comparing
with the normal margin added to the widget (they are the same when there
is nothing drawn in the gutter like line numbers etc).
2014-06-15 18:15:43 +02:00
Paolo Borelli
570653354a Dist recently added reftests 2014-06-15 12:05:40 +02:00
Paolo Borelli
c184458ab3 notebook: set tab position style class on the main frame
We want to have .top etc also on the notebook frame, not only on
the header frame.
The patch includes a reftest by Benjamin.
2014-06-14 21:37:07 +02:00
Benjamin Otte
bb3174c913 reftests: Fix random failures of reftest
The reftest is testing "transparent" works as expected by drawing a
purple background once with purple and once with transparent and
expecting the same result. This works fine unless anti-aliasing happens
at rounded corners. The overdraw of the 2nd background changes the
antialiased pixels.

Fix this by explicitly setting the border radius to 0.

Also reindent the file to make it more readable.
2014-06-09 19:18:48 +02:00
Matthias Clasen
c11b7e44a0 label-sizing reftest: Hardcode ltr
This reftest doesn't work in rtl.
2014-06-03 12:28:06 -04:00
Matthias Clasen
ac59f0ac08 reftests: Add a way to hardcode text direction
Some tests don't work in rtl, so add a way to hardcode
the expected text direction. This is in preparation for
running reftests in an rtl locale.
2014-06-03 12:28:06 -04:00
Benjamin Otte
45dbd84ff3 reftests: Use "all" property in inherit-and-inital test 2014-06-03 14:35:00 +02:00
Matthias Clasen
42945f0d74 Run reftests repeatedly
Install test files that run the reftests in the
Adwaita:dark and HighConstrast themes. It works,
so why not.
2014-06-02 22:46:23 -04:00
Matthias Clasen
7f8d0552f0 Drop debug spew from installed tests
This is no longer needed, we found the problem.
2014-06-02 22:37:29 -04:00
Matthias Clasen
5bebbb06fa Add an expander reftest
This test check that resizing the window when expanding
the expander yields the same end result as having the
expander expanded to begin with. The test uses the inhibit
mechanism introduced in the previous commit.
2014-06-02 22:36:01 -04:00
Matthias Clasen
b86f5a4086 Add a way to delay snapshots in reftests
This adds an inhibit api that code from the reftest module
can use to delay the taking of the snapshot. Also refactor
the code in gtk-reftest to use the inhibit mechanism for
its own delaying of the snapshot until after the first
expose.
2014-06-02 22:35:59 -04:00
Matthias Clasen
16c89eb5f7 Forgotten file 2014-06-02 21:43:04 -04:00
Matthias Clasen
94c065d647 Add a reftest for flipping icons
Taking advantage of our new direction flipping ability.
2014-06-02 21:41:32 -04:00
Benjamin Otte
86267fd9bd gtk-reftest: Add GMODULE_CFLAGS/LIBS
They aren't included in GTK_DEP_CFLAGS/LIBS so they need to be added
manually.
2014-05-31 14:40:13 +02:00
Matthias Clasen
98cf67ddba testsuite: put installed tests in the right place
Follow the prevailing practice and put the installed tests
into $libdir/installed-tests/$PACKAGE instead of
$pkglibdir/installed-tests.
2014-05-31 00:16:07 -04:00
Matthias Clasen
5880c9e365 gtk-reftest: Don't warn needlessly
Only warn about the --direction argument if the option was
actually specified.
2014-05-30 23:30:56 -04:00
Benjamin Otte
a18ec83b3b reftests: Add reftest for direction change
This reftest makes use of the new feature to add signal handlers.

It adds a libreftest.so module containing all the code for the reftests.
When adding a test named reftest.ui, please keep code contained in a
source file names reftest.c and add that file to Makefile.am.

https://bugzilla.gnome.org/show_bug.cgi?id=730833
2014-05-31 05:19:41 +02:00
Benjamin Otte
690fb31fb4 gtk-reftest: Clarify --direction argument parameters
... and print a proper error message when the parameter is not
recognized.
2014-05-31 05:19:41 +02:00
Benjamin Otte
8bba9b6a4a gtk-reftest: Allow loading code for reftests
When connecting signal names, gtk-reftest now allows you to use a colon
in the signal handler name like so:
  module:function_name
where module is a module loaded from the same directory (or the .libs
subdirectory for compatibility with uninstalled libtool) as the running
test and the function is resolved in that module. Of course, normal
function names work as before.
2014-05-31 05:19:41 +02:00
Benjamin Otte
030140ccc4 reftests: Add a reftest with signals 2014-05-31 05:19:40 +02:00
Benjamin Otte
1e4fea7ca9 reftests: Automatically connect signals 2014-05-31 05:19:40 +02:00
Matthias Clasen
28c04f4be3 testsuite: Run reftests with GTK_DEBUG=icontheme
This will hopefully help to track down some hard-to-squash
failures that only happen in gnome-continuous.
2014-05-23 11:38:24 -04:00
Benjamin Otte
0eb62c1629 reftests: Fix icon-vfuncs reftest
The reftest broke when font size lead to labels > 16px.
2014-05-22 22:35:08 +02:00
Jasper St. Pierre
76e18de811 reftests: Remove the css-match-style-property-order test
It was testing -GtkWidget-focus-line-width, which is a dead property
we don't use anymore.
2014-05-22 14:47:55 -04:00
Jasper St. Pierre
845f29ccf5 reftests: Fix some more easy GtkButton shadow cases 2014-05-22 11:46:07 -04:00
Benjamin Otte
b1a7aa49b3 reftests: Fix background-area test
The test should include reset-to-defaults.css but apparently it is older
than that file. So it broke when buttons started using shadows.
2014-05-22 17:38:50 +02:00
Benjamin Otte
5e07b80854 reftests: Add a test for recent commits
Check that icon-shadow is not affected by -gtk-icon-transform.
2014-05-14 04:28:35 +02:00
Benjamin Otte
59b6dee480 reftest: Add tests for the new vfuncs
This test is a bit brittle because it doesn't properly rely on CSS
properties but needs to use widget style properties to turn of extra
sizing from widgets.

It might break in the future when porting widgets to draw properly.
2014-05-14 04:28:35 +02:00
Benjamin Otte
f0a5cebe23 reftests: Add a reftest for -gtk-icon-style 2014-05-14 04:28:34 +02:00
Benjamin Otte
0e462f0d2d css: Implement "all" shorthand
Here's the spec:
  http://dev.w3.org/csswg/css-cascade/#all-shorthand

Also use it in the reset-to-defaults CSS where a bunch of properties had
been missing.
2014-05-11 03:23:55 +02:00
Benjamin Otte
3a72e2fb24 css: Implement "unset"
Quoting the spec:
  If the cascaded value of a property is the unset keyword,
  then if it is an inherited property, this is treated as
  inherit, and if it is not, this is treated as initial.

Spec in question:
  http://dev.w3.org/csswg/css-cascade/

Also use unset in the reset-to-defaults.css we use to reset css in
reftests.
2014-05-11 03:23:55 +02:00
Benjamin Otte
f2258cb05c reftests: Create the surface after running the main loop
Running the main loop may cause resizes, so creating the surface based
on the size before running it seems wrong.
2014-05-11 03:23:55 +02:00
Cosimo Cecchi
ce8846521e reftests: never set interior-focus 2014-05-09 11:02:42 -07:00
Benjamin Otte
f0ebb15dab reftests: Add test for latest commit
Check that the label gets linebroken properly.
2014-04-29 19:36:26 +02:00
Benjamin Otte
01fe1282fc reftests: Remove unused argument from function 2014-03-05 21:03:36 +01:00
Benjamin Otte
2dd3226c67 reftests: Add a test for a widget stacking regression
GTK 3.10 fails to obey the stacking order when drawing widgets.

https://bugzilla.gnome.org/show_bug.cgi?id=725089
2014-02-28 03:08:11 +01:00
Benjamin Otte
7a603c6909 reftests: Add reftest for last commit
https://bugzilla.gnome.org/show_bug.cgi?id=724999
2014-02-23 15:40:46 +01:00
Benjamin Otte
118969e70a reftests: Add a reftest for the latest fix
https://bugzilla.gnome.org/show_bug.cgi?id=724742
2014-02-20 02:10:07 +01:00
Matthias Clasen
55269cdc73 Adjust action ref test to new realities
The test was using a nonexisting GtkActionBar::spacing property.
2014-02-16 23:03:38 -05:00
Matthias Clasen
a91a793468 Give up on border-image-repeat reftest 2014-02-04 13:15:46 -05:00
Matthias Clasen
1faf3a0aaa Use the memory settings backend for make check
The color chooser test is constantly running into the
problem that the custom color setting is not empty.
Avoid that by using the memory settings backend.
2014-01-21 21:17:14 -05:00
Matthias Clasen
3c12f6da1f Make the action bar reftest reliable 2014-01-14 14:05:37 -05:00
Benjamin Otte
60968a1fec reftests: Add reftest for 0px border fix
https://bugzilla.gnome.org/show_bug.cgi?id=721800
2014-01-14 03:38:04 +01:00
Matthias Clasen
851d5f1c7d Add a reftest for GtkActionBar child ordering
This shows that GtkActionBar and GtkBox treat pack-start/-end
the same.
2014-01-07 19:05:40 -05:00