How is "--" changed to "—" within Mail, TextEdit…?

Edit > Substitutions > Untick "Smart dashes". Then relaunch "TextEdit". Same with "Mail".

To your third q: It is simply more beautiful. Personally I don't like when people type long dashes by using two short ones.

A tip: you can type long one even with "smart dashes" disabled with Option+- (short dash).


System Prefs > Keyboard > Text
Uncheck "Use smart quotes & dashes"

enter image description here


If you'd still prefer substitutions to be enabled, but just want to undo a substitution one time, immediately after the substitution occurs simply press CommandZ (or Edit → Undo). I suppose this isn't too well-known; I recall myself finding out only by coincidence. The downside to this is the substitution will be selected so you need to press Command to jump back to the end.

Demo