Commit Graph

51617 Commits

Author SHA1 Message Date
Javier Jardón
adc2f4ad9e 3.24: gtk/gtkaboutdialog: Add some more very common licenses:
- BSD 3-Clause "New" or "Revised" license
- Apache License 2.0
- Mozilla Public License 2.0
2020-04-12 13:11:22 +01:00
sicklylife
15737d7a94 Update Japanese translation 2020-04-12 08:51:04 +00:00
sicklylife
a1f43f53b4 Update Japanese translation 2020-04-12 08:42:56 +00:00
Matthias Clasen
a2b101ba5b Merge branch 'fno-common-3-24' into 'gtk-3-24'
Add a missing extern, to fix building with -fno-common (3.24 branch)

See merge request GNOME/gtk!1632
2020-04-11 15:16:55 +00:00
Matthias Clasen
f9decb0cd6 3.24.18 2020-04-09 18:33:59 -04:00
Emmanuele Bassi
85389c4bcf Merge branch 'docs-urls' into 'gtk-3-24'
docs: Update the links in the FAQ

See merge request GNOME/gtk!1654
2020-04-08 18:18:16 +00:00
Emmanuele Bassi
23d6764a6d docs: Update the links in the FAQ
The GTK website has been updated, and we don't use Bugzilla any more.

Fixes: #2593
2020-04-08 18:47:20 +01:00
Matthias Clasen
f8dd5b6b84 Merge branch 'wip/smcv/missing-xinclude-content' into 'gtk-3-24'
[gtk3] Add miscellaneous unpackaged files to dist tarball

See merge request GNOME/gtk!1653
2020-04-08 15:10:02 +00:00
Simon McVittie
c37bbb2641 Add miscellaneous unpackaged files to dist tarball
Various files are in git but not in dist tarballs. Some of them look
like potentially useful references for downstream distributors.

Signed-off-by: Simon McVittie <smcv@debian.org>
2020-04-08 13:43:28 +01:00
Simon McVittie
76b87660ba examples: Add exampleapp.desktop to dist tarballs
This should fix the last known instance of "MISSING XINCLUDE CONTENT"
in the generated documentation when using srcdir != builddir with
Autotools.

Fixes: https://gitlab.gnome.org/GNOME/gtk/issues/723
Bug-Debian: https://bugs.debian.org/672369
2020-04-08 13:38:59 +01:00
Matthias Clasen
a5dc7bbfc1 Merge branch 'wip/warn-less-about-temps' into 'gtk-3-24'
wayland: Move warning about transient-less temporaries to map()

See merge request GNOME/gtk!1650
2020-04-08 11:02:26 +00:00
Jonas Ådahl
cf060b4c7d wayland: Move warning about transient-less temporaries to map()
We shouldn't warn in a funtion that seemingly only checks how something
eventually should be mapped.

Closes: https://gitlab.gnome.org/GNOME/gtk/-/issues/2589
2020-04-08 11:43:49 +02:00
Matthias Clasen
99bae0fb5f Merge branch 'wip/wayland-unconfigured-cut-shadow-2' into 'gtk-3-24'
wayland: Always store unconfigured size

See merge request GNOME/gtk!1638
2020-04-07 11:31:56 +00:00
Emmanuele Bassi
67866bd8bc Merge branch 'wip/smcv/reproducible-resources' into 'gtk-3-24'
build: Generate gdk.gresource.xml in sorted order

See merge request GNOME/gtk!1644
2020-04-07 11:06:59 +00:00
Simon McVittie
b35cd705a7 build: Generate gdk.gresource.xml in sorted order
The order in which the resources get embedded matters for reproducible
builds. In the Meson build system, gen-gdk-gresources-xml already sorts
the list, but in the Autotools build system they were previously taken
in readdir() order.

Signed-off-by: Simon McVittie <smcv@debian.org>
2020-04-07 10:50:04 +01:00
Jonas Ådahl
c5d9c8be2b wayland: Always store unconfigured size
This means it'll always be as up to date GdkWindow::width/height. We
still skip the resize for non-configured windows though, to avoid
mapping with the wrong size.

The commit f06ee688fe also accidentally
removed the unconfigured size setting completely, so this essentially
adds it back, but always sets it.

Closes: https://gitlab.gnome.org/GNOME/gtk/-/issues/2582
2020-04-07 09:00:26 +02:00
Matthias Clasen
cdd4349bfe Merge branch 'wip/fix-epiphany-and-libreoffice-menus' into 'gtk-3-24'
Fix some Epiphany and LibreOffice menus

See merge request GNOME/gtk!1640
2020-04-06 20:34:30 +00:00
Jonas Ådahl
f06ee688fe wayland: Don't inhibit premature resize for popups
So now we essentially only inhibit the premature resize for toplevel
windows, where it is most crucial. For popups, this didn't work for two
reasons: we relied on the owner of the popup (application) to resize
according to the configured size. For custom popup operators like
Epiphany and LibreOffice, this didn't work out well, since they simply
didn't.

Making gdk do it for them in case they didn't themself did make the
popups show up properly, but there were still some weirdness in
LibreOffice where tooltips didn't still didn't get the right size. So,
even though the size set by application may be different from the one
later configured by the display server, let the applications have their
way and see their resize result immediately. It's fairly likely to be
what they eventually get anyway.

Closes: https://gitlab.gnome.org/GNOME/gtk/-/issues/2583
2020-04-06 22:02:02 +02:00
Jonas Ådahl
92aa63c203 wayland: Set unconfigured size on impl construction
Who knows who might use this for something, so lets make the
unconfigured size slightly more predictable. This doesn't fix anything
known to be broken though.
2020-04-06 22:01:12 +02:00
Matthias Clasen
dc79e07228 Merge branch 'wip/smcv/wayland-configure-positive-sizes' into 'gtk-3-24'
wayland: Guard against nonsense sizes being configured

See merge request GNOME/gtk!1639
2020-04-06 13:00:30 +00:00
Simon McVittie
46165b52e5 wayland: Guard against nonsense sizes being configured
With the fixes from !1638, it shouldn't be possible for this to happen
any more. However, non-positive sizes make no sense regardless, so if
this does somehow happen, let's make sure *something* reasonable happens.

The practical result of this assertion being hit is that we emit a
critical warning and then behave the same as if !1634 had been merged,
which is known to solve the issue for the submitter.

Signed-off-by: Simon McVittie <smcv@debian.org>
2020-04-06 13:33:09 +01:00
Matthias Clasen
e6ec3f4b95 Merge branch 'wip/wayland-unconfigured-cut-shadow' into 'gtk-3-24'
Fix restoring size from past sessions

See merge request GNOME/gtk!1637
2020-04-06 11:49:45 +00:00
Jonas Ådahl
814d1e7f06 wayland: Store unconfigured size without margin
We get the unconfigured size request either with or without the shadow
margin already configured, so to get some consistency with the 'saved
size', cut away any potential shadow margin from the size before
storing.

Then when using, add it back, so we always create a configure event with
the correct size.

Closes: https://gitlab.gnome.org/GNOME/gtk/-/issues/2576
2020-04-06 12:13:01 +02:00
Jonas Ådahl
2e5f344e3c wayland: Always update unconfigured size
If the window size didn't change, we should still update the
unconfigured size as the window size might not be up to date.
2020-04-06 12:05:58 +02:00
Jonas Ådahl
a4984cfd40 wayland: Use helpers to add/remove margins from sizes 2020-04-06 12:05:13 +02:00
John Ralls
26c75f31f4 Merge Thomas Holder's raise transient window into gtk-3-24. 2020-04-05 14:20:27 -07:00
Matthias Clasen
7fedb39b4b Merge branch 'custom-surface-resize' into 'gtk-3-24'
Do not require an initial configure for custom Wayland surfaces

See merge request GNOME/gtk!1633
2020-04-05 19:11:19 +00:00
William Wold
5a52af20cb Do not require an initial configure for DnD windows
Fixes #2075
2020-04-05 07:11:45 -04:00
William Wold
12fc9a45ef Do not require an initial configure for custom Wayland surfaces
There is no way for custom Wayland surfaces to get configure events, so an
initial configure event should not be required to resize a custom surface.

Fixes #2578.
2020-04-05 05:28:55 -04:00
Martin Storsjö
01d4c29ce3 Add a missing 'extern' attribute, to fix building with -fno-common
With C compilers defaulting to -fcommon, this isn't an issue, but
upcoming compilers (GCC 10 and Clang 11) will default to -fno-common,
ending up with duplicate definitions of this variable.
2020-04-05 00:26:19 +03:00
Ibai Oihanguren Sala
8c97702a07 Update Basque translation 2020-04-04 13:44:01 +00:00
Matthias Clasen
5a0891c69d Merge branch 'gtk-3-24' into 'gtk-3-24'
docs: Do not call GTK APIs if gtk_init_check returns FALSE

See merge request GNOME/gtk!1617
2020-04-04 03:18:01 +00:00
Nicola Fontana
392d4de8a9 docs: Do not call GTK APIs if gtk_init_check returns FALSE
See issue #994.
2020-04-03 22:59:59 +02:00
Rūdolfs Mazurs
4ce11106c8 Update Latvian translation 2020-04-03 20:47:38 +00:00
Matthias Clasen
4480c0ffc6 3.24.17 2020-04-03 13:07:53 -04:00
Matthias Clasen
da1686eb47 Fix build issues with HighContrast theme 2020-04-03 12:54:32 -04:00
Matthias Clasen
eecd33146e Merge branch 'wip/dont-postpone-subsurface-resize' into 'gtk-3-24'
wayland: Don't postpone resizes for subsurfaces

See merge request GNOME/gtk!1620
2020-04-03 16:43:19 +00:00
Jonas Ådahl
749d940887 wayland: Don't postpone resizes for subsurfaces
Subsurfaces won't ever receive a configure event.

Closes: https://gitlab.gnome.org/GNOME/gtk/-/issues/2570
2020-04-03 18:04:44 +02:00
Matthias Clasen
c67d0f0d1d Merge branch 'wip/carlosg/fix-surrounding-text-again' into 'gtk-3-24'
imwayland: Clamp the surrounding string end correctly

