如何更改 Vim 状态行中用于空格的字符? [英] How to change the characters used for empty space in Vim status line?
问题描述
我在 Vim 中使用以下 statusline
设置:
I’m using the following statusline
setting in Vim:
set statusline=%<%f\ %h%m%r%{fugitive#statusline()}%=%-14.(%l,%c%V%)\ %P
它产生以下状态行:
推荐答案
遇到了同样的问题,最终意识到我只有在使用某些颜色方案时才会看到它.进一步挖掘发现,这些配色方案将 StatusLine
和 StatusLineNC
高亮组设置为相同的值.
Had the same issue, and eventually realized that I was seeing it only when using certain colorschemes. A little more digging revealed that these colorschemes were setting StatusLine
and StatusLineNC
highlighting groups to identical values.
:help StatusLineNC
注意到如果 StatusLine
和 StatusLineNC
的值相等,那么 Vim 将使用 ^^^
在当前窗口的状态行中.
:help StatusLineNC
notes that if StatusLine
and StatusLineNC
have equal values, then Vim will use ^^^
in the status line of the current window.
解决方法是在有问题的配色方案中注释掉更改这些值的行.
The fix was to comment out the lines that changed these values in the problematic colorschemes.
这篇关于如何更改 Vim 状态行中用于空格的字符?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!