Skip to main content

Module actions

Module actions 

Source
Expand description

App-side action registrations – the CommandKind::Action peers of the grammar’s built-in motions / operators / text- objects (lattice_grammar::builtins) and built-in ex-commands (lattice_grammar::ex_commands).

See docs/dev/notes/8i-approach.md for the slice 8.i plan. Each action registered here returns Effect::AppAction(AppEffect::Foo) from its apply closure; the App’s apply_app_effect then routes the AppEffect to the historical handler. Once slice 8.i.4 retires the legacy Action enum, the bodies move directly into apply_app_effect and this layer becomes the sole producer.

New AppEffect variants land here as a single line per variant plus a one-line ID field on ActionIds; the actual per-mode chord bindings live in keymap_normal.rs (and sibling per-mode modules) and consume ActionIds alongside Builtins.

Structs§

ActionIds
Strongly-typed handles to every App-side action registered in the global CommandRegistry. Mirrors the shape of lattice_grammar::builtins::Builtins: each field is the CommandId produced by CommandRegistry::register_action at startup. The App stores this struct; per-mode keymap modules consume it to build typed CommandInvocations for chord bindings.

Functions§

populate
Register every App-side action into registry and return the resulting ActionIds. Called once at App startup, after lattice_grammar::builtins::populate and lattice_grammar::ex_commands::populate.