From 9d9fbed60e645f4b6957b815de64f583b72ac0ab Mon Sep 17 00:00:00 2001 From: johndoe6345789 Date: Thu, 19 Mar 2026 08:10:18 +0000 Subject: [PATCH] fix(qt6): fix text clipping in badges, add hero spacing - CText: use ProportionalHeight for all variants (FixedHeight with 1.0 = 1px, clips text) - FrontPage: 8px top spacer, hero height 400px, content offset +16px for breathing room - Text centered in badge circles no longer cut off Co-Authored-By: Claude Opus 4.6 (1M context) --- frontends/qt6/FrontPage.qml | 9 +++++++-- qml/components/atoms/CText.qml | 4 ++-- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/frontends/qt6/FrontPage.qml b/frontends/qt6/FrontPage.qml index f4e108c6a..9deb91316 100644 --- a/frontends/qt6/FrontPage.qml +++ b/frontends/qt6/FrontPage.qml @@ -85,12 +85,15 @@ Rectangle { width: parent.width spacing: 0 + // Top breathing room + Item { Layout.preferredHeight: 8 } + // ════════════════════════════════════════════════════════ // HERO // ════════════════════════════════════════════════════════ Rectangle { Layout.fillWidth: true - Layout.preferredHeight: 380 + Layout.preferredHeight: 400 color: "transparent" // Blue gradient wash @@ -104,7 +107,9 @@ Rectangle { } ColumnLayout { - anchors.centerIn: parent + anchors.horizontalCenter: parent.horizontalCenter + anchors.verticalCenter: parent.verticalCenter + anchors.verticalCenterOffset: 16 width: Math.min(parent.width - 80, 720) spacing: 16 diff --git a/qml/components/atoms/CText.qml b/qml/components/atoms/CText.qml index 81705e270..ab963ad5c 100644 --- a/qml/components/atoms/CText.qml +++ b/qml/components/atoms/CText.qml @@ -73,9 +73,9 @@ Text { font.family: mono ? Theme.fontFamilyMono : Theme.fontFamily - // Only body1 gets expanded line height; everything else stays compact + // Only body1 gets expanded line height lineHeight: variant === "body1" ? 1.4 : 1.0 - lineHeightMode: variant === "body1" ? Text.ProportionalHeight : Text.FixedHeight + lineHeightMode: Text.ProportionalHeight // Default to no wrap — callers opt in with wrapMode: Text.Wrap wrapMode: truncate ? Text.NoWrap : Text.NoWrap