|
|
|
|
@ -1378,7 +1378,7 @@ void MessageDelegate::paint(QPainter *painter, const QStyleOptionViewItem &optio
|
|
|
|
|
layoutInviteText(layout, L.textRect.width()); |
|
|
|
|
QVector<QTextLayout::FormatRange> selections; |
|
|
|
|
if (singleTextSel && cv) { |
|
|
|
|
auto cursorAt = [&](const QPoint& point) { |
|
|
|
|
auto cursorAt = [&](const QPoint& point) -> int { |
|
|
|
|
for (int i = 0; i < layout.lineCount(); ++i) { |
|
|
|
|
const auto line = layout.lineAt(i); |
|
|
|
|
if (point.y() < line.y() + line.height()) return line.xToCursor(point.x()); |
|
|
|
|
|