ulyssa / modalkit

A Rust library for building modal editing applications
Apache License 2.0
57 stars 8 forks source link

Add Transcribe and give both Type and OpenLine a Count #51

Closed ulyssa closed 2 years ago

ulyssa commented 2 years ago

There's not currently a blessed way to insert strings directly into a buffer, so I'm going to add an InsertTextAction::Transcribe. This will make it easier to more appropriately handle crossterm's Event::Paste.

I'm also going to add a Count field to both InsertTextAction::Type and InsertTextAction::OpenLine so that you can use counts in Emacs with them as part of #50 . (Vim doesn't need it since it uses CursorAction::Split first when you enter Insert mode via a count.)