From e4788bace8acadd5c41265c80f608f50f2fd49cc Mon Sep 17 00:00:00 2001 From: Jussi Tiira Date: Mon, 15 Nov 2021 20:49:32 +0000 Subject: [PATCH] ADD: h/l for horizontal movement --- ui/keybindings.go | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/ui/keybindings.go b/ui/keybindings.go index 5fc7356..cb2bd30 100644 --- a/ui/keybindings.go +++ b/ui/keybindings.go @@ -50,11 +50,21 @@ func setKeyBinding(c *controller, g *gocui.Gui) error { return err } + err = g.SetKeybinding("", 'h', gocui.ModNone, c.cursorLeft) + if err != nil { + return err + } + err = g.SetKeybinding("", gocui.KeyArrowRight, gocui.ModNone, c.cursorRight) if err != nil { return err } + err = g.SetKeybinding("", 'l', gocui.ModNone, c.cursorRight) + if err != nil { + return err + } + err = g.SetKeybinding("", gocui.KeyHome, gocui.ModNone, c.cursorHome) if err != nil { return err