25519 Commits (9d4fe3adf15dfd8a3147743058ba7a5a94fcdc6d)
 

Author SHA1 Message Date
Kristen McWilliam dd5ec684b7 `include-shadow` defaults to `true` so this isn't a breaking change 11 months ago
Kristen McWilliam 53a4faf4e6 refactor window geometry checking 11 months ago
Kristen McWilliam 5c8b85861e plugins/screenshot: make window shadows optional
Right now screenshots of windows always have drop shadows. This change
makes the shadows optional. Resolves a 7-year-old bug report in
conjunction with an incoming change to Spectacle.

BUG: 372408
11 months ago
Kai Uwe Broulik 3eb90b2c60 Adjust to KDecoration init API returning a bool
Will allow a fallback to client-side decoration when KDecoration init fails.
11 months ago
l10n daemon script 7e692c9cf0 GIT_SILENT Sync po/docbooks with svn 11 months ago
l10n daemon script f3012a3eda 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"
11 months ago
Kai Uwe Broulik 9f8b03cbe6 Window: Check parent windows for icon geometry
For instance, when a dialog isn't shown in the task manager.
Also matches what X11Window is doing.
11 months ago
Alexander Lohnau 6b83654560 useractions: Use static regex
The method is called quite often during KWins lifetime.
Because the pattern is constant, we can reuse the value instead of creating a new regex every time
11 months ago
Alexander Lohnau 08c3399568 useractions: Simplify for loops 11 months ago
Alexander Lohnau f842493563 x11_standalone_overlaywindow: Adjust initialization order
This fixes a clang warning about fields being initialized in a different order than they were declared
11 months ago
Alexander Lohnau 41f66a37a1 kscreenintegration: Do not use pointer in QMap as key
Sorting bases om memory addresses doesn't make sense, also, we have proper sorting using std::sort in the readOutputConfig method
11 months ago
Alexander Lohnau 55c58e72a6 kscreenintegration: Utilize QJsonObject QLatin1String overloads for faster lookups
We have a dedicated QLatin1String overload which is faster at runtime and smaller at compile time
11 months ago
Alexander Lohnau 778c85343b debug_console: Avoid iterator usage on temporary return value
This works, because the value is not modified. Hwoever, it is an antipattern and can easily break
11 months ago
Alexander Lohnau 4a8d952544 plugins/windowview: Remove unused gestureCallback lambda
The usages were removed in 028dd552cf, but the lambda remained
11 months ago
Xaver Hugl 87a7033ca6 main: use kcminit correctly 11 months ago
Xaver Hugl 10eeba06f8 main_wayland: set Xwayland scale after Xwayland starts 11 months ago
Xaver Hugl 1ff3cd9684 main: set config values for fonts and style KCMs to do their job 11 months ago
Xaver Hugl 657aa35d8f Revert "main: directly set Xwayland scale, instead of starting a KCM to do the same"
This reverts commit 2eb72d0820. The KCMs set more than just
the DPI, so it's best to keep running them
11 months ago
Xaver Hugl 2b79316e4b plugins/colorpicker: use glReadPixels instead of glReadnPixels
We always know the data for the single pixel will fit into the buffer, so
it's unnecessary to use the checked variant (which is only available in
OpenGL 4.5)
11 months ago
Xaver Hugl f69c622831 plugins/colorpicker: make sure values aren't clipped
With the floating point buffer used with color management, storing values into
uint8_t won't always work
11 months ago
l10n daemon script d7a88fb7bc GIT_SILENT Sync po/docbooks with svn 11 months ago
l10n daemon script 4719013aa5 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"
11 months ago
Nicolas Fella 2e3881b14d Adapt to KWindowSystem API change 11 months ago
Vlad Zahorodnii 754b549f01 Restart compositing if kwinrc changes only on X11
On Wayland, options don't influence compositing as on X11. For example,
kwin cannot easily switch between compositing modes, etc.

One can still force kwin_wayland to reinitialize compositing by using
the dbus api.
11 months ago
Vlad Zahorodnii 49b84ddf8c Avoid destroying effects if animation speed changes
It makes little sense to destroy effects if the animation speed changes.
The effects are written with the assumption that the animation time can
change and therefore they handle this case in reconfigure().
11 months ago
Vlad Zahorodnii f22da5f62a Fix reloading animation speed option
Amends 4d2c9f5d88.

Prior to 4d2c9f5d88, the Compositor used
to force the Options to reload settings when starting compositing.

