Overtyping existing text

Most of the time, when you type new characters, they are added to the document at the caret.

If any text is selected, new characters you type, or paste from the clipboard, replace the existing selected characters, effectively overtyping them.