microsoft / vscode

Visual Studio Code
https://code.visualstudio.com
MIT License
162.36k stars 28.61k forks source link

Blurry UI on Wayland + GNOME 200% scaling #221153

Open Aalivexy opened 2 months ago

Aalivexy commented 2 months ago

Does this issue occur when all extensions are disabled?: Yes

Steps to Reproduce:

  1. Run a Linux distribution + Wayland + GNOME
  2. Set display scaling to 200% (without experimental fractional scaling feature)
  3. Launch VS Code (with ELECTRON_OZONE_PLATFORM_HINT=auto)
  4. Observe the UI is blurry

In addition, I found that electron31 does not have this problem, but electron29 does, and vscode uses electron29, so this may be an upstream problem that has been fixed.

VSCodeTriageBot commented 2 months ago

Thanks for creating this issue! It looks like you may be using an old version of VS Code, the latest stable release is 1.91.0. Please try upgrading to the latest version and checking whether this issue remains.

Happy Coding!

Aalivexy commented 2 months ago

Thanks for creating this issue! It looks like you may be using an old version of VS Code, the latest stable release is 1.91.0. Please try upgrading to the latest version and checking whether this issue remains.

Happy Coding!

Sorry, I made a typo, it should actually be 1.91.0

Aalivexy commented 2 months ago

Any updates? The issue is still present in Electron 30, which means it seems that this issue will not be fixed in 1.92. Does this mean that we will have to wait until 1.94 in October to fix the issue?

Le0X8 commented 1 month ago

Try the following:

sudo mv /usr/bin/code /usr/bin/vscode-bin
sudo nano /usr/bin/code
sudo chmod +x /usr/bin/code

and paste the following:

#!/usr/bin/bash
/usr/bin/vscode-bin --enable-features=UseOzonePlatform --ozone-platform=wayland $*

Press ctrl+s ctrl+x to save, done.

Aalivexy commented 1 month ago

Try the following:

sudo mv /usr/bin/code /usr/bin/vscode-bin
sudo nano /usr/bin/code
sudo chmod +x /usr/bin/code

and paste the following:

#!/usr/bin/bash
/usr/bin/vscode-bin --enable-features=UseOzonePlatform --ozone-platform=wayland $*

Press ctrl+s ctrl+x to save, done.

ozone platform wayland is already enabled by ELECTRON_OZONE_PLATFORM_HINT=auto environment variable

t0rr3sp3dr0 commented 1 week ago

Try using --disable-features=WaylandFractionalScaleV1

t0rr3sp3dr0 commented 1 week ago

@deepak1556 @rzhao271, any chance we can get something like https://aur.archlinux.org/cgit/aur.git/tree/visual-studio-code-bin.sh?h=visual-studio-code-bin upstreamed? This would help us set these Wayland-related flags permanently.

I've been editing /usr/share/code/bin/code, /usr/share/applications/code.desktop, and /usr/share/applications/code-url-handler.desktop to make sure VS Code always starts with the required flags, but my changes are overwritten every time I update VS Code.