Commit graph

25874 commits

Author SHA1 Message Date
Vlad Zahorodnii
f1e1a54200 ci: Add plasma-workspace to RuntimeDependencies
kscreenlocker has some really bad dependency issues. It should not pull
plasma-workspace. But without it, our ci fails.
2023-12-21 10:40:41 +00:00
l10n daemon script
1169eed24a GIT_SILENT Sync po/docbooks with svn 2023-12-21 02:54:45 +00:00
l10n daemon script
2afa1d8272 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2023-12-21 02:32:18 +00:00
Jonathan Esk-Riddell
f029e91fd5 Update version number for 5.91.90
GIT_SILENT
2023-12-20 18:54:35 +00:00
Arjen Hiemstra
71be0f68c0 plugins/overview: Don't rely on item type to determine drop behavior
Item type is incredibly fragile as a way to determine what was dropped,
as proven by recent breakage. Instead, we can use `Drag.keys` to provide
metadata about what is being dragged/dropped.
2023-12-20 12:58:59 +00:00
Jonathan Esk-Riddell
81f9cd9992 Update version number for 5.91.0
GIT_SILENT
2023-12-20 12:02:38 +00:00
Yifan Zhu
09a547361a plugins/overview: Use correct type to match
The overview effect uses the type of the dragged object to determine
if a single window is dragged or the entires desktop.
Commit 0ff4f84a changed the type of mainBackground, but did not
update the code for matching the type.

BUG: 478746
FIXED-IN: 6.0
2023-12-20 07:06:00 +00:00
Vlad Zahorodnii
edaee17a16 Avoding releasing closed windows twice when shutting down X11 logic
The stack may contain an already closed window, in which case do nothing.
2023-12-20 06:51:47 +00:00
Xaver Hugl
d301106aef opengl/glshadermanager: use texture2D for sampling external textures
BUG: 478737
2023-12-20 02:28:57 +00:00
l10n daemon script
e77f23ac5d GIT_SILENT Sync po/docbooks with svn 2023-12-20 02:12:01 +00:00
Xaver Hugl
f03bfa324d outputconfigurationstore: adjust auto rotate to the panel orientation 2023-12-19 18:28:48 +00:00
Yifan Zhu
eda442f9b0 kcms/tabbox: change Shift+Backtab to Shift+Tab
In default shortcuts, change +Shift+Backtab to +Shift+Tab.

Functionally the behavior doesn't change.
But Shift+Tab is better since it is
- easier to understand (not everyone knows what Backtab is)
- more consistent with other shortcuts containing Shift:
  we use Alt+Shift+1, instead of Alt+Shift+!
- more consistent with how user defined shortcuts with Shift and Tab are
  displayed and stored

BUG: 422713
FIXED-IN: 6.0
2023-12-19 09:08:55 -08:00
Alexander Lohnau
82780effc1 Avoid Qt module incldues
This causes a longer compile time, because lots of unneeded files are
included. With https://invent.kde.org/sdk/clazy/-/merge_requests/91/
lots of false positives in the clazy check were resolved, this commit
takes care of the remaining places
2023-12-19 15:23:22 +00:00
Alexander Lohnau
3e5ae3b247 windowsrunner: Deduplicate/optimize strings 2023-12-19 15:23:22 +00:00
Alexander Lohnau
11d813625a windowsrunner: Reuse QVariantMap object 2023-12-19 15:23:22 +00:00
Alexander Lohnau
e3ab09dbd3 windowsrunner: Make dummy implementation of Action method inline 2023-12-19 15:23:22 +00:00
Vlad Zahorodnii
624da13e21 core: Specify explicit OutputTransform::Kind enum values
Some OutputTransform code assumes that Kind enums have specific values.
In order to ensure that that code doesn't break if the enums are reordered
or something, this change sets output transform enums to those explicit
values.
2023-12-19 17:08:13 +02:00
Vlad Zahorodnii
b3b43acc60 autotests: Slightly reduce line width in TestOutputTransform 2023-12-19 17:08:13 +02:00
Vlad Zahorodnii
3a4eebddc9 core: Rework OutputTransform::combine()
The naive way to combine output transforms is not great, especially
because of the for loop.

The output transform kind enums have the following bit pattern:

