Commit graph

25917 commits

Author SHA1 Message Date
l10n daemon script
24168aebdb GIT_SILENT Sync po/docbooks with svn 2024-01-13 01:27:27 +00:00
l10n daemon script
2a07aa238f 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-13 01:15:23 +00:00
Ismael Asensio
b08a4a1896 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
2024-01-12 23:10:06 +01:00
Xaver Hugl
427ce522a2 opengl/glshader: print the shader source if compilation fails
The shader log is almost entirely useless without the source

CCBUG: 479279
2024-01-12 20:42:05 +00:00
Xaver Hugl
d4a3d6689e 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
2024-01-12 19:15:25 +01:00
Xaver Hugl
56fc8f83ac 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
2024-01-12 17:00:01 +01:00
Xaver Hugl
a89d1f8058 opengl/openglcontext: require support for RGBA16F framebuffers
It's effectively already required, this just checks it earlier
2024-01-12 15:19:25 +01:00
Vlad Zahorodnii
c59f385996 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
2024-01-12 12:29:33 +00:00
Vlad Zahorodnii
1c15a6dd88 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
2024-01-12 14:14:53 +02:00
Xaver Hugl
260bc0a61d 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
2024-01-11 23:21:22 +00:00
Xaver Hugl
451b878bb9 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
2024-01-11 19:07:51 +00:00
Vlad Zahorodnii
36222adb25 scene: Fix software cursor clip region
The dirty region is in the output local coordinate space.

BUG: 479583
2024-01-11 18:10:04 +00:00
Vlad Zahorodnii
571e4026ac core: Add Output::rectF 2024-01-11 18:10:04 +00:00
Vlad Zahorodnii
c314705d53 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.
2024-01-11 18:10:04 +00:00
Xaver Hugl
bc58d13ee8 opengl: don't crash in GLTexture::toImage with OpenGL ES
OpenGL ES 2 doesn't support glGetTexImage
2024-01-11 16:58:04 +00:00
Bart Ribbers
a879c59a08 Fix building of tests on Musl by making sure to include sys/select.h
Required for access to fd_set
2024-01-11 17:00:09 +01:00
Vlad Zahorodnii
bc30ca64dc 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.
2024-01-11 14:17:31 +00:00
Vlad Zahorodnii
4ab504c994 Add Window::captionNormalChanged()
This signal notifies when the client specified caption changes, not when
kwin changes it because it changed the suffix, etc.
2024-01-11 14:17:31 +00:00
Vlad Zahorodnii
68f1570d45 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
2024-01-11 13:44:36 +00:00
Vlad Zahorodnii
3a5ba58a45 effect: Install xcb.h
BUG: 479584
2024-01-11 09:10:06 +00:00
Jin Liu
18ba622c40 Update keyboard focus when exiting from a keyboard-grabbing effect
BUG: 479628
2024-01-11 16:40:44 +08:00
Jie Liu
e427ad73aa update keyboard focus when window switcher is closed.
BUG:477885

Signed-off-by: Jie Liu <liujie01@kylinos.cn>
2024-01-11 01:28:52 +00:00
l10n daemon script
4d3779f061 GIT_SILENT Sync po/docbooks with svn 2024-01-11 01:19:25 +00:00
Xaver Hugl
a05a6d8727 effect/offscreenquickview: always use GL_RGBA8
GL_RGB8 isn't supported by OpenGL ES

BUG: 479055
2024-01-10 20:56:15 +01:00
Vlad Zahorodnii
66b1462cf8 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.
2024-01-10 15:18:48 +00:00
Jonathan Esk-Riddell
61699e9ed3 Update version number for 6.0.80
GIT_SILENT
2024-01-10 14:03:49 +00:00
Vlad Zahorodnii
3f1e57de1c xwayland: Fix primary output identification
Output::geometry() returns a logical geometry, while the crtc rect is in
the device pixels.
2024-01-10 12:41:31 +00:00
Jonathan Esk-Riddell
cc49e25eac Update version number for 5.92.0
GIT_SILENT
2024-01-10 12:28:48 +00:00
l10n daemon script
f3618ffe9d GIT_SILENT Sync po/docbooks with svn 2024-01-10 02:15:23 +00:00
Xaver Hugl
0ed66ed5d2 move more opengl related files to the opengl folder 2024-01-09 19:45:59 +01:00
Vlad Zahorodnii
b214251f81 Force software cursor on Intel devices
kwin randomly freezes for a second when calling glFlush or glFenceSync.
In principle, this should not happen.

BUG: 474725
2024-01-09 18:03:45 +00:00
Vlad Zahorodnii
f7e8d3cefb scene: Add SurfaceItem::destinationSize()
Its main purpose is to reroute surface size updates through SurfaceItem
so it can invalidate quads cache. Not all SurfaceItems currently discard
them when needed. When proper item transform support lands,
setDestinationSize() could also change the surface scale instead.
2024-01-09 17:42:09 +00:00
Vlad Zahorodnii
6510fe6e5d scene: Fix SurfaceItem::bufferTransform()
The wayland spec is not quite clear about the transforms, but the buffer
transform indicates a transform from wl_surface to wl_buffer or compositor
global coordinate space to composited buffer.

On the other hand, SurfaceItem assumes that the order is vice versa.
2024-01-09 17:42:09 +00:00
Vlad Zahorodnii
f8df72497f opengl: Replace TextureTransform with OutputTransform
It reduces duplication of same math code.
2024-01-09 17:42:09 +00:00
Vlad Zahorodnii
27821e3c76 plugins/screenshot: Invert render transforms in the correct order
The render transform is applied first, after that, the texture is
flipped implicitly by opengl.

So in order to undo these transforms, we need to flip the image
vertically first, then undo the render target transform.
2024-01-09 17:42:09 +00:00
Vlad Zahorodnii
16809e6b15 core: Port RenderTarget to OutputTransform 2024-01-09 17:42:09 +00:00
Vlad Zahorodnii
c970d3261b core: Add OutputTransform::FlipY convenience aliases
`flip-y | rotate-N` transforms are equivalent to `flip-x | rotate-N`.
However, it is not intuitive to express transforms that flip the y axis
via flip-x transforms. This change adds convenience aliases to improve
code readability and keep code intuitive, which is going to be needed in
order to drop TextureTransforms flags.
2024-01-09 17:42:09 +00:00
Vlad Zahorodnii
9039612c20 core: Rename OutputTransform enums 2024-01-09 17:42:09 +00:00
Vlad Zahorodnii
47017d19de core: Make flip transform first
The wayland spec says we must flip first. FWIW it also matches how
kms processes reflect-x and reflect-y.
2024-01-09 17:42:09 +00:00
Vlad Zahorodnii
1905f7586e core: Change winding order of OutputTransform
Wayland spec says we must rotate counterclockwise.
2024-01-09 17:42:09 +00:00
Vlad Zahorodnii
11aa9abfe2 core: Drop viewport arg in RenderTarget::applyTransformation() 2024-01-09 17:42:09 +00:00
Vlad Zahorodnii
b733bb69bf core: Cleanup OutputTransform::map(QRectF,QRect)
Return the resulting value immediately than use moveLeft(),moveRight().
It makes no difference for QRectF, but it might be nicer for QRect which
would need to recompute the right and bottom coordinates twice.

I wanted to do this refactoring for a while but didn't do it due to the
lack of test coverage.
2024-01-09 17:42:09 +00:00
Vlad Zahorodnii
e6853a9109 core: Add OutputTransform::map(QPointF,QPoint) 2024-01-09 17:42:09 +00:00
Vlad Zahorodnii
a9b01a68b8 core: Add OutputTransform::map(QRect,Size) overloads
These can be useful in case a QRect needs to be mapped. One could
convert the QRect into a QRectF and then back to QRect, but given that
these conversion helpers are present in rendering hot paths, it would
be great to be more efficient and also potentially loosing precision
because of floating point arithmetic.
2024-01-09 17:42:09 +00:00
Vlad Zahorodnii
98a1b5098a core: Add OutputTransform::toMatrix() 2024-01-09 17:42:09 +00:00
Xaver Hugl
7f9cbbaa98 core/renderloop: improve frame scheduling heuristics with VRR
Instead of checking for fullscreen windows and deciding whether or not to schedule repaints
based on that, check if the active window is refreshing fast enough to be reasonable for vrr.
For automatic mode, vrr is also enabled with the active window instead of the direct scanout
candidate.

BUG: 478680
BUG: 477199
2024-01-09 17:06:01 +00:00
Xaver Hugl
e1373ae2e1 scene: add the presentation hint to Item
With this, the RenderLoop can use the Item instead of having to directly
deal with Wayland surfaces
2024-01-09 17:06:01 +00:00
Fushan Wen
a4283a2437 backends/x11: convert source cursor image to BGRX format
XCB_IMAGE_FORMAT_Z_PIXMAP is in BGRX format.

BUG: 476198
FIXED-IN: 6.0
2024-01-09 17:04:01 +00:00
Vlad Zahorodnii
9bbcc746c6 scene: Fix clipping in software cursor 2024-01-09 15:35:37 +00:00
Vlad Zahorodnii
5bb209a869 Install all core headers 2024-01-09 13:43:50 +00:00