aboutsummaryrefslogtreecommitdiff
path: root/helix-term/src/commands.rs
diff options
context:
space:
mode:
authorRobin van Dijk2021-06-10 11:10:05 +0000
committerBlaž Hrastnik2021-06-10 13:02:38 +0000
commitc0d32707d03d71434c290e18d6db18b3b2de3875 (patch)
tree89c8af1aeba2421709b1cd4f56b4423ebf4a8a65 /helix-term/src/commands.rs
parentd8df10f2958f70ee84b7c78cb7ea00aa195bc1c5 (diff)
move to first nonwhitespace on shift-i
This matches the behaviour in vim and kak
Diffstat (limited to 'helix-term/src/commands.rs')
-rw-r--r--helix-term/src/commands.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/helix-term/src/commands.rs b/helix-term/src/commands.rs
index 3358f9d2..d8c56f4e 100644
--- a/helix-term/src/commands.rs
+++ b/helix-term/src/commands.rs
@@ -1189,9 +1189,9 @@ pub fn buffer_picker(cx: &mut Context) {
cx.push_layer(Box::new(picker));
}
-// I inserts at the start of each line with a selection
+// I inserts at the first nonwhitespace character of each line with a selection
pub fn prepend_to_line(cx: &mut Context) {
- move_line_start(cx);
+ move_first_nonwhitespace(cx);
let doc = cx.doc();
enter_insert_mode(doc);
}