I'm trying to map the <Cq>
combination to enter/exit the Command Line Window (CmdWin).
But when I leave the CmdWin, I'm not able to return to the insert
mode, but vim automatically goes back to the normal
mode
In my .vimrc
the following snippet is used, but doesn't work.
nmap <C-q> <Esc>:<C-f>
imap <C-q> <Esc><C-q>
au CmdWinLeave * startinsert!
I've also tried with:
au CmdWinLeave * startinsert
au CmdWinLeave * normal
您可以映射: imap <Cq> <Esc>:q<CR>a
,然后在CmdWin中编辑时按<Cq>
时它将重新进入插入模式。
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.