Skip to content
Snippets Groups Projects
Commit 184c8b28 authored by Konstantinos Sideris's avatar Konstantinos Sideris
Browse files

Use a smaller font size for the timestamp

parent f272d922
No related branches found
No related tags found
No related merge requests found
......@@ -175,7 +175,9 @@ RoomInfoListItem::paintEvent(QPaintEvent *event)
p.setFont(headingFont);
p.setPen(titlePen);
const int msgStampWidth = QFontMetrics(QFont{}).width(lastMsgInfo_.timestamp) + 4;
QFont tsFont;
tsFont.setPointSizeF(tsFont.pointSizeF() * 0.9);
const int msgStampWidth = QFontMetrics(tsFont).width(lastMsgInfo_.timestamp) + 4;
// We use the full width of the widget if there is no unread msg bubble.
const int bottomLineWidthLimit = (unreadMsgCount_ > 0) ? msgStampWidth : 0;
......@@ -226,7 +228,7 @@ RoomInfoListItem::paintEvent(QPaintEvent *event)
else
p.setPen(QPen(timestampColor_));
p.setFont(QFont{});
p.setFont(tsFont);
p.drawText(QPoint(width() - wm.padding - msgStampWidth, top_y),
lastMsgInfo_.timestamp);
p.restore();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment