Commit graph

23649 commits

Author SHA1 Message Date
Nicolas Fella
5cab7c79b4 Revert "plugins/idletime: Adjust the poller to deprecation of simulateUserActivity()"
simulateUserActivity was un-deprecated

This reverts commit 4610aaf614.
2022-12-01 10:24:11 +00:00
Vlad Zahorodnii
8d04733682 plugins/nightcolor: Register its own service name
In order to make monitoring Night Color appearing and disappearing robust,
make Night Color register its own dbus service.

CCBUG: 428854
2022-12-01 09:56:15 +00:00
Nicolas Fella
a6a022f00f Port away from deprecated KWindowSystem API 2022-12-01 08:08:54 +00:00
l10n daemon script
1d640cc013 GIT_SILENT Sync po/docbooks with svn 2022-12-01 02:08:42 +00:00
l10n daemon script
3e13c516c4 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-12-01 01:50:26 +00:00
Vlad Zahorodnii
7c0cdcf472 backends/wayland: Fix input timestamp in relative motion events
RelativePointer::relativeMotion already provides us timestamps with
microseconds granularity, so we need to convert timestamps in vice versa
order.
2022-11-30 11:20:39 +00:00
l10n daemon script
a93ccbd7e7 GIT_SILENT Sync po/docbooks with svn 2022-11-29 02:12:05 +00:00
l10n daemon script
e691c169de 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-11-29 01:51:31 +00:00
l10n daemon script
f0660a01dc GIT_SILENT Sync po/docbooks with svn 2022-11-28 02:12:17 +00:00
Vlad Zahorodnii
65cd40e85d backends/wayland: Call wl_pointer.set_cursor when pointer enters an output
We must always call wl_pointer.set_cursor when the pointer enters the
surface.
2022-11-27 11:30:03 +00:00
Vlad Zahorodnii
c784217eae backends/wayland: Use software cursor when pointer is locked
Currently, if the pointer is locked, the wayland backend will create a
subsurface. However, when the cursor moves to one of the screen edges,
it looks weird because the xdg window geometry is computed as bounding
geometry of the main surface and its subsurfaces. However, even after
calling xdg_surface.set_window_geometry, it still looks weird because
subsurfaces are stacked above window decoration.

With the proposed change, when the pointer is locked, the wayland
backend will hide the host compositor and use the software cursor. If
the pointer is unlocked, it will go back to using host cursor.

Long term goal is to make every output have its own cursor to make
output layer logic simpler.
2022-11-27 11:30:03 +00:00
l10n daemon script
2fd9cc4fc1 GIT_SILENT Sync po/docbooks with svn 2022-11-27 02:05:46 +00:00
Luigi Toscano
c18a0b80bf Install translated documentation from po/ too
... when KDocTools is found.
2022-11-27 00:05:59 +01:00
Vlad Zahorodnii
711cdc7825 backends/wayland: Try to reallocate output layer data on beginFrame()
Mesa's implementation of wl_egl_window_resize() is pretty smart. It
avoids immediately resizing the buffers. On the other hand, its API
doesn't enforce that behavior and other implementations of wayland-egl
may choose to use a different strategy.

