mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
Behave ESC key correctly when vi command mode
This commit is contained in:
parent
46bfe907f1
commit
e9bc8b35c6
2 changed files with 3 additions and 1 deletions
|
@ -55,7 +55,7 @@ class Reline::KeyActor::ViCommand < Reline::KeyActor::Base
|
|||
# 26 ^Z
|
||||
:ed_unassigned,
|
||||
# 27 ^[
|
||||
:em_meta_next,
|
||||
:ed_unassigned,
|
||||
# 28 ^\
|
||||
:ed_ignore,
|
||||
# 29 ^]
|
||||
|
|
|
@ -1049,6 +1049,8 @@ class Reline::LineEditor
|
|||
end
|
||||
end
|
||||
|
||||
private def ed_unassigned(key) end # do nothing
|
||||
|
||||
private def ed_insert(key)
|
||||
if key.instance_of?(String)
|
||||
width = Reline::Unicode.get_mbchar_width(key)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue