Bug 459230

Summary: Blue rectangle for the upper left VD of a 4x4 grid
Product: [Plasma] kwin Reporter: postix <postix>
Component: effects-desktop-gridAssignee: KWin default assignee <kwin-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: dev.bacteriostat, kde, me, nate, notmart
Priority: NOR    
Version First Reported In: 5.25.90   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:
Attachments: kWin Support Info
Screenshot

Description postix 2022-09-16 16:37:05 UTC
STEPS TO REPRODUCE
1.  Two screens 2k@Abitrary scaling like 100%, 200% and 4k@200% scaling primary
2.  Open the grid effect

OBSERVED RESULT
On the primary, the upper left VD shows a blue rectangle. It goes away if the 2nd screen becomes disabled.

SOFTWARE/OS VERSIONS
Operating System: openSUSE Tumbleweed 20220914
KDE Plasma Version: 5.26.80
KDE Frameworks Version: 5.98.0
Qt Version: 5.15.5
Kernel Version: 5.19.8-1-default (64-bit)
Graphics Platform: Wayland
Graphics Processor: AMD Radeon RX 580 Series
Comment 1 postix 2022-09-16 16:37:18 UTC
Created attachment 152120 [details]
kWin Support Info
Comment 2 postix 2022-09-16 16:38:59 UTC
Created attachment 152121 [details]
Screenshot
Comment 3 postix 2022-09-16 16:40:42 UTC
It goes away when I add another VD within the grid effect and it's also not shown if I sequentially remove the extra VD again.
It comes back when re-open the grid effect though.
Comment 4 ratijas 2022-09-16 21:30:53 UTC
I can reproduce it even without a second screen. Maybe it takes to ever had it plugged in during current session, idk.

The outline is coming from this component in desktopgrid/main.qml:

> Repeater {
>     id: gridRepeater
> 
>     DesktopView {
>         id: thumbnail
> 
>         Rectangle {
>             anchors.fill: parent
>             color: "transparent"
>             border {
>                 color: PlasmaCore.Theme.highlightColor
>                 width: 1 / grid.scale
>             }
>             visible: parent.activeFocus
>         }
 
So, that means the first desktop view is holding an 'activeFocus'. More over, it should be possible to switch with arrows between windows and different desktops. It seems like an intended feature rather than a bug, though maybe poorly and ambiguously communicated.

The only thing I'd fix here, is to focus on current desktop first. For example, I'm on 3rd desktop (second row, first column), but the lop left one is still the one that gets highlighted.
Comment 5 postix 2022-09-17 11:28:52 UTC
> I can reproduce it even without a second screen. 
Me too now!

>  More over, it should be possible to switch with arrows between windows and different desktops.
True, it is possible to navigate with the arrow keys to other VDs to select windows there and in this case the rectangle moves alongside.
Though, it appears a little bit redundant since windows already have some highlighting, when focused.

Nevertheless, it doesn't follow the cursor and when having an empty VD selected with the blue rectangle, pressing enter/space/whatever doesn't open this VD and exit the grid effect as I'd expect.
Comment 6 David Edmundson 2022-09-27 15:30:24 UTC
>pressing enter/space/whatever doesn't open this VD and exit the grid effect as I'd expect.

It does now