forked from qt-creator/qt-creator
TextEditor: Fix TextDocumentLayout::braceDepth()
Amends 343e206b48
.
Fixes: QTCREATORBUG-31601
Change-Id: I40e41214db460fc1a471a60a57c98125a20c2468
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: Artem Sokolovskii <artem.sokolovskii@qt.io>
This commit is contained in:
@@ -437,7 +437,7 @@ int TextDocumentLayout::braceDepth(const QTextBlock &block)
|
|||||||
int state = block.userState();
|
int state = block.userState();
|
||||||
if (state == -1)
|
if (state == -1)
|
||||||
return 0;
|
return 0;
|
||||||
return state >> 8;
|
return (state >> 8) & 0xff;
|
||||||
}
|
}
|
||||||
|
|
||||||
void TextDocumentLayout::setBraceDepth(QTextBlock &block, int depth)
|
void TextDocumentLayout::setBraceDepth(QTextBlock &block, int depth)
|
||||||
|
Reference in New Issue
Block a user