From 29db4a0ba7196fb3c20cc3647ece5a06448266e7 Mon Sep 17 00:00:00 2001 From: Vitor Vieira <155513369+VitorVieiraZ@users.noreply.github.com> Date: Wed, 5 Jun 2024 05:23:00 -0300 Subject: [PATCH] Fixing section headers' wrapping and eliding (#3480) * fixing wraping for sectionTitle * last adjustment * post review fix --- app/qml/form/MMFormPage.qml | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/app/qml/form/MMFormPage.qml b/app/qml/form/MMFormPage.qml index 97641a7c0..228533669 100644 --- a/app/qml/form/MMFormPage.qml +++ b/app/qml/form/MMFormPage.qml @@ -224,7 +224,7 @@ Page { property string sectionTitle: section - height: section ? 76 * __dp : 0 + height: section ? childrenRect.height : 0 width: ListView.view.width // section bgnd @@ -233,15 +233,21 @@ Page { color: __style.lightGreenColor; } - Text { + MMComponents.MMText { id: sectionTitle text: section font: __style.h3 color: __style.forestColor + width: parent.width + wrapMode: Text.Wrap + elide: Text.ElideRight + topPadding: internal.formSpacing bottomPadding: internal.formSpacing + + maximumLineCount: 3 } } }