在“O"打开新行之前延迟? [英] Delay before 'O' opens a new line?

查看:13
本文介绍了在“O"打开新行之前延迟?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我注意到,偶尔,当我使用 O(大写 'o')创建一个新行并进入插入模式时,在发生任何事情之前会有一个短暂的延迟.>

这很常见吗?有什么办法可以改变吗?

:map O:imap O 都显示No mapping found",所以我不认为这是一个奇怪的映射.

解决方案

这是因为启用了 'esckeys' 选项(我刚刚发现的 nocompatible 的结果).当您按下 ^[O 时,会有一个小的延迟,因为它会判断您是使用箭头/功能键还是只是按顺序使用这两个键.

一种解决方案是禁用该选项并在插入模式下放弃箭头键.
另一种方法是将 'timeoutlen' 设置为小于 1000,也许是 100(但要小心慢速连接).
另一种是使用 ^C 而不是 ^[ 离开插入模式.

I've noticed that, occasionally, when I use O (capital 'o') to create a new line and go into insert mode, there is a short delay before anything happens.

Is this common? Is there any way to change it?

Both :map O and :imap O show "No mapping found", so I don't think it's a strange mapping.

解决方案

It's because the 'esckeys' option is enabled (a consequence of nocompatible as I just discovered). When you press ^[O, there's a small delay as it figures out if you're using an arrow/function key or if you just meant those two keys in sequence.

One solution is to disable that option and give up on the arrow keys in insert mode.
Another is to set 'timeoutlen' to something less than 1000, maybe 100 (but be careful over slow connections).
Another is to use ^C instead of ^[ to leave insert mode.

这篇关于在“O"打开新行之前延迟?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