Skip to content

Conversation

@bagratte
Copy link

The parameter overrides the application name
(WM_CLASS).

Fixes #284420

The parameter overrides the application name
(WM_CLASS).
Copilot AI review requested due to automatic review settings December 30, 2025 18:50
@vs-code-engineering
Copy link

vs-code-engineering bot commented Dec 30, 2025

📬 CODENOTIFY

The following users are being notified based on files changed in this PR:

@bpasero

Matched files:

  • src/vs/code/electron-main/main.ts
  • src/vs/platform/environment/common/argv.ts
  • src/vs/platform/environment/node/argv.ts

@deepak1556

Matched files:

  • src/vs/code/electron-main/main.ts

@bagratte
Copy link
Author

@microsoft-github-policy-service agree

Copy link
Contributor

Copilot AI left a comment

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 adds a new --class command line parameter that allows users to override the application name (WM_CLASS) on Linux, enabling window managers to apply specific rules to VS Code windows. This addresses issue #284420.

Key Changes

  • Added a new --class command line option to the argument parser
  • The option accepts a string value that sets the application class name
  • Implementation uses Electron's app.setName() and app.setDesktopName() APIs

Reviewed changes

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

File Description
src/vs/platform/environment/node/argv.ts Adds the --class command line option definition with localized description
src/vs/platform/environment/common/argv.ts Adds the class property to the NativeParsedArgs interface
src/vs/code/electron-main/main.ts Implements the feature by calling Electron's app name APIs when the --class argument is provided

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Allow customizing WM_CLASS when launching vscode

2 participants