diff --git a/autoload/SpaceVim/plugins/iedit.vim b/autoload/SpaceVim/plugins/iedit.vim index 59b62bf49..a4f2037da 100644 --- a/autoload/SpaceVim/plugins/iedit.vim +++ b/autoload/SpaceVim/plugins/iedit.vim @@ -136,6 +136,20 @@ function! s:handle_normal(char) abort let s:Operator = 'g' call s:timeout() endif + elseif a:char == 110 " n + if s:index == len(s:stack) - 1 + let s:index = 0 + else + let s:index += 1 + endif + call cursor(s:stack[s:index][0], s:stack[s:index][1] + len(s:symbol_begin)) + elseif a:char == 78 " N + if s:index == 0 + let s:index = len(s:stack) - 1 + else + let s:index -= 1 + endif + call cursor(s:stack[s:index][0], s:stack[s:index][1] + len(s:symbol_begin)) endif silent! call s:highlight_cursor() endfunction diff --git a/docs/documentation.md b/docs/documentation.md index 4d3fc0bad..e31592ac9 100644 --- a/docs/documentation.md +++ b/docs/documentation.md @@ -1454,6 +1454,8 @@ The defalut color for iedit is `red`/`green` which is based on the current color | `D` | delete the occurrences | | `gg` | go to first occurrence | | `G` | go to last occurrence | +| `n` | go to next occurrence | +| `N` | go to previous occurrence | **In iedit-Insert mode:**