Add begin-of-line vim command
This commit is contained in:
parent
7f37451398
commit
686ff9b2ad
|
@ -718,6 +718,7 @@ end
|
|||
function core.on_event(type, ...)
|
||||
local did_keymap = false
|
||||
if type == "textinput" then
|
||||
-- FIXME: send textinput event to vim key-bindings module in vim mode
|
||||
core.root_view:on_text_input(...)
|
||||
elseif type == "keypressed" then
|
||||
did_keymap = keymap.on_key_pressed(...)
|
||||
|
|
|
@ -26,12 +26,14 @@ end
|
|||
|
||||
local verbs_obj = {'c', 'd'}
|
||||
local verbs_imm = {'a', 'h', 'i', 'j', 'k', 'l', 'p', 'u', 'x', 'y', 'left', 'right', 'up', 'down'}
|
||||
local vim_objects = {'d', 'e', 'w', '$'}
|
||||
local vim_objects = {'d', 'e', 'w', '^', '0', '$'}
|
||||
|
||||
local vim_object_map = {
|
||||
['e'] = 'next-word-end',
|
||||
['w'] = 'next-word-begin',
|
||||
['$'] = 'end-of-line',
|
||||
['^'] = 'start-of-line',
|
||||
['0'] = 'start-of-line',
|
||||
}
|
||||
|
||||
local function vim_execute(verb, mult, object)
|
||||
|
|
Loading…
Reference in New Issue