ulyssa / modalkit

A Rust library for building modal editing applications
Apache License 2.0
49 stars 5 forks source link

Support recording macros #28

Closed ulyssa closed 1 year ago

ulyssa commented 1 year ago

There's currently several Action types for recording macros (MacroExecute, MacroRepeat, MacroRecordToggle), and EditRepeat, but nothing to use them with. I'll need to figure out a way to store recorded macros in the target register, and allow passing the contents along to a ModalMachine instance.

crossterm doesn't have a way to parse a string into a KeyEvent vector, or convert a KeyEvent into it ANSI escape sequence, which would make implementing this easier.