How to make the `CocInlayHints` background color transparent in `.vimrc`

425 Views Asked by At

This is a follow up question to Change the color of the type hint in coc.nvim's rust-analyzer

I'm wondering if it's possible to change the background color of inlay hints from Rust Analyzer in Vim. Adding a hex #ffffff00 doesn't seem to work, nor does just 0.

1

There are 1 best solutions below

0
On BEST ANSWER

After some more experimenting I was able to find that if you just remove the option for a background color in the examples provided in the aforementioned question, it will not have a background as desired. For me, that looks like:

"For Types hint
hi default CocInlayHint ctermfg=71

The part to remove is ctermbg=0. I also removed other parts from the example provided but it seemed to have no effect so I've left them out here as well.