From 23dc88df60e2fd4ce1c3717c43c5d90609dede02 Mon Sep 17 00:00:00 2001 From: Arno Rehn Date: Sun, 28 Sep 2025 20:51:38 +0200 Subject: [PATCH] PollComponent: Apply word wrapping on long messages Long messages were not wrapped and would overflow. Correctly apply word wrapping and align all elements on the top of a row. --- src/messagecontent/PollComponent.qml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/messagecontent/PollComponent.qml b/src/messagecontent/PollComponent.qml index 86f591a94..dc91fcdd3 100644 --- a/src/messagecontent/PollComponent.qml +++ b/src/messagecontent/PollComponent.qml @@ -92,23 +92,31 @@ ColumnLayout { Layout.fillWidth: true QQC2.CheckBox { + Layout.alignment: Qt.AlignTop + enabled: !root.pollHandler.hasEnded checked: answerDelegate.localChoice onClicked: answerDelegate.clicked() } QQC2.Label { + Layout.alignment: Qt.AlignTop Layout.fillWidth: true text: answerDelegate.answerText + wrapMode: QQC2.Label.WordWrap } Kirigami.Icon { + Layout.alignment: Qt.AlignTop + implicitWidth: Kirigami.Units.iconSizes.small implicitHeight: implicitWidth visible: answerDelegate.isWinner source: "favorite-favorited" } QQC2.Label { + Layout.alignment: Qt.AlignTop + visible: root.pollHandler.kind == PollKind.Disclosed || root.pollHandler.hasEnded horizontalAlignment: Text.AlignRight text: i18ncp("@info", "%1 Vote", "%1 Votes", answerDelegate.count)