diff options
| author | Maxime Coste <mawww@kakoune.org> | 2024-05-31 12:38:28 +1000 |
|---|---|---|
| committer | Maxime Coste <mawww@kakoune.org> | 2024-05-31 12:38:28 +1000 |
| commit | 5c97efacb9050159aed83902184dc9c9272c4a56 (patch) | |
| tree | 3b857a39ff77061b78c8ea98cc35954600688a47 /src | |
| parent | e6a70e621de46cbd2c984d6fee5554c9902157af (diff) | |
Add v< and v> to scroll cursor to the leftmost/rightmost column
Diffstat (limited to 'src')
| -rw-r--r-- | src/normal.cc | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/normal.cc b/src/normal.cc index 4ea202ae..128a7193 100644 --- a/src/normal.cc +++ b/src/normal.cc @@ -399,6 +399,13 @@ void view_commands(Context& context, NormalParams params) case 'b': window.display_line_at(cursor.line, window.dimensions().line-1); break; + case '<': + window.display_column_at(context.buffer()[cursor.line].column_count_to(cursor.column), 0); + break; + case '>': + window.display_column_at(context.buffer()[cursor.line].column_count_to(cursor.column), + window.dimensions().column-1); + break; case 'h': window.scroll(-std::max<ColumnCount>(1, count)); break; @@ -420,6 +427,8 @@ void view_commands(Context& context, NormalParams params) {{'m'}, "center cursor (horizontally)"}, {{'t'}, "cursor on top"}, {{'b'}, "cursor on bottom"}, + {{'<'}, "cursor on left"}, + {{'>'}, "cursor on right"}, {{'h'}, "scroll left"}, {{'j'}, "scroll down"}, {{'k'}, "scroll up"}, |
