neovide
neovide copied to clipboard
Column zero often clipped (macOS)
Describe the bug
Often column zero is clipped, for example the #
in a #include
is missing (see screenshots), occasionally other single characters in line are also missing. Moving the cursor to the line, or off and on the line will get it to repaint correctly. This seems to be particularly noticeable with cmp-nvim-lsp-signature-help
(part of nvim-lspconfig
) using the LazyVIM package manager.
To Reproduce Steps to reproduce the behavior:
- Open up a .c file in neovide
- Use
gg
to go to the top - Page down with
Ctrl-f
until you see clipped output
Expected behavior No column zero/unpainted characters.
Screenshots
Clipping of some #include
statements at the top of a C program:
Clipping of cmp-nvim-lsp-signature-help
info after paging down into a C function:
Desktop (please complete the following information):
- OS: macOS 14.2.1 (arm64)
- Neovide Version: 0.12.0
- Neovim Version: v0.9.4
Please run neovide --log
and paste the contents of the .log
file created in the current directory here:
There's 18MB of log files just from a :cd <dir>
, s
to restore the session, gg
to go to the top and a Ctrl-f
to page down. I can grep the log if there are relevant lines or if there's a more selective logging option.
Additional context
Note that this issue started maybe 2 months ago and is still present in 0.12.0, not does NOT occur when running nvim
directly in a terminal such as kitty.
I think the issue is the same as, but leaving both open for now
- https://github.com/neovide/neovide/issues/2211
This look very similar to this
- https://github.com/neovim/neovim/issues/25011
But we fixed that, and I have not seen it myself since.
The log is the best way to diagnose this, maybe you can compress it, open a small file and reproduce as quickly as possible. Notice that the everything shown is in the log file, so don’t open any secrets.
Yes, it does look like neovim/neovim#25011, let me see if I can get a concise, anon log file to paste!
This one might look like #2211 but it seems a bit different though. This one is related to the clipping of the column zero.
In the case of #2211, there is a weird padding that is clipping the last column with a character.
@smithwinston, do you still have the problem? A log file would be really helpful since no-one else have reported the issue, and I'm unable to repeat it myself.
Yeah, I do with 0.12.2 on macOS. However, I was playing around with it on Windows and I don't see the same problems. I'm sort of new to nvim and lazy, there's a plugin (I'm just using the stock lazy config) that if you're in the middle of a large C function shows you the header at the top so you know where you are ... on macOS, column 0 is always clipped, but not on Windows. Not sure if that helps. Will try to get a log.
I tried to reduce this to a simple problem, so what I did was pre-position nvim in my ~/.config/nvim
tree partway down Lazyvim's example.lua
such that the signature help shows a clipped r
in return {
at the top on line 113:
This results in two log files, neovide_r2024-02-25_10-51-00.log
(10MB) and neovide_rCURRENT.log
(65k), I've zipped and attached both, hopefully you can determine something from it!
This is just one example, it's not just in the signature help that does this (although it's the most noticable), I do often see when I'm editing that within the middle of a code block, sometimes function arguments are just missing (almost as if they were syntax-highlighted as the same as the background, or just the painting for them was just skipped). I'll try to get a screen grab and logs for one of those.
Apologies for taking so long, I had switched to running nvim inside kitty to avoid this, but I do def. prefer Neovide!
There are still parts of the logs missing, but fortunately it included the critical part
GridLine { grid: 1, row: 2, column_start: 0, cells: [
GridLineCell { text: " ", highlight_id: Some(236), repeat: Some(2) },
GridLineCell { text: "1", highlight_id: Some(236), repeat: Some(2) },
GridLineCell { text: "3", highlight_id: None, repeat: None },
GridLineCell { text: " ", highlight_id: Some(236), repeat: Some(3) },
GridLineCell { text: " ", highlight_id: Some(0), repeat: Some(0) }] })
Although it does not include the parts where return
is written.
This fragment writes 113 followed by 3 spaces, which is correct, but then there's a terminator, another space repeated zero times, which should be ignored, as of Neovide 0.12.2 with:
- https://github.com/neovim/neovim/issues/25011
But in this case, it doesn't seem to be ignored, and a space is written, overwriting what was previously there, therefore the bug.
Given that you are the only one experiencing this, I think it's somehow not running 0.12.2. Unfortunately, the start of the log that prints the version is missing, so I can't verify. But you could double check with neovide --version
, or to generate another shorter log, just launch Neovide and exit. Alternatively, I think you can send all the log files, delete them all first, and then send all that were generated.
BTW, the reason why the logs become so big for you is mostly because you are using --no-multigrid
. And also because there's a lot of changing output due to the LSP load information. I don't think it should matter for this bug, but it might be worth trying to run with --multigrid
instead.
D'oh, yeah, that's it! At some point I'd switched to building from source rather than installing via Homebrew. Step 9 in Building from Mac Sources says:
cp -r ./target/release/bundle/osx/Neovide.app /Applications/Neovide.app
Which I blindly cut & paste and of course doesn't actually do the right thing (it copies the newly built Neovide.app
into /Applications/Neovide.app/Neovide.app
), so I had in fact been running the older version I installed via Homebrew way back (0.10.4 in my case!).
Thank you, I think we can consider this solved (I don't see those artifacts anymore with 0.12.2).
BTW: Not sure about the --no-multigrid
, I was just running /Application/Neovide.app/Contents/MacOS/neovide --log
. Note that with the currently built Neovide (0.12.2-11-g86c2170
as per git describe
), I get an error if I try --multigrid
:
% /Applications/Neovide.app/Contents/MacOS/neovide --multigrid
error: unexpected argument '--multigrid' found
tip: a similar argument exists: '--no-multigrid'
Usage: neovide --no-multigrid [FILES_TO_OPEN]... [-- [NEOVIM_ARGS]...]
For more information, try '--help'.
Awesome, now I can stop using nvim inside a terminal and go back to Neovide and I get to see all of the awesome new features since 0.10.4!