chromatica.nvim icon indicating copy to clipboard operation
chromatica.nvim copied to clipboard

Different coloring in a header vs cpp file

Open kartikmohta opened this issue 7 years ago • 5 comments

I noticed slightly different coloring in a header vs a cpp file, see screenshot:

chromatica_bug

Don't know if this is expected, seems wrong to me. The relevant settings in my vimrc are:

let g:chromatica#enable_at_startup=1
let g:chromatica#highlight_feature_level=1

kartikmohta avatar Nov 07 '17 06:11 kartikmohta

I think the cause might be you have different ft and syn. The one on the left seems treating the source code as C not C++.

arakashic avatar Nov 07 '17 19:11 arakashic

I checked the values of ft and syn for them and they are cpp for both. Tried disabling all other vim plugins as well but get the same behaviour.

kartikmohta avatar Nov 07 '17 19:11 kartikmohta

Same problem here.

davidkennedydev avatar Dec 06 '17 17:12 davidkennedydev

This is because libclang don't know how to compile header files, and they are not included in compile_commands.json. This is common problem to all plugins using lbclang

phush0 avatar Jan 11 '18 09:01 phush0

For anyone run into this problem, are you using a compile_commands.json or a .clang file for your compile args?

arakashic avatar Feb 25 '18 06:02 arakashic