From 9769541ed5ec46d1227c9b84aa6bbac8039d82fa Mon Sep 17 00:00:00 2001 From: RickyRister Date: Sat, 30 Nov 2024 13:22:54 -0800 Subject: [PATCH] add comment about #5204 --- cockatrice/src/game/zones/view_zone_widget.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/cockatrice/src/game/zones/view_zone_widget.cpp b/cockatrice/src/game/zones/view_zone_widget.cpp index 0be2fa5d9..e23a714b8 100644 --- a/cockatrice/src/game/zones/view_zone_widget.cpp +++ b/cockatrice/src/game/zones/view_zone_widget.cpp @@ -136,6 +136,8 @@ ZoneViewWidget::ZoneViewWidget(Player *_player, connect(zone, SIGNAL(beingDeleted()), this, SLOT(zoneDeleted())); zone->initializeCards(cardList); + // QLabel sizes aren't taken into account until the widget is rendered. + // Force refresh after 1ms to fix glitchy rendering with long QLabels. auto *lastResizeBeforeVisibleTimer = new QTimer(this); connect(lastResizeBeforeVisibleTimer, &QTimer::timeout, this, [=] { resizeToZoneContents();