Skip to content

Keymaps do not handled correctly on Windows when using AltGr #27204

@jusqua

Description

@jusqua

Summary

Keymaps don't works when using AltGr.
In my keyboard layout I need to press AltGr + q to produce / and AltGr + w to produce ?, but, on Windows, AltGr also produces Ctrl + Alt and conflicts with the existing keymaps.

An example is the / to search in vim mode the keymap produces Ctrl + Alt + / and I cannot use the search.
Also for Assistant Panel (The default is Ctrl + ?), I need to press Ctrl + AltGr + q, but returns Ctrl + Alt + /.

Some apps make workarounds to handle the AltGr key on windows to "correctly" key handling, generally the AltGr is the Right Alt key.
Some discussion: crossterm-rs/crossterm#820

Steps to trigger the problem:

  1. On Windows, using a keyboard with AltGr capability, e.g. Portuguese (Brazil ABNT2)
  2. Press AltGr + key
  3. Recieve "wrong" keys

Actual Behavior:

2025-03-20.13-26-25.mp4

Expected Behavior:

Produce the keymap correctly and use zed default keymaps without mapping to anything else.

Zed Version and System Specs

Zed: v0.178.5 (Zed)
OS: Windows 10.0.26100
Memory: 15.7 GiB
Architecture: x86_64
GPU: Intel(R) Iris(R) Xe Graphics || Intel Corporation || Intel driver

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:controls/keybindsKeyboard shortcuts, mapping, binding, keymaps, etcplatform:windowshappens only on Windows, not other OS

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions