Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot use backspace to delete selected text in INSERT MODE #879

Closed
wangadong opened this issue Oct 11, 2016 · 10 comments
Closed

Cannot use backspace to delete selected text in INSERT MODE #879

wangadong opened this issue Oct 11, 2016 · 10 comments

Comments

@wangadong
Copy link

wangadong commented Oct 11, 2016

Please thumbs-up 👍 this issue if it personally affects you! You can do this by clicking on the emoji-face on the top right of this post. Issues with more thumbs-up will be prioritized.


What did you do?

Enter INSERT MODE, use mouse to select text, then press Backspace to delete the text

What did you expect to happen?

All selected text should be deleted

What happened instead?

Only deleted the last character

Technical details:

  • VSCode Version: 1.6.0
  • VsCodeVim Version: 0.3.5
  • OS: macOS Sierra
@andlrc
Copy link

andlrc commented Oct 11, 2016

If anything then selecting text with the mouse should enter visual mode, where backspace should shrinl the selection by one character.

@wangadong
Copy link
Author

hi @andlrc maybe I was indulged by Sublime vi mode. But I do think that is more intuitive behavior.

@andlrc
Copy link

andlrc commented Oct 11, 2016

What you want is something called select mode. You can toggle between select mode and visual mode with <C-g>. At least in vim it works like that.

@xconverge
Copy link
Member

@andlrc in MacVim, you can do what @wangadong is suggesting, I think it is fair the way he wrote it, and I agree it is annoying

@johnfn
Copy link
Member

johnfn commented Oct 12, 2016

This bug is legit. Backspace, even in visual mode, should delete whatever is selected.

If someone wants to implement Select Mode, please by all means go ahead. :)

@rebornix
Copy link
Member

Not just selecting by mouse, if you select the content by cmd+a and then press backspace, only one character is deleted as well.

@xconverge
Copy link
Member

@johnfn even visual mode? For me visual mode, backspace moves the end cursor back one position

@xconverge
Copy link
Member

@andlrc I think the part you missed was that he is using the mouse once already in INSERT mode.

Press i, then select text with arrow keys + modifier or mouse, then press backspace. That is what I addressed. Regular mouse selections while in normal put you into visual mode

@johnfn
Copy link
Member

johnfn commented Oct 18, 2016

@xconverge heh, I'm using macvim, maybe it does something weird?

@sethstha
Copy link

@xconverge
Also selecting duplicate with ctrl+d on insert mode and pressing backspace seems to delete only first occurrence.

Am I missing something ?

Have a look at here
#1358

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants