Benjamin Otte
4edb3f08e4
reftests: fix background-area reftest after the last commit
2011-06-15 11:25:26 -04:00
Benjamin Otte
d3535ff6ce
tests: Add tests for font-family
...
This readds the tests now that font-family works again. They were
previously removed when font-family support was backed out due to bugs.
2011-06-15 12:57:21 +02:00
Matthias Clasen
37167ec458
Make this code more meaningful
2011-06-14 21:18:08 -04:00
William Jon McCann
be7f734aff
tests: Add simple test for image clipboard
2011-06-14 16:06:33 -04:00
Benjamin Otte
f4a6ef0d50
tests: Add a CSS test for color parsing errors
...
In [particular check for the fix in the last commit.
2011-06-13 15:01:52 +02:00
Benjamin Otte
016e0c1a3e
reftests: Check that the default border color is the foreground color
2011-06-13 15:01:52 +02:00
Matthias Clasen
d9fa5b342b
Forgotten file
2011-06-13 07:33:47 -04:00
Matthias Clasen
2ce9ff2d6a
Remove broken font-family css test
2011-06-13 06:56:12 -04:00
Ignacio Casal Quinteiro
cfb2a45f9a
overlay: add initial version of gtkoverlay
2011-06-12 23:27:18 -04:00
Javier Jardón
85747da972
tests: use GdkRGBA instead GdkColor
2011-06-13 00:24:53 +01:00
Benjamin Otte
a536a50dbd
reftests: Add reftest for unresolvable properties
2011-06-11 10:41:17 +02:00
Benjamin Otte
a1d19be950
reftests: Add a test for inset box-shadow
...
This test is copied from the CSS spec. The reference is very sensitive
to the rendering algorithm in use, because the rounded corners have
semi-transparent pixels. It might be necessary to update them in the
future.
2011-06-11 09:29:43 +02:00
Benjamin Otte
281ce813fc
reftests: Add background-area reftest
...
Checks the fix from last commit: background area is supposed to be the
border box.
2011-06-11 09:29:32 +02:00
Benjamin Otte
7adfd8a0f5
reftests: Remove unused file from EXTRA_DIST
2011-06-10 16:26:39 +02:00
Benjamin Otte
77c102ae6e
testtreeview: Don't use deprecated classes to make things interesting
2011-06-09 06:21:11 +02:00
Benjamin Otte
6114b06b3b
testgtk: Fix deprecation
2011-06-09 06:20:42 +02:00
Benjamin Otte
53e3f43217
reftests: ADd test for overlapping border-image slices
2011-06-09 05:51:55 +02:00
Benjamin Otte
9affa9fc4d
reftests: Add border-image-repeat
...
Tests that border-image-repeat is rendered correctly.
The reftest is done via toolbars stuffed into a GtkFixed using
background-image and images tuned for it.
2011-06-09 05:51:54 +02:00
Cosimo Cecchi
83a383e4ba
reftests: add reftests for border-image with gradient and url sources
...
https://bugzilla.gnome.org/show_bug.cgi?id=651194
2011-06-09 05:51:54 +02:00
Matthias Clasen
d8b3bfe778
Use separators instead of hseparators
2011-06-07 21:29:01 -04:00
Matthias Clasen
c134446230
Use boxes instead of hboxes
2011-06-07 19:56:27 -04:00
Matthias Clasen
682296391f
tests: Use boxes instead of vboxes
2011-06-07 18:39:15 -04:00
Matthias Clasen
e7f88838f6
Remove an unneeded include
2011-06-07 18:32:24 -04:00
Matthias Clasen
d4224cd325
GtkGrid: Fix a size allocation problem
...
We need pay attention the the request mode when doing size allocation.
The code was using request mode for requisition, but orientation
for allocation.
Also add a reftest that exhibits the issue, courtesy of
Benjamin Otte.
2011-06-07 11:05:50 -04:00
Javier Jardón
32ef28bc85
Replace gtk_misc_set_padding() with GtkWidget:margin properties
...
https://bugzilla.gnome.org/show_bug.cgi?id=651605
2011-06-02 18:49:54 +02:00
Benjamin Otte
b5544f5514
tests: Add tests for font-family
2011-06-02 02:03:52 +02:00
Benjamin Otte
bda86b5dd3
tests: Add a test for border-radius handling
2011-06-02 02:03:52 +02:00
Benjamin Otte
a105edbf78
tests: Add a cute demo and test app for the new box css
...
It contains a live editor for CSS, that thing finds lots of bugs...
2011-06-02 02:03:51 +02:00
Benjamin Otte
bdb8c64dd0
reftests: Add a reftest setting all colors to "none"
2011-06-02 02:03:51 +02:00
Benjamin Otte
be71ea611b
tests: Add CSS test for the last two bugs
...
And it's a 1-byte file, too!
2011-06-02 02:03:51 +02:00
Benjamin Otte
43cca78a98
reftests: Test new pseudo-class support in GtkBox
2011-06-02 02:03:50 +02:00
Matthias Clasen
60081644ae
Silence a theme parser error
2011-06-01 18:40:11 -04:00
Benjamin Otte
2108e42306
tests: Make variable const to silence gcc
2011-06-01 16:52:34 +02:00
Javier Jardón
e5c7daa828
tests: avoid boxed structs copying where possible
...
Use the GtkStyleContext accessors for boxed properties where possible,
to reduce allocations.
2011-05-31 19:12:24 +02:00
Benjamin Otte
2881930e68
tests: Remove unused variables
2011-05-27 16:11:09 +02:00
Benjamin Otte
8c4653c4f2
tests: Make forcing of class registers work without gcc warnings
2011-05-27 16:11:09 +02:00
Matthias Clasen
cf86c7c9bb
Move demos around
...
The pixbuf-demo gets its own subdirectory, the other small
tests move from demos/ to tests/.
2011-05-26 00:32:31 -04:00
Benjamin Otte
a21042c156
tests: Add simple CSS test for widget style properties
2011-05-23 15:56:09 +02:00
Benjamin Otte
0c7e5a51f3
reftests: sort EXTRA_DIST in Makefile
2011-05-22 05:56:12 +02:00
Benjamin Otte
4d92835997
reftests: Add a reftest to check shorthands do work
...
Checks shorthands are properly unpacked in the CSS and that they indeed
set all relevant properties. Or at least border-width does.
2011-05-22 05:56:12 +02:00
Benjamin Otte
ef51b5be76
reftests: Add label-shadows test
...
Tests shadows work properly for rotated labels
2011-05-22 05:56:12 +02:00
Benjamin Otte
bd610582b8
tests: Add parser test for shorthands
2011-05-22 05:56:11 +02:00
Benjamin Otte
d7c9d8ce15
tests: Add forgotten file
...
File was forgotten in 8fd6bd323c
2011-05-21 22:48:52 +02:00
Benjamin Otte
7a0600644c
tests: Add missing CSS test
2011-05-19 03:16:03 +02:00
Cosimo Cecchi
d392af2e36
reftests: Check that inherited properties work
2011-05-18 22:17:59 +02:00
Benjamin Otte
25c396409c
reftests: Check style property order
...
Ensure that style properties are read in the correct order, by having a
property twice with vastly different values.
2011-05-18 22:17:58 +02:00
Benjamin Otte
1400644069
reftests: Add a test ensuring selectors don't match children
...
Previously, the selector "Foo" would not only match Foo widgets, but
also all widgets that are descendants of Foo.
2011-05-18 22:17:57 +02:00
Benjamin Otte
f3ed498c5b
reftests: Add a test for descendant CSS selectors match
...
In widget hierarchy like "Foo Bar Bar Baz", we want the selector "Foo >
Bar Baz" to match, because it matches the elements 1, 2 and 4.
Previously, the selector only matches the Bar at position 3 and then
failed because it wasn't preceded by a Foo.
2011-05-18 22:17:56 +02:00
Benjamin Otte
806c804271
reftests: Add a test that checks that * matches regions
2011-05-18 22:17:56 +02:00
Benjamin Otte
dda83e2f98
reftests: Unset background-image in CSS of test
...
Otherwise the test screws up when it's set
2011-05-18 22:17:56 +02:00
Benjamin Otte
b8eac1e130
reftests: Add a check for matching regions only once
2011-05-18 22:17:56 +02:00
Benjamin Otte
710caeb512
tests: Add a test for enum values
2011-05-18 22:17:56 +02:00
Benjamin Otte
8ca799cc39
reftests: Add a test for matching by class
2011-05-18 22:17:56 +02:00
Benjamin Otte
78de3e8180
reftests: Add a test for matching by name
2011-05-18 22:17:56 +02:00
Benjamin Otte
269fe0f347
reftests: Add a test for matching by subtype
2011-05-18 22:17:56 +02:00
Benjamin Otte
90caef4abe
reftests: Add test to check that matching by type works
2011-05-18 22:17:56 +02:00
Benjamin Otte
174cfff50f
tests: Add a test to ensure we handle unknown pseudo-classes correctly
...
1) We want to throw an unknown value
2) We want to skip the whole rule
2011-05-18 22:17:56 +02:00
Benjamin Otte
e7aa125eb0
tests: Add a test for all selector combination
...
The test contains an error where we complain about a duplicate value for
":hover:hover"
2011-05-18 22:17:56 +02:00
Benjamin Otte
ce44c95ce8
tests: Be more verbose in error messages.
...
Also, it makes it easier to copy/paste diffs from the message log...
2011-05-18 22:17:55 +02:00
Benjamin Otte
dd78ab5a2f
tests: Add test that ensures we properly parse the color red
2011-05-18 22:17:55 +02:00
Benjamin Otte
42fb004dfc
tests: Add another parsing test from the css spec
2011-05-18 22:17:55 +02:00
Benjamin Otte
3f07482b10
tests: Add parsing test from the css spec
2011-05-18 22:17:55 +02:00
Benjamin Otte
2b807e574d
tests: Make the parser fail without assertions
...
Use the new g_test_fail() function. This way, the testsuite usually
doesn't crash, but actually finishes.
2011-05-18 22:17:55 +02:00
Benjamin Otte
7ccb9db79e
css: Rewrite the parser
...
Instead of relying on GScanner and its idea of syntax, code up a parser
that obeys the CSS spec.
This also has the great side effect of reporting correct line numbers
and positions.
Also included is a reorganization of the returned error values. Instead
of error values describing what type of syntax error was returned, the
code just returns SYNTAX_ERROR. Other messages exist for when actual
values don't work or when errors shouldn't be fatal due to backwards
compatibility.
2011-05-18 22:17:55 +02:00
Benjamin Otte
058bbb2aec
tests: Add a test for importing nonexistant files
2011-05-18 21:58:47 +02:00
Benjamin Otte
c7ef2225b7
tests: Add tests for cyclic imports
2011-05-18 21:58:47 +02:00
Benjamin Otte
427c97a635
tests: Add test for recursively importing an identical file
2011-05-18 21:58:46 +02:00
Benjamin Otte
77b40f2dcd
tests: Order files by name before adding them as tests
...
Ensures that the order of tests is not dependant on your hard disk.
2011-05-18 21:58:46 +02:00
Benjamin Otte
796d593cc1
tests: Make css-parser test take files as argument
...
Takes the css files to be tested as argument and runs with it.
2011-05-18 21:58:45 +02:00
Benjamin Otte
1f4b09b2fb
tests: Add a test for border parsing
2011-05-18 21:58:45 +02:00
Benjamin Otte
195589feac
tests: Add new test checking weird behavior for declarations
2011-05-18 21:58:44 +02:00
Benjamin Otte
fbf658b04e
tests: Add CSS integer parsing tests
2011-05-18 21:58:44 +02:00
Benjamin Otte
d28816bdba
tests: Add test for booleans to CSS tests
2011-05-18 21:58:44 +02:00
Benjamin Otte
be1da7ef92
tests: (Try to) print the actual enum value in the errors file
...
Instead of gtk-some-error-quark 5, print
GTK_SOME_ERROR_SOMETHING_FAILED.
2011-05-18 21:58:44 +02:00
Benjamin Otte
71b18a9006
test: Add a bunch of default properties to the CSS parser
...
One of each type, so that we can test the parsing of them.
2011-05-18 21:58:44 +02:00
Benjamin Otte
f1307ef428
tests: Make CSS parser pass NULL as error.
...
We are trapping errors via signals now.
2011-05-18 21:58:44 +02:00
Benjamin Otte
2d0162c97b
tests: Check errors in css test
2011-05-18 21:58:44 +02:00
Benjamin Otte
35c9650752
tests: Change the way the code does diffs
...
Use a temp file for intermediate storage and properly unlink that
tempfile after the diff is done.
2011-05-18 21:58:44 +02:00
Benjamin Otte
c18dc15694
tests: Add test for auto-closing at end of file
2011-05-18 21:58:43 +02:00
Benjamin Otte
224d65032e
tests: Add CSS test checking that we don't need a semicolon
2011-05-18 21:58:43 +02:00
Benjamin Otte
8fd6bd323c
tests: Add two simple css tests
2011-05-18 21:58:43 +02:00
Benjamin Otte
64fd32cdef
tests: Add a test for the CSS parser
...
Tests in the parser need 1 or 2 files:
1) test.css
2) test.ref.css (optional, defaults to test.css)
The test instantiates a CSS provider, loads test.css, then dumps the
loaded file to test.out.css and then checks that that file matches
test.ref.css. If not, it dumps a diff between those two to the log and
fails.
You want to run the test with --verbose to get the output dumped to
stdout.
2011-05-18 21:58:43 +02:00
Benjamin Otte
c2f23ccd23
reftests: Add a shell script to create tests
...
See the documentation in the script.
Tests are not yet added as the output from the 2 included scripts
doesn't match and the intended reference output first needs to be agreed
on.
2011-05-13 02:46:15 +02:00
Benjamin Otte
d20aa1f8dc
reftests: Add a test for the label fix
2011-05-12 23:40:26 +02:00
Matthias Clasen
7b6e3be4a7
Another grid spacing reftest
...
This one checks that empty rows/columns don't affect layout.
2011-05-11 19:52:33 -04:00
Matthias Clasen
87e46bfaa9
Add some reftests comparing aspects of grid and box spacing
2011-05-11 13:48:00 -04:00
Benjamin Otte
d01d90fccd
reftests: Add test for undersized children of GtkPaned
...
Tests the recent fixes done in 206b9f940d
and 6bda6f0c58
2011-05-10 01:39:14 +02:00
Benjamin Otte
b6c8671fde
reftests: Add CSS file for alignment test
...
We need to force arrow scaling to 1.0 to get the alignment right.
2011-05-09 13:25:36 +02:00
Matthias Clasen
432e89685f
Fix up the misc-alignment test
...
The new-style ui file had some left-over GtkMisc properties
in it.
2011-05-08 21:28:36 -04:00
Benjamin Otte
42450cacd9
reftests: Modify test to ensure identical output
...
GtkArrow and the align properties use different methods (float vs int)
to center the arrow. If the size of the arrow is odd, this will cause a
rendering that differs by half a pixel. So we request an even size for
both the arrow and the container and everything works out.
2011-05-09 01:36:00 +02:00
Benjamin Otte
3c2105c9cd
reftests: Add misc-alignment test to Makefile
2011-05-09 01:12:29 +02:00
Benjamin Otte
50c36f38ff
reftests: Actually add toplevel vs popup testcase
...
Adds missing files from 79d1b11d0b
and
reverts eba4ca3e66
.
2011-05-09 01:10:13 +02:00
Matthias Clasen
eba4ca3e66
Drop missing tests
2011-05-07 00:03:13 -04:00
Matthias Clasen
1d647df176
Add a lock button widget
...
This is a special-purpose button that can be used together with
GPermission objects to control the sensitivity of system settings.
Suitable permission objects can e.g. be obtained from PolicyKit.
http://bugzilla.gnome.org/show_bug.cgi?id=626457
2011-05-06 22:44:38 -04:00
Tristan Van Berkom
9fd1feb2a8
Adding more traditional checkered background to testtextview.
2011-05-06 17:05:35 -04:00
Tristan Van Berkom
cefb950110
Added internal GdkRGBA support for GtkTextTag::paragraph-background-rgba
...
Added the remaining implementation bits for rendering paragraph backgrounds
with rgba values and updated the test case.
2011-05-06 17:05:34 -04:00
Tristan Van Berkom
d399a4acab
Added GdkRGBA properties to GtkTextTag.
...
This now allows text view to render text with alpha values in
the text foreground and backgrounds, the work is almost complete,
currently the error-underline-color is still a GdkColor style property
and since we use only GdkRGBA for rendering it needs to be converted
and applied, probably a new rgba version of the style property should
also be introduced.
This commit adds tests/testtextview that must be run from the tests/
directory to show translucent text in action.
2011-05-06 17:05:10 -04:00
Cosimo Cecchi
297e739395
testassistant: don't use deprecated functions
2011-05-06 16:08:42 -04:00
Matthias Clasen
e8413cc28e
testassistant: some more tests
2011-05-06 14:56:36 -04:00
Matthias Clasen
6c1133c885
Add an alignment property test
...
This test compares GtkAlignment properties and GtkWidget margin and
alignment properties.
2011-05-05 22:21:59 -04:00