Showing a different background colour in Vim past 80 characters

前端 未结 6 1081
陌清茗
陌清茗 2020-12-07 06:53

I have seen Vim 80 column layout concerns, but the answer there highlights only actual content that goes over the 80 character mark. I want to have a 100+ column Vim window

6条回答
  •  遥遥无期
    2020-12-07 07:26

    Solution proposed in comment above. Highlight your background first then highlight the ColorColumn black as an overlay. Set your colorcolumn to lines 1-80.

    hi Normal guibg=#32322f ctermbg=236
    hi NonText guibg=#32322f ctermbg=236
    hi ColorColumn guibg=#000000 ctermbg=0
    let &colorcolumn=join(range(1,80),",")
    

提交回复
热议问题