Search code examples
vimunderline

Why is vim drawing underlines on the place of tabs and how to avoid this?


Without any specific regularity my vim displays underlines on the place of tabs (see below).

Sometimes it also happens to the text: I type and it's underlined.

What could be a reason?

enter image description here


Solution

  • This is likely due to the fact that you are editing an html file and the text near the underline is inside of an <a> tag.

    To disable this you can add let html_no_rendering=1 to your ~/.vimrc. This setting will, however, also disable bold and italic styling for html files.

    If you wish to only disable the underlining, see :help html.vim. There it gives you instructions on what highlight groups you need to redefine without underline.