Commit graph

27031 commits

Author SHA1 Message Date
David Redondo
56f99cb6f4 Fix debug console indices
These were off by one because the surface tab was removed.
Insetad of numbers look up the indices of the widgets so its
less prone to break in the future.
2024-07-15 13:26:05 +00:00
Vlad Zahorodnii
80a86034d0 Remove modifier_only_shortcuts.cpp
Amends c05a26f5c4.
2024-07-15 13:08:47 +00:00
Vlad Zahorodnii
4bf9a208c9 Revert "Handle null input devices in WheelEvent"
This reverts commit c342d57116.
2024-07-15 12:55:28 +00:00
Vlad Zahorodnii
a23ebe12ac Drop leftover infrastructure for modifier only shortcuts 2024-07-15 12:55:28 +00:00
Vlad Zahorodnii
12c12b3af1 Skip processing key and pointer event spies on X
These were needed for the modifier only shortcuts event spy, which has
been dropped recently.
2024-07-15 12:55:28 +00:00
Vlad Zahorodnii
2adf962467 plugins/nightlight: Relax custom times constraints
Apparently the night light kcm allows to set the custom times so the
evening is earlier than the morning to handle extreme cases close to
the North and the South pole.

NightLightManager::updateTransitionTimings() should require no changes.

BUG: 489366
2024-07-15 12:16:50 +00:00
Xaver Hugl
d3bb8ceaae wayland: update to xx color management v3
There's no change in features yet, they'll be added by future commits
2024-07-15 12:05:20 +00:00
Xaver Hugl
a1a0616dc0 workspace: don't access waylandServer on X11 2024-07-15 13:51:53 +02:00
Vlad Zahorodnii
07b31460ce wayland: Simplify XdgPopupWindow::sendRoleConfigure()
Use the precomputed relative placement rather than compute it again.
2024-07-15 07:41:43 +00:00
Vlad Zahorodnii
09e0345ccc wayland: Dismiss XdgPopupWindow when the parent window is closed
XdgPopupWindow can't exist on its own.

BUG: 472013
2024-07-15 07:41:43 +00:00
l10n daemon script
fef5791290 GIT_SILENT Sync po/docbooks with svn 2024-07-15 01:29:21 +00:00
Patrik Fábián
b84a6af8d3 backends/drm: Pass the correct arguments to encodingToNits in the ICC shader 2024-07-14 16:22:14 +00:00
Weng Xuetian
a16d98f4eb
Input method window should not break showing desktop
With recent change of using show desktop with plasma's edit mode,
wayland input method becomes unusable when trying to type in the search
box of widget explorer. This is because the input method window will
currently break showing desktop under wayland.

Under X11, an input method window is traditionally implemented as an
override redirect window. Under Wayland, the window should be treated
similarily, but now we have a special type for input method window.

BUG: 489057
FIXED-IN: 6.1
2024-07-13 23:35:29 -07:00
l10n daemon script
d6f3fb5a27 GIT_SILENT Sync po/docbooks with svn 2024-07-14 01:25:54 +00:00
Xaver Hugl
3c87b7476e backends/drm: always expose brightness control
This allows the user to change the brightness level of content even if there's no
actual underlying "backlight" device. This is the case with many internal OLED
screens for example.

BUG: 413451
2024-07-14 00:03:28 +00:00
Xaver Hugl
faba2b6286 wayland: add support for controlling brightness devices exposed by powerdevil
This way, KWin can set the brightness on internal panels or external monitors with
DDC/CI support, without being exposed to the mess that is actually directly setting
the brightness.

This also adds a capability flag for brightness control to the output management
protocol. Powerdevil will expose a brightness slider for each output and change the
brightness setting of the output accordingly. KWin in turn changes the brightness
levels of the actual brightness device, or of a multiplier in compositing accordingly.
2024-07-14 00:03:28 +00:00
l10n daemon script
7ad1303795 GIT_SILENT Sync po/docbooks with svn 2024-07-13 01:28:15 +00:00
Joshua Goins
09003d03bc ButtonRebindsFilter: Support disabled buttons
It's sometimes wanted that you disable certain buttons on the device,
such as an annoyingly place side button on a drawing tablet. This now
makes it possible to do so by putting "Disabled" in the config. The
rebind filter will then ensure the events are stopped and none are
emitted.
2024-07-12 22:57:22 +00:00
David Edmundson
5b17454aa5 eis: Change default logging category to warning
This makes it consistent with other debug categories

BUG: 489957
2024-07-12 13:39:12 +01:00
l10n daemon script
7891ee6c41 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"
2024-07-12 01:19:11 +00:00
Xaver Hugl
de8bd8f126 plugins/fadingpopups: don't block direct scanout
The effect only modifies the opacity of individual windows that
WorkspaceScene::scanoutCandidate will reject anyways, so there's no reason
for it to block direct scanout.
Once a more proper solution for blocking direct scanout on individual items
is in place, this can be removed again

BUG: 487780
2024-07-11 16:54:25 +02:00
Kristen McWilliam
6d7a9a6416 docs: update testing instructions
Updates the testing instructions with instructions
for running safely, without affecting the user's
running session.
2024-07-11 13:56:23 +00:00
Vlad Zahorodnii
9240d75e51 plugins/screencast: Don't download texture data if target size and texture size mismatch
If glGetTexImage() gets called, it can write beyond the bounds of the
target size. In long term, it would be nice to relax this check.

CCBUG: 489764
2024-07-11 09:49:26 +00:00
Vlad Zahorodnii
a6743fd2f5 plugins/screencast: Allocate offscreen texture in WindowScreenCastSource::render(QImage) as big as the memfd buffer
textureSize() can temporarily mismatch the target buffer size. It can be
a problem if glGetTexImage() gets called. glGetTexImage() assumes that
the provided buffer is as big as the texture. If it's not, it will write
data outside the bounds of the buffer.

BUG: 489764
2024-07-11 09:49:26 +00:00
Vlad Zahorodnii
abd790c4b5 autotests: Skip testScreencasting in CI
pipewire 1.2 has a known regression where the client's process callback
will not be triggered if the producer has sent only one buffer.

The issue has already been fixed upstream
525360d70a

Until our CI picks up that change, temporarily disable the test to unblock
merging patches.
2024-07-11 09:34:34 +00:00
l10n daemon script
f534aa2d24 GIT_SILENT Sync po/docbooks with svn 2024-07-11 01:26:38 +00:00
Nicolas Fella
6f410383fc Foward modifiers after disabling sticky keys
When disabling sticky keys while a key is latched or locked we unlatch the key, but don't tell the client until the next key event

Call forwardModifiers to tell the client immediately
2024-07-10 10:32:49 +00:00
Nicolas Fella
e14e4a1f8e Fix comment in test
The intent is that the key is *not* locked
2024-07-10 09:35:31 +00:00
Nicolas Fella
463d77ec18 Fix sticky keys for AltGr
We map AltGr to Qt::GroupSwitchModifier, but then ignore it

Instead map it to Mod5, which for some reason xkbcommon doesn't expose a define for

Also, since the Qt modifiers enum doesn't map nicely to XKB modifiers introduce our own enum to avoid confusion

CCBUG: 444335
2024-07-10 09:35:31 +00:00
Vlad Zahorodnii
18535ea959 Track xwayland buffer scale in X11Window
It can happen that when the xwayland scale factor changes, the logical geometry
will remain the same, but the x windows still need to reconfigured to update the
native geometry.

In order to address that, this change makes X11Window track the buffer scale
so if the logical geometry is the same, the x windows will be still reconfigured
with the new xwayland scale.
2024-07-10 07:54:15 +00:00
Vlad Zahorodnii
3f7b26cd9a Use the same logic to configure window during normal resize and interactive resize
X11Window::doInteractiveResizeSync() configures the x windows but it only
does a half of the things that should be done. The rest of it is assumed
to be performed by X11Window::updateServerGeometry() when XSync request is
acked later. The current state is not ideal and error prone.

This change makes X11Window::moveResizeInternal() and X11Window::doInteractiveResizeSync()
share the same code to configure the x windows to simplify the code.

