helix/helix-view/src/prompt.rs
2020-10-16 11:59:09 +09:00

18 lines
299 B
Rust

use std::string::String;
pub struct Prompt {
pub buffer: String,
}
impl Prompt {
pub fn new() -> Prompt {
let prompt = Prompt {
buffer: String::from(""),
};
prompt
}
pub fn insert_char(&mut self, c: char) {
self.buffer.push(c);
}
}