Improve the label for showing the rich text controls and tell users what pressing enter will do.

This commit is contained in:
James Graham
2026-02-26 19:50:26 +00:00
parent 611374d4dd
commit 23c0bdb647
3 changed files with 20 additions and 11 deletions

View File

@@ -67,16 +67,25 @@ Item {
}
}
implicitHeight: core.implicitHeight + Kirigami.Units.largeSpacing
implicitHeight: column.implicitHeight + Kirigami.Units.largeSpacing
ChatBarCore {
id: core
ColumnLayout {
id: column
anchors.top: root.top
anchors.horizontalCenter: root.horizontalCenter
Message.room: root.currentRoom
room: root.currentRoom
maxAvailableWidth: chatBarSizeHelper.availableWidth
ChatBarCore {
id: core
Message.room: root.currentRoom
room: root.currentRoom
maxAvailableWidth: chatBarSizeHelper.availableWidth
}
QQC2.Label {
Layout.fillWidth: true
visible: !Kirigami.Setting.isMobile
text: NeoChatConfig.sendMessageWith === 1 ? i18nc("As in enter starts a new line in the chat bar", "Enter starts a new line") : i18nc("As in enter starts send the chat message", "Enter sends the message")
horizontalAlignment: Text.AlignRight
font.pointSize: Kirigami.Theme.defaultFont.pointSize * NeoChatConfig.fontScale * 0.75
}
}
LibNeoChat.DelegateSizeHelper {
id: chatBarSizeHelper

View File

@@ -192,7 +192,7 @@ RowLayout {
QQC2.ToolButton {
icon.name: "edit-select-text-symbolic"
text: i18nc("@action:button", "Rich Text")
text: NeoChatConfig.sendMessageWith === 1 ? i18nc("@action:button", "Hide Rich Text Controls") : i18nc("@action:button", "Show Rich Text Controls")
display: QQC2.AbstractButton.IconOnly
checkable: true
checked: NeoChatConfig.sendMessageWith === 1