diff options
| author | zeertzjq <zeertzjq@outlook.com> | 2022-12-07 14:51:36 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-12-07 14:51:36 +0800 |
| commit | 0caae2376e6c8f6665143e77e4e7a0cdf2b054c4 (patch) | |
| tree | 35dc807dda8b78d4640a891420c6063790d4a2eb /runtime/menu.vim | |
| parent | ed23cd3e50e778604e45e85bc939271a7759ca1f (diff) | |
| parent | 214c9ed1e2ad7881103a0eaed646a29e3e1392cd (diff) | |
| download | rneovim-0caae2376e6c8f6665143e77e4e7a0cdf2b054c4.tar.gz rneovim-0caae2376e6c8f6665143e77e4e7a0cdf2b054c4.tar.bz2 rneovim-0caae2376e6c8f6665143e77e4e7a0cdf2b054c4.zip | |
Merge pull request #21324 from zeertzjq/vim-8.2.1768
vim-patch:8.2.1768,0e6adf8a29d5,fa3b72348d88
Diffstat (limited to 'runtime/menu.vim')
| -rw-r--r-- | runtime/menu.vim | 22 |
1 files changed, 21 insertions, 1 deletions
diff --git a/runtime/menu.vim b/runtime/menu.vim index 0a5ac36095..1c48d617eb 100644 --- a/runtime/menu.vim +++ b/runtime/menu.vim @@ -2,7 +2,7 @@ " You can also use this as a start for your own set of menus. " " Maintainer: Bram Moolenaar <Bram@vim.org> -" Last Change: 2020 Mar 29 +" Last Change: 2021 Dec 22 " 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. @@ -89,6 +89,21 @@ an 9999.75 &Help.-sep2- <Nop> an 9999.80 &Help.&Version :version<CR> an 9999.90 &Help.&About :intro<CR> +if exists(':tlmenu') + tlnoremenu 9999.10 &Help.&Overview<Tab><F1> <C-W>:help<CR> + tlnoremenu 9999.20 &Help.&User\ Manual <C-W>:help usr_toc<CR> + tlnoremenu 9999.30 &Help.&How-To\ Links <C-W>:help how-to<CR> + tlnoremenu <silent> 9999.40 &Help.&Find\.\.\. <C-W>:call <SID>Helpfind()<CR> + tlnoremenu 9999.45 &Help.-sep1- <Nop> + tlnoremenu 9999.50 &Help.&Credits <C-W>:help credits<CR> + tlnoremenu 9999.60 &Help.Co&pying <C-W>:help copying<CR> + tlnoremenu 9999.70 &Help.&Sponsor/Register <C-W>:help sponsor<CR> + tlnoremenu 9999.70 &Help.O&rphans <C-W>:help kcc<CR> + tlnoremenu 9999.75 &Help.-sep2- <Nop> + tlnoremenu 9999.80 &Help.&Version <C-W>:version<CR> + tlnoremenu 9999.90 &Help.&About <C-W>:intro<CR> +endif + fun! s:Helpfind() if !exists("g:menutrans_help_dialog") let g:menutrans_help_dialog = "Enter a command or word to find help on:\n\nPrepend i_ for Input mode commands (e.g.: i_CTRL-X)\nPrepend c_ for command-line editing commands (e.g.: c_<Del>)\nPrepend ' for an option name (e.g.: 'shiftwidth')" @@ -702,6 +717,11 @@ func s:BMCanAdd(name, num) return 0 endif + " no name with control characters + if a:name =~ '[\x01-\x1f]' + return 0 + endif + " no special buffer, such as terminal or popup let buftype = getbufvar(a:num, '&buftype') if buftype != '' && buftype != 'nofile' && buftype != 'nowrite' |