Skip to content
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

cursor blinks very quickly #10

Closed
Stanislav-Lapata opened this issue Jan 2, 2021 · 6 comments
Closed

cursor blinks very quickly #10

Stanislav-Lapata opened this issue Jan 2, 2021 · 6 comments
Labels
bug Something isn't working

Comments

@Stanislav-Lapata
Copy link

the cursor blinks very quickly in insert mode

Screen.Recording.2021-01-02.at.07.39.28.mov
my config
return function()
  local lualine = require('lualine')
  lualine.theme = 'gruvbox'
  lualine.separator = '/'
  lualine.sections = {
    lualine_a = { 'mode' },
    lualine_b = { 'filename' },
    lualine_c = {  },
    lualine_x = {  },
    lualine_y = { 'branch' },
    lualine_z = { 'filetype'  },
    lualine_diagnostics = {  }
  }
  lualine.inactiveSections = {
    lualine_a = { 'mode' },
    lualine_b = { 'filename' },
    lualine_c = {  },
    lualine_x = {  },
    lualine_y = { 'branch' },
    lualine_z = { },
    lualine_diagnostics = {  }
  }
  lualine.extensions = { 'fzf' }
  lualine.status()
end
@manimax3
Copy link

manimax3 commented Jan 2, 2021

Try it without the 'branch' sections which solved the issue for me.

I don't know why but the call to vim.fn.systemlist in the branch module seems to cause the cursor flickering.
If you have vim-fugitive installed I use this as a temporary solution:

lualine.sections.lualine_b = { function() 
    return vim.fn["fugitive#head"]()
end }

@hoob3rt
Copy link
Contributor

hoob3rt commented Jan 2, 2021

Yes, the branch function is causing problems for now. This may be related as well. I will try to fix it today.

@Stanislav-Lapata
Copy link
Author

Stanislav-Lapata commented Jan 2, 2021

@hoob3rt hoob3rt added the bug Something isn't working label Jan 2, 2021
@hoob3rt
Copy link
Contributor

hoob3rt commented Jan 3, 2021

could you confirm if f62c0d4 solves this issue?

@hoob3rt
Copy link
Contributor

hoob3rt commented Jan 4, 2021

@hoob3rt in Insert mode
https://github.com/hoob3rt/lualine.nvim/blob/master/lua/lualine.lua#L60 is called cyclically
https://user-images.githubusercontent.com/12072329/103457223-380a1d80-4d0e-11eb-9a46-c831f66f994c.mov
is it OK?

Yes that should be okay, otherwise things like cursor position or file location won't be updated in insert mode.

@manimax3
Copy link

manimax3 commented Jan 4, 2021

@hoob3rt thanks, this fixed the issue. at least on my side

@hoob3rt hoob3rt closed this as completed Jan 4, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants