Commit Graph

5701 Commits

Author SHA1 Message Date
Matthias Clasen
d6cc9bd7cb Add version macros for 3.14 2014-04-06 01:27:01 -04:00
Matthias Clasen
98ae6fd746 docs: More uniform formatting
Make all occurrences of hex in gdkcolor.c use “.
2014-04-04 01:25:14 -04:00
Volker Sobek
f8b6bfe744 docs: Remove '\' escape character from literals
commit 7f6a964c47 replaced entities, but
escaped the replacement text also inside literals, which resulted in the
escaping '\' to also appear in the documentation.

https://bugzilla.gnome.org/show_bug.cgi?id=727322
2014-04-04 01:24:35 -04:00
Руслан Ижбулатов
0d53a581b4 Give CC to instrospection scanner
Introspection scanner-generation script gets compiler from the CC
environment, we need to set it.

https://bugzilla.gnome.org/show_bug.cgi?id=722817
2014-04-01 11:50:35 +00:00
Руслан Ижбулатов
4b80aa1c05 Introspection for gdk-win32
https://bugzilla.gnome.org/show_bug.cgi?id=722817
2014-04-01 11:24:39 +00:00
Matthias Clasen
bf8a169cb9 docs: Another round of markup removal 2014-03-29 00:24:15 -04:00
Matthias Clasen
28377d4ffb Docs: remove some leftover markup 2014-03-28 23:51:52 -04:00
Chun-wei Fan
9e686d1fb5 gdkproperty-win32.c: Fix gtk-font-name handling
...on Windows 8+ and when the system setting for non-Unicode programs do
not match the language version of Windows by falling back to using Pango.

This ensures that the correct font is used during these scenarios, so that
we minimize the risk of seeing garbled characters for texts that the system
code page does not support due to system peculiarties.  There might be a
way to support gtk-font-name handling using the native Windows APIs
directly on Windows 8+, but that needs to be investigated.

https://bugzilla.gnome.org/show_bug.cgi?id=726298
2014-03-28 21:06:14 +08:00
Bastien Nocera
f71f7215ab all: Name more idles and timeouts
Following up from 438cd857c4,
name more timeouts and idles.

The original grep was missing checking for gdk_threads_add_*()
functions (at least for some of the files).

https://bugzilla.gnome.org/show_bug.cgi?id=726870
2014-03-26 20:09:30 -04:00
Matthias Clasen
6cc0130147 wayland: Mark ourselves as not supporting compositing
The compositing that is meant here is really specific to the
X11 Composite extension, and does not apply to Wayland.

This is very rarely used functionality anyway, and none of
the other backends support it.
2014-03-24 12:49:32 -04:00
Matthias Clasen
a8036a5143 wayland: Fix northeast resizing
Surprisingly, the same corner that was broken for resizing under
X is also broken under Wayland, for an entirely different reason.
2014-03-21 18:24:38 -04:00
Pierre-Eric Pelloux-Prayer
ad39298f6d broadway: make sure color/delta run length do not overflow
Fixes bug 723045.
2014-03-21 21:45:04 +01:00
Jasper St. Pierre
084859d150 wayland: Mark ourselves as not supporting bounding shapes
Theoretically, we apply the shape mask client-side ourselves
with an ARGB32 pixmap and intersect it to get a union shape,
but I don't particularly care enough to write that code.

Realistic application code using bounding shapes in 2014 is
quite rare.
2014-03-20 14:28:25 -04:00
Jasper St. Pierre
3472235232 wayland: Add support for input regions 2014-03-20 14:28:24 -04:00
Jasper St. Pierre
385b55f203 wayland: Refactor how opaque region is handled
Move to a sync system just like the rest of the properties.
2014-03-20 14:28:24 -04:00
Matthias Clasen
36b3b9cbeb x11: Allow unmaximizing from tiled state too
This lets us unmaximize a half-tiled csd window on a touch system.
2014-03-17 18:18:53 -04:00
Jasper St. Pierre
16b5504eb9 wayland: Remove cruft in set_keep_above / set_keep_below
It's been decided: these will most likely never be supported on
Wayland, so remove the "stub" implementation of them.
2014-03-17 15:51:46 -04:00
Jasper St. Pierre
4eb7dac75b wayland: Fix get_frame_extents
We need to traverse up the hierarchy for windows here. Just use
our existing helper method for this.
2014-03-17 15:51:46 -04:00
Jasper St. Pierre
efdd68b3b0 Implement get_root_origin generically for all backends
It seems that some backends implemented get_root_origin wrong
and returned the client window coordinates, not the frame window
coordinates. Since it's possible to implement generically for all
windows, let's do that instead of having a separate impl vfunc.
2014-03-17 15:51:46 -04:00
Jasper St. Pierre
0320c3be8e wayland: Fix "fake root" coords
We were incorrectly summing up our own window over and over
rather than the coordinates of the parent windows.
2014-03-17 15:36:41 -04:00
Jasper St. Pierre
494e253e47 wayland: Add a giant doc comment explaining "fake root" coordinate space 2014-03-17 15:36:41 -04:00
Jasper St. Pierre
92833a0b82 wayland: Properly apply the fake root offset to event coordinates
GdkEvent's x_root and y_root values should be in the same "fake root
window" coordinate space as gdk_window_get_root_coords.
2014-03-17 15:36:41 -04:00
Jasper St. Pierre
35a1f49db5 wayland: Fill in x_root / y_root of events properly
Lots of code, including dragging code in GtkWindow, use these
fields. Setting them to 0 causes lots of strange and weird bugs.

Use the same "hack" from query_device_state of just using
win_x / win_y for now. We'll convert this to the proper fake root
coordinate system used by get_root_coords in the next commit.
2014-03-17 15:36:41 -04:00
Carlos Garnacho
41b73e409f x11: Implement "drag to top to maximize" gesture on emulated window dragging
And the counterpart to unmaximize when dragging a maximized window, if
touch devices aren't going to use EWMH moveresize, having this one at least
makes things feel a bit less awkward.

https://bugzilla.gnome.org/show_bug.cgi?id=709914
2014-03-17 18:19:44 +01:00
Carlos Garnacho
d1d4c602e0 x11: Fallback to emulated window dragging for touch devices
Sadly, EWMH moveresize mechanism can't work with touch devices for two
reasons:

1) As a mutter implementation detail, the device is queried in order
to check whether the dragging button is still pressed. Touch devices
won't report the button 1 being pressed through pointer emulation.
2) Even bypassing that check, on X11 touch events are selected prior
to sequences being started, either through XISelectEvents or
XIGrabTouchBegin, no late registering through active grabs is allowed,
as WMs do on reaction to EWMH moveresize messages.

So for the time being, make touch devices fallback on emulated window
dragging, which at least allows for moving windows.

https://bugzilla.gnome.org/show_bug.cgi?id=709914
2014-03-17 18:19:44 +01:00
Jasper St. Pierre
c737045462 xdg-shell: Update to latest state change mechanism 2014-03-12 23:53:04 -04:00
Matthias Clasen
5b2236e3d7 Add a Since annotation to gdk_device_get_last_event_window 2014-03-12 23:04:37 -04:00
Owen W. Taylor
40b6d907bf Use GDK's current window tracking when synthesizing events in GTK+
Add gdk_device_get_last_event_window(), and use to implement the window
tracking we need for synthesizing crossing events for sensitivity changes
and gtk grabs, rather than keeping the information in qdata and updating
it based when GTK+ gets events.

https://bugzilla.gnome.org/show_bug.cgi?id=726187
2014-03-12 23:03:53 -04:00
Owen W. Taylor
1ff2161431 gdk_cairo_surface_create_from_pixbuf: Add missing (allow-none) annotation
The window is allowed to be %NULL
2014-03-12 11:50:55 -04:00
Ryan Lortie
ff0c470e34 broadway: remove unused libcrypt
eb1ab0dac2 removed support for authentication
based on crypt()-hashed passwords but it didn't remove the header.

Finish up with the removal.

This allows the broadway backend to build on FreeBSD (which has no
crypt.h).

https://bugzilla.gnome.org/show_bug.cgi?id=726149
2014-03-12 00:17:09 -04:00
Jasper St. Pierre
fb51bbc565 wayland: Clean up a bit 2014-03-10 13:40:04 -04:00
Jasper St. Pierre
05b8609f80 wayland: Move some code around 2014-03-10 13:40:04 -04:00
Jasper St. Pierre
c92a16fcf5 wayland: Fix submenu positioning
window->x / window->y are in "root window coordinates", e.g. relative
to the topmost toplevel. However, the coordinates in get_xdg_popup are
relative to the passed-in surface, so we need to do the reverse
translation here.
2014-03-10 13:40:04 -04:00
Owen W. Taylor
99ac2f5c49 Fix font size when gdk_x11_display_set_window_scale() is used
We have a hack in the XSETTINGS code to substitute gtk-xft-dpi
with gdk-unscaled-dpi unless the screen has a fixed window scale,
in which case we just use gtk-xft-dpi.

