Repository navigation
Pass pixel dimension through terminal resize - #295820
Merged
Anthony Kim (anthonykim1) merged 3 commits intoFeb 17, 2026
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds support for passing pixel dimensions (width and height) through the terminal resize flow, enabling more accurate terminal rendering. The changes adapt VSCode's terminal implementation to support the pixel dimension parameters that were recently added to node-pty.
Changes:
- Extended the
resizemethod signature across all terminal-related interfaces and implementations to accept optionalpixelWidthandpixelHeightparameters - Modified
_updatePtyDimensionsin TerminalInstance to extract and pass pixel dimensions from the xterm.js terminal's canvas dimensions - Updated the TerminalProcess implementation to construct and pass a pixel size object to node-pty when both dimensions are provided
Reviewed changes
Copilot reviewed 10 out of 10 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| src/vs/workbench/contrib/terminal/electron-browser/localPty.ts | Updated LocalPty's resize method to accept and forward pixel dimensions |
| src/vs/workbench/contrib/terminal/common/terminal.ts | Extended ITerminalProcessManager interface with pixel dimension parameters across all setDimensions overloads |
| src/vs/workbench/contrib/terminal/common/remote/remoteTerminalChannel.ts | Modified RemoteTerminalChannelClient to pass pixel dimensions through remote channel |
| src/vs/workbench/contrib/terminal/browser/terminalProcessManager.ts | Updated TerminalProcessManager's setDimensions and _resize methods to handle pixel dimensions |
| src/vs/workbench/contrib/terminal/browser/terminalInstance.ts | Modified _updatePtyDimensions to extract pixel dimensions from xterm.js canvas and pass them to process manager |
| src/vs/workbench/contrib/terminal/browser/remotePty.ts | Updated RemotePty's resize method to accept and forward pixel dimensions |
| src/vs/platform/terminal/node/terminalProcess.ts | Enhanced TerminalProcess to construct pixel size object for node-pty when dimensions are provided |
| src/vs/platform/terminal/node/ptyService.ts | Updated PtyService and PersistentTerminalProcess to propagate pixel dimensions through the service layer |
| src/vs/platform/terminal/node/ptyHostService.ts | Modified PtyHostService to forward pixel dimensions to the underlying proxy |
| src/vs/platform/terminal/common/terminal.ts | Extended IPtyService, IPtyServiceContribution, and ITerminalChildProcess interfaces with pixel dimension parameters |
Co-authored-by: Copilot <[email protected]>
Anthony Kim (anthonykim1)
enabled auto-merge (squash)
February 17, 2026 21:18
Daniel Imms (Tyriar)
approved these changes
Feb 17, 2026
Anthony Kim (anthonykim1)
deleted the
anthonykim1/passPixelThroughTerminalResize
branch
February 17, 2026 21:29
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Resolves: #295819
Similar to xtermjs/xterm.js#5693 adapting to microsoft/node-pty#881