Layout Loop in NotificationItem.qml #3384
renato-chagas
started this conversation in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I finally tracked down the random freezes happening on the right sidebar.
At first I thought it was something related to Hyprland binds or Quickshell IPC, but after running Quickshell directly from the terminal and checking the logs, the actual issue turned out to be a QML layout loop inside
NotificationItem.qml.The logs constantly spammed:
After digging into it, I found two main causes.
The first one was this binding:
summaryTextwas deciding whether to fill width based on the parent's implicit width, while the parent width itself depended on the child geometry. So it created a circular layout dependency.The second issue was this:
Because the HTML string depended on
expandedContentColumn.width, the text was being rebuilt every time the layout changed slightly, which triggered another layout recalculation again and again.After replacing the conditional width logic with:
and removing the dynamic HTML width injection (using
Layout.preferredWidthinstead), the freezes completely disappeared.The sidebar now opens instantly and the topbar no longer becomes unresponsive after notifications arrive.
Maybe this helps someone else debugging similar random UI freezes in Quickshell/QML layouts.
Beta Was this translation helpful? Give feedback.
All reactions