preservim/vim-colors-pencil

Option to support under curl for spelling errors, for GUI

reedes opened this issue · 5 comments

Starting with GUI-only, as I don't have a good test environment for cterm.

Non-spell underlines will remain straight "underline", without curls.

I'll try to take a look at the cterm sometime, have been swamped with work recently.

It's much appreciated. I did my best to leave the door open to a terminal implementation, if it is feasible.

Alternatively, we can make all the spelling highlights curled by default, removing the configuration option altogether.

That should be easier to implement and test.

short version: Go ahead and set cterm="undercurl", and if a terminal environment supports it an undercurl will be used. Modern versions of vim will fallback to an underline. Or, leave it as-is.

long version: Apparently there is a published standard for sending undercurls, similar to underlines or italics or bold or anything else, and vim follows it. If there is any terminal emulator that supports it, no one's using it. I'm half-tempted to try hacking it into iTerm.

I'm doing my prose-writing in MacVim these days, so I'm not inclined to care too much. A co-worker is trying to get me to switch to IntelliJ for coding after I named a function isPositiveNumer because apparently it will spell-check your code, but then I fixed the problem faster than he could launch IntelliJ, and YouCompleteMe had made sure all the code was using the misspelled function name anyway.

Updated to use undercurl for spelling errors, for both gui and terminal.