1. 第一个段落
一个段落,内容随意(不能违法、反动、色情等)一个段落,内容随意(不能违法、反动、色情等)一个段落,内容随意(不能违法、反动、色情等)一个段落,内容随意(不能违法、反动、色情等)一个段落,内容随意(不能违法、反动、色情等)一个段落,内容随意(不能违法、反动、色情等)一个段落,内容随意(不能违法、反动、色情等)There comes some English words. There comes some English words. There comes some English words. There comes some English words.
2. text-decoration
text-decoration: 文本修饰属性会延伸到后代元素。这意味着如果祖先元素指定了文本修饰属性,后代元素则不能将其删除。例如,在如下标记中<p>This text has <em>some emphasized words</em> in it.</p>,应用样式p { text-decoration: underline } 会对整个段落添加下划线,再添加样式 em { text-decoration: none } 则不会引起任何改变;整个段落仍然有下划线修饰。然而,新加样式 em { text-decoration: overline } 则会在<em>标记的文字上添加另一种新样式。
This text has some emphasized words in it.
3. text-align
text-align控制它的行内内容对齐。
/* Keyword values */ text-align: left; text-align: right; text-align: center; text-align: justify; text-align: justify-all; text-align: start; text-align: end; text-align: match-parent; /* Block alignment values (Non-standard syntax) */ text-align: -moz-center; text-align: -webkit-center; /* Global values */ text-align: inherit; text-align: initial; text-align: unset;
4. word-spacing
word-spacing字符间距 value: 50% normal 3px 1em inherit. 这有一些汉字。这有一些汉字。这有一些汉字。这有一些汉字。这有一些汉字。这有一些汉字。这有一些汉字。there comes some english words. there comes some english words. there comes some english words.
5. white-space
white-space CSS属性用来描述如何处理空格制表换行和br. 下面每个there前有一个换行+2个tab+1个空格(white-space:pre-wrap): there comes some english words. there comes some english words. there comes some english words. there comes some english words. there comes some english words. nowrap;合并所有换行 空格 制表 , 不自动换行 pre:保留所有换行 空格 制表 , 不自动换行 pre-wrap:保留所有换行 空格 制表 , 自动换行 pre-line: 保留换行 ,合并空格 制表 , 自动换行(窗口装不下的时候自动换到下一行) (遇到br都会换行) inherit
6. line-height
line-height被用来控制行与行之间垂直距离.
- line-height可以被定义为:body{line-height:normal;}
- line-height可以被定义为:body{line-height:inherit;}
- line-height可以使用一个百分比的值body{line-height:120%;}
- line-height可以被定义为一个长度值(px,em等) body{line-height:25px;}
- line-height也可以被定义为数字, body{line-height:1.2}
浏览器默认1em=16px. 当我们在body中同时设置了font-size和line-height属性时,子元素会继承这个被确定的行高。只有当body的line-height被设置为数字(注意不是em),才能让子元素自适应它的字体的行高(无论body中形式为px的font-size)。参考这里:深入理解CSS的line-height
这是一个h1标签这是一个h1标签这是一个h1标签这是一个h1标签这是一个h1标签这是一个h1标签这是一个h1标签这是一个h1标签这是一个h1标签这是一个h1标签这是一个h1标签这是一个h1标签这是一个h1标签这是一个h1标签这是一个h1标签这是一个h1标签这是一个h1标签这是一个h1标签这是一个h1标签这是一个h1标签这是一个h1标签
there comes some english words again. there comes some english words again. there comes some english words again. there comes some english words again. there comes some english words again. there comes some english words again. there comes some english words again. there comes some english words again. there comes some english words again. there comes some english words again. there comes some english words again. there comes some english words again. there comes some english words again. there comes some english words again. there comes some english words again.