This change moves wl_egl_window_resize() to beginFrame() to make buffer
resizing handling more nicer. Also, for the record, the drm backend
works in similar fashion.
2022-11-26 13:54:22 +02:00
Vlad Zahorodnii
d8c42ec540 backends/wayland: Simplify pointer locking
At the moment, once the first output gets pointer locked, other outputs
release their locks. It's unnecessary, other outputs can keep their locks.
2022-11-26 11:36:02 +00:00
l10n daemon script
613cedcc15 GIT_SILENT Sync po/docbooks with svn 2022-11-26 02:06:16 +00:00
l10n daemon script
79b35e1070 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-11-26 01:50:13 +00:00
Vlad Zahorodnii
7a1f97754f wayland: Simplify implementation of xdg_toplevel.set_minimized 2022-11-25 07:43:45 +00:00
Vlad Zahorodnii
0987b55cdd wayland: Prefer input()->pointer()->pos() over cursor pos
On Wayland, the cursor primarily visual role, not functional.
Interactive move resize should get the position from the corresponding
input device.
2022-11-25 07:43:45 +00:00
l10n daemon script
777c2bdb18 GIT_SILENT Sync po/docbooks with svn 2022-11-25 02:13:15 +00:00
l10n daemon script
738820d438 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-11-25 01:51:47 +00:00
Vlad Zahorodnii
9e97c7383c Add support for DecoratedClient::windowClass() 2022-11-24 10:18:05 +00:00
Vlad Zahorodnii
b867f76d41 backends/wayland: Stop forwarding keymap and modifiers
These concepts are hard to map to InputDevice abstractions, so remove
them and let kwin use its own internal keymap instead (rather than
get it overridden by the host compositor's keymap) and track modifiers
based on the events it receives.

If the goal is to have these at any cost, I think the way out of it
would be to provide wayland backend specific signals. I would like to
avoid doing that though because it breaks encapsulation and we would
need some casts in kwin to wire in these events.
2022-11-24 09:34:53 +00:00
l10n daemon script
c1ecce9ec3 GIT_SILENT Sync po/docbooks with svn 2022-11-24 02:08:12 +00:00
l10n daemon script
d4b6c8f911 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-11-24 01:51:45 +00:00
Vlad Zahorodnii
b4569f5985 Add ShapeCursorSource
ShapeCursorSource provides the contents of the given cursor shape in the
Xcursor theme.

If the given cursor shape is animated, ShapeCursorSource will keep
updating its content based on the value of current sprite's delay value.
2022-11-23 20:10:59 +00:00
Vlad Zahorodnii
e552be6cb1 Add CursorSource
CursorSource acts as a black box providing the contents of the cursor.
That's it, the image and the hotspot.
2022-11-23 20:10:59 +00:00
Vlad Zahorodnii
f881bdf51b backends/drm: Use drmModeGetConnectorTypeName()
It ensures that connector type naming is consistent across compositors
and saves us some work adding string mappings.

drmModeGetConnectorTypeName() uses the same naming scheme as the drm
backend so the client side should be unaffected by this change.

CCBUG: 385135
2022-11-23 13:31:00 +00:00
Nicolas Fella
f764861157 Rename Touch Screen KCM to Touchscreen Gestures
To avoid a conflict with the new Touchscreen KCM under input devices
2022-11-23 10:47:54 +00:00
l10n daemon script
08173dbb06 GIT_SILENT Sync po/docbooks with svn 2022-11-23 02:20:01 +00:00
Xaver Hugl
f70caec4b3 backends/drm: drop explicit modifiers completely if no output config works
Removing modifiers one by one creates a huge amount of combinations that
can make KWin hang for a long time in some cases. Instead of doing that,
leave it up to Mesa to pick a modifier when a setup doesn't work, which
will generally result in the least amount of bandwidth used and should be
able to power all output combinations.
2022-11-22 16:28:38 +00:00
Xaver Hugl
6bb4ebdf04 backends/drm: set hdr metadata to 0
Otherwise we might have broken colors from leftover state of other compositors
2022-11-22 15:41:21 +00:00
Vlad Zahorodnii
af24f5b011 Remove Window.clientPos and Window.clientSize properties
The main motivation behind this change is to reduce the number of
geometry properties, in particular limit the use of clientPos that can't
be expressed as an alias to clientGeometry().topLeft().

The client geometry is not useful to scripts as they lack functions to
go from one type of geometry to another. The scripts use exclusively the
frame geometry.

The client geometry is not that useful in kwin too, similar to scripts,
almost all our window management code works with frame geometry. Client
geometry is useful when requesting the client to resize the window.
2022-11-22 13:40:09 +00:00
Xaver Hugl
a762f68c08 kcmkwin/kwincompositing: remove no longer relevant keywords 2022-11-22 12:57:54 +01:00
Nicolas Fella
8986091878 [libinput] Re-run touchscreen->output mapping when externally clearing output name
When setting a device's output name externally we assign the relevant output to the device

If we pass an empty name we set a null output, which causes a crash the next time the touchscreen is touched

Since passing an empty name semantically means 'Detect output automatically' rerun the mapping heuristic so we get a valid output
2022-11-22 11:15:07 +00:00
Xaver Hugl
a054093580 qAbs -> std::abs 2022-11-22 09:27:23 +00:00
Vlad Zahorodnii
bb53b21c4c wayland: Add more inert Output checks 2022-11-22 08:17:20 +00:00
l10n daemon script
5cfab52bb6 GIT_SILENT Sync po/docbooks with svn 2022-11-22 02:20:04 +00:00
Aleix Pol
df77fcd9e0 x11window: Calculate the native floor from the begining of the output
If this function is useful to make sure we are properly aligned with the
output's pixels, we should start with the output's 0, otherwise we'll be
carrying over the rounding errors increasingly as our workspace grows.

BUG: 459373
2022-11-21 14:16:33 +00:00
Xaver Hugl
cdeacdbdad backends/libinput: update screens on Workspace::outputsChanged
Using OutputBackend::outputsQueried can cause problems because it's emitted
before output settings like enablement get adjusted to the new output configuration.
It also doesn't react to output changes initiated by KScreen and is in the
way of plans to use multiple output backends at the same time.

BUG: 461901
2022-11-21 14:25:24 +01:00
Mouse Zhang
acb25fbd5e effects/blendchanges: move effect chain position after blur and backgroundcontrast 2022-11-21 16:17:28 +08:00
l10n daemon script
51ad320962 GIT_SILENT Sync po/docbooks with svn 2022-11-21 02:08:15 +00:00
l10n daemon script
a2c3645606 GIT_SILENT Sync po/docbooks with svn 2022-11-20 02:50:52 +00:00
l10n daemon script
9d1f7cde61 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-11-20 01:49:41 +00:00
Xaver Hugl
cf3b167d50 effects/kwinquickeffect: ensure view map doesn't contain a nullptr view
BUG: 462014
2022-11-19 13:48:01 +01:00
l10n daemon script
bd7a6bb65d GIT_SILENT Sync po/docbooks with svn 2022-11-19 02:10:54 +00:00
Xaver Hugl
681368d4cc VirtualDesktopManager: clean up API a bit
Using templates brings nothing except complexity here
2022-11-18 23:35:31 +01:00
Xaver Hugl
147f3509ea Refactor placement code
This removes the usage of x11 virtual desktop ids and makes the code a bit
more readable
2022-11-18 23:35:31 +01:00
Vlad Zahorodnii
8197bf8890 Remove Window.visibleRect property
Scripts don't paint so the visible rect is no of use to them.
2022-11-18 20:04:09 +02:00
Vlad Zahorodnii
3d0101e127 Move window XID properties to X11Window
Scripts can't use platform specific apis so it makes little sense to
have these properties. On the other hand, they can be useful for debug
console.
2022-11-18 19:58:54 +02:00