Skip to main content

Module keymap

Module keymap 

Source
Expand description

The keyboard command system: one static binding table drives both dispatch (lookup) and the command bars (bar_items), so a binding shown in a bar is by construction the binding that fires.

Structs§

Binding
KeyChord
When
Applicability of a binding, shared by dispatch and the bars. Bindings apply in Normal mode only — Command mode keys go to the line editor, and any key closes Help.

Enums§

Bar
Command
Everything the reducer can be asked to do. Key bindings produce the simple variants; the ‘:’ command line produces Ex.

Statics§

KEYMAP
The single source of truth. Order matters twice over: the first matching row dispatches, and bar order follows table order.

Functions§

bar_items
The (key, action) labels a bar shows in the current state — derived from the same rows and predicate lookup dispatches through.
lookup
Resolve a Normal-mode key press to a command: the first binding whose applicability and chord both match.