It also drops X11Window::m_last{Frame,Client,Buffer}Geometry to further
simplify the code and make X window geometry tracking even more robust.
2024-07-10 07:54:15 +00:00
Xaver Hugl
706d604305 autotests: add a color pipeline test for identity transformations
If identity transformations aren't properly optimized out, we can have additional
rounding errors and reduced performance. This test ensures that doesn't happen
2024-07-09 20:10:47 +00:00
Xaver Hugl
9f2741af9f core/colorpipeline: make the matrix identity check fuzzy
Otherwise, really small rounding errors can cause the pipeline to be much
more complex than it really needs to be
2024-07-09 19:52:40 +00:00
Vlad Zahorodnii
9ae6ca3481 autotests: Force breeze_cursors cursor theme
Distros like Fedora don't ship Vanilla-DMZ cursor theme.
2024-07-09 17:51:07 +00:00
Vlad Zahorodnii
3492f52179 autotests: Fix cursor shape in PointerInputTest::testMoveCursor()
The cursor during interactive move had been changed to the "grabbing"
cursor shape in d7772031b1.
2024-07-09 17:51:07 +00:00
Alik Aslanyan
3b34e9309b tiling: Don't put maximized windows in tile
After !5532 existing behavior in public scripting API was changed for maximized Windows.
Maximized Windows didn't have a tile on purpose.
This behaviour was changed, as after refactoring separate members for storing QuickTileMode in Window and tile itself were unified
Previously QuickTileMode::Maximize was only set in the Window itself in m_quickTileMode, while tile itself was removed (by setTile(nullptr)).

Current QuickTileMod for current Window isn't part of public scripting API, so it's okay to break it.

This restores compatability with scripts created for KWin 6.0.5 and earlier

BUG: 489463

Signed-off-by: Alik Aslanyan <inline0@pm.me>
2024-07-09 17:24:15 +00:00
Vlad Zahorodnii
230e456ffd plugins/screenshot: Port blitScreenshot() to glReadnPixels()
With glReadnPixels(), it can be guaranteed that the texture data won't
be written beyond the QImage buffer bounds.
2024-07-09 14:16:49 +00:00
Vlad Zahorodnii
d2df8ea9aa autotests: Make testTranslucency less flaky
There's a race condition between the window becoming ready for painting
and testing the translucency animation.
2024-07-09 11:36:10 +03:00
l10n daemon script
51d01a6616 GIT_SILENT Sync po/docbooks with svn 2024-07-09 01:25:34 +00:00
l10n daemon script
1d91268b6e GIT_SILENT Sync po/docbooks with svn 2024-07-08 01:27:00 +00:00
l10n daemon script
c835fd76a3 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"
2024-07-08 01:18:27 +00:00
l10n daemon script
f9ad0e9e45 GIT_SILENT Sync po/docbooks with svn 2024-07-06 01:29:25 +00:00
l10n daemon script
ce93b00285 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"
2024-07-06 01:18:59 +00:00
Xaver Hugl
f20ccabe80 backends/drm: do blending in gamma 2.2 space with color management too
This matches what we do without color management, and is more what users and app
developers expect. Going with linear blending before was mostly from it being more
"correct" / how physical blending of light works, but that doesn't really matter
when existing software expects it to behave differently.

BUG: 476868
CCBUG: 479755
2024-07-05 14:52:47 +02:00
Xaver Hugl
5b86dba6bf backends/drm: support arbitrary input transfer functions in the icc shader 2024-07-05 14:52:47 +02:00
Vlad Zahorodnii
50717a2f9a plugins/screencast: Clean up cursor scale tracking
Poll the screen cast scale from the source rather have code on top of
ScreenCastStream and ScreenCastSource that figures out by itself how the
cursor should be scaled. It ensures that the cursor size will be
consistent and it makes the ScreenCastStream initialization code simpler.
2024-07-05 07:08:48 +00:00
Kai Li
e4a272e166 wayland: add error handling for QFile::open failure in org_kde_plasma_window_get_icon
when creating a QDataStream object, if the file has not been successfully opened
before (file.open() fails), the created QDataStream object 'ds' may not function
properly. If you continue to perform the operation 'ds << icon;' in this case,
it may cause kwin to crash. Therefore, it is essential to ensure that the file
has been successfully opened before creating the QDataStream object.

Signed-off-by: likai <likai@kylinos.cn>
2024-07-05 09:33:01 +08:00
l10n daemon script
23e1f10c22 GIT_SILENT Sync po/docbooks with svn 2024-07-05 01:25:28 +00:00
Nate Graham
b0970bd6c7 kcms/desktop: make list items conform to HIG
* Use correct deletion icon (this isn't a file).
* Use alternating list backgrounds to help line up the content on the
  left and right.
2024-07-04 11:09:27 -06:00
Xaver Hugl
40f50c9d0f placement: ignore the active output with place under mouse
BUG: 488110
2024-07-04 18:44:14 +02:00