Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mouse cursor dissapears when i move it to the editor area. #204181

Closed
ashen92 opened this issue Feb 2, 2024 · 21 comments
Closed

Mouse cursor dissapears when i move it to the editor area. #204181

ashen92 opened this issue Feb 2, 2024 · 21 comments
Assignees
Labels
*duplicate Issue identified as a duplicate of another issue(s)

Comments

@ashen92
Copy link

ashen92 commented Feb 2, 2024

Type: Bug

Actual - Move mouse cursor to the editor area.
Expected - Cursor should be always visible.

VS Code version: Code 1.86.0 (0504748, 2024-01-31T10:28:19.990Z)
OS version: Windows_NT x64 10.0.22631
Modes:

System Info
Item Value
CPUs AMD Ryzen 5 5625U with Radeon Graphics (12 x 2296)
GPU Status 2d_canvas: enabled
canvas_oop_rasterization: enabled_on
direct_rendering_display_compositor: disabled_off_ok
gpu_compositing: enabled
multiple_raster_threads: enabled_on
opengl: enabled_on
rasterization: enabled
raw_draw: disabled_off_ok
skia_graphite: disabled_off
video_decode: enabled
video_encode: enabled
vulkan: disabled_off
webgl: enabled
webgl2: enabled
webgpu: enabled
Load (avg) undefined
Memory (System) 23.36GB (9.05GB free)
Process Argv
Screen Reader no
VM 0%
Extensions (30)
Extension Author (truncated) Version
vscode-markdownlint Dav 0.54.0
vscode-eslint dba 2.4.4
composer-php-vscode DEV 1.43.14858
intelli-php-vscode DEV 0.12.14619
phptools-vscode DEV 1.43.14858
profiler-php-vscode DEV 1.43.14858
copilot Git 1.156.0
copilot-chat Git 0.12.0
vscode-drawio hed 1.6.6
twig-language mbl 0.9.4
git-graph mhu 1.30.0
vscode-azurecache ms- 0.1.0
vscode-azureappservice ms- 0.25.1
vscode-azureresourcegroups ms- 0.8.3
vscode-docker ms- 1.28.0
autopep8 ms- 2023.8.0
debugpy ms- 2024.0.0
python ms- 2024.0.0
vscode-pylance ms- 2023.12.1
remote-containers ms- 0.338.1
azure-account ms- 0.11.6
vscode-speech ms- 0.4.0
sqltools mtx 0.28.1
sqltools-driver-mysql mtx 0.6.0
material-icon-theme PKi 4.33.0
vscode-xml red 0.26.1
vscode-yaml red 1.14.0
code-spell-checker str 3.0.1
php-debug xde 1.34.0
material-theme zhu 3.16.2
@KamilEterna
Copy link

I have the issue too, also not visible in terminal (bottom panel).
I found that it gets visible after ~2 seconds spent in the same editor. If I move it to another (split) editor then it is invisible for 2 seconds.

@RyanZhou416
Copy link

Under the Light Modern theme in VSCode, the cursor becomes white, making it indistinguishable from the background. However, it briefly changes back to black when right-clicking.

VID_20240208_145016.mp4

@ashen92
Copy link
Author

ashen92 commented Feb 9, 2024

This happens with other default light themes too. Only in light themes not dark themes.

@KamilEterna
Copy link

It seems to me that it happened after a windows update. This issue also appears for me on Google Docs where the page is white.

@bvazx
Copy link

bvazx commented Feb 9, 2024

I have the same problem with the cursor in version 1.86.2. I had to roll back to version 1.85.2, this problem does not exist there.
As far as I know, VSCode is built on the basis of Chromium. Just like Edge. Such a bug exists in this browser. It used to be more noticeable, now less… Apparently, this needs to be fixed somewhere deeper, in the same Chromium.

@AnWeber
Copy link
Contributor

AnWeber commented Feb 15, 2024

I also observed the problem in the current Chrome Version (121.0.6167.161). After a short wait, the cursor turns black for me (in VSCode and Chrome).
A rollback to the previous VSCode version also prevents the problem for me.

chrome_issue

@MikuAuahDark
Copy link

MikuAuahDark commented Feb 16, 2024

Same thing happend to me in 1.86.2. A workaround is to use dark theme but I don't want to use dark theme when coding.

@jeanfgagnon
Copy link

Had the same issue. Using a dark theme and a larger, orange, mouse cursor. Reverting to 1.85.2 fixed the issue.

