Closed fdelacruz closed 3 months ago
I would open an issue with Neovim, but this only happens when noice.nvim is enabled.
I am seeing the same flicker ff
too on a MacOs Monterey 12.7, I can reproduce with the above minimal repro.lua
. It seems this only happens when running nightly: at the moment I am on NVIM v0.10.0-dev-2432+gacb13c7ac
but the behaviour exists on many previous commits too (I haven't been able to find the specific commit yet).
This might be a guicursor
issue, does it happen when you set guicursor to an invisible highlight without noice?
e.g:
vim.api.nvim_set_hl(0,"HIDDEN",{blend = 100,nocombine = true})
vim.opt.guicursor = "a:HIDDEN"
I don't have MacOs to test this.
does it happen when you set guicursor to an invisible highlight without noice?
Do you mean without enabling noice?
Do you mean without enabling noice?
Yes.
You are right, without enabling noice but setting the options as above the flicker ff
still appears: you can reproduce with the following
-- DO NOT change the paths and don't remove the colorscheme
local root = vim.fn.fnamemodify("./.repro", ":p")
-- set stdpaths to use .repro
for _, name in ipairs({ "config", "data", "state", "cache" }) do
vim.env[("XDG_%s_HOME"):format(name:upper())] = root .. "/" .. name
end
-- bootstrap lazy
local lazypath = root .. "/plugins/lazy.nvim"
if not vim.loop.fs_stat(lazypath) then
vim.fn.system({ "git", "clone", "--filter=blob:none", "https://github.com/folke/lazy.nvim.git", lazypath })
end
vim.opt.runtimepath:prepend(lazypath)
-- install plugins
local plugins = {
"folke/tokyonight.nvim",
}
require("lazy").setup(plugins, {
root = root .. "/plugins",
})
vim.cmd.colorscheme("tokyonight")
vim.api.nvim_set_hl(0, "HIDDEN", { blend = 100, nocombine = true })
vim.opt.guicursor = "a:HIDDEN"
-- add anything else here
see recording below for demonstration
https://github.com/folke/noice.nvim/assets/15387611/5d5ebc24-65cf-482a-94ec-14655efb328b
Is lazy or tokyonight needed here or can you reproduce it with just these 2 lines?
vim.api.nvim_set_hl(0, "HIDDEN", { blend = 100, nocombine = true })
vim.opt.guicursor = "a:HIDDEN"
Is lazy or tokyonight needed here or can you reproduce it with just these 2 lines?
I confirm I can reproduce it with just those two lines with nvim --clean
.
You should make an issue to neovim, noice can't do anything about this.
Are the options above part of the noice code explicitly? The issue does disappear when not using noice (and it only occurs on "old" MacOs architectures).
Are the options above part of the noice code explicitly
What do you mean explicitly?, there is something close to the 2 lines in noice
This is called at the start of the command-line, and NoiceHiddenCursor
is the same as the HIDDEN
highlight in the 2 lines.
I see, I will address it to neovim, thank you for the explanation!
Hi, i have found a workaround for iterm, set the report terminal type option to linux in preferences > profiles > terminal
Nice!
I have digged an old neovim issue here where the same problem was discussed already: it seems that the problem is that this happens whenever the highlight group to which the guicursor
is set does not exist.
Using noice
the vim.opt.guicursor
defaults to a highlight group NoiceHiddenCursor
which seems not to be defined anywhere (or am I wrong)? I cannot find it in the documentation nor do I see it in the highlight groups that are being used in my configuration. I have tried to override it, however it appears that it is being overridden once again by the plugin somewhen in the require calls.
Could I ask you the favour to check if such highlight group is defined to be anything in the plugin code and/or if setting it to anything else could get rid of the problem?
check if such highlight group is defined to be anything in the plugin code
It's defined here: https://github.com/folke/noice.nvim/blob/0cbe3f88d038320bdbda3c4c5c95f43a13c3aa12/lua/noice/config/highlights.lua#L107
i’m sorry, what’s wrong with setting the report terminal type option to linux. It works.
Please excuse brevity/mistakes, message sent from my phone.
On Mon, Apr 8, 2024 at 3:01 PM Sam @.***> wrote:
check if such highlight group is defined to be anything in the plugin code
It's defined here:
— Reply to this email directly, view it on GitHub https://github.com/folke/noice.nvim/issues/671#issuecomment-2043466213, or unsubscribe https://github.com/notifications/unsubscribe-auth/AABEFAX6LTSHJH7RFRQMM3DY4LSSNAVCNFSM6AAAAABAXRLKBCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDANBTGQ3DMMRRGM . You are receiving this because you modified the open/close state.Message ID: @.***>
i’m sorry, what’s wrong with setting the report terminal type option to linux. It works. Please excuse brevity/mistakes, message sent from my phone.
changing terminal type option to linux completely changes terminal behaviour on non-linux computers (colours, fonts, shell completions, cursor movement and so forth).
@Sam-programs thank you for addressing the issue on the neovim side with the PR: it seems now to be entirely solved with the latest merge on master
(at least from my side).
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 7 days.
This issue was closed because it has been stalled for 7 days with no activity.
Did you check docs and existing issues?
Neovim version (nvim -v)
v0.10.0-dev-1858+g7e7da962d
Operating system/version
MacOs 10.15.7
Describe the bug
This only happens in the latest version of neovim v0.10.0-dev-1858+g7e7da962d where extra characters "ff" appear after ':' when enter ":" in normal mode.
No issue when noice is disabled..
Steps To Reproduce
Shift + :
Expected Behavior
Characters "ff" to not cloud the buffer replacing the cursor position.
Repro