Prev Next space

Latex Horizontal Spacing Of Output

Syntax
$latex space $$
$latex \hspace{number unit} $$

Description
Display Latex spacing commands.

Warning
The case where unit is negative does not display properly in the Firefox browser. (This was fixed in version 3 of Firefox.)

Space
The following table demonstrates the result for the possible values of space :
Space Description Example Output
nothing $latex | | $$ @(@ | | @)@
\, thin space $latex | \, | $$ @(@ | \, | @)@
\: medium space $latex | \: | $$ @(@ | \: | @)@
\; thick space $latex | \; | $$ @(@ | \; | @)@

Hspace
In the Latex hspace command, number can be any valid Latex number and unit must be one of the units listed below
Unit Description Example Output
em approximate width of M (current font) $latex | \hspace{1em} | $$ @(@ | \hspace{1em} | @)@
ex approximate height of x (current font) $latex | \hspace{2ex} | $$ @(@ | \hspace{2ex} | @)@
cm centimeters $latex | \hspace{0.4cm} | $$ @(@ | \hspace{0.4cm} | @)@
mm millimeters $latex | \hspace{4mm} | $$ @(@ | \hspace{4mm} | @)@
in inches $latex | \hspace{0.15in} | $$ @(@ | \hspace{0.15in} | @)@
pt points (72 points = 1 inch) $latex | \hspace{12pt} | $$ @(@ | \hspace{12pt} | @)@
pc picas (1 pica = 12 points) $latex | \hspace{1pc} | $$ @(@ | \hspace{1pc} | @)@

Input File: latex/space.omh