简体   繁体   中英

How do I link highlighting groups in a vim colour scheme?

I'm trying to clean up a colour scheme that I'm making for vim by linking some highlighting groups but I can't get the linking to work.

Here is a sample of my vim script:

highlight Error            ctermbg=161
highlight link ErrorMsg    Error

The ErrorMsg still has the default background colour.

Make sure you're clearing the settings for ErrorMsg before the link, otherwise the link will fail.

highlight Error            ctermbg=161
highlight ErrorMsg         NONE
highlight link ErrorMsg    Error

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM