diff options
| author | Marc André Tanner <mat@brain-dump.org> | 2015-07-03 18:10:05 +0200 |
|---|---|---|
| committer | Marc André Tanner <mat@brain-dump.org> | 2015-07-03 18:10:05 +0200 |
| commit | e939ddc25927a1b0f03f3a878acfc1ffe167ff3f (patch) | |
| tree | c98f6644e480dacfbdcc3dbb8eac2aa25aac0d8f /vis.c | |
| parent | 506be16743cc5a049b9dcc640f2da74955f1ce2f (diff) | |
| download | vis-e939ddc25927a1b0f03f3a878acfc1ffe167ff3f.tar.gz vis-e939ddc25927a1b0f03f3a878acfc1ffe167ff3f.tar.xz | |
Add movements to next/previous character within same line
These movements always keep the cursor on the same line and do
not move over newlines.
Diffstat (limited to 'vis.c')
| -rw-r--r-- | vis.c | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -105,6 +105,8 @@ enum { MOVE_COLUMN, MOVE_CHAR_PREV, MOVE_CHAR_NEXT, + MOVE_LINE_CHAR_PREV, + MOVE_LINE_CHAR_NEXT, MOVE_WORD_START_NEXT, MOVE_WORD_END_PREV, MOVE_WORD_END_NEXT, @@ -186,6 +188,8 @@ static Movement moves[] = { [MOVE_COLUMN] = { .txt = column, .type = CHARWISE|IDEMPOTENT}, [MOVE_CHAR_PREV] = { .txt = text_char_prev }, [MOVE_CHAR_NEXT] = { .txt = text_char_next }, + [MOVE_LINE_CHAR_PREV] = { .txt = text_line_char_prev, .type = CHARWISE }, + [MOVE_LINE_CHAR_NEXT] = { .txt = text_line_char_next, .type = CHARWISE }, [MOVE_WORD_START_PREV] = { .txt = text_word_start_prev, .type = CHARWISE }, [MOVE_WORD_START_NEXT] = { .txt = text_word_start_next, .type = CHARWISE }, [MOVE_WORD_END_PREV] = { .txt = text_word_end_prev, .type = CHARWISE|INCLUSIVE }, |
