kkawakam / rustyline

Readline Implementation in Rust
https://crates.io/crates/rustyline/
MIT License
1.53k stars 176 forks source link

How to access LineBuffer? #656

Open rtfeldman opened 1 year ago

rtfeldman commented 1 year ago

Thanks for making rustyline! I've been enjoying it.

I see the docs for LineBuffer but I can't seem to find a way to obtain one. Looking through the source, it seems none of its usages are exposed (that I can tell), but LineBuffer itself is exposed, which makes me think there's some way to access it...I just can't figure out what it is!

gwenn commented 1 year ago

Currently, the only place where you access the LineBuffer is here. => https://docs.rs/rustyline/latest/rustyline/completion/trait.Completer.html#method.update We may add something like replxx modify_callback.