- rotate-0:   000
- rotate-90:  001
- rotate-180: 010
- rotate-270: 011
- flip-0:     100
- flip-90:    101
- flip-180:   110
- flip-270:   111

`(rotate-a + rotate-b) & 0x3` can be used to combine two rotation
transforms. The rotatation is clockwise.

If the first transform is a flip transform, then we should rotate
counter-clockwise, i.e. `(rotate-a - rotate-b) & 0x3`.
2023-12-19 17:08:13 +02:00
Xaver Hugl
50346b6e37 core: Introduce OutputTransform::combine()
Co-authored-by: Vlad Zahorodnii <vlad.zahorodnii@kde.org>
2023-12-19 17:08:13 +02:00
Yifan Zhu
bc73e14e68 tabbox: match Shift+Backtab against Shift+Tab
When users simultaneously press Shift and Tab, the keys are sometimes
registered as Shift+Tab, and sometimes as Shift+Backtab.
So we need to match received Shift+Tab against shortcuts containing
Shift+Backtab, and vice versa. Previously the code only checks for
the first case. This commit adds checks for the second case.

BUG: 438991
FIXED-IN: 6.0
2023-12-19 10:00:08 +00:00
Aleix Pol
a02545e8f5 glshadermanager: Fix nv12 shader for older versions of opengles
It wasn't compiling for PowerVR drivers.
2023-12-19 09:37:17 +00:00
Vlad Zahorodnii
c45ee91ab2 plugins/showpaint: Snap repaint region to the pixel grid 2023-12-19 11:00:30 +02:00
Vlad Zahorodnii
2e78ae2b6d core: Fix pixel grid snapping in RenderViewport
Our painting code is assumed to work as following: scale the geometry,
snap it to the pixel grid, apply the render transform, e.g. flip the
geometry vertically.

However, with QMatrix4x4 in RenderViewport, we have a slightly different
order: scale the geometry, apply the render transform, snap to the pixel
grid. It results in mapToRenderTarget() not properly mapping logical
geometry to the device geometry, which later manifests as glitches.

BUG: 477455
2023-12-19 11:00:30 +02:00
Stefan Hoffmeister
44419d832d Decrease log level of reporting choosing backend
Automatic backend selection is a very normal by-design activity that warrants informing. Decrease from log level Warning to Info to avoid spoiling the log at too high of a log priority.
2023-12-19 08:43:36 +00:00
Vlad Zahorodnii
71326cc91c autotests: Add OutputTransform test 2023-12-19 08:30:38 +00:00
Vlad Zahorodnii
c5124a1daf core: Document what each OutputTransform does
Flipped transforms are very confusing because the order of mirroring and
rotatation transforms matters in some cases.
2023-12-19 08:13:58 +00:00
Vlad Zahorodnii
08d2ec835d Install more headers 2023-12-19 07:44:37 +00:00
Vlad Zahorodnii
b476d7f4c0 plugins/screentransform: Stop tracking disabled outputs
If an output is disabled, the Output object will be kept alive. That
means that the aboutToChange connection will be kept.

If the output is enabled again and its transform changes, its contents
will be captured more than once.

In order to fix, the screentransform plugin has to break the
aboutToChange connection.
2023-12-18 22:40:12 +00:00
Vlad Zahorodnii
1f5fb58d23 plugins/screentransform: Don't preemptively cancel screen animation
If two output configurations are applied consecutively, the screen
rotation animation may be cancelled too early.
2023-12-18 22:40:12 +00:00
Vlad Zahorodnii
bd5c566399 plugins/screentransform: Avoid mangling with opengl context when a screen is removed
For the most part, the screen transform effect is inactive. So if a
screen is removed, it's likely that m_states contains no entry for it.
2023-12-18 22:40:12 +00:00
Vlad Zahorodnii
e894f694ce plugins/screentransform: Avoid needlessly capturing screen contents
If the output configuration doesn't touch the output transform,
capturing the previous screen contents is pointless.

