Commit graph

24929 commits

Author SHA1 Message Date
Xaver Hugl
e55c9e924e platformsupport/egldisplay: fix external_only filtering for implicit modifiers 2023-06-27 21:26:14 +02:00
ivan tkachenko
b270ff92ae
kcms/scripts: Relax Kirigami import version
Needed to make DisplayHint type available, which is registered as 2.14.

Amends 899bef4126
2023-06-27 20:24:04 +03:00
ivan tkachenko
899bef4126
kcms/scripts: Set text of Delete action correctly
Fixes missing text on the menu item in ActionToolBar's menu.
2023-06-27 18:43:29 +03:00
Laurent Montel
c7ccf91d92 We use Qt6/kf6 only 2023-06-27 04:45:01 +00:00
l10n daemon script
b23d707e0c GIT_SILENT Sync po/docbooks with svn 2023-06-26 02:30:08 +00:00
l10n daemon script
edcd52dd9f GIT_SILENT Sync po/docbooks with svn 2023-06-25 02:53:10 +00:00
David Edmundson
b22e58846a contrast: Improve performance
glCopyTexSubImage2D is super slow on Intel GPUs on wayland.

We have an existing method to read from the framebuffer that is used in
the blur and other effects.

Rather than creating a scratch framebuffer every frame we keep a cache
per window for the lifespan of the effect.

BUG: 469151
2023-06-24 07:54:34 +00:00
l10n daemon script
2d53204738 GIT_SILENT Sync po/docbooks with svn 2023-06-24 02:52:03 +00:00
l10n daemon script
c817568735 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-06-24 02:48:07 +00:00
Aleksei Bavshin
f70bda9f6d
locale1: fix use-after-free in xkb_keymap creation
qPrintable creates temporary objects that are destroyed before
`xkb_keymap_new_from_names` is called. It's highly likely that the data
we pass to xkbcommon will be overwritten by random data by that point.

Fix that by storing values as QByteArrays just like
`Xkb::loadKeymapFromConfig` does.
2023-06-23 03:14:09 -07:00
Xaver Hugl
cd94cdaf3a plugins/backgroundcontrast,blur: ensure the effect is only applied behind the window
When a window is translated and/or scaled, the effect must be strictly behind the
window and never beyond it, as that is very noticeable.

BUG: 469625
2023-06-23 08:45:21 +00:00
Vlad Zahorodnii
acf1333bee plugins/overview: Precompile qml code
This saves us qml parsing extra step.
2023-06-23 08:01:03 +00:00
Vlad Zahorodnii
16cc0f5ebb autotests: Make test framework a static lib again
Static plugins being linked with shared libraries doesn't work smoothly.
POSITION_INDEPENDENT_CODE target property needs to be set for
every such plugin. However, there can be targets that we have no control
over, which need POSITION_INDEPENDENT_CODE to be set too. Asking such
projects to add this property and them refusing to do so would be
reasonable because kwin's entire static plugin pipeline is weird.

The test framework was made a shared library because kwin build
directory used to get really big (in 10s of gigabytes).

Due to the -fPIC issues, this change makes the test framework a static
lib again. Obviously, this brings back the big build directory problem.
But, it's not as terrible as it used to be. With this change, kwin build
directory is a couple of gigabytes in debug build, which is a lot but
not as bad as it used to be before.
2023-06-23 08:01:03 +00:00
David Edmundson
6d83ce30af wayland: Update window caption suffix on map
Window captions have a suffix for disambiguation, based on window
captions of other mapped windows.

In xdgshell we update this when a caption changes, but this could be
before a window is mapped. This can lead to two windows at once having
the same suffix, as a suffix could be used but not in the list of
searched clients.

