cpea2506 / one_monokai.nvim

One Monokai for Neovim
MIT License
155 stars 9 forks source link

bug: different keyword color with vscode OneMonokai #88

Open xanahopper opened 1 month ago

xanahopper commented 1 month ago

Describe the bug

as you can see, key words enum, struct or even enum variant, field name have different color.

Same code source in VSCode:

image

with NVim 0.10 and one_monokai.nvim:

image

Screenshots

No response

Operating System + version

macOS 14.5 (23F79)

Neovim version

NVIM v0.10.1-dev-9+g671073e71

Reproduce steps

  1. open same code in VSCode and nvim with OneMonokai color theme.

Expected Behavior

No response

Additional context

No response

cpea2506 commented 1 month ago

Hi, have you tried to disable semantic token highlighting? If semantic token highlighting is enable, some of colors will be decided by language server instead.

If you have disabled it but the issue still happens, please take a picture and note on what are the most clearly difference you see. I will take my time for a look. Or if you know what to do, please consider a PR, that would be so helpful.

Note:

The color scheme for Neovim is designed in a way that cannot totally mimic the original one from VSCode because of the way they treat the language tokens.

Tips:

You can use :Inspect from within Neovim to see the token's highlight group under your cursor. The result will be like this:

Screenshot 2024-07-05 at 22 33 42

See more:

xanahopper commented 4 weeks ago

I'm not sure how to disable semantic token highlighting, but I tried

the first two operations did not make a change. After disable LSP & treesitter, color changes, like VSCode but not exactly same. It becomes like this image seems like with nvim builtin syntax, it lost lots of info for colorscheme.

I dont know what to do next.

xanahopper commented 4 weeks ago

I reverted all disables and re-enable LSP and Treesitter, do some inspect.

struct, enum

image

Unnamed enum variant

image