Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/microsoft/vscode.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAlexandru Dima <alexdima@microsoft.com>2022-07-20 13:04:01 +0300
committerGitHub <noreply@github.com>2022-07-20 13:04:01 +0300
commitc79556aed38346a6d5f515d5006345c49777b313 (patch)
tree2e32cf3b4007d5470844df94eca82104d30e78ec /src
parentabf921bd9cce74a881608b93b76b5617251af82a (diff)
Also use the first line which has a begin state when tokenizing the viewport (#155698)
Diffstat (limited to 'src')
-rw-r--r--src/vs/editor/common/model/textModelTokens.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/vs/editor/common/model/textModelTokens.ts b/src/vs/editor/common/model/textModelTokens.ts
index b504fc14366..120da61f3f5 100644
--- a/src/vs/editor/common/model/textModelTokens.ts
+++ b/src/vs/editor/common/model/textModelTokens.ts
@@ -472,12 +472,12 @@ export class TextModelTokenization extends Disposable {
}
if (newNonWhitespaceIndex < nonWhitespaceColumn) {
+ fakeLines.push(this._textModel.getLineContent(i));
+ nonWhitespaceColumn = newNonWhitespaceIndex;
initialState = this._tokenizationStateStore.getBeginState(i - 1);
if (initialState) {
break;
}
- fakeLines.push(this._textModel.getLineContent(i));
- nonWhitespaceColumn = newNonWhitespaceIndex;
}
}