sainnhe / edge

Clean & Elegant Color Scheme inspired by Atom One and Material
MIT License
860 stars 56 forks source link

Wrong coloring with Treesitter #58

Closed gaborvecsei closed 2 years ago

gaborvecsei commented 2 years ago

Operating system/version

macOS/Ubuntu

Terminal emulator/version

iTerm2/Kitty

$TERM environment variable

xterm-256color

Tmux version

No response

Feature matrix

NVIM v0.8.0-dev+302-gaf2899aee Build type: Release LuaJIT 2.1.0-beta3

Minimal vimrc that can reproduce this bug.

call plug#begin('~/.config/nvim/plugged/')

Plug 'nvim-lua/plenary.nvim'
Plug 'nvim-treesitter/nvim-treesitter', {'do': ':TSUpdate'}
Plug 'sainnhe/edge'

call plug#end()

lua << EOF
    require'nvim-treesitter.configs'.setup {
    ensure_installed = {'python'},
    sync_install = false,
    ignore_install = {},
    highlight = {
          enable = true, -- `false` will disable the whole extension
          additional_vim_regex_highlighting = false,
    },
}
EOF

if (has('termguicolors'))
  let &t_8f = "\<Esc>[38;2;%lu;%lu;%lum"
  let &t_8b = "\<Esc>[48;2;%lu;%lu;%lum"
  set termguicolors
endif

" Edge Theme
let g:edge_style = 'neon'
colorscheme edge

Steps to reproduce this bug using minimal vimrc

  1. nvim +PlugClean +PlugInstall
  2. nvim <any python file>

Expected behavior

I should see the same coloring as I can see on the screenshots provided in the README.

(With vim-polygot it is working fine.)

Actual behavior

I attached the image how it colors my script:

image
gaborvecsei commented 2 years ago

Truecolor test output:

image
sainnhe commented 2 years ago

You mean you want white colors?

Simply disable tree-sitter in python.

gaborvecsei commented 2 years ago

Sorry, I thought that the coloring will be consistent no matter if we use tree-sitter or vim-ploygot and that it should match with the one we see on the screenshots.

But as I see I misunderstood, and I am closing the issue.