Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Fix issue with incorrect colorization immediately after saving a new file#4153

Merged
Colengms merged 2 commits into
mastermicrosoft/vscode-cpptools:masterfrom
coleng/colorization_fixmicrosoft/vscode-cpptools:coleng/colorization_fixCopy head branch name to clipboard
Aug 28, 2019
Merged

Fix issue with incorrect colorization immediately after saving a new file#4153
Colengms merged 2 commits into
mastermicrosoft/vscode-cpptools:masterfrom
coleng/colorization_fixmicrosoft/vscode-cpptools:coleng/colorization_fixCopy head branch name to clipboard

Conversation

@Colengms

Copy link
Copy Markdown
Contributor

Addresses one of the issues mentioned in #4109 , where a newly created then saved file gets no or incorrect colorization. The cause is similar to other fixed issues involving didOpen delivering an updated document due to use of async code. Colorization code on the TS side needs similar handling, to keep track of changed document ranges, as it needs to fix up colorized ranges if the document is changed between colorization passes.

Defers TS handling of DidOpen until immediately before forwarded to native side.
Added cleanup of colorizationState on didClose, and initialization of colorizationState on didOpen instead of lazily.
Prevented reporting of changes to visible ranges of unsaved new file.

@Colengms Colengms merged commit 41933fa into master Aug 28, 2019
@Colengms Colengms deleted the coleng/colorization_fix branch August 28, 2019 17:15
@github-actions github-actions Bot locked and limited conversation to collaborators Oct 10, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.