Commit f40a4465 authored by Martin Tobias Holmedahl Sandsmark's avatar Martin Tobias Holmedahl Sandsmark Committed by Kurt Hindenburg
Browse files

Fix reverse URL hints

When reversing it never actually got the URL number in range if there
were more than 10 URLs visible.
parent 9bb6e3fe
......@@ -1499,15 +1499,17 @@ void TerminalDisplay::paintFilters(QPainter& painter)
region |= r;
}
if (_showUrlHint && urlNumber >= 0 && urlNumber < 10 && spot->type() == HotSpot::Link) {
// Position at the beginning of the URL
QRect hintRect(*region.begin());
hintRect.setWidth(r.height());
painter.fillRect(hintRect, QColor(0, 0, 0, 128));
painter.setPen(Qt::white);
painter.drawRect(hintRect.adjusted(0, 0, -1, -1));
painter.drawText(hintRect, Qt::AlignCenter, QString::number(urlNumber));
if (_showUrlHint && spot->type() == HotSpot::Link) {
if (urlNumber >= 0 && urlNumber < 10) {
// Position at the beginning of the URL
QRect hintRect(*region.begin());
hintRect.setWidth(r.height());
painter.fillRect(hintRect, QColor(0, 0, 0, 128));
painter.setPen(Qt::white);
painter.drawRect(hintRect.adjusted(0, 0, -1, -1));
painter.drawText(hintRect, Qt::AlignCenter, QString::number(urlNumber));
}
urlNumber += urlNumInc;
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment