Bug 480210

Summary: apps (kdevelop, konsole, ...) windows shrink when tabs are added/closed
Product: [Plasma] kwin Reporter: Milian Wolff <mail>
Component: generalAssignee: KWin default assignee <kwin-bugs-null>
Status: RESOLVED DUPLICATE    
Severity: normal CC: fanzhuyifan
Priority: NOR    
Version: 5.27.10   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Milian Wolff 2024-01-23 08:46:40 UTC
SUMMARY

Since some time now some applications shrink when one interacts with them, and I believe this is not a reaction to a application side request, but rather something in the stack somewhere leading to this issue. I don't know if it's KWin or Breeze or whatever triggering this, as I'm not well acquainted with how this stack works.

STEPS TO REPRODUCE
1.  open konsole
2.  open tabs in konsole

alternatively:

1. open kdevelop
2. open some files

OBSERVED RESULT

the main window shrinks a little for every tab opened, kdevelop also resizes slightly when closing tabs.

Here's a backtrace I got by setting a breakpoint in `QWindow::heightChanged`, but note how it reacts to a XCB event - any suggestion on how I could track down where that async request originates?

```
Thread 1 "konsole" hit Breakpoint 3, QWindow::heightChanged (this=0x605c72e597b0, _t1=658) at .moc/moc_qwindow.cpp:776
776     {
(gdb) bt
#0  QWindow::heightChanged(int) (this=0x605c72e597b0, _t1=658) at .moc/moc_qwindow.cpp:776
#1  0x000075de04745a03 in QGuiApplicationPrivate::processGeometryChangeEvent(QWindowSystemInterfacePrivate::GeometryChangeEvent*) (e=<optimized out>) at kernel/qguiapplication.cpp:2617
#2  0x000075de0472a6f5 in QWindowSystemInterface::sendWindowSystemEvents(QFlags<QEventLoop::ProcessEventsFlag>) (flags=flags@entry=...) at kernel/qwindowsysteminterface.cpp:1169
#3  0x000075ddfd92f560 in xcbSourceDispatch(GSource*, GSourceFunc, gpointer) (source=<optimized out>) at /usr/src/debug/qt5-base/qtbase/src/plugins/platforms/xcb/qxcbeventdispatcher.cpp:105
#4  0x000075de023acf69 in g_main_dispatch (context=0x75ddf8000ec0) at ../glib/glib/gmain.c:3476
#5  0x000075de0240b367 in g_main_context_dispatch_unlocked (context=0x75ddf8000ec0) at ../glib/glib/gmain.c:4284
#6  g_main_context_iterate_unlocked.isra.0 (context=context@entry=0x75ddf8000ec0, block=block@entry=1, dispatch=dispatch@entry=1, self=<optimized out>) at ../glib/glib/gmain.c:4349
#7  0x000075de023ab162 in g_main_context_iteration (context=0x75ddf8000ec0, may_block=1) at ../glib/glib/gmain.c:4414
#8  0x000075de042ead0c in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) (this=0x605c72ba50a0, flags=...) at kernel/qeventdispatcher_glib.cpp:423
#9  0x000075de0429ac04 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) (this=this@entry=0x7ffce35b5580, flags=..., flags@entry=...) at ../../include/QtCore/../../src/corelib/global/qflags.h:69
#10 0x000075de0429c0a3 in QCoreApplication::exec() () at ../../include/QtCore/../../src/corelib/global/qflags.h:121
#11 0x0000605c7106db15 in  ()
#12 0x000075de03a45cd0 in __libc_start_call_main (main=main@entry=0x605c7106c020, argc=argc@entry=1, argv=argv@entry=0x7ffce35b5898) at ../sysdeps/nptl/libc_start_call_main.h:58
#13 0x000075de03a45d8a in __libc_start_main_impl (main=0x605c7106c020, argc=1, argv=0x7ffce35b5898, init=<optimized out>, fini=<optimized out>, rtld_fini=<optimized out>, stack_end=0x7ffce35b5888) at ../csu/libc-start.c:36
```

Note that I'm on Arch, but a colleague reproduced the same issue on OpenSuSE. Both of us use X11.

EXPECTED RESULT

the mainwindow doesn't change size

SOFTWARE/OS VERSIONS
Linux/KDE Plasma:  5.27.10
KDE Plasma Version: 5.27.10
KDE Frameworks Version: 5.27.10
Qt Version: 5.15.12

ADDITIONAL INFORMATION

I'm happy to help with debugging this if anyone can provide me further suggestions on what to investigate here. If this is not kwin related, then please point me to the suggested place to report this instead.

Thanks
Comment 1 fanzhuyifan 2024-01-23 18:57:44 UTC

*** This bug has been marked as a duplicate of bug 477700 ***