VIM spelling function -
i wan't have function turns spell check on go's next misspelled word , replaces first suggestion heres i've got far:
function! spell_new_word() set spell=true exe ']s' exe '1z=' set spell=false endfunction but seems set spelling true , doesn't anything.... doing wrong?
update:
i've tired changing exe normal, still no luck:
function! spell_new_word() set spell! normal ']s' normal '1z=' set spell! endfunction update 2:
i've tired , still doesn't work:
function! spell_new_word() set spell normal ]s normal 1z= set nospell endfunction but don't think problem think thats not binding ,d:
let mapleader = "," namp ,d spell_next_word()
nnoremap ,d :call spell_next_word()^m things note:
- choose mode (normal mode, no remapping)
- include
:enter command mode callfunction- execute it!
^mnormally entered c-venter on linux, or c-qenter on windows
additionally, perhaps include
inoremap ,d ^o:call spell_next_word()^m (again typeing ^o c-vc-o or c-qc-o)
Comments
Post a Comment