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.
The progressbar is composed by two different rendered areas: the trough
(i.e. the non-filled part of the bar) and the bar itself.
The bar should be able to fill the whole height/width of the trough
without resorting to nasty hacks in the theme, and we can control the
amount of space between the bar and the trough with the padding already.
https://bugzilla.gnome.org/show_bug.cgi?id=649593
GtkAssistant is widely recognized as a butt-ugly widget.
This commit changes its style to look more modern. We
deprecate the sidebar and header image properties and
don't show them anymore. Instead, page titles are arranged
in a sidebar, with the title of the current page shown
in highlighted style.
This commit simply removes some child->parent == container checks,
to add some flexibility for containers with 'inner structure'.
If these checks are considered useful, we can bring them back
with a is_child vfunc that allows container implementations to
decided who they consider legitimate child.
This is a variant of gtk_widget_child_notify() that takes an
explicit container, instead of relying on widget->parent to
be the correct container to use.
With gtk-auto-mnemonics on, we hide mnemonics on focus out. We should also
check if the modifier is pressed on focus in and if so, show mnemonics again.
https://bugzilla.gnome.org/show_bug.cgi?id=618815
This reverts commit 1c46e04f30.
The change broke too many widgets that relied on the size being
constant. A proper fix would require letting themes override the size.
That would probably also require letting themes specify the size
relative to font size.
I was hunting a memory leak and couldn't find it; at least I'm
pretty sure all of these are OK. But document things better
for the future.
Also use g_hash_table_replace in one more case for consistency.
https://bugzilla.gnome.org/show_bug.cgi?id=649457
If we have a toplevel, and not a popup window, do wait an additional
0.5s to give the WM/server enough time to actually create the window.
This is a hack and there should be a better solution. But it works.
Please use POPUP windows for tests unless the test must use toplevel
windows.
It could be the case that gdk_window_set_cursor() is called on
pointers not yet known to the device tracking code in GdkDisplay,
so update the cursor on all master pointers.
The code actually updating the cursor for the given window has
been refactored out to gdk_window_set_cursor_internal(), used
in gdk_window_set_device_cursor() as well, which makes it handle
root/foreign windows too.
https://bugzilla.gnome.org/show_bug.cgi?id=649313
Checks that the size requests for labels are as they should be for
required and natural size given various combinations of wrap, ellipsize,
width-chars and max-width-chars.
See
http://mail.gnome.org/archives/gtk-devel-list/2011-April/msg00036.html
for the discussion spawning this test.
Add a new test runner supposed to do a lot of generic tests. Run it like
this:
./gtk-reftest [OPTIONS] TESTFILE [TESTFILES...]
where FILE is a GtkBuilder ui file to run.
For a general test named "test", you want to have the following files:
1) test.ui
2) test.ref.ui
3) test.css (optional)
The test will then check that test.ui and test.ref.ui are rendered
identically with the provided css.
In detail, for every provided TESTFILE the test runner will:
1) Add the css to the default screen
2) Load the test.ui file and the test.ref.ui file
3) Grab the first GtkWindow subclass widget
4) gtk_widget_show() it and take a snapshot image of its contents into
a cairo surface.
5) Compare the two images to be bitwise identical. If they are not, a
diff image will be created hilighting the differences.
6) Save the images as png files to the output directory named:
- test.out.png (rendering of test.ui)
- test.ref.png (rendering of test.ref.ui)
- test.diff.png (optional, differences from step 5)
7) Fail the test if the two images are not bitwise identical
Credit for the idea of reftests goes to Mozilla and in particular David
Baron. For a larger introduction of why reftests are useful, see
http://weblogs.mozillazine.org/roc/archives/2008/12/reftests.html