aboutsummaryrefslogtreecommitdiff
path: root/helix-view/src/prompt.rs
diff options
context:
space:
mode:
Diffstat (limited to 'helix-view/src/prompt.rs')
-rw-r--r--helix-view/src/prompt.rs18
1 files changed, 18 insertions, 0 deletions
diff --git a/helix-view/src/prompt.rs b/helix-view/src/prompt.rs
new file mode 100644
index 00000000..4aaf770b
--- /dev/null
+++ b/helix-view/src/prompt.rs
@@ -0,0 +1,18 @@
+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);
+ }
+}