The VSCodeVim team prioritizes issues based on reaction count.
FEATURE REQUEST:
Environment:
When I work on a LaTeX document I usually turn on automatic word wrap in VS Code because of long sentences. Navigating with j,k up and down the lines is a pain then because the cursor jumps right to the next line (with line number) rather than going down one screen line.
I'd love to navigate in those lines with soft line breaks the same way as in those with hard line breaks.
Undesired behaviour can be reproduced as follows:
Desired behaviour:
Cursor should move like it does with UP,DOWN when Vim-Mode is deactivated, namely from screen line to screen line.
@elmewo I believe you're looking for gj
That is correct, thank you. Unfortunately, I don't see a possibility to add conditions, such as
nnoremap <expr> k (v:count == 0 ? 'gk' : 'k')
nnoremap <expr> j (v:count == 0 ? 'gj' : 'j')
Can I do that here?
@elmewo unluckily, we can't do that currently.
Ok, thanks a lot! I'll close the issue, because my actual feature request is not needed. However, I'd appreciate conditional bindings in VSCodeVim.
@elmewo honestly, it seems unlikely to me that we'll be able to add conditional keybindings currently. I don't see a good way to do it that isn't fairly awkward.
However, when we integrate neovim https://github.com/Chillee/VSCodeNeovim that should be easily possible :)
It's possible to move among display lines with j, k, ↓ or ↑ by remapping key bindings as I documented in #3623.
Most helpful comment
@elmewo I believe you're looking for
gj