zed
zed copied to clipboard
Vim: Syntax highlighting glitch and slow behavior with [[
Summary
When using the "Go to next" shortcut ([[) in Vim mode (https://zed.dev/docs/vim#treesitter), some parts of the syntax highlighting become plain text as it reaches the start or end of the file (look app.js). Additionally, in certain cases (look index.d.ts), the text glitches.
At the end of the demo, I showed that using Shift + { (to move between blocks) does not trigger this glitch. Also, the [[ shortcut is noticeably slower compared to Shift + {.
Both issues are demonstrated in the video below:
Video
https://github.com/user-attachments/assets/36118a1f-e3f2-4f00-b007-188b26876997
Steps to reproduce:
- Open a language file with LSP support.
- Enter Vim normal mode.
- Press
[[to navigate forward through the file until you reach the start or end.
Expected Behavior:
- Syntax highlighting should remain intact during navigation.
- The
[[shortcut should perform at the same speed asShift + {.
Actual Behavior:
- Syntax highlighting glitches or turns into plain text in some cases.
-
[[navigation is slower thanShift + {.
Zed Version and System Specs
Zed: v0.184.8 (Zed) OS: macOS 15.4.1 Memory: 16 GiB Architecture: x86_64