Commit graph

23361 commits

Author SHA1 Message Date
Vlad Zahorodnii
de3aa69c1e Fix some tests not building with Qt 6
Client-side wrappers for input-method-unstable-v1 fail to build because
wl_keyboard_interface is referenced in the header file generated by
wayland-scanner.

Unfortunately, qt6_generate_wayland_protocol_client_sources() forces
--include-core-only argument, this is addressed in Qt 6.4.1, but in
meanwhile let's ship a copy of Qt6WaylandClientMacros.cmake file until
the required Qt version is out.
2022-10-20 09:37:00 +00:00
Arjen Hiemstra
cc4787500d Allow specifying a render target scale for windows
This allows overriding the render target scale when rendering windows
and makes use of it in the screencasting plugin.
2022-10-20 08:20:51 +00:00
Arjen Hiemstra
ec6b9ed67e Convert WindowPaintData's translation to device coordinates when rendering
Otherwise we're using a translation in logical coordinates as a
translation in device coordinates, which means we're not translating
enough.
2022-10-20 08:20:51 +00:00
Arjen Hiemstra
ada87dbc60 Properly scale cursordelegate_opengl to device geometry
Rather than converting to logical to then later on convert back to
device.
2022-10-20 08:20:51 +00:00
Arjen Hiemstra
642bd06cef glide: Convert to device coordinates when rendering 2022-10-20 08:20:51 +00:00
Arjen Hiemstra
40e7dadbfe offscreeneffect: Convert to device coordinates when rendering 2022-10-20 08:20:51 +00:00
Arjen Hiemstra
154dd33857 touchpoints: Account for render target scale when creating geometry 2022-10-20 08:20:51 +00:00
Arjen Hiemstra
0133de12c3 zoom: Account for render target scale when creating geometry 2022-10-20 08:20:51 +00:00
Arjen Hiemstra
9e7a7afccc snaphelper: Account for render target scale when creating geometry 2022-10-20 08:20:51 +00:00
Arjen Hiemstra
846f612fcc trackmouse: Account for render target scale when rendering 2022-10-20 08:20:51 +00:00
Arjen Hiemstra
8d93ef0221 screencast: Account for output scale when rendering 2022-10-20 08:20:51 +00:00
Arjen Hiemstra
dea0383719 mousemark: Account for render target scale when creating geometry 2022-10-20 08:20:51 +00:00
Arjen Hiemstra
b730308e2f mouseclick: Account for render target scale when creating geometry 2022-10-20 08:20:51 +00:00
Arjen Hiemstra
cb093bfae4 screenedge: Account for render target scale when rendering 2022-10-20 08:20:51 +00:00
Arjen Hiemstra
f791eb8fa7 screenshot: Account for render target scale when rendering 2022-10-20 08:20:51 +00:00
Arjen Hiemstra
239bbf93f4 magnifier: Account for output scale when creating geometry 2022-10-20 08:20:51 +00:00
Arjen Hiemstra
6cfeb3e3e8 Require GLTexture::render() to provide an output scale
This ensures we render the texture at the right scale while providing
geometry information in logical coordinates.
2022-10-20 08:20:51 +00:00
Arjen Hiemstra
74ff3bf082 Account for render target scale when rendering a WindowThumbnailItem
Otherwise we get too large and cut off window thumbnails.
2022-10-20 08:20:51 +00:00
Arjen Hiemstra
5a85ecd8c4 Convert to device pixels when rendering an offscreen quick view
Rendering a texture needs to be done in device pixels, not logical
pixels.
2022-10-20 08:20:51 +00:00
Arjen Hiemstra
8a69432d76 EffectsHandler: Use QRectF for mapToRenderTarget 2022-10-20 08:20:51 +00:00
Arjen Hiemstra
2609458c8b screentransform: Account for render target scale when creating geometry 2022-10-20 08:20:51 +00:00
Arjen Hiemstra
78d2c1f7e0 showpaint: Account for render target scale when creating geometry 2022-10-20 08:20:51 +00:00
Arjen Hiemstra
5ab9008ca6 blur: Account for render target scale when creating geometry 2022-10-20 08:20:51 +00:00
Arjen Hiemstra
9b28744de0 backgroundcontrast: Account for render target scale when creating geometry 2022-10-20 08:20:51 +00:00
Arjen Hiemstra
822e6da569 Use a perspective matrix again for the Glide and Sheet effects
Since we now use an orthographic matrix as main projection matrix, the
glide and sheet effects don't really work as intended anymore. To fix
that, copy over the old perspective matrix and use that as base rather
than the current orthographic matrix.
2022-10-20 08:20:51 +00:00
Arjen Hiemstra
6ae32076f8 Use device coordinates for geometry in the OpenGL Scene
It is quite a bit easier to reason about the conversion to device
coordinates when we actually have code that does that, instead of
implicitly assuming OpenGL handles it. Additionally, it means we don't
need to convert back to logical coordinates again when we're rounding
pixel values.
2022-10-20 08:20:51 +00:00
Arjen Hiemstra
ebc5a6c638 Add scaledRect as a helper function to scale a QRectF by a scalar
I have no idea why QRectF doesn't have this...
2022-10-20 08:20:51 +00:00
Arjen Hiemstra
3922f468b4 Only recalculate renderTargetMatrix if it is needed
If there's no changes then there's no need to recalculate the projection
matrix.
2022-10-20 08:20:51 +00:00
Arjen Hiemstra
695cc7c010 Use an orthographic projection matrix for rendering the scene
Rather than a perspective matrix, which is rather unexpected when coming
from something like QtQuick. Generally, when doing 2D you want an
orthographic matrix so Z values do not matter.