BUG: 450369
2023-06-23 07:32:18 +00:00
l10n daemon script
666c8d69c9 GIT_SILENT Sync po/docbooks with svn 2023-06-23 02:37:27 +00:00
l10n daemon script
5dbe7d7adc 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-06-23 02:33:21 +00:00
l10n daemon script
acd281f04d GIT_SILENT Sync po/docbooks with svn 2023-06-22 02:30:21 +00:00
Laurent Montel
d604f4ed16 Remove PlasmaCore qml module (unused) 2023-06-21 22:18:40 +02:00
Marco Martin
569e0f8f64 Port to KSvg
port Svg and FrameSvg items to KSvg
2023-06-21 15:16:39 +00:00
Xaver Hugl
2132dddf0d layershellv1window: don't destroy the window twice
Outputs get disabled before they get destroyed, so destroying the window
when the output gets disabled and when it gets destroyed causes the window
to be destroyed twice and run into an assert
2023-06-21 16:44:58 +02:00
Xaver Hugl
4d9a0d2306 input: don't crash if the internal handle is nullptr
Pointer focus can stay on a closed tooltip while focus updates are blocked,
so this needs to be checked for

BUG: 471285
2023-06-21 11:48:29 +00:00
Vlad Zahorodnii
3698127bc6 Drop InputConfig
The InputConfig was introduced to handle tests that don't have valid
kwinApp object. Those tests have been either reworked or dropped, so
let's drop the InputConfig to tidy the config stuff.
2023-06-21 10:48:50 +00:00
Vlad Zahorodnii
84c7d3cf4b autotests: Remove cursor.cpp from test framework sources
It's included because of InputConfig, but we don't need to include
cursor.cpp for this purpose.
2023-06-21 10:48:50 +00:00
Nate Graham
dd4f879ecd outputconfigurationstore: reformat comment
GIT_SILENT
2023-06-21 11:17:00 +02:00
Xaver Hugl
480f857d29 outputconfigurationstore: don't handle laptop lid closing yet
Interactions with KScreen cause settings to be reset to the default when the lid
gets closed, so handling lid closing in KWin needs to wait until KScreen no longer
writes configs

BUG: 471282
2023-06-21 11:05:42 +02:00
l10n daemon script
b850e55953 GIT_SILENT Sync po/docbooks with svn 2023-06-21 02:23:23 +00:00
l10n daemon script
af565b554c 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-06-21 02:20:14 +00:00
Nate Graham
3ca2870deb outputconfigurationstore: restore comment lost in migration from KScreen
This comment is important to explain the underlying reason *why* we have
different target DPIs for different device types.
2023-06-20 23:59:36 +02:00
Xaver Hugl
7872e7cb22 backends/drm: hardcode a list of known formats instead of querying egl for information on drm formats 2023-06-20 18:24:37 +02:00
Laurent Montel
7992813abc Remove unused import module (scripted) 2023-06-20 12:33:16 +00:00
Vlad Zahorodnii
df8cb7df3c wayland: Make surface damage buffer local
This allows us to avoid losing precision when updating surface pixmaps.
Surface damage needs special handling either way.

Another advantage from switching to buffer damage is that it lets us to
decouple surface textures from surface items, which is useful for making
surface helpers more reusable.
2023-06-20 08:27:18 +00:00
Xaver Hugl
d8e57f7886 backends/drm: improve multi gpu performance with NVidia as secondary GPU
With the Nvidia driver, linear textures are external_only, so additional
measures need to be taken to make the egl import path work

CCBUG: 452219
2023-06-20 09:59:42 +02:00
Vlad Zahorodnii
24bfca7959 Drop "Configure Window Manager" entry in user actions menu
Because the kcm list has to be maintained manually, it's prone to get
outdated and incomplete (it already is!). On the other hand, "configure
window manager" is somewhat redundant as same kcms can be opened in
system settings.
2023-06-20 06:01:59 +00:00
l10n daemon script
a97d05585a GIT_SILENT Sync po/docbooks with svn 2023-06-20 03:27:48 +00:00
Vlad Zahorodnii
056177cf98 backends/drm: Remove unused includes 2023-06-19 22:43:01 +03:00
Vlad Zahorodnii
9af2eb0bfc backends/drm: Drop EglGbmBackend::{importBufferObjectAsImage,importBufferObjectAsTexture}
They're unused.
2023-06-19 22:43:01 +03:00
Vlad Zahorodnii
d6a384627b autotests: Let drm test use host primary node to allocate buffers 2023-06-19 22:43:01 +03:00
Vlad Zahorodnii
dc70be404a core: Provide own dumb graphics buffer allocator
If a gbm_bo is allocated with GBM_BO_USE_WRITE, it will be backed by a
dumb buffer under the hood. However, it seems like neither gbm_bo_get_fd()
nor gbm_bo_get_plane_fd() would return valid file descriptors, which are
required to fill in DmaBufAttributes.