But if the screen is changed to have a fixed window scale, then
the substituted value of gdk-unscaled-dpi will stick around until
the next (coincidental) change to XSETTINGS. To fix this, force
an immediate reread of the XSETTINGS property when
gdk_x11_display_set_window_scale() is used.

https://bugzilla.gnome.org/show_bug.cgi?id=725754
2014-03-06 23:20:00 -05:00
Benjamin Otte
32a420b7d6 broadway: Print a useful error message
.. instead of the generic "failed to open display".
2014-03-05 21:03:36 +01:00
Matthias Clasen
7fae042208 Deprecate GdkEventVisibility and ::visibility-notify-event
These don't really work anymore in a composited world.
Lets make it official.
https://bugzilla.gnome.org/show_bug.cgi?id=481073
2014-03-03 21:39:03 -05:00
Benjamin Otte
e9aa5a9822 gdkwindow: Call function instead of copying its code
gdk_window_get_origin() is just a variant of
gdk_window_get_root_coords() after all.
2014-02-28 03:09:23 +01:00
Jasper St. Pierre
0f212b5fb7 gdkwindow: Always pass the impl window to GdkWindowImpl::get_root_coords
The point of GdkWindowImpl::get_root_coords is to translate the passed
in coordinates against the passed-in impl window. For a child window,
in fact, window->abs_x and window->abs_y already track the child
window's coordinates against the impl window.

If we pass in a child window, and backends don't explicitly get the impl
window from it, we'll double-count the child window.

Really, we should *always* be passing impl windows to backends, and
never child windows. However, I'm a bit worried for regressions late
in the cycle if we want to fix up the rest of the callers, like
gdk_window_get_geometry, so I'm only going to touch get_root_coords
for now after careful review of all the backends.
2014-02-27 21:06:35 -05:00
Jasper St. Pierre
b922e0e213 Remove the return value of GdkWindowImpl::get_root_coords
It's unused by callers, and the historical return values are
undocumented, so just remove it now.
2014-02-27 21:06:35 -05:00
Jasper St. Pierre
056ca21e2f wayland: Seal up a non-declared public member 2014-02-27 17:33:09 -05:00
Jasper St. Pierre
7d67530982 wayland: Remove old, outdated comment 2014-02-27 17:00:56 -05:00
Jasper St. Pierre
08d0bedb28 wayland: Fix margins at startup
GtkWindow calls set_shadow_width then maps the window, meaning
that we never set the margin. Save it when we set and then set
it when we create the XDG surface.
2014-02-27 16:55:02 -05:00
Giovanni Campagna
ad2f96ff48 Gdk: fix wrong user_data handling in resize_cairo_surface()
Instead of destroying the surface in the backend if this is
unable to resize, let the core code do it, and do it properly.

Based on a patch by Benjamin Otte.

https://bugzilla.gnome.org/show_bug.cgi?id=725172
2014-02-26 00:04:41 +01:00
Jasper St. Pierre
084c2feb7e wayland: Don't destroy the cairo surface when resizing it
The code in GDK is incredibly broken and nobody is quite sure what's
right-side-up and what's upside down, but this breaks mutter-wayland
now, so let's remove it. It might leak, but we should probably do a
full restructuring of GDK drawing to fix it.
2014-02-23 16:07:38 -05:00
Rui Matos
6ea4bf8a9d wayland: Fix gdk_window_wayland_resize_cairo_surface()
Like in other backends (except X) we can't resize cairo image surfaces
so let's sync the code here with what the other backends do.

This prevents the painting machinery above us to paint on the wrong
buffer.

https://bugzilla.gnome.org/show_bug.cgi?id=724968
2014-02-23 18:40:29 +01:00
Matthias Clasen
6dcf6e0f3b Be more careful to change state atomically
This avoids temporary states of maximized+tiled that
we otherwise report.
2014-02-22 22:24:20 -05:00
Paolo Borelli
e34d9eafed Do not leak cairo_region 2014-02-21 21:11:21 +01:00
William Jon McCann
469d333aa2 docs: use Returns: consistently
Instead of Return value:
2014-02-19 18:56:05 -05:00
Jasper St. Pierre
7fbcff8d71 xdg-shell: Update for focused_set / focused_unset rename 2014-02-18 16:48:42 -05:00
Jasper St. Pierre
6845eade49 wayland: Update to new xdg-shell pinging standards 2014-02-18 16:47:34 -05:00