Apparently this was originally done for 3D effects, but there are only
two of those remaining (glide and sheet) and for those, the effects
themselves can set up a perspective projection matrix.
2022-10-20 08:20:51 +00:00
Vlad Zahorodnii
085e44cdf9 scripts: Convert desktop metadata files to json metadata files 2022-10-20 07:12:31 +00:00
Vlad Zahorodnii
acc2336833 effects: Convert desktop metadata files to json metadata files 2022-10-20 07:12:31 +00:00
Vlad Zahorodnii
0c28de5b42 wayland: Add support for ext-idle-notify-v1
Wayland protocols MR: https://gitlab.freedesktop.org/wayland/wayland-protocols/-/merge_requests/29
2022-10-20 06:36:58 +00:00
Vlad Zahorodnii
28c19c8215 wayland: Make output subpixel info static
subpixel info cannot change.
2022-10-20 06:18:30 +00:00
Vlad Zahorodnii
146bed14bc wayland: Make OutputInterface pull information from Output
It's a necessary step towards killing src/waylandoutput.{h,cpp}. Besides
that, it makes OutputInterface more reusable and less error prone.
2022-10-20 06:18:30 +00:00
Vlad Zahorodnii
7734676aa1 autotests: Drop DontCrashCursorPhysicalSizeEmpty
wl_cursor is no longer used to load cursors on server side so the test
is irrelevant now.
2022-10-20 06:18:30 +00:00
l10n daemon script
a650f0b069 GIT_SILENT Sync po/docbooks with svn 2022-10-20 03:16:04 +00:00
l10n daemon script
665b7bb989 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"
2022-10-20 02:05:10 +00:00
Nicolas Fella
f3471293bf [desktopchangedosd] Port from KQuickControlsAddons.QIconItem to PlasmaCore.IconItem 2022-10-19 19:51:04 +00:00
Vlad Zahorodnii
187f556f85 Drop Screens 2022-10-19 13:29:39 +00:00
Nicolas Fella
9cf60224e6 [aurorae] Port from KQuickControlsAddons.QIconItem to PlasmaCore.IconItem 2022-10-19 11:55:23 +00:00
Gabriel Karlsson
02145bddce Fix wording in action 'Switch to Screen'
This erroneous "Window" instead of "Switch" apparently broke stuff.

The issue was pointed out on Reddit here: [https://www.reddit.com/r/kde/comments/y78qps/comment/istrj6t/](https://www.reddit.com/r/kde/comments/y78qps/comment/istrj6t/)
2022-10-19 05:33:11 +00:00
l10n daemon script
d7c091e449 GIT_SILENT Sync po/docbooks with svn 2022-10-19 02:08:11 +00:00
Xaver Hugl
850ae0cfe9 backends/drm: don't crash if connector has no modes 2022-10-18 11:21:45 +00:00
David Edmundson
50b4e988a4 [windowthumbnails] Guard against software QtQuick backend
If we are using the software renderer
QQuickWindow::createTextureFromNativeObject returns null. We already
checking for kwin using GL compositing so we can expand to check
QtQuick's usage.
2022-10-18 08:19:20 +00:00
Vlad Zahorodnii
1a87e9c9ac effects: Make WindowHeap try to fill gaps 2022-10-18 07:03:32 +00:00
l10n daemon script
3406c50d5e GIT_SILENT Sync po/docbooks with svn 2022-10-18 02:05:39 +00:00
Aleix Pol
212a19da38 screencast: Don't report damage on the full screen every time
I think this was added as a debug measure and we (I) forgot to remove
it.
While at it, make sure we always send the damage on the cursor changes.
2022-10-17 15:03:01 +00:00
David Edmundson
1df10c3518 Handle scale override in locked and confined pointers
BUG: 460532
2022-10-17 13:40:03 +01:00
David Edmundson
dae7d738a3 Move installPointerConstraint calls into the constraint handlers 2022-10-17 13:36:56 +01:00
David Edmundson
a43ef8ac91 Guard against reconfiguring wayland specific input on X11
reconfigure is hooked up to a config watcher that is applicable on X11
and wayland.

A runtime check is added to reconfigure, if we're not initialised we
have nothing to reconfigure. initialise calls reconfigure at the end of
the method.
2022-10-17 10:00:10 +00:00