Skip to content

Editor GPU: Fix wrapped line indent - #286934

Merged
Daniel Imms (Tyriar) merged 1 commit into
mainfrom
tyriar/238404
Jan 10, 2026
Merged

Daniel Imms (Tyriar) merged 1 commit into
mainfrom
tyriar/238404

Conversation

@Tyriar

Copy link
Copy Markdown
Contributor

Fixes #238404

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes an issue where wrapped lines were not properly indented in the GPU-accelerated editor rendering. The fix ensures that when rendering wrapped lines, the horizontal offset accounts for the visual indent (faux indent) that should precede the content on continuation lines.

Changes:

  • Initialize absoluteOffsetX to account for the faux indent by calculating (lineData.minColumn - 1) * charWidth instead of starting at 0

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
src/vs/editor/browser/gpu/renderStrategy/viewportRenderStrategy.ts Fixed wrapped line indent calculation in viewport render strategy
src/vs/editor/browser/gpu/renderStrategy/fullFileRenderStrategy.ts Fixed wrapped line indent calculation in full file render strategy

@Tyriar
Daniel Imms (Tyriar) merged commit b22b0a9 into main Jan 10, 2026
27 of 28 checks passed
@Tyriar
Daniel Imms (Tyriar) deleted the tyriar/238404 branch January 10, 2026 18:11
@github-project-automation github-project-automation Bot moved this from In Review to Done in VS Code Editor GPU Renderer Jan 10, 2026
Elijah King (eli-w-king) pushed a commit that referenced this pull request Jan 14, 2026
Editor GPU: Fix wrapped line indent
@vs-code-engineering vs-code-engineering Bot locked and limited conversation to collaborators Feb 24, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

Editor GPU: Offset is incorrect for wrapped lines

3 participants