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

Remove backspace, delete, etc., bindings from insert mode for consistency #3861

Closed
aral opened this issue Sep 16, 2022 · 9 comments
Closed
Labels
C-enhancement Category: Improvements

Comments

@aral
Copy link
Contributor

aral commented Sep 16, 2022

Further to #3671, if we’re going to stick with insert mode being for insertion only, the following bindings should also be removed from insert mode for consistency:

  • Backspace
  • Delete
  • Delete previous word
  • Delete next word
  • Delete to start of line
  • Delete to end of line

(The other option, of course, is to revert #3671. Either way, the interface provided should be consistent.)

@aral aral added the C-enhancement Category: Improvements label Sep 16, 2022
@aral aral changed the title Remove backspace and delete bindings from insert mode Remove backspace, delete, insert new line, etc., bindings from insert mode for consistency Sep 16, 2022
@aral aral changed the title Remove backspace, delete, insert new line, etc., bindings from insert mode for consistency Remove backspace, delete, etc., bindings from insert mode for consistency Sep 16, 2022
@the-mikedavis
Copy link
Member

I don't see these bindings as inconsistent with the removals of #3671. #3671 covers navigation/movement while these are deletion actions.

@aral
Copy link
Contributor Author

aral commented Sep 16, 2022

@the-mikedavis Deletion in insert mode? We have deletion commands already (mapped to d, etc., in normal mode). If our design constraint is that people should not be bringing their non-modal habits with them and that insert mode should do just that (insert), then these should go to. The modal way to do it, surely, is to exit insert mode and use the delete command.

If that’s not our design constraint, then why was navigation singled out and removed?

@dead10ck
Copy link
Member

@aral you're taking the terms too literally. "insert mode" is for editing text. Inserting characters and deleting them. The reasons that navigation were removed were detailed in the PR's discussion. Take a closer read of the comments there.

@David-Else
Copy link
Contributor

Removing delete in insert mode would be madness.

When touch typing it is best practice to delete the entire last word if you make a mistake to improve muscle memory. Having to enter normal mode to do that would not be workable.

@archseer
Copy link
Member

There's a "selection mode" and a "text editing mode". We could rename them but INS reads a lot better than TXE.

@archseer archseer closed this as not planned Won't fix, can't repro, duplicate, stale Sep 16, 2022
@archseer
Copy link
Member

If you're trying to start a discussion about reintroducing those mappings then please do so instead of making a snarky issue :)

@YangtseSu
Copy link

YangtseSu commented Sep 16, 2022

@aral you're taking the terms too literally. "insert mode" is for editing text. Inserting characters and deleting them. The reasons that navigation were removed were detailed in the PR's discussion. Take a closer read of the comments there.

Helix is designed to work well with modal editing.
"insert mode" should be insert only. You can enter normal mode and delete characters with d, after disabling deletion in "insert mode".

If you want to do some deletion in "insert mode", you can add one line in your config.
What we're all talking about is 1 line in your config.

@aral
Copy link
Contributor Author

aral commented Sep 16, 2022

If you're trying to start a discussion about reintroducing those mappings then please do so instead of making a snarky issue :)

Done (#3865), but please understand this isn’t (an overly) ;) snarky issue. There is an inconsistency being introduced by this.

@archseer
Copy link
Member

@YangtseSu Your tone isn't helping this discussion.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-enhancement Category: Improvements
Projects
None yet
Development

No branches or pull requests

6 participants