[gnome-builder] vim: keep cursor on position 0 after 'dd'
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder] vim: keep cursor on position 0 after 'dd'
- Date: Sat, 13 Dec 2014 03:52:37 +0000 (UTC)
commit e8af69bc5ab8d2fe3f6a32129eae51ace9b36c00
Author: Christian Hergert <christian hergert me>
Date: Fri Dec 12 19:52:31 2014 -0800
vim: keep cursor on position 0 after 'dd'
This should feel more like VIM now.
src/vim/gb-source-vim.c | 6 ++++++
1 files changed, 6 insertions(+), 0 deletions(-)
---
diff --git a/src/vim/gb-source-vim.c b/src/vim/gb-source-vim.c
index 34c6d97..99e19f7 100644
--- a/src/vim/gb-source-vim.c
+++ b/src/vim/gb-source-vim.c
@@ -4033,6 +4033,12 @@ gb_source_vim_cmd_delete (GbSourceVim *vim,
}
gb_source_vim_delete_selection (vim);
+
+ if (modifier == 'd')
+ {
+ /* Move the cursor to the 0 position */
+ gb_source_vim_cmd_backward_0 (vim, 0, 0);
+ }
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]