tamton-aquib / dynamic-cursor.nvim

inverts the cursor color (as some terminals like kitty doesn't support it)

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

dynamic-cursor.nvim

A neovim plugin in lua that gives the cursor dynamic highlight.

Some terminals like alacritty has this by default. But some others like kitty does not support it. This plugin gets the treesitter highlight and sets it to cursor.

❗ Kitty has introduced this recently: afe728 so this plugin is obsolete now.

Alacritty:

alacritty

Kitty:

kitty

Installation

  • Vim-plug:
    Plug 'tamton-aquib/dynamic-cursor.nvim'
  • Packer
    use 'tamton-aquib/dynamic-cursor.nvim'

Configuration

require("dynamic-cursor").setup()
the default config looks something like:
require("dynamic-cursor").setup { 
	guicursor = "n-v-c:block-DynamicCursor,i:ver100-DynamicCursor" 
}

  • This plugin exposes a highlight: DynamicCursor which can be used elsewhere.
  • The treesitter highlight function was mostly taken from treesitter-playground.

About

inverts the cursor color (as some terminals like kitty doesn't support it)


Languages

Language:Lua 100.0%