@AnWeber
Copy link
Contributor

AnWeber commented Feb 26, 2024

Disabling GPU acceleration works for me AS workaround

1. Open command pallete (Ctrl + Shift + P)
2. Enter "Preferences: Configure Runtime Arguments"
3. Add config: "disable-hardware-acceleration": true
4. Restart VS Code

@MikuAuahDark
Copy link

MikuAuahDark commented Feb 29, 2024

Still reproducible in 1.87 stable and Insiders 1.88 (8c2b09c). Based on Chromium bug report on #205491 (comment), launching VSCode with code --disable_direct_composition=1 will solve the issue without having to disable hardware acceleration entirely.

Note that it must be launched directly with that command-line arguments. Adding it to argv.json doesn't work as VSCode restricts them.

@wendelloliveiradev
Copy link

wendelloliveiradev commented Feb 29, 2024

As I commented on #204103. I'm having the same issue. It seems to come from the OS (idk how it behaves in other OSs, rather than Windows), and it intensifies terribly with VSCode.

Workaround:

The best (and easiest) way around this on Windows, without changing the settings of the VSCode is through the mouse setting on the Operating System. Go to 'Start -> Settings -> Accessibility -> Mouse pointer and touch', under 'Mouse pointer style', change the style to 'Black', it will fix it. Or under 'Size', change the size of the pointer, it will also fix it.

vscode-cursor-fix-for-light-themes

@david-morris
Copy link

david-morris commented Mar 7, 2024

I am also affected, in vscode 1.87. I was not affected in version 1.84, so this should maybe be labeled as a regression.

I notice that snapping the window into another screen can make this temporarily stop.
Here's a weird part: when I record the screen with the built-in windows tool that seems to be intended for gaming, it strips this bug and the cursor finder from PowerToys! So the phone videos are attached because screencasts look normal.

Edit: @MikuAuahDark 's analysis looks like it probably applies to my case as well. I also have radeon graphics.
Personally I would recommend using alternate cursors instead of downgrading chromium version (security issues?) and acceleration settings.

@arisudesu
Copy link

This happens on my setup too. This is very annoying and disorienting.

@MikuAuahDark
Copy link

MikuAuahDark commented Apr 6, 2024

After more investigation, it looks like this is AMD's fault and it's been a thing for 1-2 years. For now, the best "solution" would be:

  • Allow --disable_direct_composition=1 in argv.json.
  • Downgrade Chromium to version that was used in 1.85 where it doesn't occur.

@arisudesu
Copy link

@MikuAuahDark you guessed right, I have Radeon RX 6750, Adrenalin Software ver. 24.3.1. "disable-hardware-acceleration": 1 in argv.json fixes the problem for the time being.

@MikuAuahDark
Copy link

MikuAuahDark commented Apr 14, 2024

"disable-hardware-acceleration": 1 completely disables hardware acceleration, resulting in higher CPU usage, while --disable-direct-composition=1 keeps them enabled with slightly increased power usage (important for laptops).

Also changing the pointer is not an option for me because larger cursor size looks ugly and it takes time to get used to.

Perhaps someone can send PR to allow disable_direct_composition in argv.json? Probably the best method for now without downgrading Chromium.

@bvazx
Copy link

bvazx commented Apr 20, 2024

More information here.
I solved the same problem with Edge using D3D9. I wonder if it can be enabled for VSCode?

@bvazx
Copy link

bvazx commented Apr 20, 2024

After more investigation, it looks like this is AMD's fault and it's been a thing for 1-2 years.

No, this is a Windows bug that has already been fixed in the dev and canary builds. Microsoft is about to roll out updates for stable.

@arisudesu
Copy link

I hope that this fix gets to Windows 10 before it reaches EOL, not only Win 11.

@bbyby
Copy link

bbyby commented May 27, 2024

Same problem appeared and it's very annoying. Tried to apply such thing, I changed cursor theme - made it dark. Maybe it will help someone.

@alexdima
Copy link
Member

Let's track in #204103

@alexdima alexdima closed this as not planned Won't fix, can't repro, duplicate, stale Jun 12, 2024
@alexdima alexdima added the *duplicate Issue identified as a duplicate of another issue(s) label Jun 12, 2024
@vs-code-engineering vs-code-engineering bot locked and limited conversation to collaborators Jul 27, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
*duplicate Issue identified as a duplicate of another issue(s)
Projects
None yet
Development

No branches or pull requests