1
0
Fork 0
mirror of https://git.jami.net/savoirfairelinux/jami-client-qt.git synced 2025-08-04 06:45:45 +02:00

SBSMessageBase: add text metrics on author

Change-Id: Idf3aee2c667c86ea9a224d68624f733a2250e83a
GitLab: #1551
This commit is contained in:
Sébastien Blin 2024-02-14 09:48:14 -05:00
parent 07e0b10478
commit 0b96cf5f1f

View file

@ -101,7 +101,16 @@ Control {
Label {
id: username
text: UtilsAdapter.getBestNameForUri(CurrentAccount.id, Author)
wrapMode: Text.NoWrap
text: textMetricsUsername.elidedText
TextMetrics {
id: textMetricsUsername
text: UtilsAdapter.getBestNameForUri(CurrentAccount.id, Author)
elideWidth: 200
elide: Qt.ElideMiddle
}
visible: (seq === MsgSeq.first || seq === MsgSeq.single) && !isOutgoing && !isReply
font.pointSize: JamiTheme.smallFontSize