I like to use undercurl to highlight spelling mistakes in Vim. I believe it does this by default. This works fine in MacOS and Linux but it isn't visible for gvim on Windows 10. Originally, I thought it was missing but it turns out that it's there very faintly.

undercurl on Windows

I apologize for the bad font but this is what I get when I use -u NONE. It also doesn't work with my customized font, Consolas:h10 or guifont=DejaVu_Sans_Mono_for_Powerline:h10:cANSI:qDRAFT.

Compare this to the same settings on Mac. The undercurl is more visible.

undercurl on Mac

Is there a way to get undercurl to display more boldly on Windows 10? I am using gvim 8.2. I found this question but it's not relevant since I still have the the problem with a minimal configuration (i.e. no vim-solarized colorscheme. Maybe another font is better? Some accessibility setting?

  • 3
    Isn't there a tiny undercurl below the xxx in your screenshot? – Christian Brabandt Jun 8 '20 at 15:07
  • Hmmm, my old eyes can't see that. I guess I should change this question to "How do I make undercurl visible. – Stephen Rasku Jun 8 '20 at 17:09
  • I agree, it's very hard to see. Does changing the font size (and of course the font, the default is not very nice) make a difference? How about turning on directx rendering (see :h 'renderoptions' )? – Christian Brabandt Jun 9 '20 at 6:19
  • @ChristianBrabandt, thanks for the question. Changing the font or the font size seems to have no effect on the visibility of undercurl. Similarly for renderoptions. – Stephen Rasku Jun 9 '20 at 15:47

Maybe another font is better? Some accessibility setting?

GVim has different undercurl implementation in Windows and Mac. The code for Mac uses "LineTo" primitive, but Windows-specific procedure sticks to "SetPixel" and you can't do anything about this except choosing more contrast color or opening issue on Vim's github.

I'd rather choose not to have "undercurl" at all. For example, make SpellBad look as Underlined instead:

augroup color_fix | au!
    autocmd ColorScheme * hi! link SpellBad Underlined
augroup end

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.