2

I often use an editor like OpenOffice Writer to build documentation. My documentation is usually technical, and it often includes commands for the terminal.

When I format a command, I will indent the command by 1/2 inch and I will change the font to Times Roman or Times New Roman.

The editors replace a hyphen with a dash (I think its called an em-dash). So a command like:

ls -al

will fail when copy/pasted into a terminal due to the errant character.

The problem comes to light after performing a "Save as PDF". No matter what I do, the PDF always ends up with the wrong dash or hyphen (even if the OO document seems correct).

How do I distinguish text that include a hyphen so that the dash is unchanged?

jww
  • 12,722

1 Answers1

1

Typographically speaking, what you are typing is a hyphen or minus, not a dash, and what OpenOffice Writer is replacing the hyphen with is a dash, either an e-dash or an em-dash, depending on the context in which OpenOffice Writer sees your hyphen.

This is explained in the OpenOffice Writer under replacement options. Look in the index.

You can change this behavior from the menu, Format -> AutoCorrect -> AutoCorrect Options... and uncheck either or both of the Replace dashes boxes. You can also access the relevant help topic by clicking Help in this dialog.

garyjohn
  • 36,494