See merge request GNOME/gtk!1619
2020-04-03 15:39:30 +00:00
Matthias Clasen
0fbc3581bc Merge branch '3.24-meson-bump' into 'gtk-3-24'
meson: Bump to latest version of the 3.24 branch

See merge request GNOME/gtk!1613
2020-04-03 12:25:32 +00:00
Carlos Garnacho
d7fb15c822 imwayland: Clamp the surrounding string end correctly
In the paths where len > MAX_LEN and cursor/anchor are separated by
at least MAX_LEN from text edges, we were clamping the right end of
the surrounding string at MAX_LEN. Oops.

This end anchor may go as far as the string length, although just
up to len - MAX_LEN in real terms (due to the condition above that
caches cursor/anchor positions being near enough the text end).

Closes: https://gitlab.gnome.org/GNOME/gtk/-/issues/2565
2020-04-03 12:57:44 +02:00
Philippe Normand
c010a95d8c meson: Bump to latest version of the 3.24 branch
3.24.16 was tagged without bumping the version in the Meson build definitions.
2020-04-03 10:52:29 +01:00
Matthias Clasen
d5264673cb wayland: Load .Compose in imwayland too
GtkIMContextSimple loads custom compose sequences
in its set_client_window implmentation, so we need
to chain up in order to not lose those.
2020-04-02 17:30:54 -04:00
Matthias Clasen
94a2827ed9 Merge branch 'keyboard-focus' into 'gtk-3-24'
gdk/wayland: Clear modifiers when we lose keyboard focus

See merge request GNOME/gtk!1609
2020-04-02 19:23:36 +00:00
Jan Alexander Steffens (heftig)
c27cb675b7
gdk/wayland: Clear modifiers when we lose keyboard focus
When we `Alt+Tab` away from a GTK application, it loses keyboard focus.
If we don't clear the modifiers, events from other devices that we
receive while unfocused will assume `Alt` is still pressed. This results
in e.g. Firefox navigating through the history instead of scrolling the
page when using the mouse wheel on it.

We don't get any information about modifiers while we are missing
keyboard focus, so assuming no modifiers are active is the best we can
do.

The shell sends us a modifier update immediately before we regain
keyboard focus, so the state shouldn't get out of sync.

Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/2112
2020-04-02 20:45:55 +02:00
Matthias Clasen
263467ca3d Merge branch 'wip/window-state-change-fixes' into 'gtk-3-24'
Some Wayland window state change resize fixes

See merge request GNOME/gtk!1606
2020-04-02 17:25:31 +00:00
Jonas Ådahl
3b91c20eac wayland: Add margin to saved size when restoring size
We're normally going from a fixed size to a floating state when we're
using the saved size, meaning we're practically always going towards a
state where the shadow margin will non-empty. However, if we don't
include any margin when creating a new configure request, we'll end up
resizing to a slightly smaller size as gtk will cut off the margin from
the configure request when changing the window widget size.

This wasn't visible when e.g. going from maximized to floating, as we'd
add the shadow margin at a later point, which would effectively "grow"
the widnow size, but when we're going from tiled to floating, we both
start and end with a non-empty shadow margin, meaning we'd shrink ever
so slightly every time going between tiled and floating.
2020-04-02 18:10:03 +02:00
Jonas Ådahl
50aa947e51 wayland: Treat being tiled as maximized when saving size
We should never save a size when we're tiled, just as we shouldn't when
we're maximized. This fixes returning to the correct floating size after
having been tiled or maximized.
2020-04-02 18:10:03 +02:00
Jonas Ådahl
04b7853a38 wayland: Respect fixed size when resizing
If a window is configured with a fixed size (it's tiled, maximized, or
fullscreen), ignore any resize call that doesn't respect this. The set
size will instead be saved, when appropriate, so that the new size is
used when e.g. unmaximizing.

This makes it possible to call 'gtk_window_resize()' while the window is
maximized, without the window actually changing size until it's
unmaximized. Changing size to a non-maximized size is a violation of the
xdg-shell protocol.
2020-04-02 18:10:03 +02:00
Jonas Ådahl
7f12dc2b66 wayland: Postpone window resize requests until configured
An application may want to set a fallback size of a window while still
mapping maximized. This is done by calling gtk_window_resize() before
gtk_window_maximize() and before gtk_window_show(). When the window is
mapped, it should have a maximized size, and if it eventually is
unmaximized, it should fall back to the size from the earlier
gtk_window_resize() call.

What happens before this commit is that the initial window size ends up
respecting the first gtk_window_resize() dimensions, and not the window
dimension configured by the Wayland display server (i.e. maximized
dimensions).

Fix this by postponing any configure events until we received our
configuration from the display server. If we got one with a fixed size
(e.g. we're maximized, tiled etc), we use that, otherwise we look at the
one that was previously configured by gtk which corresponds to the
"preferred" size when not being maximized.

This fixes Firefox being started in a maximized state when using the
Wayland backend.

Closes: https://gitlab.gnome.org/GNOME/gtk/-/issues/2538
2020-04-02 18:09:56 +02:00