HOME

TheInfoList



OR:

The hyphen-minus is the most commonly used type of
hyphen The hyphen is a punctuation mark used to join words and to separate syllables of a single word. The use of hyphens is called hyphenation. ''Son-in-law'' is an example of a hyphenated word. The hyphen is sometimes confused with dashes ( figure ...
, widely used in digital
document A document is a written, drawn, presented, or memorialized representation of thought, often the manifestation of non-fictional, as well as fictional, content. The word originates from the Latin ''Documentum'', which denotes a "teaching" o ...
s. It is the only character that looks like a
minus sign The plus and minus signs, and , are mathematical symbols used to represent the notions of positive and negative, respectively. In addition, represents the operation of addition, which results in a sum, while represents subtraction, resul ...
or a
dash The dash is a punctuation mark consisting of a long horizontal line. It is similar in appearance to the hyphen but is longer and sometimes higher from the baseline. The most common versions are the endash , generally longer than the hyphen ...
in many character sets such as
ASCII ASCII ( ), abbreviated from American Standard Code for Information Interchange, is a character encoding standard for electronic communication. ASCII codes represent text in computers, telecommunications equipment, and other devices. Because ...
or on most keyboards, so it is also used as such. The name "hyphen-minus" derives from the original ASCII standard, where it was called "hyphen(minus)". The character is referred to as a "hyphen", a "minus sign", or a "dash" according to the context where it is being used.


Description

In early
monospaced font A monospaced font, also called a fixed-pitch, fixed-width, or non-proportional font, is a font whose letters and characters each occupy the same amount of horizontal space. This contrasts with variable-width fonts, where the letters and spac ...
typewriter A typewriter is a mechanical or electromechanical machine for typing characters. Typically, a typewriter has an array of keys, and each one causes a different single character to be produced on paper by striking an inked ribbon selectivel ...
s and character encodings, a single key/code was almost always used for hyphen, minus, various dashes, and strikethrough, since they all have a roughly similar appearance. The current
Unicode Standard Unicode, formally The Unicode Standard,The formal version reference is is an information technology standard for the consistent encoding, representation, and handling of text expressed in most of the world's writing systems. The standard, whic ...
specifies distinct characters for a number of different
dash The dash is a punctuation mark consisting of a long horizontal line. It is similar in appearance to the hyphen but is longer and sometimes higher from the baseline. The most common versions are the endash , generally longer than the hyphen ...
es, an unambiguous
minus sign The plus and minus signs, and , are mathematical symbols used to represent the notions of positive and negative, respectively. In addition, represents the operation of addition, which results in a sum, while represents subtraction, resul ...
("Unicode minus") at
code point In character encoding terminology, a code point, codepoint or code position is a numerical value that maps to a specific character. Code points usually represent a single grapheme—usually a letter, digit, punctuation mark, or whitespace—but ...
U+2212, and various types of
hyphen The hyphen is a punctuation mark used to join words and to separate syllables of a single word. The use of hyphens is called hyphenation. ''Son-in-law'' is an example of a hyphenated word. The hyphen is sometimes confused with dashes ( figure ...
including the unambiguous "Unicode hyphen" at U+2010 and the hyphen-minus at U+002D. When a hyphen is called for, the hyphen-minus is a common choice as it is well known, easy to enter on
keyboard Keyboard may refer to: Text input * Keyboard, part of a typewriter * Computer keyboard ** Keyboard layout, the software control of computer keyboards and their mapping ** Keyboard technology, computer keyboard hardware and firmware Music * Musi ...
s, and still the only form recognised by many data formats and computer languages. Though the Unicode Standard states that the U+2010 hyphen is "preferred" over the hyphen-minus, the standard itself uses the hyphen-minus as its hyphen character. In most modern fonts, the hyphen-minus is identical or very similar to the "Unicode hyphen". In mathematical texts that include the plus sign, use of the hyphen-minus as a minus sign typically results in an unattractive appearance. Unlike the Unicode minus sign, the hyphen-minus is generally smaller and at a different height than the horizontal line in the plus sign; see the image above. Further, many word processors will
word wrap Line breaking, also known as word wrapping, is breaking a section of text into lines so that it will fit into the available width of a page, window or other display area. In text display, line wrap is continuing on a new line when a line is ful ...
at a hyphen-minus, but not after the "Unicode hyphen" sign.


Uses


Typing

This character is typed when a hyphen or a minus sign is wanted. Based on old typewriter conventions, it is common to use a pair to represent an em dash , and to put spaces around it to represent a spaced en dash . Some
word processor A word processor (WP) is a device or computer program that provides for input, editing, formatting, and output of text, often with some additional features. Early word processors were stand-alone devices dedicated to the function, but current ...
s automatically convert these to the correct dash. The character can also be typed multiple times to simulate a horizontal line (though in most cases, repeated entry of the
underscore An underscore, ; also called an underline, low line, or low dash; is a line drawn under a segment of text. In proofreading, underscoring is a convention that says "set this text in italic type", traditionally used on manuscript or typescript a ...
will produce a solid line). Alternating the hyphen-minus with spaces produces a "dashed" line, often to indicate where paper is to be cut. On a typewriter, over-striking a section of text with this is used for strikethrough.


Programming languages

Most
programming language A programming language is a system of notation for writing computer programs. Most programming languages are text-based formal languages, but they may also be graphical. They are a kind of computer language. The description of a programming ...
s use the hyphen-minus for denoting subtraction and negation. It is almost never used to indicate a range, due to ambiguity with subtraction. Generally other characters, such as the Unicode are not recognized. In some programming languages (for example
MySQL MySQL () is an open-source relational database management system (RDBMS). Its name is a combination of "My", the name of co-founder Michael Widenius's daughter My, and "SQL", the acronym for Structured Query Language. A relational database ...
) (two hyphen-minus) mark the beginning of a
comment Comment may refer to: * Comment (linguistics) or rheme, that which is said about the topic (theme) of a sentence * Bernard Comment (born 1960), Swiss writer and publisher Computing * Comment (computer programming), explanatory text or informa ...
. It can be used to start the signature block in
Usenet Usenet () is a worldwide distributed discussion system available on computers. It was developed from the general-purpose Unix-to-Unix Copy (UUCP) dial-up network architecture. Tom Truscott and Jim Ellis conceived the idea in 1979, and it wa ...
news system.
YAML YAML ( and ) (''see '') is a human-readable data-serialization language. It is commonly used for configuration files and in applications where data is being stored or transmitted. YAML targets many of the same communications applications as Ext ...
uses (three hyphen-minuses) to end a section.


Command line

The hyphen-minus character is often used when specifying command-line options, a convention popularized by
Unix Unix (; trademarked as UNIX) is a family of multitasking, multiuser computer operating systems that derive from the original AT&T Unix, whose development started in 1969 at the Bell Labs research center by Ken Thompson, Dennis Ritchie, an ...
. Examples of the "short" form are -R or . A user can specify both by using -Rq. Some implementations allow two hyphen-minuses to specify "long" option names as or . These are easier to understand when reading commands (some software does not care about the number of hyphen-minuses, and either does not allow combinations of single-letter options, or requires the user to rearrange them, so they do not match a long option). A double hyphen-minus by itself (followed by a space) indicates that there are no more options, which is useful when one needs to specify a filename that starts with a hyphen-minus. An option of just a hyphen-minus (followed by a space) may be recognized in lieu of a filename and indicates that
stdin In computer programming, standard streams are interconnected input and output communication channels between a computer program and its environment when it begins execution. The three input/output (I/O) connections are called standard input (stdin ...
is to be read.


Encoding

The glyph has a
code point In character encoding terminology, a code point, codepoint or code position is a numerical value that maps to a specific character. Code points usually represent a single grapheme—usually a letter, digit, punctuation mark, or whitespace—but ...
in
Unicode Unicode, formally The Unicode Standard,The formal version reference is is an information technology standard for the consistent encoding, representation, and handling of text expressed in most of the world's writing systems. The standard, wh ...
as ; it is also in
ASCII ASCII ( ), abbreviated from American Standard Code for Information Interchange, is a character encoding standard for electronic communication. ASCII codes represent text in computers, telecommunications equipment, and other devices. Because ...
with the same value.


See also

* -- (disambiguation) *
Box-drawing characters Box-drawing characters, also known as line-drawing characters, are a form of semigraphics widely used in text user interfaces to draw various geometric frames and boxes. Box-drawing characters typically only work well with monospaced fonts. In ...
including (U+2500), useful for drawing horizontal lines *
Hyphen The hyphen is a punctuation mark used to join words and to separate syllables of a single word. The use of hyphens is called hyphenation. ''Son-in-law'' is an example of a hyphenated word. The hyphen is sometimes confused with dashes ( figure ...
*
Soft hyphen In computing and typesetting, a soft hyphen (ISO 8859: 0xAD, Unicode , HTML: ­ or ­ or ­) or syllable hyphen (EBCDIC: 0xCA), abbreviated SHY, is a code point reserved in some coded character sets for the purpose of breaki ...


Explanatory notes


References


External links

* {{DEFAULTSORT:Hyphen-Minus Punctuation Typographical symbols