Commit 7f6ec706 authored by Thomas BOUTROUE's avatar Thomas BOUTROUE

Adjust ID token position in Code Editor navigation panel

parent 14c4be23
......@@ -201,14 +201,14 @@ void SyntaxHighlighter::refreshAst (void) {
(nextIdPos < nextOpenPos || nextOpenPos < 0) &&
(nextIdPos < nextClosePos || nextClosePos < 0)) { // ID
index = (nextIdPos + regexpId.matchedLength ());
m_ast.append (new SyntaxToken { SyntaxToken::Id, regexpId.capturedTexts ().at (1), nextIdPos });
m_ast.append (new SyntaxToken { SyntaxToken::Id, regexpId.cap (1), regexpId.pos (1) });
}
else if ((nextObjectPos >= 0) &&
(nextObjectPos < nextIdPos || nextIdPos < 0) &&
(nextObjectPos < nextOpenPos || nextOpenPos < 0) &&
(nextObjectPos < nextClosePos || nextClosePos < 0)) { // Object
index = (nextObjectPos + regexpObject.matchedLength ());
m_ast.append (new SyntaxToken { SyntaxToken::Type, regexpObject.capturedTexts ().at (1), nextObjectPos });
m_ast.append (new SyntaxToken { SyntaxToken::Type, regexpObject.cap (1), regexpObject.pos (1) });
}
else if ((nextOpenPos >= 0) &&
(nextOpenPos < nextObjectPos || nextObjectPos < 0) &&
......
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