无继承性的属性
- display:规定元素应该生成的框的类型
- 文本属性
vertical-align:垂直文本对齐 text-decoration:规定添加文本的装饰 text-shadow:文本阴影效果 white-space:空白符的处理 unicode-bidi:设置文本的方向
3.盒子模型的属性
width;height;margin,margin,margin-top,margin-bottom,margin-right,margin-left; border,border-style,border-top-stye,border-right-style,border-bottom-style,border-left-style, border-width,border-top-width,border-bottom-width,border-right-width,border-left-width, border-color,border-top-color,border-bottom-color,border-left-color,border-right-color, border-top,border-right,border-bottom,border-left; padding,padding-top,padding-padding-right,padding-bottom,padding-left;
4.背景属性
background,background-color,background-image,background-repeat,background-position,background-attachment;
5.定位属性
float,clear,position,top,right,bottom,left,min-width,min-height,max-width,max-height,overflow,clip,z-index
总结:
可以继承的样式属性包含(字体系列样式属性,文本系列样式属性:text-align、line-height、text-indent)
不可继承的属性display:inline、block、inline-block、table-cell、none文本类:盒子模型,背景类,浮动类,定位类
转载请注明:大灰牛博客 » 可以继承和不可以继承样式属性