Dashes And HyphensA lot of people are familiar only with the hyphen ("-") as a horizontal-line puntuator. However, in typesetting, there are several kinds of horizontal line punctuators. This page describes them. Underscore ("_"): The underscore is used in identifiers in computer programs as a sort of visible space-substitute. For example "list_header_record". On a Macintosh, underscore can be struck by holding down the shift key and pressing the hyphen key. I think it's the same for Windows. Hyphen ("-"): The hyphen is used to connect words that are closely bound to each other in phrases such "dual-band" or surnames such as "Cartright-Smith". The hyphen is the shortest of all the constructs described on this page. On a Macintosh, a hyphen can be struck by hitting the hyphen key next to the key for the digit zero. I think it's the same for Windows. En dash (""): The en-dash is named because it is the same width as a lower case letter "n". It is longer than the hyphen and shorter than the em-dash. En-dashes are used in numerical ranges such as "pages 367422". On a Macintosh, an en-dash can be struck by holding down option and hitting the hyphen key. In HTML it is –. On Windows, to type an en-dash, press and hold down the ALT key and then type the digits 0150 on the numeric keypad and then release the ALT key. Em dash (""): The em-dash (also called just "dash") is named because it is the same width as a lower case letter "m". Em dashes are longer than both hyphens and en-dashes. Em-dashes are used to separate major components of sentences. For example: "Overhead the far-ranging Catalina air-boats soared vigilant protecting eagles of the skies". Note: It's easy to get into the habit of overusing dashes in sentences, so use them carefully. Very often a semicolon will be more appropriate. On a Macintosh, an em-dash can be struck by holding down shift and option and hitting the hyphen key. In HTML it is —. On Windows, to type an em-dash, press and hold down the ALT key and then type the digits 0151 on the numeric keypad and then release the ALT key. Here is an example of a sentence that contains all four kinds:
"James Smith-Bloggs looked up the software manual and saw that on pages 345346 the identifier loop_counter was being used as a flag a big mistake." Ross Williams (ross@ross.net) Revised 11 November 2003.
Home RossHome Copyright © Ross Williams 2001-2002. All rights reserved. |