zed
zed copied to clipboard
Spacebar Not Working in Zed Editor with English Keyboard Layout
Check for existing issues
- [X] Completed
Describe the bug / provide steps to reproduce it
When the keyboard layout is set to English, the spacebar does not function within the Zed editor. This issue is isolated to the Zed editor, as the spacebar works normally in all other applications. Steps to reproduce:
Set your keyboard layout to English. Open the Zed editor. Try to use the spacebar inside the editor. The spacebar will not produce a space character.
Environment
Zed: v0.149.3 (Zed) OS: Linux X11 fedora 40 Memory: 23.4 GiB Architecture: x86_64 GPU: NVIDIA GeForce RTX 2060 || NVIDIA || 550.107.02
If applicable, add mockups / screenshots to help explain present your vision of the feature
No response
If applicable, attach your Zed.log file to this issue.
Zed.log
Hi, I also had this issue.
I found that it happened once I installed zoom (and along with it ibus, the english spacebar stopped working (though when I switched language it worked in Hebrew).
Once I uninstalled Ibus and restarted the computer, the issue went away... Just means that there might be trouble using both zoom and zed together.
Hope this helps you folks debug the issue, keep up the good work!
well ibus is needed for GNOME, i dont even have zoom installed, never had, so im not uninstalling ibus, this is a bug from zed key binding, waiting for them to fix it
Also having the same issue. Changing from English (US) to Estonian keyboard the space works. Also English (UK) does not have this problem
I also have the same issue, but I seem to have found a workaround. The space works with any primary keyboard layout and does not with any other. It does not matter, which layout (English, etc.) is primary. If there is only one layout, the spacebar works.
In my case, I have the Czech QWERTY layout as primary and the spacebar works, if I switch to secondary English US, the spacebar does not work. If I make the US layout primary, now the spacebar works with it but does not with Czech.
Zed: v0.167.2 OS: Linux X11, Fedora 40, Cinnamon Architecture: x86_64 Memory: 15.5 GiB Graphics: Intel UHD Graphics 620
I also have the same issue, but I seem to have found a workaround. The space works with any primary keyboard layout and does not with any other. It does not matter, which layout (English, etc.) is primary. If there is only one layout, the spacebar works.
In my case, I have the Czech QWERTY layout as primary and the spacebar works, if I switch to secondary English US, the spacebar does not work. If I make the US layout primary, now the spacebar works with it but does not with Czech.
Zed: v0.167.2 OS: Linux X11, Fedora 40, Cinnamon Architecture: x86_64 Memory: 15.5 GiB Graphics: Intel UHD Graphics 620
Indeed, this seems to be the case also for me
Same here. But it seems like this issue is only exclusive to Xorg, on Wayland everything's fine for me.
I also have the same issue, but I seem to have found a workaround. The space works with any primary keyboard layout and does not with any other. It does not matter, which layout (English, etc.) is primary. If there is only one layout, the spacebar works.
In my case, I have the Czech QWERTY layout as primary and the spacebar works, if I switch to secondary English US, the spacebar does not work. If I make the US layout primary, now the spacebar works with it but does not with Czech.
Zed: v0.167.2 OS: Linux X11, Fedora 40, Cinnamon Architecture: x86_64 Memory: 15.5 GiB Graphics: Intel UHD Graphics 620
Having exact same issue
I also have the same issue, but I seem to have found a workaround. The space works with any primary keyboard layout and does not with any other. It does not matter, which layout (English, etc.) is primary. If there is only one layout, the spacebar works.
In my case, I have the Czech QWERTY layout as primary and the spacebar works, if I switch to secondary English US, the spacebar does not work. If I make the US layout primary, now the spacebar works with it but does not with Czech.
Zed: v0.167.2 OS: Linux X11, Fedora 40, Cinnamon Architecture: x86_64 Memory: 15.5 GiB Graphics: Intel UHD Graphics 620
Same, but with Russian layout. Mint 22 (Wilma) Cinnamon, X11.
I also have the same issue, but I seem to have found a workaround. The space works with any primary keyboard layout and does not with any other. It does not matter, which layout (English, etc.) is primary. If there is only one layout, the spacebar works. In my case, I have the Czech QWERTY layout as primary and the spacebar works, if I switch to secondary English US, the spacebar does not work. If I make the US layout primary, now the spacebar works with it but does not with Czech. Zed: v0.167.2 OS: Linux X11, Fedora 40, Cinnamon Architecture: x86_64 Memory: 15.5 GiB Graphics: Intel UHD Graphics 620
Same, but with Russian layout. Mint 22 (Wilma) Cinnamon, X11.
this bug as fixed for me on 0.183.10
Not for me. The spacebar still does not work with secondary keyboard layout even on v0.183.10.
I wanted to try Zed but ran into this same issue unfortunately.
I tried editing the ~/.config/zed/keymap.json file and adding the space using this line in the bindings section under context "Editor": "space": ["workspace::SendKeystrokes", " "]
But that made it worse; where initially the space under the Dutch (standard) layout worked, it no longer did after making the change. My keyboard layout is English (US).
Running Zed 0.185.13 on: Distributor ID: Linuxmint Description: Linux Mint 22 Release: 22 Codename: wilma
Linux Mint 22.1 Kernel: 6.8.0-62-generic DE: Cinnamon 6.4.8 Zed: 0.191.7 a3e535d72007d0c0e55c1e8a1b62a64e31927d2b
British keyboard layout on a Dell laptop. No space for me either. I enjoy a challenge but this issue makes development quite difficult. It did give me a good laugh, though.
Linux Mint 22.1 Kernel: 6.8.0-62-generic DE: Cinnamon 6.4.8 Zed: 0.191.9
British keyboard
plus one here, does not work with russian layout
Linux Mint 22.1 DE: Cinnamon 6.4.8
same story as https://github.com/zed-industries/zed/issues/20465#issuecomment-2676897646
Same issue
Linux Mint 22.1 Cinnamon 6.4.8 Zed 0.192.5
Looks like https://github.com/zed-industries/zed/pull/31174 might fix this.
Edit: I was able to reproduce this issue on latest stable Linux Mint Cinnamon with Dutch layout. Issue is likely how are handing mask on key press event on this line:
https://github.com/zed-industries/zed/blob/96ff6d86a3666b4efcd5ae16b008e286405e9b98/crates/gpui/src/platform/linux/x11/client.rs#L1033
Simply masking to bits 0-7 fixes the issue i.e. (event.state.bits() & 0xff) as ModMask but I think there should be better solution than that, which above mentioned PR might be taking look at. Ref: https://www.x.org/releases/X11R7.6/doc/libX11/specs/XKB/xkblib.html#keyboard_state_description
#31174 (closed unmerged) was superceded by https://github.com/zed-industries/zed/pull/34053 and https://github.com/zed-industries/zed/pull/34396 but I don't have the context to know whether it'll fixes this.
Can someone validate whether this is still an issue in main? (Or check v0.196.0 when it becomes available in Zed Preview on Wednesday 2025-07-16).