# Em dash in LaTeX

My friend Daniel Reeves was recently discussing different ways to typeset em dashes. Here is the way I like to do it in LaTeX.

GeSHi Error: GeSHi could not find the language tex (using path /home/robfelty/robfelty.com/wp-content/plugins/codecolorer/lib/geshi/) (code 2)

Here is the resulting output:

Different ways to make em dashes in LaTeX

Notice how using spaces around the --- can result in a dash at the end of a line, which is not desirable. And using no spaces around the --- doesn’t look nice, and can also result in problems when copying and pasting. The \dash command solves both of these issues. I did not come up with it myself, but I cannot remember where I found it.

This entry was posted in latex. Bookmark the permalink.