PowerToys icon indicating copy to clipboard operation
PowerToys copied to clipboard

Key mappings don't work when Visual Studio has focus

Open tsobczynski opened this issue 2 years ago • 3 comments

Microsoft PowerToys version

0.66.0

Installation method

GitHub, PowerToys auto-update

Running as admin

No

Area(s) with issue?

Keyboard Manager

Steps to reproduce

Set up Keyboard Manager to swap Caps Lock with Control, and Left Win with Left Alt.

Exercise the remapped keys, see that they are swapped as requested.

Run Visual Studio.

Exercise the remapped keys again.

image

✔️ Expected Behavior

I expected the remapped keys to still be remapped when Visual Studio has focus.

❌ Actual Behavior

Instead, the keys behave according to their original function with no remapping applied. As soon as focus leaves Visual Studio, remapping resumes. For example, press remapped Win in Visual Studio, and the menu bar pops up. Press remapped Alt in Visual Studio, and the Windows menu appears. Now that focus has left Visual Studio, press remapped Win and the Windows menu disappears.

Other Software

Microsoft Visual Studio Community 2022 (64-bit) Version 17.4.4

running on Windows 10 21H2

tsobczynski avatar Jan 24 '23 18:01 tsobczynski

It seems intermittent. I'm using VsVim 2022 and it works for the most part but sometimes not. Ctrl-[ will sometimes put caps lock on. Remapped Insert will turn capslock off until next time it fails.

Powertools 0.69.1.

tommy-hansen avatar Apr 28 '23 14:04 tommy-hansen

I have the same problem. Kyeboard Manager works fine everywhere except the Visual Studio 2022.

Other Information Windows 10 Enterprise 22H2 Microsoft Visual Studio Enterprise 2022 (64-bit) Version 17.6.5 PowerToys v0.74.1

Yushann avatar Nov 01 '23 06:11 Yushann

If you run VS as Admin, you need to run PowerToys as admin as well https://powertoys.io/keyboard-manager-utility-for-windows/ https://stackoverflow.com/questions/67593307/microsoft-powertoys-key-mapping-not-working-in-visual-studio

xpengineer avatar May 13 '24 22:05 xpengineer