-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Lens flicker on file write #63
Comments
Can't reproduce it, maybe some script change your |
Okay, I reproduced it like this: vim.api.nvim_create_autocmd("BufWritePre", {
callback = function()
vim.wait(2000)
end,
})
Here |
Sorry, still can't rerpoduce it. |
I have the same problem. When I save a file, it shows the lens quickly on every line and then disappears. require("hlslens").setup() Nvim version:
|
I am able to reproduce the issue with the following config: vim.env.LAZY_STDPATH = '.repro'
load(vim.fn.system('curl -s https://raw.githubusercontent.com/folke/lazy.nvim/main/bootstrap.lua'))()
vim.api.nvim_create_autocmd("BufWritePre", {
callback = function()
vim.wait(10)
vim.cmd("m +1")
vim.cmd("m -2")
end,
})
require('lazy.minit').repro {
spec = {
{
'kevinhwang91/nvim-hlslens',
config = function()
require('hlslens').setup()
end,
lazy = false,
},
},
} NVIM v0.10.1 In order to see the flickering follow these steps:
int main() {
int foo = 1;
int bar = 2;
int foobar = foo + bar;
return foobar;
}
I worked around the issue with this answer on stackoverflow. |
Fixed. |
nvim --version
:Describe the bug
A clear and concise description of what the bug is.
To Reproduce using
nvim -u mini.lua
Example:
cat mini.lua
Steps to reproduce the behavior:
*
or/
:nohl
:w
Expected behavior
Saving a file shouldn't cause flicker.
Screenshots
If applicable, add screenshots to help explain your problem.
Additional context
Add any other context about the problem here.
nvim-hlslens/lua/hlslens/cmdline/init.lua
Lines 330 to 334 in 5e3e908
The flicker is triggered from this code.
The text was updated successfully, but these errors were encountered: