diff options
author | bptato <nincsnevem662@gmail.com> | 2023-09-08 20:07:58 +0200 |
---|---|---|
committer | bptato <nincsnevem662@gmail.com> | 2023-09-08 20:23:42 +0200 |
commit | 39e9d80a49124067edb38c4711c58d5cb790c91e (patch) | |
tree | e4c676814f13078ad77ffaa5101f852870d05809 /res | |
parent | 099550625e55ad59a6ed6bef54ad0d86470cdd91 (diff) | |
download | chawan-39e9d80a49124067edb38c4711c58d5cb790c91e.tar.gz |
Add vi-style numeric prefixes, make gotoLine 1-based
* it is now possible to jump to the nth line by typing {n}G * gotoLine is now 1-based, so to go to the first line you would use pager.gotoLine(1) * it is now allowed to return a function from a keybinding (which will be subsequently executed as a regular keybinding)
Diffstat (limited to 'res')
-rw-r--r-- | res/config.toml | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/res/config.toml b/res/config.toml index b96f05d8..14b746fd 100644 --- a/res/config.toml +++ b/res/config.toml @@ -38,6 +38,9 @@ default-headers = { Cache-Control = "no-cache" } +[input] +vi-numeric-prefix = true + [display] color-mode = "auto" format-mode = "auto" @@ -104,9 +107,8 @@ U = 'pager.reload()' r = 'pager.redraw()' R = 'pager.reshape()' M-C-c = 'pager.cancel()' -1G = 'pager.cursorFirstLine()' g = 'pager.cursorFirstLine()' -G = 'pager.cursorLastLine()' +G = 'n => n ? pager.gotoLine(n) : pager.cursorLastLine()' M-g = 'pager.gotoLine()' z = 'pager.centerLine()' C-g = 'pager.lineInfo()' |