Commit graph

997 commits

Author SHA1 Message Date
Xaver Hugl
4759ec6089 wayland: implement the alpha-modifier protocol
The alpha modifier protocol allows clients to set a multiplier for the opacity
of a surface, which allows them to offload some operations to KWin, which
in turn may offload them to KMS in the future
2024-08-14 14:26:33 +02:00
Thomas Duckworth
4019989959 kcms: Use flat QGroupBoxes and set documentMode on QTabWidgets
Makes it consistent with other KCMs and and Kirigami KCMs.

**Before:**

![Screenshot_20240809_181201.png](/uploads/ff17bdcbdacda38d4abe752054d7f6d2/Screenshot_20240809_181201.png){width=431 height=399}![Screenshot_20240809_181210.png](/uploads/2e360efae4dd8982ab0a7b7af7ec85b4/Screenshot_20240809_181210.png){width=430 height=398}![Screenshot_20240809_181155.png](/uploads/6f534ffad87350a4d8fd47735f1c8c60/Screenshot_20240809_181155.png){width=431 height=399}

**After:**

![Screenshot_20240809_181243.png](/uploads/94babd127faaa8021054b7c46c806f93/Screenshot_20240809_181243.png){width=433 height=358}![Screenshot_20240809_181251.png](/uploads/25bd2d99ada694173ba875006dbe57bc/Screenshot_20240809_181251.png){width=436 height=361}

![Screenshot_20240809_181236.png](/uploads/03f0fb73e357728ae558649381cecdf7/Screenshot_20240809_181236.png){width=443 height=367}

@teams/vdg
2024-08-13 18:04:14 +00:00
Aleix Pol Gonzalez
e2ef47031c Only look up X11 if it's needed
Do not look it up if KWIN_BUILD_X11=OFF.

Signed-off-by: Falko Becker <falko.becker@mbition.io>
2024-08-09 16:33:51 +02:00
Vlad Zahorodnii
266c6ee855 utils: Add support for svg cursors
With this change, KXcursorTheme will be able to load svg cursors provided
by breeze.

If a cursor theme provides both xcursor cursors and svg cursors, the svg
cursors will be preferred.

At the moment, KXcursorTheme doesn't cache svg render results but it could
do that if it becomes a noticeable issue.
2024-08-07 11:57:39 +03:00
Jonathan Riddell
15538c303b Update Qt version requirement to 6.7.0
GIT_SILENT
2024-08-02 10:15:30 +01:00
Nicolas Fella
80b5910594 Add visual bell effect
This effect is used to implement the visual bell accessibility feature.

It allows to implement it on Wayland and significantly improve it on X11,
where it's currently rather broken.

It offers two modes:
- Inverting the colors (code is based off the invert effect)
- Flashing a solid color
2024-07-30 15:19:35 +02:00
Harald Sitter
63bf2db551 cmake: bump plasma-wayland-protocols requirement
we need it to implement window protocol v18
2024-07-18 15:07:57 +00:00
Neal Gompa
915d103128 cmake: Allow not building kwin_x11
Some distributions do not wish to build the KWin X11 backend as
they do not use it, even though they wish to maintain X11 support
for Xwayland when using KWin as a Wayland compositor.

Allow this choice by splitting the build flag and setting it up to
forcibly disable building the backend when building X11 code is
switched off.
2024-07-16 06:47:43 +00:00
Jonathan Riddell
6f2cab89d9 use separation dep_version to build against, updated by release scripts 2024-06-27 12:42:45 +01:00
Vlad Zahorodnii
7590c6d386 wayland: Bump default max buffer size to 1 MiB
This is to prevent disconnecting clients that sometimes struggle with
keeping up with the events that the compositor sends. 1 MiB was eyeballed.

Wayland's wire protocol consists of a stream of messages. Every message
consists of a header (2 words: 1 word for object id, the other word
specifies the message size + event/request opcode) and the arguments.

Considering the compositor sending motion events generated by a mouse
with 1000Hz polling rate, we have

- wl_pointer.motion event size: (4 bytes for serial + 4 bytes for x +
  4 bytes for y + 8 bytes for header) = 20 bytes
- wl_pointer.frame event size: 8 bytes for header

