rhysd / NyaoVim

Web-enhanced Extensible Neovim Frontend
Other
2.22k stars 57 forks source link

Some colors are not present #71

Open haifengkao opened 8 years ago

haifengkao commented 8 years ago

highlight has no effect for certain colors

Expected Behavior

2016-08-05 8 34 30

Actual Behavior

2016-08-05 8 35 40

Steps to Reproduce (including precondition)

:hi Comment guifg=seagreen3

Comments

neovim has the full color table here

rhysd commented 8 years ago

Thank you for your report. I'll investigate.

rhysd commented 8 years ago

Nice catch! Fix for this issue may also fix #33.

rhysd commented 8 years ago

@haifengkao Could you tell me your colorscheme name?

rhysd commented 8 years ago

I investigated this. But actually this looks bug of neovim.

From neovim, all colors are sent with 0xrrggbb format number. So all color names should be converted into RGB format number before sending via RPC. But actually it is not refrected. Below is a log when sending "//" on filetype=javascript after set Comment highlight to seagreen3.

Input to neovim: "/"
index.js:2365 COLOR: undefined
index.js:2365 COLOR: undefined
index.js:2365 COLOR: undefined
index.js:2461 Highlight is updated:  Object {fg: "#ffffff", bg: "#333333", sp: "#ffffff", bold: undefined, italic: undefined…}
index.js:1544 Cursor is moved to (0, 0)
index.js:2365 COLOR: undefined
index.js:2365 COLOR: undefined
index.js:2365 COLOR: undefined
index.js:2461 Highlight is updated:  Object {fg: "#ffffff", bg: "#333333", sp: "#ffffff", bold: undefined, italic: undefined…}
index.js:2309 drawText(): (0, 0) 2 Object {line: 0, col: 0}
index.js:1544 Cursor is moved to (16.802734375, 0)
index.js:2365 COLOR: undefined
index.js:2365 COLOR: undefined
index.js:2365 COLOR: undefined

Input to neovim: "/" is a second / for comment. Just after the input, highlight is not set to seagreen3 but set to gray color.

haifengkao commented 8 years ago

@rhysd thanks. I will tell neovim team

rhysd commented 8 years ago

@haifengkao Thank you for the report.