Commit graph

27187 commits

Author SHA1 Message Date
Joshua Goins
0ea1bcfe89 ButtonRebindsFilter: Add test for disabled bindings
This was missed when it was first implemented, but now there's tests for
checking if bindings can be disabled in the buttons rebind plugin.
2024-07-23 00:38:36 +00:00
Joshua Goins
47a538e61c ButtonRebindsFilter: Add test for mouse button binding
This was missed when it was first implemented, but now there's tests for
checking the mouse binding functionality in the buttons rebind plugin.
2024-07-23 00:38:36 +00:00
Ismael Asensio
ac5c175ade kcms/rules: Some QML clean-ups
- Remove unnecessary bindings to enabled: Properties that are not
  enabled are not shown in the list anyway, and it fixes QML warnings:

  RuleItemDelegate.qml:16:5: Unable to assign [undefined] to bool
  RuleItemDelegate.qml:93:17: Unable to assign [undefined] to bool

- Remove unnecessary colorSet
- Port away from javascript `var`
- Remove outdated comment
2024-07-22 12:46:29 +02:00
Ismael Asensio
0bd722e84b kcms/rules: Add a placeholder for properties filter
The list to add properties can be empty because no entry matches
the filter text or if all the properties have been already added.

Show a placeholder instead of leaving the view just empty
2024-07-22 12:46:29 +02:00
Ismael Asensio
9098fd4910 kcms/rules: Make the "Add Property" button non-toggleable
Changing the text and meaning of the button unexpectedly for a
regular operation is not consistent with any other place, and
disregarded by the HIG.

The sheet can be closed by tapping outside of it, or throught
the close button in its titlebar, as usual elsewhere.
2024-07-22 12:46:29 +02:00
Ismael Asensio
893bffd572 kcms/rules: Reuse items on the property selection ListView
This makes scrolling the list view much more responsive as there
is no need to create new delegates

BUG: 449275
FIXED-IN: 6.2
2024-07-22 12:46:29 +02:00
Ismael Asensio
90dbeef1d6 kcms/rules: Increase the default dialog size
This KCM is usually called via the application menu, which uses
kcmshell, so it doesn't benefit from the SystemSettings minimum size.

Slightly increse its height, so there is more space for properties
in the list views, either to configure them or to add them, so it
feels less cramped.
2024-07-22 12:46:29 +02:00
l10n daemon script
b9ace07d74 GIT_SILENT Sync po/docbooks with svn 2024-07-22 01:31:18 +00:00
l10n daemon script
1bf7018634 GIT_SILENT Sync po/docbooks with svn 2024-07-21 01:30:24 +00:00
l10n daemon script
0c6e458423 GIT_SILENT Sync po/docbooks with svn 2024-07-20 01:28:34 +00:00
Vlad Zahorodnii
ac80307eba wayland: Make XdgPopupWindow also destroy Window
Arguably, the compositor doesn't need to wait any longer after dismissing
the popup because it knows that the popup has been closed.

BUG: 490097
2024-07-19 20:49:01 +00:00
Xaver Hugl
eddced099d backends/drm: don't unset degamma in prepareAtomicModeset
We're now using and, if necessary, un-setting the property in prepareAtomicPresentation

BUG: 490517
2024-07-19 21:39:33 +02:00
Xaver Hugl
2340470a9a backends/drm: add support for drm plane size hints
On a lot of hardware, using bigger plane sizes than necessary means wasting power.
This is specifically problematic with the cursor plane, where we so far only had a
single fixed size hint through drm caps, even though the hardware often could use
a smaller cursor size.
This adds support for the per-plane SIZE_HINTS property, which allows us to pick a
smaller cursor size when the cursor image fits into it, and should save some power
that way.
2024-07-19 13:40:44 +02:00
Vlad Zahorodnii
2296f1ac3b utils: Load Xcursor cursors on demand
Usually, only a small subset of cursors would be used, for example the
default shape, the pointer shape, the text shape, etc.

Another reason why this change makes the KXcursorTheme load cursors on
demand is to prepare the cursor loading machinery to SVG cursors.
2024-07-19 06:02:11 +00:00
l10n daemon script
4f12792c2f GIT_SILENT Sync po/docbooks with svn 2024-07-19 01:28:35 +00:00
Vlad Zahorodnii
a10c322f7a wayland: Ignore plasma shell reposition requests during interactive move resize
Both kwin and plasma have different placement strategies during interactive
move resize. That can result in the window flipping between two positions.