So in total, if the client freezes for a second, the client buffer size
should be at least (20 + 8) * 1000 / 1024 = 27 KiB. 1 MiB corresponds to
the client not processing the motion events for approximately 30 seconds.
2024-06-25 20:19:59 +03:00
Vlad Zahorodnii
64bbbde249 cmake: Group together code that tests compiler features and platform features 2024-06-17 05:09:13 +00:00
Vlad Zahorodnii
f89a1f9766 cmake: Remove invalid comments 2024-06-17 05:09:13 +00:00
Vlad Zahorodnii
a1443cb43e cmake: Move find_package() around to keep them all close 2024-06-17 05:09:13 +00:00
Vlad Zahorodnii
2d4bbe917c cmake: Group option()s 2024-06-17 05:09:13 +00:00
Xaver Hugl
3f0627172d cmake: bump required plasma-wayland-protocols version 2024-05-24 20:53:02 +00:00
Jonathan Riddell
3ebbe28b64 update version for new release 2024-05-24 16:14:01 +01:00
Jonathan Riddell
572e07b130 Update Qt version requirement to 6.6.0
GIT_SILENT
2024-05-24 13:11:44 +01:00
Jonathan Riddell
01d3f22633 update version for new release 2024-05-24 12:32:27 +01:00
Jonathan Riddell
5e79956933 Update Qt version requirement to 6.7.0
GIT_SILENT
2024-05-24 11:22:28 +01:00
Jonathan Riddell
1ab1a5f297 Update Frameworks version requirement to 6.2.0
GIT_SILENT
2024-05-24 11:22:28 +01:00
David Redondo
805435d157 xwayland: Enable xtest libei integration
Enabling this feature makes Xwayland send xtest events via
the remote desktop portal and libei.
XWayland will create a new session for each X client (it keeps
contexts around and reuses them if the cmdline matches, so not
every xdotool invocation produces a new portal prompt).
2024-05-15 09:31:53 +00:00
David Redondo
499d006e3a Add a libeis input backend plugin
This adds a libeis backend via plugin which supports clients sending
emulated input events. No public listening socket is exposed,
clients are expected to go through the RemoteDesktop portal.
In order to restrict the device types available to clients
according to what was approved via the portal a separate eis
context per portal request is created. The communication with
the portal happens through a simple dbus interface where cookies
are  handed out for each eis context so the portal can inform KWin
when the portal session is closed/should end.
2024-04-15 13:05:15 +00:00
Xaver Hugl
36001e5ee0 increase minimum libdrm version to 2.4.116
It's required for drmSyncobjEventfd
2024-04-15 09:22:00 +00:00
Carl Schwan
b2f181fe80 Update kirigami target
Since kf6, FindKirigami2Config is deprecated in favor of
FindKirigamiConfig
2024-04-12 10:22:48 +00:00
David Redondo
7f20621b25 Bump wayland-protocols to 1.34 2024-04-03 09:27:46 +00:00
David Edmundson
b650f55d60 xwayland: Add unit test for XWayland key tracking 2024-03-03 12:41:15 +00:00
Aleix Pol Gonzalez
bf1ce85474 Make it possible to build KWin without libxcb
Now that we have Wayland around, there's a whole branch of dependencies
that shouldn't be necessary anymore.
This allows to build KWin without all of it, allowing us to have a much
more compact alignment for cases where all the legacy software isn't
necessary anymore.

Bundle KWindowSystem X11-specific headers into it too, since it's part
of the same process.

Signed-off-by: Victoria Fischer <victoria.fischer@mbition.io>
2024-02-28 16:03:50 +00:00
Aleix Pol Gonzalez
05a3e2bad9 systemd: Set up a watchdog
Allows to notify systemd whether kwin is still running and possibly
restart the service if it stops responding.

Use Type=notify-reload to watch the kwin service. This will make it so
we receive SIGHUP rather than SIGTERM on the wrapper which we can handle
gracefully and stop the kwin process and restart as expected.

https://www.freedesktop.org/software/systemd/man/latest/systemd.service.html

Signed-off-by: Victoria Fischer <victoria.fischer@mbition.io>
2024-02-22 16:47:35 +00:00
Jonathan Esk-Riddell
5306823435 Update Frameworks version requirement to 6.0.0
GIT_SILENT
2024-02-21 14:33:28 +00:00
Aleix Pol Gonzalez
c5305820d4 Reduce needed dependencies
For many components KConfigWidgets isn't necessary, just KColorScheme.

