Patch 9.0.0960
Problem: Error when using the "Tools / Spelling / Find More Languages"
menu.
Solution: Remove "<SID>". Reset "g:menutrans_set_lang_to" when 'encoding'
changes. (closes #11625)
Files: runtime/menu.vim
*** ../vim-9.0.0959/runtime/menu.vim 2022-11-27 15:51:43.722995582 +0000
--- runtime/menu.vim 2022-11-27 16:16:19.723292274 +0000
***************
*** 474,480 ****
an <silent> 40.335.270 &Tools.&Spelling.&Find\ More\ Languages :call <SID>SpellLang()<CR>
let s:undo_spelllang = ['aun &Tools.&Spelling.&Find\ More\ Languages']
! def s:SpellLang()
for cmd in s:undo_spelllang
exe "silent! " .. cmd
endfor
--- 474,480 ----
an <silent> 40.335.270 &Tools.&Spelling.&Find\ More\ Languages :call <SID>SpellLang()<CR>
let s:undo_spelllang = ['aun &Tools.&Spelling.&Find\ More\ Languages']
! def s:SpellLang(encChanged = false)
for cmd in s:undo_spelllang
exe "silent! " .. cmd
endfor
***************
*** 482,488 ****
var enc = &enc == "iso-8859-15" ? "latin1" : &enc
! if !exists("g:menutrans_set_lang_to")
g:menutrans_set_lang_to = 'Set Language to'
endif
--- 482,489 ----
var enc = &enc == "iso-8859-15" ? "latin1" : &enc
! # Reset g:menutrans_set_lang_to when called for the EncodingChanged event.
! if !exists("g:menutrans_set_lang_to") || encChanged
g:menutrans_set_lang_to = 'Set Language to'
endif
***************
*** 510,521 ****
else
echomsg "Found " .. found .. " more spell files"
endif
# Need to redo this when 'encoding' is changed.
augroup spellmenu
! au! EncodingChanged * call <SID>SpellLang()
augroup END
enddef
-
endif
" Tools.Fold Menu
--- 511,522 ----
else
echomsg "Found " .. found .. " more spell files"
endif
+
# Need to redo this when 'encoding' is changed.
augroup spellmenu
! au! EncodingChanged * call SpellLang(true)
augroup END
enddef
endif
" Tools.Fold Menu
*** ../vim-9.0.0959/src/version.c 2022-11-27 15:51:43.722995582 +0000
--- src/version.c 2022-11-27 16:18:11.407338979 +0000
***************
*** 697,698 ****
--- 697,700 ----
{ /* Add new patch number below this line */
+ /**/
+ 960,
/**/
--
Two sheep in a meadow. One says "baaah". The other says "exactly!".
/// Bram Moolenaar -- Br...@Moolenaar.net --
http://www.Moolenaar.net \\\
/// \\\
\\\ sponsor Vim, vote for features --
http://www.Vim.org/sponsor/ ///
\\\ help me help AIDS victims --
http://ICCF-Holland.org ///