In order to prevent that, this change makes kwin placement take precedence
over the window position specified using the plasmashell protocol. This can
be considered as a workaround.

BUG: 481829
2024-07-18 17:02:52 +00:00
Xaver Hugl
49f656a3d9 xdgshellwindow: guard against sending negative configure bounds
It's unlikely to happen, but if it were to happen, it would cause crashes
2024-07-18 15:48:17 +00:00
Xaver Hugl
099a1cc31f backends/drm: limit max_bpc to 8 by default with docks
There's generally a lot of problems with higher than 8bpc in docking stations,
especially when multiple monitors are involved. Until these problems are hopefully
eventually fixed on the driver side, limit the bpc to 8 with docks by default
2024-07-18 15:28:32 +00: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
Harald Sitter
ae336e464e wayland: implement plasmawindowmanagement v18 2024-07-18 15:07:57 +00:00
Xaver Hugl
a6e429f348 wayland/xxcolormanagement: set the correct mastering display info in the color description 2024-07-18 16:11:14 +02:00
Xaver Hugl
1d3e3faf7b wayland: update xx color management to version 4 2024-07-18 16:11:13 +02:00
Xaver Hugl
01d9393e80 xdgshellwindow: never request clients to resize to a negative size
Doing that can cause clients to crash

BUG: 489983
2024-07-18 15:41:02 +02:00
Xaver Hugl
c3d202b0d2 compositor_wayland: count rendering time for all steps of compositing
Otherwise, prePaintPass, postPaintPass and possible future overhead like overlay
plane matching aren't accounted for, which can cause frames to be dropped.

CCBUG: 488782
2024-07-18 13:25:16 +00:00
Vlad Zahorodnii
7b486e215d Avoid sending excessive synthetic ConfigureNotify events
While they are harmless, they can result in the client repainting more
than needed and resulting in the opposite edge "bouncing" when resizing
the window.
2024-07-18 12:17:18 +00:00
Vlad Zahorodnii
8f144460d7 Initialize X11Window::m_client geometry
Initialize X11Window::m_client geometry with a proper value so, later, the
X11Window::configure() function can properly determine whether the client
window is resized.
2024-07-18 12:17:18 +00:00
Vlad Zahorodnii
53b61ce5d7 autotests: Fix a race condition in X11WindowTest
NETWinInfo queries the window state and setState() will do nothing if the
proposed new state matches the cached server side state.

On the other hand, given how the test is structured, there can be pending
fullscreen changes on the kwin side that are yet to be sent to the X server
when the NETWinInfo object is created.

This change fixes that race condition by adding an explicit Xcb::sync().
2024-07-18 12:17:18 +00:00
Xaver Hugl
75075fdb89 backends/drm: combine matrix operations in the right order
Matrix multiplication is right to left, so the operations have to be added
in the reverse order from the list
2024-07-18 12:02:35 +00:00
Xaver Hugl
cd1b70ef05 backends/x11/standalone: fix night light 2024-07-18 13:38:58 +02:00
Vlad Zahorodnii
ddfb26fc8e utils: Provide size hints in native pixels
This is mainly to make the Xcb utils api consistent.
2024-07-18 13:39:11 +03:00
Vlad Zahorodnii
95f56399b8 utils: Make Xcb::WindowGeometry return native geometry 2024-07-18 13:38:09 +03:00
David Redondo
ccde653ac2 plugins/eis: Ignore duplicate key and buttons events
Some clients (like xdotool) can send multiple events for the same
key. In some instances the number of presses and releases can even
be mismatched leading to stuck keys. While we clean up pressed keys
when the client vanishes, this doesnt help when it doesnt immediately
disconnect (for example Xwayland keeps client connections live
longer than the actual x client to reuse them).
Also fixes a copy paste mistake where key presses where also written
to buttons.
2024-07-18 10:17:31 +00:00
Jakob Petsovits
6ca6308ccd wayland: Use brightness range 1..max for internal displays
This avoids regressing compared to PowerDevil in 6.1 which also
protected against setting internal display brightness to 0.

