How do I configure Vim to move the cursor to the end of the previous line, when the left arrow key is pressed and the cursor is currently at the beginning of a line?
‘<' flag to the 'whichwrap' option to configure Vim to move the cursor to the end of the previous line, when the left arrow key is pressed and the cursor is currently at the beginning of a line: :set whichwrap+=< Similarly, to move the cursor the beginning of the next line, when the right arrow key is pressed and the cursor is currently at the end of a line, add the '>‘ flag to the ‘whichwrap’ option: :set whichwrap+= The above will work only in normal and visual modes. To use this in insert and replace modes, add the ‘[‘ and ‘]’ flags respectively. For more information, read :help ‘whichwrap’ :help 05.7 10.11.
‘whichwrap’ option to configure Vim to move the cursor to the end of the previous line, when the left arrow key is pressed and the cursor is currently at the beginning of a line: :set whichwrap+=< Similarly, to move the cursor the beginning of the next line, when the right arrow key is pressed and the cursor is currently at the end of a line, add the '>‘ flag to the ‘whichwrap’ option: :set whichwrap+=> The above will work only in normal and visual modes. To use this in insert and replace modes, add the ‘[‘ and ‘]’ flags respectively. For more information, read :help ‘whichwrap’ :help 05.7 10.11.
Related Questions
- How do I configure Vim to move the cursor to the end of the previous line, when the left arrow key is pressed and the cursor is currently at the beginning of a line?
- In the WP I moved the cursor onto a line and pressed [Home] but it is still several inches from the left hand edge of the screen - whats going on?
- What happens inside Asterisk when a shared line key is pressed?