Open rodhash opened 2 years ago
I was playing around with floating_window_above_cur_line
which helps but doesn't solve it, the same thing happens depending on which line I'm in and the size of the signature that pops up.
Disabling the max width / height seems to help, I'm not sure but it seems the float (or popup) is adjusting itself to the terminal size. Is this a thing?
Also something else I was wondering, besides the toggle keybinding is there any option to bind a "disable" key?
I can confirm the issue on my end too (using default configuration - no customization, just dropped the require('lsp_signature').on_attach()
line in my lsp shared on_attach
)
https://user-images.githubusercontent.com/551858/169643551-fd49f41b-4675-4d9b-bb12-6fde2a63e1fe.mp4
This is a known issue, you can use toggle_key
to hide floating win.
I think the toggle_key isn't enough, or perhaps it's not working as expected in my setup.
If you noticed ~0:06 in the vid I posted, when it was covering the code I used the toggle_key to disable it but shortly it came back covering it again.
Was it supposed to say hidden / disabled? If yes I might be missing something in my setup.
put floating_window_off_y = 0 in config
Hey ..
It seems to me changing to zero didn't help.
Honestly I'm not even using floating_window anymore, I had work to do so I did the obvious, disabled it. I'm now using only "hint", it's enough for me and doesn't cover curr line.
I just enabled it again and gave it a try, changed to zero, however the window still covers my current line.
how about floating_window_off_y = -1
? Also how about disabling the floatwin border?
TBH, I am a bit surprise to me that it still covers the current line. Might be something different between your setup and mine.
@ray-x
Once the float window is too big to fit under/ over the current line of insert it overlaps it. (change font size to check)
messing with the option you mentioned mess up everything (even if the window fit it overlaps the line, because its randomly render above or under the line), floating_window_above_cur_line = true
- even this options cant force float window to render above line
floating_window_off_y = -1
floating_window_off_y = 1
would be great if the float window would get dynamic sizing, just a % of window width and height
my config:
require "lsp_signature".setup({
floating_window = true,
floating_window_off_y = 0,
bind = true,
floating_window_above_cur_line = true,
doc_lines = 10,
hint_enable = false,
handler_opts = {
border = "rounded"
},
-- zindex = 1,
-- hint_prefix = " >",
-- max_width = 120,
})
Hi, Could you try latest version
The issue is fixed in https://github.com/ray-x/lsp_signature.nvim/commit/4156acf14b2b4f7d4db3f232228e80932ec5dd5d
The wrap
option need to set to true (default false now)
Wow amazing, it seems to be working fine!
I just enabled at my personal pc, tomorrow will enable at work too and will test all day.
@ray-x works great now, i think the window shouldn't be rendered when it overlaps current line, so it would solve the overlap issue, also the offset for y should be secured, like there should be option to chose to render the window only above(it doesnt work) or only below, so the y offset may stay always positive
From my testing it's working just fine now
I just noticed that occasionally the border line goes missing, the float window still show up as expected only without the border line. It happened couple times now.
By chance related to the latest change?
There is another reporting regarding the border missing
Thank you, will follow up there.
BTW it's kinda rare the situations that I need to resize the terminal to a small size but I found the floating window overlapping again. However in most cases it's working fine, it seems to work fine for the normal use.
The floating wont resizes together with the terminal. The nearest solution might be close and reopen the floating window. If you feel the feature is essential to you, you can submit a separate issue.
Hi..
Found it overlaping again in a normal use.
Check this test file in a normal terminal size, with a big signature the floating window overlapped again the current line
You can set wrap=true
in setup and check if it fixes the issue.
Actually I tried that, I just reset all config to default except for the wrap
which I changed to true
well, pushed another change for this. Could you check if it works?
when i do enter insert mode to make the popup signature show then the bug still show up, it overlaps the current line (border render fine, also text wraps fine), but when i just move out and in, at insert mode (by arrows) it doesn't overlap current line anymore ( border stop rendering), the 2nd kind of window sometimes happen randomly, it was the only one i could reproduce Screencast from 07-18-2022 09:28:48 AM.webm
Yep, it seems to be working fine
Hi,
Latest fix was working just fine, no issue so far, but I just found one more situation where it still overlaps.
In case the floating window is already up, and I press enter to go to next line, cursor goes behind and the floating window stay still.
I'm on latest version: 4665921
Hello,
In general it works just fine and I love this lsp signature however recently I found myself dealing with two situations that I'm unsure whether they mean any bug or misconfiguration.
https://user-images.githubusercontent.com/29671981/168479628-bc939a37-7970-47c0-ae72-f08c6b87f540.mp4
My config.
I suspect the float win issue happens because of the border but I'm wondering if theres any workaround for that. And the flickering doesn't happen all the time, it only happens when I go back to some part of the code and try to change it, that's when it starts updating the internal value in the popup.
I'm running
0.8-dev
and latest lsp_signature2496aac
Thanks