What is Line spacing?
In ancient times we used printing presses to come out with WORDS. Each of the printed words is in a separate block.
Line spacing, which is legendary to control the vertical distance between two lines of Text. In css, line-height is used to control the vertical distance between rows and Rows.
however, the line spacing and half-line spacing are still dependent on the line-height in the Css. so, How to use line-height?
Default state, The browser uses 1.0-1.2 line-height, which is an initial Value. You can define the Line-height property to overwrite the initial value: p{line-height:140%}
There are 5 ways you can define Line-height.
1.line-height can be defined as: body{line-height:normal;}
2.line-height can be defined as: body{line-height:inherit;}
3.line-height can use a percentage of the value body{line-height:120%;}
4.line-height can be defined as a length value (px,em, etc.) body{line-height:25px;}
5.line-height can also be defined as a pure number, body{line-height:1.2}
Abbreviation Line-height
The 5 types of line-height can be abbreviated in the font Attribute. The value of the line-height is followed by a font-size value separated by a slash, such as:<font-size>/<line-height>
Example: body{font:100%/normal arial;}, body{font:100%/120% arial;}, body{font:100%/1.2 arial;} , body{font:100%/25px arial;}
Calculate Line-height
Some CSS properties are inheritable (inherited), which are passed down from the stacked Elements. This is done to make it easier for developers to no longer reset values for descendant Elements.
For Line-height inheritance is a bit complicated.
1. percentage
2. length
3 Value: Normal
4 Pure Numerals
(but the actual combat application in the Chinese font or the English font mix, as well as Ie678,xp win7, row high rules and different, tears)
Learn more about the line height property of CSS