hiasr / vim-zellij-navigator

76 stars 4 forks source link

Flicker each time when moving between panes on WSL #6

Closed xpressivecode closed 5 months ago

xpressivecode commented 5 months ago

If I use the alt + hjkl to move between Zellij panes it works fine without any flickering. But when using the Ctrl + hjkl from the read me zellij flickers/flashes.

Zellij: 0.40.1 (built using cargo install --locked zellij) with stock theme / config (with the exception of the bindings from the readme) Plugin: 0.2.0 Terminal: windows wsl OS: Ubuntu 22.04.4 Shell: zsh

I'm not sure what else to provide in order to help isolate / fix the issue?

hiasr commented 5 months ago

Due to the way Zellij plugins work, it flickers the first time it is launched, this will be gone once headless plugins become available in a future release. It currently launches once for each direction l, this is a bug and is being tracked here. It does not do that when using alt because then it does not use the plugin but the standard Zellij key bindings. This means the vim navigation doesn't work either.

xpressivecode commented 5 months ago

Thanks for the explanation. Did I set something up wrong? If I just move up/down between panes say 10 times. It flickers every time. From your message it sounds like if I went up/down once each it would flicker the first time but after the plugin would have been initialized per direction and shouldn't flicker afterwards?

Peeeaje commented 5 months ago

For me it doesn't flicker but the first push of C-h, j, k, l.

hiasr commented 5 months ago

From your message it sounds like if I went up/down once each it would flicker the first time but after the plugin would have been initialized per direction and shouldn't flicker afterwards?

That is at least how it works on my side (and how it is supposed to work on Zellij's side AFAIK). You can retry on the latest release, but I think this is an issue on Zellij's side. Can you add your Zellij logs after pressing each direction a few times?

xpressivecode commented 5 months ago

Out of curiosity I installed Zellij and the plugin on my mac. Worked through that curl issue and sure enough it works exactly as you described. It's a great experience.

So it's something with the wsl2 setup. I tried capturing some log output but I didn't see anything when moving between panes, even with the --debug flag set.

I've tried installing alacritty on windows and the flashing persists. I'll keep troubleshooting. Glad it's working so well on osx though.

hiasr commented 5 months ago

The logs are not printed to stdout, but to the log file. The docs describe where you can find this. I do think it is indeed a wsl issue, though. If the logs don't say anything useful you can consider opening an issue with Zellij itself. The fact that the pane flashes each time, means that a new instance of the plugin is launched each time.

xpressivecode commented 5 months ago

Yeah I checked the log file and it didn't have anything included while moving between panes. Thanks for the prompt responses and the plugin. Cheers.

xpressivecode commented 5 months ago

if someone else experiences this, for whatever reason wezterm on windows does not experience the flickering.