Bug 462396

Summary: KWin allows (and sometimes creates) nearly invisible 1-sized windows
Product: [Plasma] kwin Reporter: Louis Moureaux <m_louis30>
Component: generalAssignee: KWin default assignee <kwin-bugs-null>
Status: REPORTED ---    
Severity: normal CC: nate
Priority: NOR    
Version First Reported In: 5.26.2   
Target Milestone: ---   
Platform: Neon   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:
Attachments: Here I moved the window on top of the Submit Bug button

Description Louis Moureaux 2022-11-29 14:30:19 UTC
Created attachment 154138 [details]
Here I moved the window on top of the Submit Bug button

SUMMARY

[Sorry if wrong component or product.]

KWin on X11 allows windows to be extremely small, and window decorations follow suit, resulting in nearly invisible windows. Haven't tried on Wayland.

STEPS TO REPRODUCE
1. Execute the following PyQt code, preferably on a high-res or large display:

import sys
from PyQt5 import QtWidgets as w
app = w.QApplication(sys.argv)
wdg = w.QWidget()
wdg.resize(1, 1)
wdg.show()

2. Try to find the window you just opened

OBSERVED RESULT

The window is extremely small, making it very hard to find and interact with.

EXPECTED RESULT

Window decorations remain visible around the window. Not sure what to do with windows that have no decorations.

SOFTWARE/OS VERSIONS
Operating System: KDE neon 5.26
KDE Plasma Version: 5.26.2
KDE Frameworks Version: 5.99.0
Qt Version: 5.15.6
Kernel Version: 5.15.0-52-generic (64-bit)
Graphics Platform: X11
Processors: 8 × Intel® Core™ i5-10310U CPU @ 1.70GHz
Memory: 15.3 Gio of RAM
Graphics Processor: Mesa Intel® UHD Graphics
Manufacturer: Dell Inc.
Product Name: Latitude 7410

ADDITIONAL INFORMATION

KWin sometimes resizes a window to such a size by itself, which seems to be associated with switching between two screens with vastly different resolutions and a layout combining those.