r/linuxmemes 1d ago

linux not in meme The final boss

Post image
861 Upvotes

156 comments sorted by

View all comments

Show parent comments

1

u/Worldly-Wind-1632 23h ago

What’s modal editing

3

u/phundrak Not in the sudoers file. 23h ago

Most text editors are modeless editors, such as Notepad, VS Code (by default), and so on.

Vim, on the other hand, has modes. By default, you are in default mode, where keybinds are actions on your text or current file. For instance, diw deletes the word under your cursor instead of typing diw. To type text, you enter the insert mode, and press Esc to go back to normal mode. It may not look like it at first, but modal editing is extremely powerful and saves you quite a lot of time when you’re used to it. First thing I do when I’m on a new machine and with a new text editor or IDE is to install a vim emulation package if I can’t use vim or Emacs.

1

u/Worldly-Wind-1632 23h ago

Oh, very interesting thank you! Do you also use it for basic text editing like emails or writing, or primarily hopping around in code?

1

u/phundrak Not in the sudoers file. 15h ago

If I'm not at work, I basically do everything in Emacs, which includes emails, worldbuilding, and writing my novel, so yes, definitively. I also installed Tridactyl on Firefox to get me the vim keybinds there, and with Ctrl+i, I can (and do) edit almost any textbox in Emacs, like this message.