To: vim-dev@vim.org Subject: Patch 7.0.106 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 7.0.106 Problem: The spell popup menu uses ":amenu", triggering mappings. Other PopupMenu autocommands are removed. (John Little) Solution: Use ":anoremenu" and use an autocmd group. Files: runtime/menu.vim *** ../vim-7.0.105/runtime/menu.vim Tue Apr 18 00:06:31 2006 --- runtime/menu.vim Thu Sep 14 13:14:25 2006 *************** *** 2,8 **** " You can also use this as a start for your own set of menus. " " Maintainer: Bram Moolenaar ! " Last Change: 2006 Apr 17 " Note that ":an" (short for ":anoremenu") is often used to make a menu work " in all modes and avoid side effects from mappings defined by the user. --- 2,8 ---- " You can also use this as a start for your own set of menus. " " Maintainer: Bram Moolenaar ! " Last Change: 2006 Sep 14 " Note that ":an" (short for ":anoremenu") is often used to make a menu work " in all modes and avoid side effects from mappings defined by the user. *************** *** 885,890 **** --- 885,892 ---- if exists("s:changeitem") && s:changeitem != '' call SpellDel() endif + + " Return quickly if spell checking is not enabled. if !&spell || &spelllang == '' return endif *************** *** 908,925 **** let s:fromword = w let pri = 1 for sug in s:suglist ! exe 'amenu 1.5.' . pri . ' PopUp.' . s:changeitem . '.' . escape(sug, ' .') \ . ' :call SpellReplace(' . pri . ')' let pri += 1 endfor let s:additem = 'add\ "' . escape(w, ' .') . '"\ to\ word\ list' ! exe 'amenu 1.6 PopUp.' . s:additem . ' :spellgood ' . w . '' let s:ignoreitem = 'ignore\ "' . escape(w, ' .') . '"' ! exe 'amenu 1.7 PopUp.' . s:ignoreitem . ' :spellgood! ' . w . '' ! amenu 1.8 PopUp.-SpellSep- : endif endif endfunc --- 910,927 ---- let s:fromword = w let pri = 1 for sug in s:suglist ! exe 'anoremenu 1.5.' . pri . ' PopUp.' . s:changeitem . '.' . escape(sug, ' .') \ . ' :call SpellReplace(' . pri . ')' let pri += 1 endfor let s:additem = 'add\ "' . escape(w, ' .') . '"\ to\ word\ list' ! exe 'anoremenu 1.6 PopUp.' . s:additem . ' :spellgood ' . w . '' let s:ignoreitem = 'ignore\ "' . escape(w, ' .') . '"' ! exe 'anoremenu 1.7 PopUp.' . s:ignoreitem . ' :spellgood! ' . w . '' ! anoremenu 1.8 PopUp.-SpellSep- : endif endif endfunc *************** *** 938,944 **** let s:changeitem = '' endfun ! au! MenuPopup * call SpellPopup() endif " The GUI toolbar (for MS-Windows and GTK) --- 940,948 ---- let s:changeitem = '' endfun ! augroup SpellPopupMenu ! au! MenuPopup * call SpellPopup() ! augroup END endif " The GUI toolbar (for MS-Windows and GTK) *************** *** 1013,1021 **** tmenu ToolBar.FindPrev Find Previous tmenu ToolBar.Replace Find / Replace... endif ! tmenu ToolBar.LoadSesn Chose a session to load tmenu ToolBar.SaveSesn Save current session ! tmenu ToolBar.RunScript Chose a Vim Script to run tmenu ToolBar.Make Make current project (:make) tmenu ToolBar.RunCtags Build tags in current directory tree (!ctags -R .) tmenu ToolBar.TagJump Jump to tag under cursor --- 1017,1025 ---- tmenu ToolBar.FindPrev Find Previous tmenu ToolBar.Replace Find / Replace... endif ! tmenu ToolBar.LoadSesn Choose a session to load tmenu ToolBar.SaveSesn Save current session ! tmenu ToolBar.RunScript Choose a Vim Script to run tmenu ToolBar.Make Make current project (:make) tmenu ToolBar.RunCtags Build tags in current directory tree (!ctags -R .) tmenu ToolBar.TagJump Jump to tag under cursor *** ../vim-7.0.105/src/version.c Thu Sep 14 11:27:12 2006 --- src/version.c Thu Sep 14 13:24:44 2006 *************** *** 668,669 **** --- 668,671 ---- { /* Add new patch number below this line */ + /**/ + 106, /**/ -- BROTHER MAYNARD: Armaments Chapter Two Verses Nine to Twenty One. ANOTHER MONK: And St. Attila raised his hand grenade up on high saying "O Lord bless this thy hand grenade that with it thou mayest blow thine enemies to tiny bits, in thy mercy. "and the Lord did grin and people did feast upon the lambs and sloths and carp and anchovies and orang-utans and breakfast cereals and fruit bats and... BROTHER MAYNARD: Skip a bit brother ... "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ \\\ download, build and distribute -- http://www.A-A-P.org /// \\\ help me help AIDS victims -- http://ICCF-Holland.org ///