文本颜色
<style>
p {
color: red;
color: #ff0000;
}
</style>
对其文本
<style>
p {
/* left, center, right */
text-align: center;
}
</style>
装饰文本
下划线-underline
<style>
p {
text-decoration: underline;
}
</style>
删除线-line-through
上划线-overline
链接下划线取消掉
a {
text-decoration: none;
}
文本缩进
<style>
p {
text-indent: 20px;
/* em就是一个文字的大小 */
text-indent: 2em;
}
</style>
行间距
line_height = 上间距+文本距离(16px)+下间距
<style>
h2 {
line-height: 26px;
}
</style>