I believe the main reason why the screen transform operates this way is
because it couldn't access OutputConfiguration before.
2023-12-18 22:40:12 +00:00
Kai Uwe Broulik
699bdda60a plugins/windowsystem: Implement new virtuals
For XDG foreign support. No-ops.
2023-12-18 18:46:42 +00:00
Vlad Zahorodnii
4283ba00c6 scene: Snap DecorationItem texture coords to the pixel grid
Do the same what the SurfaceItem does.
2023-12-18 15:05:43 +00:00
Stefan Hoffmeister
3887542240 backends/drm: Detect mode content change instead of comparing mode pointers
This fixes Plasma Desktop / kwin resizing problems at least for virtual
machines running off the vmwgfx Linux kernel driver

BUG: 477985
2023-12-18 14:23:27 +00:00
l10n daemon script
01f59b20d1 GIT_SILENT Sync po/docbooks with svn 2023-12-18 02:53:06 +00:00
Vlad Zahorodnii
d733daf772 Drop dead code 2023-12-15 08:57:11 +00:00
l10n daemon script
e11ffbb612 GIT_SILENT Sync po/docbooks with svn 2023-12-15 02:13:13 +00:00
Xaver Hugl
51ff2e4c32 backends/drm: do glFinish after rendering on NVidia
Polling the dmabuf for readability doesn't appear to work on NVidia and
we're no longer using an egl surface where the driver does this for us,
so we need to explicitly wait for rendering to complete or there are glitches
on the output
2023-12-14 22:41:57 +00:00
Arjen Hiemstra
0ff4f84ace plugins/overview: Replace OpacityMask with ShadowedTexture
The OpacityMask is used purely for rounding the corners. We can get rid
of it by using ShadowedTexture which does the same thing while also
drawing the shadow, meaning we can also eliminate the ShadowedRectangle.
2023-12-14 13:44:28 +00:00
l10n daemon script
9c1b50bdba GIT_SILENT Sync po/docbooks with svn 2023-12-14 02:12:58 +00:00
l10n daemon script
510e776e80 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2023-12-14 02:06:54 +00:00
Vlad Zahorodnii
3663453c7d scene: Freeze SurfaceItem tree when the Window is closed
If the wl_surface is unmapped, the compositor should unmap the window.
Most clients don't do it, and instead destroy the wl_surface or the
surface role object or both. A very tiny fraction of clients actually
close the window by unmapping the wl_surface. Either way, it's worth
handling that case because xdg-shell protocol says that the clients are
allowed to do it.

BUG: 478297
2023-12-13 15:06:45 +02:00
David Edmundson
5dc16fc614 x11: Avoid calls to workspace in OverlayWindow and sync GLX and EGL paths
OverlayWindow had different paths for GLX and EGL when it came to
managing size. On EGL the initial size comes from the overlay resizing
to workspace, but future updates were explicitly handled by the backend.
On GLX the backend tracked changes, but then it was the overlay's job to
resize but using a different method.

This patch also prevents use of workspace after destruction fixing
kwin_x11 --replace.
2023-12-13 09:33:31 +00:00
Vlad Zahorodnii
76fbea704a plugins/slidingpopups: Cancel animations when screen is locked/unlocked
BUG: 412104
2023-12-13 08:19:40 +00:00
l10n daemon script
89b4b1f4a5 GIT_SILENT Sync po/docbooks with svn 2023-12-13 02:14:49 +00:00
Vlad Zahorodnii
ef2c4e201e plugins/overview: Load milou on demand
Milou.ResultsView loads runners regardless whether the query string is
empty. It's not clear what milou should do. There are valid arguments
both in favor and against preloading runners.

This change puts Milou.ResultsView behind a Loader so milou is loaded
when it's actually needed and not when starting overview.

CCBUG: 455780
2023-12-12 15:21:23 +00:00
Niccolò Venerandi
667b95e240 Make window captions in Overview 2 lines at most
Captions are set to elide with ElideRight, which does allow for multi-line captions.
However, this means that the height of the captions depends on their width (since a shorter
width results in more lines), and the width of the captions depends on the size of the
window thumbnail, which depends on the height of the caption to be positioned. If the
caption is really long, this can cause visual glitches. Having a maximum line value avoids that.

BUG: 477103
2023-12-12 13:55:41 +00:00
l10n daemon script
5ddc0b26dd GIT_SILENT Sync po/docbooks with svn 2023-12-12 02:16:29 +00:00
l10n daemon script
47e7f6e06a SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2023-12-12 02:09:54 +00:00