By keys I mean like being Normal
mode and pressing e
(takes you to end of [next] word), by commands I mean like being in Normal
mode and pressing Shift+;
and typing :delete
.
For example: after entering select mode, I would like to be able to press Ctrl+e
to jump to the end of the line, selecting everything in between as I go, the equivalent of being in Visual mode
and pressing: Shift+$
. Is there something I can put in my .vim
file that would make that work ? I tried this:
snoremap <C-e> <S-$>
and
snoremap <C-e> execute "visual! <S-$>"
but they both don't work. The first one replaces the selection with a $
in the text and the second one replace the selection with visual! $
.
Or for example copying the selection, the equivalent of being in Visual mode
and pressing y
. I tried: snoremap <C-c> y
, but this just replaces the selection with a y
.
Intent behind this
I kinda of just want to use select mode to perform selections like in normal (GUI) editors, be able to select text with Arrow
and Alt+Arrow
, but also with Ctrl+[a|e]
for jumping to front/end of line and then be able to copy/delete/move/duplicate-up/down the selection, but then also just be able to start typing replace the selection. Ik you can just basically do all that with Visual mode but to replace the selection there's an extra step involved, which is first delete the selection and enter insert mode, then start typing.
Visual mode
. It's just out of curiosity, maybe someone experienced could quickly say if it's possible.c
, your new friend :) (:help v_c
says "Delete the highlighted text and start insert")