As an interim solution, this change makes the GbmGraphicsBufferAllocator
allocate dumb buffers on its own rather than delegate it to gbm.
2023-06-19 22:43:01 +03:00
Vlad Zahorodnii
e81fa52c76 backends/drm: Prefer egl import mode
The egl import mode ensures that there's a local buffer, which is
preferred as it minimizes the number of data transfers over PCIe.

With dmabuf, it's unclear what the driver will do. But the main takeaway
from discussion with mesa developers is that it's undesired for
gbm_bo_import() to migrate or perform data transfers behind the user's
back, it should be done explicitly.
2023-06-19 22:43:01 +03:00
Vlad Zahorodnii
082301920e backends/drm: Port to GraphicsBuffer
This change ports the drm backend to the GraphicsBuffer and
GraphicsBufferAllocator.

The main motivation is to unify graphics buffer abstractions across
various backends and to prepare it for output layers, which could be
nicer if we could have direct control over the buffers.
2023-06-19 22:42:58 +03:00
Vlad Zahorodnii
8fa6c5307b backends/drm: Reopen the drm node
GEM handles are not reference counted and are unique per drm file
descriptor.

With the upcoming changes, dmabuf and dumb buffers will be abstraced
using DmaBufAttributes.

The issue with it is that we need GEM handles to get a drm framebuffer.
drmPrimeFDToHandle() can be used to get the GEM handle for a drm file
descriptor, but we would hit the reference counting issues then and
potentially double close GEM handles.

In order to resolve that, this change makes the drm backend reopen the
drm node to get a new GEM handle namespace for rendering.
2023-06-19 16:47:26 +03:00
Vlad Zahorodnii
0a7bfcf1a3 backends: Remove concrete graphics buffer types 2023-06-19 16:47:26 +03:00
Vlad Zahorodnii
ea639ad170 core: Add GraphicsBuffer map flags
This allows to specify whether the graphics buffer will be read or
written. It's mainly needed to map our APIs to gbm APIs.
2023-06-19 16:47:26 +03:00
Vlad Zahorodnii
9bbe0cc4ac core: Allow GbmGraphicsBufferAllocator allocate dumb buffers
The drm backend needs to allocate both dmabuf and dumb buffers, for
example for multi-gpu import.

Allowing GbmGraphicsBufferAllocator to allocate dumb buffers allows us
to avoid using several buffer allocators in the drm backend.
2023-06-19 16:47:26 +03:00
Vlad Zahorodnii
7782cb6853 core: Add GraphicsBufferOptions::software
The software flag indicates whether the graphics buffer allocator needs
to allocate a buffer suitable for software rendering. Its intended usage
is to allow the gbm allocator to allocate both dmabuf and dumb buffers.
2023-06-19 16:47:26 +03:00
Vlad Zahorodnii
1833d790f5 core: Introduce GraphicsBufferOptions
GraphicsBufferOptions describes the properties of the allocated graphics
buffer.
2023-06-19 16:47:26 +03:00
Vlad Zahorodnii
bdc14f247e core: Allow allocating linear gbm buffers with implicit modifier 2023-06-19 16:47:26 +03:00
Vlad Zahorodnii
f579b073c9 core: Change type of DmaBufAttributes::{pitch,offset}
Change it to uint32_t[] to match drmModeAddFB() API.
2023-06-19 16:47:26 +03:00
Vlad Zahorodnii
b98f68d581 Use proper ellipsis in user actions menu
"…" is not same as "..."
2023-06-19 14:48:35 +03:00
l10n daemon script
754beff474 GIT_SILENT Sync po/docbooks with svn 2023-06-19 02:39:55 +00:00