vimlet 0.2.0

A headless Vim editing engine for Rust
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
mod support;

use vimlet::{EditingState, Session};

fn main() {
    let mut host = support::StringHost::new("one two three");
    let mut session = Session::new();
    let mut state = EditingState::default();
    host.keys(&mut session, &mut state, "cwhello<Esc>w.");
    println!(
        "{} (mode: {:?}, cursor: {})",
        host.text,
        state.mode(),
        host.cursor.0
    );
}