Unfortunately it was overlooked that Options::animationTimeFactor() can
return an old value when the Options::animationSpeedChanged() signal is
emitted. This change addresses that.
11 months ago
Vlad Zahorodnii 3af30c4250 kcms/screenedges: Fix Overview not being displayed
Scripted and builtin effect metadata formats are no longer compatible.
So KPackageLoader doesn't list builtin effects anymore. To address that,
load builtin effect metadata manually.
11 months ago
l10n daemon script 65db053ba6 GIT_SILENT Sync po/docbooks with svn 11 months ago
l10n daemon script 863a81ba6d 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"
11 months ago
Vlad Zahorodnii 509b9e8e3f scripting: Reload SceneEffect configuration when effect is reconfigured
This ensures that the SceneEffect uses new settings when KCM changes
them.
11 months ago
Vlad Zahorodnii bf602ccd44 kcms/screenedges: Fix listing of effects
Effects have KWin/Effect package type.
11 months ago
Laurent Montel bc6116c5a7 There's no QVector anymore, QList is the QVector in Qt6 11 months ago
Vlad Zahorodnii f9163bf6a5 Clear X11 cursor cache when XCB connection changes
We need to clear it because if Xwayland restarts, the future Xwayland
instance may have different cursor ids.
11 months ago
Marco Martin 2eabd17547 Adapt to KSvg api changes
Size/elementSize is a QSizeF now.

Depends on https://invent.kde.org/frameworks/ksvg/-/merge_requests/29.
11 months ago
ivan tkachenko 07dd2a5086
Port implicit default content items to use contentItem: property
See also
https://invent.kde.org/frameworks/kirigami/-/merge_requests/1338
and
https://invent.kde.org/frameworks/kirigami/-/merge_requests/1340
11 months ago
Vlad Zahorodnii 7ae4497d5b Specify scripted effect kcm using X-KDE-ConfigModule
At the moment, if an effect wants to have a configure button in the
desktop effects kcm, it needs to add X-KDE-PluginKeyword field with
its plugin id. This is confusing.

This change ports scripted effects to X-KDE-ConfigModule, which is more
intuitive than X-KDE-PluginKeyword.

kcm_kwin4_genericscriptedconfig is a special config module that loads
config.ui from KPackage. However, an effect can specify a different
config module in the metadata if kcm_kwin4_genericscriptedconfig doesn't
suit their needs.
11 months ago
Vlad Zahorodnii 2c29dfd596 libkwineffects: Make SceneEffect fallback to root context
QuickSceneEffect can also be instantiated by C++, for example that's
the case with the overview effect. In that case, qmlContext() is not
going to return a valid context because the effect has not been created
by a QQmlEngine. In that case, use the root context as the parent
context.
11 months ago
Aki Sakurai aa57e9130b Fix misgenerated QHoverEvent
https://doc.qt.io/qt-6/qhoverevent.html#oldPos

https://doc.qt.io/qt-6/qhoverevent-obsolete.html#pos

oldPos: On QEvent::HoverEnter events, this position will always be QPoint(-1, -1).

pos: On QEvent::HoverLeave events, this position will always be QPoint(-1, -1).

On the same app, such as Wayland-enabled VS Code, the misgeneration causes the cursor to move to the origin when moving the cursor away from the server side decoration.
11 months ago
Joshua Goins e398289287 Add QKeySequence to VirtualDesktopManager::addAction overload
There are four usages of this overload, two of them are for the
intentionally disabled "Switch to Next/Previous Desktop" actions and the
rest are for "Switch One Desktop to X" actions. Due to the order they
were added, an empty keybind was set as the default and the actual
keybind is never enabled.

Now there's a QKeySequence argument to this overload, so an unexpected
empty keybind is never added. The two usages of addAction that depend on
this empty keybind behavior now pass in an empty QKeySequence.

BUG: 475748
11 months ago
Vlad Zahorodnii be88c8ec49 libkwineffects: Drop OffscreenQuickView::repaintNeeded connection in SceneEffect
It's no longer needed since views are not updated in the post paint
stage anymore.
11 months ago
Vlad Zahorodnii 066492ef1d libkwineffects: Make dirty view tracking more robust in SceneEffect
It's possible that a view can request a repaint again in update(). If
that happens, we don't want to overwrite the dirty state after update().
11 months ago
l10n daemon script b4717ca590 GIT_SILENT Sync po/docbooks with svn 11 months ago
Vlad Zahorodnii 3eb64535d8 examples/quick-effect: Change license of main.qml
Apparently CC0 is not okay with KDE's licensing policies.
11 months ago
Vlad Zahorodnii 3817fc096f libkwineffects: Add QuickSceneView.rootItem property
The root item property can be useful if a QML effect needs to invoke
some function for particular screen delegate.
11 months ago
Vlad Zahorodnii d7345a77ce libkwineffects: Expose QuickSceneEffect::{viewForScreen,viewAt} to QML 11 months ago
Vlad Zahorodnii 264ebe6377 scripting: Add qml effect bindings
This allows creating third party qtquick scene effects without linking
to libkwineffects and thus rebuilding the effect every kwin release.
11 months ago
Vlad Zahorodnii 793a0e72bf scripting: Add gesture handlers 11 months ago
ivan tkachenko 264b054c5c
kcms/screenedges: Fix buttons overlap on a too narrow vertical screen
BUG: 475579
11 months ago
ivan tkachenko 6c67b73b7d
kcms/screenedges: Slightly refactor monitor size calculation
It doesn't need width when it's going to be scaled with KeepAspectRatio
to some other rectangle anyway, so using constant 1.0 makes it clearer.
11 months ago
ivan tkachenko c5d692843f
kcms/screenedges: Remove commented out dead code 11 months ago