CCBUG: 430439
CCBUG: 483490
2024-07-18 07:13:27 +00:00
Bruno Filipe
998be47ac1 backends/libinput: Ignore redundant events for pointer buttons and keyboard keys when pressed/released on multiple devices
BUG: 486034
2024-07-18 06:56:18 +00:00
l10n daemon script
ea4b2c2b20 GIT_SILENT Sync po/docbooks with svn 2024-07-18 01:25:49 +00:00
Xaver Hugl
6b42e59677 colors/colordevice: remove brightness factor
It's completely unused. If brightness modification is desired for night light
for example, it should be tied in with the actual brightness controls for outputs
instead
2024-07-17 16:08:18 +00:00
Xaver Hugl
cb830957aa core: remove unused colorlut class 2024-07-17 16:08:18 +00:00
Xaver Hugl
0260c2e9cd backends/drm,x11/standalone: apply night light in linear space
It's more correct and, as long as you have a programmable LUT, also not less efficient
2024-07-17 16:08:18 +00:00
Xaver Hugl
a86a914f70 backends/drm: allow offloading more complex color pipelines to legacy modesetting
This is done by combining multiple transfer functions and multipliers into one LUT.
2024-07-17 16:08:18 +00:00
Xaver Hugl
e2c8f25d31 backends/drm: combine color operations more aggressively than ColorPipeline does
With programmable LUTs, consecutive transfer functions, inverse transfer functions and
multipliers can all be combined into one LUT. This allows offloading operations in more
situations and makes the operations more efficient too, as potentially fewer LUTs have
to be programmed
2024-07-17 16:08:18 +00:00
Xaver Hugl
3f2f3cb020 core/colorpipeline: add evaluate method to calculate colorpipeline results on the CPU
This is useful for autotests and some other special cases where we need to calculate
the result of a color pipeline on the CPU. Long term, this should replace
ColorDescription::mapTo
2024-07-17 16:08:18 +00:00
Xaver Hugl
4b91ac8cca core/output: remove unused setGammaRamp method 2024-07-17 16:08:18 +00:00
Vlad Zahorodnii
7a472fcab2 backends/x11: Fix crash that happens when toggling compositing
When the GLX or the EGL backend is destroyed, it is going to reset the
RenderLoop state, including the number of frames in flight. It does so
because of the historical reasons. At the time, there was no output frame
object to track the lifecycle of a frame.

After introducing the OutputFrame and hooking it into the RenderLoop,
the pending frame count will be reset automatically in RenderLoop when
the GLX or the EGL backend is destroyed. But we forgot to remove
the invalidate() function calls. So, when the GLX backend goes down, it
resets the pending frame count to zero and then it destroys the pending
OutputFrame object, which would result in decreasing the pending frame
count by 1 and triggering an assert in the RenderLoopPrivate::notifyFrameDropped()
function.

Since there is the OutputFrame helper now, the invalidate() function
can be dropped. Technically, the invalidate function did more than just
reset pendingFrameCount to 0, for example also stop the compositeTime.
But that should be fairly harmless new behavior.
2024-07-17 12:19:21 +00:00
Nicolas Fella
19bf66c42a plugins/stickykeys: Unlatch modifiers when locking
The state should be either latched or locked, not both
2024-07-17 13:13:40 +02:00
Nicolas Fella
85b5048e72 Test locking sticky keys for all modifiers 2024-07-17 10:58:49 +00:00
Nicolas Fella
65405c128e Release key in sticky key test
Otherwise it's pressed the whole time, breaking subsequent tests
2024-07-17 10:58:49 +00:00
l10n daemon script
fa443bb806 GIT_SILENT Sync po/docbooks with svn 2024-07-17 01:26:31 +00:00
Xaver Hugl
0672313c20 core/renderloop: add some hysteresis to triple buffering
Switching to triple buffering requires dropping a frame, so if we constantly
switch back and forth between double and triple buffering, that can cause
very visible performance issues

CCBUG: 488843
2024-07-16 14:21:47 +00:00
Nicolas Fella
6f750f0aa5 Fix typo in comments 2024-07-16 16:08:14 +02:00
Vlad Zahorodnii
5921be95d3 utils: Fix gaining realtime scheduling with musl
sched_setscheduler() is implemented as a stub in musl that does
nothing because Linux provides no way to set scheduling parameters
per process.

Use pthread_setschedparam() to change the scheduling parameters of
the threads instead.

BUG: 487996
2024-07-16 12:56:04 +00:00