Signed-off-by: Falko Becker <falko.becker@mbition.io>
2024-02-14 14:45:24 +01:00
Vlad Zahorodnii
50fae55821 Revert "systemd: Set up a watchdog"
kwin_wayland has become unstable. Sometimes it works fine, sometimes it
is randomly killed. Things are quite bad after kwin_wayland --replace.

This reverts commit 71ade59f4b.
2024-02-05 12:54:47 +02:00
Aleix Pol Gonzalez
71ade59f4b systemd: Set up a watchdog
Allows to notify systemd whether kwin is still running and possibly
restart the service if it stops responding.

Use Type=notify-reload to watch the kwin service. This will make it so
we receive SIGHUP rather than SIGTERM on the wrapper which we can handle
gracefully and stop the kwin process and restart as expected.

https://www.freedesktop.org/software/systemd/man/latest/systemd.service.html

Signed-off-by: Victoria Fischer <victoria.fischer@mbition.io>
2024-02-05 09:25:08 +00:00
Jonathan Esk-Riddell
61699e9ed3 Update version number for 6.0.80
GIT_SILENT
2024-01-10 14:03:49 +00:00
Jonathan Esk-Riddell
cc49e25eac Update version number for 5.92.0
GIT_SILENT
2024-01-10 12:28:48 +00:00
Jonathan Esk-Riddell
f029e91fd5 Update version number for 5.91.90
GIT_SILENT
2023-12-20 18:54:35 +00:00
Jonathan Esk-Riddell
81f9cd9992 Update version number for 5.91.0
GIT_SILENT
2023-12-20 12:02:38 +00:00
David Redondo
f25b8817d9 Update Qt version requirement to 6.6.0
GIT_SILENT
2023-12-08 12:10:27 +01:00
Jonathan Esk-Riddell
0b5b361b4a Update version number for 5.90.90
GIT_SILENT
2023-12-07 16:40:47 +00:00
Nicolas Fella
f399d2442a Adapt to plasma-framework targets being renamed 2023-12-04 19:43:47 +00:00
Jonathan Esk-Riddell
cea6368e72 Update version number for 5.90.0
GIT_SILENT
2023-11-29 10:24:10 +00:00
Oliver Beard
9b73cdeeba Find WaylandClient in non-testing builds 2023-11-27 17:30:41 +00:00
Aleix Pol Gonzalez
b853de3d29 Allow building KWin without KGlobalAccel
Signed-off-by: Falko Becker <falko.becker@mbition.io>
2023-11-27 17:07:28 +01:00
Kai Uwe Broulik
7bd9ae8d0b helpers/killer: Modernize UI
This overhauls the kill prompt UI to make it more modern and more
easily to grasp.

* Reduce the amount of text and redundancy.
  Give the window a title and drop the "app is not responding" heading.
  Try to remove the application name from the displayed window title.
  Also use the bold emphasis used in other places like deleting files.

* Use the application icon if available with a warning overlay.
  This makes it easier to grasp which application it's talking about.

* Move technical information (like PID and hostname) into an
  expandable "Details" section.

KGuiAddons has been implicitly pulled in by KConfigWidgets already.
2023-11-27 14:10:15 +00:00
Nicolas Fella
8ec88aa3bf Adjust to renamed activities libraries 2023-11-23 21:48:01 +01:00
Jonathan Esk-Riddell
cc4eac4c85 Port to renamed kwayland
https://invent.kde.org/plasma/kwayland/-/merge_requests/107  use renamed kwayland
2023-11-23 19:34:24 +00:00
Jonathan Esk-Riddell
2302d81d5a Update version number for 5.81.80
GIT_SILENT
2023-11-17 12:28:13 +00:00
Alexander Lohnau
22dfc8978e Adjust to removed QueryMatch::Type enum in KRunner 2023-11-10 07:11:44 +01:00
Jonathan Esk-Riddell
2f1fd37c9b Update version number for 5.81.0
GIT_SILENT
2023-11-09 12:31:09 +00:00
Nicolas Fella
41a5b84958 Fix KWayland version 2023-11-06 21:58:19 +01:00
Jonathan Esk-Riddell
7aaf2d2903 Update Qt version requirement to 6.5.0
GIT_SILENT
2023-11-06 19:57:32 +00:00