forked from len0rd/rockbox
Theme Editor: Switched error highlighting to the line numbers
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26785 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
3fec40194c
commit
0c38353869
3 changed files with 13 additions and 13 deletions
|
@ -128,9 +128,15 @@ void CodeEditor::lineNumberAreaPaintEvent(QPaintEvent *event)
|
|||
while (block.isValid() && top <= event->rect().bottom()) {
|
||||
if (block.isVisible() && bottom >= event->rect().top()) {
|
||||
QString number = QString::number(blockNumber + 1);
|
||||
/* Drawing an error circle if necessary */
|
||||
if(errors.contains(blockNumber + 1))
|
||||
{
|
||||
painter.fillRect(QRect(0, top, lineNumberArea->width(),
|
||||
fontMetrics().height()), Qt::red);
|
||||
}
|
||||
painter.setPen(Qt::black);
|
||||
painter.drawText(0, top, lineNumberArea->width(), fontMetrics().height(),
|
||||
Qt::AlignRight, number);
|
||||
painter.drawText(0, top, lineNumberArea->width(),
|
||||
fontMetrics().height(), Qt::AlignRight, number);
|
||||
}
|
||||
|
||||
block = block.next();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue