Summary:
If we know that we are going to disobey resize increment and aspect ratio
geometry hints, then there is no point for trying to constrain the client
size according to those hints. Just return early.
Reviewers: #kwin, davidedmundson
Reviewed By: #kwin, davidedmundson
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D27031
Summary:
Clarify that AbstractClient::minSize() and AbstractClient::maxSize()
specify the minimum and the maximum client size.
Reviewers: #kwin, davidedmundson
Reviewed By: #kwin, davidedmundson
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D26829
Summary:
Currently, there are a couple of issues with sizeForClientSize(). First
of all, we have a method called clientSizeToFrameSize() which does similar
thing except applying geometry constraints and checking window rules. The
other issue is that sizeForClientSize() is doing a bit too much, it checks
window rules, it applies a bunch of geometry constrains. Sometimes it
does not perform conversion between client sizes and frame sizes!
This change attempts to address those issues by replacing sizeForClientSize
with two similar methods and changing semantics of some methods of the
X11Client class.
The most significant difference between sizeForClientSize() and the new
methods is that neither constrainClientSize() nor constrainFrameSize()
check window rules. This is up to users of those methods. In many places,
we don't have to check window rules because we check isResizable(),
which returns false if the frame size is enforced by a window rule.
Reviewers: #kwin, davidedmundson
Reviewed By: #kwin, davidedmundson
Subscribers: davidedmundson, romangg, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D26828
Summary:
Touch events coming from libinput devices must be transformed according to the
current device rotation.
Test Plan: Manually.
Reviewers: #kwin
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D25921
Summary:
The calculation of cursor position and orientation on outputs rotations other
than 0° and 180° was faulty.
This patch fixes both.
Test Plan: In live session cursor looks and moves as expected.
Reviewers: #kwin
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D25909
Summary:
The previous code uses a fixed version of GSLS which does not match our suported GL targets. We need both, using kwin's existing MapTexture framework we can achieve the same thing in a better way with less code.
Test Plan:
Had some slight issues with the rotation, but everything appeared the same
as when I applied the patchset with the custom shader.
Reviewers: #kwin, zzag
Reviewed By: #kwin, zzag
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D26371
Summary:
In case the hardware is not able to rotate the output for the configured
rotation value do this rotation in a post-process step.
For that rendering the current view into a separate framebuffer bound to a
texture that then gets sampled to the default framebuffer in an additional
rendering pass through a simple shader rotating it.
This allows us to leave the Effects system and internal model-view-projection
matrix untouched. The rotation in the post-processing step is isolated.
BUG: 389665
FIXED-IN: 5.18
Test Plan: With KScreen all rotations work.
Reviewers: #kwin
Subscribers: davidedmundson, PureTryOut, z3ntu, zzag, univerz, kwin
Tags: #kwin
Maniphest Tasks: T6106
Differential Revision: https://phabricator.kde.org/D25907
Summary:
First we need to set a transformation, then update the backend. In DRM the
cursor gets updated and needs the new transformed size.
Longterm we need a pending state if we want to apply configuration changes
atomically or deny them.
Test Plan: Compiles.
Reviewers: #kwin, zzag
Reviewed By: #kwin, zzag
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D25903
Summary:
The getter pixelSize rotates the size of the mode. In contrast modeSize just
directly returns the current mode size.
Test Plan: Compiles
Reviewers: #kwin, zzag
Reviewed By: #kwin, zzag
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D25901
Summary:
Changes to a Wayland output that could affect the overall geometry
need to be communicated to the Screens class.
Test Plan: Compiles, runtime tested with other patches for rotation.
Reviewers: #kwin, zzag
Reviewed By: #kwin, zzag
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D25900
Summary:
KWin only renders into the default framebuffer, which is for example an EGL
surface.
To prepare a post-processing step with a different framebuffer allow the
framebuffer to be changable. For that KWin's current framebuffer must be
communicated to the GLRenderTarget class, which otherwise does not set it back
to KWin's current one when a render target is disabled again.
Test Plan: Compiles, with other patches for Gl based screen rotation
Reviewers: #kwin
Subscribers: fredrik, zzag, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D25904
Summary:
Planes might be able to do transformations without compositing required.
When changing the current transform try this with the primary plane. If this
fails fall back to no transformation at all through hardware and communicate
the fact and other information through some getters.
Also adds an environment variable to never do hardware transformations.
Test Plan: Compiles.
Reviewers: #kwin
Subscribers: zzag, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D25906
Summary:
The semantics of a window taking focus on user interaction apply to more roles. See D25851.
Given it is used by `KWindowSystem::forceActivateWindow` in kwayland-integration, it makes sense to pass focus to the window once it gets this property set.
Reviewers: #kwin
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D25968
Summary:
Typically by default newly added toplevel windows are added only to the
current activity.
Initially windows with no borders were added to all activities. This
causes problems particularly now with the newer frame extents support
leaving window behaviour quite inconsistent.
Since the time of the original code the taskbar gained control for
controlling activities allowing at least one method of changing them.
This means we can use this as the new filter.
BUG: 274931
Test Plan:
Opened gtk3-demo
Switched activities, it wasn't on the new one
Went back, altered it through the taskmanager, it worked
Reviewers: #kwin, zzag
Reviewed By: #kwin, zzag
Subscribers: zzag, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D27690
Test Plan:
KScreen now shows "Dell Inc." instead of DEL and
"Eizo Nano Corporation" instead of ENC in output names, which
matches closer to what's written on my monitors.
Reviewers: graesslin, davidedmundson, #plasma
Reviewed By: davidedmundson, #plasma
Subscribers: apol, feverfew, ngraham, davidedmundson, mart, kwin, sebas
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D10041
Summary:
The "Candy" category suffers from some problems:
- It does not need to exist; everything in it is purely appearance-related and could live in the existing "Appearance" category
- The name is inappropriate; "Eye Candy" would be better, but changing it to this has proven controversial in the past
Let's just remove the category and move everything in it into the "Appearance" category.
Test Plan:
Apply and compile
Open Desktop Effects KCM
See that the "Candy" category is no more and the "Appearance" category has more stuff in it
Reviewers: #kwin, #vdg, zzag, abetts
Reviewed By: #kwin, #vdg, zzag, abetts
Subscribers: abetts, zzag, kwin, kde-doc-english, GB_2
Tags: #kwin, #documentation
Differential Revision: https://phabricator.kde.org/D27658
Summary:
Otherwise the content overflows the frame when scrolling.
QQC2 scrollview docs say "ScrollView does not automatically clip its contents. If it is not used as a full-screen item, you should consider setting the clip property to true"
Test Plan:
Before:
{F8121150}
After:
{F8121152}
Reviewers: #kwin, #plasma, ngraham
Reviewed By: ngraham
Subscribers: ngraham, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D27558
Summary:
Otherwise the content overflows the frame when scrolling.
QQC2 scrollview docs say "ScrollView does not automatically clip its contents. If it is not used as a full-screen item, you should consider setting the clip property to true"
Test Plan:
Before:
{F8121150}
After:
{F8121152}
Reviewers: #kwin, #plasma, ngraham
Reviewed By: ngraham
Subscribers: ngraham, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D27558
Summary:
Otherwise the content overflows the frame when scrolling.
QQC2 scrollview docs say "ScrollView does not automatically clip its contents. If it is not used as a full-screen item, you should consider setting the clip property to true"
Test Plan:
Before:
{F8121150}
After:
{F8121152}
Reviewers: #kwin, #plasma, ngraham
Reviewed By: ngraham
Subscribers: ngraham, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D27558
Summary:
We need to schedule a workspace repaint in minimize() to ensure that
there are no ghost windows on Wayland.
Test Plan:
Make sure that window minimization effects are disabled,
minimize a window. Without this patch, you are going to see a ghost
window. With this patch, no ghost window.
Reviewers: #kwin, davidedmundson, apol
Reviewed By: #kwin, davidedmundson, apol
Subscribers: apol, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D27516
Summary:
Use of "style: Text.Raised" combined with UTF-8 emoji characters
currently crashes deep in font rendering code.
A report has been submitted upstream:
https://bugreports.qt.io/browse/QTBUG-82311
Given this crash is surprisingly common, this patch removes the text
shadow. I normally would be against removing features, but this was a
subtle effect anyway and frankly just made things look blurry. I doubt
it'll be missed.
BUG: 417699
BUG: 413179
Test Plan:
Made unit test for the crash in qmlscene
Fixed the issue there
Reviewers: #kwin, zzag
Reviewed By: #kwin, zzag
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D27488
Summary:
This regression was introduced by me, sorry. The client window may be at
location other than (0, 0), in which case we have to move it to (0, 0)
to ensure that the client contents is not covered by window frame.
BUG: 417584
FIXED-IN: 5.18.1
Reviewers: #kwin, broulik
Reviewed By: broulik
Subscribers: broulik, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D27456
Summary:
We need to provide the input geometry and the input transformation
matrix for Xwayland clients in order to make sure that input events
are correctly mapped from the global screen coordinates to the
screen-local coordinates.
BUG: 417444
FIXED-IN: 5.18.1
Reviewers: #kwin
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D27375