Compare commits
6 Commits
5022408e65
...
b048eba60c
Author | SHA1 | Date |
---|---|---|
mars | b048eba60c | |
Roux | 8cb37a7820 | |
Roux | badd6a0b71 | |
Roux | 36bbb3b77b | |
Roux | f5ea473328 | |
Roux | 8a110c5b01 |
13
src/main.rs
13
src/main.rs
|
@ -194,6 +194,19 @@ impl State {
|
|||
self.move_cursor(Direction::Right);
|
||||
self.mode = Mode::Insert(state);
|
||||
}
|
||||
KeyCode::Char('o') => {
|
||||
let state = InsertState { append: false };
|
||||
self.cursor.line += 1;
|
||||
self.cursor.column = 0;
|
||||
self.buffer.insert_char(self.cursor, '\n');
|
||||
self.mode = Mode::Insert(state);
|
||||
}
|
||||
KeyCode::Char('O') => {
|
||||
let state = InsertState { append: false };
|
||||
self.cursor.column = 0;
|
||||
self.buffer.insert_char(self.cursor, '\n');
|
||||
self.mode = Mode::Insert(state);
|
||||
}
|
||||
KeyCode::Char(':') => {
|
||||
self.mode = Mode::Command(Default::default());
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue