Compare commits

...

434 Commits

Author SHA1 Message Date
l10n daemon script 8219d3714e GIT_SILENT Sync po/docbooks with svn 2024-04-22 03:54:29 +00:00
Xaver Hugl fbd780186c scene/workspacescene: don't check direct scanout candidates for a pixmap
We don't need a pixmap for direct scanout, and the drm backend destroys the pixmap
when direct scanout is successful... so this check created a loop of direct scanout
working and not working, and worse, the client reallocating its buffers each time.

BUG: 485639
BUG: 485730
BUG: 485712
CCBUG: 477016


(cherry picked from commit fba948b39f)
2024-04-21 14:55:10 +00:00
l10n daemon script 94401d00fb GIT_SILENT Sync po/docbooks with svn 2024-04-19 03:07:00 +00:00
Fabian Vogt 750fd5e8de Fall back to breeze_cursors if neither configured nor default can be loaded
Try harder to get some cursor theme loaded, otherwise the cursor is
invisible, which also makes it hard to fix the configuration.

Also add some warnings instead of failing silently.

(cherry picked from commit 01d224fa22)
2024-04-16 13:06:09 +02:00
David Edmundson fe5089925a Remove superfluous wake in dpmsinputeventfilter destruction
Workspace already makes sure to only dynamically delete the
dpmsinputeventfilter if all screens are currently on. This line to wake
all screens is therefore redundant.

It's problematic as it can cause a crash on final teardown when
workspace is destroyed.

BUG: 484861


(cherry picked from commit 3ed535dd67)

14cd96a8 backends: Remove superfluous wake in dpmsinputeventfilter destruction
2024-04-16 07:03:45 +00:00
Yifan Zhu fc3a2d0d5d scripting/windowmodel: match screen closest to center for filter
When filtering windows by screen, match the screen closest to the window
center, instead of testing whether the window is visible on the current
screen. The new method guarantees that when filtering by screen, the
window appears for exactly one screen. Previously windows spanning
multiple screens appear on all of them, and off-screen windows are not
shown in any screen.

BUG: 480028
BUG: 485337

FIXED-IN: 6.0.4


(cherry picked from commit 1a4606d990)
2024-04-11 19:16:32 +00:00
Vlad Zahorodnii f76b1947b1 wayland: Send data offer source actions only for dnd
It makes sense only with dnd and sending the source_actions events for
selections and primary selections tricks gtk into thinking that there
are drag motion events.

BUG: 464196


(cherry picked from commit ab1350b6a6)
2024-04-11 08:34:06 +00:00
Yifan Zhu 68532f178d screenedge: reset timer when pointer leaves edge
Currently the edge erroneously triggers when the pointer repeatedly
enters and leaves the edge in short durations. Send all events to edges,
and reset the timer when pointer leaves edge. Add corresponding test.

BUG: 441892
FIXED-IN: 6.0.4


(cherry picked from commit 9ca69cf50c)
2024-04-10 21:15:31 +00:00
David Redondo a516e9e6cd Mark windows for offsceen rendering in WindowThumbnailSource
This way if an effect wants to show such  window  that is for example
on a different virtual desktop it is updated live.
BUG:456280
FIXED-IN:6.0.4


(cherry picked from commit 1573d04b5a)
2024-04-10 14:27:33 +00:00
l10n daemon script 61217e1c8f GIT_SILENT Sync po/docbooks with svn 2024-04-10 03:21:37 +00:00
Vlad Zahorodnii 2d68d150dd plugins/screencast: Remove irrelevant code
testCreateDmaBuf() is going to use the GbmGraphicsBufferAllocator under
the hood.

The GbmGraphicsBufferAllocator works as follows: if you pass it the
DRM_FORMAT_MOD_INVALID modifier, the resulting GraphicsBuffer is going
to have the invalid modifier as well. So the receivedModifiers check
is unnecessary.


(cherry picked from commit 2014f9a382)
2024-04-09 09:45:26 +00:00
l10n daemon script 979c04335d GIT_SILENT Sync po/docbooks with svn 2024-04-09 03:20:05 +00:00
Vlad Zahorodnii a69fb4b958 plugins/screencast: Fix sizeof() of SPA_META_Header
At the moment, the sizeof the pointer is passed, but the size of the
struct must be passed instead.


(cherry picked from commit 7d557784a1)
2024-04-08 22:36:42 +00:00
Zack Rusin 16bac3dbe5 backends/drm: Force software cursor on vmwgfx
The hardware cursor on vmware virtual machines is missing. This is
likely related to issues with importing DRM dumb buffers through
prime on vmwgfx.
Force software cursor on vmwgfx to make sure cursor is visible and
working properly until the hardware cursor is fixed.
2024-04-08 23:29:46 +02:00
Zack Rusin 4bf2a5dd86 backends/drm: Fix redraw issues on vmwgfx
Disable the readability checks when running on vmwgfx. The DMABuf syncs
seem broken on vmwgfx and until they're fixed disable the readablity
checks to actually let KDE propertly redraw when running on vmwgfx.
2024-04-08 23:29:30 +02:00
Zack Rusin a941323e25 backends/drm: Fix the closefb ioctl
The DRM_IOCTL_MODE_CLOSEFB ioctl takes a struct drm_mode_closefb as
argument and not the framebuffer id as integer.

That distinction is important because the kernel side explicitly
checks whether the padding in drm_mode_closefb has been correctly
initialized to zero:
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/drivers/gpu/drm/drm_framebuffer.c#n494

Use drm_mode_closefb and thus make sure the kernel side is not reading
garbage when testing the padding.
2024-04-08 23:15:11 +02:00
Ian Forbes 6e4fae02c3 backend/drm: fix cursor hotspot enablement for virtualized drivers
DRM_CLIENT_CAP_CURSOR_PLANE_HOTSPOT can only be set after DRM_CLIENT_CAP_ATOMIC
has been enabled.

(cherry picked from commit bd2728fac1)
2024-04-08 21:52:54 +02:00
Vlad Zahorodnii 81ef5d3500 plugins/screencast: Add a n_datas guard
There's a crash in the onStreamAddBuffer() function. It's not totally
clear why the crash happens when accessing `chunk`.

This MR is a blind attempt to confirm that the crash is caused by wrong
n_datas value.

CCBUG: 483681
2024-04-08 13:39:38 +03:00
l10n daemon script 4bcf3d6ad5 GIT_SILENT Sync po/docbooks with svn 2024-04-08 03:19:17 +00:00
l10n daemon script b8c7f8d339 GIT_SILENT Sync po/docbooks with svn 2024-04-07 03:20:12 +00:00
Xaver Hugl 615177749e plugins/colorpicker: fix interaction with SDR brightness
Right now both source and target color descriptions have SDR brightness values,
and the target one gets used; in this case however the source brightness needs
to be used instead.

BUG: 484497


(cherry picked from commit b29b3db26d)
2024-04-06 13:52:14 +00:00
Xaver Hugl 9720ef2e23 backends/drm: signal dmabuf feedback if an unsupported modifier is used
Otherwise the per-surface feedback never gets updated, and direct scanout fails


(cherry picked from commit 38e2bf34cf)
2024-04-05 11:03:54 +00:00
Xaver Hugl 19ffe2ac41 scene/workspacescene: fix direct scanout checks with subsurfaces
The check ignored that subsurfaces could be not visible, not mapped, and also below
the parent surface


(cherry picked from commit 9c2035ca63)
2024-04-04 15:18:50 +00:00
Xaver Hugl 4919a8f007 backends/drm: actually prefer alpha formats again
The drm formats will never be the same, the intention was to check for bits
per color and bits per pixel

(cherry picked from commit da34191115)
2024-04-04 16:19:04 +02:00
Weng Xuetian 8b2ddc447e
Fix inconsistent default keyboard delay value used in kwin.
plasma-desktop/keyboard/keyboardmiscsettings.kcfg has the default value
600. When default value (600) is set from kcm, kwin will wrongly use its
own default value in the code (660, which is most likely due to a typo when the
code is initially written).

(cherry picked from commit 8c6ebee318)
2024-04-03 17:41:46 -07:00
Vlad Zahorodnii 135a9355ce Guard against negative screen indices in Workspace::xineramaIndexToOutput()
(cherry picked from commit baaa1db5d1)
2024-04-03 14:11:29 +00:00
Xaver Hugl 24e4a90637 backends/drm: don't do direct scanout with buffers that need cropping 2024-04-03 14:01:12 +00:00
Vlad Zahorodnii fc659638f6 Disable freebsd ci
It's broken and it blocks normal workflow.


(cherry picked from commit 57a79608da)
2024-04-03 13:38:24 +00:00
l10n daemon script 93a168df94 GIT_SILENT Sync po/docbooks with svn 2024-04-03 03:05:33 +00:00
Vlad Zahorodnii 9e89fe7e13 wayland: Emit closed signal immediately after marking the window as closed
The main motivation is to give users a chance to perform their cleanup.

(cherry picked from commit 7bb250826e)
2024-04-02 16:50:50 +03:00
Vlad Zahorodnii fcbeeb0581 Unset Window::tile() when the window is closed
If a window is closed, its geometry should not change. The window has to
leave its assigned tile so it's not possibly moved or resized.

(cherry picked from commit 28d6b5230a)
2024-04-02 16:50:41 +03:00
Yifan Zhu f53c62494a plugins/mousemark: clear drawing when no modifiers are pressed
Previously when drawing has length 1, it is not cleared. So the
remaining point in drawing can connect with the new point when the user
represses the modifiers, leading to a unexpected mark.

This ammends commit 46807b1a72.

BUG: 482297
(cherry picked from commit 5272c24301)
2024-04-02 12:06:38 +03:00
Yifan Zhu bb4262a621 plugins/mousemark: correct reserve size.
verts is now QVector<QVector2D>. So don't reserve 2x the size.

This ammends commit 617f3b9000.

(cherry picked from commit b4e15b28b6)
2024-04-02 12:06:31 +03:00
Vlad Zahorodnii 238dec820f plugins/screencast: Destroy renegotiate event
If I'm not mistaken, the renegotiate event is leaked. Also, its handler
function can be hypothetically called after thhe ScreenCastStream object
is destroyed.


(cherry picked from commit 4c384d1e9f)
2024-04-02 08:33:21 +00:00
Vlad Zahorodnii 8706a9356d plugins/screencast: Corrupt header to indicate that buffer has no data
SPA_META_HEADER_FLAG_CORRUPTED indicates that the buffer contains
absolutely no any data.

SPA_CHUNK_FLAG_CORRUPTED indicates that the buffer has no frame contents
but it can contain other data, for example cursor metadata.

(cherry picked from commit 0c49ae5360)
2024-04-01 11:44:56 +03:00
l10n daemon script 8597caf132 GIT_SILENT Sync po/docbooks with svn 2024-03-31 03:29:30 +00:00
l10n daemon script 4e33f715d3 GIT_SILENT Sync po/docbooks with svn 2024-03-30 02:52:20 +00:00
Jonathan Riddell f4289cd853 update version for new release 2024-03-28 14:31:33 +00:00
l10n daemon script fbb1705649 GIT_SILENT Sync po/docbooks with svn 2024-03-28 03:27:28 +00:00
Vlad Zahorodnii 166988cef7 plugins/screencast: Handle failing to import dmabuf
(cherry picked from commit 5c2314a6bd)
2024-03-27 15:54:20 +00:00
Vlad Zahorodnii 09e638ff55 plugins/screencast: Simplify damage calculation in region screen cast source
Whether the output is rotated should be irrelevant. The region screen
cast source handles scrapping fairly well blitting from rotated outputs.

(cherry picked from commit 8d3c06a178)
2024-03-27 10:44:38 +00:00
Vlad Zahorodnii 45fbfb7222 plugins/screencast: Drop "stream" in ScreenCastStream::streamReady
The word "stream" is redundant.

(cherry picked from commit d1fdb69946)
2024-03-27 10:44:38 +00:00
Vlad Zahorodnii 6e9f1f3eeb plugins/screencast: Rename ScreenCastStream::stop() to close()
This is to help disambiguating between the code that shuts down the
stream completely and one that pauses/resumes the stream.

(cherry picked from commit cd2a4de82f)
2024-03-27 10:44:38 +00:00
Vlad Zahorodnii f4230e4a09 plugins/screencast: Pause/resume source when stream is paused/resumed
(cherry picked from commit 7894db7504)
2024-03-27 10:44:38 +00:00
Niccolò Venerandi ee0dd6c8c5 Fix oversights on shortcut handling within Overview/Grid effect
BUG:482931


(cherry picked from commit c8e0568022)
2024-03-27 10:26:42 +00:00
l10n daemon script c9b94bbac0 GIT_SILENT Sync po/docbooks with svn 2024-03-27 03:27:50 +00:00
Vlad Zahorodnii 13e31baca8 tiles: Evacuate windows in CustomTile::remove()
(cherry picked from commit 9d3e87bd9d)
2024-03-27 01:33:41 +02:00
Vlad Zahorodnii 74060343a0 tiles: Use deleteLater() in CustomTile::remove()
Otherwise it seems that QQmlEngine can segfault.

(cherry picked from commit ea9691a2f5)
2024-03-27 01:33:35 +02:00
Jonathan Riddell 501ab30677 update version for new release 2024-03-26 14:23:27 +00:00
l10n daemon script f38fd572db GIT_SILENT Sync po/docbooks with svn 2024-03-26 03:30:10 +00:00
Vlad Zahorodnii 551100b469 plugins/screencast: Neutralize stopped streams
Streams are deleted with QObject::deleteLater(), it's still possible to
process some events before the stream is actually destroyed, which can
cause problems.


(cherry picked from commit 8428b4603c)
2024-03-25 20:24:41 +00:00
Xaver Hugl a1d0105836 backends/wayland: don't clear the format map on tranche_done
It's not per tranche, it's global. Clearing the map means we ignore formats
from non-preferred tranches entirely


(cherry picked from commit c6c99c1740)
2024-03-25 13:46:47 +00:00
l10n daemon script 91d0849250 GIT_SILENT Sync po/docbooks with svn 2024-03-25 03:24:42 +00:00
David Edmundson 760e35065e xwayland: Allow pushing to the clipboard without focus
X11 did not have a requirement that apps needed keyboard focus to update
a clipboard. Apps could copy things on click. With context menus and
grabs there can be no active window at this point.

Kwin tried to retrofit a requirement, which doesn't work in all cases.

Whilst there are security implications of reading a clipboard there are
no security issues about pushing a new clipboard. Gnome also allows X11
apps to push to the clipboard at any point.


(cherry picked from commit b2a48d09e7)
2024-03-22 14:17:39 +00:00
Nicolas Fella d8019dbf16 kcms/decoration: Fix crash when preview cannot be generated
m_bridge->createDecoration() can return nullptr. Most codepaths
already guard against that, but not all of them

BUG: 456531
(cherry picked from commit 0fef229587)
2024-03-22 13:58:48 +01:00
Vlad Zahorodnii f2a7876178 plugins/screencast: Prefer allocating 3 buffers per stream by default
The current default 16 is way too many. For example, when screencasting
a 4K output, about 500MB will be wasted.


(cherry picked from commit 831ca28f93)
2024-03-22 09:35:27 +00:00
l10n daemon script 9a029a423e GIT_SILENT Sync po/docbooks with svn 2024-03-22 02:55:08 +00:00
Vlad Zahorodnii ac831f0b97 plugins/screenshot: Fix a crash in ScreenShotSource2::marshal()
There are behavior differences between QFutureInterface and QPromise.
The QFutureWatcher::finished() signal will be emitted in both cases
when the promise reports results or it is canceled.


(cherry picked from commit 8bf1f9203b)
2024-03-21 14:16:48 +00:00
Vlad Zahorodnii 79fa595d25 plugins/screencast: Enqueue buffers immediately
There's still a crash in pw_stream_queue_buffer().

(cherry picked from commit a7e7923d6b)
2024-03-21 12:43:14 +00:00
Vlad Zahorodnii 2d0117de92 Disable placeholder output when removing it
The current assumption is that Output::enabledChanged(false) always comes
before Output::destroyed.


(cherry picked from commit 489cd31ee9)
2024-03-21 12:24:30 +00:00
l10n daemon script 3bb54d629f GIT_SILENT Sync po/docbooks with svn 2024-03-21 03:01:58 +00:00
Yifan Zhu 5af86d18f4 x11window: round border size to integral XNative units
Both frameSize and clientSize are rounded to integral XNative units.
So their difference must also be rounded to integral XNative units.
Otherwise we get cycles of rounding that can cause growing window sizes.

BUG: 481460


(cherry picked from commit 111657ad04)
2024-03-20 21:37:50 +00:00
Vlad Zahorodnii 045199f3a4 backends/drm: Guard against null m_frame in DrmAbstractOutput::{frameFailed,pageFlipped} 2024-03-20 15:44:48 +00:00
Vlad Zahorodnii e378a35d05 backends/drm: Reset m_frame when present fails 2024-03-20 15:44:48 +00:00
Vlad Zahorodnii ea8fa09e2d Fix warning about nullptr sender in QObject::connect()
When one sets "no border" property, the decoration can be null.


(cherry picked from commit 012c64b054)
2024-03-20 14:54:22 +00:00
Vlad Zahorodnii 0dbbcd83fe backends/drm: Handle failing to reopen drm node
Otherwise the drm backend will crash.


(cherry picked from commit 236baa63df)
2024-03-20 14:17:10 +00:00
Vlad Zahorodnii e2aec38015 Add more guards for closed windows
(cherry picked from commit 8934a31dad)
2024-03-20 14:06:58 +00:00
Vlad Zahorodnii c1c7de07aa wayland: Remove zombie ClientConnection from Display later
Otherwise it's theoretically possible to create a new ClientConnection
object for the zombie wl_client when its resources are being destroyed.
For example

- process early wl_client destroy notification
- the ClientConnection objects gets removed from the client list in Display
- process wl_resource objects getting destroyed
- if some code calls display->getConnection(zombie_client), it's going to
  reintroduce the client in the client list
- process late wl_client destroy notification, it's going to destroy the
  original and the clone ClientConnection object

This change prevents reintoducing a clone client object, by keeping the
original for a bit longer until it's actually destroyed. In the future though,
it would be great to kill the client lists in Display and ClientConnection,
and just use `static_cast<ClientConnection *>(wl_client_get_user_data())`.


(cherry picked from commit 442648edc0)
2024-03-20 13:52:14 +00:00
Vlad Zahorodnii d38a8d48a9 Don't trigger screen edge if the pointer is constrained
If the pointer is constrained, the screen edge may push the cursor back,
which will work not as expected. It's also undesired to trigger the screen
edge while the pointer is constrained by some surface, in general.


(cherry picked from commit 44b72823c2)
2024-03-20 13:37:02 +00:00
l10n daemon script 37ae820b29 GIT_SILENT Sync po/docbooks with svn 2024-03-20 02:59:09 +00:00
Xaver Hugl 0b2d8901ab pointer input: handle warp events differently from absolute motion events
As Wayland doesn't have a warp event yet, before this commit, warps were
dealt with like normal absolute motion events. This trips up games though,
which don't deal with actual absolute motion events well. As a solution
to that, until an actual warp event is a thing, we send a motion event with
a position + a relative motion event with no motion

BUG: 458233
CCBUG: 482476
(cherry picked from commit 630ba5fab4)
2024-03-19 20:31:58 +01:00
Vlad Zahorodnii fe1c814ee1 plugins/screencast: Improve code readability
(cherry picked from commit 3ebe34bc3f)
2024-03-19 14:38:30 +02:00
Vlad Zahorodnii bb1507eadf plugins/screencast: Guard against having no dmabuf data for particular buffer
(cherry picked from commit 75f94c7cd0)
2024-03-19 14:38:23 +02:00
Vlad Zahorodnii 5521920d31 plugins/screencast: Properly mark pw buffers as corrupted
(cherry picked from commit afbb878fca)
2024-03-19 14:38:15 +02:00
Vlad Zahorodnii 6000cca756 plugins/screencast: Clean up how pw_buffer is initialized
The offset and the stride of dmabuf can be set during the pw_buffer
initialization.

(cherry picked from commit 01fa6c0af0)
2024-03-19 14:38:08 +02:00
Vlad Zahorodnii 5164f6969e plugins/kpackage: Fix mainscript for declarative effects
(cherry picked from commit 7bfb4a93e2)
2024-03-19 11:40:57 +00:00
Yifan Zhu 90e070d004 window: fix interactiveMove exit condition
Previously the <= 1.0 test always succeeds in the first try, causing the
loop to exit prematurely.

BUG:  481610
(cherry picked from commit 701f914081)
2024-03-18 20:44:56 -07:00
l10n daemon script abeec73a47 GIT_SILENT Sync po/docbooks with svn 2024-03-19 03:02:51 +00:00
Vlad Zahorodnii 46d6ad9e94 plugins/screencast: Add missing Q_OBJECT
(cherry picked from commit 29135f188f)
2024-03-18 17:14:53 +00:00
Vlad Zahorodnii bd681c3c72 Fix the titlebar visibility check for small windows
Consider a window with the size of 50x100 and the titlebar height of 36px.
The maximum number of visible titlebar pixels is 1800, but the
titleBarRect() function reports 3600 instead, which is completely wrong.

Since the reported number of required visible pixels is wrong, the window
geometry constraining logic is mistriggered and it's possible to move the
window only by 1px.
2024-03-18 15:17:45 +00:00
Vlad Zahorodnii 808ff015ad plugins/screencast: Avoid closing dmabuf fds twice
dmabuf fds are owned by the GraphicsBuffer, which will be destroyed when
`m_dmabufDataForPwBuffer.remove(buffer);` is executed.


(cherry picked from commit fb7dd07076)
2024-03-18 14:52:40 +00:00
David Edmundson 745625f04d effects: Do not take ownership of QuickEffect::delegate
QuickEffect::setDelegate is exposed QML API.

The lifespan of assigned objects is therefore managed by the QML engine,
and we should be watching for deletion not actually deleting it.


(cherry picked from commit e13a30f00f)
2024-03-18 13:50:22 +00:00
l10n daemon script 5fd10faeca GIT_SILENT Sync po/docbooks with svn 2024-03-18 03:38:49 +00:00
Xaver Hugl e8f567b055 platformsupport/scenes/opengl: don't access std::nullopt
(cherry picked from commit af3bf939c5)
2024-03-17 17:44:07 +00:00
Xaver Hugl f1c132d329 platformsupport/scenes/opengl: advertise formats unnknown to KWin too
While KWin may not have information about the formats, that doesn't mean KWin
should filter them out - EGL can still import them, so allow clients to use them


(cherry picked from commit 2a13a33040)
2024-03-17 14:20:54 +00:00
l10n daemon script 26537fecfe GIT_SILENT Sync po/docbooks with svn 2024-03-16 03:44:48 +00:00
Harald Sitter 24610e67a3 keyboard_layout: always expose dbus interface
our plasmoid only listens to signals when the interface was found.
also when switching from 2 to 1 layout we'd emit a signal that the
layouts changed but then we'd throw away our interface leaving
the client wondering what happened to us (and consequently
printing warnings because our service wasn't found)

this specifically resulted in the plasmoid not getting layout event
changes when switching from 1 to >1

BUG: 449531


(cherry picked from commit 645db7fc90)
2024-03-16 02:25:50 +00:00
Méven Car 84412b22df wayland: DrmLeaseDevice, use Q_OBJECT macro
BUG: 483008
(cherry picked from commit aa465efa51)
2024-03-15 17:51:22 +01:00
l10n daemon script be43a33002 GIT_SILENT Sync po/docbooks with svn 2024-03-12 02:52:30 +00:00
Xaver Hugl e83e8503d6 plugins/screencast: fix the cursor being offset after changing the scale
When the scale of a screen is changed, the cursor parameters have to be
adjusted or the client will render it offset to the actual cursor


(cherry picked from commit 3a55351211)
2024-03-11 22:56:26 +00:00
Yifan Zhu 05ad71e9fc xkb: fix testing if on keypad
XKB_KEY_KP_9 is 0xffb9 while XKB_KEY_KP_Equal is 0xffbd and XKB_KEY_F1
is 0xffbe. So XKB_KEY_KP_Equal, instead of XKB_KEY_KP_9, has the maximum
keysym for keypad keys.


(cherry picked from commit 681752ada1)
2024-03-11 15:11:29 +00:00
David Edmundson 783a63e594 wayland: Only send artificial mouse up events for xwayland drags
Seat has to handle two types of drags; ones where clients are updated
through data device, and xwayland version where the drag target has
mouse events sents as pointer events. A mechanism to treat them
differently was introduced, but this former xwayland hack was not
included. We also don't need to send frame events when in datadevice
mode.

This reset of pointer state breaks electron.

(cherry picked from commit 044c9f0154)
2024-03-11 13:50:41 +00:00
David Edmundson 61f65ce98d wayland: Only partially revert send pointer leave on drag
This was changed to match the behaviour of other compositors.
However what kwin did before is more sensible.

Sending a leave event breaks cursor updates by design. See
https://gitlab.freedesktop.org/wayland/wayland/-/issues/444

This reverts commit 8a2d77e0a5
(cherry picked from commit 9302e84b95)
2024-03-11 13:49:59 +00:00
Marco Martin 29bfd35585 Properly intersect the shape with clipRect
That for loop in the end didn't have any effect,
actually compute the final region and return that one


(cherry picked from commit 609833e880)

609833e8 Properly intersect the shape with clipRect
2024-03-11 12:06:09 +00:00
l10n daemon script a54cd2ded4 GIT_SILENT Sync po/docbooks with svn 2024-03-11 02:52:38 +00:00
Xaver Hugl d549fee89e core/colorspace: fix ColorDescription comparisons
They used the sdr gamut wideness (which should've been removed) instead of
the sdr colorimetry

BUG: 482809


(cherry picked from commit 0360ce38e2)
2024-03-09 19:24:04 +00:00
l10n daemon script b225e135a2 GIT_SILENT Sync po/docbooks with svn 2024-03-09 03:03:11 +00:00
Yifan Zhu 369c3cbd7d utils/xcbutils: Don't call toXNative with unsigned integer
Instead use signed integers, to prevent the implicit cast from unsigned
integers to qreal.

BUG: 482687


(cherry picked from commit ea4fa87bc6)
2024-03-08 19:34:06 +00:00
Xaver Hugl cc7d710476 backends/drm: handle dumb buffer target correctly
It's independent of the multi gpu import mode

BUG: 482859


(cherry picked from commit f3d9e5c90c)
2024-03-08 17:08:31 +00:00
Vlad Zahorodnii aef8796c72 Port IdleDetector to QBasicTimer
QBasicTimer is lighter and it properly handles timeout values bigger
than INT32_MAX.

CCBUG: 482077
(cherry picked from commit e2cbed7060)
2024-03-08 13:27:07 +02:00
Vlad Zahorodnii 18882eefde Add timeout assert in IdleDetector
CCBUG: 482077
(cherry picked from commit 18e414443e)
2024-03-08 13:26:59 +02:00
Patrik Fábián ab8345a24c xdgshellwindow: Always update window position and size along all axes when fully miximizing window
BUG: 482086


(cherry picked from commit 40b8637ab8)
2024-03-08 09:11:57 +00:00
Nicolas Fella dbf1edcc41 Fix sending window to all desktops
NET::OnAllDesktops is a special desktop number (-1), desktopForX11Id will not return a desktop for it

When all desktops are requested pass an empty desktop list, the following code will handle it appropriately

BUG: 482670


(cherry picked from commit 7078f4e3af)
2024-03-08 08:32:59 +00:00
l10n daemon script 99cfa50a8d GIT_SILENT Sync po/docbooks with svn 2024-03-08 02:52:55 +00:00
Xaver Hugl 673f9a0ac5 backends/drm: also set legacy gamma after VT switches
Just like with modes, the gamma state is unknown after VT switches, and has
to be explicitly set again to ensure it's correct

(cherry picked from commit e4349536a3)
2024-03-07 13:22:29 +01:00
Xaver Hugl 4a78a5417b backends/drm: don't set gamma with legacy unless really necessary
It seems to have a pretty large performance impact

(cherry picked from commit d1bc39a6ea)
2024-03-07 13:22:29 +01:00
Xaver Hugl 29838e1e5b backends/drm: ignore ctm support on legacy
BUG: 482143
(cherry picked from commit 568f9fb666)
2024-03-07 13:22:09 +01:00
Vlad Zahorodnii 6d5a0ed4d2 Rename Workspace::updateClientArea as Workspace::rearrange
We need to re-arrange layer shell surfaces, compute new struts and adjust
the windows in a single step.

Workspace::updateClientArea() is the best candidate for that, so this change
repurposes that function from computing work areas to a generic relayouting
function.

CCBUG: 482361
(cherry picked from commit b674b458df)
2024-03-07 13:52:10 +02:00
Vlad Zahorodnii b3925a9460 wayland: Fix windows shrinking when output layout changes
When the output layout changes, the Workspace is going to update the
struts and then go through every window and see whether it should be
moved or resized.

On the other hand, the layer shell windows react to output changes on
a timer. Furthermore, it's not synchronized with the workspace rearranging
the managed windows. It means that when Workspace::desktopResized() runs,
the panel struts can be slightly outdated, i.e.

- An output layout change occurs
- Workspace::desktopResized() is called but the struts can be wrong
- some time later, LayerShellV1Integration::rearrange is called, it
  fixes layer shell window geometries and struts
- after the layer shell integration has finished rearranging the
  layer shell windows, it calls Workspace::desktopResized(), but the
  damage had already been caused

With the proposed change, the Workspace and the LayerShellV1Integration
will rearrange the windows in sync.

CCBUG: 482361
(cherry picked from commit a489bfa12c)
2024-03-07 13:52:00 +02:00
Łukasz Patron 7db7c97e41 x11window: Skip strict geometry checks in isFullScreenable()
This addresses an issue where mpv window with keep aspect ratio enabled
cannot be fullscreened due to constrainClientSize() returning size that
doesn't fit full screen area.

NOTE: This has been tested with 3440x1440 display and 1920x1080 video in
      mpv.


(cherry picked from commit 083318dddd)
2024-03-06 19:33:32 +00:00
David Edmundson 9e4d7e54c5 xwayland: Use correct key for key release events
When a key is pressed the string that should be used in the key event
changes depending on the xkb updated state for composed keys.

The key itself should be not be affected.
2024-03-06 12:42:41 +00:00
David Edmundson 18e6256dd6 xwayland: Send to xwayland even when no window is focussed
In the codepath to keep xwayland notified of key presses we have to
check the focussed window is not already an xwayland client. To avoid a
null dereference a guard is added that the focussed window is not null,
however the current code incorrectly returns early intead of skipping
just the relevant check.

BUG: 478705
2024-03-06 12:42:41 +00:00
Jonathan Riddell e516aed779 update version for new release 2024-03-05 23:23:29 +00:00
Jonathan Riddell 26cacb79c8 update version for new release 2024-03-05 22:16:52 +00:00
Vlad Zahorodnii fdcc9be2ce effect: Fix EffectWindow::contentsRect()
It should specify the client rect inside the frame.

2556378dfa incorrectly assumed that the
buffer geometry includes the decoration.

BUG: 482294


(cherry picked from commit 8736e44e1a)
2024-03-05 13:57:58 +00:00
Vlad Zahorodnii 7da6ecb3df Fix confined pointer being able to escape the surface
When using fractional scaling, an xwayland window's client geometry can
have some fractional part. When that's the case, .toRect() can shrink the
client geometry or extruding the decoration borders inside the surface.

On the other hand, the pointer is going to be confined as long as the
wl_surface is focused. If the focus jumps to the decoration, the pointer
constraint is going to be broken. Unfortunately, the focus can shift to
the decoration even though the wl_surface is still focused because of the
pesky .toRect().

BUG: 482448
CCBUG: 477124


(cherry picked from commit bfd755aee9)
2024-03-05 13:35:00 +00:00
Dominique Hummel 63a39646ea effects/windowview: use correct enum value for `PointerDevice`
BUG: 482191


(cherry picked from commit d0a6bd3404)

b842efc0 effects/windowview: use correct enum value for `PointerDevice`
2024-03-04 23:15:12 +00:00
Xaver Hugl 42eca26802 backends/drm: don't work around pageflips timing out
It doesn't seem to (always) work, and it has caused at least one crash. If the workaround
is needed, it'll have to be implemented in a different way


(cherry picked from commit 599020d8da)
2024-03-04 14:05:53 +00:00
Xaver Hugl 456ed767e6 opengl: assume a minimum of 2ms of render time
When GPUs are barely loaded, render times can spike randomly, likely because it goes
to a lower power state and has to ramp up again when KWin renders. To ensure this
doesn't make KWin drop frames, assume rendering always takes at least 2 milliseconds


(cherry picked from commit 1b10dde569)
2024-03-04 13:20:03 +00:00
Xaver Hugl be9d2fd7d0 backends/drm: fix vblank calculation
Due to some misinterpretation of mode timings, the old method calculated vsync, not vblank,
so the resulting duration was much shorter, which caused frame drops on some systems.

BUG: 482064


(cherry picked from commit da80dd4c84)
2024-03-04 12:41:11 +00:00
Vlad Zahorodnii 84b4bd3ae8 wayland: Fix a crash in DrmLeaseDeviceV1Interface::setDrmMaster()
The case when a resource is destroyed before kwin becomes the drm master
again is not handled. It can leave dangling pointers in m_pendingFds.


(cherry picked from commit 9e77e5038f)
2024-03-04 11:08:20 +00:00
Xaver Hugl d161f042f6 wayland/surface: don't update preferred color description unless it changed
This avoids clients doing unnecessary work


(cherry picked from commit 3b28788592)
2024-03-03 18:24:34 +00:00
Sam James e89919227f Fix ODR violation with MouseClick plugin
```
/var/tmp/portage/kde-plasma/kwin-6.0.49.9999/work/kwin-6.0.49.9999/src/input_event.h:21:7: error: type ‘struct MouseEvent’ violates the C++ One Definition Rule [-Werror=odr]
   21 | class MouseEvent : public QMouseEvent
      |       ^
/var/tmp/portage/kde-plasma/kwin-6.0.49.9999/work/kwin-6.0.49.9999/src/plugins/mouseclick/mouseclick.h:27:7: note: a type with different bases is defined in another translation unit
   27 | class MouseEvent
      |       ^
lto1: some warnings being treated as errors
```

Bug: https://bugs.gentoo.org/921558
Signed-off-by: Sam James <sam@gentoo.org>


(cherry picked from commit 53a61dfac0)
2024-03-03 10:54:39 +00:00
l10n daemon script b352c5b9ef GIT_SILENT Sync po/docbooks with svn 2024-03-03 03:06:10 +00:00
l10n daemon script c707d87b4d 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-03-03 03:01:51 +00:00
l10n daemon script 098a374fab GIT_SILENT Sync po/docbooks with svn 2024-03-02 02:58:55 +00:00
Akseli Lahtinen 565faf1713 plugins/overview: Adds a border around hovered and selected desktop in desktopGrid
Currently desktop grid view is missing the selection rectangle when hovered over a desktop.
This adds the selection rectangle on hover, since it used to be there before three-state design.

Currently selected desktop has thinner and different colored border.


![image](/uploads/ad1f2f7acbe602fb7b9479ce859026b7/image.png)

![image](/uploads/9fa50bac4b81958da0b8926f8d2518ba/image.png)

![image](/uploads/3e46c1f5a740c40bbf18a5d887f31d39/image.png)

BUG:481812


(cherry picked from commit 181ce590a9)

9b22e56c Adds a border around hovered desktop in desktopGrid
0566df70 Simplify code
f4a4fd4c Use different color and spacing for already selected desktop
99a7fc51 Show borders only in desktop grid view
6c12f24a fix indent
a8981c94 Add parenthesis to ternary expressions, remove stray line
075b6117 Apply 1 suggestion(s) to 1 file(s)
2024-03-01 12:05:50 +00:00
l10n daemon script ee3d84dffc GIT_SILENT Sync po/docbooks with svn 2024-03-01 03:39:37 +00:00
Vlad Zahorodnii aa741db0e7 opengl: Harden GLRenderTimeQuery against opengl providing bad timestamps
The end render timestamp can be slightly in the past before the start
render timestamp. This results in negative render times, which can make
kwin wait way more than just one vblank interval before starting the
next frame.

It appears that there is no way to detect if the gpu has performed a
disjoint operation in OpenGL. It's available only in GLES. As a way
around, this change makes the GLRenderTimeQuery insert two probes: one
queries gl timestamps when starting rendering and ending rendering;
another one just queries std::steady_clock before and after painting.
This hardens the GLRenderTimeQuery against OpenGL providing nonsensical
results sometimes.

BUG: 481721


(cherry picked from commit 0dc3f4906f)
2024-02-29 18:16:34 +00:00
Xaver Hugl 27d215357c backends/drm: delay cursor updates with adaptive sync
While the primary plane delivers a high enough refresh rate for the cursor to be
at least usable, delay cursor updates to be in sync with the primary plane. This
avoids stutter of the content being shown on the primary plane.

Because amdgpu doesn't handle this correctly at the moment, this feature is guarded
behind the KWIN_DRM_DELAY_VRR_CURSOR_UPDATES environment variable.
See https://gitlab.freedesktop.org/drm/amd/-/issues/2186 for more details on that.

(cherry picked from commit 039fd39e34)
2024-02-29 17:58:04 +00:00
Xaver Hugl 803009848c backends/drm: move committing logic into a separate method
This makes the code a bit more readable

(cherry picked from commit 080d28b3f9)
2024-02-29 17:58:04 +00:00
Vlad Zahorodnii 63d7a29e84 backends/x11: Make SwapEventFilter report presentation feedback to OutputFrame
(cherry picked from commit 79b7545840)
2024-02-29 17:44:45 +00:00
Marco Martin 69b64ef78d Remove invalid tabbox configs from defaults
We know that org.kde.breeze.desktop is invalid as LayoutName for the
tabbox, it will break the default button in the tabbox kcm.
Also the DesktopListLayout and DesktopLayout aren't valid anymore

BUG:481640
2024-02-29 12:25:47 +01:00
Fushan Wen 4145d4a26d plugins/outputlocator: show physical size in output locator
Make sure the effect shows the same sizes as the KScreen KCM.


(cherry picked from commit d377b5cdab)
2024-02-29 09:44:39 +00:00
l10n daemon script 5aea602058 GIT_SILENT Sync po/docbooks with svn 2024-02-29 03:01:27 +00:00
l10n daemon script 85e7e617f5 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-02-29 02:56:39 +00:00
l10n daemon script 73d2860647 GIT_SILENT Sync po/docbooks with svn 2024-02-28 02:55:55 +00:00
l10n daemon script ee4b772007 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-02-28 02:51:10 +00:00
Patrik Fábián 018a1d35db plugins/overview: Search bar can be clicked without closing effect
(cherry picked from commit c11eeabc86)
2024-02-27 16:18:17 +00:00
Xaver Hugl 14b96e67e9 autotests/test_colorspaces: add an autotest for non-normalized primaries 2024-02-27 16:57:20 +01:00
Xaver Hugl f20ce6244c core/colorspace: normalize XYZ values before using them in calculations
Otherwise ICC profiles where the primaries are normalized to different values than what
KWin needs may cause too dark or bright results.

BUG: 481034
2024-02-27 16:57:18 +01:00
Xaver Hugl 75b741128e comopsitor: only activate VRR if the active window is on the current screen
BUG: 481750
(cherry picked from commit af4e12c5fc)
2024-02-27 15:33:58 +01:00
l10n daemon script 5bf74d9384 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-02-27 02:59:41 +00:00
Vlad Zahorodnii 5b263b41d5 xwayland: Ignore somebody else claiming WM_S0 selection
If somebody else claims the selection, it's unclear what we should do.
kwin can't give up its selection as it's the one who is responsible for
window management and compositing. If anything, Xwayland should ensure
that no client can claim WM_S0.


(cherry picked from commit 329c5de451)
2024-02-26 14:11:47 +00:00
Vlad Zahorodnii 4ae0f0cd65 Fix a crash in eglDestroyImageKHR()
Apparently, libepoxy requires a current EGL display in order to resolve
EGL functions. This is unexpected as most of the EGL functions require no
current opengl context.

This change makes kwin bypass libepoxy for problematic cases.

BUG: 470980


(cherry picked from commit 13c092d671)
2024-02-26 13:49:05 +00:00
Ser Freeman 7a36938672 Window: Don't reset quick tile mode on interactive move start
Quick tile mode reset should be done in the interactive move handler,
where the new move offset is set. Only reset it on resize to unsnap
the window from the tile.

BUG: 472366


(cherry picked from commit 192ec437df)
2024-02-26 11:27:49 +00:00
David Edmundson ebce0e3c33 x11window: Disable strict geometry placement by default in wayland
Strict geometry disables certain user activites; full screen requests
and only sending configure events at sizes the client claims to support.

This was added as a workaround for xterm in 19 years ago. It's a client
side bug as applications can still choose to ignore the configure event,
so kwin shouldn't have to sanitise them in advance. xterm seems to have
fixed it's bug, and pragmatically we know not all window managers
perform these checks so most clients should not be relying on it.

On Wayland this additional check is proving problematic, the handling of
scaling especially fractional scaling is hitting cases where it's better
to always ask the client to do what kwin wants.

Tests that refer to sizeIncrements are dropped as they are only used in
the strict geometry passes which is being obsoleted. Resizing in general
is still tested.

BUG: 481456


(cherry picked from commit 32be54b19d)
2024-02-26 11:15:08 +00:00
Akseli Lahtinen bd71e48327 tileseditor: Don't allow tiles to move tiles already at minimum size
Previously a tile could intersect with the tile next to it when resizing tiles in tiles-editor.

This checks that the tile next to the resized one is not at minimum size already, and stops
resizing if it is.

Do note that any current setups that may get broken if there is tiles that intersect each other,
so they may have to remake the tile setup.

BUG: 465721
FIXED-IN: 6.0.1


(cherry picked from commit 024db60ccd)
2024-02-26 10:17:43 +00:00
l10n daemon script 9844badc93 GIT_SILENT Sync po/docbooks with svn 2024-02-26 03:01:01 +00:00
Aleix Pol Gonzalez fbe35105ac wayland: Install the clientconnection.h header file
Together with the rest of files that effects might use.

Signed-off-by: Falko Becker <falko.becker@mbition.io>


(cherry picked from commit 7468465393)
2024-02-25 23:07:40 +00:00
l10n daemon script 3397b86108 GIT_SILENT Sync po/docbooks with svn 2024-02-25 03:08:49 +00:00
l10n daemon script 866b0bf142 GIT_SILENT Sync po/docbooks with svn 2024-02-24 02:51:58 +00:00
Xaver Hugl 10eac23ed2 useractions: don't interact with deleted windows
BUG: 481688


(cherry picked from commit d51b69d6ac)
2024-02-23 22:28:19 +00:00
Vlad Zahorodnii 66af39ec9e plugins/showpaint: Add support for color management
It makes the show paint plugin work when color management is enabled.


(cherry picked from commit 56d3c797cc)
2024-02-23 18:45:11 +00:00
Vlad Zahorodnii 515f60cb7f plugins/glide: Fix rotation order when applying render target transformation
The perspective projection matrix has its y axis flipped vertically. It
should be undone when applying the render target transformation, otherwise
the rotation order will be wrong.

BUG: 481664


(cherry picked from commit 7c0a88f34b)
2024-02-23 14:51:15 +00:00
Marco Martin 111cd842f1 Send tablet input to active screen
Try to send the tablet input to the configured screen for the tablet if any,
otherwise always send it to the active screen, not the screen of the active window
which is very confusing

BUG:479713
2024-02-23 12:52:55 +01:00
l10n daemon script 6de7a85083 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-02-23 02:50:44 +00:00
Vlad Zahorodnii df4b125506 backends/x11: Avoid calling doneCurrent() if GLX context has not been created
BUG: 477854


(cherry picked from commit ff4cfe279a)
2024-02-22 15:57:37 +00:00
Vlad Zahorodnii cb3dadf283 backends/wayland: Guard against failing to create EGLSwapchain
BUG: 478864


(cherry picked from commit bb354de90e)
2024-02-22 15:25:23 +00:00
Xaver Hugl 80e30821af backends/drm: only enable HDR if both display and driver are capable of it
The config may have HDR or WCG enabled, and the driver or display settings changed
since then to make it impossible to actually enable either.
The config values stay unchanged when this happens, so reconnecting the display with
HDR support will automatically turn it on again.

BUG: 481518


(cherry picked from commit d33ab542db)
2024-02-22 13:08:56 +00:00
zoro wk 2f4480e60b xcbutils: arm x apps can't be dragged to a negative position on the screen
the behavior of converting negative floating-point numbers to unsigned
integers is undefined. It is necessary to keep the conversion behavior
consistent between ARM and x86 platforms.

through the above conversions, all become the two's complement of
negative numbers.

Signed-off-by: zorowk <near.kingzero@gmail.com>


(cherry picked from commit 904c33556b)
2024-02-22 10:35:06 +00:00
Vlad Zahorodnii 47973b4f1c wayland: Avoid rearranging layer surfaces when wl_surface size changes
wl_surface size is not used when re-arranging surfaces. It also results in
excessive configure events.

Note that it can be useful for updating strut rects, but we could use the
next geometry, which is even preferrable over the frame geometry as the
Workspace would use proper struts earlier.


(cherry picked from commit 648cfcd66c)
2024-02-22 10:04:33 +00:00
l10n daemon script 1ddcb4e288 GIT_SILENT Sync po/docbooks with svn 2024-02-22 02:56:29 +00:00
l10n daemon script adf58ef8d3 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-02-22 02:53:06 +00:00
Xaver Hugl 961a2d7041 opengl/eglcontext: tell Qt when the OpenGL context gets changed
Otherwise, Qt thinks the old context is still current and will do things like
destroying VAOs with KWin's context, which ends up destroying the VAO of the
context and breaks rendering.

BUG: 479094


(cherry picked from commit 8c3332f619)
2024-02-21 20:16:39 +00:00
Jonathan Esk-Riddell 2b8d404a31 Update Frameworks version requirement to 6.0.0
GIT_SILENT
2024-02-21 14:43:11 +00:00
Vlad Zahorodnii fff63dadd4 Remove all legacy virtual desktop ids
Amends 0bd65de375.


(cherry picked from commit 2c445ebf3c)
2024-02-21 13:01:36 +00:00
David Edmundson 8a2d77e0a5 Revert "wayland: Send wl_pointer leave before data_device enter"
This reverts commit a706490763
2024-02-21 11:55:42 +00:00
Jin Liu 38a03f3d3d plugins/contrast: fix: effect not clipped to region
Introduced in:
7732f0e56b


(cherry picked from commit c2c19fe91f)
2024-02-21 11:23:48 +00:00
Vlad Zahorodnii d26d95ed3b plugins/overview: Make screen edge toggle overview rather than cycle between modes
The user may have no usecase for the grid view mode, i.e. they may want
to activate overview, do their thing, and then return back to normal
desktop. However, with the current behavior, there's one extra step
(switch to grid mode) in order to go back to desktop.

In hindsight, we should have added different screen edge actions for
overview and grid modes. This can be done in 6.1.

BUG: 481335


(cherry picked from commit f77f5b2342)
2024-02-21 10:06:25 +00:00
Xaver Hugl 09e4243513 useractions: remove legacy virtual desktop number from the menu
In almost all cases it's duplicated in the name, and if the user manually
changes the name, the custom name should be shown without additional numbers

CCBUG: 481576


(cherry picked from commit 0bd65de375)
2024-02-21 09:19:41 +00:00
l10n daemon script 04ef67ef16 GIT_SILENT Sync po/docbooks with svn 2024-02-21 02:58:05 +00:00
l10n daemon script 26ce318518 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-02-21 02:53:12 +00:00
Vlad Zahorodnii 6e7088d047 Fix disappearing software cursor in overview and zoom effect
The overview and the zoom effect repaint the whole screen every frame.
But the problem is that there are cases when there's nothing to repaint.
I'm not quite sure why it happens. Maybe overview and other effects
should honor the repaint region, but on the other hand, they don't need
to because of the fullscreen effect api promises.

This change forces overview and zoom effect to use "generic paint" code
path in the workspace scene to force infiniteRegion() repaint regions.

BUG: 481523
(cherry picked from commit bb8b51a3ab)
2024-02-21 01:21:44 +02:00
Vlad Zahorodnii 5e3d9fa52a plugins/wobblywindows: Ignore PAINT_SCREEN_TRANSFORMED
Screen transform apis have been dropped, so the wobbly windows should be
safe to ignore screen transformations.

(cherry picked from commit b2450cfe14)
2024-02-21 01:21:35 +02:00
Michael VanOverbeek dde3219c69 Fix zoom push mouse tracking on multi-monitor workspaces
Zoom push tracking now considers the layout of the user's monitors, accounting for situations where the monitor layout doesn't form a perfect rectangle. These changes help prevent the zoom area from being unable to reach certain areas of the workspace depending on which edge of which screen the user pushes against.

One known issue is that, if the mouse moves too quickly, the zoom area can sometimes imperfectly track the movement. It will look the same as the original bug (areas of the screen will appear to be cut off/unreachable), but moving the mouse in the opposite direction a tiny bit snaps the zoom area back to where it should be. 

BUG: 467182

@teams/qa Heads-up that I'm very blind, and this is the first time I've ever contributed to a KDE project. I've tested the changes on my system and they fix the bug, but I want to make sure I didn't break anything in the process.


(cherry picked from commit 86f0d9914e)
2024-02-20 20:57:33 +00:00
Jakob Petsovits d062ce8750 backends/drm: Undo fade-out effect upon unsuccessful DPMS Off
DrmOutput::setDrmDpmsMode() already takes care of reverting any
pending output pipeline changes, but the aboutToTurnOff signal from
setDpmsMode() needs an explicit wakeUp signal to cancel it out.

BUG: 477916
CCBUG: 481520


(cherry picked from commit 9e3e567592)
2024-02-20 19:43:13 +00:00
Nicolas Fella cc057c5865 Set componentDisplayName for shortcut migration
Otherwise the binary name is used as display name, causing all kwin
shortcuts to be registered under kwin-6.0-delete-desktop-switching-shortcuts

(cherry picked from commit afa450b97a)
2024-02-20 12:40:34 +01:00
l10n daemon script 454f48f345 GIT_SILENT Sync po/docbooks with svn 2024-02-20 03:00:39 +00:00
Xaver Hugl d1b5062709 autotests/integration/outputchanges: add geometry restore test
(cherry picked from commit 8fa782f1a8)
2024-02-19 17:30:41 +01:00
Xaver Hugl 9c63c04c13 placementtracker: save geometry restores more explicitly
Geometry restores were only saved when maximize or fullscreen changed, which is
not the only time the geometry restores change. This adds a signal to Window for
that, which fixes a few bugs with windows being moved between screens while
maximized or fullscreened

(cherry picked from commit 2c280b1bb0)
2024-02-19 17:30:41 +01:00
Xaver Hugl e9004f723a placementtracker: don't set geometry to geometry restores
It can cause problems when the geometry restore value is invalid

BUG: 473602
(cherry picked from commit 86db3b4336)
2024-02-19 17:30:41 +01:00
David Edmundson e4443c32b3 overview: Only handled input events in on-screen desktops
kwin does not support true multiscreen drag and drops. Events are sent
to an offscreen location of the screen initiating the drag. Therefore it
is important that off-screen items do not process drop events

BUG: 481331


(cherry picked from commit 3ede995b27)
2024-02-19 15:42:22 +00:00
Vlad Zahorodnii 84e9a6e69b Synchronize input transformation regardless of interactive move resize status
This check is old and I'm not sure why it even exists. It should not be
needed in general.

The problem with this check is that when interactive move/resize
operation finishes, the seat input transformation is not synchronized.


(cherry picked from commit 64e701fdaf)
2024-02-19 15:28:03 +00:00
Niccolò Venerandi dc05316de8 Ensure that translations never change the size of a contrast effect / blur regions
BUG:480434


(cherry picked from commit 7732f0e56b)
2024-02-19 11:23:33 +00:00
l10n daemon script 4f6daadf83 GIT_SILENT Sync po/docbooks with svn 2024-02-19 03:00:44 +00:00
l10n daemon script 19c49093f2 GIT_SILENT Sync po/docbooks with svn 2024-02-18 02:59:31 +00:00
l10n daemon script 42e57a852f GIT_SILENT Sync po/docbooks with svn 2024-02-17 02:59:24 +00:00
Xaver Hugl 09fbf4dac7 backends/drm: don't advertise support for wide color gamut on Intel
i915 doesn't implement the Colorspace property correctly, so exposing this
feature makes it look like our HDR implementation is broken. This hides the
HDR checkbox in system settings until Intel fixes their driver

For testing purposes, users can still opt into this with the environment
variable KWIN_DRM_ALLOW_INTEL_COLORSPACE.


(cherry picked from commit 742268bfa1)
2024-02-16 12:17:33 +00:00
Xaver Hugl c84739d51e backends/drm: force a modeset when connectors are unplugged
And turn off unused CRTCs with legacy

BUG: 478476


(cherry picked from commit 9ea6f311ea)
2024-02-16 11:41:29 +00:00
Xaver Hugl 9e4c3b525a backends/drm: fix HDR with legacy modesetting
The properties were entirely ignored before


(cherry picked from commit d69331d186)
2024-02-16 11:19:46 +00:00
Vlad Zahorodnii 58f33b03a2 plugins/overview: Allow switching between modes using shortcuts while already active
Overview and Grid modes have shortcuts assigned to them. While they
provide a way to toggle the overview effect between on and off state, in
other words overview <-> off or grid <-> off, it's not possible to move
between the modes by pressing those shortcuts, e.g. off -> overview ->
grid -> overview -> grid -> ... -> off.

The culprit seems to be that EffectTogglableState has two "inactive"
states - Inactive and Stopped. It's counter-intuitive and needs a further
cleanup.

To make switching between overview modes work, this change makes
EffectTogglableState::toggle() toggle the state based on the Active state.
There's only one active state.

CCBUG: 481335


(cherry picked from commit fc92544cb3)
2024-02-16 09:06:44 +00:00
Ismael Asensio 8756591037 kcms/rules: Fix section header and info button sizing
The section header being now a QQC2.ItemDelegate needs to explicitly
set the width to be visible.

The ContextualHelpButton size was getting constrained by the parent
layout's being adjusted to just the label height.


(cherry picked from commit 0991cded05)
2024-02-16 08:55:31 +00:00
l10n daemon script 6394a32162 GIT_SILENT Sync po/docbooks with svn 2024-02-16 03:04:08 +00:00
Vlad Zahorodnii c707ce77d7 plugins/screencast: Make grabTexture() more nicer to memfd code path
OutputTransform::Normal is handled by doGrabTexture().

If the texture transform is neither normal nor flip-y, the GPU is going
to be used to transform the texture, however since it doesn't flip the y
axis, doGrabTexture() will flip the y axis on the cpu side. To fix that,
make the contents of backingTexture mirrored vertically.


(cherry picked from commit 7297e62283)
2024-02-15 14:47:55 +00:00
Vlad Zahorodnii deeb0672bf plugins/screencast: Make region screen cast nicer to memfd
Set the FlipY flag so when the memfd code grabs the texture contents, it
doesn't need to flip the texture on the cpu side.

(cherry picked from commit af12a103ae)
2024-02-15 16:18:27 +02:00
Vlad Zahorodnii 1ce25f7137 plugins/screencast: Fix window screencasts being vertically mirrored with memfd
WindowScreenCastSource::render(GLFramebuffer) renders windows with the y
axis flipped, but the offscreen has no FlipY flag set.

BUG: 478223
(cherry picked from commit 3388b7643c)
2024-02-15 16:18:19 +02:00
Xaver Hugl 60849214b3 wayland/textinput_v2: copy the data instead of assuming ownership
The life time of the wl_array is limited to the callback, afterwards it's
a dangling pointer

BUG: 481239


(cherry picked from commit 3a8ae60f87)
2024-02-15 12:23:25 +00:00
David Edmundson a706490763 wayland: Send wl_pointer leave before data_device enter
SeatInterface currently has a separation of kwin's focus scope to
pointer input with early return guards in notifyPointerEnter and
notifyPointerLeave where clients don't get pointer events.

However we don't update the initial state when a drag is started, this
patch notifies sends a pointer leave to the new drag target before the
data_device enter so things are consistent.

This also brings it in line with Weston and Mutter.

notifyPointerLeave has it's early return removed as for wayland windows
as we know nothing will have pointer focus.


(cherry picked from commit 5386360928)
2024-02-15 12:06:23 +00:00
Vlad Zahorodnii 58f38ff522 opengl: Invalidate cached vbo when content transform is different
When output rotation changes, the texture size stays the same, but the
texture coordinates are no longer valid and have to be recomputed.


(cherry picked from commit 5d787a4083)
2024-02-15 11:46:47 +00:00
David Edmundson cc3d5ea89d decorations: Avoid opaque areas of decorations being larger than the rendered contents
Opaque is a QRegion in logical pixels, using .toRect will round to the
nearest integer in either direction. This can mean an area is considered
opaque outside the rendered area, leading to glitchy contents on
shadows.

This is most noticable on on X11 windows when fractional scaling is
used.

Long term I hope to move Item::opaque to QList<QRectF> and
WindowPrePaintData::opaque to device pixels.

(cherry picked from commit c6a3d76b92)
2024-02-15 11:33:29 +00:00
David Edmundson 8becf3cd68 wayland: Dispatch mouse events to internal windows via QWindowSystemInterface
QWindowSystemInterface goes via QGuiApplication which updates some
internal properties. Most notably QGuiApplication::lastCursorPosition
which is used by advanced menu closing behaviour.

BUG: 478061
(cherry picked from commit b36894884e)
2024-02-15 11:33:29 +00:00
Marco Martin 5bf066ff11 Only show otherScreenThumbnail if we are actually dragging
otherScreenThumbnail is used to fake a window thumbnail being dragged
half in the old screen, half in the "new" one (or even more than two)

right now the condition to use it is purely the "real" thumbnail x
or y change, but sometimes especially when the item has just been created
and is being laid out it might trigger an itemDraggedOutOfScreen
when no-one was dragging.

We should never make otherScreenThumbnail visible when we aren't dragging
a thumbnail, so check for Drag being active in the source item.

the item will be kept visible even if drag becomes inactive as before,
as it still needs to be visible for the reset animation

BUG:480564
2024-02-15 11:01:02 +01:00
Fushan Wen 0aaf3e8c84 plugins/colorblindnesscorrection: set translation domain in config ui
By default the translation domain of KQuickManagedConfigModule is the
unique identifier within the namespace of the plugin, but those i18n
strings belong to kwin.po.

(cherry picked from commit f303ba4b59)
2024-02-15 00:40:01 +00:00
Xaver Hugl 160aa7dcba window: use normal keyboard modifiers for triggering custom tiling
Modifiers for global shortcuts are handled differently from normal shortcuts,
because they need to consider modifiers that are consumed by xkb for keyboard
layout transitions and similar. This restriction is not relevant for custom
tiling.

BUG: 465858
(cherry picked from commit 1f1c54ca6c)
2024-02-14 17:39:26 +01:00
Xaver Hugl 6fff1c9d2c input_event: remove modifiersRelevantForTabBox
It was only needed because the normal modifiers path considered caps lock
as shift lock

(cherry picked from commit a917d1885e)
2024-02-14 17:39:26 +01:00
Xaver Hugl 668f6a6978 xkb: caps lock is not shift lock
Caps lock only locks capitalization of letters, making it artificially also
trigger shift in the context of KWin only causes problems

(cherry picked from commit 8c543dbe7c)
2024-02-14 17:39:26 +01:00
Vlad Zahorodnii e1bf40976c Adapt to NETRootInfo::moveResize() changes
(cherry picked from commit 8a9cb06b41)
2024-02-14 11:03:34 +00:00
David Edmundson cab4fdaad2 overview: Explicitly reset parent on teradown
Instantiators create objects when they're added to a model, and
deference when when they're removed from the model.

When we explicitly set a parent in onObjectAdded we're creating a second
reference. This does get cleaned up later, but not in the same frame.

This brings us in line to what QQmlRepeater (which works with items)
does internally for items being added and removed.

BUG: 478777


(cherry picked from commit eab90b6a0a)
2024-02-14 10:08:26 +00:00
l10n daemon script bae9233f7a GIT_SILENT Sync po/docbooks with svn 2024-02-14 03:02:00 +00:00
Yifan Zhu 4727a7d956 screenedge: don't reduce approachGeometry
Reducing approachGeometry is not needed.

During edge creation, createHorizontalEdge and createVerticalEdge
already substract the needed cornerOffset, and edges reserved by client
windows shouldn't be reduced in geometry.
In addition, during display, ScreenEdgeEffect confines the painted area
to approachGeometry. So approachGeometry shouldn't be reduced in
advance.

BUG: 481282


(cherry picked from commit 2f4db693e3)
2024-02-13 15:41:03 +00:00
Ismael Asensio b9bf9d7d41 tabbox/thumbnail-grid: Activate on thumbnail click when selected
While tabbox switching is usually a keyboard operation, we offer also
a mouse-friendly way to launch it via screen edges, and should allow
to switch directly on mouse click.

BUG: 481267
FIXED-IN: 6.0


(cherry picked from commit f6447ad188)
2024-02-13 13:18:49 +00:00
Vlad Zahorodnii 4b7614f04a Fix a warning about null sender in QObject::connect()
The original assumption was that once PointerInputRedirection starts
pushing cursor sources to cursors, they cannot be null. In many cases,
it is true, but the tests are a bit special as many of them lack
wl_pointer.set_cursor requests, so it's possible to set a null source.
As an example, when the pointer moves from the decoration to the
surface. On the other hand, it also does make sense to allow having
no source connected.


(cherry picked from commit 55ef69645c)
2024-02-13 12:59:59 +00:00
l10n daemon script 7f4535490c GIT_SILENT Sync po/docbooks with svn 2024-02-13 03:05:42 +00:00
Vlad Zahorodnii 6ff5b6361c plugins/blur: Fix blurred region sticking outside panel popups
The blur geometry is scaled in the global coordinate space, while it
works fine with integer scale factors, it's not okay with fractional
scale factors as it doesn't match how the ItemRenderer snaps quads to
the pixel grid.

Note that blur behind apps can be still off by one pixel, but it
should be harder to notice it. In order to fix it, it would be great
to apply effects behind Items, which is on my todo list.


(cherry picked from commit 9abf7a9d61)
2024-02-12 14:57:15 +00:00
Xaver Hugl e4f53d983c kscreenintegration: fix rotation not being preserved from Plasma 5
(cherry picked from commit 2ca1d3fd4c)
2024-02-12 14:23:18 +00:00
Vlad Zahorodnii 2e8d386042 scene: Fix DecorationItem reacting to new geometry
Window::layoutDecorationRects() uses KDecoration2::Decoration::rect() to
get the bounding decoration rect.

While Decoration::rect() should normally match Window::rect(), they can
diverge for a brief moment during async geometry updates. The worst
possible case is that the cached item quads may not be invalidated when
the geometry updates saddle.

To fix that, make DecorationItem monitor decorated client size changes
instead of window frame geometry changes. The reason for that is that
Decoration::size() is effectively decorated client size with added border
margins.


(cherry picked from commit 857766eb74)
2024-02-12 13:38:33 +00:00
Vlad Zahorodnii 26b605d4d9 plugins/overview: Fix a warning about incorrect anchor
The mouse area is no longer a sibling of the window heap, which produces
a warning.

BUG: 481106


(cherry picked from commit b02190bf23)
2024-02-12 11:20:57 +00:00
Vlad Zahorodnii d265fe2ad5 wayland: Avoid setting tiled_ xdg-toplevel state
Resizing of tiled GTK apps is broken because GDK relies on some information
provided by the gtk-shell protocol. There is an upstream fix, but it has
not been merged yet.

5.27 is affected too, but unlike 6.0, wayland is not enabled there by default.
So let's disable tiled_ state to fix resizing GTK apps. As far as I know,
GTK is the biggest consumer of tiled_ xdg-toplevel state at the moment, so
hopefully no other apps are going to be affected by this change.
2024-02-12 11:41:32 +02:00
l10n daemon script 5f0c20503e GIT_SILENT Sync po/docbooks with svn 2024-02-12 02:59:39 +00:00
l10n daemon script 7f099cac6c GIT_SILENT Sync po/docbooks with svn 2024-02-11 03:05:57 +00:00
l10n daemon script ad71ff1dfa 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-02-11 02:59:21 +00:00
l10n daemon script ad3268b0b8 GIT_SILENT Sync po/docbooks with svn 2024-02-10 03:23:35 +00:00
l10n daemon script 168e25ee38 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-02-10 03:17:30 +00:00
Vlad Zahorodnii 7644499e20 Handle wl_surface destruction in SurfaceCursorSource
Wine/Wayland hides the cursor as follows:

[ 853107.473]  -> wl_pointer@15.set_cursor(172832, wl_surface@38, 0, 0)
...
[ 858989.757]  -> wl_surface@38.destroy()
[ 858989.759]  -> wl_pointer@15.set_cursor(172832, nil, 0, 0)

i.e. it destroys the cursor surface, then calls wl_pointer.set_cursor().

SurfaceCursorSource stores the wl_surface in a QPointer, furthermore it
is going to emit the changed signal, which is needed to force the
CursorItem to update its content, only if either a new hotspot or a
surface has been passed to SurfaceCursorSource::update(). So what happens
is the following:

- The SurfaceInterface object is destroyed and the QPointer resets its
  value to nullptr
- SurfaceCursorSource::update(nullptr, QPointF(0, 0)) gets called in
  response to wl_pointer@15.set_cursor(nil, 0, 0)
- but since m_surface has been implicitly reset to nullptr, no changed
  signal is going to be emitted

This change addresses the issue by making the SurfaceCursorSource track
the SurfaceInterface's destroyed signal.

BUG: 480582


(cherry picked from commit 13e7cac019)
2024-02-09 12:08:17 +00:00
David Edmundson 8b73147fa9 quickeffect: Avoid double delete of QQuickViews
Views are owned by the C++ backend, but also retrievable by invokables
to get neighbouring screens from JS space. By default Qt then transfers
ownership of the view to the QML collector. This results in double
ownership.

BUG: 480788


(cherry picked from commit 95d4671a10)
2024-02-09 09:19:26 +00:00
Vlad Zahorodnii 16031795c0 Fix X11Window wrapper window geometry
This amends 66a491bda6.

There are a few more cases that had been overlooked in the original patch.

(cherry picked from commit 2556378dfa)
2024-02-09 08:36:37 +00:00
Vlad Zahorodnii f231f22546 wayland: Remove extra space around the wrapper window in X11 windows
This way no extra buffer space is going to be wasted for a decoration
that isn't there, and it might be nicer for fractional scaling as kwin
won't need to deal with border size voodoo cases.

(cherry picked from commit 66a491bda6)
2024-02-09 08:36:37 +00:00
l10n daemon script b1f9379266 GIT_SILENT Sync po/docbooks with svn 2024-02-09 03:09:29 +00:00
Ismael Asensio 2d099d6603 kcms/rules: Fix import/export FileDialog type
They were just missing the alias qualifier.

Add also explicit parameters to the signal handlers.

BUG: 481082
FIXED-IN: 6.0


(cherry picked from commit 7c8b5be55a)
2024-02-08 21:57:50 +00:00
Xaver Hugl dd54b03aaf scene/surfaceitem: change refresh rate estimation to frame time estimation
This is both more direct and avoids divisions by durations that can potentially
be zero

BUG: 480971


(cherry picked from commit 31ebdb73a0)
2024-02-08 19:01:22 +00:00
Vlad Zahorodnii 89688db8e9 wayland: Schedule a configure event when borders change
Window::checkWorkspacePosition() before the window is mapped is still
problematic and should be avoided as it can produce undesired constrained
client size (1x1).

Given that XdgToplevelWindow tries to maintain the same frame geometry
size, it should be enough to schedule another configure event instead.
It is going to be in line with the other decoration logic in the
XdgToplevelWindow and it's a better way to handle async geometry updates.

BUG: 480910
(cherry picked from commit e974c07001)
2024-02-08 17:14:21 +02:00
Vlad Zahorodnii 25f5cbcc15 plugins/nightcolor: Rename d-bus interface
(cherry picked from commit 5ad63f21e0)
2024-02-08 17:14:06 +02:00
Xaver Hugl 7f8cf985af wayland: update xx-color-management to v2
(cherry picked from commit a5726e19fd)
2024-02-08 17:13:47 +02:00
Vlad Zahorodnii 4f430bcc7e plugins/overview: Revoke Meta+Tab and Meta+Shift+Tab shortcuts
These shortcuts make more sense to be used with Meta+Tab and Meta+Shift+Tab.
Let's keep them reserved for the task switcher. Cycling between overview
modes is not something that requires Meta+Tab to be assigned to it by default.

(cherry picked from commit cd43199e70)
2024-02-08 17:13:35 +02:00
Vlad Zahorodnii 7d456cd63a kconf_update: Drop kwin-6.0-overview-activities-shortcuts script
There are a few issues:

- it's incompatible with Version 6 format
- activity shortcuts cannot be changed in kwin
- overview shortcuts don't need to be touched

BUG: 480758
(cherry picked from commit 540dff30e7)
2024-02-08 17:13:21 +02:00
David Redondo c34aec1c7b Guard against render time query failing
glGetQuery can fail (for example because of a context loss) in this
case the buffer stays unmodified. In this case this is zero resulting
in GLRenderTimeQuery::result() returning a negative value. Down the
line this leads to a negative duration in the RenderJournal and
RenderLoopPrivate::scheduleRepaint starting a timer with an amount
of milliseconds bigger than what an int can hold. This will not
actually start a timer but QTimer::isActive returns true resulting
in no futher repaints being scheduled.
BUG: 475605
FIXED-IN: 6.0


(cherry picked from commit 6b4018014c)
2024-02-08 13:53:27 +00:00
Vlad Zahorodnii 6168b5dd54 kcms/tabbox: Update layout name in response to user input
The current index can change when populating the combobox.


(cherry picked from commit 4b7874391d)
2024-02-08 13:23:18 +00:00
Marco Martin e824ab00a3 Don't scale WindowHeap in overview mode
when in overview mode, don't scale down WindowHeap, as this
will cause ugly glitches, but resize it down instead.
Still use transforms when it goes in desktop grid mode, at least for now

probably future further refactor can still help things

Before:

![image](/uploads/7ca83e7e9292bd8489faaf76d4c12693/image.png)

After:

![image](/uploads/27b970d056c89486661d6695d09813ff/image.png)

CCBUG:475682
2024-02-08 14:14:53 +01:00
l10n daemon script 38201e5edd GIT_SILENT Sync po/docbooks with svn 2024-02-08 03:01:57 +00:00
Xaver Hugl 43f223afe2 backends/drm: fix night light updates after dpms
BUG: 480911
FIXED-IN: 6.0


(cherry picked from commit 83fe158a16)
2024-02-07 22:50:36 +00:00
Xaver Hugl 590055e8ff backends/drm: fix multi gpu transfers with mixed modifiers and implicit modifiers usage
BUG: 478921
(cherry picked from commit d3a2e07002)
2024-02-07 15:21:48 +00:00
Xaver Hugl e4244c8056 backends/drm: fix EglGbmLayerSurface::doesSurfaceFit with multi gpu
CCBUG: 478921
(cherry picked from commit 1583b2c717)
2024-02-07 15:21:48 +00:00
Vlad Zahorodnii c3eb4ecd04 plugins/backgroundcontrast: Correct texture transform
The y axis should be mirrored as the last step, otherwise it's going to
change the winding order in rotation transforms in the render target
transform.

BUG: 479934


(cherry picked from commit 6d0f1fedc0)
2024-02-07 15:14:27 +00:00
Vlad Zahorodnii d174a6ba33 Prefer up-arrow cursor shape
That's what breeze only has.

(cherry picked from commit a472c90327)
2024-02-07 10:53:15 +02:00
Vlad Zahorodnii 001865d37f Prefer cursor shape names from the CSS W3C specification
There is a mix of cursor shape names from the CSS W3C specification and
non-spec ones, which is confusing when deciding what cursor shapes need
aliases in Cursor::cursorAlternativeNames().

(cherry picked from commit c9c84b6859)
2024-02-07 10:53:07 +02:00
Columbariu S b49eb3d396 plugins/screencast: Announce size and stride only for SHM buffers
DmaBufs don't have a welldefined size or stride. Clients and PipeWire
shouldn't rely on those values. Therefore we better omit them.

(cherry picked from commit 7c2cf9c953)
2024-02-07 10:52:58 +02:00
Columbariu S c9f36137ec plugins/screencast: Reset dmabufParams if SHM buffers are negotiated
m_dmabufParams is initialised after a format with modifiers is
suggested. Should the negotiation process fallback to SHM buffers, we
should reset it, so it can be used to determine if the negotiated format
is of type DmaBuf or not.

(cherry picked from commit cb398ce6fe)
2024-02-07 10:52:50 +02:00
l10n daemon script ca9e55be49 GIT_SILENT Sync po/docbooks with svn 2024-02-07 02:55:04 +00:00
Vlad Zahorodnii 8a932da1f4 Revert "tabbox: Show window switcher only when there are two or more windows"
This reverts commit b31baaf0cd.

It's still a good idea to show the task switcher even if there's only
one window in order to provide the user feedback about their action.
Since the task switcher is not shown when there's only one window, it
can be confusing and lead to thinking that the task switcher is broken.
It also fixes a regression which prevents alt-tabbing to the only
remaining minimized window.

BUG: 480940
CCBUG: 419408


(cherry picked from commit 8086707d1c)
2024-02-06 16:14:06 +00:00
l10n daemon script f6a2821698 GIT_SILENT Sync po/docbooks with svn 2024-02-06 03:41:06 +00:00
Xaver Hugl 7927351bcb backends/drm: add workaround for an amdgpu adaptive sync cursor bug
See https://gitlab.freedesktop.org/drm/amd/-/issues/3034 for details


(cherry picked from commit 3d21e41bc9)
2024-02-06 00:02:41 +00:00
Xaver Hugl bb7d2152ba backends/drm: try to handle page flips timing out
While this should really never happen in the first place, if the kernel still accepts
atomic commits, this is better than the screen(s) freezing and never recovering.

BUG: 480895


(cherry picked from commit 14749e91e9)
2024-02-05 23:00:28 +00:00
Xaver Hugl f94e4d16dd backends/drm: use explicit sync where possible
Instead of calling glFinish, which blocks until it's done and has high CPU
usage on NVidia, use EGL_ANDROID_native_fence_fd to get an explicit sync
fd, which the commit thread automatically waits on before committing the
buffer to KMS.

CCBUG: 452219


(cherry picked from commit 1c8bd1be62)
2024-02-05 22:19:13 +00:00
Vlad Zahorodnii f1e7776cb6 kcms/options: Hide "active mouse screen" option
In the late Plasma 5 times we agreed that it would be better to drop
"active mouse screen" option and stick with last interacted screen
approach instead. However, it was forgotten and nobody has pursued this
goal, so let's hide the option in the system settings ui at least.

The option is not completely removed because some parts of kwin would
need adjustments.


(cherry picked from commit e7d6e8b217)
2024-02-05 18:45:09 +00:00
Vlad Zahorodnii e29f765635 plugins/desktopchangeosd: Fix previous desktop indicator
BUG: 480630


(cherry picked from commit 8f7f97148c)
2024-02-05 18:09:14 +00:00
Vlad Zahorodnii e658d5ee02 Fix syncing Xwayland::Scale config option
The new scale value is written but it's not flushed to the disk so
when kcm_fonts_init and kcm_style_init run, they use the old scale
value.

CCBUG: 480792


(cherry picked from commit 63c1363ca1)
2024-02-05 17:16:51 +00:00
Xaver Hugl 1a6d8d265c scene/surfaceitem: prevent division by zero
If the steady_clock's resolution is very limited, now - m_lastDamage might be zero,
so enforce a minimum time of 10us (or 100'000 fps)


(cherry picked from commit 41aeecbb2a)
2024-02-05 16:51:02 +00:00
Vlad Zahorodnii 9e4d6f4389 effect: Allow ref'ing normal windows
It can be used to simplify state tracking in some effects. The
restriction exists because there used to be separation between normal
and closed windows (Toplevel and Deleted), and one could reference
only Deleted windows. So it was easier just to forbid referencing still
alive windows.

(cherry picked from commit e97b6032c2)
2024-02-05 18:33:48 +02:00
Vlad Zahorodnii 66df775a53 plugins/slidingpopups: Always ref window when sliding it offscreen
Imagine the following case:

- the window is hidden, slideOut() is called but no deleted reference is
  created because the window is not deleted
- the window is closed, slideOut() won't be called because the window is
  hidden and SlidingPopupsEffect::slotWindowClosed() ignores closed windows
  that are already hidden
- the window is deleted in meanwhile
- the sliding popups effects attempt to delete m_animations[w] entry,
  but since "w" is a dangling pointer at this point, visibleRef is going
  to access released memory

To fix that, make slideOut() always ref the window.

(cherry picked from commit 0c03e7ccfc)
2024-02-05 18:33:38 +02:00
Vlad Zahorodnii 0e96bc341f plugins/screenshot: Cache screenshot attributes
When a QPromise reports results, it's not necessary that the
QFutureWatcher is going to report it immediately. That can happen at
some point in the future, which is okay according to the QFuture api
contract.

Due to that, we cannot assume that the stored Output and EffectWindow
objects pointers are valid when the QFutureWatcher::finished is emitted.


(cherry picked from commit 69f344a439)
2024-02-05 16:13:39 +00:00
Aleix Pol 23af6cb5f1 autotests: Bundle pipewiresourcestream with testScreencasting
testScreencasting refuses to pass with kpipewire. We've attempted
various things to debug it, neither makes any sense. Furthermore, the
test passes locally.

As a short term solution, make the test use pipewire directly.
2024-02-05 18:01:17 +02:00
l10n daemon script 065ce0475f GIT_SILENT Sync po/docbooks with svn 2024-02-05 03:38:15 +00:00
l10n daemon script d3fbe753ea GIT_SILENT Sync po/docbooks with svn 2024-02-04 03:02:00 +00:00
l10n daemon script 158d557683 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-02-04 02:55:59 +00:00
l10n daemon script 0bdc3e73aa GIT_SILENT Sync po/docbooks with svn 2024-02-03 03:02:44 +00:00
Vlad Zahorodnii d296e10803 Add fallback cursor shape for "default" shape
Some cursor themes don't have "default" shape, so fallback to "left_ptr"
with such themes.

BUG: 477476


(cherry picked from commit cc2e6fc96c)
2024-02-02 15:18:45 +00:00
David Redondo 8e46556fff Update to merged version of xdg-toplevel-drag
(cherry picked from commit ee782c8a91)
2024-02-02 14:47:50 +01:00
David Redondo 8c03472f8c Revert "Use qt prefix variant of toplevel drag protocol"
The protocol has been merged upstream and Qt is now using it.

This reverts commit 216a268a43.

(cherry picked from commit 4d0cd42aef)
2024-02-02 14:47:50 +01:00
Niccolò Venerandi 1688463cfb Register touch action to activate Overview instead of toggling it
This is because the Overview will activate itself at the end of a 1:1 gesture,
and a toggle action might actually deactivate it rather than activate it.

(cherry picked from commit 79a61deb25)
2024-02-02 14:47:50 +01:00
Vlad Zahorodnii aafce3b54e wayland: Truncate virtual desktop names
Virtual desktop names are user defined strings so they can exceed
the maximum size of a wayland message size.

BUG: 480614


(cherry picked from commit e58451fc01)
2024-02-02 11:51:01 +00:00
l10n daemon script 23fa0041aa GIT_SILENT Sync po/docbooks with svn 2024-02-02 02:55:20 +00:00
Vlad Zahorodnii e566bdfcd7 Activate next window when an X11 window is minimized
It matches the behavior of XdgToplevelWindow.

BUG: 479388
(cherry picked from commit 5896bab86f)
2024-02-02 02:06:22 +01:00
Xaver Hugl e40366b750 xwayland/xwaylandlauncher: don't enable WAYLAND_DEBUG with KWIN_XWAYLAND_DEBUG=0
(cherry picked from commit 880ce92fb2)
2024-02-02 02:06:22 +01:00
Vlad Zahorodnii 74ab969c72 backends/virtual: Fix OutputFrame
(cherry picked from commit c733e7a7b6)
2024-02-02 02:06:22 +01:00
Xaver Hugl 63868e4dd4 x11window: explicitly resize when the Xwayland scale changes
With how Xwayland scaling works, KWin assumes the window already uses the
new coordinate system - but that doesn't happen until Xwayland and the client
know about the new size as well.

BUG: 480642
(cherry picked from commit c2749e3acf)
2024-02-02 02:06:22 +01:00
Vlad Zahorodnii 8ed28586d9 effect: Fix initialization of QEvent::isAccepted() in cloned events in OffscreenQuickView
QEvent::isAccepted() is initialized to true by default.

BUG: 480538
(cherry picked from commit 93b9fdd391)
2024-02-02 02:06:22 +01:00
Xaver Hugl 19d665b216 autotests/integration: re-enable lid closed output changes test
KWin is handling the lid switch now

(cherry picked from commit 67b1a88466)
2024-02-02 02:06:22 +01:00
Xaver Hugl 9180693c50 plugins/nightcolor: clamp preview color temperature to be somewhat sane
BUG: 480700
(cherry picked from commit cc72778d5e)
2024-02-02 02:06:22 +01:00
Yifan Zhu babc295b3c inputmethod&plugins/buttonrebinds: use new KKeyServer API
To correctly handle Qt::Key_Calculator corresponding to both
XF86Calculator and XF86Calculater.

(cherry picked from commit ae7fb3885b)
2024-02-02 02:06:22 +01:00
Jonathan Esk-Riddell 7bcdd78a89 update version for new release 2024-02-01 09:45:38 +00:00
Vlad Zahorodnii 1cab899c5a Take surface idle inhibitors into account only after window is added to the workspace
This helps to reduce having N sources for the same information.


(cherry picked from commit 795b619704)
2024-02-01 08:50:56 +00:00
Marco Martin 44325842b8 plugins/wobblywindows: Use snapping when the window isn't moving
disable pixel snapping when the window is moving with some velocity/acceleration,
reenable it when is (alsmost) stopped


(cherry picked from commit 19970bd639)
2024-02-01 08:49:03 +00:00
Jay Paul 416ed6479d plugins/screencast: set frame timer to one shot
BUG: 469777


(cherry picked from commit 5ae170f1d6)
2024-02-01 08:28:49 +00:00
l10n daemon script 09529f60f6 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-02-01 02:57:33 +00:00
Xaver Hugl d2d054b921 opengl/glshader: make uniform enums type safe
(cherry picked from commit 896a57d3be)
2024-01-31 13:28:07 +01:00
Xaver Hugl fe2ead7644 backends/drm: use the correct uniform type
(cherry picked from commit a649be64db)
2024-01-31 13:28:07 +01:00
Xaver Hugl 10612ba279 backends/drm: merge all commits and try again if atomic commits fail
The failure might be from the commit reordering going wrong in some way.
The total accumulated state might still work even if an individual commit
does not though, so before considering the whole frame lost, merge all the
commits and try again

(cherry picked from commit 6db05aaef1)
2024-01-31 13:28:07 +01:00
Xaver Hugl 19a0a0118e colorspace: make sdr colorimetry not be about rec.2020 anymore
This was just done because of the wrong assumption that displays needed that
to show the full native gamut. That turned out to be an amdgpu bug though; with
that fixed, most of the 0-100% range is wildly oversaturated.
To make the slider more intuitive, this changes the sdr gamut wideness to instead
interpolate to the native display primaries as indicated by the EDID.

(cherry picked from commit 9c0085f5a9)
2024-01-31 13:28:07 +01:00
Jonathan Esk-Riddell ba0ce9ec1a Update version number for 5.93.0
GIT_SILENT
2024-01-31 10:52:47 +00:00
Xaver Hugl a47d6ffe9b input: increase raise timeout for drag and drop to 1s
This should be long enough to not happen accidentally, but short enough to not be
annoying and discoverable.

BUG: 480511


(cherry picked from commit 8d44ece874)
2024-01-31 08:42:00 +00:00
Vlad Zahorodnii 604924b8a9 plugins/screencast: Fix hidden cursors
The screencast plugin doesn't take into account the hidden status of
the cursor, which results in the cursor being visible when screencasting
even though it's hidden.


(cherry picked from commit 3a1b9414ed)
2024-01-31 08:40:22 +00:00
l10n daemon script ee606a1fc6 GIT_SILENT Sync po/docbooks with svn 2024-01-31 03:14:17 +00:00
l10n daemon script 184522822f 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-01-31 03:06:46 +00:00
Vlad Zahorodnii 0691a973f8 Ignore external updates of _NET_DESKTOP_LAYOUT and _NET_DESKTOP_NAMES
At the moment, the desktop layout in _NET_DESKTOP_LAYOUT overwrites new
desktop layout with outdated information. This happens because kwin tries
to honor the desktop layout set by the pager. However, kwin itself
already acts as the pager. The pager applet in plasma doesn't attempt to
maintain _NET_DESKTOP_LAYOUT with proper values.

On the other hand, kwin trying to both update and also sync its state to
_NET_DESKTOP_LAYOUT and _NET_DESKTOP_NAMES has created a series of
issues, like lockups or rendering glitches.

Given that the window manager can ignore these properties, and the fact
that kwin already does act like a pager, this patch makes kwin ignore
external updates to _NET_DESKTOP_LAYOUT and _NET_DESKTOP_NAMES.

In order to modify the desktop layout on X11, use the dbus api. On
Wayland, either the dbus api or the virtual desktop wayland protocol.

BUG: 422319
BUG: 480371


(cherry picked from commit def3a50558)
2024-01-30 14:54:25 +00:00
l10n daemon script 33f1cd8e81 GIT_SILENT Sync po/docbooks with svn 2024-01-30 03:00:18 +00:00
Xaver Hugl d28e89cc6f colorimetry: use 4x4 matrices for colorimetry transforms
This is so that offsets can be represented in the matrices and not just
scaled and rotated coordinate systems

(cherry picked from commit b1414033ef)
2024-01-29 23:16:58 +01:00
Xaver Hugl 9dd0943b0a wayland: implement experimental tag of the upstream color management protocol
Support is hidden by an environment variable to prevent accidental standardization
on this experimental version. It allows app devs to already implement and
test it though, and easily switch to the proper protocol later

(cherry picked from commit 4dd1e91bda)
2024-01-29 23:16:51 +01:00
Vlad Zahorodnii 655733d834 wayland: Install headers generated by qtwaylandscanner
(cherry picked from commit a64c86b73f)
2024-01-29 20:40:34 +00:00
Vlad Zahorodnii aa5fbb7bbb wayland: Add windows when readyForPainting changes
A window is added to the workspace when it's mapped. It's assumed that
the first Window::windowShown signal indicates that. But it's not
entirely true. For example, if setHidden(false); setHidden(true); are
called in succession, the window will be marked as ready for painting
even though it isn't.

The Window::readyForPaintingChanged() signal fixes that. It's emitted
when the window is actually mapped.


(cherry picked from commit e23cb52a16)
2024-01-29 10:49:08 +00:00
Xaver Hugl 2b03587364 backends/drm: don't set the content type drm property
We haven't seen any benefit from passing it through from apps and apparently
it can make atomic commits fail in some cases.

BUG: 480454


(cherry picked from commit b05fa94d32)
2024-01-29 09:56:52 +00:00
Akseli Lahtinen c51a53f93b Set correct opaqueRegion for Xwayland apps
(cherry picked from commit 91974b7794)
2024-01-29 09:45:21 +00:00
Vlad Zahorodnii 7d99853edc plugins/slidingpopups: Avoid sliding already hidden popups
(cherry picked from commit d9e96223f4)
2024-01-29 09:39:06 +00:00
Vlad Zahorodnii 91b01d66b4 Port ScreenEdges::recreateEdges() to std::span
(cherry picked from commit 341067d4d7)
2024-01-29 09:38:38 +00:00
Vlad Zahorodnii 70ddead9d2 Reserve a screen edge on the same output as the window
This makes the association between the window's output and the screen
edge's output more robust.


(cherry picked from commit 16aaf92782)
2024-01-29 09:38:06 +00:00
Vlad Zahorodnii 80cd4bdbb5 Relax constraints for screen edges reserved by windows
At the moment, if the workspace extends or shrinks by an output, the
hidden panel will be shown. It doesn't make sense in all cases.

Furthermore, no screen edge will be reserved if the layer surface has
some margins.

To address that, allow "floating" panels reserve screen edges and also
make kwin try harder to preserve window edges if the output layout
changes.

CCBUG: 448420


(cherry picked from commit 2d399e93f0)
2024-01-29 09:37:25 +00:00
Vlad Zahorodnii 1264672374 plugins/shakecursor: Ignore pointer motion events when the pointer is constrained
The main motivation is to prevent the shake cursor from triggering in
video games. It's not a bullet-proof solution though.


(cherry picked from commit aaa35d455c)
2024-01-29 09:06:12 +00:00
Vlad Zahorodnii 08b3643153 autotests: Disable outline in breeze
Some our tests assume that with "none" border size, the decoration has
no borders. When breeze paints an outline, that's not the case.


(cherry picked from commit 1eb95982dc)
2024-01-29 09:04:48 +00:00
Vlad Zahorodnii e241e3eb9f wayland: Implement closeable window rule
BUG: 443129


(cherry picked from commit b21229e59a)
2024-01-29 09:03:18 +00:00
Vlad Zahorodnii d1083a4db0 effect: Overwrite the output in OffscreenQuickView::setGeometry()
It seems like QWindow::setGeometry() won't update the associated output
if no platform window has been created, which is the case when running
overview or any other qml effect.

It's not clear whether this is a Qt bug or intended behavior.
qwindow.cpp contains comments assuming that the window is on the primary
output if no platform window exists.


(cherry picked from commit 35572904fc)
2024-01-29 08:56:23 +00:00
Vlad Zahorodnii 8ee4484548 effect: Allocate an offscreen fbo with correct scale in OffscreenQuickView
QQuickWindow::effectiveDevicePixelRatio() uses the device pixel ratio
of the attached QQuickRenderTarget. Instead, the scale factor of the
output should be used, which is what QWindow::devicePixelRatio() returns.


(cherry picked from commit 601d33f294)
2024-01-29 08:56:01 +00:00
Fushan Wen be9bd4caea tabbox/switchers/thumbnail_grid: use FocusScope as main item
By default the focus item in a tabbox is always the main item, so if the
main item is not a focus scope, the inner item will not get focused.

BUG: 477286
FIXED-IN: 6.0


(cherry picked from commit 75b08a8fd9)
2024-01-29 08:50:28 +00:00
l10n daemon script a787b39845 GIT_SILENT Sync po/docbooks with svn 2024-01-28 03:00:30 +00:00
l10n daemon script c67601c20b GIT_SILENT Sync po/docbooks with svn 2024-01-27 02:58:15 +00:00
l10n daemon script 8e6648ecf0 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-01-27 02:54:37 +00:00
Vlad Zahorodnii 615fbac7ee autotests: Add layer_surface_v1.set_exclusive_edge test cases
(cherry picked from commit 1b6aa65ee5)
2024-01-26 12:56:00 +00:00
Marco Martin 67e154b101 wayland: Add support for layer_surface_v1.set_exclusive_edge
This can be used to disambiguate the exclusive edge when the anchors are
on a corner (so there would be 2 candidates)

it's quite quick and dirty mostly to understand if we do want to push for
something along the lines (it should at least do a protocol error when
the requested edge is not within the anchors)


(cherry picked from commit fe8fe42ea9)
2024-01-26 11:38:19 +00:00
l10n daemon script ef3d1f2629 GIT_SILENT Sync po/docbooks with svn 2024-01-26 03:01:16 +00:00
Vlad Zahorodnii 9b964088dc plugins/zoom: Unset PAINT_SCREEN_TRANSFORMED
It's not needed because of the offscreen texture.

BUG: 480216


(cherry picked from commit 91ae3d907e)
2024-01-25 23:18:00 +00:00
Vlad Zahorodnii 7f8c41bedc kconf_update: Add script to drop old desktop switching shortcuts
BUG: 479984
(cherry picked from commit 2505fd03f1)
2024-01-25 10:57:08 +02:00
Xaver Hugl 063d0ab81a core/renderloop: take the output of the active window into account for vrr scheduling
If the active window is on a different output than the one the renderloop is for,
the scheduling logic would otherwise never schedule a repaint while adaptive sync
is active.

BUG: 480252
(cherry picked from commit bbc833baa6)
2024-01-25 10:56:58 +02:00
Xaver Hugl 6fba02a75f plugins/screencast: hardcode DRM_FORMAT_ARGB8888 for screencasts
It's universally supported, and our format negotiation code needs improvements to
properly handle the receiving application not suporting the actual output format

(cherry picked from commit bb2391133d)
2024-01-25 10:56:44 +02:00
Nicolas Fella 6ef84f8451 Remove wrong handling of Qt::KeypadModifier
Qt::KeypadModifier doesn't actually map to any XKB modifier

The XKB_MOD_NAME_NUM modifier is (semi-)unrelated

(cherry picked from commit 06230e43d6)
2024-01-25 10:56:27 +02:00
l10n daemon script 824b38a8fd GIT_SILENT Sync po/docbooks with svn 2024-01-25 02:54:29 +00:00
l10n daemon script 56a65284e2 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-01-25 02:51:08 +00:00
Vlad Zahorodnii d6202dcc60 autotests: Add keypad global shortcuts test
(cherry picked from commit 9cdf19c657)
2024-01-24 15:26:56 +02:00
Nicolas Fella ae23df1f53 Consider Qt::KeypadModifier relevant for global shortcuts
Otherwise kglobalaccel can't distinguish between numbers on the num block and other numbers

BUG: 453423

BUG: 446389
(cherry picked from commit 296d3f31be)
2024-01-24 15:26:46 +02:00
Vlad Zahorodnii dd03140289 kconf_update: Update Version
kconf_expects version 6.


(cherry picked from commit 25150633ed)
2024-01-24 10:17:41 +00:00
Vlad Zahorodnii 13c3a499cd Prefer QRegion::operator+=
`QRegion::operator|=` has some optimizations but it basically boils
down to

  QRegion result(*this);
  result.detach(); // it will make a copy because this is shared
  result.d->append(rect);
  return result;

On the other hand, `QRegion::operator+=` tries to add the new rect
in-place.

(cherry picked from commit 3bce89553c)
2024-01-24 10:36:14 +02:00
Vlad Zahorodnii e6685c0d21 plugins/blur: Fix blur behind decoration
Currently, if only blur behind decoration is enabled, no m_windows entry
is going to be created and so the blur effect won't blur the background.

BUG: 479893
(cherry picked from commit f44484137e)
2024-01-24 10:36:04 +02:00
Vlad Zahorodnii bf33a3de15 tests: Fix constraint region in pointerconstraints example
(cherry picked from commit e01116149b)
2024-01-24 10:35:55 +02:00
l10n daemon script 2849f66f97 GIT_SILENT Sync po/docbooks with svn 2024-01-24 02:56:57 +00:00
l10n daemon script 5e691497c1 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-01-24 02:53:12 +00:00
Vlad Zahorodnii de36aad203 Apply "Accepts focus" window rule to WM_TAKE_FOCUS messages as well
Currently the window rule is not 100% effective because the "take focus"
message is not guarded. So depending on the input model of the X11
window, kwin can still activate a window even if it has a window rule
to force no focus.

workspace()->setShouldGetFocus() should be guarded too to help the focus
stealing prevention logic.

Technically though, forcing XSetInputFocus() or WM_TAKE_FOCUS if the
client doesn't advertise supporting them is finiky. But on the other
hand, the window rules are an advanced feature, so its assumed that the
user knows what they do.

(cherry picked from commit 3663e1ec13)
2024-01-23 22:25:33 +02:00
Vlad Zahorodnii 424ba7d0fc Fix lingering dpms input event filter after cancelling scheduled dpms mode change
The output goes through the following stages when it changes its dpms
mode:

- Output::aboutToTurnOff()]
- some time later, Output::dpmsModeChanged() to indicate that it's off
- Output::dpmsModeChanged() to indicate that it's back on
- Output::wakeUp()

The Output::dpmsModeChanged() signals in the middle are optional. They
may not be emitted after Output::aboutToTurnOff() if the user quickly
cancels the dpms mode transition.

The Workspace should monitor the Output::wakeUp() signal instead.
Alternatively, create the dpms input event filter only after the dpms
mode has changed. While the screen won't be turned back on immediately,
it's still going to produce acceptable visuals. Either solution is fine.
This patch makes the Workspace monitor the wakeUp signal because it
takes fewer lines of code.

BUG: 479659
(cherry picked from commit bbb40a9a84)
2024-01-23 22:25:23 +02:00
Yifan Zhu b0f9cdccdc plugins/fallapart: use InCubic easing
This visual effect corresponds to visible to invisible. So use InCubic
easing for opacity and speed.

(cherry picked from commit adc076322b)
2024-01-23 22:25:13 +02:00
Vlad Zahorodnii e572246ed7 helpers/wayland_wrapper: Bump the buffer size for display_name
The compiler prints the following warning at the moment:

    wl-socket.c:143:9: note: ‘snprintf’ output between 10 and 20 bytes into a destination of size 16

(cherry picked from commit d0a49a6b77)
2024-01-23 22:25:05 +02:00
Xaver Hugl 0fe9e7ac0c move vao from WorkspaceSceneOpenGL to GlxContext
EglContext already had a vao, and it makes more sense for the context to
take care of this than the scene

(cherry picked from commit 8db8dd24bf)
2024-01-23 20:46:08 +01:00
Xaver Hugl e674014d9d outputconfigurationstore: add a fallback for when edid parsing fails
When edid parsing fails, KWin will base output settings on the connector, which
isn't great on its own, but at least works in many cases. When the edid can be
parsed later though, the display settings will reset because now the edid identifier
is used to exclude the old config (in which the latter is missing).
To work around that, this commit adds output identification based on the edid hash,
which is also not ideal, but can be safely matched with in case no output config
with a matching edid identifier exists.

(cherry picked from commit 7e095412aa)
2024-01-23 20:46:04 +01:00
Xaver Hugl 2d08593522 backensd/drm: directly try presentation with changed properties
This optimizes out an unnecessary atomic test - instead of testing the new state and
then attempting to present with that new state, this just directly tries to present the
full state. If that commit fails, the backend just tries again with the safer presentation
mode.

(cherry picked from commit 3cafc20981)
2024-01-23 20:46:01 +01:00
Xaver Hugl d22e6a1977 outputconfigurationstore: take rotation into account for the position
Otherwise outputs may overlap

(cherry picked from commit 7a2d95ddc8)
2024-01-23 20:45:56 +01:00
Vlad Zahorodnii a26d171c78 plugins/qpa: Fix a warning about unused variable
(cherry picked from commit 575ff68e5b)
2024-01-23 21:18:14 +02:00
Vlad Zahorodnii 101a3d075e wayland: Add missing wp_security_context_manager_v1.destroy implementation
(cherry picked from commit 01818f683c)
2024-01-23 21:18:06 +02:00
Yifan Zhu e289c81284 plugins/private/Windowheap: Use InOutCubic easing
All transitions correspond to visible to visible changes, and should
have InOutCubic easing as per HIG.

(cherry picked from commit 8774a0114c)
2024-01-23 21:17:58 +02:00
l10n daemon script 1b4898c2de GIT_SILENT Sync po/docbooks with svn 2024-01-23 03:05:16 +00:00
l10n daemon script 96e85597da 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-01-23 02:58:34 +00:00
Aleix Pol 7ba44593fe screencasting_test: Declaring the metatype is unnecessary now
(cherry picked from commit fd7a67d92e)
2024-01-22 10:44:36 +02:00
Ismael Asensio ab4264a6df kcms/tabbox: Use higher resolution thumbnails for previews
Replace the hardcoded thumbnails which have a low resolution for
current screen standards (~300x200), with higher resolution ones
(~1200x800).

Also set the new 6.0 wallpaper as the fallback desktop thumbnail

BUG: 446765
FIXED-IN: 5.93.0


(cherry picked from commit efde6c8e9e)
2024-01-22 10:41:03 +02:00
Stefan Hoffmeister 264a41cff3 Fix mishandling of output configuration if output monitor EDID is missing
This functionally fixes
* duplication of output configuration in ~/.config/kwinoutputconfig.json
* _wrong_ ouput configuration - in particular the scale - being restored (i.e. scale would never be restored)


(cherry picked from commit d563bc6c86)
2024-01-22 10:39:56 +02:00
Xaver Hugl 219ec5f385 core/renderjournal: improve render time heuristics
Instead of giving the rolling average for render times a special case for
when render time suddenly increases, detect how stable render times are.
If they're volatile and increase a lot, increase the predicated render time
beyond the spike, as more render time spikes are likely to follow.

CCBUG: 477959


(cherry picked from commit 9822e75fbf)
2024-01-22 10:39:03 +02:00
Vlad Zahorodnii 40a9533578 opengl: Correct order of transforms in GLTexturePrivate::updateMatrix
The textureToTransformMatrix should be applied first, otherwise the scale
transform is going to change the winding order of rotations.

In practice though, it shouldn't matter because these matrices are used
to downscale or upscale uv coordinates.


(cherry picked from commit cffacc514d)
2024-01-22 10:37:53 +02:00
Tino Lorenz 5a0f716236 plugins/buttonrebinds: Support rebinding to modifier keys
Allow rebinding buttons to send modifier keys (Control, Alt, Meta,
Shift) without any other key.
This is part of restoring the functionality kcm-wacomtablet had under
X11 for wayland.
CCBUG: 461259

(cherry picked from commit adbf69aab4)
2024-01-22 10:36:46 +02:00
Aki Sakurai a619fc095e Accepting the tablet serial for the xdg_toplevel move/resize function
(cherry picked from commit ab41bcf3ad)
2024-01-22 10:34:56 +02:00
Vlad Zahorodnii 617acb537f opengl: Let OpenGL implementation handle if preprocessor directive
It's less error prone and handles cases like if/elif/else better, etc.

CCBUG: 479279
(cherry picked from commit 7ba7ddfee8)
2024-01-22 10:33:39 +02:00
Vlad Zahorodnii 6c6be75fdf opengl: Fix parsing of the else branch
`it` points to `#else`. We need to move to the next line.

BUG: 479279
(cherry picked from commit 0284610eff)
2024-01-22 10:33:39 +02:00
Vlad Zahorodnii 444b51d95e plugins/colorblindnesscorrection: Ensure that error and correction are fully initialized
vec3() will complain if the vector is not fully initialized. Also if the
type of these variables is changed to vec4 and some miss alpha values,
the glsl compiler will complain again.

(cherry picked from commit 7e8230a596)
2024-01-22 10:33:39 +02:00
Vlad Zahorodnii 22b5634f99 plugins/colorblindnesscorrection: Fix screen becoming white on intel machines
correction.a is uninitialized. It creates problems on intel machines.

BUG: 479749
(cherry picked from commit 4cc94e9462)
2024-01-22 10:33:39 +02:00
l10n daemon script 4e0b7b343e GIT_SILENT Sync po/docbooks with svn 2024-01-22 03:40:08 +00:00
l10n daemon script 0f8893f532 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-01-22 03:36:05 +00:00
l10n daemon script 84c8f4a4e0 GIT_SILENT Sync po/docbooks with svn 2024-01-21 02:55:26 +00:00
Aleix Pol afeee286f5 Revert "screencasting_test: Adapt to KPipeWire change"
This reverts commit e6b8c5318d.

The change in KPipeWire was reverted
2024-01-21 01:53:17 +01:00
l10n daemon script c9b6c5439a GIT_SILENT Sync po/docbooks with svn 2024-01-19 02:59:31 +00:00
Aleix Pol e6b8c5318d screencasting_test: Adapt to KPipeWire change 2024-01-19 01:42:08 +01:00
Xaver Hugl 0050f1443e colors/colordevice: make channel factors linear
The redshift table is in gamma 2.2 encoding and not linear, which means
that it only yields correct results with 1.0 pixel values. It also means
that when it's being applied in linear space in the color management shaders,
the result is quite wrong.

To fix that, this commit makes the channel factors linear and the backend
calculates the nonlinear factors where needed.


(cherry picked from commit 36bec2d941)
2024-01-19 00:15:41 +00:00
Vlad Zahorodnii f1a70c459d plugins/shakecursor: Ensure that cursor is magnificated for at least certain amount of time
If the cursor is magnificated and it's slightly moved so the shake
detector returns std::nullopt, the cursor scale will be set back to 1.0
as soon as possible. This is not ideal. Immediately resetting doesn't
help with locating the cursor.

Also the cursor scale reset delay has been increased to two seconds to
provide more time to see the cursor.


(cherry picked from commit 788c186701)
2024-01-18 19:00:45 +00:00
Vlad Zahorodnii 558c87c359 plugins/screenshot: Use SmoothPixmapTransform when stitching area screenshots
CCBUG: 478426


(cherry picked from commit f6d9b8a0b4)
2024-01-18 17:25:03 +00:00
Vlad Zahorodnii daf7afb68a opengl: Correct transformation order in GLTexture::render()
First, the texture-to-buffer transform has to be applied, then the y
axis should be flipped. Doing it vice versa changes the winding order
of rotation transforms.

Also the screenshot plugin uses incorrect render transform. Since
convertFromGLImage() undoes the render target's transform, the color
space transformation pass should use the same transform, not the
inverted one.

BUG: 479934


(cherry picked from commit f23e0ef05b)
2024-01-18 15:35:30 +00:00
Niccolò Venerandi 94ab3cdb66 kcms/screenedges: Hardcode the Overview as an option in the touchscreen KCM
You can now select "Overview" in the touch KCM to use it as a touch edge gesture again!


(cherry picked from commit 69f8bee0b1)
2024-01-18 14:50:45 +00:00
Xaver Hugl a18c712282 wayland: consider every commit a "content update" for presentation time
The protocol doesn't have a definition of what it means, but damage is a
flawed interpretation. Color management changes are arguably content updates,
so are viewporter changes, so are blur changes and so on.

Also see https://gitlab.freedesktop.org/wayland/wayland-protocols/-/issues/36
for an upstream discussion of this


(cherry picked from commit d5ca429627)
2024-01-18 13:51:24 +00:00
Vlad Zahorodnii b5884bc721 Rename UnmanagedLayer to OverlayLayer
The UnmanagedLayer layer is used for placing overlay content so
rename it to match how it's used in practice.


(cherry picked from commit da4f4d7e69)
2024-01-18 13:17:04 +00:00
l10n daemon script b57c31a896 GIT_SILENT Sync po/docbooks with svn 2024-01-18 02:54:43 +00:00
Fushan Wen f143003647 plugins/colorblindnesscorrection: remove duplicate definition in Tritanopia shader
(cherry picked from commit f79886765d)
2024-01-17 23:53:03 +00:00
Vlad Zahorodnii 947d8c5e59 Drop window type rule
Practically all code assumes that the window type is static and fixing
it would bring extra complexity, which may not be worth given that there
are window rules to control position, focus, layer, etc.

BUG: 466016
(cherry picked from commit 176ae6e692)
2024-01-18 01:17:03 +02:00
Vlad Zahorodnii 7e6876cc63 Introduce layer window rule
The new window rule allows to overwrite the stack layer. It can be
useful on wayland to force picture-in-picture surfaces (which are
xdg-toplevels at the moment) to be placed above fullscreen windows.
Keep above flag is unsuitable because fullscreen windows are placed
higher "above" windows.

CCBUG: 466016
(cherry picked from commit 5c4acbdddd)
2024-01-18 01:16:55 +02:00
Vlad Zahorodnii 8fb0363432 plugins/shakecursor: Use std::deque to store history
It's more suitable for the task. The ShakeDetector constantly adds new
items at the end of the list and pops old items at the front.


(cherry picked from commit 74a193d383)
2024-01-17 23:04:30 +00:00
Xaver Hugl c297b54c6f backends/drm: ensure commits are done before vblank
If a commit is applied during vblank, the kernel delays it to the next vblank,
for X11 reasons. To ensure that doesn't happen with KWin, read how long
vblank is for the current mode and adjust the safety margin accordingly.

CCBUG: 477959


(cherry picked from commit 7007599b3f)
2024-01-17 21:27:53 +00:00
Yifan Zhu cc75f86e4b window: use QRect to calculate visiblePixels
If QRectF is used, the exact comparison several lines down will fail.


(cherry picked from commit 597753047d)
2024-01-17 18:49:04 +00:00
Yifan Zhu 33077cb81c window: don't use exact comparison for QRectFs
With fractional geometries, we can only guarantee that
nextMoveResizeGeom eventually is within one unit of
currentMoveResizeGeom.

BUG: 479786
FIXED-IN: 6.0


(cherry picked from commit 2dba3d30af)
2024-01-17 18:37:35 +00:00
Nate Graham 74da1f01a5 screenedge: reduce default activation delay
Currently there is a 150ms delay before screen edge actions and
hotcorners are triggered; the cursor has to spend that much time there
before they'll activate. This is good for preventing accidental
activations, but also prevents and delays deliberate activations, which
are likely to be more annoying for the user.

To alleviate this, the delay is reduced to 75ms, which still prevents
most of the accidental activations in my testing, while making
deliberate activations faster and easier.


(cherry picked from commit e963ae09cc)
2024-01-17 15:28:09 +00:00
David Edmundson 37d2a79143 plugins/screencast: Don't recreate the core every stream
Loading pipewire is noticably slow with libpipewire loading a bunch of
internals.

Change from a singleton pattern to being managed by the
ScreencastManager

This is still unloaded if the plugin is explicitly stopped.


(cherry picked from commit 42c61dc6a3)
2024-01-17 14:26:54 +00:00
Vlad Zahorodnii 0e62379248 backends/drm: Provide a way to force color management
It can be handy if kwin runs on a setup not capable of HDR or without an
ICC profile. The output management protocol has not been touched because
the long term goal is to have color management enabled by default. This
is rather for testing purposes.


(cherry picked from commit 9c2f12f98f)
2024-01-17 11:43:14 +00:00
Xaver Hugl 6e8f56f713 plugins/fullscreen: retarget the animation instead of restarting it
BUG: 474488
FIXED-IN: 6.0


(cherry picked from commit e9db9cd7d3)
2024-01-17 11:03:04 +00:00
Jie Liu 8c318194eb Only precompute the geometry restore when m_interactiveMoveResize.initialQuickTileMode is None
If the user wants to move a tiled window but changes their mind and tiles the window back to the previous
position, quickTileGeometryRestore() will return an error value beacause m_electricMaximizing is true and
the m_electricGeometryRestore is the same as the geometry of the window in the last tiled mode.

Now the geometry restore of the tiled window is true when starting interactive move, so we no longer need
to precompute it.

Changes for testQuickTilingPointerMove:

We need to attach a new image after the tiling window, so that updateElectricGeometryRestore can obtain
the same framegeometry as the framegeometry obtained during actual runtime.

Now testQuickTilingPointerMove can detect the error:If the user wants to move a tiled window but changes
their mind and tiles the window back to the previous position, quickTileGeometryRestore() will return an
error value beacause m_electricMaximizing is true and the m_electricGeometryRestore is the same as the
geometry of the window in the last tiled mode.

Signed-off-by: Jie Liu <liujie01@kylinos.cn>


(cherry picked from commit 1a1eaee13f)
2024-01-17 09:48:55 +00:00
l10n daemon script f5e552c07b GIT_SILENT Sync po/docbooks with svn 2024-01-17 02:59:14 +00:00
Xaver Hugl e20c953b8a wayland/surface: store subsurface transaction in a unique_ptr
(cherry picked from commit fd2e77317f)
2024-01-17 01:00:51 +00:00
Xaver Hugl 3569eaab15 backends/drm: apply the ICC profile without premultiplication
As a side effect, this ensures that when alpha is zero, rgb is zero as well.
This is needed because the ICC profile may contain transformations where zero
brightness gets mapped to a non-zero value.

BUG: 479380


(cherry picked from commit 6ab8f179a7)
2024-01-16 19:05:25 +00:00
Xaver Hugl 12c3197ca6 opengl/glshadermanager: add missing newline
BUG: 479279


(cherry picked from commit ed339de953)
2024-01-16 13:55:02 +00:00
David Redondo 228ef989b4 Make sure window thumbnails and Qt Quick resources are destroyed properly
Drops the doneCurrent as it was preventing proper cleanUp
because no context was current when textures were deleted.
Also avoid manipulating the context when Qt has the current
one, as various Qt classes have guards around their cleanup
handlers which rely on a current Qt context.
Despite the comment the order of render control and view destruction
needs to be switched as the QQuickWindow destructor calls into
the render control to notify if of window destruction.
BUG:478770
BUG:479846
FIXED-IN:6.0


(cherry picked from commit 203c4998bc)
2024-01-16 13:34:11 +00:00
l10n daemon script 3a3ea5d23a GIT_SILENT Sync po/docbooks with svn 2024-01-16 03:00:00 +00:00
Xaver Hugl c115b793a9 backends/drm: make icc profiles work with OpenGL ES
OpenGL doesn't support 1D textures, and has some special requirements in
the shaders, like no implicit conversion from int to float


(cherry picked from commit 4433fb48dc)
2024-01-15 19:15:25 +00:00
Joshua Goins 5b557a6ada Add missing find_dependency for epoxy
This is required by the KWin target, but was missing a find_dependency
call. If any downstream project tried to link to the KWin::kwin target,
it would fail because epoxy couldn't be found.


(cherry picked from commit c3d3d83b56)
2024-01-15 19:00:48 +00:00
David Edmundson 49ced6dcdd screencasting: Resume streams after buffer renegotiation
When we start renegotiation the stream is pasused. This is not restarted
when the format has been renegotiated.

This occurred when a streaming window was resized


(cherry picked from commit 2e6619f3d0)
2024-01-15 18:20:47 +00:00
Vlad Zahorodnii 3f5f1ce9ba scene: Remove warning message about older presentation timestamps
Outputs present frames at different pace, some can present new content
later, some sooner. If the scene gets a slightly older presentation
timestamp, it's okay.

(cherry picked from commit f665dda192)
2024-01-15 19:57:33 +02:00
Vlad Zahorodnii b813b9879a Break show desktop mode if a new window is added
BUG: 479424
(cherry picked from commit af39179446)
2024-01-15 19:57:21 +02:00
Vlad Zahorodnii 484e7c94e6 autotests: Add a test to verify that show desktop mode quits after activating a window
(cherry picked from commit 359f36d6ab)
2024-01-15 19:57:10 +02:00
Vlad Zahorodnii 05de026fd2 backends/drm: Fix a crash in VirtualEglGbmLayer::texture()
If nothing has been rendered yet, m_currentSlot will be null.

BUG: 475296
BUG: 479558
(cherry picked from commit 3b67edf20d)
2024-01-15 19:57:01 +02:00
Vlad Zahorodnii f05f1a29d0 effect: Remove const refs in EffectFrame
It's a micro optimization.

(cherry picked from commit 72c391ebc8)
2024-01-15 19:56:51 +02:00
Vlad Zahorodnii 9a09ebe673 plugins/mouseclick: Fix glitches
Effect frame geometry is not properly synchronized with the quick
scene geometry.

BUG: 477892
(cherry picked from commit 09f97c8037)
2024-01-15 19:56:42 +02:00
Vlad Zahorodnii b62d212a58 Fix cleanup of forced window shortcuts
XdgToplevelWindow doesn't call finishWindowRules(). It creates a problem
for Workspace::removeWindow() because it calls setShortcut() to release
the window shortcut.

While one way to fix the bug would be to add a finishWindowRules() call
in XdgToplevelWindow, it would perhaps be not the best one because it
would change the appearance of decoration when the window is closed.

Instead, this change makes the workspace release the shortcut when the
window is closed. It has a couple of advantages: the appearance of the
decoration won't change, shortcut cleanup is better encapsulated.

BUG: 478647


(cherry picked from commit b98607c689)
2024-01-15 14:41:54 +00:00
Vlad Zahorodnii 3a37f8dbb2 scripting: Fix a crash in useGlThumbnails() when compositing is off
BUG: 479791


(cherry picked from commit 4f8c941bff)
2024-01-15 14:24:33 +00:00
Vlad Zahorodnii fc7a92096b plugins: Hide "Drag Down to Close" when using a pointing device
BUG: 479802


(cherry picked from commit 2d71d7cada)
2024-01-15 14:07:27 +00:00
Vlad Zahorodnii e87dcd4cd9 plugins/shakecursor: Ignore motion events with at least one pressed button
It reduces the chances of false triggering the plugin, for example if
the user presses a mouse button and chaotically moves the pointer
because they navigate in 3D space and what not.


(cherry picked from commit 0ddcc85f68)
2024-01-15 09:39:00 +00:00
Yifan Zhu f0387d2f85 scene/cursordelegate_opengl: undo ortho() flip y
Flip y axis before and after applying renderTarget.transform to undo
ortho() flipping the y axis. Otherwise the cursor is invisible on
rotated screen.

BUG: 479764
FIXED-IN: 6.0


(cherry picked from commit 1f74e9a5c5)
2024-01-15 08:19:32 +00:00
Weng Xuetian 1ac4a2498d
inputmethod: Ensure InputPanelV1Window is always within the screen
Currently when input panel is using overlay mode and the cursor rectangle
is below or above the screen area, the input panel may be placed off the
screen. The change ensure it is always placed within the screen area
using similar math like xdg_popup's slide_y constrain.

(cherry picked from commit 1fd5a6555e)
2024-01-14 09:48:35 -08:00
l10n daemon script ef7664a647 GIT_SILENT Sync po/docbooks with svn 2024-01-14 03:45:34 +00:00
Yifan Zhu ffb13a1cd8 kcms/options: port to KCModule methods
Remove code that duplicates functionality of KCModule.

Previously the various config items were not fully ported to using
KCModule methods, and kept custom versions of isSaveNeeded and
isDefault. When called from KWinOptions::updateUnmanagedState, these
methods incorrectly reports that there are still changes to be saved.
This patch set ports all configs in window behavior to methods provided
by KCModule, solving the problem.

BUG: 477940


(cherry picked from commit faab23e914)
2024-01-13 18:32:47 +00:00
Xaver Hugl 97df214487 opengl/glshader: use gamma 2.2 for sRGB render targets
The sRGB global colordescription uses gamma 2.2, so this function also has to do
it, or the shader will end up doing a colorspace conversion where there shouldn't
be one.
This also meams that HDR content will be wrongly encoded, but fixing that while
also dealing with sRGB content correctly requires a lot more invasive changes, in
KWin and in the screenshot and screencast APIs.

BUG: 478967


(cherry picked from commit c1e09f65c9)
2024-01-13 17:28:01 +00:00
Ismael Asensio eca4049ef6 kcms/tabbox: Fix preview for show desktop option
Use the correct config option to decide whether to show the desktop
thumbnail on preview. "DesktopMode" refers to filter by desktop.

(cherry picked from commit 20bee00681)
2024-01-13 17:10:55 +01:00
Ismael Asensio b08547968d kcms/tabbox: Mock-up closeable role for previews
Fixes a qml warning and wrong representation when trying to
access this model property

(cherry picked from commit 3353ed87ef)
2024-01-13 16:07:30 +01:00
Ismael Asensio 7bd9fe6827 kcms/tabbox: Add mock-up object for KWin.DesktopBackground
The window switcher previews don't use the actual quick components
the KWin plugin provides, but mock-up objects of those.

Add a mock-up component for `KWin.DesktopBackground`, which is just
a thumbnail of the desktop default image but stretched to cover the
whole parent size.

This fixes the previews for flip&cover window switchers.

BUG: 479552
FIXED-IN: 5.93.0

(cherry picked from commit 3572e6f0e7)
2024-01-13 16:07:25 +01:00
Alexander Lohnau 3fa088af00 Remove unneeded includes from headers and cpp files
(cherry picked from commit 7d1db53f6b)
2024-01-13 11:26:36 +00:00
Ismael Asensio 0dd9f0a31f kcms/tabbox: Fix tabbox preview not getting dismissed
On X11 we would dismiss the tabbox preview when clicking outside
of the switcher. This doesn't work on Wayland because the popup
cannot globally grab the mouse and doesn't get notified.

Use `QEvent::FocusOut` instead which works on both platforms.

We also get rid of a warning message.

BUG: 374971
FIXED-IN: 5.93.0


(cherry picked from commit b08a4a1896)
2024-01-12 23:07:35 +00:00
Xaver Hugl df4657c963 opengl/glshader: print the shader source if compilation fails
The shader log is almost entirely useless without the source

CCBUG: 479279


(cherry picked from commit 427ce522a2)
2024-01-12 21:17:53 +00:00
Xaver Hugl 4b4852463f backends/drm: wait for the pageflip to be done with the condition variable
...instead of busy looping, which is causing several percent CPU usage in some cases

BUG: 479126


(cherry picked from commit d4a3d6689e)
2024-01-12 20:56:05 +00:00
Xaver Hugl 4a674e6726 backends/drm: don't call QThread::currentThread in a loop
We're always in the same thread, so there's no need to check it


(cherry picked from commit 56fc8f83ac)
2024-01-12 20:40:15 +00:00
Vlad Zahorodnii fc4a6ab4ff wayland: Fix handling of unminimization for not fully initialized xdg-toplevels
If setMinimized(false) is called for a not fully initialized
XdgToplevelWindow, we don't want to emit the windowShown signal.

BUG: 479234


(cherry picked from commit c59f385996)
2024-01-12 13:09:48 +00:00
Vlad Zahorodnii 37b6092aef Fix software cursor stucking on old monitor
When the software cursor leaves an output, its RenderLayer is marked
as invisible and the area corresponding to the layer is scheduled to
be repainted in the output layer. However, the composite function only
checks whether the root RenderLayer needs a repaint, not the output
layer too.

BUG: 479668


(cherry picked from commit 1c15a6dd88)
2024-01-12 12:39:55 +00:00
Xaver Hugl e7870f0841 input: remove the terminate server shortcut
Accidentally pressing any shortcut shouldn't take down the whole session.
If KWin isn't reponsive but can still process shortcuts for some reason,
you can still switch to a different virtual terminal to explicitly kill
it from there


(cherry picked from commit 260bc0a61d)
2024-01-12 12:27:05 +00:00
Xaver Hugl d1d1b52bed backends/drm: don't allow implicit modifiers for multi gpu transfers
As we translate DRM_FORMAT_MOD_LINEAR to implicit modifiers + linear flag, the
egl import path should still work without implicit modifiers too.

BUG: 478921


(cherry picked from commit 451b878bb9)
2024-01-12 12:17:18 +00:00
Xaver Hugl d02cf12f13 opengl: don't crash in GLTexture::toImage with OpenGL ES
OpenGL ES 2 doesn't support glGetTexImage


(cherry picked from commit bc58d13ee8)
2024-01-12 11:48:00 +00:00
Jin Liu a5437f9af7 Update keyboard focus when exiting from a keyboard-grabbing effect
BUG: 479628


(cherry picked from commit 18ba622c40)
2024-01-12 11:32:01 +00:00
Vlad Zahorodnii 88d19feec4 Fix evaluating window rules for closed windows
gedit changes its caption from "Untitled document - gedit" to "gedit"
when it closes. This schedules Window::evaluateWindowRules() to be
called when the window is already marked as deleted. kwin then crashes.

In order to prevent that, a direct connection can be used instead. But
then the caption must be initialized extra carefully because if the
window rule changes the window type, "<N>" can be lost.

(cherry picked from commit bc30ca64dc)
2024-01-12 11:14:48 +00:00
Vlad Zahorodnii fe5e3a4ce2 Add Window::captionNormalChanged()
This signal notifies when the client specified caption changes, not when
kwin changes it because it changed the suffix, etc.

(cherry picked from commit 4ab504c994)
2024-01-12 11:14:48 +00:00
Vlad Zahorodnii a7f1c284a0 scene: Fix alpha channel of offscreen cursor texture
When running with 10bpc, the alpha channel has only 2 bits for it, which
is too low for the cursor.

BUG: 479637


(cherry picked from commit 68f1570d45)
2024-01-12 11:01:50 +00:00
Jie Liu 2292ad8bd0 update keyboard focus when window switcher is closed.
BUG:477885

Signed-off-by: Jie Liu <liujie01@kylinos.cn>


(cherry picked from commit e427ad73aa)
2024-01-12 10:37:52 +00:00
Vlad Zahorodnii 0da6354bce scene: Fix software cursor clip region
The dirty region is in the output local coordinate space.

BUG: 479583
(cherry picked from commit 36222adb25)
2024-01-12 10:20:42 +00:00
Vlad Zahorodnii e3e4547392 core: Add Output::rectF
(cherry picked from commit 571e4026ac)
2024-01-12 10:20:42 +00:00
Vlad Zahorodnii 680a759852 core: Rename Output::fractionalGeometry()
In Qt, if an overloaded function returns QRectF/QSizeF/QPointF, it
usually has F suffix. Do the same in kwin for the consistency sake.

(cherry picked from commit c314705d53)
2024-01-12 10:20:42 +00:00
Vlad Zahorodnii fce26936d0 effect: Install xcb.h
BUG: 479584


(cherry picked from commit 3a5ba58a45)
2024-01-12 10:06:59 +00:00
Vlad Zahorodnii 62ac1f86d1 xwayland: Make xinerama index -> Output mapping more robust with fractional scaling
xdg-output-v1 uses the fractional geometry, so also use it when mapping
a xinerama screen index to an Output.


(cherry picked from commit 66b1462cf8)
2024-01-12 09:55:35 +00:00
Vlad Zahorodnii 0b1759076c xwayland: Fix primary output identification
Output::geometry() returns a logical geometry, while the crtc rect is in
the device pixels.


(cherry picked from commit 3f1e57de1c)
2024-01-12 09:20:42 +00:00
Xaver Hugl bce1047080 effect/offscreenquickview: always use GL_RGBA8
GL_RGB8 isn't supported by OpenGL ES

BUG: 479055


(cherry picked from commit a05a6d8727)
2024-01-10 22:47:04 +00:00
l10n daemon script 3298ae3405 GIT_SILENT Sync po/docbooks with svn 2024-01-10 22:42:15 +00:00
Jonathan Esk-Riddell 9a73beecdd Update version number for 5.92.90
GIT_SILENT
2024-01-10 14:17:35 +00:00
1069 changed files with 34871 additions and 29436 deletions
examples/quick-effect/package

View File

@ -5,7 +5,7 @@ include:
- project: sysadmin/ci-utilities
file:
- /gitlab-templates/linux-qt6.yml
- /gitlab-templates/freebsd-qt6.yml
# - /gitlab-templates/freebsd-qt6.yml
suse_tumbleweed_qt66_reduced_featureset:
extends: suse_tumbleweed_qt66

View File

@ -1,6 +1,6 @@
cmake_minimum_required(VERSION 3.16)
set(PROJECT_VERSION "5.92.0") # Handled by release scripts
set(PROJECT_VERSION "6.0.4") # Handled by release scripts
project(KWin VERSION ${PROJECT_VERSION})
set(CMAKE_C_STANDARD 99)
@ -8,7 +8,7 @@ set(CMAKE_CXX_STANDARD 20)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(QT_MIN_VERSION "6.6.0")
set(KF6_MIN_VERSION "5.240.0")
set(KF6_MIN_VERSION "6.0.0")
set(KDE_COMPILERSETTINGS_LEVEL "5.82")
find_package(ECM ${KF6_MIN_VERSION} REQUIRED NO_MODULE)
@ -71,7 +71,7 @@ if (NOT Qt6Test_FOUND)
endif()
if (BUILD_TESTING)
find_package(KPipeWire)
pkg_check_modules(PipeWire IMPORTED_TARGET libpipewire-0.3 REQUIRED)
endif()
# required frameworks by Core

View File

@ -6,5 +6,5 @@ set(KWIN_EFFECTS_INTERFACE "@PACKAGE_KDE_INSTALL_DBUSINTERFACEDIR@/org.kde.kwin.
set(KWIN_VIRTUALKEYBOARD_INTERFACE "@PACKAGE_KDE_INSTALL_DBUSINTERFACEDIR@/org.kde.kwin.VirtualKeyboard.xml")
set(KWIN_TABLETMODE_INTERFACE "@PACKAGE_KDE_INSTALL_DBUSINTERFACEDIR@/org.kde.KWin.TabletModeManager.xml")
set(KWIN_INPUTDEVICE_INTERFACE "@PACKAGE_KDE_INSTALL_DBUSINTERFACEDIR@/org.kde.kwin.InputDevice.xml")
set(KWIN_COLORCORRECT_INTERFACE "@PACKAGE_KDE_INSTALL_DBUSINTERFACEDIR@/org.kde.kwin.ColorCorrect.xml")
set(KWIN_NIGHTLIGHT_INTERFACE "@PACKAGE_KDE_INSTALL_DBUSINTERFACEDIR@/org.kde.KWin.NightLight.xml")
set(KWIN_WAYLAND_BIN_PATH "@CMAKE_INSTALL_FULL_BINDIR@/kwin_wayland")

View File

@ -131,6 +131,7 @@ integrationTest(NAME testXwaylandServerRestart SRCS xwaylandserver_restart_test.
integrationTest(NAME testFakeInput SRCS fakeinput_test.cpp)
integrationTest(NAME testSecurityContext SRCS security_context_test.cpp)
integrationTest(NAME testStickyKeys SRCS sticky_keys_test.cpp)
integrationTest(NAME testXinerama SRCS xinerama_test.cpp)
qt_add_dbus_interfaces(DBUS_SRCS ${CMAKE_BINARY_DIR}/src/org.kde.kwin.VirtualKeyboard.xml)
integrationTest(NAME testVirtualKeyboardDBus SRCS test_virtualkeyboard_dbus.cpp ${DBUS_SRCS})
@ -139,8 +140,8 @@ if (KWIN_BUILD_GLOBALSHORTCUTS)
integrationTest(NAME testGlobalShortcuts SRCS globalshortcuts_test.cpp LIBS XCB::ICCCM KF6::GlobalAccel KF6::I18n XKB::XKB)
integrationTest(NAME testKWinBindings SRCS kwinbindings_test.cpp LIBS KF6::I18n)
endif()
if (TARGET K::KPipeWire)
integrationTest(NAME testScreencasting SRCS screencasting_test.cpp LIBS K::KPipeWire)
if (TARGET PkgConfig::PipeWire)
integrationTest(NAME testScreencasting SRCS screencasting_test.cpp pipewirecore.cpp pipewiresourcestream.cpp LIBS Qt::GuiPrivate PkgConfig::PipeWire)
endif()
if (KWIN_BUILD_ACTIVITIES)

View File

@ -140,6 +140,7 @@ void TestDbusInterface::testGetWindowInfoXdgShellClient()
#if KWIN_BUILD_ACTIVITIES
{QStringLiteral("activities"), QStringList()},
#endif
{QStringLiteral("layer"), NormalLayer},
};
// let's get the window info
@ -276,6 +277,7 @@ void TestDbusInterface::testGetWindowInfoX11Client()
#if KWIN_BUILD_ACTIVITIES
{QStringLiteral("activities"), QStringList()},
#endif
{QStringLiteral("layer"), NormalLayer},
};
// let's get the window info

View File

@ -119,8 +119,8 @@ void WobblyWindowsShadeTest::testShadeMove()
QVERIFY(!window->isShade());
QVERIFY(window->isActive());
QSignalSpy windowShownSpy(window, &Window::windowShown);
QVERIFY(windowShownSpy.wait());
QSignalSpy readyForPaintingChangedSpy(window, &Window::readyForPaintingChanged);
QVERIFY(readyForPaintingChangedSpy.wait());
// now shade the window
workspace()->slotWindowShade();

View File

@ -49,6 +49,7 @@ private Q_SLOTS:
void testUserActionsMenu();
void testMetaShiftW();
void testComponseKey();
void testKeypad();
void testX11WindowShortcut();
void testWaylandWindowShortcut();
void testSetupWindowShortcut();
@ -275,6 +276,44 @@ void GlobalShortcutsTest::testComponseKey()
QTRY_COMPARE(triggeredSpy.count(), 0);
}
void GlobalShortcutsTest::testKeypad()
{
auto zeroAction = std::make_unique<QAction>();
zeroAction->setProperty("componentName", QStringLiteral("kwin"));
zeroAction->setObjectName(QStringLiteral("globalshortcuts-test-keypad-0"));
QSignalSpy zeroActionTriggeredSpy(zeroAction.get(), &QAction::triggered);
KGlobalAccel::self()->setShortcut(zeroAction.get(), QList<QKeySequence>{Qt::MetaModifier | Qt::KeypadModifier | Qt::Key_0}, KGlobalAccel::NoAutoloading);
auto insertAction = std::make_unique<QAction>();
insertAction->setProperty("componentName", QStringLiteral("kwin"));
insertAction->setObjectName(QStringLiteral("globalshortcuts-test-keypad-ins"));
QSignalSpy insertActionTriggeredSpy(insertAction.get(), &QAction::triggered);
KGlobalAccel::self()->setShortcut(insertAction.get(), QList<QKeySequence>{Qt::MetaModifier | Qt::KeypadModifier | Qt::Key_Insert}, KGlobalAccel::NoAutoloading);
// Turn on numlock
quint32 timestamp = 0;
Test::keyboardKeyPressed(KEY_NUMLOCK, timestamp++);
Test::keyboardKeyReleased(KEY_NUMLOCK, timestamp++);
Test::keyboardKeyPressed(KEY_LEFTMETA, timestamp++);
Test::keyboardKeyPressed(KEY_KP0, timestamp++);
Test::keyboardKeyReleased(KEY_KP0, timestamp++);
Test::keyboardKeyReleased(KEY_LEFTMETA, timestamp++);
QTRY_COMPARE(zeroActionTriggeredSpy.count(), 1);
QCOMPARE(insertActionTriggeredSpy.count(), 0);
// Turn off numlock
Test::keyboardKeyPressed(KEY_NUMLOCK, timestamp++);
Test::keyboardKeyReleased(KEY_NUMLOCK, timestamp++);
Test::keyboardKeyPressed(KEY_LEFTMETA, timestamp++);
Test::keyboardKeyPressed(KEY_KP0, timestamp++);
Test::keyboardKeyReleased(KEY_KP0, timestamp++);
Test::keyboardKeyReleased(KEY_LEFTMETA, timestamp++);
QTRY_COMPARE(insertActionTriggeredSpy.count(), 1);
QCOMPARE(zeroActionTriggeredSpy.count(), 1);
}
void GlobalShortcutsTest::testX11WindowShortcut()
{
// create an X11 window

View File

@ -10,6 +10,7 @@
#include "core/output.h"
#include "inputmethod.h"
#include "inputpanelv1window.h"
#include "keyboard_input.h"
#include "pointer_input.h"
#include "qwayland-input-method-unstable-v1.h"
@ -63,6 +64,8 @@ private Q_SLOTS:
void testDisableShowInputPanel();
void testModifierForwarding();
void testFakeEventFallback();
void testOverlayPositioning_data();
void testOverlayPositioning();
private:
void touchNow()
@ -552,6 +555,10 @@ void InputMethodTest::testV3Styling()
// Merged range should be [1,6).
QCOMPARE(textInputPreeditSpy.last().at(1), 1);
QCOMPARE(textInputPreeditSpy.last().at(2), 6);
shellSurface.reset();
QVERIFY(Test::waitForWindowClosed(window));
QVERIFY(!kwinApp()->inputMethod()->isActive());
}
void InputMethodTest::testDisableShowInputPanel()
@ -584,6 +591,9 @@ void InputMethodTest::testDisableShowInputPanel()
textInputV2->showInputPanel();
QVERIFY(requestShowInputPanelSpy.count() || requestShowInputPanelSpy.wait());
QVERIFY(!kwinApp()->inputMethod()->isActive());
shellSurface.reset();
QVERIFY(Test::waitForWindowClosed(window));
}
void InputMethodTest::testModifierForwarding()
@ -655,6 +665,10 @@ void InputMethodTest::testModifierForwarding()
QVERIFY(modifierSpy.count() == 3 || modifierSpy.wait());
disconnect(keyChangedConnection);
disconnect(modifiersChangedConnection);
shellSurface.reset();
QVERIFY(Test::waitForWindowClosed(window));
QVERIFY(!kwinApp()->inputMethod()->isActive());
}
void InputMethodTest::testFakeEventFallback()
@ -726,6 +740,71 @@ void InputMethodTest::testFakeEventFallback()
compare(keySpy.at(0), KEY_ENTER, KWayland::Client::Keyboard::KeyState::Pressed);
compare(keySpy.at(1), KEY_ENTER, KWayland::Client::Keyboard::KeyState::Released);
shellSurface.reset();
QVERIFY(Test::waitForWindowClosed(window));
kwinApp()->inputMethod()->setActive(false);
QVERIFY(!kwinApp()->inputMethod()->isActive());
}
void InputMethodTest::testOverlayPositioning_data()
{
QTest::addColumn<QRect>("cursorRectangle");
QTest::addColumn<QRect>("result");
QTest::newRow("regular") << QRect(10, 20, 30, 40) << QRect(60, 160, 200, 50);
QTest::newRow("offscreen-left") << QRect(-200, 40, 30, 40) << QRect(0, 180, 200, 50);
QTest::newRow("offscreen-right") << QRect(1200, 40, 30, 40) << QRect(1080, 180, 200, 50);
QTest::newRow("offscreen-top") << QRect(1200, -400, 30, 40) << QRect(1080, 0, 200, 50);
// Check it is flipped near the bottom of screen (anchor point 844 + 100 + 40 = 1024 - 40)
QTest::newRow("offscreen-bottom-flip") << QRect(1200, 844, 30, 40) << QRect(1080, 894, 200, 50);
// Top is (screen height 1024 - window height 50) = 984
QTest::newRow("offscreen-bottom-slide") << QRect(1200, 1200, 30, 40) << QRect(1080, 974, 200, 50);
}
void InputMethodTest::testOverlayPositioning()
{
QFETCH(QRect, cursorRectangle);
QFETCH(QRect, result);
Test::inputMethod()->setMode(Test::MockInputMethod::Mode::Overlay);
QVERIFY(!kwinApp()->inputMethod()->isActive());
touchNow();
QSignalSpy windowAddedSpy(workspace(), &Workspace::windowAdded);
QSignalSpy windowRemovedSpy(workspace(), &Workspace::windowRemoved);
QSignalSpy activateSpy(kwinApp()->inputMethod(), &InputMethod::activeChanged);
std::unique_ptr<KWayland::Client::TextInput> textInput(Test::waylandTextInputManager()->createTextInput(Test::waylandSeat()));
// Create an xdg_toplevel surface and wait for the compositor to catch up.
std::unique_ptr<KWayland::Client::Surface> surface(Test::createSurface());
std::unique_ptr<Test::XdgToplevel> shellSurface(Test::createXdgToplevelSurface(surface.get()));
// Make the window smaller than the screen and move it.
Window *window = Test::renderAndWaitForShown(surface.get(), QSize(1080, 824), Qt::red);
window->move(QPointF(50, 100));
waylandServer()->seat()->setFocusedTextInputSurface(window->surface());
textInput->setCursorRectangle(cursorRectangle);
textInput->enable(surface.get());
// Overlay is shown upon activate
QVERIFY(windowAddedSpy.wait());
QCOMPARE(workspace()->activeWindow(), window);
QCOMPARE(windowAddedSpy.count(), 2);
QVERIFY(activateSpy.count() || activateSpy.wait());
QVERIFY(kwinApp()->inputMethod()->isActive());
auto keyboardWindow = kwinApp()->inputMethod()->panel();
QVERIFY(keyboardWindow);
// Check the overlay window is placed with cursor rectangle + window position.
QCOMPARE(keyboardWindow->frameGeometry(), result);
// Destroy the test window.
shellSurface.reset();
QVERIFY(Test::waitForWindowClosed(window));
Test::inputMethod()->setMode(Test::MockInputMethod::Mode::TopLevel);
}
WAYLANDTEST_MAIN(InputMethodTest)

View File

@ -58,7 +58,6 @@ private Q_SLOTS:
void testReconfigure();
void testChangeLayoutThroughDBus();
void testPerLayoutShortcut();
void testDBusServiceExport();
void testVirtualDesktopPolicy();
void testWindowPolicy();
void testApplicationPolicy();
@ -307,36 +306,6 @@ void KeyboardLayoutTest::testPerLayoutShortcut()
Test::keyboardKeyReleased(KEY_LEFTCTRL, timestamp++);
}
void KeyboardLayoutTest::testDBusServiceExport()
{
// verifies that the dbus service is only exported if there are at least two layouts
// first configure layouts, with just one layout
layoutGroup.writeEntry("LayoutList", QStringLiteral("us"));
layoutGroup.sync();
reconfigureLayouts();
auto xkb = input()->keyboard()->xkb();
QCOMPARE(xkb->numberOfLayouts(), 1u);
// default layout is English
QCOMPARE(xkb->layoutName(), QStringLiteral("English (US)"));
// with one layout we should not have the dbus interface
QVERIFY(!QDBusConnection::sessionBus().interface()->isServiceRegistered(QStringLiteral("org.kde.keyboard")).value());
// reconfigure to two layouts
layoutGroup.writeEntry("LayoutList", QStringLiteral("us,de"));
layoutGroup.sync();
reconfigureLayouts();
QCOMPARE(xkb->numberOfLayouts(), 2u);
QVERIFY(QDBusConnection::sessionBus().interface()->isServiceRegistered(QStringLiteral("org.kde.keyboard")).value());
// and back to one layout
layoutGroup.writeEntry("LayoutList", QStringLiteral("us"));
layoutGroup.sync();
reconfigureLayouts();
QCOMPARE(xkb->numberOfLayouts(), 1u);
QVERIFY(!QDBusConnection::sessionBus().interface()->isServiceRegistered(QStringLiteral("org.kde.keyboard")).value());
}
void KeyboardLayoutTest::testVirtualDesktopPolicy()
{
layoutGroup.writeEntry("LayoutList", QStringLiteral("us,de,de(neo)"));

View File

@ -71,6 +71,10 @@ WaylandTestApplication::WaylandTestApplication(OperationMode mode, int &argc, ch
qunsetenv("XKB_DEFAULT_VARIANT");
qunsetenv("XKB_DEFAULT_OPTIONS");
auto breezerc = KSharedConfig::openConfig(QStringLiteral("breezerc"));
breezerc->group(QStringLiteral("Common")).writeEntry(QStringLiteral("OutlineIntensity"), QStringLiteral("OutlineOff"));
breezerc->sync();
auto config = KSharedConfig::openConfig(QString(), KConfig::SimpleConfig);
KConfigGroup windowsGroup = config->group(QStringLiteral("Windows"));
windowsGroup.writeEntry("Placement", Placement::policyToString(PlacementSmart));

View File

@ -446,6 +446,11 @@ class MockInputMethod : public QObject, QtWayland::zwp_input_method_v1
{
Q_OBJECT
public:
enum class Mode {
TopLevel,
Overlay,
};
MockInputMethod(struct wl_registry *registry, int id, int version);
~MockInputMethod();
@ -458,6 +463,8 @@ public:
return m_context;
}
void setMode(Mode mode);
Q_SIGNALS:
void activate();
@ -469,6 +476,7 @@ private:
std::unique_ptr<KWayland::Client::Surface> m_inputSurface;
QtWayland::zwp_input_panel_surface_v1 *m_inputMethodSurface = nullptr;
struct ::zwp_input_method_context_v1 *m_context = nullptr;
Mode m_mode = Mode::TopLevel;
};
class FractionalScaleManagerV1 : public QObject, public QtWayland::wp_fractional_scale_manager_v1
@ -683,7 +691,8 @@ enum class CreationSetup {
};
QtWayland::zwp_input_panel_surface_v1 *createInputPanelSurfaceV1(KWayland::Client::Surface *surface,
KWayland::Client::Output *output);
KWayland::Client::Output *output,
MockInputMethod::Mode mode);
FractionalScaleV1 *createFractionalScaleV1(KWayland::Client::Surface *surface);

View File

@ -7,6 +7,7 @@
#include "kwin_wayland_test.h"
#include "core/output.h"
#include "core/outputconfiguration.h"
#include "main.h"
#include "pointer_input.h"
#include "screenedge.h"
@ -44,6 +45,7 @@ private Q_SLOTS:
void testChangeLayer();
void testPlacementArea_data();
void testPlacementArea();
void testPlacementAreaAfterOutputLayoutChange();
void testFill_data();
void testFill();
void testStack();
@ -52,6 +54,7 @@ private Q_SLOTS:
void testActivate_data();
void testActivate();
void testUnmap();
void testScreenEdge_data();
void testScreenEdge();
};
@ -263,7 +266,7 @@ void LayerShellV1WindowTest::testLayer_data()
QTest::addColumn<int>("protocolLayer");
QTest::addColumn<Layer>("compositorLayer");
QTest::addRow("overlay") << int(Test::LayerShellV1::layer_overlay) << UnmanagedLayer;
QTest::addRow("overlay") << int(Test::LayerShellV1::layer_overlay) << OverlayLayer;
QTest::addRow("top") << int(Test::LayerShellV1::layer_top) << AboveLayer;
QTest::addRow("bottom") << int(Test::LayerShellV1::layer_bottom) << BelowLayer;
QTest::addRow("background") << int(Test::LayerShellV1::layer_background) << DesktopLayer;
@ -356,22 +359,42 @@ void LayerShellV1WindowTest::testPlacementArea_data()
QTest::addColumn<int>("anchor");
QTest::addColumn<QMargins>("margins");
QTest::addColumn<int>("exclusiveZone");
QTest::addColumn<int>("exclusiveEdge");
QTest::addColumn<QRectF>("placementArea");
QTest::addRow("left") << int(Test::LayerSurfaceV1::anchor_left) << QMargins(0, 0, 0, 0) << 300 << QRectF(300, 0, 980, 1024);
QTest::addRow("top") << int(Test::LayerSurfaceV1::anchor_top) << QMargins(0, 0, 0, 0) << 300 << QRectF(0, 300, 1280, 724);
QTest::addRow("right") << int(Test::LayerSurfaceV1::anchor_right) << QMargins(0, 0, 0, 0) << 300 << QRectF(0, 0, 980, 1024);
QTest::addRow("bottom") << int(Test::LayerSurfaceV1::anchor_bottom) << QMargins(0, 0, 0, 0) << 300 << QRectF(0, 0, 1280, 724);
QTest::addRow("left") << int(Test::LayerSurfaceV1::anchor_left) << QMargins(0, 0, 0, 0) << 300 << 0 << QRectF(300, 0, 980, 1024);
QTest::addRow("top") << int(Test::LayerSurfaceV1::anchor_top) << QMargins(0, 0, 0, 0) << 300 << 0 << QRectF(0, 300, 1280, 724);
QTest::addRow("right") << int(Test::LayerSurfaceV1::anchor_right) << QMargins(0, 0, 0, 0) << 300 << 0 << QRectF(0, 0, 980, 1024);
QTest::addRow("bottom") << int(Test::LayerSurfaceV1::anchor_bottom) << QMargins(0, 0, 0, 0) << 300 << 0 << QRectF(0, 0, 1280, 724);
QTest::addRow("left, negative margin") << int(Test::LayerSurfaceV1::anchor_left) << QMargins(-5, 0, 0, 0) << 300 << QRectF(295, 0, 985, 1024);
QTest::addRow("top, negative margin") << int(Test::LayerSurfaceV1::anchor_top) << QMargins(0, -5, 0, 0) << 300 << QRectF(0, 295, 1280, 729);
QTest::addRow("right, negative margin") << int(Test::LayerSurfaceV1::anchor_right) << QMargins(0, 0, -5, 0) << 300 << QRectF(0, 0, 985, 1024);
QTest::addRow("bottom, negative margin") << int(Test::LayerSurfaceV1::anchor_bottom) << QMargins(0, 0, 0, -5) << 300 << QRectF(0, 0, 1280, 729);
QTest::addRow("top | left") << int(Test::LayerSurfaceV1::anchor_top | Test::LayerSurfaceV1::anchor_left) << QMargins(0, 0, 0, 0) << 300 << 0 << QRectF(0, 0, 1280, 1024);
QTest::addRow("top | right") << int(Test::LayerSurfaceV1::anchor_top | Test::LayerSurfaceV1::anchor_right) << QMargins(0, 0, 0, 0) << 300 << 0 << QRectF(0, 0, 1280, 1024);
QTest::addRow("bottom | left") << int(Test::LayerSurfaceV1::anchor_bottom | Test::LayerSurfaceV1::anchor_left) << QMargins(0, 0, 0, 0) << 300 << 0 << QRectF(0, 0, 1280, 1024);
QTest::addRow("bottom | right") << int(Test::LayerSurfaceV1::anchor_bottom | Test::LayerSurfaceV1::anchor_right) << QMargins(0, 0, 0, 0) << 300 << 0 << QRectF(0, 0, 1280, 1024);
QTest::addRow("left, positive margin") << int(Test::LayerSurfaceV1::anchor_left) << QMargins(5, 0, 0, 0) << 300 << QRectF(305, 0, 975, 1024);
QTest::addRow("top, positive margin") << int(Test::LayerSurfaceV1::anchor_top) << QMargins(0, 5, 0, 0) << 300 << QRectF(0, 305, 1280, 719);
QTest::addRow("right, positive margin") << int(Test::LayerSurfaceV1::anchor_right) << QMargins(0, 0, 5, 0) << 300 << QRectF(0, 0, 975, 1024);
QTest::addRow("bottom, positive margin") << int(Test::LayerSurfaceV1::anchor_bottom) << QMargins(0, 0, 0, 5) << 300 << QRectF(0, 0, 1280, 719);
QTest::addRow("left, negative margin") << int(Test::LayerSurfaceV1::anchor_left) << QMargins(-5, 0, 0, 0) << 300 << 0 << QRectF(295, 0, 985, 1024);
QTest::addRow("top, negative margin") << int(Test::LayerSurfaceV1::anchor_top) << QMargins(0, -5, 0, 0) << 300 << 0 << QRectF(0, 295, 1280, 729);
QTest::addRow("right, negative margin") << int(Test::LayerSurfaceV1::anchor_right) << QMargins(0, 0, -5, 0) << 300 << 0 << QRectF(0, 0, 985, 1024);
QTest::addRow("bottom, negative margin") << int(Test::LayerSurfaceV1::anchor_bottom) << QMargins(0, 0, 0, -5) << 300 << 0 << QRectF(0, 0, 1280, 729);
QTest::addRow("left, positive margin") << int(Test::LayerSurfaceV1::anchor_left) << QMargins(5, 0, 0, 0) << 300 << 0 << QRectF(305, 0, 975, 1024);
QTest::addRow("top, positive margin") << int(Test::LayerSurfaceV1::anchor_top) << QMargins(0, 5, 0, 0) << 300 << 0 << QRectF(0, 305, 1280, 719);
QTest::addRow("right, positive margin") << int(Test::LayerSurfaceV1::anchor_right) << QMargins(0, 0, 5, 0) << 300 << 0 << QRectF(0, 0, 975, 1024);
QTest::addRow("bottom, positive margin") << int(Test::LayerSurfaceV1::anchor_bottom) << QMargins(0, 0, 0, 5) << 300 << 0 << QRectF(0, 0, 1280, 719);
QTest::addRow("left + left exclusive edge") << int(Test::LayerSurfaceV1::anchor_left) << QMargins(0, 0, 0, 0) << 300 << int(Test::LayerSurfaceV1::anchor_left) << QRectF(300, 0, 980, 1024);
QTest::addRow("top + top exclusive edge") << int(Test::LayerSurfaceV1::anchor_top) << QMargins(0, 0, 0, 0) << 300 << int(Test::LayerSurfaceV1::anchor_top) << QRectF(0, 300, 1280, 724);
QTest::addRow("right + right exclusive edge") << int(Test::LayerSurfaceV1::anchor_right) << QMargins(0, 0, 0, 0) << 300 << int(Test::LayerSurfaceV1::anchor_right) << QRectF(0, 0, 980, 1024);
QTest::addRow("bottom + bottom exclusive edge") << int(Test::LayerSurfaceV1::anchor_bottom) << QMargins(0, 0, 0, 0) << 300 << int(Test::LayerSurfaceV1::anchor_bottom) << QRectF(0, 0, 1280, 724);
QTest::addRow("top | left + top exclusive edge") << int(Test::LayerSurfaceV1::anchor_top | Test::LayerSurfaceV1::anchor_left) << QMargins(0, 0, 0, 0) << 300 << int(Test::LayerSurfaceV1::anchor_top) << QRectF(0, 300, 1280, 724);
QTest::addRow("top | left + left exclusive edge") << int(Test::LayerSurfaceV1::anchor_top | Test::LayerSurfaceV1::anchor_left) << QMargins(0, 0, 0, 0) << 300 << int(Test::LayerSurfaceV1::anchor_left) << QRectF(300, 0, 980, 1024);
QTest::addRow("top | right + top exclusive edge") << int(Test::LayerSurfaceV1::anchor_top | Test::LayerSurfaceV1::anchor_right) << QMargins(0, 0, 0, 0) << 300 << int(Test::LayerSurfaceV1::anchor_top) << QRectF(0, 300, 1280, 724);
QTest::addRow("top | right + right exclusive edge") << int(Test::LayerSurfaceV1::anchor_top | Test::LayerSurfaceV1::anchor_right) << QMargins(0, 0, 0, 0) << 300 << int(Test::LayerSurfaceV1::anchor_right) << QRectF(0, 0, 980, 1024);
QTest::addRow("bottom | left + bottom exclusive edge") << int(Test::LayerSurfaceV1::anchor_bottom | Test::LayerSurfaceV1::anchor_left) << QMargins(0, 0, 0, 0) << 300 << int(Test::LayerSurfaceV1::anchor_bottom) << QRectF(0, 0, 1280, 724);
QTest::addRow("bottom | left + left exclusive edge") << int(Test::LayerSurfaceV1::anchor_bottom | Test::LayerSurfaceV1::anchor_left) << QMargins(0, 0, 0, 0) << 300 << int(Test::LayerSurfaceV1::anchor_left) << QRectF(300, 0, 980, 1024);
QTest::addRow("bottom | right + bottom exclusive edge") << int(Test::LayerSurfaceV1::anchor_bottom | Test::LayerSurfaceV1::anchor_right) << QMargins(0, 0, 0, 0) << 300 << int(Test::LayerSurfaceV1::anchor_bottom) << QRectF(0, 0, 1280, 724);
QTest::addRow("bottom | right + right exclusive edge") << int(Test::LayerSurfaceV1::anchor_bottom | Test::LayerSurfaceV1::anchor_right) << QMargins(0, 0, 0, 0) << 300 << int(Test::LayerSurfaceV1::anchor_right) << QRectF(0, 0, 980, 1024);
}
void LayerShellV1WindowTest::testPlacementArea()
@ -384,9 +407,11 @@ void LayerShellV1WindowTest::testPlacementArea()
QFETCH(int, anchor);
QFETCH(QMargins, margins);
QFETCH(int, exclusiveZone);
QFETCH(int, exclusiveEdge);
shellSurface->set_anchor(anchor);
shellSurface->set_margin(margins.top(), margins.right(), margins.bottom(), margins.left());
shellSurface->set_exclusive_zone(exclusiveZone);
shellSurface->set_exclusive_edge(exclusiveEdge);
shellSurface->set_size(280, 124);
surface->commit(KWayland::Client::Surface::CommitFlag::None);
@ -408,6 +433,54 @@ void LayerShellV1WindowTest::testPlacementArea()
QVERIFY(Test::waitForWindowClosed(window));
}
void LayerShellV1WindowTest::testPlacementAreaAfterOutputLayoutChange()
{
// This test verifies that layer shell windows correctly react to output layout changes.
// The output where the layer surface should be placed.
Output *output = workspace()->activeOutput();
// Create a layer surface with an exclusive zone.
std::unique_ptr<KWayland::Client::Surface> surface(Test::createSurface());
std::unique_ptr<Test::LayerSurfaceV1> shellSurface(Test::createLayerSurfaceV1(surface.get(), QStringLiteral("dock"), Test::waylandOutput(output->name())));
shellSurface->set_layer(Test::LayerShellV1::layer_top);
shellSurface->set_anchor(Test::LayerSurfaceV1::anchor_bottom);
shellSurface->set_size(100, 50);
shellSurface->set_exclusive_edge(Test::LayerSurfaceV1::anchor_bottom);
shellSurface->set_exclusive_zone(50);
surface->commit(KWayland::Client::Surface::CommitFlag::None);
// Wait for the compositor to position the layer surface.
QSignalSpy configureRequestedSpy(shellSurface.get(), &Test::LayerSurfaceV1::configureRequested);
QVERIFY(configureRequestedSpy.wait());
shellSurface->ack_configure(configureRequestedSpy.last().at(0).toUInt());
Window *window = Test::renderAndWaitForShown(surface.get(), configureRequestedSpy.last().at(1).toSize(), Qt::red);
QVERIFY(window);
QCOMPARE(workspace()->clientArea(PlacementArea, window), output->geometry().adjusted(0, 0, 0, -50));
// Move the output 100px down.
OutputConfiguration config1;
{
auto changeSet = config1.changeSet(output);
changeSet->pos = output->geometry().topLeft() + QPoint(0, 100);
}
workspace()->applyOutputConfiguration(config1);
QCOMPARE(workspace()->clientArea(PlacementArea, window), output->geometry().adjusted(0, 0, 0, -50));
// Move the output back to its original position.
OutputConfiguration config2;
{
auto changeSet = config2.changeSet(output);
changeSet->pos = output->geometry().topLeft() - QPoint(0, 100);
}
workspace()->applyOutputConfiguration(config2);
QCOMPARE(workspace()->clientArea(PlacementArea, window), output->geometry().adjusted(0, 0, 0, -50));
// Destroy the window.
shellSurface.reset();
QVERIFY(Test::waitForWindowClosed(window));
}
void LayerShellV1WindowTest::testFill_data()
{
QTest::addColumn<int>("anchor");
@ -672,10 +745,18 @@ void LayerShellV1WindowTest::testUnmap()
QVERIFY(Test::waitForWindowClosed(window));
}
void LayerShellV1WindowTest::testScreenEdge_data()
{
QTest::addColumn<QMargins>("margins");
QTest::addRow("normal") << QMargins(0, 0, 0, 0);
QTest::addRow("with margin") << QMargins(0, 0, 0, 10);
}
void LayerShellV1WindowTest::testScreenEdge()
{
auto config = kwinApp()->config();
config->group(QStringLiteral("Windows")).writeEntry("ElectricBorderDelay", 150);
config->group(QStringLiteral("Windows")).writeEntry("ElectricBorderDelay", 75);
config->sync();
workspace()->slotReconfigure();
@ -685,9 +766,11 @@ void LayerShellV1WindowTest::testScreenEdge()
std::unique_ptr<Test::AutoHideScreenEdgeV1> screenEdge(Test::createAutoHideScreenEdgeV1(surface.get(), Test::ScreenEdgeManagerV1::border_bottom));
// Set the initial state of the layer surface.
QFETCH(QMargins, margins);
shellSurface->set_layer(Test::LayerShellV1::layer_top);
shellSurface->set_anchor(Test::LayerSurfaceV1::anchor_bottom);
shellSurface->set_size(100, 50);
shellSurface->set_margin(margins.top(), margins.right(), margins.bottom(), margins.left());
surface->commit(KWayland::Client::Surface::CommitFlag::None);
// Wait for the compositor to position the surface.

View File

@ -223,7 +223,7 @@ void LockScreenTest::testStackingOrder()
Window *window = windowAddedSpy.first().first().value<Window *>();
QVERIFY(window);
QVERIFY(window->isLockScreen());
QCOMPARE(window->layer(), UnmanagedLayer);
QCOMPARE(window->layer(), OverlayLayer);
UNLOCK;
}

View File

@ -266,14 +266,14 @@ void ModifierOnlyShortcutTest::testCapsLock()
// now capslock
Test::keyboardKeyPressed(KEY_CAPSLOCK, timestamp++);
Test::keyboardKeyReleased(KEY_CAPSLOCK, timestamp++);
QCOMPARE(input()->keyboardModifiers(), Qt::ShiftModifier);
QCOMPARE(input()->keyboardModifiers(), Qt::NoModifier);
QCOMPARE(triggeredSpy.count(), 1);
// currently caps lock is on
// shift still triggers
Test::keyboardKeyPressed(modifier, timestamp++);
Test::keyboardKeyReleased(modifier, timestamp++);
QCOMPARE(input()->keyboardModifiers(), Qt::ShiftModifier);
QCOMPARE(input()->keyboardModifiers(), Qt::NoModifier);
QCOMPARE(triggeredSpy.count(), 2);
// meta should also trigger
@ -284,7 +284,7 @@ void ModifierOnlyShortcutTest::testCapsLock()
group.sync();
workspace()->slotReconfigure();
Test::keyboardKeyPressed(KEY_LEFTMETA, timestamp++);
QCOMPARE(input()->keyboardModifiers(), Qt::ShiftModifier | Qt::MetaModifier);
QCOMPARE(input()->keyboardModifiers(), Qt::MetaModifier);
QCOMPARE(input()->keyboard()->xkb()->modifiersRelevantForGlobalShortcuts(), Qt::MetaModifier);
Test::keyboardKeyReleased(KEY_LEFTMETA, timestamp++);
QCOMPARE(triggeredSpy.count(), 3);

View File

@ -576,7 +576,7 @@ void MoveResizeWindowTest::testNetMove()
// use NETRootInfo to trigger a move request
NETRootInfo root(c.get(), NET::Properties());
root.moveResizeRequest(windowId, origGeo.center().x(), origGeo.center().y(), NET::Move);
root.moveResizeRequest(windowId, origGeo.center().x(), origGeo.center().y(), NET::Move, XCB_BUTTON_INDEX_1);
xcb_flush(c.get());
QVERIFY(interactiveMoveResizeStartedSpy.wait());
@ -591,7 +591,7 @@ void MoveResizeWindowTest::testNetMove()
QCOMPARE(interactiveMoveResizeSteppedSpy.first().last(), origGeo.translated(10, 10));
// let's cancel the move resize again through the net API
root.moveResizeRequest(windowId, window->frameGeometry().center().x(), window->frameGeometry().center().y(), NET::MoveResizeCancel);
root.moveResizeRequest(windowId, window->frameGeometry().center().x(), window->frameGeometry().center().y(), NET::MoveResizeCancel, XCB_BUTTON_INDEX_1);
xcb_flush(c.get());
QVERIFY(interactiveMoveResizeFinishedSpy.wait());

View File

@ -43,6 +43,7 @@ private Q_SLOTS:
void testFullScreenWindowRestoredAfterEnablingOutput();
void testWindowRestoredAfterChangingScale();
void testMaximizeStateRestoredAfterEnablingOutput();
void testInvalidGeometryRestoreAfterEnablingOutput();
void testWindowNotRestoredAfterMovingWindowAndEnablingOutput();
void testLaptopLidClosed();
@ -595,9 +596,101 @@ void OutputChangesTest::testMaximizeStateRestoredAfterEnablingOutput()
QCOMPARE(window->geometryRestore(), QRectF(1280 + 50, 100, 100, 50));
}
void OutputChangesTest::testInvalidGeometryRestoreAfterEnablingOutput()
{
// This test verifies that the geometry restore gets restore correctly, even if it's invalid
const auto outputs = kwinApp()->outputBackend()->outputs();
// Disable the right output
{
OutputConfiguration config;
auto changeSet = config.changeSet(outputs[1]);
changeSet->enabled = false;
workspace()->applyOutputConfiguration(config);
}
// Create a window.
std::unique_ptr<KWayland::Client::Surface> surface(Test::createSurface());
std::unique_ptr<Test::XdgToplevel> shellSurface(Test::createXdgToplevelSurface(surface.get(), Test::CreationSetup::CreateOnly));
shellSurface->set_maximized();
{
QSignalSpy surfaceConfigureRequestedSpy(shellSurface->xdgSurface(), &Test::XdgSurface::configureRequested);
shellSurface->xdgSurface()->surface()->commit(KWayland::Client::Surface::CommitFlag::None);
QVERIFY(surfaceConfigureRequestedSpy.wait());
shellSurface->xdgSurface()->ack_configure(surfaceConfigureRequestedSpy.last().first().toUInt());
}
auto window = Test::renderAndWaitForShown(surface.get(), QSize(1280, 1024), Qt::blue);
QVERIFY(window);
QCOMPARE(window->maximizeMode(), MaximizeFull);
const QRectF originalGeometry = window->moveResizeGeometry();
const QRectF originalGeometryRestore = window->geometryRestore();
// Enable the right output
{
OutputConfiguration config;
auto changeSet = config.changeSet(outputs[1]);
changeSet->enabled = true;
workspace()->applyOutputConfiguration(config);
}
// Move the window to the right monitor
window->sendToOutput(outputs[1]);
surface->commit(KWayland::Client::Surface::CommitFlag::None);
QCOMPARE(window->frameGeometry(), QRectF(1280, 0, 1280, 1024));
QCOMPARE(window->moveResizeGeometry(), QRectF(1280, 0, 1280, 1024));
QCOMPARE(window->output(), outputs[1]);
QCOMPARE(window->requestedMaximizeMode(), MaximizeFull);
QVERIFY(outputs[1]->geometry().contains(window->geometryRestore().topLeft().toPoint()));
QCOMPARE(window->geometryRestore().size(), QSizeF(0, 0));
const QRectF rightGeometryRestore = window->geometryRestore();
// Disable the right output
{
OutputConfiguration config;
auto changeSet = config.changeSet(outputs[1]);
changeSet->enabled = false;
workspace()->applyOutputConfiguration(config);
}
QSignalSpy toplevelConfigureRequestedSpy(shellSurface.get(), &Test::XdgToplevel::configureRequested);
QSignalSpy surfaceConfigureRequestedSpy(shellSurface->xdgSurface(), &Test::XdgSurface::configureRequested);
QSignalSpy frameGeometryChangedSpy(window, &Window::frameGeometryChanged);
// The window will be moved to its prior position on the left monitor, and still maximized
QCOMPARE(window->frameGeometry(), originalGeometry);
QCOMPARE(window->moveResizeGeometry(), originalGeometry);
QCOMPARE(window->output(), outputs[0]);
QCOMPARE(window->maximizeMode(), MaximizeFull);
QCOMPARE(window->requestedMaximizeMode(), MaximizeFull);
QVERIFY(outputs[0]->geometry().contains(window->geometryRestore().topLeft().toPoint()));
QCOMPARE(window->geometryRestore(), originalGeometryRestore);
// Enable the right output again
{
OutputConfiguration config;
auto changeSet = config.changeSet(outputs[1]);
changeSet->enabled = true;
workspace()->applyOutputConfiguration(config);
}
// The window will be moved back to the right monitor, maximized and the geometry restore will be updated
QVERIFY(surfaceConfigureRequestedSpy.wait());
QCOMPARE(toplevelConfigureRequestedSpy.last().at(0).value<QSize>(), outputs[1]->geometry().size());
shellSurface->xdgSurface()->ack_configure(surfaceConfigureRequestedSpy.last().at(0).value<quint32>());
Test::render(surface.get(), outputs[1]->geometry().size(), Qt::blue);
QCOMPARE(window->frameGeometry(), QRectF(1280, 0, 1280, 1024));
QCOMPARE(window->moveResizeGeometry(), QRectF(1280, 0, 1280, 1024));
QCOMPARE(window->output(), outputs[1]);
QCOMPARE(window->maximizeMode(), MaximizeFull);
QCOMPARE(window->requestedMaximizeMode(), MaximizeFull);
QCOMPARE(window->geometryRestore(), rightGeometryRestore);
}
void OutputChangesTest::testLaptopLidClosed()
{
QSKIP("Laptop lid handling is disabled until config writing is moved into KWin");
Test::setOutputConfig({
Test::OutputInfo{
.geometry = QRect(0, 0, 1280, 1024),

View File

@ -0,0 +1,146 @@
/*
SPDX-FileCopyrightText: 2020 Aleix Pol Gonzalez <aleixpol@kde.org>
SPDX-FileContributor: Jan Grulich <jgrulich@redhat.com>
SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
*/
#include "pipewirecore_p.h"
#include <QDebug>
#include <QSocketNotifier>
#include <QThread>
#include <QThreadStorage>
#include <mutex>
#include <spa/utils/result.h>
pw_core_events PipeWireCore::s_pwCoreEvents = {
.version = PW_VERSION_CORE_EVENTS,
.info = &PipeWireCore::onCoreInfo,
.done = nullptr,
.ping = nullptr,
.error = &PipeWireCore::onCoreError,
.remove_id = nullptr,
.bound_id = nullptr,
.add_mem = nullptr,
.remove_mem = nullptr,
};
PipeWireCore::PipeWireCore()
{
static std::once_flag pwInitOnce;
std::call_once(pwInitOnce, [] {
pw_init(nullptr, nullptr);
});
}
void PipeWireCore::onCoreError(void *data, uint32_t id, int seq, int res, const char *message)
{
Q_UNUSED(seq)
qWarning() << "PipeWire remote error: " << res << message;
if (id == PW_ID_CORE) {
PipeWireCore *pw = static_cast<PipeWireCore *>(data);
Q_EMIT pw->pipewireFailed(QString::fromUtf8(message));
if (res == -EPIPE) {
// Broken pipe, need reconnecting
if (pw->m_pwCore) {
Q_EMIT pw->pipeBroken();
spa_hook_remove(&pw->m_coreListener);
pw_core_disconnect(pw->m_pwCore);
pw->init_core();
}
}
}
}
void PipeWireCore::onCoreInfo(void *data, const struct pw_core_info *info)
{
PipeWireCore *pw = static_cast<PipeWireCore *>(data);
pw->m_serverVersion = QVersionNumber::fromString(QString::fromUtf8(info->version));
}
PipeWireCore::~PipeWireCore()
{
if (m_pwMainLoop) {
pw_loop_leave(m_pwMainLoop);
}
if (m_pwCore) {
pw_core_disconnect(m_pwCore);
}
if (m_pwContext) {
pw_context_destroy(m_pwContext);
}
if (m_pwMainLoop) {
pw_loop_destroy(m_pwMainLoop);
}
}
bool PipeWireCore::init(int fd)
{
m_pwMainLoop = pw_loop_new(nullptr);
pw_loop_enter(m_pwMainLoop);
QSocketNotifier *notifier = new QSocketNotifier(pw_loop_get_fd(m_pwMainLoop), QSocketNotifier::Read, this);
connect(notifier, &QSocketNotifier::activated, this, [this] {
int result = pw_loop_iterate(m_pwMainLoop, 0);
if (result < 0)
qWarning() << "pipewire_loop_iterate failed: " << spa_strerror(result);
});
m_pwContext = pw_context_new(m_pwMainLoop, nullptr, 0);
if (!m_pwContext) {
qWarning() << "Failed to create PipeWire context";
m_error = QStringLiteral("Failed to create PipeWire context");
return false;
}
m_fd = fd;
return init_core();
}
bool PipeWireCore::init_core()
{
if (m_fd > 0) {
m_pwCore = pw_context_connect_fd(m_pwContext, m_fd, nullptr, 0);
} else {
m_pwCore = pw_context_connect(m_pwContext, nullptr, 0);
}
if (!m_pwCore) {
m_error = QStringLiteral("Failed to connect to PipeWire");
qWarning() << "error:" << m_error << m_fd;
return false;
}
if (pw_loop_iterate(m_pwMainLoop, 0) < 0) {
qWarning() << "Failed to start main PipeWire loop";
m_error = QStringLiteral("Failed to start main PipeWire loop");
return false;
}
pw_core_add_listener(m_pwCore, &m_coreListener, &s_pwCoreEvents, this);
return true;
}
QSharedPointer<PipeWireCore> PipeWireCore::fetch(int fd)
{
static QThreadStorage<QHash<int, QWeakPointer<PipeWireCore>>> global;
QSharedPointer<PipeWireCore> ret = global.localData().value(fd).toStrongRef();
if (!ret) {
ret.reset(new PipeWireCore);
if (ret->init(fd)) {
global.localData().insert(fd, ret);
}
}
return ret;
}
QString PipeWireCore::error() const
{
return m_error;
}

View File

@ -0,0 +1,62 @@
/*
SPDX-FileCopyrightText: 2020 Aleix Pol Gonzalez <aleixpol@kde.org>
SPDX-FileContributor: Jan Grulich <jgrulich@redhat.com>
SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
*/
#pragma once
#include <QObject>
#include <QVersionNumber>
#include <pipewire/pipewire.h>
class PipeWireCore : public QObject
{
Q_OBJECT
public:
PipeWireCore();
static void onCoreError(void *data, uint32_t id, int seq, int res, const char *message);
static void onCoreInfo(void *data, const struct pw_core_info *info);
~PipeWireCore();
bool init(int fd);
bool init_core();
QString error() const;
QVersionNumber serverVersion() const
{
return m_serverVersion;
}
pw_loop *loop() const
{
return m_pwMainLoop;
}
pw_core *operator*() const
{
return m_pwCore;
};
static QSharedPointer<PipeWireCore> fetch(int fd);
private:
int m_fd = 0;
pw_core *m_pwCore = nullptr;
pw_context *m_pwContext = nullptr;
pw_loop *m_pwMainLoop = nullptr;
spa_hook m_coreListener;
QString m_error;
QVersionNumber m_serverVersion;
static pw_core_events s_pwCoreEvents;
Q_SIGNALS:
void pipewireFailed(const QString &message);
/**
* Clients should disconnect from the core and reconnect to it on receiving this signal
*/
void pipeBroken();
};

View File

@ -0,0 +1,643 @@
/*
SPDX-FileCopyrightText: 2018-2020 Red Hat Inc
SPDX-FileCopyrightText: 2020-2021 Aleix Pol Gonzalez <aleixpol@kde.org>
SPDX-FileContributor: Jan Grulich <jgrulich@redhat.com>
SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
*/
#include <epoxy/egl.h>
#include "pipewirecore_p.h"
#include "pipewiresourcestream.h"
#include <libdrm/drm_fourcc.h>
#include <spa/utils/result.h>
#include <sys/ioctl.h>
#include <sys/mman.h>
#include <unistd.h>
#include <QGuiApplication>
#include <QOpenGLTexture>
#include <QSocketNotifier>
#include <QThread>
#include <QVersionNumber>
#include <qpa/qplatformnativeinterface.h>
#undef Status
#if !PW_CHECK_VERSION(0, 3, 29)
#define SPA_POD_PROP_FLAG_MANDATORY (1u << 3)
#endif
#if !PW_CHECK_VERSION(0, 3, 33)
#define SPA_POD_PROP_FLAG_DONT_FIXATE (1u << 4)
#endif
#define CURSOR_BPP 4
#define CURSOR_META_SIZE(w, h) (sizeof(struct spa_meta_cursor) + sizeof(struct spa_meta_bitmap) + w * h * CURSOR_BPP)
pw_stream_events pwStreamEvents = {};
static QImage SpaBufferToQImage(const uchar *data, int width, int height, qsizetype bytesPerLine, spa_video_format format)
{
switch (format) {
case SPA_VIDEO_FORMAT_BGRx:
case SPA_VIDEO_FORMAT_BGRA:
case SPA_VIDEO_FORMAT_xBGR:
case SPA_VIDEO_FORMAT_ABGR: {
// This is needed because QImage does not support BGRA
// This is obviously a much slower path, it makes sense to avoid it as much as possible
return QImage(data, width, height, bytesPerLine, SpaToQImageFormat(format)).rgbSwapped();
}
case SPA_VIDEO_FORMAT_BGR:
case SPA_VIDEO_FORMAT_RGBx:
case SPA_VIDEO_FORMAT_RGB:
case SPA_VIDEO_FORMAT_RGBA:
default:
return QImage(data, width, height, bytesPerLine, SpaToQImageFormat(format));
}
}
QImage::Format SpaToQImageFormat(quint32 format)
{
switch (format) {
case SPA_VIDEO_FORMAT_BGRx:
case SPA_VIDEO_FORMAT_BGRA:
return QImage::Format_RGBA8888_Premultiplied; // Handled in SpaBufferToQImage
case SPA_VIDEO_FORMAT_ABGR:
case SPA_VIDEO_FORMAT_xBGR:
return QImage::Format_ARGB32; // Handled in SpaBufferToQImage
case SPA_VIDEO_FORMAT_BGR:
return QImage::Format_BGR888;
case SPA_VIDEO_FORMAT_RGBx:
return QImage::Format_RGBX8888;
case SPA_VIDEO_FORMAT_RGB:
return QImage::Format_RGB888;
case SPA_VIDEO_FORMAT_RGBA:
return QImage::Format_RGBA8888_Premultiplied;
default:
qWarning() << "cannot convert spa format to QImage" << format;
return QImage::Format_RGB32;
}
}
struct PipeWireSourceStreamPrivate
{
QSharedPointer<PipeWireCore> pwCore;
pw_stream *pwStream = nullptr;
spa_hook streamListener;
uint32_t pwNodeId = 0;
std::optional<std::chrono::nanoseconds> m_currentPresentationTimestamp;
QAtomicInt m_stopped = false;
pw_stream_state m_state = PW_STREAM_STATE_UNCONNECTED;
spa_video_info_raw videoFormat;
QString m_error;
bool m_allowDmaBuf = true;
bool m_usingDmaBuf = false;
QHash<spa_video_format, QList<uint64_t>> m_availableModifiers;
spa_source *m_renegotiateEvent = nullptr;
bool m_withDamage = false;
Fraction maxFramerate;
};
static const QVersionNumber pwClientVersion = QVersionNumber::fromString(QString::fromUtf8(pw_get_library_version()));
static const QVersionNumber kDmaBufMinVersion = {0, 3, 24};
static const QVersionNumber kDmaBufModifierMinVersion = {0, 3, 33};
static const QVersionNumber kDropSingleModifierMinVersion = {0, 3, 40};
uint32_t PipeWireSourceStream::spaVideoFormatToDrmFormat(spa_video_format spa_format)
{
switch (spa_format) {
case SPA_VIDEO_FORMAT_RGBA:
return DRM_FORMAT_ABGR8888;
case SPA_VIDEO_FORMAT_RGBx:
return DRM_FORMAT_XBGR8888;
case SPA_VIDEO_FORMAT_BGRA:
return DRM_FORMAT_ARGB8888;
case SPA_VIDEO_FORMAT_BGRx:
return DRM_FORMAT_XRGB8888;
case SPA_VIDEO_FORMAT_BGR:
return DRM_FORMAT_BGR888;
case SPA_VIDEO_FORMAT_RGB:
return DRM_FORMAT_RGB888;
case SPA_VIDEO_FORMAT_xBGR:
return DRM_FORMAT_RGBX8888;
case SPA_VIDEO_FORMAT_ABGR:
return DRM_FORMAT_RGBA8888;
default:
qWarning() << "cannot convert spa format to fourcc" << spa_format;
return DRM_FORMAT_INVALID;
}
}
static QHash<spa_video_format, QList<uint64_t>> queryDmaBufModifiers(EGLDisplay display, const QList<spa_video_format> &formats)
{
QHash<spa_video_format, QList<uint64_t>> ret;
ret.reserve(formats.size());
const bool hasEglImageDmaBufImportExt = epoxy_has_egl_extension(display, "EGL_EXT_image_dma_buf_import");
static auto eglQueryDmaBufModifiersEXT = (PFNEGLQUERYDMABUFMODIFIERSEXTPROC)eglGetProcAddress("eglQueryDmaBufModifiersEXT");
static auto eglQueryDmaBufFormatsEXT = (PFNEGLQUERYDMABUFFORMATSEXTPROC)eglGetProcAddress("eglQueryDmaBufFormatsEXT");
EGLint count = 0;
EGLBoolean successFormats = eglQueryDmaBufFormatsEXT(display, 0, nullptr, &count);
QList<uint32_t> drmFormats(count);
successFormats &= eglQueryDmaBufFormatsEXT(display, count, reinterpret_cast<EGLint *>(drmFormats.data()), &count);
if (!successFormats)
qWarning() << "Failed to query DMA-BUF formats.";
const QList<uint64_t> mods = hasEglImageDmaBufImportExt ? QList<uint64_t>{DRM_FORMAT_MOD_INVALID} : QList<uint64_t>{};
if (!eglQueryDmaBufFormatsEXT || !eglQueryDmaBufModifiersEXT || !hasEglImageDmaBufImportExt || !successFormats) {
for (spa_video_format format : formats) {
ret[format] = mods;
}
return ret;
}
for (spa_video_format format : formats) {
uint32_t drm_format = PipeWireSourceStream::spaVideoFormatToDrmFormat(format);
if (drm_format == DRM_FORMAT_INVALID) {
qDebug() << "Failed to find matching DRM format." << format;
break;
}
if (std::find(drmFormats.begin(), drmFormats.end(), drm_format) == drmFormats.end()) {
qDebug() << "Format " << drm_format << " not supported for modifiers.";
ret[format] = mods;
break;
}
successFormats = eglQueryDmaBufModifiersEXT(display, drm_format, 0, nullptr, nullptr, &count);
if (!successFormats) {
qWarning() << "Failed to query DMA-BUF modifier count.";
ret[format] = mods;
break;
}
QList<uint64_t> modifiers(count);
if (count > 0) {
if (!eglQueryDmaBufModifiersEXT(display, drm_format, count, modifiers.data(), nullptr, &count)) {
qWarning() << "Failed to query DMA-BUF modifiers.";
}
}
// Support modifier-less buffers
modifiers.push_back(DRM_FORMAT_MOD_INVALID);
ret[format] = modifiers;
}
return ret;
}
void PipeWireSourceStream::onStreamStateChanged(void *data, pw_stream_state old, pw_stream_state state, const char *error_message)
{
PipeWireSourceStream *pw = static_cast<PipeWireSourceStream *>(data);
qDebug() << "state changed" << pw_stream_state_as_string(old) << "->" << pw_stream_state_as_string(state) << error_message;
pw->d->m_state = state;
Q_EMIT pw->stateChanged(state, old);
switch (state) {
case PW_STREAM_STATE_ERROR:
qWarning() << "Stream error: " << error_message;
break;
case PW_STREAM_STATE_PAUSED:
Q_EMIT pw->streamReady();
break;
case PW_STREAM_STATE_STREAMING:
Q_EMIT pw->startStreaming();
break;
case PW_STREAM_STATE_CONNECTING:
break;
case PW_STREAM_STATE_UNCONNECTED:
if (!pw->d->m_stopped) {
Q_EMIT pw->stopStreaming();
}
break;
}
}
void PipeWireSourceStream::onRenegotiate(void *data, uint64_t)
{
PipeWireSourceStream *pw = static_cast<PipeWireSourceStream *>(data);
uint8_t buffer[4096];
spa_pod_builder podBuilder = SPA_POD_BUILDER_INIT(buffer, sizeof(buffer));
auto params = pw->createFormatsParams(podBuilder);
pw_stream_update_params(pw->d->pwStream, params.data(), params.size());
}
void PipeWireSourceStream::renegotiateModifierFailed(spa_video_format format, quint64 modifier)
{
if (d->pwCore->serverVersion() >= kDropSingleModifierMinVersion) {
const int removed = d->m_availableModifiers[format].removeAll(modifier);
if (removed == 0) {
d->m_allowDmaBuf = false;
}
} else {
d->m_allowDmaBuf = false;
}
qDebug() << "renegotiating, modifier didn't work" << format << modifier << "now only offering" << d->m_availableModifiers[format].count();
pw_loop_signal_event(d->pwCore->loop(), d->m_renegotiateEvent);
}
static spa_pod *
buildFormat(spa_pod_builder *builder, spa_video_format format, const QList<uint64_t> &modifiers, bool withDontFixate, const Fraction &requestedMaxFramerate)
{
spa_pod_frame f[2];
const spa_rectangle pw_min_screen_bounds{1, 1};
const spa_rectangle pw_max_screen_bounds{UINT32_MAX, UINT32_MAX};
spa_pod_builder_push_object(builder, &f[0], SPA_TYPE_OBJECT_Format, SPA_PARAM_EnumFormat);
spa_pod_builder_add(builder, SPA_FORMAT_mediaType, SPA_POD_Id(SPA_MEDIA_TYPE_video), 0);
spa_pod_builder_add(builder, SPA_FORMAT_mediaSubtype, SPA_POD_Id(SPA_MEDIA_SUBTYPE_raw), 0);
spa_pod_builder_add(builder, SPA_FORMAT_VIDEO_format, SPA_POD_Id(format), 0);
spa_pod_builder_add(builder, SPA_FORMAT_VIDEO_size, SPA_POD_CHOICE_RANGE_Rectangle(&pw_min_screen_bounds, &pw_min_screen_bounds, &pw_max_screen_bounds), 0);
if (requestedMaxFramerate) {
auto defFramerate = SPA_FRACTION(0, 1);
auto minFramerate = SPA_FRACTION(1, 1);
auto maxFramerate = SPA_FRACTION(requestedMaxFramerate.numerator, requestedMaxFramerate.denominator);
spa_pod_builder_add(builder, SPA_FORMAT_VIDEO_framerate, SPA_POD_Fraction(&defFramerate), 0);
spa_pod_builder_add(builder, SPA_FORMAT_VIDEO_maxFramerate, SPA_POD_CHOICE_RANGE_Fraction(&maxFramerate, &minFramerate, &maxFramerate), 0);
}
if (modifiers.size() == 1 && modifiers[0] == DRM_FORMAT_MOD_INVALID) {
// we only support implicit modifiers, use shortpath to skip fixation phase
spa_pod_builder_prop(builder, SPA_FORMAT_VIDEO_modifier, SPA_POD_PROP_FLAG_MANDATORY);
spa_pod_builder_long(builder, modifiers[0]);
} else if (!modifiers.isEmpty()) {
// SPA_POD_PROP_FLAG_DONT_FIXATE can be used with PipeWire >= 0.3.33
if (withDontFixate) {
spa_pod_builder_prop(builder, SPA_FORMAT_VIDEO_modifier, SPA_POD_PROP_FLAG_MANDATORY | SPA_POD_PROP_FLAG_DONT_FIXATE);
} else {
spa_pod_builder_prop(builder, SPA_FORMAT_VIDEO_modifier, SPA_POD_PROP_FLAG_MANDATORY);
}
spa_pod_builder_push_choice(builder, &f[1], SPA_CHOICE_Enum, 0);
// mofifiers from the array
for (auto it = modifiers.begin(); it != modifiers.end(); it++) {
spa_pod_builder_long(builder, *it);
if (it == modifiers.begin()) {
spa_pod_builder_long(builder, *it);
}
}
spa_pod_builder_pop(builder, &f[1]);
}
return static_cast<spa_pod *>(spa_pod_builder_pop(builder, &f[0]));
}
static const int videoDamageRegionCount = 16;
void PipeWireSourceStream::onStreamParamChanged(void *data, uint32_t id, const struct spa_pod *format)
{
if (!format || id != SPA_PARAM_Format) {
return;
}
PipeWireSourceStream *pw = static_cast<PipeWireSourceStream *>(data);
spa_format_video_raw_parse(format, &pw->d->videoFormat);
uint8_t paramsBuffer[1024];
spa_pod_builder pod_builder = SPA_POD_BUILDER_INIT(paramsBuffer, sizeof(paramsBuffer));
// When SPA_FORMAT_VIDEO_modifier is present we can use DMA-BUFs as
// the server announces support for it.
// See https://github.com/PipeWire/pipewire/blob/master/doc/dma-buf.dox
pw->d->m_usingDmaBuf = pw->d->m_allowDmaBuf && spa_pod_find_prop(format, nullptr, SPA_FORMAT_VIDEO_modifier);
Q_ASSERT(pw->d->m_allowDmaBuf || !pw->d->m_usingDmaBuf);
const auto bufferTypes =
pw->d->m_usingDmaBuf ? (1 << SPA_DATA_DmaBuf) | (1 << SPA_DATA_MemFd) | (1 << SPA_DATA_MemPtr) : (1 << SPA_DATA_MemFd) | (1 << SPA_DATA_MemPtr);
QVarLengthArray<const spa_pod *> params = {
(spa_pod *)spa_pod_builder_add_object(&pod_builder,
SPA_TYPE_OBJECT_ParamBuffers,
SPA_PARAM_Buffers,
SPA_PARAM_BUFFERS_buffers,
SPA_POD_CHOICE_RANGE_Int(16, 2, 16),
SPA_PARAM_BUFFERS_align,
SPA_POD_Int(16),
SPA_PARAM_BUFFERS_dataType,
SPA_POD_CHOICE_FLAGS_Int(bufferTypes)),
(spa_pod *)spa_pod_builder_add_object(&pod_builder,
SPA_TYPE_OBJECT_ParamMeta,
SPA_PARAM_Meta,
SPA_PARAM_META_type,
SPA_POD_Id(SPA_META_Header),
SPA_PARAM_META_size,
SPA_POD_Int(sizeof(struct spa_meta_header))),
(spa_pod *)spa_pod_builder_add_object(&pod_builder,
SPA_TYPE_OBJECT_ParamMeta,
SPA_PARAM_Meta,
SPA_PARAM_META_type,
SPA_POD_Id(SPA_META_Cursor),
SPA_PARAM_META_size,
SPA_POD_CHOICE_RANGE_Int(CURSOR_META_SIZE(64, 64), CURSOR_META_SIZE(1, 1), CURSOR_META_SIZE(1024, 1024))),
};
if (pw->d->m_withDamage) {
params.append((spa_pod *)spa_pod_builder_add_object(&pod_builder,
SPA_TYPE_OBJECT_ParamMeta,
SPA_PARAM_Meta,
SPA_PARAM_META_type,
SPA_POD_Id(SPA_META_VideoDamage),
SPA_PARAM_META_size,
SPA_POD_CHOICE_RANGE_Int(sizeof(struct spa_meta_region) * videoDamageRegionCount,
sizeof(struct spa_meta_region) * 1,
sizeof(struct spa_meta_region) * videoDamageRegionCount)));
}
pw_stream_update_params(pw->d->pwStream, params.data(), params.count());
Q_EMIT pw->streamParametersChanged();
}
static void onProcess(void *data)
{
PipeWireSourceStream *stream = static_cast<PipeWireSourceStream *>(data);
stream->process();
}
QSize PipeWireSourceStream::size() const
{
return QSize(d->videoFormat.size.width, d->videoFormat.size.height);
}
pw_stream_state PipeWireSourceStream::state() const
{
return d->m_state;
}
std::optional<std::chrono::nanoseconds> PipeWireSourceStream::currentPresentationTimestamp() const
{
return d->m_currentPresentationTimestamp;
}
QString PipeWireSourceStream::error() const
{
return d->m_error;
}
PipeWireSourceStream::PipeWireSourceStream(QObject *parent)
: QObject(parent)
, d(new PipeWireSourceStreamPrivate)
{
pwStreamEvents.version = PW_VERSION_STREAM_EVENTS;
pwStreamEvents.process = &onProcess;
pwStreamEvents.state_changed = &PipeWireSourceStream::onStreamStateChanged;
pwStreamEvents.param_changed = &PipeWireSourceStream::onStreamParamChanged;
}
PipeWireSourceStream::~PipeWireSourceStream()
{
d->m_stopped = true;
if (d->m_renegotiateEvent) {
pw_loop_destroy_source(d->pwCore->loop(), d->m_renegotiateEvent);
}
if (d->pwStream) {
pw_stream_destroy(d->pwStream);
}
}
Fraction PipeWireSourceStream::framerate() const
{
if (d->pwStream) {
return {d->videoFormat.max_framerate.num, d->videoFormat.max_framerate.denom};
}
return {0, 1};
}
void PipeWireSourceStream::setMaxFramerate(const Fraction &framerate)
{
d->maxFramerate = framerate;
if (d->pwStream) {
pw_loop_signal_event(d->pwCore->loop(), d->m_renegotiateEvent);
}
}
uint PipeWireSourceStream::nodeId()
{
return d->pwNodeId;
}
QList<const spa_pod *> PipeWireSourceStream::createFormatsParams(spa_pod_builder podBuilder)
{
const auto pwServerVersion = d->pwCore->serverVersion();
const QList<spa_video_format> formats = {
SPA_VIDEO_FORMAT_RGBx,
SPA_VIDEO_FORMAT_RGBA,
SPA_VIDEO_FORMAT_BGRx,
SPA_VIDEO_FORMAT_BGRA,
SPA_VIDEO_FORMAT_RGB,
SPA_VIDEO_FORMAT_BGR,
SPA_VIDEO_FORMAT_xBGR,
SPA_VIDEO_FORMAT_ABGR,
};
QList<const spa_pod *> params;
params.reserve(formats.size() * 2);
const EGLDisplay display = static_cast<EGLDisplay>(QGuiApplication::platformNativeInterface()->nativeResourceForIntegration("egldisplay"));
d->m_allowDmaBuf = d->m_allowDmaBuf && (pwServerVersion.isNull() || (pwClientVersion >= kDmaBufMinVersion && pwServerVersion >= kDmaBufMinVersion));
const bool withDontFixate = d->m_allowDmaBuf && (pwServerVersion.isNull() || (pwClientVersion >= kDmaBufModifierMinVersion && pwServerVersion >= kDmaBufModifierMinVersion));
if (d->m_availableModifiers.isEmpty()) {
d->m_availableModifiers = queryDmaBufModifiers(display, formats);
}
for (auto it = d->m_availableModifiers.constBegin(), itEnd = d->m_availableModifiers.constEnd(); it != itEnd; ++it) {
if (d->m_allowDmaBuf && !it->isEmpty()) {
params += buildFormat(&podBuilder, it.key(), it.value(), withDontFixate, d->maxFramerate);
}
params += buildFormat(&podBuilder, it.key(), {}, withDontFixate, d->maxFramerate);
}
return params;
}
bool PipeWireSourceStream::createStream(uint nodeid, int fd)
{
d->m_availableModifiers.clear();
d->pwCore = PipeWireCore::fetch(fd);
if (!d->pwCore->error().isEmpty()) {
qDebug() << "received error while creating the stream" << d->pwCore->error();
d->m_error = d->pwCore->error();
return false;
}
connect(d->pwCore.data(), &PipeWireCore::pipewireFailed, this, &PipeWireSourceStream::coreFailed);
if (objectName().isEmpty()) {
setObjectName(QStringLiteral("plasma-screencast-%1").arg(nodeid));
}
const auto pwServerVersion = d->pwCore->serverVersion();
d->pwStream = pw_stream_new(**d->pwCore, objectName().toUtf8().constData(), nullptr);
d->pwNodeId = nodeid;
pw_stream_add_listener(d->pwStream, &d->streamListener, &pwStreamEvents, this);
d->m_renegotiateEvent = pw_loop_add_event(d->pwCore->loop(), onRenegotiate, this);
uint8_t buffer[4096];
spa_pod_builder podBuilder = SPA_POD_BUILDER_INIT(buffer, sizeof(buffer));
auto params = createFormatsParams(podBuilder);
pw_stream_flags s = (pw_stream_flags)(PW_STREAM_FLAG_DONT_RECONNECT | PW_STREAM_FLAG_AUTOCONNECT);
if (pw_stream_connect(d->pwStream, PW_DIRECTION_INPUT, d->pwNodeId, s, params.data(), params.size()) != 0) {
qWarning() << "Could not connect to stream";
pw_stream_destroy(d->pwStream);
d->pwStream = nullptr;
return false;
}
qDebug() << "created successfully" << nodeid;
return true;
}
void PipeWireSourceStream::handleFrame(struct pw_buffer *buffer)
{
spa_buffer *spaBuffer = buffer->buffer;
PipeWireFrame frame;
frame.format = d->videoFormat.format;
struct spa_meta_header *h = (struct spa_meta_header *)spa_buffer_find_meta_data(spaBuffer, SPA_META_Header, sizeof(*h));
if (h) {
d->m_currentPresentationTimestamp = std::chrono::nanoseconds(h->pts);
frame.presentationTimestamp = std::chrono::nanoseconds(h->pts);
frame.sequential = h->seq;
} else {
using namespace std::chrono;
auto now = system_clock::now();
d->m_currentPresentationTimestamp = time_point_cast<nanoseconds>(now).time_since_epoch();
frame.presentationTimestamp = d->m_currentPresentationTimestamp;
}
if (spa_meta *vd = spa_buffer_find_meta(spaBuffer, SPA_META_VideoDamage)) {
frame.damage = QRegion();
spa_meta_region *mr;
spa_meta_for_each(mr, vd)
{
*frame.damage += QRect(mr->region.position.x, mr->region.position.y, mr->region.size.width, mr->region.size.height);
}
}
{ // process cursor
struct spa_meta_cursor *cursor = static_cast<struct spa_meta_cursor *>(spa_buffer_find_meta_data(spaBuffer, SPA_META_Cursor, sizeof(*cursor)));
if (cursor && spa_meta_cursor_is_valid(cursor)) {
struct spa_meta_bitmap *bitmap = nullptr;
if (cursor->bitmap_offset)
bitmap = SPA_MEMBER(cursor, cursor->bitmap_offset, struct spa_meta_bitmap);
QImage cursorTexture;
if (bitmap && bitmap->size.width > 0 && bitmap->size.height > 0) {
const uint8_t *bitmap_data = SPA_MEMBER(bitmap, bitmap->offset, uint8_t);
cursorTexture =
SpaBufferToQImage(bitmap_data, bitmap->size.width, bitmap->size.height, bitmap->stride, spa_video_format(bitmap->format));
}
frame.cursor = {{cursor->position.x, cursor->position.y}, {cursor->hotspot.x, cursor->hotspot.y}, cursorTexture};
}
}
if (spaBuffer->datas->chunk->size == 0 || spaBuffer->datas->chunk->flags == SPA_CHUNK_FLAG_CORRUPTED) {
// do not get a frame
qDebug() << "skipping empty buffer" << spaBuffer->datas->chunk->size << spaBuffer->datas->chunk->flags;
} else if (spaBuffer->datas->type == SPA_DATA_MemFd) {
uint8_t *map =
static_cast<uint8_t *>(mmap(nullptr, spaBuffer->datas->maxsize + spaBuffer->datas->mapoffset, PROT_READ, MAP_PRIVATE, spaBuffer->datas->fd, 0));
if (map == MAP_FAILED) {
qWarning() << "Failed to mmap the memory: " << strerror(errno);
return;
}
QImage img =
SpaBufferToQImage(map, d->videoFormat.size.width, d->videoFormat.size.height, spaBuffer->datas->chunk->stride, d->videoFormat.format);
frame.image = img.copy();
munmap(map, spaBuffer->datas->maxsize + spaBuffer->datas->mapoffset);
} else if (spaBuffer->datas->type == SPA_DATA_DmaBuf) {
DmaBufAttributes attribs;
attribs.planes.reserve(spaBuffer->n_datas);
attribs.format = spaVideoFormatToDrmFormat(d->videoFormat.format);
attribs.modifier = d->videoFormat.modifier;
attribs.width = d->videoFormat.size.width;
attribs.height = d->videoFormat.size.height;
for (uint i = 0; i < spaBuffer->n_datas; ++i) {
const auto &data = spaBuffer->datas[i];
DmaBufPlane plane;
plane.fd = data.fd;
plane.stride = data.chunk->stride;
plane.offset = data.chunk->offset;
attribs.planes += plane;
}
Q_ASSERT(!attribs.planes.isEmpty());
frame.dmabuf = attribs;
} else if (spaBuffer->datas->type == SPA_DATA_MemPtr) {
frame.image = SpaBufferToQImage(static_cast<uint8_t *>(spaBuffer->datas->data),
d->videoFormat.size.width,
d->videoFormat.size.height,
spaBuffer->datas->chunk->stride,
d->videoFormat.format);
} else {
if (spaBuffer->datas->type == SPA_ID_INVALID)
qWarning() << "invalid buffer type";
else
qWarning() << "unsupported buffer type" << spaBuffer->datas->type;
QImage errorImage(200, 200, QImage::Format_ARGB32_Premultiplied);
errorImage.fill(Qt::red);
frame.image = errorImage;
}
Q_EMIT frameReceived(frame);
}
void PipeWireSourceStream::coreFailed(const QString &errorMessage)
{
qDebug() << "received error message" << errorMessage;
d->m_error = errorMessage;
Q_EMIT stopStreaming();
}
void PipeWireSourceStream::process()
{
pw_buffer *buf = pw_stream_dequeue_buffer(d->pwStream);
if (!buf) {
qDebug() << "out of buffers";
return;
}
handleFrame(buf);
pw_stream_queue_buffer(d->pwStream, buf);
}
void PipeWireSourceStream::setActive(bool active)
{
Q_ASSERT(d->pwStream);
pw_stream_set_active(d->pwStream, active);
}
void PipeWireSourceStream::setDamageEnabled(bool withDamage)
{
d->m_withDamage = withDamage;
}
bool PipeWireSourceStream::usingDmaBuf() const
{
return d->m_usingDmaBuf;
}
bool PipeWireSourceStream::allowDmaBuf() const
{
return d->m_allowDmaBuf;
}
void PipeWireSourceStream::setAllowDmaBuf(bool allowed)
{
d->m_allowDmaBuf = allowed;
}
#include "moc_pipewiresourcestream.cpp"

View File

@ -0,0 +1,142 @@
/*
SPDX-FileCopyrightText: 2018-2020 Red Hat Inc
SPDX-FileCopyrightText: 2020-2021 Aleix Pol Gonzalez <aleixpol@kde.org>
SPDX-FileContributor: Jan Grulich <jgrulich@redhat.com>
SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
*/
#pragma once
#include <QHash>
#include <QImage>
#include <QObject>
#include <QPoint>
#include <QSharedPointer>
#include <QSize>
#include <optional>
#include <pipewire/pipewire.h>
#include <spa/param/format-utils.h>
#include <spa/param/props.h>
#include <spa/param/video/format-utils.h>
#undef Status
class PipeWireCore;
struct gbm_device;
typedef void *EGLDisplay;
struct DmaBufPlane
{
int fd; ///< The dmabuf file descriptor
uint32_t offset; ///< The offset from the start of buffer
uint32_t stride; ///< The distance from the start of a row to the next row in bytes
};
struct DmaBufAttributes
{
int width = 0;
int height = 0;
uint32_t format = 0;
uint64_t modifier = 0; ///< The layout modifier
QList<DmaBufPlane> planes;
};
struct PipeWireCursor
{
QPoint position;
QPoint hotspot;
QImage texture;
bool operator!=(const PipeWireCursor &other) const
{
return !operator==(other);
};
bool operator==(const PipeWireCursor &other) const
{
return position == other.position && hotspot == other.hotspot && texture == other.texture;
}
};
struct PipeWireFrame
{
spa_video_format format;
std::optional<int> sequential;
std::optional<std::chrono::nanoseconds> presentationTimestamp;
std::optional<DmaBufAttributes> dmabuf;
std::optional<QImage> image;
std::optional<QRegion> damage;
std::optional<PipeWireCursor> cursor;
};
struct Fraction
{
bool operator==(const Fraction &other) const
{
return numerator == other.numerator && denominator == other.denominator;
}
explicit operator bool() const
{
return isValid();
}
bool isValid() const
{
return denominator > 0;
}
quint32 numerator = 0;
quint32 denominator = 0;
};
QImage::Format SpaToQImageFormat(quint32 /*spa_video_format*/ format);
struct PipeWireSourceStreamPrivate;
class PipeWireSourceStream : public QObject
{
Q_OBJECT
public:
explicit PipeWireSourceStream(QObject *parent = nullptr);
~PipeWireSourceStream();
Fraction framerate() const;
void setMaxFramerate(const Fraction &framerate);
uint nodeId();
QString error() const;
QSize size() const;
pw_stream_state state() const;
bool createStream(uint nodeid, int fd);
void setActive(bool active);
void setDamageEnabled(bool withDamage);
void handleFrame(struct pw_buffer *buffer);
void process();
void renegotiateModifierFailed(spa_video_format format, quint64 modifier);
std::optional<std::chrono::nanoseconds> currentPresentationTimestamp() const;
static uint32_t spaVideoFormatToDrmFormat(spa_video_format spa_format);
bool usingDmaBuf() const;
bool allowDmaBuf() const;
void setAllowDmaBuf(bool allowed);
Q_SIGNALS:
void streamReady();
void startStreaming();
void stopStreaming();
void streamParametersChanged();
void frameReceived(const PipeWireFrame &frame);
void stateChanged(pw_stream_state state, pw_stream_state oldState);
private:
static void onStreamParamChanged(void *data, uint32_t id, const struct spa_pod *format);
static void onStreamStateChanged(void *data, pw_stream_state old, pw_stream_state state, const char *error_message);
static void onRenegotiate(void *data, uint64_t);
QList<const spa_pod *> createFormatsParams(spa_pod_builder podBuilder);
void coreFailed(const QString &errorMessage);
QScopedPointer<PipeWireSourceStreamPrivate> d;
};

View File

@ -1170,7 +1170,7 @@ void PointerInputTest::testCursorShapeV1()
// move cursor somewhere the new window won't open
input()->pointer()->warp(QPointF(800, 800));
QCOMPARE(currentCursorShape(), QByteArray("left_ptr"));
QCOMPARE(currentCursorShape(), QByteArrayLiteral("default"));
// create a window
std::unique_ptr<KWayland::Client::Surface> surface(Test::createSurface());
@ -1191,10 +1191,10 @@ void PointerInputTest::testCursorShapeV1()
// cursor shape won't be changed if the window has no pointer focus
input()->pointer()->warp(QPointF(800, 800));
QCOMPARE(currentCursorShape(), QByteArray("left_ptr"));
QCOMPARE(currentCursorShape(), QByteArrayLiteral("default"));
cursorShapeDevice->set_shape(enteredSpy.last().at(0).value<quint32>(), Test::CursorShapeDeviceV1::shape_grab);
QVERIFY(Test::waylandSync());
QCOMPARE(currentCursorShape(), QByteArray("left_ptr"));
QCOMPARE(currentCursorShape(), QByteArrayLiteral("default"));
}
class HelperEffect : public Effect
@ -1245,19 +1245,19 @@ void PointerInputTest::testEffectOverrideCursorImage()
// now create an effect and set an override cursor
std::unique_ptr<HelperEffect> effect(new HelperEffect);
effects->startMouseInterception(effect.get(), Qt::SizeAllCursor);
QCOMPARE(currentCursorShape(), QByteArray("size_all"));
QCOMPARE(currentCursorShape(), QByteArrayLiteral("all-scroll"));
// let's change to arrow cursor, this should be our fallback
effects->defineCursor(Qt::ArrowCursor);
QCOMPARE(currentCursorShape(), QByteArray("left_ptr"));
QCOMPARE(currentCursorShape(), QByteArrayLiteral("default"));
// back to size all
effects->defineCursor(Qt::SizeAllCursor);
QCOMPARE(currentCursorShape(), QByteArray("size_all"));
QCOMPARE(currentCursorShape(), QByteArrayLiteral("all-scroll"));
// move cursor outside the window area
input()->pointer()->warp(QPointF(800, 800));
QCOMPARE(currentCursorShape(), QByteArray("size_all"));
QCOMPARE(currentCursorShape(), QByteArrayLiteral("all-scroll"));
// move cursor to area of window
input()->pointer()->warp(window->frameGeometry().center());
@ -1270,7 +1270,7 @@ void PointerInputTest::testEffectOverrideCursorImage()
QVERIFY(enteredSpy.wait());
cursorShapeDevice->set_shape(enteredSpy.last().at(0).value<quint32>(), Test::CursorShapeDeviceV1::shape_crosshair);
QVERIFY(cursorChanged.wait());
QCOMPARE(currentCursorShape(), QByteArray("cross"));
QCOMPARE(currentCursorShape(), QByteArrayLiteral("crosshair"));
}
void PointerInputTest::testPopup()

View File

@ -389,6 +389,7 @@ void QuickTilingTest::testQuickTilingPointerMove()
// we have to receive a configure event when the window becomes active
QSignalSpy toplevelConfigureRequestedSpy(shellSurface.get(), &Test::XdgToplevel::configureRequested);
QSignalSpy surfaceConfigureRequestedSpy(shellSurface->xdgSurface(), &Test::XdgSurface::configureRequested);
QSignalSpy frameGeometryChangedSpy(window, &Window::frameGeometryChanged);
QVERIFY(surfaceConfigureRequestedSpy.wait());
QCOMPARE(surfaceConfigureRequestedSpy.count(), 1);
@ -412,6 +413,12 @@ void QuickTilingTest::testQuickTilingPointerMove()
QCOMPARE(surfaceConfigureRequestedSpy.count(), 2);
QCOMPARE(toplevelConfigureRequestedSpy.last().at(0).toSize(), tileSize);
// attach a new image
shellSurface->xdgSurface()->ack_configure(surfaceConfigureRequestedSpy.last().at(0).value<quint32>());
Test::render(surface.get(), tileSize, Qt::red);
QVERIFY(frameGeometryChangedSpy.wait());
QCOMPARE(window->frameGeometry().size(), tileSize);
// verify that geometry restore is correct after user untiles the window, but changes
// their mind and tiles the window again while still holding left button
workspace()->performWindowOperation(window, Options::UnrestrictedMoveOp);
@ -425,6 +432,12 @@ void QuickTilingTest::testQuickTilingPointerMove()
QCOMPARE(surfaceConfigureRequestedSpy.count(), 3);
QCOMPARE(toplevelConfigureRequestedSpy.last().at(0).toSize(), QSize(100, 50));
// attach a new image
shellSurface->xdgSurface()->ack_configure(surfaceConfigureRequestedSpy.last().at(0).value<quint32>());
Test::render(surface.get(), QSize(100, 50), Qt::red);
QVERIFY(frameGeometryChangedSpy.wait());
QCOMPARE(window->frameGeometry().size(), QSize(100, 50));
Test::pointerMotion(pointerPos, timestamp++); // tile the window again
Test::pointerButtonReleased(BTN_LEFT, timestamp++);
QCOMPARE(quickTileChangedSpy.count(), 3);

View File

@ -10,6 +10,7 @@
#include "core/output.h"
#include "generic_scene_opengl_test.h"
#include "opengl/glplatform.h"
#include "pipewiresourcestream.h"
#include "pointer_input.h"
#include "scene/workspacescene.h"
#include "wayland_server.h"
@ -19,12 +20,9 @@
#include <KWayland/Client/output.h>
#include <KWayland/Client/subsurface.h>
#include <KWayland/Client/surface.h>
#include <PipeWireSourceStream>
#include <QPainter>
#include <QScreen>
Q_DECLARE_METATYPE(PipeWireFrame);
#define QCOMPAREIMG(actual, expected, id) \
{ \
if ((actual) != (expected)) { \
@ -49,8 +47,6 @@ public:
ScreencastingTest()
: GenericSceneOpenGLTest(QByteArrayLiteral("O2"))
{
qRegisterMetaType<PipeWireFrame>();
auto wrap = [this](const QString &process, const QStringList &arguments = {}) {
// Make sure PipeWire is running. If it's already running it will just exit
QProcess *p = new QProcess(this);

View File

@ -65,6 +65,8 @@ private Q_SLOTS:
void testPushBack();
void testObjectEdge_data();
void testObjectEdge();
void testMultipleEntry_data();
void testMultipleEntry();
void testKdeNetWmScreenEdgeShow();
};
@ -304,6 +306,50 @@ void ScreenEdgesTest::testObjectEdge()
QCOMPARE(spy.count(), 2);
}
void ScreenEdgesTest::testMultipleEntry_data()
{
QTest::addColumn<ElectricBorder>("border");
QTest::addColumn<QPointF>("triggerPoint");
QTest::addColumn<QPointF>("delta");
QTest::newRow("top") << ElectricTop << QPointF(640, 0) << QPointF(0, 50);
QTest::newRow("right") << ElectricRight << QPointF(1279, 512) << QPointF(-50, 0);
QTest::newRow("bottom") << ElectricBottom << QPointF(640, 1023) << QPointF(0, -50);
QTest::newRow("left") << ElectricLeft << QPointF(0, 512) << QPointF(50, 0);
}
void ScreenEdgesTest::testMultipleEntry()
{
TestObject callback;
QSignalSpy spy(&callback, &TestObject::gotCallback);
// Reserve a screen edge border.
QFETCH(ElectricBorder, border);
workspace()->screenEdges()->reserve(border, &callback, "callback");
QFETCH(QPointF, triggerPoint);
QFETCH(QPointF, delta);
qint64 timestamp = 0;
while (timestamp < 300) {
// doesn't activate from repeated entries of short duration
Test::pointerMotion(triggerPoint, timestamp);
QVERIFY(spy.isEmpty());
timestamp += 50;
Test::pointerMotion(triggerPoint + delta, timestamp);
QVERIFY(spy.isEmpty());
timestamp += 50;
}
// and this one triggers
Test::pointerMotion(triggerPoint, timestamp);
timestamp += 110;
Test::pointerMotion(triggerPoint, timestamp);
QVERIFY(!spy.isEmpty());
QCOMPARE(spy.count(), 1);
}
static void enableAutoHide(xcb_connection_t *connection, xcb_window_t windowId, ElectricBorder border)
{
if (border == ElectricNone) {
@ -379,7 +425,7 @@ void ScreenEdgesTest::testKdeNetWmScreenEdgeShow()
// _KDE_NET_WM_SCREEN_EDGE_SHOW has oneshot effect. It's deleted when the window is shown.
auto config = kwinApp()->config();
config->group(QStringLiteral("Windows")).writeEntry("ElectricBorderDelay", 150);
config->group(QStringLiteral("Windows")).writeEntry("ElectricBorderDelay", 75);
config->sync();
workspace()->slotReconfigure();
@ -449,7 +495,7 @@ void ScreenEdgesTest::testKdeNetWmScreenEdgeShow()
QVERIFY(window->isShown());
}
// If the screen edge is destroyed (can happen when the screen layout changes), the window will be shown.
// The screen edge reservation won't be affected when recreating screen edges (can happen when the screen layout changes).
{
enableAutoHide(c.get(), windowId, ElectricBottom);
xcb_flush(c.get());
@ -457,7 +503,12 @@ void ScreenEdgesTest::testKdeNetWmScreenEdgeShow()
QVERIFY(!window->isShown());
workspace()->screenEdges()->recreateEdges();
QVERIFY(withdrawnSpy.wait());
QVERIFY(!withdrawnSpy.wait(50));
QVERIFY(!window->isShown());
enableAutoHide(c.get(), windowId, ElectricNone);
xcb_flush(c.get());
QVERIFY(windowShownSpy.wait());
QVERIFY(window->isShown());
}

View File

@ -28,6 +28,10 @@ private Q_SLOTS:
void testRestoreFocus();
void testRestoreFocusWithDesktopWindow();
void testQuitAfterActivatingHiddenWindow();
void testDontQuitAfterActivatingDock();
void testQuitAfterAddingWindow();
void testDontQuitAfterAddingDock();
};
void ShowingDesktopTest::initTestCase()
@ -115,5 +119,121 @@ void ShowingDesktopTest::testRestoreFocusWithDesktopWindow()
QCOMPARE(workspace()->activeWindow(), window2);
}
void ShowingDesktopTest::testQuitAfterActivatingHiddenWindow()
{
// This test verifies that the show desktop mode is deactivated after activating a hidden window.
std::unique_ptr<KWayland::Client::Surface> surface1(Test::createSurface());
std::unique_ptr<Test::XdgToplevel> shellSurface1(Test::createXdgToplevelSurface(surface1.get()));
auto window1 = Test::renderAndWaitForShown(surface1.get(), QSize(100, 50), Qt::blue);
std::unique_ptr<KWayland::Client::Surface> surface2(Test::createSurface());
std::unique_ptr<Test::XdgToplevel> shellSurface2(Test::createXdgToplevelSurface(surface2.get()));
auto window2 = Test::renderAndWaitForShown(surface2.get(), QSize(100, 50), Qt::blue);
QCOMPARE(workspace()->activeWindow(), window2);
workspace()->slotToggleShowDesktop();
QVERIFY(workspace()->showingDesktop());
workspace()->activateWindow(window1);
QVERIFY(!workspace()->showingDesktop());
}
void ShowingDesktopTest::testDontQuitAfterActivatingDock()
{
// This test verifies that activating windows belonging to desktop doesn't break showing desktop mode.
std::unique_ptr<KWayland::Client::Surface> desktopSurface(Test::createSurface());
std::unique_ptr<Test::LayerSurfaceV1> desktopShellSurface(Test::createLayerSurfaceV1(desktopSurface.get(), QStringLiteral("desktop")));
desktopShellSurface->set_keyboard_interactivity(1);
desktopShellSurface->set_layer(Test::LayerShellV1::layer_background);
desktopShellSurface->set_size(0, 0);
desktopShellSurface->set_exclusive_zone(-1);
desktopShellSurface->set_anchor(Test::LayerSurfaceV1::anchor_bottom
| Test::LayerSurfaceV1::anchor_top
| Test::LayerSurfaceV1::anchor_left
| Test::LayerSurfaceV1::anchor_right);
desktopSurface->commit(KWayland::Client::Surface::CommitFlag::None);
QSignalSpy desktopConfigureRequestedSpy(desktopShellSurface.get(), &Test::LayerSurfaceV1::configureRequested);
QVERIFY(desktopConfigureRequestedSpy.wait());
auto desktop = Test::renderAndWaitForShown(desktopSurface.get(), desktopConfigureRequestedSpy.last().at(1).toSize(), Qt::blue);
std::unique_ptr<KWayland::Client::Surface> dockSurface{Test::createSurface()};
std::unique_ptr<Test::LayerSurfaceV1> dockShellSurface{Test::createLayerSurfaceV1(dockSurface.get(), QStringLiteral("dock"))};
dockShellSurface->set_size(1280, 50);
dockShellSurface->set_anchor(Test::LayerSurfaceV1::anchor_bottom);
dockShellSurface->set_exclusive_zone(50);
dockShellSurface->set_keyboard_interactivity(1);
dockSurface->commit(KWayland::Client::Surface::CommitFlag::None);
QSignalSpy dockConfigureRequestedSpy(dockShellSurface.get(), &Test::LayerSurfaceV1::configureRequested);
QVERIFY(dockConfigureRequestedSpy.wait());
auto dock = Test::renderAndWaitForShown(dockSurface.get(), dockConfigureRequestedSpy.last().at(1).toSize(), Qt::blue);
std::unique_ptr<KWayland::Client::Surface> surface(Test::createSurface());
std::unique_ptr<Test::XdgToplevel> shellSurface(Test::createXdgToplevelSurface(surface.get()));
auto window = Test::renderAndWaitForShown(surface.get(), QSize(100, 50), Qt::blue);
QVERIFY(window->isActive());
workspace()->slotToggleShowDesktop();
QVERIFY(workspace()->showingDesktop());
QVERIFY(desktop->isActive());
workspace()->activateWindow(dock);
QVERIFY(workspace()->showingDesktop());
QVERIFY(dock->isActive());
workspace()->activateWindow(desktop);
QVERIFY(workspace()->showingDesktop());
QVERIFY(desktop->isActive());
workspace()->slotToggleShowDesktop();
QVERIFY(!workspace()->showingDesktop());
}
void ShowingDesktopTest::testQuitAfterAddingWindow()
{
// This test verifies that the show desktop mode is deactivated after mapping a new window.
std::unique_ptr<KWayland::Client::Surface> surface1(Test::createSurface());
std::unique_ptr<Test::XdgToplevel> shellSurface1(Test::createXdgToplevelSurface(surface1.get()));
Test::renderAndWaitForShown(surface1.get(), QSize(100, 50), Qt::blue);
workspace()->slotToggleShowDesktop();
QVERIFY(workspace()->showingDesktop());
std::unique_ptr<KWayland::Client::Surface> surface2(Test::createSurface());
std::unique_ptr<Test::XdgToplevel> shellSurface2(Test::createXdgToplevelSurface(surface2.get()));
Test::renderAndWaitForShown(surface2.get(), QSize(100, 50), Qt::blue);
QVERIFY(!workspace()->showingDesktop());
}
void ShowingDesktopTest::testDontQuitAfterAddingDock()
{
// This test verifies that the show desktop mode is not broken after adding a dock.
std::unique_ptr<KWayland::Client::Surface> surface(Test::createSurface());
std::unique_ptr<Test::XdgToplevel> shellSurface(Test::createXdgToplevelSurface(surface.get()));
auto window = Test::renderAndWaitForShown(surface.get(), QSize(100, 50), Qt::blue);
QVERIFY(window->isActive());
workspace()->slotToggleShowDesktop();
QVERIFY(workspace()->showingDesktop());
std::unique_ptr<KWayland::Client::Surface> dockSurface{Test::createSurface()};
std::unique_ptr<Test::LayerSurfaceV1> dockShellSurface{Test::createLayerSurfaceV1(dockSurface.get(), QStringLiteral("dock"))};
dockShellSurface->set_size(1280, 50);
dockShellSurface->set_anchor(Test::LayerSurfaceV1::anchor_bottom);
dockShellSurface->set_exclusive_zone(50);
dockShellSurface->set_keyboard_interactivity(1);
dockSurface->commit(KWayland::Client::Surface::CommitFlag::None);
QSignalSpy dockConfigureRequestedSpy(dockShellSurface.get(), &Test::LayerSurfaceV1::configureRequested);
QVERIFY(dockConfigureRequestedSpy.wait());
auto dock = Test::renderAndWaitForShown(dockSurface.get(), dockConfigureRequestedSpy.last().at(1).toSize(), Qt::blue);
QVERIFY(dock->isActive());
QVERIFY(workspace()->showingDesktop());
workspace()->slotToggleShowDesktop();
}
WAYLANDTEST_MAIN(ShowingDesktopTest)
#include "showing_desktop_test.moc"

View File

@ -104,11 +104,11 @@ void TabBoxTest::testCapsLock()
quint32 timestamp = 0;
Test::keyboardKeyPressed(KEY_CAPSLOCK, timestamp++);
Test::keyboardKeyReleased(KEY_CAPSLOCK, timestamp++);
QCOMPARE(input()->keyboardModifiers(), Qt::ShiftModifier);
QCOMPARE(input()->keyboardModifiers(), Qt::NoModifier);
// press alt+tab
Test::keyboardKeyPressed(KEY_LEFTALT, timestamp++);
QCOMPARE(input()->keyboardModifiers(), Qt::ShiftModifier | Qt::AltModifier);
QCOMPARE(input()->keyboardModifiers(), Qt::AltModifier);
Test::keyboardKeyPressed(KEY_TAB, timestamp++);
Test::keyboardKeyReleased(KEY_TAB, timestamp++);

View File

@ -326,14 +326,27 @@ void MockInputMethod::zwp_input_method_v1_activate(struct ::zwp_input_method_con
{
if (!m_inputSurface) {
m_inputSurface = Test::createSurface();
m_inputMethodSurface = Test::createInputPanelSurfaceV1(m_inputSurface.get(), s_waylandConnection.outputs.first());
m_inputMethodSurface = Test::createInputPanelSurfaceV1(m_inputSurface.get(), s_waylandConnection.outputs.first(), m_mode);
}
m_context = context;
switch (m_mode) {
case Mode::TopLevel:
Test::render(m_inputSurface.get(), QSize(1280, 400), Qt::blue);
break;
case Mode::Overlay:
Test::render(m_inputSurface.get(), QSize(200, 50), Qt::blue);
break;
}
Q_EMIT activate();
}
void MockInputMethod::setMode(MockInputMethod::Mode mode)
{
m_mode = mode;
}
void MockInputMethod::zwp_input_method_v1_deactivate(struct ::zwp_input_method_context_v1 *context)
{
QCOMPARE(context, m_context);
@ -924,7 +937,7 @@ LayerSurfaceV1 *createLayerSurfaceV1(KWayland::Client::Surface *surface, const Q
return shellSurface;
}
QtWayland::zwp_input_panel_surface_v1 *createInputPanelSurfaceV1(KWayland::Client::Surface *surface, KWayland::Client::Output *output)
QtWayland::zwp_input_panel_surface_v1 *createInputPanelSurfaceV1(KWayland::Client::Surface *surface, KWayland::Client::Output *output, MockInputMethod::Mode mode)
{
if (!s_waylandConnection.inputPanelV1) {
qWarning() << "Unable to create the input panel surface. The interface input_panel global is not bound";
@ -937,7 +950,14 @@ QtWayland::zwp_input_panel_surface_v1 *createInputPanelSurfaceV1(KWayland::Clien
return nullptr;
}
switch (mode) {
case MockInputMethod::Mode::TopLevel:
s->set_toplevel(output->output(), QtWayland::zwp_input_panel_surface_v1::position_center_bottom);
break;
case MockInputMethod::Mode::Overlay:
s->set_overlay_panel();
break;
}
return s;
}

View File

@ -35,8 +35,6 @@ private Q_SLOTS:
void testMinimumSize();
void testMaximumSize();
void testResizeIncrements();
void testResizeIncrementsNoBaseSize();
void testTrimCaption_data();
void testTrimCaption();
void testFullscreenLayerWithActiveWaylandWindow();
@ -291,175 +289,6 @@ void X11WindowTest::testMaximumSize()
c.reset();
}
void X11WindowTest::testResizeIncrements()
{
// This test verifies that the resize increments constraint is correctly applied.
QFETCH_GLOBAL(qreal, scale);
kwinApp()->setXwaylandScale(scale);
// Create an xcb window.
Test::XcbConnectionPtr c = Test::createX11Connection();
QVERIFY(!xcb_connection_has_error(c.get()));
const QRect windowGeometry(0, 0, 100, 200);
xcb_window_t windowId = xcb_generate_id(c.get());
xcb_create_window(c.get(), XCB_COPY_FROM_PARENT, windowId, rootWindow(),
windowGeometry.x(),
windowGeometry.y(),
windowGeometry.width(),
windowGeometry.height(),
0, XCB_WINDOW_CLASS_INPUT_OUTPUT, XCB_COPY_FROM_PARENT, 0, nullptr);
xcb_size_hints_t hints;
memset(&hints, 0, sizeof(hints));
xcb_icccm_size_hints_set_position(&hints, 1, windowGeometry.x(), windowGeometry.y());
xcb_icccm_size_hints_set_size(&hints, 1, windowGeometry.width(), windowGeometry.height());
xcb_icccm_size_hints_set_base_size(&hints, windowGeometry.width(), windowGeometry.height());
xcb_icccm_size_hints_set_resize_inc(&hints, 3, 5);
xcb_icccm_set_wm_normal_hints(c.get(), windowId, &hints);
xcb_map_window(c.get(), windowId);
xcb_flush(c.get());
QSignalSpy windowCreatedSpy(workspace(), &Workspace::windowAdded);
QVERIFY(windowCreatedSpy.wait());
X11Window *window = windowCreatedSpy.last().first().value<X11Window *>();
QVERIFY(window);
QVERIFY(window->isDecorated());
QSignalSpy interactiveMoveResizeStartedSpy(window, &Window::interactiveMoveResizeStarted);
QSignalSpy interactiveMoveResizeSteppedSpy(window, &Window::interactiveMoveResizeStepped);
QSignalSpy interactiveMoveResizeFinishedSpy(window, &Window::interactiveMoveResizeFinished);
QSignalSpy frameGeometryChangedSpy(window, &Window::frameGeometryChanged);
// Begin resize.
QCOMPARE(workspace()->moveResizeWindow(), nullptr);
QVERIFY(!window->isInteractiveResize());
workspace()->slotWindowResize();
QCOMPARE(workspace()->moveResizeWindow(), window);
QCOMPARE(interactiveMoveResizeStartedSpy.count(), 1);
QVERIFY(window->isInteractiveResize());
const QPointF cursorPos = KWin::Cursors::self()->mouse()->pos();
window->keyPressEvent(Qt::Key_Right);
window->updateInteractiveMoveResize(KWin::Cursors::self()->mouse()->pos());
QCOMPARE(KWin::Cursors::self()->mouse()->pos(), cursorPos + QPoint(8, 0));
QCOMPARE(interactiveMoveResizeSteppedSpy.count(), 1);
QVERIFY(frameGeometryChangedSpy.wait());
// 100 + 8 logical pixels, rounded to resize increments. This will differ on scale
const qreal horizontalResizeInc = 3 / scale;
const qreal verticalResizeInc = 5 / scale;
const qreal expectedHorizontalResizeInc = std::floor(8. / horizontalResizeInc) * horizontalResizeInc;
const qreal expectedVerticalResizeInc = std::floor(8. / verticalResizeInc) * verticalResizeInc;
QCOMPARE(window->clientSize(), QSizeF(100, 200) / scale + QSizeF(expectedHorizontalResizeInc, 0));
window->keyPressEvent(Qt::Key_Down);
window->updateInteractiveMoveResize(KWin::Cursors::self()->mouse()->pos());
QCOMPARE(KWin::Cursors::self()->mouse()->pos(), cursorPos + QPoint(8, 8));
QCOMPARE(interactiveMoveResizeSteppedSpy.count(), 2);
QVERIFY(frameGeometryChangedSpy.wait());
QCOMPARE(window->clientSize(), QSize(100, 200) / scale + QSizeF(expectedHorizontalResizeInc, expectedVerticalResizeInc));
// Finish the resize operation.
QCOMPARE(interactiveMoveResizeFinishedSpy.count(), 0);
window->keyPressEvent(Qt::Key_Enter);
QCOMPARE(interactiveMoveResizeFinishedSpy.count(), 1);
QCOMPARE(workspace()->moveResizeWindow(), nullptr);
QVERIFY(!window->isInteractiveResize());
// Destroy the window.
QSignalSpy windowClosedSpy(window, &X11Window::closed);
xcb_unmap_window(c.get(), windowId);
xcb_destroy_window(c.get(), windowId);
xcb_flush(c.get());
QVERIFY(windowClosedSpy.wait());
c.reset();
}
void X11WindowTest::testResizeIncrementsNoBaseSize()
{
QFETCH_GLOBAL(qreal, scale);
kwinApp()->setXwaylandScale(scale);
// Create an xcb window.
Test::XcbConnectionPtr c = Test::createX11Connection();
QVERIFY(!xcb_connection_has_error(c.get()));
const QRect windowGeometry(0, 0, 100, 200);
xcb_window_t windowId = xcb_generate_id(c.get());
xcb_create_window(c.get(), XCB_COPY_FROM_PARENT, windowId, rootWindow(),
windowGeometry.x(),
windowGeometry.y(),
windowGeometry.width(),
windowGeometry.height(),
0, XCB_WINDOW_CLASS_INPUT_OUTPUT, XCB_COPY_FROM_PARENT, 0, nullptr);
xcb_size_hints_t hints;
memset(&hints, 0, sizeof(hints));
xcb_icccm_size_hints_set_position(&hints, 1, windowGeometry.x(), windowGeometry.y());
xcb_icccm_size_hints_set_size(&hints, 1, windowGeometry.width(), windowGeometry.height());
xcb_icccm_size_hints_set_min_size(&hints, windowGeometry.width(), windowGeometry.height());
xcb_icccm_size_hints_set_resize_inc(&hints, 3, 5);
xcb_icccm_set_wm_normal_hints(c.get(), windowId, &hints);
xcb_map_window(c.get(), windowId);
xcb_flush(c.get());
QSignalSpy windowCreatedSpy(workspace(), &Workspace::windowAdded);
QVERIFY(windowCreatedSpy.wait());
X11Window *window = windowCreatedSpy.last().first().value<X11Window *>();
QVERIFY(window);
QVERIFY(window->isDecorated());
QSignalSpy interactiveMoveResizeStartedSpy(window, &Window::interactiveMoveResizeStarted);
QSignalSpy interactiveMoveResizeSteppedSpy(window, &Window::interactiveMoveResizeStepped);
QSignalSpy interactiveMoveResizeFinishedSpy(window, &Window::interactiveMoveResizeFinished);
QSignalSpy frameGeometryChangedSpy(window, &Window::frameGeometryChanged);
// Begin resize.
QCOMPARE(workspace()->moveResizeWindow(), nullptr);
QVERIFY(!window->isInteractiveResize());
workspace()->slotWindowResize();
QCOMPARE(workspace()->moveResizeWindow(), window);
QCOMPARE(interactiveMoveResizeStartedSpy.count(), 1);
QVERIFY(window->isInteractiveResize());
const QPointF cursorPos = KWin::Cursors::self()->mouse()->pos();
window->keyPressEvent(Qt::Key_Right);
window->updateInteractiveMoveResize(KWin::Cursors::self()->mouse()->pos());
QCOMPARE(KWin::Cursors::self()->mouse()->pos(), cursorPos + QPoint(8, 0));
QCOMPARE(interactiveMoveResizeSteppedSpy.count(), 1);
QVERIFY(frameGeometryChangedSpy.wait());
// 100 + 8 pixels, rounded to resize increments. This will differ on scale
const qreal horizontalResizeInc = 3 / scale;
const qreal verticalResizeInc = 5 / scale;
const qreal expectedHorizontalResizeInc = std::floor(8. / horizontalResizeInc) * horizontalResizeInc;
const qreal expectedVerticalResizeInc = std::floor(8. / verticalResizeInc) * verticalResizeInc;
QCOMPARE(window->clientSize(), QSizeF(100, 200) / scale + QSizeF(expectedHorizontalResizeInc, 0));
window->keyPressEvent(Qt::Key_Down);
window->updateInteractiveMoveResize(KWin::Cursors::self()->mouse()->pos());
QCOMPARE(KWin::Cursors::self()->mouse()->pos(), cursorPos + QPoint(8, 8));
QCOMPARE(interactiveMoveResizeSteppedSpy.count(), 2);
QVERIFY(frameGeometryChangedSpy.wait());
QCOMPARE(window->clientSize(), QSizeF(100, 200) / scale + QSizeF(expectedHorizontalResizeInc, expectedVerticalResizeInc));
// Finish the resize operation.
QCOMPARE(interactiveMoveResizeFinishedSpy.count(), 0);
window->keyPressEvent(Qt::Key_Enter);
QCOMPARE(interactiveMoveResizeFinishedSpy.count(), 1);
QCOMPARE(workspace()->moveResizeWindow(), nullptr);
QVERIFY(!window->isInteractiveResize());
// Destroy the window.
QSignalSpy windowClosedSpy(window, &X11Window::closed);
xcb_unmap_window(c.get(), windowId);
xcb_destroy_window(c.get(), windowId);
xcb_flush(c.get());
QVERIFY(windowClosedSpy.wait());
c.reset();
}
void X11WindowTest::testTrimCaption_data()
{
QFETCH_GLOBAL(qreal, scale);

View File

@ -151,6 +151,14 @@ private Q_SLOTS:
void testScreenApplyNow();
void testScreenForceTemporarily();
void testLayerDontAffect();
void testLayerForce();
void testLayerForceTemporarily();
void testCloseableDontAffect();
void testCloseableForce();
void testCloseableForceTemporarily();
void testMatchAfterNameChange();
private:
@ -2980,5 +2988,78 @@ void TestXdgShellWindowRules::testMatchAfterNameChange()
QCOMPARE(window->keepAbove(), true);
}
void TestXdgShellWindowRules::testLayerDontAffect()
{
setWindowRule("layer", QStringLiteral("overlay"), int(Rules::DontAffect));
createTestWindow();
// The layer should not be affected by the rule.
QCOMPARE(m_window->layer(), NormalLayer);
destroyTestWindow();
}
void TestXdgShellWindowRules::testLayerForce()
{
setWindowRule("layer", QStringLiteral("overlay"), int(Rules::Force));
createTestWindow();
QCOMPARE(m_window->layer(), OverlayLayer);
destroyTestWindow();
}
void TestXdgShellWindowRules::testLayerForceTemporarily()
{
setWindowRule("layer", QStringLiteral("overlay"), int(Rules::ForceTemporarily));
createTestWindow();
QCOMPARE(m_window->layer(), OverlayLayer);
// The rule should be discarded when the window is closed.
destroyTestWindow();
createTestWindow();
QCOMPARE(m_window->layer(), NormalLayer);
destroyTestWindow();
}
void TestXdgShellWindowRules::testCloseableDontAffect()
{
setWindowRule("closeable", false, int(Rules::DontAffect));
createTestWindow();
QVERIFY(m_window->isCloseable());
destroyTestWindow();
}
void TestXdgShellWindowRules::testCloseableForce()
{
setWindowRule("closeable", false, int(Rules::Force));
createTestWindow();
QVERIFY(!m_window->isCloseable());
destroyTestWindow();
}
void TestXdgShellWindowRules::testCloseableForceTemporarily()
{
setWindowRule("closeable", false, int(Rules::ForceTemporarily));
createTestWindow();
QVERIFY(!m_window->isCloseable());
// The rule should be discarded when the window is closed.
destroyTestWindow();
createTestWindow();
QVERIFY(m_window->isCloseable());
destroyTestWindow();
}
WAYLANDTEST_MAIN(TestXdgShellWindowRules)
#include "xdgshellwindow_rules_test.moc"

View File

@ -0,0 +1,65 @@
/*
SPDX-FileCopyrightText: 2024 Vlad Zahorodnii <vlad.zahorodnii@kde.org>
SPDX-License-Identifier: GPL-2.0-or-later
*/
#include "kwin_wayland_test.h"
#include "core/output.h"
#include "wayland_server.h"
#include "workspace.h"
namespace KWin
{
static const QString s_socketName = QStringLiteral("wayland_test_kwin_xinerama-0");
class XineramaTest : public QObject
{
Q_OBJECT
private Q_SLOTS:
void initTestCase();
void indexToOutput();
};
void XineramaTest::initTestCase()
{
QSignalSpy applicationStartedSpy(kwinApp(), &Application::started);
QVERIFY(waylandServer()->init(s_socketName));
kwinApp()->start();
QVERIFY(applicationStartedSpy.wait());
}
void XineramaTest::indexToOutput()
{
Test::setOutputConfig({
Test::OutputInfo{
.geometry = QRect(0, 0, 1280, 1024),
.scale = 1.5,
},
Test::OutputInfo{
.geometry = QRect(1280, 0, 1280, 1024),
.scale = 1.5,
},
});
kwinApp()->setXwaylandScale(1.5);
// Start Xwayland
Test::XcbConnectionPtr c = Test::createX11Connection();
QVERIFY(!xcb_connection_has_error(c.get()));
const auto outputs = workspace()->outputs();
QCOMPARE(workspace()->xineramaIndexToOutput(0), outputs.at(0));
QCOMPARE(workspace()->xineramaIndexToOutput(1), outputs.at(1));
workspace()->setOutputOrder({outputs[1], outputs[0]});
QCOMPARE(workspace()->xineramaIndexToOutput(0), outputs.at(1));
QCOMPARE(workspace()->xineramaIndexToOutput(1), outputs.at(0));
}
} // namespace KWin
WAYLANDTEST_MAIN(KWin::XineramaTest)
#include "xinerama_test.moc"

View File

@ -53,7 +53,7 @@ void InputEventsTest::testInitMouseEvent()
QFETCH(QEvent::Type, type);
// now create our own event
MouseEvent event(type, QPointF(100, 200), Qt::LeftButton, Qt::LeftButton | Qt::RightButton,
Qt::ShiftModifier | Qt::ControlModifier, 300ms, QPointF(1, 2), QPointF(3, 4), &d);
Qt::ShiftModifier | Qt::ControlModifier, 300ms, QPointF(1, 2), QPointF(3, 4), &d, false);
// and verify the contract of QMouseEvent
QCOMPARE(event.type(), type);
QCOMPARE(event.globalPos(), QPoint(100, 200));

View File

@ -20,6 +20,7 @@ public:
private Q_SLOTS:
void roundtripConversion_data();
void roundtripConversion();
void nonNormalizedPrimaries();
};
static bool compareVectors(const QVector3D &one, const QVector3D &two, float maxDifference)
@ -33,6 +34,8 @@ static bool compareVectors(const QVector3D &one, const QVector3D &two, float max
return ret;
}
static const double s_resolution10bit = std::pow(1.0 / 2.0, 10);
void TestColorspaces::roundtripConversion_data()
{
QTest::addColumn<NamedColorimetry>("srcColorimetry");
@ -41,12 +44,11 @@ void TestColorspaces::roundtripConversion_data()
QTest::addColumn<NamedTransferFunction>("dstTransferFunction");
QTest::addColumn<double>("requiredAccuracy");
const double resolution10bit = std::pow(1.0 / 2.0, 10);
QTest::addRow("BT709 (sRGB) <-> BT2020 (linear)") << NamedColorimetry::BT709 << NamedTransferFunction::sRGB << NamedColorimetry::BT2020 << NamedTransferFunction::linear << resolution10bit;
QTest::addRow("BT709 (gamma 2.2) <-> BT2020 (linear)") << NamedColorimetry::BT709 << NamedTransferFunction::gamma22 << NamedColorimetry::BT2020 << NamedTransferFunction::linear << resolution10bit;
QTest::addRow("BT709 (scRGB) <-> BT2020 (linear)") << NamedColorimetry::BT709 << NamedTransferFunction::scRGB << NamedColorimetry::BT2020 << NamedTransferFunction::linear << resolution10bit;
QTest::addRow("BT709 (linear) <-> BT2020 (linear)") << NamedColorimetry::BT709 << NamedTransferFunction::linear << NamedColorimetry::BT2020 << NamedTransferFunction::linear << resolution10bit;
QTest::addRow("BT709 (PQ) <-> BT2020 (linear)") << NamedColorimetry::BT709 << NamedTransferFunction::PerceptualQuantizer << NamedColorimetry::BT2020 << NamedTransferFunction::linear << 3 * resolution10bit;
QTest::addRow("BT709 (sRGB) <-> BT2020 (linear)") << NamedColorimetry::BT709 << NamedTransferFunction::sRGB << NamedColorimetry::BT2020 << NamedTransferFunction::linear << s_resolution10bit;
QTest::addRow("BT709 (gamma 2.2) <-> BT2020 (linear)") << NamedColorimetry::BT709 << NamedTransferFunction::gamma22 << NamedColorimetry::BT2020 << NamedTransferFunction::linear << s_resolution10bit;
QTest::addRow("BT709 (scRGB) <-> BT2020 (linear)") << NamedColorimetry::BT709 << NamedTransferFunction::scRGB << NamedColorimetry::BT2020 << NamedTransferFunction::linear << s_resolution10bit;
QTest::addRow("BT709 (linear) <-> BT2020 (linear)") << NamedColorimetry::BT709 << NamedTransferFunction::linear << NamedColorimetry::BT2020 << NamedTransferFunction::linear << s_resolution10bit;
QTest::addRow("BT709 (PQ) <-> BT2020 (linear)") << NamedColorimetry::BT709 << NamedTransferFunction::PerceptualQuantizer << NamedColorimetry::BT2020 << NamedTransferFunction::linear << 3 * s_resolution10bit;
}
void TestColorspaces::roundtripConversion()
@ -57,8 +59,8 @@ void TestColorspaces::roundtripConversion()
QFETCH(NamedTransferFunction, dstTransferFunction);
QFETCH(double, requiredAccuracy);
const auto src = ColorDescription(srcColorimetry, srcTransferFunction, 100, 0, 100, 100, 0);
const auto dst = ColorDescription(dstColorimetry, dstTransferFunction, 100, 0, 100, 100, 0);
const auto src = ColorDescription(srcColorimetry, srcTransferFunction, 100, 0, 100, 100);
const auto dst = ColorDescription(dstColorimetry, dstTransferFunction, 100, 0, 100, 100);
const QVector3D red(1, 0, 0);
const QVector3D green(0, 1, 0);
@ -71,6 +73,18 @@ void TestColorspaces::roundtripConversion()
QVERIFY(compareVectors(dst.mapTo(src.mapTo(white, dst), src), white, requiredAccuracy));
}
void TestColorspaces::nonNormalizedPrimaries()
{
// this test ensures that non-normalized primaries don't mess up the transformations between color spaces
const auto from = Colorimetry::fromName(NamedColorimetry::BT709);
const auto to = Colorimetry(Colorimetry::xyToXYZ(from.red()) * 2, Colorimetry::xyToXYZ(from.green()) * 2, Colorimetry::xyToXYZ(from.blue()) * 2, Colorimetry::xyToXYZ(from.white()) * 2);
const auto convertedWhite = from.toOther(to) * QVector3D(1, 1, 1);
QCOMPARE_LE(std::abs(1 - convertedWhite.x()), s_resolution10bit);
QCOMPARE_LE(std::abs(1 - convertedWhite.y()), s_resolution10bit);
QCOMPARE_LE(std::abs(1 - convertedWhite.z()), s_resolution10bit);
}
QTEST_MAIN(TestColorspaces)
#include "test_colorspaces.moc"

View File

@ -419,47 +419,32 @@ void TestVirtualDesktops::updateGrid_data()
{
QTest::addColumn<uint>("initCount");
QTest::addColumn<QSize>("size");
QTest::addColumn<Qt::Orientation>("orientation");
QTest::addColumn<QPoint>("coords");
QTest::addColumn<uint>("desktop");
const Qt::Orientation h = Qt::Horizontal;
const Qt::Orientation v = Qt::Vertical;
QTest::newRow("one desktop, h") << (uint)1 << QSize(1, 1) << h << QPoint(0, 0) << (uint)1;
QTest::newRow("one desktop, v") << (uint)1 << QSize(1, 1) << v << QPoint(0, 0) << (uint)1;
QTest::newRow("one desktop, h, 0") << (uint)1 << QSize(1, 1) << h << QPoint(1, 0) << (uint)0;
QTest::newRow("one desktop, v, 0") << (uint)1 << QSize(1, 1) << v << QPoint(0, 1) << (uint)0;
QTest::newRow("one desktop, h") << (uint)1 << QSize(1, 1) << QPoint(0, 0) << (uint)1;
QTest::newRow("one desktop, h, 0") << (uint)1 << QSize(1, 1) << QPoint(1, 0) << (uint)0;
QTest::newRow("two desktops, h, 1") << (uint)2 << QSize(2, 1) << h << QPoint(0, 0) << (uint)1;
QTest::newRow("two desktops, h, 2") << (uint)2 << QSize(2, 1) << h << QPoint(1, 0) << (uint)2;
QTest::newRow("two desktops, h, 3") << (uint)2 << QSize(2, 1) << h << QPoint(0, 1) << (uint)0;
QTest::newRow("two desktops, h, 4") << (uint)2 << QSize(2, 1) << h << QPoint(2, 0) << (uint)0;
QTest::newRow("two desktops, h, 1") << (uint)2 << QSize(2, 1) << QPoint(0, 0) << (uint)1;
QTest::newRow("two desktops, h, 2") << (uint)2 << QSize(2, 1) << QPoint(1, 0) << (uint)2;
QTest::newRow("two desktops, h, 3") << (uint)2 << QSize(2, 1) << QPoint(0, 1) << (uint)0;
QTest::newRow("two desktops, h, 4") << (uint)2 << QSize(2, 1) << QPoint(2, 0) << (uint)0;
QTest::newRow("two desktops, v, 1") << (uint)2 << QSize(2, 1) << v << QPoint(0, 0) << (uint)1;
QTest::newRow("two desktops, v, 2") << (uint)2 << QSize(2, 1) << v << QPoint(1, 0) << (uint)2;
QTest::newRow("two desktops, v, 3") << (uint)2 << QSize(2, 1) << v << QPoint(0, 1) << (uint)0;
QTest::newRow("two desktops, v, 4") << (uint)2 << QSize(2, 1) << v << QPoint(2, 0) << (uint)0;
QTest::newRow("four desktops, h, one row, 1") << (uint)4 << QSize(4, 1) << QPoint(0, 0) << (uint)1;
QTest::newRow("four desktops, h, one row, 2") << (uint)4 << QSize(4, 1) << QPoint(1, 0) << (uint)2;
QTest::newRow("four desktops, h, one row, 3") << (uint)4 << QSize(4, 1) << QPoint(2, 0) << (uint)3;
QTest::newRow("four desktops, h, one row, 4") << (uint)4 << QSize(4, 1) << QPoint(3, 0) << (uint)4;
QTest::newRow("four desktops, h, one row, 1") << (uint)4 << QSize(4, 1) << h << QPoint(0, 0) << (uint)1;
QTest::newRow("four desktops, h, one row, 2") << (uint)4 << QSize(4, 1) << h << QPoint(1, 0) << (uint)2;
QTest::newRow("four desktops, h, one row, 3") << (uint)4 << QSize(4, 1) << h << QPoint(2, 0) << (uint)3;
QTest::newRow("four desktops, h, one row, 4") << (uint)4 << QSize(4, 1) << h << QPoint(3, 0) << (uint)4;
QTest::newRow("four desktops, h, grid, 1") << (uint)4 << QSize(2, 2) << QPoint(0, 0) << (uint)1;
QTest::newRow("four desktops, h, grid, 2") << (uint)4 << QSize(2, 2) << QPoint(1, 0) << (uint)2;
QTest::newRow("four desktops, h, grid, 3") << (uint)4 << QSize(2, 2) << QPoint(0, 1) << (uint)3;
QTest::newRow("four desktops, h, grid, 4") << (uint)4 << QSize(2, 2) << QPoint(1, 1) << (uint)4;
QTest::newRow("four desktops, h, grid, 0/3") << (uint)4 << QSize(2, 2) << QPoint(0, 3) << (uint)0;
QTest::newRow("four desktops, v, one column, 1") << (uint)4 << QSize(1, 4) << v << QPoint(0, 0) << (uint)1;
QTest::newRow("four desktops, v, one column, 2") << (uint)4 << QSize(1, 4) << v << QPoint(0, 1) << (uint)2;
QTest::newRow("four desktops, v, one column, 3") << (uint)4 << QSize(1, 4) << v << QPoint(0, 2) << (uint)3;
QTest::newRow("four desktops, v, one column, 4") << (uint)4 << QSize(1, 4) << v << QPoint(0, 3) << (uint)4;
QTest::newRow("four desktops, h, grid, 1") << (uint)4 << QSize(2, 2) << h << QPoint(0, 0) << (uint)1;
QTest::newRow("four desktops, h, grid, 2") << (uint)4 << QSize(2, 2) << h << QPoint(1, 0) << (uint)2;
QTest::newRow("four desktops, h, grid, 3") << (uint)4 << QSize(2, 2) << h << QPoint(0, 1) << (uint)3;
QTest::newRow("four desktops, h, grid, 4") << (uint)4 << QSize(2, 2) << h << QPoint(1, 1) << (uint)4;
QTest::newRow("four desktops, h, grid, 0/3") << (uint)4 << QSize(2, 2) << h << QPoint(0, 3) << (uint)0;
QTest::newRow("three desktops, h, grid, 1") << (uint)3 << QSize(2, 2) << h << QPoint(0, 0) << (uint)1;
QTest::newRow("three desktops, h, grid, 2") << (uint)3 << QSize(2, 2) << h << QPoint(1, 0) << (uint)2;
QTest::newRow("three desktops, h, grid, 3") << (uint)3 << QSize(2, 2) << h << QPoint(0, 1) << (uint)3;
QTest::newRow("three desktops, h, grid, 4") << (uint)3 << QSize(2, 2) << h << QPoint(1, 1) << (uint)0;
QTest::newRow("three desktops, h, grid, 1") << (uint)3 << QSize(2, 2) << QPoint(0, 0) << (uint)1;
QTest::newRow("three desktops, h, grid, 2") << (uint)3 << QSize(2, 2) << QPoint(1, 0) << (uint)2;
QTest::newRow("three desktops, h, grid, 3") << (uint)3 << QSize(2, 2) << QPoint(0, 1) << (uint)3;
QTest::newRow("three desktops, h, grid, 4") << (uint)3 << QSize(2, 2) << QPoint(1, 1) << (uint)0;
}
void TestVirtualDesktops::updateGrid()
@ -470,9 +455,8 @@ void TestVirtualDesktops::updateGrid()
VirtualDesktopGrid grid;
QFETCH(QSize, size);
QFETCH(Qt::Orientation, orientation);
QCOMPARE(vds->desktops().count(), int(initCount));
grid.update(size, orientation, vds->desktops());
grid.update(size, vds->desktops());
QCOMPARE(grid.size(), size);
QCOMPARE(grid.width(), size.width());
QCOMPARE(grid.height(), size.height());

View File

@ -457,6 +457,28 @@ static const TransKey g_rgQtToSymX[] = {
{XKB_KEY_KP_7, Qt::Key_7, Qt::KeypadModifier},
{XKB_KEY_KP_8, Qt::Key_8, Qt::KeypadModifier},
{XKB_KEY_KP_9, Qt::Key_9, Qt::KeypadModifier},
{XKB_KEY_KP_Space, Qt::Key_Space, Qt::KeypadModifier},
{XKB_KEY_KP_Tab, Qt::Key_Tab, Qt::KeypadModifier},
{XKB_KEY_KP_Enter, Qt::Key_Enter, Qt::KeypadModifier},
{XKB_KEY_KP_Home, Qt::Key_Home, Qt::KeypadModifier},
{XKB_KEY_KP_Left, Qt::Key_Left, Qt::KeypadModifier},
{XKB_KEY_KP_Up, Qt::Key_Up, Qt::KeypadModifier},
{XKB_KEY_KP_Right, Qt::Key_Right, Qt::KeypadModifier},
{XKB_KEY_KP_Down, Qt::Key_Down, Qt::KeypadModifier},
{XKB_KEY_KP_Prior, Qt::Key_PageUp, Qt::KeypadModifier},
{XKB_KEY_KP_Next, Qt::Key_PageDown, Qt::KeypadModifier},
{XKB_KEY_KP_End, Qt::Key_End, Qt::KeypadModifier},
{XKB_KEY_KP_Begin, Qt::Key_Clear, Qt::KeypadModifier},
{XKB_KEY_KP_Insert, Qt::Key_Insert, Qt::KeypadModifier},
{XKB_KEY_KP_Delete, Qt::Key_Delete, Qt::KeypadModifier},
{XKB_KEY_KP_Equal, Qt::Key_Equal, Qt::KeypadModifier},
{XKB_KEY_KP_Multiply, Qt::Key_Asterisk, Qt::KeypadModifier},
{XKB_KEY_KP_Add, Qt::Key_Plus, Qt::KeypadModifier},
{XKB_KEY_KP_Separator, Qt::Key_Comma, Qt::KeypadModifier},
{XKB_KEY_KP_Subtract, Qt::Key_Minus, Qt::KeypadModifier},
{XKB_KEY_KP_Decimal, Qt::Key_Period, Qt::KeypadModifier},
{XKB_KEY_KP_Divide, Qt::Key_Slash, Qt::KeypadModifier},
};
void XkbTest::testToQtKey_data()

View File

@ -274,8 +274,6 @@ void TestDragAndDrop::testPointerDragAndDrop()
// verify that we did not get any further input events
QVERIFY(pointerMotionSpy.isEmpty());
// the release event is sent primarily for xwayland
QCOMPARE(buttonPressSpy.count(), 2);
}
void TestDragAndDrop::testTouchDragAndDrop()
@ -394,6 +392,7 @@ void TestDragAndDrop::testDragAndDropWithCancelByDestroyDataSource()
QSignalSpy dragEnteredSpy(m_dataDevice, &KWayland::Client::DataDevice::dragEntered);
QSignalSpy dragMotionSpy(m_dataDevice, &KWayland::Client::DataDevice::dragMotion);
QSignalSpy pointerMotionSpy(m_pointer, &KWayland::Client::Pointer::motion);
QSignalSpy pointerLeftSpy(m_pointer, &KWayland::Client::Pointer::left);
QSignalSpy dragLeftSpy(m_dataDevice, &KWayland::Client::DataDevice::dragLeft);
// now we can start the drag and drop
@ -401,11 +400,12 @@ void TestDragAndDrop::testDragAndDropWithCancelByDestroyDataSource()
m_dataSource->setDragAndDropActions(KWayland::Client::DataDeviceManager::DnDAction::Copy | KWayland::Client::DataDeviceManager::DnDAction::Move);
m_dataDevice->startDrag(buttonPressSpy.first().first().value<quint32>(), m_dataSource, s.get());
QVERIFY(dragStartedSpy.wait());
QCOMPARE(m_seatInterface->dragSurface(), serverSurface);
QCOMPARE(m_seatInterface->dragSurfaceTransformation(), QMatrix4x4());
QVERIFY(!m_seatInterface->dragIcon());
QCOMPARE(SeatInterfacePrivate::get(m_seatInterface)->drag.dragImplicitGrabSerial, buttonPressSpy.first().first().value<quint32>());
QVERIFY(dragEnteredSpy.wait());
QVERIFY(dragEnteredSpy.count() || dragEnteredSpy.wait());
QCOMPARE(dragEnteredSpy.count(), 1);
QCOMPARE(dragEnteredSpy.first().first().value<quint32>(), m_display->serial());
QCOMPARE(dragEnteredSpy.first().last().toPointF(), QPointF(0, 0));
@ -452,7 +452,6 @@ void TestDragAndDrop::testDragAndDropWithCancelByDestroyDataSource()
// verify that we did not get any further input events
QVERIFY(pointerMotionSpy.isEmpty());
QCOMPARE(buttonPressSpy.count(), 2);
}
void TestDragAndDrop::testPointerEventsIgnored()
@ -528,14 +527,12 @@ void TestDragAndDrop::testPointerEventsIgnored()
m_seatInterface->notifyPointerButton(1, PointerButtonState::Released);
m_seatInterface->notifyPointerFrame();
QVERIFY(cancelledSpy.wait());
QVERIFY(pointerLeftSpy.count() || pointerLeftSpy.wait());
// all the changes should have been ignored
QCOMPARE(axisSpy.count(), 1);
QCOMPARE(pointerMotionSpy.count(), 1);
QCOMPARE(pointerEnteredSpy.count(), 1);
QVERIFY(pointerLeftSpy.isEmpty());
// the release event is sent primary for xwayland, see BUG 465444
QCOMPARE(buttonSpy.count(), 2);
}
QTEST_GUILESS_MAIN(TestDragAndDrop)

View File

@ -81,7 +81,6 @@ void TestWaylandServerDisplay::testClientConnection()
QVERIFY(client);
QVERIFY(connectedSpy.isEmpty());
QVERIFY(display.connections().isEmpty());
ClientConnection *connection = display.getConnection(client);
QVERIFY(connection);
QCOMPARE(connection->client(), client);
@ -101,8 +100,6 @@ void TestWaylandServerDisplay::testClientConnection()
QCOMPARE((wl_client *)constRef, client);
QCOMPARE(connectedSpy.count(), 1);
QCOMPARE(connectedSpy.first().first().value<ClientConnection *>(), connection);
QCOMPARE(display.connections().count(), 1);
QCOMPARE(display.connections().first(), connection);
QCOMPARE(connection, display.getConnection(client));
QCOMPARE(connectedSpy.count(), 1);
@ -119,10 +116,6 @@ void TestWaylandServerDisplay::testClientConnection()
QCOMPARE(connectedSpy.first().first().value<ClientConnection *>(), connection);
QCOMPARE(connectedSpy.last().first().value<ClientConnection *>(), connection2);
QCOMPARE(connectedSpy.last().first().value<ClientConnection *>(), client2);
QCOMPARE(display.connections().count(), 2);
QCOMPARE(display.connections().first(), connection);
QCOMPARE(display.connections().last(), connection2);
QCOMPARE(display.connections().last(), client2);
// and destroy
QVERIFY(disconnectedSpy.isEmpty());
@ -136,7 +129,6 @@ void TestWaylandServerDisplay::testClientConnection()
close(sv[1]);
close(sv2[0]);
close(sv2[1]);
QVERIFY(display.connections().isEmpty());
}
void TestWaylandServerDisplay::testConnectNoSocket()

View File

@ -9,11 +9,13 @@
// read additional window rules and add them to kwinrulesrc
#include <KConfig>
#include <KConfigGroup>
#include <QCoreApplication>
#include <QDBusConnection>
#include <QDBusMessage>
#include <QDebug>
#include <QStandardPaths>
#include <QtDBus>
#include <kconfig.h>
#include <kconfiggroup.h>
int main(int argc, char *argv[])
{

View File

@ -12,13 +12,18 @@
"Name[eo]": "Reala Nomo",
"Name[es]": "Nombre real",
"Name[eu]": "Benetako izena",
"Name[fi]": "Oikea nimi",
"Name[fr]": "Nom réel",
"Name[gl]": "Nome real.",
"Name[he]": "שם אמיתי",
"Name[hu]": "Valódi név",
"Name[ia]": "Nomine real",
"Name[is]": "Raunverulegt nafn",
"Name[it]": "Nome reale",
"Name[ja]": "作者の名前",
"Name[ka]": "ნამდვილი სახელი",
"Name[ko]": "실제 이름",
"Name[lt]": "Tikras vardas",
"Name[nl]": "Echte naam",
"Name[pl]": "Rzeczywista nazwa",
"Name[ru]": "Настоящее имя",
@ -41,13 +46,18 @@
"Description[eo]": "Rapida Efiko",
"Description[es]": "Efecto rápido",
"Description[eu]": "Efektu azkarra",
"Description[fi]": "Pikatehoste",
"Description[fr]": "Effet rapide",
"Description[gl]": "Efectos rápidos.",
"Description[he]": "אפקט מהיר",
"Description[hu]": "Gyors effektus",
"Description[ia]": "Effecto Rapide",
"Description[is]": "Skyndiáhrif",
"Description[it]": "Effetto rapido",
"Description[ja]": "クイック効果",
"Description[ka]": "სწრაფი ეფექტი",
"Description[ko]": "빠른 효과",
"Description[lt]": "Quick efektas",
"Description[nl]": "Snel-effect",
"Description[pl]": "Szybki Efekt",
"Description[ru]": "Быстрый эффект",
@ -69,13 +79,18 @@
"Name[eo]": "Rapida Efiko",
"Name[es]": "Efecto rápido",
"Name[eu]": "Efektu azkarra",
"Name[fi]": "Pikatehoste",
"Name[fr]": "Effet rapide",
"Name[gl]": "Efectos rápidos",
"Name[he]": "אפקט מהיר",
"Name[hu]": "Gyors effektus",
"Name[ia]": "Effecto Rapide",
"Name[is]": "Skyndiáhrif",
"Name[it]": "Effetto rapido",
"Name[ja]": "クイック効果",
"Name[ka]": "სწრაფი ეფექტი",
"Name[ko]": "빠른 효과",
"Name[lt]": "Quick efektas",
"Name[nl]": "Snel-effect",
"Name[pl]": "Szybki Efekt",
"Name[ru]": "Быстрый эффект",

View File

@ -1,7 +1,20 @@
# SPDX-FileCopyrightText: 2023 Niccolò Venerandi <niccolo.venerandi@kde.org>
# SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL
add_executable(kwin-6.0-delete-desktop-switching-shortcuts)
target_sources(kwin-6.0-delete-desktop-switching-shortcuts PRIVATE kwin-6.0-delete-desktop-switching-shortcuts.cpp)
target_link_libraries(kwin-6.0-delete-desktop-switching-shortcuts PRIVATE KF6::GlobalAccel)
install(TARGETS kwin-6.0-delete-desktop-switching-shortcuts DESTINATION ${KDE_INSTALL_LIBDIR}/kconf_update_bin/)
add_executable(kwin-6.0-reset-active-mouse-screen)
target_sources(kwin-6.0-reset-active-mouse-screen PRIVATE kwin-6.0-reset-active-mouse-screen.cpp)
target_link_libraries(kwin-6.0-reset-active-mouse-screen PRIVATE KF6::ConfigCore)
install(TARGETS kwin-6.0-reset-active-mouse-screen DESTINATION ${KDE_INSTALL_LIBDIR}/kconf_update_bin/)
add_executable(kwin-6.0-remove-breeze-tabbox-default)
target_sources(kwin-6.0-remove-breeze-tabbox-default PRIVATE kwin-6.0-remove-breeze-tabbox-default.cpp)
target_link_libraries(kwin-6.0-remove-breeze-tabbox-default PRIVATE KF6::ConfigCore)
install(TARGETS kwin-6.0-remove-breeze-tabbox-default DESTINATION ${KDE_INSTALL_LIBDIR}/kconf_update_bin/)
install(FILES kwin.upd
DESTINATION ${KDE_INSTALL_KCONFUPDATEDIR})
install(PROGRAMS kwin-6.0-overview-activities-shortcuts.py
DESTINATION ${KDE_INSTALL_KCONFUPDATEDIR})

View File

@ -0,0 +1,34 @@
/*
SPDX-FileCopyrightText: 2023 Marco Martin <mart@kde.org>
SPDX-License-Identifier: GPL-2.0-or-later
*/
#include <KGlobalAccel>
#include <QAction>
#include <QGuiApplication>
#include <QStandardPaths>
int main(int argc, char **argv)
{
QGuiApplication app(argc, argv);
const QStringList actionNames{
QStringLiteral("Walk Through Desktops"),
QStringLiteral("Walk Through Desktops (Reverse)"),
QStringLiteral("Walk Through Desktop List"),
QStringLiteral("Walk Through Desktop List (Reverse)"),
};
for (const QString &actionName : actionNames) {
QAction action;
action.setObjectName(actionName);
action.setProperty("componentName", QStringLiteral("kwin"));
action.setProperty("componentDisplayName", QStringLiteral("KWin"));
KGlobalAccel::self()->setShortcut(&action, {QKeySequence()}, KGlobalAccel::NoAutoloading);
KGlobalAccel::self()->removeAllShortcuts(&action);
}
return 0;
}

View File

@ -1,20 +0,0 @@
#!/usr/bin/env python3
# SPDX-FileCopyrightText: 2023 Niccolò Venerandi <niccolo.venerandi@kde.org>
# SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL
import fileinput
for line in fileinput.input():
if line.startswith('next activity'):
print(line.replace('Meta+Tab', 'Meta+A'))
elif line.startswith('previous activity'):
print(line.replace('Meta+Shift+Tab', 'Meta+Shift+A'))
elif line.startswith('ShowDesktopGrid'):
pass
elif line.startswith('Overview'):
print('Overview=Meta+W,Meta+W,Toggle Overview')
print('Cycle Overview=Meta+Tab,Meta+Tab,Cycle through Overview and Grid View')
print('Cycle Overview Opposite=Meta+Shift+Tab,Meta+Shift+Tab,Cycle through Grid View and Overview')
print('Grid View=Meta+G,Meta+G,Toggle Grid View')
else:
print(line)

View File

@ -0,0 +1,40 @@
/*
SPDX-FileCopyrightText: 2024 Vlad Zahorodnii <vlad.zahorodnii@kde.org>
SPDX-License-Identifier: GPL-2.0-or-later
*/
#include <KConfigGroup>
#include <KSharedConfig>
int main()
{
KConfig config(QStandardPaths::writableLocation(QStandardPaths::GenericConfigLocation) + QLatin1String("/kdedefaults/kwinrc"), KConfig::SimpleConfig);
KConfigGroup windows = config.group(QStringLiteral("TabBox"));
bool needsSync = false;
if (!windows.exists()) {
return EXIT_SUCCESS;
}
if (windows.hasKey(QStringLiteral("LayoutName")) && windows.readEntry(QStringLiteral("LayoutName"), QString()) == QString("org.kde.breeze.desktop")) {
windows.deleteEntry(QStringLiteral("LayoutName"));
needsSync = true;
}
if (windows.hasKey(QStringLiteral("DesktopListLayout"))) {
windows.deleteEntry(QStringLiteral("DesktopListLayout"));
needsSync = true;
}
if (windows.hasKey(QStringLiteral("DesktopLayout"))) {
windows.deleteEntry(QStringLiteral("DesktopLayout"));
needsSync = true;
}
if (needsSync) {
return windows.sync() ? EXIT_SUCCESS : EXIT_FAILURE;
} else {
return EXIT_SUCCESS;
}
}

View File

@ -0,0 +1,26 @@
/*
SPDX-FileCopyrightText: 2024 Vlad Zahorodnii <vlad.zahorodnii@kde.org>
SPDX-License-Identifier: GPL-2.0-or-later
*/
#include <KConfigGroup>
#include <KSharedConfig>
int main()
{
auto config = KSharedConfig::openConfig(QStringLiteral("kwinrc"));
KConfigGroup windows = config->group(QStringLiteral("Windows"));
if (!windows.exists()) {
return EXIT_SUCCESS;
}
if (!windows.hasKey(QStringLiteral("ActiveMouseScreen"))) {
return EXIT_SUCCESS;
}
windows.deleteEntry(QStringLiteral("ActiveMouseScreen"));
return windows.sync() ? EXIT_SUCCESS : EXIT_FAILURE;
}

View File

@ -1,11 +1,16 @@
# SPDX-FileCopyrightText: 2023 Niccolò Venerandi <niccolo.venerandi@kde.org>
# SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL
Version=5
Version=6
# Changes the default Activities shortcut from Meta+Tab to Meta+A,
# so that the Overview can take its place
Id=change-activities-overview-shortcuts
File=kglobalshortcutsrc
Group=plasmashell,kwin
Script=kwin-6.0-overview-activities-shortcuts.py,python3
# Reset ActiveMouseScreen config option.
Id=kwin-6.0-reset-active-mouse-screen
Script=kwin-6.0-reset-active-mouse-screen
# Delete old desktop switching shortcuts.
Id=kwin-6.0-delete-desktop-switching-shortcuts
Script=kwin-6.0-delete-desktop-switching-shortcuts
# Delete old tabbox defaults
Id=kwin-6.0-remove-breeze-tabbox-default
Script=kwin-6.0-remove-breeze-tabbox-default

View File

@ -5,7 +5,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kcmkwindecoration stable\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-08-06 02:04+0000\n"
"POT-Creation-Date: 2024-01-14 03:08+0000\n"
"PO-Revision-Date: 2005-06-18 11:28+0200\n"
"Last-Translator: JUANITA FRANZ <JUANITA.FRANZ@VR-WEB.DE>\n"
"Language-Team: AFRIKAANS <translate-discuss-af@lists.sourceforge.net>\n"
@ -66,7 +66,7 @@ msgstr ""
msgid "Keep above other windows"
msgstr ""
#: kcm.cpp:176
#: kcm.cpp:177
#, kde-format
msgctxt "%1 is the name of a border size"
msgid "Theme's default (%1)"

View File

@ -3,7 +3,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kcmkwinrules stable\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-12-08 01:36+0000\n"
"POT-Creation-Date: 2024-02-17 02:27+0000\n"
"PO-Revision-Date: 2005-11-26 16:33+0200\n"
"Last-Translator: Ilze Thirion <ilze.thirion@gmail.com>\n"
"Language-Team: AFRIKAANS <translate-discuss-af@lists.sourceforge.net>\n"
@ -274,7 +274,7 @@ msgstr "Aktiewe opacity in %"
msgid "Screen"
msgstr "Spat Skerm"
#: rulesmodel.cpp:513
#: rulesmodel.cpp:513 rulesmodel.cpp:922
#, fuzzy, kde-format
#| msgid "&Fullscreen"
msgid "Fullscreen"
@ -411,7 +411,7 @@ msgstr ""
#: rulesmodel.cpp:609 rulesmodel.cpp:614 rulesmodel.cpp:620 rulesmodel.cpp:625
#: rulesmodel.cpp:631 rulesmodel.cpp:658 rulesmodel.cpp:686 rulesmodel.cpp:692
#: rulesmodel.cpp:704 rulesmodel.cpp:709 rulesmodel.cpp:715 rulesmodel.cpp:720
#: rulesmodel.cpp:704 rulesmodel.cpp:709 rulesmodel.cpp:714 rulesmodel.cpp:719
#, kde-format
msgid "Appearance & Fixes"
msgstr ""
@ -527,21 +527,20 @@ msgid "Closeable"
msgstr "Toemaakbaar"
#: rulesmodel.cpp:709
#, fuzzy, kde-format
#| msgid "Window &type"
msgid "Set window type"
msgstr "Venster tipe"
#: rulesmodel.cpp:715
#, kde-format
msgid "Desktop file name"
msgstr ""
#: rulesmodel.cpp:720
#: rulesmodel.cpp:714
#, kde-format
msgid "Block compositing"
msgstr ""
#: rulesmodel.cpp:719
#, kde-format
msgid "Layer"
msgstr ""
#: rulesmodel.cpp:772
#, fuzzy, kde-format
#| msgid "Window &class (application type):"
@ -599,7 +598,7 @@ msgstr "Afskeur kieslys"
msgid "Splash Screen"
msgstr "Spat Skerm"
#: rulesmodel.cpp:815
#: rulesmodel.cpp:815 rulesmodel.cpp:917
#, kde-format
msgid "Desktop"
msgstr "Werkskerm"
@ -695,7 +694,7 @@ msgstr "Geen"
msgid "Low"
msgstr "Laag"
#: rulesmodel.cpp:889
#: rulesmodel.cpp:889 rulesmodel.cpp:919
#, kde-format
msgid "Normal"
msgstr "Normaal"
@ -710,13 +709,49 @@ msgstr "Hoog"
msgid "Extreme"
msgstr "Buitensporige"
#: rulesmodel.cpp:934
#: rulesmodel.cpp:918
#, kde-format
msgid "Below"
msgstr ""
#: rulesmodel.cpp:920
#, kde-format
msgid "Above"
msgstr ""
#: rulesmodel.cpp:921
#, fuzzy, kde-format
#| msgid "&Position"
msgid "Notification"
msgstr "Posisie"
#: rulesmodel.cpp:923
#, kde-format
msgid "Popup"
msgstr ""
#: rulesmodel.cpp:924
#, kde-format
msgid "Critical Notification"
msgstr ""
#: rulesmodel.cpp:925
#, kde-format
msgid "OSD"
msgstr ""
#: rulesmodel.cpp:926
#, kde-format
msgid "Overlay"
msgstr ""
#: rulesmodel.cpp:951
#, fuzzy, kde-format
#| msgid "On Main Window"
msgid "Unmanaged window"
msgstr "Op Hoof Venster"
#: rulesmodel.cpp:935
#: rulesmodel.cpp:952
#, kde-format
msgid "Could not detect window properties. The window is not managed by KWin."
msgstr ""
@ -875,29 +910,29 @@ msgstr[1] ""
msgid "Add property to the rule"
msgstr ""
#: ui/RulesEditor.qml:278 ui/ValueEditor.qml:54
#: ui/RulesEditor.qml:279 ui/ValueEditor.qml:54
#, kde-format
msgid "Yes"
msgstr ""
#: ui/RulesEditor.qml:278 ui/ValueEditor.qml:60
#: ui/RulesEditor.qml:279 ui/ValueEditor.qml:60
#, fuzzy, kde-format
#| msgid "None"
msgid "No"
msgstr "Geen"
#: ui/RulesEditor.qml:280 ui/ValueEditor.qml:168 ui/ValueEditor.qml:175
#: ui/RulesEditor.qml:281 ui/ValueEditor.qml:168 ui/ValueEditor.qml:175
#, kde-format
msgid "%1 %"
msgstr ""
#: ui/RulesEditor.qml:282
#: ui/RulesEditor.qml:283
#, kde-format
msgctxt "Coordinates (x, y)"
msgid "(%1, %2)"
msgstr ""
#: ui/RulesEditor.qml:284
#: ui/RulesEditor.qml:285
#, kde-format
msgctxt "Size (width, height)"
msgid "(%1, %2)"
@ -909,6 +944,11 @@ msgctxt "(x, y) coordinates separator in size/position"
msgid "x"
msgstr ""
#, fuzzy
#~| msgid "Window &type"
#~ msgid "Set window type"
#~ msgstr "Venster tipe"
#~ msgid "This helper utility is not supposed to be called directly."
#~ msgstr ""
#~ "Hierdie helper nutsprogramme is nie veronderstel om direk geroep te word "

View File

@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kcmkwm stable\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-11-02 01:40+0000\n"
"POT-Creation-Date: 2024-02-06 03:08+0000\n"
"PO-Revision-Date: 2005-11-25 19:56+0200\n"
"Last-Translator: Kobus Venter <kabousv@therugby.co.za>\n"
"Language-Team: AFRIKAANS <translate-discuss-af@lists.sourceforge.net>\n"
@ -944,23 +944,8 @@ msgstr ""
msgid "Multiscreen behavior:"
msgstr ""
#. i18n: ectx: property (whatsThis), widget (QCheckBox, kcfg_ActiveMouseScreen)
#: focus.ui:203
#, kde-format
msgid ""
"When this option is enabled, the active screen (where new windows appear, "
"for example) is the screen containing the mouse pointer. When disabled, the "
"active screen is the screen containing the focused window."
msgstr ""
#. i18n: ectx: property (text), widget (QCheckBox, kcfg_ActiveMouseScreen)
#: focus.ui:206
#, kde-format
msgid "Active screen follows &mouse"
msgstr ""
#. i18n: ectx: property (whatsThis), widget (QCheckBox, kcfg_SeparateScreenFocus)
#: focus.ui:213
#: focus.ui:203
#, kde-format
msgid ""
"When this option is enabled, focus operations are limited only to the active "
@ -968,13 +953,13 @@ msgid ""
msgstr ""
#. i18n: ectx: property (text), widget (QCheckBox, kcfg_SeparateScreenFocus)
#: focus.ui:216
#: focus.ui:206
#, kde-format
msgid "&Separate screen focus"
msgstr ""
#. i18n: ectx: property (text), widget (QLabel, windowFocusPolicyDescriptionLabel)
#: focus.ui:229
#: focus.ui:219
#, kde-format
msgid "Window activation policy description"
msgstr ""
@ -1314,14 +1299,14 @@ msgstr ""
msgid "Only when overlapping"
msgstr "Klamp vensters slegs wanneer oorvleuel"
#: windows.cpp:93
#: windows.cpp:92
#, kde-format
msgid ""
"<em>Click to focus:</em> A window becomes active when you click into it. "
"This behavior is common on other operating systems and likely what you want."
msgstr ""
#: windows.cpp:96
#: windows.cpp:95
#, kde-format
msgid ""
"<em>Click to focus (mouse precedence):</em> Mostly the same as <em>Click to "
@ -1331,7 +1316,7 @@ msgid ""
"em>."
msgstr ""
#: windows.cpp:99
#: windows.cpp:98
#, kde-format
msgid ""
"<em>Focus follows mouse:</em> Moving the mouse onto a window will activate "
@ -1340,7 +1325,7 @@ msgid ""
"to focus</em> just without having to actually click."
msgstr ""
#: windows.cpp:102
#: windows.cpp:101
#, kde-format
msgid ""
"This is mostly the same as <em>Focus follows mouse</em>. If an active window "
@ -1349,7 +1334,7 @@ msgid ""
"if you want a hover controlled focus."
msgstr ""
#: windows.cpp:105
#: windows.cpp:104
#, kde-format
msgid ""
"<em>Focus under mouse:</em> The focus always remains on the window under the "
@ -1359,7 +1344,7 @@ msgid ""
"precedence)</em> instead!"
msgstr ""
#: windows.cpp:108
#: windows.cpp:107
#, kde-format
msgid ""
"<em>Focus strictly under mouse:</em> The focus is always on the window under "

File diff suppressed because it is too large Load Diff

View File

@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-06-21 02:02+0000\n"
"POT-Creation-Date: 2024-01-14 03:08+0000\n"
"PO-Revision-Date: 2023-06-08 12:05+0400\n"
"Last-Translator: Zayed Al-Saidi <zayed.alsaidi@gmail.com>\n"
"Language-Team: ar\n"
@ -18,17 +18,17 @@ msgstr ""
"&& n%100<=10 ? 3 : n%100>=11 && n%100<=99 ? 4 : 5;\n"
"X-Generator: Lokalize 22.12.3\n"
#: module.cpp:50
#: module.cpp:49
#, kde-format
msgid "Import KWin Script"
msgstr "استورد سكرِبت نوافذك"
#: module.cpp:51
#: module.cpp:50
#, kde-format
msgid "*.kwinscript|KWin scripts (*.kwinscript)"
msgstr "*.kwinscript|سكرِبتات نوافذك (*.kwinscript)"
#: module.cpp:62
#: module.cpp:61
#, kde-format
msgctxt "Placeholder is error message returned from the install service"
msgid ""
@ -38,13 +38,13 @@ msgstr ""
"لا يمكن استيراد السكربت المحدد.\n"
"%1"
#: module.cpp:66
#: module.cpp:65
#, kde-format
msgctxt "Placeholder is name of the script that was imported"
msgid "The script \"%1\" was successfully imported."
msgstr "استورد السّكرِبت \"%1\" بنجاح."
#: module.cpp:125
#: module.cpp:124
#, kde-format
msgid "Error when uninstalling KWin Script: %1"
msgstr "خطأ عند إلغاء تثبيت سكربت كوين: %1"

View File

@ -14,7 +14,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kcmkwindecoration\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-08-06 02:04+0000\n"
"POT-Creation-Date: 2024-01-14 03:08+0000\n"
"PO-Revision-Date: 2023-04-06 12:35+0400\n"
"Last-Translator: Zayed Al-Saidi <zayed.alsaidi@gmail.com>\n"
"Language-Team: ar\n"
@ -76,7 +76,7 @@ msgstr "أبقها أسفل النوافذ الأخرى"
msgid "Keep above other windows"
msgstr "أبقها أعلى النوافذ الأخرى"
#: kcm.cpp:176
#: kcm.cpp:177
#, kde-format
msgctxt "%1 is the name of a border size"
msgid "Theme's default (%1)"

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kcmkwinrules\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-12-08 01:36+0000\n"
"POT-Creation-Date: 2024-02-17 02:27+0000\n"
"PO-Revision-Date: 2023-06-08 12:05+0400\n"
"Last-Translator: Zayed Al-Saidi <zayed.alsaidi@gmail.com>\n"
"Language-Team: ar\n"
@ -277,7 +277,7 @@ msgstr "الأنشطة"
msgid "Screen"
msgstr "الشّاشة"
#: rulesmodel.cpp:513
#: rulesmodel.cpp:513 rulesmodel.cpp:922
#, kde-format
msgid "Fullscreen"
msgstr "ملء الشّاشة"
@ -418,7 +418,7 @@ msgstr "بدون شريط العنوان والإطار"
#: rulesmodel.cpp:609 rulesmodel.cpp:614 rulesmodel.cpp:620 rulesmodel.cpp:625
#: rulesmodel.cpp:631 rulesmodel.cpp:658 rulesmodel.cpp:686 rulesmodel.cpp:692
#: rulesmodel.cpp:704 rulesmodel.cpp:709 rulesmodel.cpp:715 rulesmodel.cpp:720
#: rulesmodel.cpp:704 rulesmodel.cpp:709 rulesmodel.cpp:714 rulesmodel.cpp:719
#, kde-format
msgid "Appearance & Fixes"
msgstr "المظهر والإصلاحات"
@ -564,19 +564,19 @@ msgstr "قابلة للإغلاق"
#: rulesmodel.cpp:709
#, kde-format
msgid "Set window type"
msgstr "حدد نوع النافذة"
#: rulesmodel.cpp:715
#, kde-format
msgid "Desktop file name"
msgstr "اسم ملف سطح المكتب"
#: rulesmodel.cpp:720
#: rulesmodel.cpp:714
#, kde-format
msgid "Block compositing"
msgstr "التركيب الكتلي"
#: rulesmodel.cpp:719
#, kde-format
msgid "Layer"
msgstr ""
#: rulesmodel.cpp:772
#, kde-format
msgid "Window class not available"
@ -636,7 +636,7 @@ msgstr "قائمة ممزقة"
msgid "Splash Screen"
msgstr "شاشة البداية"
#: rulesmodel.cpp:815
#: rulesmodel.cpp:815 rulesmodel.cpp:917
#, kde-format
msgid "Desktop"
msgstr "سطح المكتب"
@ -729,7 +729,7 @@ msgstr "لا شيء"
msgid "Low"
msgstr "منخفض"
#: rulesmodel.cpp:889
#: rulesmodel.cpp:889 rulesmodel.cpp:919
#, kde-format
msgid "Normal"
msgstr "عادي"
@ -744,12 +744,48 @@ msgstr "عالي"
msgid "Extreme"
msgstr "قصوى"
#: rulesmodel.cpp:934
#: rulesmodel.cpp:918
#, kde-format
msgid "Below"
msgstr ""
#: rulesmodel.cpp:920
#, kde-format
msgid "Above"
msgstr ""
#: rulesmodel.cpp:921
#, fuzzy, kde-format
#| msgid "Position"
msgid "Notification"
msgstr "الموقع"
#: rulesmodel.cpp:923
#, kde-format
msgid "Popup"
msgstr ""
#: rulesmodel.cpp:924
#, kde-format
msgid "Critical Notification"
msgstr ""
#: rulesmodel.cpp:925
#, kde-format
msgid "OSD"
msgstr ""
#: rulesmodel.cpp:926
#, kde-format
msgid "Overlay"
msgstr ""
#: rulesmodel.cpp:951
#, kde-format
msgid "Unmanaged window"
msgstr "نافذة غير مدارة"
#: rulesmodel.cpp:935
#: rulesmodel.cpp:952
#, kde-format
msgid "Could not detect window properties. The window is not managed by KWin."
msgstr "لا يمكن اكتشاف خواص النافذة. لا تدار النافذة بواسطة كوين."
@ -912,28 +948,28 @@ msgstr[5] "بعد %1 ثانية"
msgid "Add property to the rule"
msgstr "أضف خاصية للقاعدة"
#: ui/RulesEditor.qml:278 ui/ValueEditor.qml:54
#: ui/RulesEditor.qml:279 ui/ValueEditor.qml:54
#, kde-format
msgid "Yes"
msgstr "نعم"
#: ui/RulesEditor.qml:278 ui/ValueEditor.qml:60
#: ui/RulesEditor.qml:279 ui/ValueEditor.qml:60
#, kde-format
msgid "No"
msgstr "لا"
#: ui/RulesEditor.qml:280 ui/ValueEditor.qml:168 ui/ValueEditor.qml:175
#: ui/RulesEditor.qml:281 ui/ValueEditor.qml:168 ui/ValueEditor.qml:175
#, kde-format
msgid "%1 %"
msgstr "%1 ٪"
#: ui/RulesEditor.qml:282
#: ui/RulesEditor.qml:283
#, kde-format
msgctxt "Coordinates (x, y)"
msgid "(%1, %2)"
msgstr "(%1، %2)"
#: ui/RulesEditor.qml:284
#: ui/RulesEditor.qml:285
#, kde-format
msgctxt "Size (width, height)"
msgid "(%1, %2)"
@ -945,6 +981,9 @@ msgctxt "(x, y) coordinates separator in size/position"
msgid "x"
msgstr "×"
#~ msgid "Set window type"
#~ msgstr "حدد نوع النافذة"
#~ msgid "Window shall (not) appear in the taskbar."
#~ msgstr "لا/يجب أن تظهر النافذة في شريط المهام."

View File

@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-12-20 01:35+0000\n"
"POT-Creation-Date: 2024-01-14 03:08+0000\n"
"PO-Revision-Date: 2023-02-16 12:17+0400\n"
"Last-Translator: Zayed Al-Saidi <zayed.alsaidi@gmail.com>\n"
"Language-Team: ar\n"
@ -18,33 +18,33 @@ msgstr ""
"&& n%100<=10 ? 3 : n%100>=11 && n%100<=99 ? 4 : 5;\n"
"X-Generator: Lokalize 21.12.3\n"
#: layoutpreview.cpp:131
#: layoutpreview.cpp:127
#, kde-format
msgid "Show Desktop"
msgstr "أظهر سطح المكتب"
#: layoutpreview.cpp:161
#: layoutpreview.cpp:157
#, kde-format
msgctxt "An example Desktop Name"
msgid "Desktop 1"
msgstr "سطح المكتب 1"
#: main.cpp:67
#: main.cpp:66
#, kde-format
msgid "Main"
msgstr "الرّئيسيّ"
#: main.cpp:68
#: main.cpp:67
#, kde-format
msgid "Alternative"
msgstr "البديل"
#: main.cpp:70
#: main.cpp:69
#, kde-format
msgid "Get New Task Switchers..."
msgstr "احصل على مُبدِّل مهام جديد"
#: main.cpp:84
#: main.cpp:83
#, kde-format
msgid ""
"Focus policy settings limit the functionality of navigating through windows."

View File

@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kcmkwinscreenedges\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-12-20 01:35+0000\n"
"POT-Creation-Date: 2024-01-19 02:29+0000\n"
"PO-Revision-Date: 2022-08-08 21:54+0400\n"
"Last-Translator: Zayed Al-Saidi <zayed.alsaidi@gmail.com>\n"
"Language-Team: Arabic <kde-l10n-ar@kde.org>\n"
@ -18,68 +18,68 @@ msgstr ""
"&& n%100<=10 ? 3 : n%100>=11 && n%100<=99 ? 4 : 5;\n"
"X-Generator: Lokalize 21.07.70\n"
#: main.cpp:151 touch.cpp:117
#: main.cpp:151 touch.cpp:118
#, kde-format
msgid "No Action"
msgstr "لا إجراء"
#: main.cpp:152 touch.cpp:118
#: main.cpp:152 touch.cpp:119
#, kde-format
msgid "Peek at Desktop"
msgstr "نظرة على سطح المكتب"
#: main.cpp:153 touch.cpp:119
#: main.cpp:153 touch.cpp:120
#, kde-format
msgid "Lock Screen"
msgstr "اقفل الشّاشة"
#: main.cpp:154 touch.cpp:120
#: main.cpp:154 touch.cpp:121
#, kde-format
msgid "Show KRunner"
msgstr "أظهر مشغل.ك"
#: main.cpp:155 touch.cpp:121
#: main.cpp:155 touch.cpp:122
#, kde-format
msgid "Activity Manager"
msgstr "مدير الأنشطة"
#: main.cpp:156 touch.cpp:122
#: main.cpp:156 touch.cpp:123
#, kde-format
msgid "Application Launcher"
msgstr "مُطلق التّطبيقات"
#: main.cpp:160 touch.cpp:126
#: main.cpp:160 touch.cpp:127
#, kde-format
msgid "Present Windows"
msgstr "النوافذ الحاضرة"
#: main.cpp:161 touch.cpp:127
#: main.cpp:161 touch.cpp:128
#, kde-format
msgid "%1 - All Desktops"
msgstr "%1 - كلّ أسطح المكتب"
#: main.cpp:162 touch.cpp:128
#: main.cpp:162 touch.cpp:129
#, kde-format
msgid "%1 - Current Desktop"
msgstr "%1 - سطح المكتب الحاليّ"
#: main.cpp:163 touch.cpp:129
#: main.cpp:163 touch.cpp:130
#, kde-format
msgid "%1 - Current Application"
msgstr "%1 - التّطبيق الحاليّ"
#: main.cpp:165
#: main.cpp:165 touch.cpp:132
#, fuzzy, kde-format
#| msgid "Toggle Overview"
msgid "Overview"
msgstr "بدل النظرة العامة"
#: main.cpp:167 touch.cpp:131
#: main.cpp:167 touch.cpp:134
#, kde-format
msgid "Toggle window switching"
msgstr "بدّل تنقل النوافذ"
#: main.cpp:168 touch.cpp:132
#: main.cpp:168 touch.cpp:135
#, kde-format
msgid "Toggle alternative window switching"
msgstr "بدّل تنقل النوافذ البديل"

View File

@ -12,7 +12,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kcmkwm\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-11-02 01:40+0000\n"
"POT-Creation-Date: 2024-02-06 03:08+0000\n"
"PO-Revision-Date: 2022-12-22 11:14+0400\n"
"Last-Translator: Zayed Al-Saidi <zayed.alsaidi@gmail.com>\n"
"Language-Team: ar\n"
@ -878,26 +878,8 @@ msgstr ""
msgid "Multiscreen behavior:"
msgstr "سلوك الشاشات المتعددة:"
#. i18n: ectx: property (whatsThis), widget (QCheckBox, kcfg_ActiveMouseScreen)
#: focus.ui:203
#, kde-format
msgid ""
"When this option is enabled, the active screen (where new windows appear, "
"for example) is the screen containing the mouse pointer. When disabled, the "
"active screen is the screen containing the focused window."
msgstr ""
"عند تمكين هذا الخيار ، تكون الشاشة النشطة (حيث تظهر النوافذ الجديدة ، على "
"سبيل المثال) هي الشاشة التي تحتوي على مؤشر الفأرة. عند التعطيل ، تكون الشاشة "
"النشطة هي الشاشة التي تحتوي على النافذة المركزة."
#. i18n: ectx: property (text), widget (QCheckBox, kcfg_ActiveMouseScreen)
#: focus.ui:206
#, kde-format
msgid "Active screen follows &mouse"
msgstr "الشاشة النشطة تتبع ال&فأرة"
#. i18n: ectx: property (whatsThis), widget (QCheckBox, kcfg_SeparateScreenFocus)
#: focus.ui:213
#: focus.ui:203
#, kde-format
msgid ""
"When this option is enabled, focus operations are limited only to the active "
@ -906,13 +888,13 @@ msgstr ""
"إذا تم تمكين هذا الخيار ، عمليات التركيز ستكون محدودة فقط في الشاشة النشطة"
#. i18n: ectx: property (text), widget (QCheckBox, kcfg_SeparateScreenFocus)
#: focus.ui:216
#: focus.ui:206
#, kde-format
msgid "&Separate screen focus"
msgstr "اف&صل تركيز الشاشة"
#. i18n: ectx: property (text), widget (QLabel, windowFocusPolicyDescriptionLabel)
#: focus.ui:229
#: focus.ui:219
#, kde-format
msgid "Window activation policy description"
msgstr "وصف سياسة تنشيط النافذة"
@ -1217,7 +1199,7 @@ msgstr ""
msgid "Only when overlapping"
msgstr "فقط عندما تكون تغطي بعضها"
#: windows.cpp:93
#: windows.cpp:92
#, kde-format
msgid ""
"<em>Click to focus:</em> A window becomes active when you click into it. "
@ -1226,7 +1208,7 @@ msgstr ""
"<em> انقر للتركيز: </em> تصبح النافذة نشطة عندما تنقر عليها.هذا السلوك شائع "
"في أنظمة التشغيل الأخرى وعلى الأرجح ما تريده."
#: windows.cpp:96
#: windows.cpp:95
#, kde-format
msgid ""
"<em>Click to focus (mouse precedence):</em> Mostly the same as <em>Click to "
@ -1240,7 +1222,7 @@ msgstr ""
"بسبب إغلاق النافذة النشطة حاليًا) ، فإن النافذة الموجودة أسفل الفأرة هي "
"المرشح المفضل. هذا غير معتاد ولكنه تنويع ممكن لـ <em> انقر للتركيز </em>."
#: windows.cpp:99
#: windows.cpp:98
#, kde-format
msgid ""
"<em>Focus follows mouse:</em> Moving the mouse onto a window will activate "
@ -1253,7 +1235,7 @@ msgstr ""
"يستمر <em> التركيز على منع السرقة </em> كالمعتاد. إنها تشبه <em> انقر "
"للتركيز </em> دون الحاجة إلى النقر فعليًا."
#: windows.cpp:102
#: windows.cpp:101
#, kde-format
msgid ""
"This is mostly the same as <em>Focus follows mouse</em>. If an active window "
@ -1266,7 +1248,7 @@ msgstr ""
"حاليًا) ، فإن النافذة الموجودة أسفل الفأرة هي المرشح المفضل. اختر هذا ، إذا "
"كنت تريد تركيزًا متحكمًا فيه بواسطة التحويم."
#: windows.cpp:105
#: windows.cpp:104
#, kde-format
msgid ""
"<em>Focus under mouse:</em> The focus always remains on the window under the "
@ -1281,7 +1263,7 @@ msgstr ""
"من المحتمل جدًا أنك تريد استخدام <em> التركيز يتبع الفأرة (أولوية الفأرة) </"
"em> بدلاً من ذلك!"
#: windows.cpp:108
#: windows.cpp:107
#, kde-format
msgid ""
"<em>Focus strictly under mouse:</em> The focus is always on the window under "
@ -1298,6 +1280,18 @@ msgstr ""
"التنشيط ولن تعمل. من المحتمل جدًا أنك تريد استخدام <em> التركيز يتبع الفأرة "
"(أولوية الفأرة) </em> بدلاً من ذلك!"
#~ msgid ""
#~ "When this option is enabled, the active screen (where new windows appear, "
#~ "for example) is the screen containing the mouse pointer. When disabled, "
#~ "the active screen is the screen containing the focused window."
#~ msgstr ""
#~ "عند تمكين هذا الخيار ، تكون الشاشة النشطة (حيث تظهر النوافذ الجديدة ، على "
#~ "سبيل المثال) هي الشاشة التي تحتوي على مؤشر الفأرة. عند التعطيل ، تكون "
#~ "الشاشة النشطة هي الشاشة التي تحتوي على النافذة المركزة."
#~ msgid "Active screen follows &mouse"
#~ msgstr "الشاشة النشطة تتبع ال&فأرة"
#~ msgctxt "NAME OF TRANSLATORS"
#~ msgid "Your names"
#~ msgstr "Mohamed SAAD محمد سعد,زايد السعيدي"

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kwin\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-06-21 02:02+0000\n"
"POT-Creation-Date: 2024-01-14 03:08+0000\n"
"PO-Revision-Date: 2023-05-03 21:12+0200\n"
"Last-Translator: Enol P. <enolp@softastur.org>\n"
"Language-Team: \n"
@ -17,17 +17,17 @@ msgstr ""
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"X-Generator: Lokalize 23.04.0\n"
#: module.cpp:50
#: module.cpp:49
#, kde-format
msgid "Import KWin Script"
msgstr ""
#: module.cpp:51
#: module.cpp:50
#, kde-format
msgid "*.kwinscript|KWin scripts (*.kwinscript)"
msgstr "*.kwinscript|Scripts de KWin (*.kwinscript)"
#: module.cpp:62
#: module.cpp:61
#, kde-format
msgctxt "Placeholder is error message returned from the install service"
msgid ""
@ -35,13 +35,13 @@ msgid ""
"%1"
msgstr ""
#: module.cpp:66
#: module.cpp:65
#, kde-format
msgctxt "Placeholder is name of the script that was imported"
msgid "The script \"%1\" was successfully imported."
msgstr ""
#: module.cpp:125
#: module.cpp:124
#, kde-format
msgid "Error when uninstalling KWin Script: %1"
msgstr ""

View File

@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kwin\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-08-06 02:04+0000\n"
"POT-Creation-Date: 2024-01-14 03:08+0000\n"
"PO-Revision-Date: 2023-05-03 21:12+0200\n"
"Last-Translator: Enol P. <enolp@softastur.org>\n"
"Language-Team: \n"
@ -67,7 +67,7 @@ msgstr ""
msgid "Keep above other windows"
msgstr ""
#: kcm.cpp:176
#: kcm.cpp:177
#, kde-format
msgctxt "%1 is the name of a border size"
msgid "Theme's default (%1)"

View File

@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kwin\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-12-08 01:36+0000\n"
"POT-Creation-Date: 2024-02-17 02:27+0000\n"
"PO-Revision-Date: 2023-11-07 21:27+0100\n"
"Last-Translator: Enol P. <enolp@softastur.org>\n"
"Language-Team: \n"
@ -254,7 +254,7 @@ msgstr ""
msgid "Screen"
msgstr ""
#: rulesmodel.cpp:513
#: rulesmodel.cpp:513 rulesmodel.cpp:922
#, kde-format
msgid "Fullscreen"
msgstr ""
@ -381,7 +381,7 @@ msgstr ""
#: rulesmodel.cpp:609 rulesmodel.cpp:614 rulesmodel.cpp:620 rulesmodel.cpp:625
#: rulesmodel.cpp:631 rulesmodel.cpp:658 rulesmodel.cpp:686 rulesmodel.cpp:692
#: rulesmodel.cpp:704 rulesmodel.cpp:709 rulesmodel.cpp:715 rulesmodel.cpp:720
#: rulesmodel.cpp:704 rulesmodel.cpp:709 rulesmodel.cpp:714 rulesmodel.cpp:719
#, kde-format
msgid "Appearance & Fixes"
msgstr ""
@ -491,19 +491,19 @@ msgstr ""
#: rulesmodel.cpp:709
#, kde-format
msgid "Set window type"
msgstr ""
#: rulesmodel.cpp:715
#, kde-format
msgid "Desktop file name"
msgstr ""
#: rulesmodel.cpp:720
#: rulesmodel.cpp:714
#, kde-format
msgid "Block compositing"
msgstr ""
#: rulesmodel.cpp:719
#, kde-format
msgid "Layer"
msgstr ""
#: rulesmodel.cpp:772
#, kde-format
msgid "Window class not available"
@ -559,7 +559,7 @@ msgstr ""
msgid "Splash Screen"
msgstr ""
#: rulesmodel.cpp:815
#: rulesmodel.cpp:815 rulesmodel.cpp:917
#, kde-format
msgid "Desktop"
msgstr ""
@ -652,7 +652,7 @@ msgstr ""
msgid "Low"
msgstr ""
#: rulesmodel.cpp:889
#: rulesmodel.cpp:889 rulesmodel.cpp:919
#, kde-format
msgid "Normal"
msgstr ""
@ -667,12 +667,47 @@ msgstr ""
msgid "Extreme"
msgstr ""
#: rulesmodel.cpp:934
#: rulesmodel.cpp:918
#, kde-format
msgid "Below"
msgstr ""
#: rulesmodel.cpp:920
#, kde-format
msgid "Above"
msgstr ""
#: rulesmodel.cpp:921
#, kde-format
msgid "Notification"
msgstr ""
#: rulesmodel.cpp:923
#, kde-format
msgid "Popup"
msgstr ""
#: rulesmodel.cpp:924
#, kde-format
msgid "Critical Notification"
msgstr ""
#: rulesmodel.cpp:925
#, kde-format
msgid "OSD"
msgstr ""
#: rulesmodel.cpp:926
#, kde-format
msgid "Overlay"
msgstr ""
#: rulesmodel.cpp:951
#, kde-format
msgid "Unmanaged window"
msgstr ""
#: rulesmodel.cpp:935
#: rulesmodel.cpp:952
#, kde-format
msgid "Could not detect window properties. The window is not managed by KWin."
msgstr ""
@ -825,28 +860,28 @@ msgstr[1] ""
msgid "Add property to the rule"
msgstr ""
#: ui/RulesEditor.qml:278 ui/ValueEditor.qml:54
#: ui/RulesEditor.qml:279 ui/ValueEditor.qml:54
#, kde-format
msgid "Yes"
msgstr "Sí"
#: ui/RulesEditor.qml:278 ui/ValueEditor.qml:60
#: ui/RulesEditor.qml:279 ui/ValueEditor.qml:60
#, kde-format
msgid "No"
msgstr ""
#: ui/RulesEditor.qml:280 ui/ValueEditor.qml:168 ui/ValueEditor.qml:175
#: ui/RulesEditor.qml:281 ui/ValueEditor.qml:168 ui/ValueEditor.qml:175
#, kde-format
msgid "%1 %"
msgstr ""
#: ui/RulesEditor.qml:282
#: ui/RulesEditor.qml:283
#, kde-format
msgctxt "Coordinates (x, y)"
msgid "(%1, %2)"
msgstr ""
#: ui/RulesEditor.qml:284
#: ui/RulesEditor.qml:285
#, kde-format
msgctxt "Size (width, height)"
msgid "(%1, %2)"

View File

@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kwin\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-12-20 01:35+0000\n"
"POT-Creation-Date: 2024-01-14 03:08+0000\n"
"PO-Revision-Date: 2023-11-07 21:27+0100\n"
"Last-Translator: Enol P. <enolp@softastur.org>\n"
"Language-Team: \n"
@ -17,33 +17,33 @@ msgstr ""
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"X-Generator: Lokalize 23.08.2\n"
#: layoutpreview.cpp:131
#: layoutpreview.cpp:127
#, kde-format
msgid "Show Desktop"
msgstr ""
#: layoutpreview.cpp:161
#: layoutpreview.cpp:157
#, kde-format
msgctxt "An example Desktop Name"
msgid "Desktop 1"
msgstr ""
#: main.cpp:67
#: main.cpp:66
#, kde-format
msgid "Main"
msgstr ""
#: main.cpp:68
#: main.cpp:67
#, kde-format
msgid "Alternative"
msgstr ""
#: main.cpp:70
#: main.cpp:69
#, kde-format
msgid "Get New Task Switchers..."
msgstr ""
#: main.cpp:84
#: main.cpp:83
#, kde-format
msgid ""
"Focus policy settings limit the functionality of navigating through windows."

View File

@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kwin\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-12-20 01:35+0000\n"
"POT-Creation-Date: 2024-01-19 02:29+0000\n"
"PO-Revision-Date: 2023-05-03 21:14+0200\n"
"Last-Translator: Enol P. <enolp@softastur.org>\n"
"Language-Team: \n"
@ -17,67 +17,67 @@ msgstr ""
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"X-Generator: Lokalize 23.04.0\n"
#: main.cpp:151 touch.cpp:117
#: main.cpp:151 touch.cpp:118
#, kde-format
msgid "No Action"
msgstr ""
#: main.cpp:152 touch.cpp:118
#: main.cpp:152 touch.cpp:119
#, kde-format
msgid "Peek at Desktop"
msgstr ""
#: main.cpp:153 touch.cpp:119
#: main.cpp:153 touch.cpp:120
#, kde-format
msgid "Lock Screen"
msgstr ""
#: main.cpp:154 touch.cpp:120
#: main.cpp:154 touch.cpp:121
#, kde-format
msgid "Show KRunner"
msgstr ""
#: main.cpp:155 touch.cpp:121
#: main.cpp:155 touch.cpp:122
#, kde-format
msgid "Activity Manager"
msgstr ""
#: main.cpp:156 touch.cpp:122
#: main.cpp:156 touch.cpp:123
#, kde-format
msgid "Application Launcher"
msgstr ""
#: main.cpp:160 touch.cpp:126
#: main.cpp:160 touch.cpp:127
#, kde-format
msgid "Present Windows"
msgstr ""
#: main.cpp:161 touch.cpp:127
#: main.cpp:161 touch.cpp:128
#, kde-format
msgid "%1 - All Desktops"
msgstr ""
#: main.cpp:162 touch.cpp:128
#: main.cpp:162 touch.cpp:129
#, kde-format
msgid "%1 - Current Desktop"
msgstr ""
#: main.cpp:163 touch.cpp:129
#: main.cpp:163 touch.cpp:130
#, kde-format
msgid "%1 - Current Application"
msgstr ""
#: main.cpp:165
#: main.cpp:165 touch.cpp:132
#, kde-format
msgid "Overview"
msgstr ""
#: main.cpp:167 touch.cpp:131
#: main.cpp:167 touch.cpp:134
#, kde-format
msgid "Toggle window switching"
msgstr ""
#: main.cpp:168 touch.cpp:132
#: main.cpp:168 touch.cpp:135
#, kde-format
msgid "Toggle alternative window switching"
msgstr ""

View File

@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kwin\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-11-02 01:40+0000\n"
"POT-Creation-Date: 2024-02-06 03:08+0000\n"
"PO-Revision-Date: 2023-11-07 21:27+0100\n"
"Last-Translator: Enol P. <enolp@softastur.org>\n"
"Language-Team: \n"
@ -779,23 +779,8 @@ msgstr ""
msgid "Multiscreen behavior:"
msgstr ""
#. i18n: ectx: property (whatsThis), widget (QCheckBox, kcfg_ActiveMouseScreen)
#: focus.ui:203
#, kde-format
msgid ""
"When this option is enabled, the active screen (where new windows appear, "
"for example) is the screen containing the mouse pointer. When disabled, the "
"active screen is the screen containing the focused window."
msgstr ""
#. i18n: ectx: property (text), widget (QCheckBox, kcfg_ActiveMouseScreen)
#: focus.ui:206
#, kde-format
msgid "Active screen follows &mouse"
msgstr ""
#. i18n: ectx: property (whatsThis), widget (QCheckBox, kcfg_SeparateScreenFocus)
#: focus.ui:213
#: focus.ui:203
#, kde-format
msgid ""
"When this option is enabled, focus operations are limited only to the active "
@ -803,13 +788,13 @@ msgid ""
msgstr ""
#. i18n: ectx: property (text), widget (QCheckBox, kcfg_SeparateScreenFocus)
#: focus.ui:216
#: focus.ui:206
#, kde-format
msgid "&Separate screen focus"
msgstr ""
#. i18n: ectx: property (text), widget (QLabel, windowFocusPolicyDescriptionLabel)
#: focus.ui:229
#: focus.ui:219
#, kde-format
msgid "Window activation policy description"
msgstr ""
@ -1102,14 +1087,14 @@ msgstr ""
msgid "Only when overlapping"
msgstr ""
#: windows.cpp:93
#: windows.cpp:92
#, kde-format
msgid ""
"<em>Click to focus:</em> A window becomes active when you click into it. "
"This behavior is common on other operating systems and likely what you want."
msgstr ""
#: windows.cpp:96
#: windows.cpp:95
#, kde-format
msgid ""
"<em>Click to focus (mouse precedence):</em> Mostly the same as <em>Click to "
@ -1119,7 +1104,7 @@ msgid ""
"em>."
msgstr ""
#: windows.cpp:99
#: windows.cpp:98
#, kde-format
msgid ""
"<em>Focus follows mouse:</em> Moving the mouse onto a window will activate "
@ -1128,7 +1113,7 @@ msgid ""
"to focus</em> just without having to actually click."
msgstr ""
#: windows.cpp:102
#: windows.cpp:101
#, kde-format
msgid ""
"This is mostly the same as <em>Focus follows mouse</em>. If an active window "
@ -1137,7 +1122,7 @@ msgid ""
"if you want a hover controlled focus."
msgstr ""
#: windows.cpp:105
#: windows.cpp:104
#, kde-format
msgid ""
"<em>Focus under mouse:</em> The focus always remains on the window under the "
@ -1147,7 +1132,7 @@ msgid ""
"precedence)</em> instead!"
msgstr ""
#: windows.cpp:108
#: windows.cpp:107
#, kde-format
msgid ""
"<em>Focus strictly under mouse:</em> The focus is always on the window under "

File diff suppressed because it is too large Load Diff

View File

@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kwin\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-06-21 02:02+0000\n"
"POT-Creation-Date: 2024-01-14 03:08+0000\n"
"PO-Revision-Date: 2022-10-18 00:04+0400\n"
"Last-Translator: Kheyyam <xxmn77@gmail.com>\n"
"Language-Team: Azerbaijani <kde-i18n-doc@kde.org>\n"
@ -17,17 +17,17 @@ msgstr ""
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"X-Generator: Lokalize 22.08.2\n"
#: module.cpp:50
#: module.cpp:49
#, kde-format
msgid "Import KWin Script"
msgstr "KWin Skriptinin İdxalı"
#: module.cpp:51
#: module.cpp:50
#, kde-format
msgid "*.kwinscript|KWin scripts (*.kwinscript)"
msgstr "*.kwinscript|KWin skriptləri (*.kwinscript)"
#: module.cpp:62
#: module.cpp:61
#, kde-format
msgctxt "Placeholder is error message returned from the install service"
msgid ""
@ -37,13 +37,13 @@ msgstr ""
"Seçilmiş skript idxal edilə bilmir.\n"
"%1"
#: module.cpp:66
#: module.cpp:65
#, kde-format
msgctxt "Placeholder is name of the script that was imported"
msgid "The script \"%1\" was successfully imported."
msgstr "\"%1\" skripti uğurla idxal olundu."
#: module.cpp:125
#: module.cpp:124
#, kde-format
msgid "Error when uninstalling KWin Script: %1"
msgstr "Bu KWin Script'in silinməsi zamanı xəta: %1"

View File

@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kwin\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-08-06 02:04+0000\n"
"POT-Creation-Date: 2024-01-14 03:08+0000\n"
"PO-Revision-Date: 2021-06-10 11:34+0400\n"
"Last-Translator: Kheyyam Gojayev <xxmn77@gmail.com>\n"
"Language-Team: Azerbaijani <kde-i18n-doc@kde.org>\n"
@ -67,7 +67,7 @@ msgstr "Digər pəncərələrin altında tutmaq"
msgid "Keep above other windows"
msgstr "Digər pəncərələrin üzərində tutmaq"
#: kcm.cpp:176
#: kcm.cpp:177
#, kde-format
msgctxt "%1 is the name of a border size"
msgid "Theme's default (%1)"

View File

@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kwin\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-12-08 01:36+0000\n"
"POT-Creation-Date: 2024-02-17 02:27+0000\n"
"PO-Revision-Date: 2023-01-02 23:31+0400\n"
"Last-Translator: Kheyyam <xxmn77@gmail.com>\n"
"Language-Team: Azerbaijani <kde-i18n-doc@kde.org>\n"
@ -274,7 +274,7 @@ msgstr "Otaqlar"
msgid "Screen"
msgstr "Ekran"
#: rulesmodel.cpp:513
#: rulesmodel.cpp:513 rulesmodel.cpp:922
#, kde-format
msgid "Fullscreen"
msgstr "Tam ekran"
@ -414,7 +414,7 @@ msgstr "Başlıq və çərçivə yoxdur"
#: rulesmodel.cpp:609 rulesmodel.cpp:614 rulesmodel.cpp:620 rulesmodel.cpp:625
#: rulesmodel.cpp:631 rulesmodel.cpp:658 rulesmodel.cpp:686 rulesmodel.cpp:692
#: rulesmodel.cpp:704 rulesmodel.cpp:709 rulesmodel.cpp:715 rulesmodel.cpp:720
#: rulesmodel.cpp:704 rulesmodel.cpp:709 rulesmodel.cpp:714 rulesmodel.cpp:719
#, kde-format
msgid "Appearance & Fixes"
msgstr "Xarici görünüş və Səhv düzəlişi"
@ -524,19 +524,19 @@ msgstr "Bağlana bilən"
#: rulesmodel.cpp:709
#, kde-format
msgid "Set window type"
msgstr "Pəncərə növünü seçin"
#: rulesmodel.cpp:715
#, kde-format
msgid "Desktop file name"
msgstr ".desktop faylı"
#: rulesmodel.cpp:720
#: rulesmodel.cpp:714
#, kde-format
msgid "Block compositing"
msgstr "Effektləri əngəlləmək"
#: rulesmodel.cpp:719
#, kde-format
msgid "Layer"
msgstr ""
#: rulesmodel.cpp:772
#, fuzzy, kde-format
#| msgid "Window class (application)"
@ -593,7 +593,7 @@ msgstr "Qopan menyu"
msgid "Splash Screen"
msgstr "Açılış ekranı"
#: rulesmodel.cpp:815
#: rulesmodel.cpp:815 rulesmodel.cpp:917
#, kde-format
msgid "Desktop"
msgstr "İş masası"
@ -686,7 +686,7 @@ msgstr "Heç biri"
msgid "Low"
msgstr "Zəif üstünlük"
#: rulesmodel.cpp:889
#: rulesmodel.cpp:889 rulesmodel.cpp:919
#, kde-format
msgid "Normal"
msgstr "Normal üstünlük"
@ -701,13 +701,49 @@ msgstr "Yüksək üstünlük"
msgid "Extreme"
msgstr "Müstəsna"
#: rulesmodel.cpp:934
#: rulesmodel.cpp:918
#, kde-format
msgid "Below"
msgstr ""
#: rulesmodel.cpp:920
#, kde-format
msgid "Above"
msgstr ""
#: rulesmodel.cpp:921
#, fuzzy, kde-format
#| msgid "Position"
msgid "Notification"
msgstr "Mövqe"
#: rulesmodel.cpp:923
#, kde-format
msgid "Popup"
msgstr ""
#: rulesmodel.cpp:924
#, kde-format
msgid "Critical Notification"
msgstr ""
#: rulesmodel.cpp:925
#, kde-format
msgid "OSD"
msgstr ""
#: rulesmodel.cpp:926
#, kde-format
msgid "Overlay"
msgstr ""
#: rulesmodel.cpp:951
#, fuzzy, kde-format
#| msgid "On Main Window"
msgid "Unmanaged window"
msgstr "Əsas Pəncərədə"
#: rulesmodel.cpp:935
#: rulesmodel.cpp:952
#, kde-format
msgid "Could not detect window properties. The window is not managed by KWin."
msgstr ""
@ -871,28 +907,28 @@ msgstr[1] "%1 saniyədən sonra"
msgid "Add property to the rule"
msgstr "Xüsusiyyətləri qaydaya əlavə et"
#: ui/RulesEditor.qml:278 ui/ValueEditor.qml:54
#: ui/RulesEditor.qml:279 ui/ValueEditor.qml:54
#, kde-format
msgid "Yes"
msgstr "Bəli"
#: ui/RulesEditor.qml:278 ui/ValueEditor.qml:60
#: ui/RulesEditor.qml:279 ui/ValueEditor.qml:60
#, kde-format
msgid "No"
msgstr "1"
#: ui/RulesEditor.qml:280 ui/ValueEditor.qml:168 ui/ValueEditor.qml:175
#: ui/RulesEditor.qml:281 ui/ValueEditor.qml:168 ui/ValueEditor.qml:175
#, kde-format
msgid "%1 %"
msgstr "%1 %"
#: ui/RulesEditor.qml:282
#: ui/RulesEditor.qml:283
#, kde-format
msgctxt "Coordinates (x, y)"
msgid "(%1, %2)"
msgstr "(%1, %2)"
#: ui/RulesEditor.qml:284
#: ui/RulesEditor.qml:285
#, kde-format
msgctxt "Size (width, height)"
msgid "(%1, %2)"
@ -904,6 +940,9 @@ msgctxt "(x, y) coordinates separator in size/position"
msgid "x"
msgstr "x"
#~ msgid "Set window type"
#~ msgstr "Pəncərə növünü seçin"
#~ msgid "Window shall (not) appear in the taskbar."
#~ msgstr "Pəncərə tapşırıq panelində görünəcək/görünməyəcək."

View File

@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kwin\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-12-20 01:35+0000\n"
"POT-Creation-Date: 2024-01-14 03:08+0000\n"
"PO-Revision-Date: 2022-07-03 14:23+0400\n"
"Last-Translator: Kheyyam <xxmn77@gmail.com>\n"
"Language-Team: Azerbaijani <kde-i18n-doc@kde.org>\n"
@ -17,33 +17,33 @@ msgstr ""
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"X-Generator: Lokalize 22.04.2\n"
#: layoutpreview.cpp:131
#: layoutpreview.cpp:127
#, kde-format
msgid "Show Desktop"
msgstr "İş masasını göstərmək"
#: layoutpreview.cpp:161
#: layoutpreview.cpp:157
#, kde-format
msgctxt "An example Desktop Name"
msgid "Desktop 1"
msgstr "İş masası 1"
#: main.cpp:67
#: main.cpp:66
#, kde-format
msgid "Main"
msgstr "Əsas"
#: main.cpp:68
#: main.cpp:67
#, kde-format
msgid "Alternative"
msgstr "Alternativ"
#: main.cpp:70
#: main.cpp:69
#, kde-format
msgid "Get New Task Switchers..."
msgstr "Yeni Vizual Pəncərə Dəyişdiricilərini Almaq..."
#: main.cpp:84
#: main.cpp:83
#, kde-format
msgid ""
"Focus policy settings limit the functionality of navigating through windows."

View File

@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kwin\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-12-20 01:35+0000\n"
"POT-Creation-Date: 2024-01-19 02:29+0000\n"
"PO-Revision-Date: 2022-07-19 10:54+0400\n"
"Last-Translator: Kheyyam <xxmn77@gmail.com>\n"
"Language-Team: Azerbaijani <kde-i18n-doc@kde.org>\n"
@ -17,68 +17,68 @@ msgstr ""
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"X-Generator: Lokalize 22.04.3\n"
#: main.cpp:151 touch.cpp:117
#: main.cpp:151 touch.cpp:118
#, kde-format
msgid "No Action"
msgstr "Hərəkətsiz"
#: main.cpp:152 touch.cpp:118
#: main.cpp:152 touch.cpp:119
#, kde-format
msgid "Peek at Desktop"
msgstr "İş masasına nəzər salın"
#: main.cpp:153 touch.cpp:119
#: main.cpp:153 touch.cpp:120
#, kde-format
msgid "Lock Screen"
msgstr "Ekranı kilidləmək"
#: main.cpp:154 touch.cpp:120
#: main.cpp:154 touch.cpp:121
#, kde-format
msgid "Show KRunner"
msgstr "KRunner göstərmək"
#: main.cpp:155 touch.cpp:121
#: main.cpp:155 touch.cpp:122
#, kde-format
msgid "Activity Manager"
msgstr "Fəaliyyət Meneceri"
#: main.cpp:156 touch.cpp:122
#: main.cpp:156 touch.cpp:123
#, kde-format
msgid "Application Launcher"
msgstr "Tətbiq Başladıcı"
#: main.cpp:160 touch.cpp:126
#: main.cpp:160 touch.cpp:127
#, kde-format
msgid "Present Windows"
msgstr "hazırkı pəncərələr"
#: main.cpp:161 touch.cpp:127
#: main.cpp:161 touch.cpp:128
#, kde-format
msgid "%1 - All Desktops"
msgstr "%1 - Bütün İş masaları"
#: main.cpp:162 touch.cpp:128
#: main.cpp:162 touch.cpp:129
#, kde-format
msgid "%1 - Current Desktop"
msgstr "%1 - Hazırkı İş masası"
#: main.cpp:163 touch.cpp:129
#: main.cpp:163 touch.cpp:130
#, kde-format
msgid "%1 - Current Application"
msgstr "%1 - Cari tətbiq"
#: main.cpp:165
#: main.cpp:165 touch.cpp:132
#, fuzzy, kde-format
#| msgid "Toggle Overview"
msgid "Overview"
msgstr "Ümumi baxışı dəyişmək"
#: main.cpp:167 touch.cpp:131
#: main.cpp:167 touch.cpp:134
#, kde-format
msgid "Toggle window switching"
msgstr "Pəncərə dəyişmə açarı"
#: main.cpp:168 touch.cpp:132
#: main.cpp:168 touch.cpp:135
#, kde-format
msgid "Toggle alternative window switching"
msgstr "Əlavə pəncərə dəyişmə açarı"

View File

@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kwin\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-11-02 01:40+0000\n"
"POT-Creation-Date: 2024-02-06 03:08+0000\n"
"PO-Revision-Date: 2022-10-18 00:03+0400\n"
"Last-Translator: Kheyyam <xxmn77@gmail.com>\n"
"Language-Team: Azerbaijani <kde-i18n-doc@kde.org>\n"
@ -914,26 +914,8 @@ msgstr ""
msgid "Multiscreen behavior:"
msgstr "Birdən çox ekranla davranış:"
#. i18n: ectx: property (whatsThis), widget (QCheckBox, kcfg_ActiveMouseScreen)
#: focus.ui:203
#, kde-format
msgid ""
"When this option is enabled, the active screen (where new windows appear, "
"for example) is the screen containing the mouse pointer. When disabled, the "
"active screen is the screen containing the focused window."
msgstr ""
"Bu seçim aktiv edildikdə, aktiv ekran (məsələn yeni pəncərələrin göründüyü "
"yer) siçan kursorundan ibarət ekrandır. Söndürüldükdə isə aktiv kranın "
"fokuslanmış pəncərələrindən ibarət ekrandır."
#. i18n: ectx: property (text), widget (QCheckBox, kcfg_ActiveMouseScreen)
#: focus.ui:206
#, kde-format
msgid "Active screen follows &mouse"
msgstr "Aktiv ekran &kursoru izləyir"
#. i18n: ectx: property (whatsThis), widget (QCheckBox, kcfg_SeparateScreenFocus)
#: focus.ui:213
#: focus.ui:203
#, kde-format
msgid ""
"When this option is enabled, focus operations are limited only to the active "
@ -943,13 +925,13 @@ msgstr ""
"məhdudlaşır"
#. i18n: ectx: property (text), widget (QCheckBox, kcfg_SeparateScreenFocus)
#: focus.ui:216
#: focus.ui:206
#, kde-format
msgid "&Separate screen focus"
msgstr "Ekran üçün ayrıca foku&s"
#. i18n: ectx: property (text), widget (QLabel, windowFocusPolicyDescriptionLabel)
#: focus.ui:229
#: focus.ui:219
#, kde-format
msgid "Window activation policy description"
msgstr "Pəncərənin aktivləşdirilməsi qaydalarının təfərrüatları"
@ -1259,7 +1241,7 @@ msgstr ""
msgid "Only when overlapping"
msgstr "Yalnız üst-üstə gəldikdə yapışdırmaq"
#: windows.cpp:93
#: windows.cpp:92
#, kde-format
msgid ""
"<em>Click to focus:</em> A window becomes active when you click into it. "
@ -1269,7 +1251,7 @@ msgstr ""
"aktivləşir. Siz ola bilsin ki, bununla başqa əməliyyat sistemlərindən "
"tanışsını."
#: windows.cpp:96
#: windows.cpp:95
#, kde-format
msgid ""
"<em>Click to focus (mouse precedence):</em> Mostly the same as <em>Click to "
@ -1284,7 +1266,7 @@ msgstr ""
"olsa da <em>Fokus üçün klik</em> rejiminə alternativ variant kimi qəbul "
"olunur."
#: windows.cpp:99
#: windows.cpp:98
#, kde-format
msgid ""
"<em>Focus follows mouse:</em> Moving the mouse onto a window will activate "
@ -1297,7 +1279,7 @@ msgstr ""
"ki, <em>Fokusun dəyişməsin qarşısının alınması</em> adi qaydada işləyir. Bu "
"variant <em>Fokus üçün klik</em>oxşayır, ancaq xüsusi klik tələb olunmur."
#: windows.cpp:102
#: windows.cpp:101
#, kde-format
msgid ""
"This is mostly the same as <em>Focus follows mouse</em>. If an active window "
@ -1310,7 +1292,7 @@ msgstr ""
"altındakı pəncərəyə verilir. Üstündə saxlayarkən fokuslamaq üçün bu rejimi "
"seçin."
#: windows.cpp:105
#: windows.cpp:104
#, kde-format
msgid ""
"<em>Focus under mouse:</em> The focus always remains on the window under the "
@ -1325,7 +1307,7 @@ msgstr ""
"işlıməz.Bunun əvəzinə siz <em>Fokus siçanı izləyir</em>variantını işlətmək "
"istəyə bilərsiniz."
#: windows.cpp:108
#: windows.cpp:107
#, kde-format
msgid ""
"<em>Focus strictly under mouse:</em> The focus is always on the window under "
@ -1342,6 +1324,18 @@ msgstr ""
"ziddir və işləməz. Bunun əvəzinə siz <em>Fokus siçanı izləyir (siçanın "
"üstünlüyü)</em>variantını işlətmək istəyə bilərsiniz."
#~ msgid ""
#~ "When this option is enabled, the active screen (where new windows appear, "
#~ "for example) is the screen containing the mouse pointer. When disabled, "
#~ "the active screen is the screen containing the focused window."
#~ msgstr ""
#~ "Bu seçim aktiv edildikdə, aktiv ekran (məsələn yeni pəncərələrin "
#~ "göründüyü yer) siçan kursorundan ibarət ekrandır. Söndürüldükdə isə aktiv "
#~ "kranın fokuslanmış pəncərələrindən ibarət ekrandır."
#~ msgid "Active screen follows &mouse"
#~ msgstr "Aktiv ekran &kursoru izləyir"
#~ msgctxt "NAME OF TRANSLATORS"
#~ msgid "Your names"
#~ msgstr "Xəyyam Qocayev"

File diff suppressed because it is too large Load Diff

View File

@ -3,7 +3,7 @@ msgid ""
msgstr ""
"Project-Id-Version: 86ff119b1606fcaa910d6b44fc14b611\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-06-21 02:02+0000\n"
"POT-Creation-Date: 2024-01-14 03:08+0000\n"
"PO-Revision-Date: 2022-12-25 17:08\n"
"Last-Translator: Zmicier <zmicerturok@gmail.com>\n"
"Language-Team: Belarusian\n"
@ -21,17 +21,17 @@ msgstr ""
"X-Crowdin-File: /main/be/kwin/kcm_kwin_scripts.po\n"
"X-Crowdin-File-ID: 8758\n"
#: module.cpp:50
#: module.cpp:49
#, kde-format
msgid "Import KWin Script"
msgstr "Імпартаваць скрыпт KWin"
#: module.cpp:51
#: module.cpp:50
#, kde-format
msgid "*.kwinscript|KWin scripts (*.kwinscript)"
msgstr "*.kwinscript|скрыпт KWin (*.kwinscript)"
#: module.cpp:62
#: module.cpp:61
#, kde-format
msgctxt "Placeholder is error message returned from the install service"
msgid ""
@ -41,13 +41,13 @@ msgstr ""
"Не ўдалося імпартаваць абраны скрыпт.\n"
"%1"
#: module.cpp:66
#: module.cpp:65
#, kde-format
msgctxt "Placeholder is name of the script that was imported"
msgid "The script \"%1\" was successfully imported."
msgstr "Скрыпт \"%1\" паспяхова імпартаваны."
#: module.cpp:125
#: module.cpp:124
#, kde-format
msgid "Error when uninstalling KWin Script: %1"
msgstr "Падчас выдалення скрыпта KWin адбылася памылка: %1"

View File

@ -5,7 +5,7 @@ msgid ""
msgstr ""
"Project-Id-Version: 86ff119b1606fcaa910d6b44fc14b611\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-08-06 02:04+0000\n"
"POT-Creation-Date: 2024-01-14 03:08+0000\n"
"PO-Revision-Date: 2023-02-09 08:31\n"
"Last-Translator: Darafei Praliaskouski <komzpa@gmail.com>\n"
"Language-Team: Belarusian\n"
@ -73,7 +73,7 @@ msgstr "Размяшчаць ніжэй астатніх акон"
msgid "Keep above other windows"
msgstr "Размяшчаць вышэй астатніх акон"
#: kcm.cpp:176
#: kcm.cpp:177
#, kde-format
msgctxt "%1 is the name of a border size"
msgid "Theme's default (%1)"

View File

@ -5,7 +5,7 @@ msgid ""
msgstr ""
"Project-Id-Version: 86ff119b1606fcaa910d6b44fc14b611\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-12-08 01:36+0000\n"
"POT-Creation-Date: 2024-02-17 02:27+0000\n"
"PO-Revision-Date: 2023-02-08 13:45\n"
"Last-Translator: Darafei Praliaskouski <komzpa@licei2.com>\n"
"Language-Team: Belarusian\n"
@ -281,7 +281,7 @@ msgstr "Пакоі"
msgid "Screen"
msgstr "Экран"
#: rulesmodel.cpp:513
#: rulesmodel.cpp:513 rulesmodel.cpp:922
#, kde-format
msgid "Fullscreen"
msgstr "На ўвесь экран"
@ -418,7 +418,7 @@ msgstr "Без панэлі загалоўка і рамкі"
#: rulesmodel.cpp:609 rulesmodel.cpp:614 rulesmodel.cpp:620 rulesmodel.cpp:625
#: rulesmodel.cpp:631 rulesmodel.cpp:658 rulesmodel.cpp:686 rulesmodel.cpp:692
#: rulesmodel.cpp:704 rulesmodel.cpp:709 rulesmodel.cpp:715 rulesmodel.cpp:720
#: rulesmodel.cpp:704 rulesmodel.cpp:709 rulesmodel.cpp:714 rulesmodel.cpp:719
#, kde-format
msgid "Appearance & Fixes"
msgstr "Выгляд і фіксацыя"
@ -528,19 +528,19 @@ msgstr "Можна закрыць"
#: rulesmodel.cpp:709
#, kde-format
msgid "Set window type"
msgstr "Вызначыць тып акна"
#: rulesmodel.cpp:715
#, kde-format
msgid "Desktop file name"
msgstr "Назва файла працоўнага стала"
#: rulesmodel.cpp:720
#: rulesmodel.cpp:714
#, kde-format
msgid "Block compositing"
msgstr "Блакаванне кампазітынгу"
#: rulesmodel.cpp:719
#, kde-format
msgid "Layer"
msgstr ""
#: rulesmodel.cpp:772
#, kde-format
msgid "Window class not available"
@ -601,7 +601,7 @@ msgstr "Адчэпленае меню"
msgid "Splash Screen"
msgstr "Застаўка"
#: rulesmodel.cpp:815
#: rulesmodel.cpp:815 rulesmodel.cpp:917
#, kde-format
msgid "Desktop"
msgstr "Працоўны стол"
@ -694,7 +694,7 @@ msgstr "Няма"
msgid "Low"
msgstr "Нізкі ўзровень"
#: rulesmodel.cpp:889
#: rulesmodel.cpp:889 rulesmodel.cpp:919
#, kde-format
msgid "Normal"
msgstr "Звычайны ўзровень"
@ -709,12 +709,48 @@ msgstr "Высокі ўзровень"
msgid "Extreme"
msgstr "Экстрымальны ўзровень"
#: rulesmodel.cpp:934
#: rulesmodel.cpp:918
#, kde-format
msgid "Below"
msgstr ""
#: rulesmodel.cpp:920
#, kde-format
msgid "Above"
msgstr ""
#: rulesmodel.cpp:921
#, fuzzy, kde-format
#| msgid "Position"
msgid "Notification"
msgstr "Пазіцыя"
#: rulesmodel.cpp:923
#, kde-format
msgid "Popup"
msgstr ""
#: rulesmodel.cpp:924
#, kde-format
msgid "Critical Notification"
msgstr ""
#: rulesmodel.cpp:925
#, kde-format
msgid "OSD"
msgstr ""
#: rulesmodel.cpp:926
#, kde-format
msgid "Overlay"
msgstr ""
#: rulesmodel.cpp:951
#, kde-format
msgid "Unmanaged window"
msgstr "Акно без кіравання"
#: rulesmodel.cpp:935
#: rulesmodel.cpp:952
#, kde-format
msgid "Could not detect window properties. The window is not managed by KWin."
msgstr "Не ўдалося выявіць уласцівасці акна. Акно не кіруецца KWin."
@ -878,28 +914,28 @@ msgstr[3] "Праз %1 секунды"
msgid "Add property to the rule"
msgstr "Дадаць уласцівасць у правіла"
#: ui/RulesEditor.qml:278 ui/ValueEditor.qml:54
#: ui/RulesEditor.qml:279 ui/ValueEditor.qml:54
#, kde-format
msgid "Yes"
msgstr "Так"
#: ui/RulesEditor.qml:278 ui/ValueEditor.qml:60
#: ui/RulesEditor.qml:279 ui/ValueEditor.qml:60
#, kde-format
msgid "No"
msgstr "Не"
#: ui/RulesEditor.qml:280 ui/ValueEditor.qml:168 ui/ValueEditor.qml:175
#: ui/RulesEditor.qml:281 ui/ValueEditor.qml:168 ui/ValueEditor.qml:175
#, kde-format
msgid "%1 %"
msgstr "%1 %"
#: ui/RulesEditor.qml:282
#: ui/RulesEditor.qml:283
#, kde-format
msgctxt "Coordinates (x, y)"
msgid "(%1, %2)"
msgstr "(%1, %2)"
#: ui/RulesEditor.qml:284
#: ui/RulesEditor.qml:285
#, kde-format
msgctxt "Size (width, height)"
msgid "(%1, %2)"
@ -911,6 +947,9 @@ msgctxt "(x, y) coordinates separator in size/position"
msgid "x"
msgstr "x"
#~ msgid "Set window type"
#~ msgstr "Вызначыць тып акна"
#~ msgid "Window shall (not) appear in the taskbar."
#~ msgstr "Акно (не) павінна з'яўляцца на панэлі задач."

View File

@ -3,7 +3,7 @@ msgid ""
msgstr ""
"Project-Id-Version: 86ff119b1606fcaa910d6b44fc14b611\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-12-20 01:35+0000\n"
"POT-Creation-Date: 2024-01-14 03:08+0000\n"
"PO-Revision-Date: 2023-02-08 13:48\n"
"Last-Translator: Zmicier <zmicerturok@gmail.com>\n"
"Language-Team: Belarusian\n"
@ -21,33 +21,33 @@ msgstr ""
"X-Crowdin-File: /main/be/kwin/kcm_kwintabbox.po\n"
"X-Crowdin-File-ID: 8760\n"
#: layoutpreview.cpp:131
#: layoutpreview.cpp:127
#, kde-format
msgid "Show Desktop"
msgstr "Паказаць працоўны стол"
#: layoutpreview.cpp:161
#: layoutpreview.cpp:157
#, kde-format
msgctxt "An example Desktop Name"
msgid "Desktop 1"
msgstr "Працоўны стол 1"
#: main.cpp:67
#: main.cpp:66
#, kde-format
msgid "Main"
msgstr "Асноўныя"
#: main.cpp:68
#: main.cpp:67
#, kde-format
msgid "Alternative"
msgstr "Альтэрнатыўны"
#: main.cpp:70
#: main.cpp:69
#, kde-format
msgid "Get New Task Switchers..."
msgstr "Атрымаць новыя сродкі пераключэння задач..."
#: main.cpp:84
#: main.cpp:83
#, kde-format
msgid ""
"Focus policy settings limit the functionality of navigating through windows."

View File

@ -3,7 +3,7 @@ msgid ""
msgstr ""
"Project-Id-Version: 86ff119b1606fcaa910d6b44fc14b611\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-12-20 01:35+0000\n"
"POT-Creation-Date: 2024-01-19 02:29+0000\n"
"PO-Revision-Date: 2022-12-25 17:08\n"
"Last-Translator: Zmicier <zmicerturok@gmail.com>\n"
"Language-Team: Belarusian\n"
@ -21,67 +21,67 @@ msgstr ""
"X-Crowdin-File: /main/be/kwin/kcmkwinscreenedges.po\n"
"X-Crowdin-File-ID: 8766\n"
#: main.cpp:151 touch.cpp:117
#: main.cpp:151 touch.cpp:118
#, kde-format
msgid "No Action"
msgstr "Няма дзеяння"
#: main.cpp:152 touch.cpp:118
#: main.cpp:152 touch.cpp:119
#, kde-format
msgid "Peek at Desktop"
msgstr "Аглядзець працоўны стол"
#: main.cpp:153 touch.cpp:119
#: main.cpp:153 touch.cpp:120
#, kde-format
msgid "Lock Screen"
msgstr "Заблакаваць экран"
#: main.cpp:154 touch.cpp:120
#: main.cpp:154 touch.cpp:121
#, kde-format
msgid "Show KRunner"
msgstr "Паказаць KRunner"
#: main.cpp:155 touch.cpp:121
#: main.cpp:155 touch.cpp:122
#, kde-format
msgid "Activity Manager"
msgstr "Кіраўнік пакояў"
#: main.cpp:156 touch.cpp:122
#: main.cpp:156 touch.cpp:123
#, kde-format
msgid "Application Launcher"
msgstr "Сродак запуску праграм"
#: main.cpp:160 touch.cpp:126
#: main.cpp:160 touch.cpp:127
#, kde-format
msgid "Present Windows"
msgstr "Бягучыя вокны"
#: main.cpp:161 touch.cpp:127
#: main.cpp:161 touch.cpp:128
#, kde-format
msgid "%1 - All Desktops"
msgstr "%1 - усе працоўныя сталы"
#: main.cpp:162 touch.cpp:128
#: main.cpp:162 touch.cpp:129
#, kde-format
msgid "%1 - Current Desktop"
msgstr "%1 - бягучы працоўны стол"
#: main.cpp:163 touch.cpp:129
#: main.cpp:163 touch.cpp:130
#, kde-format
msgid "%1 - Current Application"
msgstr "%1 - бягучая праграма"
#: main.cpp:165
#: main.cpp:165 touch.cpp:132
#, kde-format
msgid "Overview"
msgstr ""
#: main.cpp:167 touch.cpp:131
#: main.cpp:167 touch.cpp:134
#, kde-format
msgid "Toggle window switching"
msgstr "Змена рэжыму пераключэння акон"
#: main.cpp:168 touch.cpp:132
#: main.cpp:168 touch.cpp:135
#, kde-format
msgid "Toggle alternative window switching"
msgstr "Змена рэжыму альтэрнатыўнага пераключэння акон"

View File

@ -4,7 +4,7 @@ msgid ""
msgstr ""
"Project-Id-Version: 86ff119b1606fcaa910d6b44fc14b611\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-11-02 01:40+0000\n"
"POT-Creation-Date: 2024-02-06 03:08+0000\n"
"PO-Revision-Date: 2023-02-08 13:45\n"
"Last-Translator: Darafei Praliaskouski <komzpa@licei2.com>\n"
"Language-Team: Belarusian\n"
@ -892,26 +892,8 @@ msgstr ""
msgid "Multiscreen behavior:"
msgstr "Паводзіны пры некалькіх экранах:"
#. i18n: ectx: property (whatsThis), widget (QCheckBox, kcfg_ActiveMouseScreen)
#: focus.ui:203
#, kde-format
msgid ""
"When this option is enabled, the active screen (where new windows appear, "
"for example) is the screen containing the mouse pointer. When disabled, the "
"active screen is the screen containing the focused window."
msgstr ""
"Калі гэты параметр уключаны, актыўны экран (напрыклад, дзе з'яўляюцца новыя "
"вокны) - экран, які змяшчае паказальнік мышы. Калі гэты параметр адключаны, "
"актыўны экран - экран, які змяшчае акно ў фокусе."
#. i18n: ectx: property (text), widget (QCheckBox, kcfg_ActiveMouseScreen)
#: focus.ui:206
#, kde-format
msgid "Active screen follows &mouse"
msgstr "Актыўны экран пільнуецца &мышы"
#. i18n: ectx: property (whatsThis), widget (QCheckBox, kcfg_SeparateScreenFocus)
#: focus.ui:213
#: focus.ui:203
#, kde-format
msgid ""
"When this option is enabled, focus operations are limited only to the active "
@ -921,13 +903,13 @@ msgstr ""
"актыўным экранам"
#. i18n: ectx: property (text), widget (QCheckBox, kcfg_SeparateScreenFocus)
#: focus.ui:216
#: focus.ui:206
#, kde-format
msgid "&Separate screen focus"
msgstr "&Асобнае факусаванне экранаў"
#. i18n: ectx: property (text), widget (QLabel, windowFocusPolicyDescriptionLabel)
#: focus.ui:229
#: focus.ui:219
#, kde-format
msgid "Window activation policy description"
msgstr "Апісанне палітыкі актывацыі акон"
@ -1240,7 +1222,7 @@ msgstr ""
msgid "Only when overlapping"
msgstr "Толькі пры накладанні"
#: windows.cpp:93
#: windows.cpp:92
#, kde-format
msgid ""
"<em>Click to focus:</em> A window becomes active when you click into it. "
@ -1250,7 +1232,7 @@ msgstr ""
"пстрыкаеце па ім. Такія паводзіны часта сустракаюцца ў іншых аперацыйных "
"сістэмах. Хутчэй за ўсё, гэта тое, што вам патрэбна."
#: windows.cpp:96
#: windows.cpp:95
#, kde-format
msgid ""
"<em>Click to focus (mouse precedence):</em> Mostly the same as <em>Click to "
@ -1265,7 +1247,7 @@ msgstr ""
"акно пад мышшу - пераважны кандыдат. Незвычайны, але магчымы варыянт "
"<em>Факусавацца пры пстрыканні</em>."
#: windows.cpp:99
#: windows.cpp:98
#, kde-format
msgid ""
"<em>Focus follows mouse:</em> Moving the mouse onto a window will activate "
@ -1279,7 +1261,7 @@ msgstr ""
"функцыянуе звычайным чынам. Падобна на <em>Факусавацца пры пстрыканні</em>, "
"але няма патрэбы пстрыкаць."
#: windows.cpp:102
#: windows.cpp:101
#, kde-format
msgid ""
"This is mostly the same as <em>Focus follows mouse</em>. If an active window "
@ -1292,7 +1274,7 @@ msgstr ""
"было закрыта), акно пад мышшу - пераважны кандыдат. Абярыце гэта, калі "
"хочаце кантраляваць факусаванне пры навядзенні."
#: windows.cpp:105
#: windows.cpp:104
#, kde-format
msgid ""
"<em>Focus under mouse:</em> The focus always remains on the window under the "
@ -1306,7 +1288,7 @@ msgstr ""
"<em>Alt+Tab</em> супярэчаць правілам актывацыі і не будуць працаваць. "
"Напэўна, вам патрэбна <em>Факусавацца ўслед за мышшу (прыярытэт мышы)</em>!"
#: windows.cpp:108
#: windows.cpp:107
#, kde-format
msgid ""
"<em>Focus strictly under mouse:</em> The focus is always on the window under "
@ -1323,6 +1305,18 @@ msgstr ""
"і не будуць працаваць. Напэўна, вам патрэбна <em>Факусавацца ўслед за мышшу "
"(прыярытэт мышы)</em>!"
#~ msgid ""
#~ "When this option is enabled, the active screen (where new windows appear, "
#~ "for example) is the screen containing the mouse pointer. When disabled, "
#~ "the active screen is the screen containing the focused window."
#~ msgstr ""
#~ "Калі гэты параметр уключаны, актыўны экран (напрыклад, дзе з'яўляюцца "
#~ "новыя вокны) - экран, які змяшчае паказальнік мышы. Калі гэты параметр "
#~ "адключаны, актыўны экран - экран, які змяшчае акно ў фокусе."
#~ msgid "Active screen follows &mouse"
#~ msgstr "Актыўны экран пільнуецца &мышы"
#~ msgctxt "NAME OF TRANSLATORS"
#~ msgid "Your names"
#~ msgstr "Дарафей Праляскоўскі, Antikruk"

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kwin\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-06-21 02:02+0000\n"
"POT-Creation-Date: 2024-01-14 03:08+0000\n"
"PO-Revision-Date: 2023-06-08 19:15+0200\n"
"Last-Translator: Mincho Kondarev <mkondarev@yahoo.de>\n"
"Language-Team: Bulgarian <kde-i18n-doc@kde.org>\n"
@ -17,17 +17,17 @@ msgstr ""
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"X-Generator: Lokalize 23.04.1\n"
#: module.cpp:50
#: module.cpp:49
#, kde-format
msgid "Import KWin Script"
msgstr "Импортиране на KWin скрипт"
#: module.cpp:51
#: module.cpp:50
#, kde-format
msgid "*.kwinscript|KWin scripts (*.kwinscript)"
msgstr "* .kwinscript | KWin скриптове (* .kwinscript)"
#: module.cpp:62
#: module.cpp:61
#, kde-format
msgctxt "Placeholder is error message returned from the install service"
msgid ""
@ -37,13 +37,13 @@ msgstr ""
"Избраният скрипт не може да се импортира.\n"
"%1"
#: module.cpp:66
#: module.cpp:65
#, kde-format
msgctxt "Placeholder is name of the script that was imported"
msgid "The script \"%1\" was successfully imported."
msgstr "Скриптът \"%1\" беше импортиран успешно."
#: module.cpp:125
#: module.cpp:124
#, kde-format
msgid "Error when uninstalling KWin Script: %1"
msgstr "Грешка при деинсталиране на KWin скрипт: %1"

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kcmkwindecoration\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-08-06 02:04+0000\n"
"POT-Creation-Date: 2024-01-14 03:08+0000\n"
"PO-Revision-Date: 2023-04-06 18:47+0200\n"
"Last-Translator: Mincho Kondarev <mkondarev@yahoo.de>\n"
"Language-Team: Bulgarian <kde-i18n-doc@kde.org>\n"
@ -69,7 +69,7 @@ msgstr "Задържане под другите прозорците"
msgid "Keep above other windows"
msgstr "Задържане над другите прозорци"
#: kcm.cpp:176
#: kcm.cpp:177
#, kde-format
msgctxt "%1 is the name of a border size"
msgid "Theme's default (%1)"

View File

@ -3,13 +3,13 @@
#
# Zlatko Popov <zlatkopopov@fsa-bg.org>, 2006, 2007, 2008.
# Yasen Pramatarov <yasen@lindeas.com>, 2011.
# Mincho Kondarev <mkondarev@yahoo.de>, 2022, 2023.
# SPDX-FileCopyrightText: 2022, 2023, 2024 Mincho Kondarev <mkondarev@yahoo.de>
msgid ""
msgstr ""
"Project-Id-Version: kcmkwinrules\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-12-08 01:36+0000\n"
"PO-Revision-Date: 2023-06-08 19:13+0200\n"
"POT-Creation-Date: 2024-02-17 02:27+0000\n"
"PO-Revision-Date: 2024-01-27 21:15+0100\n"
"Last-Translator: Mincho Kondarev <mkondarev@yahoo.de>\n"
"Language-Team: Bulgarian <kde-i18n-doc@kde.org>\n"
"Language: bg\n"
@ -17,7 +17,7 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"X-Generator: Lokalize 23.04.1\n"
"X-Generator: Lokalize 23.08.4\n"
#: kcmrules.cpp:228
#, kde-format
@ -283,7 +283,7 @@ msgstr "Дейности"
msgid "Screen"
msgstr "Екран"
#: rulesmodel.cpp:513
#: rulesmodel.cpp:513 rulesmodel.cpp:922
#, kde-format
msgid "Fullscreen"
msgstr "Цял екран"
@ -429,7 +429,7 @@ msgstr "Без заглавна лента и рамка"
#: rulesmodel.cpp:609 rulesmodel.cpp:614 rulesmodel.cpp:620 rulesmodel.cpp:625
#: rulesmodel.cpp:631 rulesmodel.cpp:658 rulesmodel.cpp:686 rulesmodel.cpp:692
#: rulesmodel.cpp:704 rulesmodel.cpp:709 rulesmodel.cpp:715 rulesmodel.cpp:720
#: rulesmodel.cpp:704 rulesmodel.cpp:709 rulesmodel.cpp:714 rulesmodel.cpp:719
#, kde-format
msgid "Appearance & Fixes"
msgstr "Външен вид и корекции"
@ -582,19 +582,19 @@ msgstr "Може да бъде затворен"
#: rulesmodel.cpp:709
#, kde-format
msgid "Set window type"
msgstr "Задаване на тип прозорец"
#: rulesmodel.cpp:715
#, kde-format
msgid "Desktop file name"
msgstr "Име на файла за работния плот"
#: rulesmodel.cpp:720
#: rulesmodel.cpp:714
#, kde-format
msgid "Block compositing"
msgstr "Блоково композиране"
#: rulesmodel.cpp:719
#, kde-format
msgid "Layer"
msgstr "Слой"
#: rulesmodel.cpp:772
#, kde-format
msgid "Window class not available"
@ -655,7 +655,7 @@ msgstr "Откачено меню"
msgid "Splash Screen"
msgstr "Начален екран"
#: rulesmodel.cpp:815
#: rulesmodel.cpp:815 rulesmodel.cpp:917
#, kde-format
msgid "Desktop"
msgstr "Работен плот"
@ -748,7 +748,7 @@ msgstr "Без"
msgid "Low"
msgstr "Слабо"
#: rulesmodel.cpp:889
#: rulesmodel.cpp:889 rulesmodel.cpp:919
#, kde-format
msgid "Normal"
msgstr "Нормално"
@ -763,12 +763,47 @@ msgstr "Силно"
msgid "Extreme"
msgstr "Крайно"
#: rulesmodel.cpp:934
#: rulesmodel.cpp:918
#, kde-format
msgid "Below"
msgstr "Отдолу"
#: rulesmodel.cpp:920
#, kde-format
msgid "Above"
msgstr "Отгоре"
#: rulesmodel.cpp:921
#, kde-format
msgid "Notification"
msgstr "Известие"
#: rulesmodel.cpp:923
#, kde-format
msgid "Popup"
msgstr "Изскачащ прозорец"
#: rulesmodel.cpp:924
#, kde-format
msgid "Critical Notification"
msgstr "Критично известие"
#: rulesmodel.cpp:925
#, kde-format
msgid "OSD"
msgstr "Екранен надпис"
#: rulesmodel.cpp:926
#, kde-format
msgid "Overlay"
msgstr "Наслагване"
#: rulesmodel.cpp:951
#, kde-format
msgid "Unmanaged window"
msgstr "Неуправляван прозорец"
#: rulesmodel.cpp:935
#: rulesmodel.cpp:952
#, kde-format
msgid "Could not detect window properties. The window is not managed by KWin."
msgstr ""
@ -928,28 +963,28 @@ msgstr[1] "След %1 секунди"
msgid "Add property to the rule"
msgstr "Добавяне на свойство към правилото"
#: ui/RulesEditor.qml:278 ui/ValueEditor.qml:54
#: ui/RulesEditor.qml:279 ui/ValueEditor.qml:54
#, kde-format
msgid "Yes"
msgstr "Да"
#: ui/RulesEditor.qml:278 ui/ValueEditor.qml:60
#: ui/RulesEditor.qml:279 ui/ValueEditor.qml:60
#, kde-format
msgid "No"
msgstr "Не"
#: ui/RulesEditor.qml:280 ui/ValueEditor.qml:168 ui/ValueEditor.qml:175
#: ui/RulesEditor.qml:281 ui/ValueEditor.qml:168 ui/ValueEditor.qml:175
#, kde-format
msgid "%1 %"
msgstr "%1 %"
#: ui/RulesEditor.qml:282
#: ui/RulesEditor.qml:283
#, kde-format
msgctxt "Coordinates (x, y)"
msgid "(%1, %2)"
msgstr "(%1, %2)"
#: ui/RulesEditor.qml:284
#: ui/RulesEditor.qml:285
#, kde-format
msgctxt "Size (width, height)"
msgid "(%1, %2)"

View File

@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kcm_kwintabbox\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-12-20 01:35+0000\n"
"POT-Creation-Date: 2024-01-14 03:08+0000\n"
"PO-Revision-Date: 2023-02-13 12:06+0100\n"
"Last-Translator: Mincho Kondarev <mkondarev@yahoo.de>\n"
"Language-Team: Bulgarian <kde-i18n-doc@kde.org>\n"
@ -18,33 +18,33 @@ msgstr ""
"X-Generator: Lokalize 22.12.1\n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
#: layoutpreview.cpp:131
#: layoutpreview.cpp:127
#, kde-format
msgid "Show Desktop"
msgstr "Показване на работния плот"
#: layoutpreview.cpp:161
#: layoutpreview.cpp:157
#, kde-format
msgctxt "An example Desktop Name"
msgid "Desktop 1"
msgstr "Работен плот 1"
#: main.cpp:67
#: main.cpp:66
#, kde-format
msgid "Main"
msgstr "Основни"
#: main.cpp:68
#: main.cpp:67
#, kde-format
msgid "Alternative"
msgstr "Алтернативни"
#: main.cpp:70
#: main.cpp:69
#, kde-format
msgid "Get New Task Switchers..."
msgstr "Изтеглете нови превключватели на задачи..."
#: main.cpp:84
#: main.cpp:83
#, kde-format
msgid ""
"Focus policy settings limit the functionality of navigating through windows."

View File

@ -73,10 +73,3 @@ msgstr ""
"системата до тази на X11 като позволява на злонамерен софтуер да краде "
"пароли и да шпионира текста, който въвеждате. Уверете се, че разбирате и "
"приемате този риск."
#~ msgid "Only Meta, Control, Alt, and Shift keys"
#~ msgstr "Само клавиши Meta, Control, Alt и Shift"
#~ msgid "All keys, but only while Meta, Ctrl, Alt, or Shift keys are pressed"
#~ msgstr ""
#~ "Всички клавиши, но само докато са натиснати Meta, Ctrl, Alt или Shift"

View File

@ -124,29 +124,3 @@ msgstr "Винаги"
#, kde-format
msgid "Re-enable OpenGL detection"
msgstr "Повторно активиране на откриване на OpenGL"
#~ msgid "Latency:"
#~ msgstr "Забавяне:"
#~ msgid "Force lowest latency (may cause dropped frames)"
#~ msgstr ""
#~ "Принудително задаване на най-малко забавяне (може да доведе до отпадане "
#~ "на кадри)"
#~ msgid "Prefer lower latency"
#~ msgstr "Предпочитане на малко забавяне"
#~ msgid "Balance of latency and smoothness"
#~ msgstr "Баланс между забавяне и плавност"
#~ msgid "Prefer smoother animations"
#~ msgstr "Предпочитане на плавни анимации"
#~ msgid "Force smoothest animations"
#~ msgstr "Принудително задаване на възможно най-плавни анимации"
#~ msgid ""
#~ "Reduce latency by allowing screen tearing artifacts in fullscreen windows"
#~ msgstr ""
#~ "Намаляване на латентността чрез допускане на артефакти на разкъсване на "
#~ "екрана в пълноекранни прозорци"

View File

@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kcmkwinscreenedges\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-12-20 01:35+0000\n"
"POT-Creation-Date: 2024-01-19 02:29+0000\n"
"PO-Revision-Date: 2023-12-11 11:49+0100\n"
"Last-Translator: Mincho Kondarev <mkondarev@yahoo.de>\n"
"Language-Team: Bulgarian <kde-i18n-doc@kde.org>\n"
@ -18,67 +18,67 @@ msgstr ""
"X-Generator: Lokalize 23.08.4\n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
#: main.cpp:151 touch.cpp:117
#: main.cpp:151 touch.cpp:118
#, kde-format
msgid "No Action"
msgstr "Без действие"
#: main.cpp:152 touch.cpp:118
#: main.cpp:152 touch.cpp:119
#, kde-format
msgid "Peek at Desktop"
msgstr "Поглед върху работния плот"
#: main.cpp:153 touch.cpp:119
#: main.cpp:153 touch.cpp:120
#, kde-format
msgid "Lock Screen"
msgstr "Заключване на екрана"
#: main.cpp:154 touch.cpp:120
#: main.cpp:154 touch.cpp:121
#, kde-format
msgid "Show KRunner"
msgstr "Показване на KRunner"
#: main.cpp:155 touch.cpp:121
#: main.cpp:155 touch.cpp:122
#, kde-format
msgid "Activity Manager"
msgstr "Мениджър на дейности"
#: main.cpp:156 touch.cpp:122
#: main.cpp:156 touch.cpp:123
#, kde-format
msgid "Application Launcher"
msgstr "Стартер за приложения"
#: main.cpp:160 touch.cpp:126
#: main.cpp:160 touch.cpp:127
#, kde-format
msgid "Present Windows"
msgstr "Представяне на прозорци"
#: main.cpp:161 touch.cpp:127
#: main.cpp:161 touch.cpp:128
#, kde-format
msgid "%1 - All Desktops"
msgstr "%1 - Всички работни плотове"
#: main.cpp:162 touch.cpp:128
#: main.cpp:162 touch.cpp:129
#, kde-format
msgid "%1 - Current Desktop"
msgstr "%1 - Текущ работен плот"
#: main.cpp:163 touch.cpp:129
#: main.cpp:163 touch.cpp:130
#, kde-format
msgid "%1 - Current Application"
msgstr "%1 - Текущо приложение"
#: main.cpp:165
#: main.cpp:165 touch.cpp:132
#, kde-format
msgid "Overview"
msgstr "Преглед"
#: main.cpp:167 touch.cpp:131
#: main.cpp:167 touch.cpp:134
#, kde-format
msgid "Toggle window switching"
msgstr "Превключване на прозорци"
#: main.cpp:168 touch.cpp:132
#: main.cpp:168 touch.cpp:135
#, kde-format
msgid "Toggle alternative window switching"
msgstr "Алтернативно превключване на прозорци"

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kcmkwm\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-11-02 01:40+0000\n"
"POT-Creation-Date: 2024-02-06 03:08+0000\n"
"PO-Revision-Date: 2022-12-05 00:26+0100\n"
"Last-Translator: Mincho Kondarev <mkondarev@yahoo.de>\n"
"Language-Team: Bulgarian <kde-i18n-doc@kde.org>\n"
@ -886,26 +886,8 @@ msgstr ""
msgid "Multiscreen behavior:"
msgstr "Поведение при няколко екрана:"
#. i18n: ectx: property (whatsThis), widget (QCheckBox, kcfg_ActiveMouseScreen)
#: focus.ui:203
#, kde-format
msgid ""
"When this option is enabled, the active screen (where new windows appear, "
"for example) is the screen containing the mouse pointer. When disabled, the "
"active screen is the screen containing the focused window."
msgstr ""
"Когато тази опция е активирана, активният екран е екранът, съдържащ "
"показалеца на мишката (там например се появяват новите прозорци) . Когато е "
"деактивиран, активният екран е екранът, съдържащ фокусирания прозорец."
#. i18n: ectx: property (text), widget (QCheckBox, kcfg_ActiveMouseScreen)
#: focus.ui:206
#, kde-format
msgid "Active screen follows &mouse"
msgstr "Активният екран следва &мишката"
#. i18n: ectx: property (whatsThis), widget (QCheckBox, kcfg_SeparateScreenFocus)
#: focus.ui:213
#: focus.ui:203
#, kde-format
msgid ""
"When this option is enabled, focus operations are limited only to the active "
@ -915,13 +897,13 @@ msgstr ""
"до активния екран на Xinerama"
#. i18n: ectx: property (text), widget (QCheckBox, kcfg_SeparateScreenFocus)
#: focus.ui:216
#: focus.ui:206
#, kde-format
msgid "&Separate screen focus"
msgstr "&Отделен фокус на екрана"
#. i18n: ectx: property (text), widget (QLabel, windowFocusPolicyDescriptionLabel)
#: focus.ui:229
#: focus.ui:219
#, kde-format
msgid "Window activation policy description"
msgstr "Описание на правилата за активиране на прозореца"
@ -1240,7 +1222,7 @@ msgstr ""
msgid "Only when overlapping"
msgstr "Само при припокриване"
#: windows.cpp:93
#: windows.cpp:92
#, kde-format
msgid ""
"<em>Click to focus:</em> A window becomes active when you click into it. "
@ -1250,7 +1232,7 @@ msgstr ""
"върху него.Това поведение е често срещано при други операционни системи и е "
"вероятно това, което искате."
#: windows.cpp:96
#: windows.cpp:95
#, kde-format
msgid ""
"<em>Click to focus (mouse precedence):</em> Mostly the same as <em>Click to "
@ -1265,7 +1247,7 @@ msgstr ""
"е предпочитан кандидат. Необичаен, но възможен вариант на <em> Щракване за "
"фокусиране </em>."
#: windows.cpp:99
#: windows.cpp:98
#, kde-format
msgid ""
"<em>Focus follows mouse:</em> Moving the mouse onto a window will activate "
@ -1279,7 +1261,7 @@ msgstr ""
"Предотвратяване на отнемане на фокус </em>. Приемете го като <em> Щракване "
"за фокусиране</em> , но без да се налага действително да щраквате."
#: windows.cpp:102
#: windows.cpp:101
#, kde-format
msgid ""
"This is mostly the same as <em>Focus follows mouse</em>. If an active window "
@ -1292,7 +1274,7 @@ msgstr ""
"момента) прозорецът под мишката е предпочитан кандидат. Изберете това,ако "
"искате фокус, контролиран от задържането на показалеца."
#: windows.cpp:105
#: windows.cpp:104
#, kde-format
msgid ""
"<em>Focus under mouse:</em> The focus always remains on the window under the "
@ -1307,7 +1289,7 @@ msgstr ""
"на политиката и няма да работят. Много вероятно, вместо това, ще искате да "
"използвате <em> Фокусът следва мишката (предимство на мишката) </em>!"
#: windows.cpp:108
#: windows.cpp:107
#, kde-format
msgid ""
"<em>Focus strictly under mouse:</em> The focus is always on the window under "
@ -1324,3 +1306,15 @@ msgstr ""
"\") </em> противоречат на политика за активиране и няма да работят. Най-"
"вероятно, вместо това, ще искате да използвате <em> Фокусът следва мишка "
"(предимство на мишката) </em>!"
#~ msgid ""
#~ "When this option is enabled, the active screen (where new windows appear, "
#~ "for example) is the screen containing the mouse pointer. When disabled, "
#~ "the active screen is the screen containing the focused window."
#~ msgstr ""
#~ "Когато тази опция е активирана, активният екран е екранът, съдържащ "
#~ "показалеца на мишката (там например се появяват новите прозорци) . Когато "
#~ "е деактивиран, активният екран е екранът, съдържащ фокусирания прозорец."
#~ msgid "Active screen follows &mouse"
#~ msgstr "Активният екран следва &мишката"

File diff suppressed because it is too large Load Diff

View File

@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kcmkwm\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-11-02 01:40+0000\n"
"POT-Creation-Date: 2024-02-06 03:08+0000\n"
"PO-Revision-Date: 2010-06-01 10:33-0700\n"
"Last-Translator: Deepayan Sarkar <deepayan.sarkar@gmail.com>\n"
"Language-Team: Bengali <kde-translation@bengalinux.org>\n"
@ -889,23 +889,8 @@ msgstr ""
msgid "Multiscreen behavior:"
msgstr ""
#. i18n: ectx: property (whatsThis), widget (QCheckBox, kcfg_ActiveMouseScreen)
#: focus.ui:203
#, kde-format
msgid ""
"When this option is enabled, the active screen (where new windows appear, "
"for example) is the screen containing the mouse pointer. When disabled, the "
"active screen is the screen containing the focused window."
msgstr ""
#. i18n: ectx: property (text), widget (QCheckBox, kcfg_ActiveMouseScreen)
#: focus.ui:206
#, kde-format
msgid "Active screen follows &mouse"
msgstr "&সক্রিয় স্ক্রীন মাউস অনুসরণ করে"
#. i18n: ectx: property (whatsThis), widget (QCheckBox, kcfg_SeparateScreenFocus)
#: focus.ui:213
#: focus.ui:203
#, kde-format
msgid ""
"When this option is enabled, focus operations are limited only to the active "
@ -913,14 +898,14 @@ msgid ""
msgstr ""
#. i18n: ectx: property (text), widget (QCheckBox, kcfg_SeparateScreenFocus)
#: focus.ui:216
#: focus.ui:206
#, fuzzy, kde-format
#| msgid "S&eparate screen focus"
msgid "&Separate screen focus"
msgstr "&আলাদা স্ক্রীণ ফোকাস"
#. i18n: ectx: property (text), widget (QLabel, windowFocusPolicyDescriptionLabel)
#: focus.ui:229
#: focus.ui:219
#, kde-format
msgid "Window activation policy description"
msgstr ""
@ -1253,14 +1238,14 @@ msgstr ""
msgid "Only when overlapping"
msgstr "কেব&লমাত্র উপরিপাতন হলে উইন্ডোগুলি আটকে দাও"
#: windows.cpp:93
#: windows.cpp:92
#, kde-format
msgid ""
"<em>Click to focus:</em> A window becomes active when you click into it. "
"This behavior is common on other operating systems and likely what you want."
msgstr ""
#: windows.cpp:96
#: windows.cpp:95
#, kde-format
msgid ""
"<em>Click to focus (mouse precedence):</em> Mostly the same as <em>Click to "
@ -1270,7 +1255,7 @@ msgid ""
"em>."
msgstr ""
#: windows.cpp:99
#: windows.cpp:98
#, kde-format
msgid ""
"<em>Focus follows mouse:</em> Moving the mouse onto a window will activate "
@ -1279,7 +1264,7 @@ msgid ""
"to focus</em> just without having to actually click."
msgstr ""
#: windows.cpp:102
#: windows.cpp:101
#, kde-format
msgid ""
"This is mostly the same as <em>Focus follows mouse</em>. If an active window "
@ -1288,7 +1273,7 @@ msgid ""
"if you want a hover controlled focus."
msgstr ""
#: windows.cpp:105
#: windows.cpp:104
#, kde-format
msgid ""
"<em>Focus under mouse:</em> The focus always remains on the window under the "
@ -1298,7 +1283,7 @@ msgid ""
"precedence)</em> instead!"
msgstr ""
#: windows.cpp:108
#: windows.cpp:107
#, kde-format
msgid ""
"<em>Focus strictly under mouse:</em> The focus is always on the window under "
@ -1309,6 +1294,9 @@ msgid ""
"follows mouse (mouse precedence)</em> instead!"
msgstr ""
#~ msgid "Active screen follows &mouse"
#~ msgstr "&সক্রিয় স্ক্রীন মাউস অনুসরণ করে"
#~ msgctxt "NAME OF TRANSLATORS"
#~ msgid "Your names"
#~ msgstr "ডাঃ অনির্বাণ মিত্র, দীপায়ন সরকার"

File diff suppressed because it is too large Load Diff

View File

@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kcmkwindecoration\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-08-06 02:04+0000\n"
"POT-Creation-Date: 2024-01-14 03:08+0000\n"
"PO-Revision-Date: 2009-01-13 17:22+0530\n"
"Last-Translator: Runa Bhattacharjee <runab@redhat.com>\n"
"Language-Team: Bengali INDIA <fedora-trans-bn_IN@redhat.com>\n"
@ -69,7 +69,7 @@ msgstr ""
msgid "Keep above other windows"
msgstr ""
#: kcm.cpp:176
#: kcm.cpp:177
#, kde-format
msgctxt "%1 is the name of a border size"
msgid "Theme's default (%1)"

View File

@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kcmkwinrules\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-12-08 01:36+0000\n"
"POT-Creation-Date: 2024-02-17 02:27+0000\n"
"PO-Revision-Date: 2009-01-07 14:37+0530\n"
"Last-Translator: Runa Bhattacharjee <runab@redhat.com>\n"
"Language-Team: Bengali INDIA <fedora-trans-bn_IN@redhat.com>\n"
@ -273,7 +273,7 @@ msgstr ""
msgid "Screen"
msgstr "স্প্ল্যাশ স্ক্রিন"
#: rulesmodel.cpp:513
#: rulesmodel.cpp:513 rulesmodel.cpp:922
#, fuzzy, kde-format
#| msgid "&Fullscreen"
msgid "Fullscreen"
@ -410,7 +410,7 @@ msgstr ""
#: rulesmodel.cpp:609 rulesmodel.cpp:614 rulesmodel.cpp:620 rulesmodel.cpp:625
#: rulesmodel.cpp:631 rulesmodel.cpp:658 rulesmodel.cpp:686 rulesmodel.cpp:692
#: rulesmodel.cpp:704 rulesmodel.cpp:709 rulesmodel.cpp:715 rulesmodel.cpp:720
#: rulesmodel.cpp:704 rulesmodel.cpp:709 rulesmodel.cpp:714 rulesmodel.cpp:719
#, kde-format
msgid "Appearance & Fixes"
msgstr ""
@ -521,21 +521,20 @@ msgid "Closeable"
msgstr "বন্ধ করার যোগ্য (&C)"
#: rulesmodel.cpp:709
#, fuzzy, kde-format
#| msgid "Window &type"
msgid "Set window type"
msgstr "উইন্ডোর প্রকৃতি (&t)"
#: rulesmodel.cpp:715
#, kde-format
msgid "Desktop file name"
msgstr ""
#: rulesmodel.cpp:720
#: rulesmodel.cpp:714
#, kde-format
msgid "Block compositing"
msgstr ""
#: rulesmodel.cpp:719
#, kde-format
msgid "Layer"
msgstr ""
#: rulesmodel.cpp:772
#, fuzzy, kde-format
#| msgid "Window &class (application type):"
@ -593,7 +592,7 @@ msgstr ""
msgid "Splash Screen"
msgstr "স্প্ল্যাশ স্ক্রিন"
#: rulesmodel.cpp:815
#: rulesmodel.cpp:815 rulesmodel.cpp:917
#, kde-format
msgid "Desktop"
msgstr "ডেস্কটপ"
@ -689,7 +688,7 @@ msgstr "শূণ্য"
msgid "Low"
msgstr "কম"
#: rulesmodel.cpp:889
#: rulesmodel.cpp:889 rulesmodel.cpp:919
#, kde-format
msgid "Normal"
msgstr "স্বাভাবিক"
@ -704,13 +703,49 @@ msgstr "বেশি"
msgid "Extreme"
msgstr ""
#: rulesmodel.cpp:934
#: rulesmodel.cpp:918
#, kde-format
msgid "Below"
msgstr ""
#: rulesmodel.cpp:920
#, kde-format
msgid "Above"
msgstr ""
#: rulesmodel.cpp:921
#, fuzzy, kde-format
#| msgid "&Position"
msgid "Notification"
msgstr "অবস্থান (&P)"
#: rulesmodel.cpp:923
#, kde-format
msgid "Popup"
msgstr ""
#: rulesmodel.cpp:924
#, kde-format
msgid "Critical Notification"
msgstr ""
#: rulesmodel.cpp:925
#, kde-format
msgid "OSD"
msgstr ""
#: rulesmodel.cpp:926
#, kde-format
msgid "Overlay"
msgstr ""
#: rulesmodel.cpp:951
#, fuzzy, kde-format
#| msgid "On Main Window"
msgid "Unmanaged window"
msgstr "প্রধান উইন্ডোর মধ্যে"
#: rulesmodel.cpp:935
#: rulesmodel.cpp:952
#, kde-format
msgid "Could not detect window properties. The window is not managed by KWin."
msgstr ""
@ -869,29 +904,29 @@ msgstr[1] ""
msgid "Add property to the rule"
msgstr ""
#: ui/RulesEditor.qml:278 ui/ValueEditor.qml:54
#: ui/RulesEditor.qml:279 ui/ValueEditor.qml:54
#, kde-format
msgid "Yes"
msgstr ""
#: ui/RulesEditor.qml:278 ui/ValueEditor.qml:60
#: ui/RulesEditor.qml:279 ui/ValueEditor.qml:60
#, fuzzy, kde-format
#| msgid "None"
msgid "No"
msgstr "শূণ্য"
#: ui/RulesEditor.qml:280 ui/ValueEditor.qml:168 ui/ValueEditor.qml:175
#: ui/RulesEditor.qml:281 ui/ValueEditor.qml:168 ui/ValueEditor.qml:175
#, kde-format
msgid "%1 %"
msgstr ""
#: ui/RulesEditor.qml:282
#: ui/RulesEditor.qml:283
#, kde-format
msgctxt "Coordinates (x, y)"
msgid "(%1, %2)"
msgstr ""
#: ui/RulesEditor.qml:284
#: ui/RulesEditor.qml:285
#, kde-format
msgctxt "Size (width, height)"
msgid "(%1, %2)"
@ -903,6 +938,11 @@ msgctxt "(x, y) coordinates separator in size/position"
msgid "x"
msgstr ""
#, fuzzy
#~| msgid "Window &type"
#~ msgid "Set window type"
#~ msgstr "উইন্ডোর প্রকৃতি (&t)"
#, fuzzy
#~| msgid "WId of the window for special window settings."
#~ msgid "KWin id of the window for special window settings."

View File

@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kcmkwm\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-11-02 01:40+0000\n"
"POT-Creation-Date: 2024-02-06 03:08+0000\n"
"PO-Revision-Date: 2009-01-07 16:17+0530\n"
"Last-Translator: Runa Bhattacharjee <runab@redhat.com>\n"
"Language-Team: Bengali INDIA <fedora-trans-bn_IN@redhat.com>\n"
@ -814,23 +814,8 @@ msgstr ""
msgid "Multiscreen behavior:"
msgstr ""
#. i18n: ectx: property (whatsThis), widget (QCheckBox, kcfg_ActiveMouseScreen)
#: focus.ui:203
#, kde-format
msgid ""
"When this option is enabled, the active screen (where new windows appear, "
"for example) is the screen containing the mouse pointer. When disabled, the "
"active screen is the screen containing the focused window."
msgstr ""
#. i18n: ectx: property (text), widget (QCheckBox, kcfg_ActiveMouseScreen)
#: focus.ui:206
#, kde-format
msgid "Active screen follows &mouse"
msgstr ""
#. i18n: ectx: property (whatsThis), widget (QCheckBox, kcfg_SeparateScreenFocus)
#: focus.ui:213
#: focus.ui:203
#, kde-format
msgid ""
"When this option is enabled, focus operations are limited only to the active "
@ -838,13 +823,13 @@ msgid ""
msgstr ""
#. i18n: ectx: property (text), widget (QCheckBox, kcfg_SeparateScreenFocus)
#: focus.ui:216
#: focus.ui:206
#, kde-format
msgid "&Separate screen focus"
msgstr ""
#. i18n: ectx: property (text), widget (QLabel, windowFocusPolicyDescriptionLabel)
#: focus.ui:229
#: focus.ui:219
#, kde-format
msgid "Window activation policy description"
msgstr ""
@ -1159,14 +1144,14 @@ msgstr ""
msgid "Only when overlapping"
msgstr "শুধুমাত্র উইন্ডো স্থানান্তর কালে (&w)"
#: windows.cpp:93
#: windows.cpp:92
#, kde-format
msgid ""
"<em>Click to focus:</em> A window becomes active when you click into it. "
"This behavior is common on other operating systems and likely what you want."
msgstr ""
#: windows.cpp:96
#: windows.cpp:95
#, kde-format
msgid ""
"<em>Click to focus (mouse precedence):</em> Mostly the same as <em>Click to "
@ -1176,7 +1161,7 @@ msgid ""
"em>."
msgstr ""
#: windows.cpp:99
#: windows.cpp:98
#, kde-format
msgid ""
"<em>Focus follows mouse:</em> Moving the mouse onto a window will activate "
@ -1185,7 +1170,7 @@ msgid ""
"to focus</em> just without having to actually click."
msgstr ""
#: windows.cpp:102
#: windows.cpp:101
#, kde-format
msgid ""
"This is mostly the same as <em>Focus follows mouse</em>. If an active window "
@ -1194,7 +1179,7 @@ msgid ""
"if you want a hover controlled focus."
msgstr ""
#: windows.cpp:105
#: windows.cpp:104
#, kde-format
msgid ""
"<em>Focus under mouse:</em> The focus always remains on the window under the "
@ -1204,7 +1189,7 @@ msgid ""
"precedence)</em> instead!"
msgstr ""
#: windows.cpp:108
#: windows.cpp:107
#, kde-format
msgid ""
"<em>Focus strictly under mouse:</em> The focus is always on the window under "

File diff suppressed because it is too large Load Diff

View File

@ -4,7 +4,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kcmkwindecoration\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-08-06 02:04+0000\n"
"POT-Creation-Date: 2024-01-14 03:08+0000\n"
"PO-Revision-Date: 2004-07-08 22:51+0200\n"
"Last-Translator: Thierry Vignaud <tvignaud.com>\n"
"Language-Team: Brezhoneg <Suav.Icb.fr>\n"
@ -65,7 +65,7 @@ msgstr ""
msgid "Keep above other windows"
msgstr ""
#: kcm.cpp:176
#: kcm.cpp:177
#, kde-format
msgctxt "%1 is the name of a border size"
msgid "Theme's default (%1)"

View File

@ -4,7 +4,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kcmkwinrules\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-12-08 01:36+0000\n"
"POT-Creation-Date: 2024-02-17 02:27+0000\n"
"PO-Revision-Date: 2004-07-08 17:18+0200\n"
"Last-Translator: Thierry Vignaud <tvignaud.com>\n"
"Language-Team: Brezhoneg <Suav.Icb.fr>\n"
@ -267,7 +267,7 @@ msgstr ""
msgid "Screen"
msgstr "Skramm-degemer"
#: rulesmodel.cpp:513
#: rulesmodel.cpp:513 rulesmodel.cpp:922
#, fuzzy, kde-format
#| msgid "&Fullscreen"
msgid "Fullscreen"
@ -400,7 +400,7 @@ msgstr ""
#: rulesmodel.cpp:609 rulesmodel.cpp:614 rulesmodel.cpp:620 rulesmodel.cpp:625
#: rulesmodel.cpp:631 rulesmodel.cpp:658 rulesmodel.cpp:686 rulesmodel.cpp:692
#: rulesmodel.cpp:704 rulesmodel.cpp:709 rulesmodel.cpp:715 rulesmodel.cpp:720
#: rulesmodel.cpp:704 rulesmodel.cpp:709 rulesmodel.cpp:714 rulesmodel.cpp:719
#, kde-format
msgid "Appearance & Fixes"
msgstr ""
@ -509,21 +509,20 @@ msgid "Closeable"
msgstr ""
#: rulesmodel.cpp:709
#, fuzzy, kde-format
#| msgid "Window &type"
msgid "Set window type"
msgstr "&Giz ar prenestr"
#: rulesmodel.cpp:715
#, kde-format
msgid "Desktop file name"
msgstr ""
#: rulesmodel.cpp:720
#: rulesmodel.cpp:714
#, kde-format
msgid "Block compositing"
msgstr ""
#: rulesmodel.cpp:719
#, kde-format
msgid "Layer"
msgstr ""
#: rulesmodel.cpp:772
#, fuzzy, kde-format
#| msgid "Window &class (application type):"
@ -581,7 +580,7 @@ msgstr ""
msgid "Splash Screen"
msgstr "Skramm-degemer"
#: rulesmodel.cpp:815
#: rulesmodel.cpp:815 rulesmodel.cpp:917
#, kde-format
msgid "Desktop"
msgstr "Burev"
@ -676,7 +675,7 @@ msgstr "Ebet"
msgid "Low"
msgstr "Izel"
#: rulesmodel.cpp:889
#: rulesmodel.cpp:889 rulesmodel.cpp:919
#, kde-format
msgid "Normal"
msgstr "Boas"
@ -691,13 +690,49 @@ msgstr "Uhel"
msgid "Extreme"
msgstr ""
#: rulesmodel.cpp:934
#: rulesmodel.cpp:918
#, kde-format
msgid "Below"
msgstr ""
#: rulesmodel.cpp:920
#, kde-format
msgid "Above"
msgstr ""
#: rulesmodel.cpp:921
#, fuzzy, kde-format
#| msgid "&Position"
msgid "Notification"
msgstr "&Lec'h"
#: rulesmodel.cpp:923
#, kde-format
msgid "Popup"
msgstr ""
#: rulesmodel.cpp:924
#, kde-format
msgid "Critical Notification"
msgstr ""
#: rulesmodel.cpp:925
#, kde-format
msgid "OSD"
msgstr ""
#: rulesmodel.cpp:926
#, kde-format
msgid "Overlay"
msgstr ""
#: rulesmodel.cpp:951
#, fuzzy, kde-format
#| msgid "On Main Window"
msgid "Unmanaged window"
msgstr "War ar brenestr gentañ"
#: rulesmodel.cpp:935
#: rulesmodel.cpp:952
#, kde-format
msgid "Could not detect window properties. The window is not managed by KWin."
msgstr ""
@ -853,29 +888,29 @@ msgstr[1] ""
msgid "Add property to the rule"
msgstr ""
#: ui/RulesEditor.qml:278 ui/ValueEditor.qml:54
#: ui/RulesEditor.qml:279 ui/ValueEditor.qml:54
#, kde-format
msgid "Yes"
msgstr ""
#: ui/RulesEditor.qml:278 ui/ValueEditor.qml:60
#: ui/RulesEditor.qml:279 ui/ValueEditor.qml:60
#, fuzzy, kde-format
#| msgid "None"
msgid "No"
msgstr "Ebet"
#: ui/RulesEditor.qml:280 ui/ValueEditor.qml:168 ui/ValueEditor.qml:175
#: ui/RulesEditor.qml:281 ui/ValueEditor.qml:168 ui/ValueEditor.qml:175
#, kde-format
msgid "%1 %"
msgstr ""
#: ui/RulesEditor.qml:282
#: ui/RulesEditor.qml:283
#, kde-format
msgctxt "Coordinates (x, y)"
msgid "(%1, %2)"
msgstr ""
#: ui/RulesEditor.qml:284
#: ui/RulesEditor.qml:285
#, kde-format
msgctxt "Size (width, height)"
msgid "(%1, %2)"
@ -887,6 +922,11 @@ msgctxt "(x, y) coordinates separator in size/position"
msgid "x"
msgstr ""
#, fuzzy
#~| msgid "Window &type"
#~ msgid "Set window type"
#~ msgstr "&Giz ar prenestr"
#, fuzzy
#~| msgid "Application settings for %1"
#~ msgctxt "Window caption for the application wide rules dialog"

View File

@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kcmkwm-1.1\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-11-02 01:40+0000\n"
"POT-Creation-Date: 2024-02-06 03:08+0000\n"
"PO-Revision-Date: 2004-07-08 22:32+0200\n"
"Last-Translator: Jañ-Mai Drapier <jan-mai.drapier@mail.dotcom.fr>\n"
"Language-Team: Brezhoneg <Suav.Icb@wanadoo.fr>\n"
@ -816,23 +816,8 @@ msgstr ""
msgid "Multiscreen behavior:"
msgstr ""
#. i18n: ectx: property (whatsThis), widget (QCheckBox, kcfg_ActiveMouseScreen)
#: focus.ui:203
#, kde-format
msgid ""
"When this option is enabled, the active screen (where new windows appear, "
"for example) is the screen containing the mouse pointer. When disabled, the "
"active screen is the screen containing the focused window."
msgstr ""
#. i18n: ectx: property (text), widget (QCheckBox, kcfg_ActiveMouseScreen)
#: focus.ui:206
#, kde-format
msgid "Active screen follows &mouse"
msgstr ""
#. i18n: ectx: property (whatsThis), widget (QCheckBox, kcfg_SeparateScreenFocus)
#: focus.ui:213
#: focus.ui:203
#, kde-format
msgid ""
"When this option is enabled, focus operations are limited only to the active "
@ -840,13 +825,13 @@ msgid ""
msgstr ""
#. i18n: ectx: property (text), widget (QCheckBox, kcfg_SeparateScreenFocus)
#: focus.ui:216
#: focus.ui:206
#, kde-format
msgid "&Separate screen focus"
msgstr ""
#. i18n: ectx: property (text), widget (QLabel, windowFocusPolicyDescriptionLabel)
#: focus.ui:229
#: focus.ui:219
#, kde-format
msgid "Window activation policy description"
msgstr ""
@ -1154,14 +1139,14 @@ msgstr ""
msgid "Only when overlapping"
msgstr "&En ur fiñval ar prenester hepken"
#: windows.cpp:93
#: windows.cpp:92
#, kde-format
msgid ""
"<em>Click to focus:</em> A window becomes active when you click into it. "
"This behavior is common on other operating systems and likely what you want."
msgstr ""
#: windows.cpp:96
#: windows.cpp:95
#, kde-format
msgid ""
"<em>Click to focus (mouse precedence):</em> Mostly the same as <em>Click to "
@ -1171,7 +1156,7 @@ msgid ""
"em>."
msgstr ""
#: windows.cpp:99
#: windows.cpp:98
#, kde-format
msgid ""
"<em>Focus follows mouse:</em> Moving the mouse onto a window will activate "
@ -1180,7 +1165,7 @@ msgid ""
"to focus</em> just without having to actually click."
msgstr ""
#: windows.cpp:102
#: windows.cpp:101
#, kde-format
msgid ""
"This is mostly the same as <em>Focus follows mouse</em>. If an active window "
@ -1189,7 +1174,7 @@ msgid ""
"if you want a hover controlled focus."
msgstr ""
#: windows.cpp:105
#: windows.cpp:104
#, kde-format
msgid ""
"<em>Focus under mouse:</em> The focus always remains on the window under the "
@ -1199,7 +1184,7 @@ msgid ""
"precedence)</em> instead!"
msgstr ""
#: windows.cpp:108
#: windows.cpp:107
#, kde-format
msgid ""
"<em>Focus strictly under mouse:</em> The focus is always on the window under "

File diff suppressed because it is too large Load Diff

View File

@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: bosnianuniversetranslation\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-06-21 02:02+0000\n"
"POT-Creation-Date: 2024-01-14 03:08+0000\n"
"PO-Revision-Date: 2013-11-03 21:03+0000\n"
"Last-Translator: Samir Ribić <Unknown>\n"
"Language-Team: Bosnian <bs@li.org>\n"
@ -20,17 +20,17 @@ msgstr ""
"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && n"
"%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n"
#: module.cpp:50
#: module.cpp:49
#, kde-format
msgid "Import KWin Script"
msgstr "Uvezi KWin skriptu"
#: module.cpp:51
#: module.cpp:50
#, kde-format
msgid "*.kwinscript|KWin scripts (*.kwinscript)"
msgstr "*.kwinscript|KWin skripte (*.kwinscript)"
#: module.cpp:62
#: module.cpp:61
#, kde-format
msgctxt "Placeholder is error message returned from the install service"
msgid ""
@ -38,13 +38,13 @@ msgid ""
"%1"
msgstr ""
#: module.cpp:66
#: module.cpp:65
#, kde-format
msgctxt "Placeholder is name of the script that was imported"
msgid "The script \"%1\" was successfully imported."
msgstr ""
#: module.cpp:125
#: module.cpp:124
#, kde-format
msgid "Error when uninstalling KWin Script: %1"
msgstr ""

View File

@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kcmkwindecoration\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-08-06 02:04+0000\n"
"POT-Creation-Date: 2024-01-14 03:08+0000\n"
"PO-Revision-Date: 2015-02-03 11:42+0100\n"
"Last-Translator: Samir Ribic <sribic@etf.unsa.ba>\n"
"Language-Team: Bosnian <kde-i18n-doc@kde.org>\n"
@ -73,7 +73,7 @@ msgstr ""
msgid "Keep above other windows"
msgstr ""
#: kcm.cpp:176
#: kcm.cpp:177
#, kde-format
msgctxt "%1 is the name of a border size"
msgid "Theme's default (%1)"

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kcmkwinrules\n"
"Report-Msgid-Bugs-To: https://bugs.kde.org\n"
"POT-Creation-Date: 2023-12-08 01:36+0000\n"
"POT-Creation-Date: 2024-02-17 02:27+0000\n"
"PO-Revision-Date: 2014-10-20 19:53+0000\n"
"Last-Translator: Samir Ribić <Unknown>\n"
"Language-Team: bosanski <bs@li.org>\n"
@ -286,7 +286,7 @@ msgstr "Sve aktivnosti"
msgid "Screen"
msgstr "Ekran"
#: rulesmodel.cpp:513
#: rulesmodel.cpp:513 rulesmodel.cpp:922
#, fuzzy, kde-format
#| msgid "&Fullscreen"
msgid "Fullscreen"
@ -436,7 +436,7 @@ msgstr "&Nema naslovne trake i okvira"
#: rulesmodel.cpp:609 rulesmodel.cpp:614 rulesmodel.cpp:620 rulesmodel.cpp:625
#: rulesmodel.cpp:631 rulesmodel.cpp:658 rulesmodel.cpp:686 rulesmodel.cpp:692
#: rulesmodel.cpp:704 rulesmodel.cpp:709 rulesmodel.cpp:715 rulesmodel.cpp:720
#: rulesmodel.cpp:704 rulesmodel.cpp:709 rulesmodel.cpp:714 rulesmodel.cpp:719
#, fuzzy, kde-format
#| msgid "Appearance && &Fixes"
msgid "Appearance & Fixes"
@ -553,21 +553,20 @@ msgid "Closeable"
msgstr "&Zatvorljiv"
#: rulesmodel.cpp:709
#, fuzzy, kde-format
#| msgid "Window &type"
msgid "Set window type"
msgstr "&Tip prozora"
#: rulesmodel.cpp:715
#, kde-format
msgid "Desktop file name"
msgstr ""
#: rulesmodel.cpp:720
#: rulesmodel.cpp:714
#, kde-format
msgid "Block compositing"
msgstr "Kompozicija blokova"
#: rulesmodel.cpp:719
#, kde-format
msgid "Layer"
msgstr ""
#: rulesmodel.cpp:772
#, fuzzy, kde-format
#| msgid "Window &class (application):"
@ -625,7 +624,7 @@ msgstr "Otcijepljen meni"
msgid "Splash Screen"
msgstr "Uvodni ekran"
#: rulesmodel.cpp:815
#: rulesmodel.cpp:815 rulesmodel.cpp:917
#, kde-format
msgid "Desktop"
msgstr "Površ"
@ -733,7 +732,7 @@ msgid "Low"
msgstr "Nisko"
# >> @item:inlistbox Focus stealing prevention->Force
#: rulesmodel.cpp:889
#: rulesmodel.cpp:889 rulesmodel.cpp:919
#, kde-format
msgid "Normal"
msgstr "Normalno"
@ -750,14 +749,50 @@ msgstr "Visoko"
msgid "Extreme"
msgstr "Ekstremno"
#: rulesmodel.cpp:918
#, kde-format
msgid "Below"
msgstr ""
#: rulesmodel.cpp:920
#, kde-format
msgid "Above"
msgstr ""
#: rulesmodel.cpp:921
#, fuzzy, kde-format
#| msgid "&Position"
msgid "Notification"
msgstr "&Položaj"
#: rulesmodel.cpp:923
#, kde-format
msgid "Popup"
msgstr ""
#: rulesmodel.cpp:924
#, kde-format
msgid "Critical Notification"
msgstr ""
#: rulesmodel.cpp:925
#, kde-format
msgid "OSD"
msgstr ""
#: rulesmodel.cpp:926
#, kde-format
msgid "Overlay"
msgstr ""
# >> @item:inlistbox Placement->Force
#: rulesmodel.cpp:934
#: rulesmodel.cpp:951
#, fuzzy, kde-format
#| msgid "Unmanaged Window"
msgid "Unmanaged window"
msgstr "Neupravljani prozor"
#: rulesmodel.cpp:935
#: rulesmodel.cpp:952
#, kde-format
msgid "Could not detect window properties. The window is not managed by KWin."
msgstr ""
@ -924,31 +959,31 @@ msgstr[2] ""
msgid "Add property to the rule"
msgstr ""
#: ui/RulesEditor.qml:278 ui/ValueEditor.qml:54
#: ui/RulesEditor.qml:279 ui/ValueEditor.qml:54
#, kde-format
msgid "Yes"
msgstr ""
# >> @item:inlistbox +
#: ui/RulesEditor.qml:278 ui/ValueEditor.qml:60
#: ui/RulesEditor.qml:279 ui/ValueEditor.qml:60
#, fuzzy, kde-format
#| msgctxt "no focus stealing prevention"
#| msgid "None"
msgid "No"
msgstr "Nikakvo"
#: ui/RulesEditor.qml:280 ui/ValueEditor.qml:168 ui/ValueEditor.qml:175
#: ui/RulesEditor.qml:281 ui/ValueEditor.qml:168 ui/ValueEditor.qml:175
#, kde-format
msgid "%1 %"
msgstr ""
#: ui/RulesEditor.qml:282
#: ui/RulesEditor.qml:283
#, kde-format
msgctxt "Coordinates (x, y)"
msgid "(%1, %2)"
msgstr ""
#: ui/RulesEditor.qml:284
#: ui/RulesEditor.qml:285
#, kde-format
msgctxt "Size (width, height)"
msgid "(%1, %2)"
@ -960,6 +995,11 @@ msgctxt "(x, y) coordinates separator in size/position"
msgid "x"
msgstr ""
#, fuzzy
#~| msgid "Window &type"
#~ msgid "Set window type"
#~ msgstr "&Tip prozora"
#~ msgid "Window shall (not) appear in the taskbar."
#~ msgstr "Prozor se (ne) treba pojaviti u traci zadataka."

Some files were not shown because too many files have changed in this diff Show More