CSS继承属性
无继承性的属性
display:规定元素应该生成的框的类型- 文本属性:
vertical-align:垂直文本对齐text-decoration:添加文本装饰text-shadow:文本阴影效果white-space:空白符的处理unicode-bidi:设置文本的方向
- 盒子模型的属性:
width、heightmargin、margin-top/right/bottom/leftborder、border-top/right/bottom/leftborder-style、border-top/right/bottom/left-styleborder-width、border-top/right/bottom/left-widthborder-color、border-top/right/bottom/left-colorpadding、padding-top/right/bottom/left
- 背景属性:
backgroundbackground-colorbackground-imagebackground-repeatbackground-positionbackground-attachment
- 定位属性:
floatclearpositiontop/right/bottom/leftmin-width/min-height、max-width/max-heightoverflowclipz-index
- 生成内容属性:
contentcounter-resetcounter-increment
- 轮廓样式属性:
outline-styleoutline-widthcounter-coloroutline
有继承性的属性
- 字体系列属性
font:组合字体font-family:字体系列font-weight:字体粗细font-size:字体尺寸font-style:字体风格font-variant:小写字母转换为大写,字体尺寸更小font-stretch:对当前font-family进行伸缩变形。所有主流浏览器不支持。font-size-adjust:为某个元素规定一个aspect值,保持首选字体的x-height
- 文本系列属性
text-indent:文本缩进text-align:文本水平对齐line-height:行高word-spacing:字间距letter-spacing:字符间距text-transform:控制文本大小写direction:文本书写方向color:文本颜色
- 元素可见性:
visibility - 表格布局属性
caption-sideborder-collapseborder-spacingempty-cellstable-layout
- 列表布局属性
list-style-typelist-style-imagelist-style-positionlist-style
- 生成内容属性:
quotes - 光标属性:
cursor - 页面样式属性
pagepage-break-insidewindowsorphans
- 字体系列属性