中文说明标记语法1字体样式{font:font-stylefont-variantfont-weightfont-sizefont-family}2字体类型{font-family:"字体1","字体2","字体3",...}3字体大小{font-size:数值|inherit|medium|large|larger|x-large|xx-large|small|smaller|x-small|xx-small}4字体风格{font-style:inherit|italic|normal|oblique}5字体粗细{font-weight:100-900|bold|bolder|lighter|normal;}6字体颜色{color:数值;}7阴影颜色{text-shadow:16位色值}8字体行高{line-height:数值|inherit|normal;}9字间距{letter-spacing:数值|inherit|normal}10单词间距{word-spacing:数值|inherit|normal}11字体变形{font-variant:inherit|normal|small-cps}12英文转换{text-transform:inherit|none|capitalize|uppercase|lowercase}13?{font-size-adjust:inherit|none}14?{font-stretch:condensed|expanded|extra-condensed|extra-expanded|inherit|narrower|normal|semi-condensed|semi-expanded|ultra-condensed|ultra-expanded|wider}:font语法:{font:font-stylefont-variantfont-weightfont-sizefont-family} [<字体风格>||<字体变形>||<字体加粗>]?<字体大小>[/<行高>]?<字体类形>作用:简写属性,提供了对字体所有属性进行设置的快捷方法。注意:字体样式用作不同字体属性的略写,特别是行高。例如P{font:italicbold12pt/14ptTimes,serif}指定该段为bold(粗体)和italic(斜体)Times或serif字体,12点大小,行高为14点。例子::font-family语法:{font-family:字体1,字体2,字体3,...}作用:调用客户端字体说明:·当指定多种字体时,用“,”分隔每种字体名称。·当字体名称包含两个以上分开的单词时,用“”把该字体名称括起来。·当样式规则外已经有“”时,用‘’代替“”。注意:如果在font-family后加上多种字体的名称,浏览器会按字体名称的顺序逐一在用户的计算机里寻找已经安装的字体,一旦遇到与要求的相匹配的字体,就按这种字体显示网页内容,并停止搜索;如果不匹配就继续搜索,直到找到为止,万一样式表里的所有字体都没有安装的话,浏览器就会用自己默认的字体来替代显示网页的内容。例子:{font-family:黑体,隶书;} :font-size语法:{font-size:数值|inherit|m
css字体样式 来自淘豆网m.daumloan.com转载请标明出处.