Commit d4797bd9 authored by mae's avatar mae
Browse files

show the visual column in the line-column-label (makes a difference

when using tabs).

Column counting still starts with 1.
parent e8b95f63
......@@ -4203,8 +4203,8 @@ void BaseTextEditorEditable::updateCursorPosition()
const QTextCursor cursor = e->textCursor();
const QTextBlock block = cursor.block();
const int line = block.blockNumber() + 1;
const int column = cursor.position() - block.position() + 1;
m_cursorPositionLabel->setText(tr("Line: %1, Col: %2").arg(line).arg(column),
const int column = cursor.position() - block.position();
m_cursorPositionLabel->setText(tr("Line: %1, Col: %2").arg(line).arg(e->tabSettings().columnAt(block.text(), column)+1),
tr("Line: %1, Col: 999").arg(e->blockCount()));
m_contextHelpId.clear();
......
Supports Markdown
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