Commit Graph

44217 Commits

Author SHA1 Message Date
Lars Uebernickel
71b31c84c0 gdkpixbuf-drawable: reinstate accidentally removed line 2015-10-27 13:38:14 +01:00
Lars Uebernickel
657a43e54e gdk_pixbuf_get_from_window: honor device scale
gdk_pixbuf_get_from_window() paints the given window onto a new cairo
surface. Create that new surface with the same device scale as the
window so that the result is not scaled down on hidpi screens.

https://bugzilla.gnome.org/show_bug.cgi?id=757147
2015-10-27 09:38:52 +01:00
Marek Černocký
46e834cf3e Updated Czech translation 2015-10-27 07:38:21 +01:00
Matthias Clasen
ed00d86496 inspector: Allow editing css node properties
This reuses the property editor infrastructure from the
property list pages. Good that css nodes are objects.
2015-10-26 23:39:51 -04:00
Matthias Clasen
6852a1eef9 inspector: Support editing interned string properties
Sadly, interned string properties cannot be handled generically
at all - GObject insists on inserting a strcpy in any attempt
to set a string property with generic api, destroying the
internedness of the string.

Therefore, we have to special-case GtkCssNode in the property
editor code :-(
2015-10-26 23:39:51 -04:00
Matthias Clasen
b7d001e613 Add some api annotations
Nothing is using the /*interned*/ annotations currently,
but if we are doing this, we should be consistent.
2015-10-26 23:39:50 -04:00
Benjamin Otte
a648afae12 widget: Add name to widget paths
This changes widget paths for widgets with a CSS name to return that CSS
name, now that we have added API for it.
This means that style properties are now matches using the CSS name.

Also fix the theme to use the correct name when matching style properties.
2015-10-27 03:13:42 +01:00
Benjamin Otte
517cea36ed cssmatcher: Actually match names for widget paths
The type is always 0 when we use names. So this would always return
FALSE. Oops.
2015-10-27 03:13:42 +01:00
Matthias Clasen
d717afd4d4 entry: properly update css subnode state
Update the state of the css subnodes for icons when
appropriate, and avoid calling set_state after save_to_node.
2015-10-26 22:09:07 -04:00
Matthias Clasen
c72d094ae0 entry: Use better element name for progress
Change the name of the CSS subnode for progress rendering from
progressbar to progress. This will align better with GtkProgressBar.
2015-10-26 21:34:16 -04:00
Robert Ancell
aefa1ba611 gdk: Deprecate gdk_display_get_screen 2015-10-27 14:17:52 +13:00
Jonas Ådahl
db04c1eda7 wayland: Don't use GTK symbols from GDK
GTK_WINDOW_POPUP sets the GdkWindow type to GDK_WINDOW_TEMP, so use
that in GDK, not the GTK symbol which doesn't exist there.
2015-10-27 09:02:35 +08:00
Benjamin Otte
101df329ae API: Add gtk_widget_path_iter_set_object_name()
... and gtk_widget_path_iter_get_object_name(). This allows applications
that still use widget paths to use the new object names to get the
correct styling.

Mutter and webkit-gtk are examples here.
2015-10-27 01:44:50 +01:00
Jonas Ådahl
aedd193c69 GtkTreeView: Rework the search window hack so it also works on Wayland
The search window of a tree view was implemented by showing without
making it visible by by positioning it outside the screen edge. This is
not possible on Wayland, so implement another method for being able to
enter text into a non-visible entry.

The new method is implemented by, before showing the window, pass the
key event directly to the IM context backing the entry. If the key
event triggered the context to commit new text or change the preedit
content, the search window is shown, and from that point the key events
are forwarded directly to the entry widget.

https://bugzilla.gnome.org/show_bug.cgi?id=756780
2015-10-27 08:41:02 +08:00
Jonas Ådahl
bcb28adba3 wayland: Map UTILITY hinted popup windows as subsurfaces
Currently used by GtkTreeView to map windows without changing focus. We
can't map this as a popup, because popup implies focus change.

https://bugzilla.gnome.org/show_bug.cgi?id=756780
2015-10-27 08:41:02 +08:00
Jonas Ådahl
97dbef451e GtkTreeView: Make a search window destroy helper
https://bugzilla.gnome.org/show_bug.cgi?id=756780
2015-10-27 08:41:02 +08:00
Jonas Ådahl
e25ea62f22 wayland: Don't try to use subsurfaces as popup parents
If a GtkMenu (or something else that is mapped as a xdg_popup) tries to
use a subsurface window as a parent, it will be terminated by the
compositor due to protocol violation. So to avoid this, if a parent
window is not a xdg_popup or xdg_surface, i.e. a wl_subsurface, then
traverse up the transient parents until we find the right popup parent.

https://bugzilla.gnome.org/show_bug.cgi?id=756780
2015-10-27 08:41:02 +08:00
Jonas Ådahl
49798754e6 wayland: Make window type conditions switches
In order to make it easier to add/remove in future commits.

https://bugzilla.gnome.org/show_bug.cgi?id=756780
2015-10-27 08:41:02 +08:00
Jonas Ådahl
2eb7d7476b GtkTreeView: Use more consistent search window naming
Instead of alternating between search dialog and search window, use
search window everywhere.

https://bugzilla.gnome.org/show_bug.cgi?id=756780
2015-10-27 08:41:02 +08:00
Matthias Clasen
76619cf1ae entry: Bring back icon padding
Not sure why this is necessary now, but it is.
2015-10-26 16:51:28 -04:00
Matthias Clasen
ed8641ff26 entry: Only set one of the .left, .right style classes
We were not removing the old style class when adding a new one.
2015-10-26 15:28:50 -04:00
Matthias Clasen
8db30aa9a0 testassistant: Add another example
This adds a test involving removing and re-adding pages, to
help with
https://bugzilla.gnome.org/show_bug.cgi?id=756385
2015-10-26 09:16:38 -04:00
Matthias Clasen
e28b3d1296 assistant: Handle page-type and title changes properly
We need to update our state when a pages' type or title changes.
2015-10-26 09:01:07 -04:00
Matthias Clasen
6efbf329c3 shortcuts: Cosmetic change
The .flat style class is controlled by the relief property,
so just use that instead of manually setting style classes.
2015-10-26 07:23:07 -04:00
Matthias Clasen
953aa45c04 label docs: Mention common style classes
Mention some of the style classes that are commonly used
with labels.
2015-10-26 07:23:07 -04:00
Olivier Fourdan
305b34aa15 GtkWindow: fix move/get position with CSD
Take into account and compensate for the size of the client side
decorations widgets in gtk_window_move() and gtk_window_get_pos()
including gravity.

Bugzilla: https://bugzilla.gnome.org/show_bug.cgi?id=756618
2015-10-26 08:40:36 +01:00
Olivier Fourdan
3450f53907 GtkWindow: add up CSD size in gtk_window_resize()
When client side decoration is used, the size passed to
gtk_window_resize() or retrieved from gtk_window_get_size() for top-
level windows also accounts for the client side decorations widgets
such as the title bar or the shadow borders.

Add up the size of these additional controls to the given size to get
the size expected.

Bugzilla: https://bugzilla.gnome.org/show_bug.cgi?id=756618
2015-10-26 08:40:36 +01:00
Marek Černocký
2258fe576f Updated Czech translation 2015-10-26 07:56:07 +01:00
Matthias Clasen
bf65b06781 HighContrast: Don't use GtkInfoBar type name
We have a proper element name for it now.
2015-10-25 17:19:34 -04:00
Matthias Clasen
91ec104dd3 Adwaita: Don't use GtkInfoBar type name
We have a proper element name for it now.
2015-10-25 17:19:01 -04:00
Matthias Clasen
f1248ccea4 infobar: Add a name to the css node
This lets us avoid the type name in css.
2015-10-25 17:18:20 -04:00
Matthias Clasen
2de0f06af9 HighContrast: Update separator rendering
Adapt HighContrast t othe changes in the pre-previous commit.
2015-10-25 16:29:11 -04:00
Matthias Clasen
0ba03aac16 Adwaita: Update separator styling
Adapt Adwaita to the changes in the previous commit.
2015-10-25 16:28:38 -04:00
Matthias Clasen
2eb6599b29 separator: Use the element name separator
Switch GtkSeparator from using the .separator style class to
using the element name separator for its css node.
2015-10-25 16:27:44 -04:00
Matthias Clasen
aa67ad0011 Adwaita: Update accel label styling
Adapt Adwaita to the changes in the previous commit.
2015-10-25 15:45:13 -04:00
Matthias Clasen
caa6fb0732 accel label: Use a css node for the accelerator
Use a permanent subnode with name accelerator instead of the
.accelerator style class.
2015-10-25 15:45:13 -04:00
Matthias Clasen
2b20bd54c5 HighContrast: Update spinner rendering
Adapt HighContrast to the changes in the pre-previous commit.
2015-10-25 15:45:13 -04:00
Matthias Clasen
bd80b1d037 Adwaita: Update spinner styling
Adapt Adwaita to the changes in the previous commit.
2015-10-25 15:45:13 -04:00
Matthias Clasen
9269525f07 spinner: Use the element name spinner
Switch GtkSpinner from using the .spinner style class to
using the element name spinner for its css node.
2015-10-25 15:45:13 -04:00
Rico Tzschichholz
3011820485 docs: Add index for 3.20 api 2015-10-25 19:36:38 +01:00
Matthias Clasen
7c7fde136e Translate GDK_KEY_KP_Decimal according to locale
It makes sense that you should be able to type numbers that are
correctly formatted and parsable according to the current locale,
using just the keypad. This patch makes it so by translating
GDK_KEY_KP_Decimal to the decimal separator for the current locale,
instead of hardcoding a '.'.

https://bugzilla.gnome.org/show_bug.cgi?id=756751
2015-10-25 13:59:48 -04:00
Matthias Clasen
64c5b97be8 quartz: Don't use the instancetype keyword
gdkcursor-quartz.c uses the instancetype keyword, which doesn't seem to
be supported in the version of Objective C that Snow Leopard uses.
Replacing that keyword with the thing it represents makes it build.

Patch by Ryan Hendrickson,
http://bugzilla.gnome.org/show_bug.cgi?id=756770
2015-10-25 13:26:01 -04:00
Matthias Clasen
f55e3f7eda inspector: Be more careful with dead objects
gtk_inspector_object_tree_find_object accesses the type information
of the object, so we can't safely use it on an already decaying
object when we get a weak notify. Instead just walk the tree and
compare pointers, that is safe.

https://bugzilla.gnome.org/show_bug.cgi?id=756852
2015-10-25 13:11:17 -04:00
Matthias Clasen
4305aa1def inspector: Improve css node UI
All the other object pages have a title, this one was missing it.
Add one, so the page fits in with the rest.
2015-10-25 09:20:43 -04:00
Matthias Clasen
1e112ca75e inspector: Allow editing strv-valued properties
These do occur in some places, and we can easily allow editing
them.
2015-10-25 02:14:04 -04:00
Marek Černocký
9d81f3f6f1 Updated Czech translation 2015-10-25 00:19:25 +02:00
Matthias Clasen
e440050134 Fix the build 2015-10-24 17:04:38 -04:00
Matthias Clasen
f1b7560938 notebook: Document css nodes and style class
This will have to be updates as we do further changes to the
way GtkNotebook does its rendering.
2015-10-24 10:54:56 -04:00
Matthias Clasen
8917ee5373 notebook: Drop unneeded code
We no longer need to set the position classes on the main css node,
since they are already set on the per-tab subnodes.
2015-10-24 10:39:18 -04:00
Matthias Clasen
9f738da11b HighContrast: Update notebook styling
The switch from .notebook to notebook requires minor changes,
such as moving the style properties into a separate selector.
2015-10-24 10:39:18 -04:00