选择器权重、文本样式、列表总结、边框总结、背景颜色

权重:

    标签选择符(元素选择器)的权重为 1      

    class选择符(类选择器)的权重为  1      

    id选择符的权重为  100

    伪类选择符的权重为  10     如     :link     :visited......

    包含选择符的权重:为包含选择符的权重之和

    @important权重最终

    继承权重为0

文本字体:

    文本大小:font-size:px/em/pt/rem   网页中默认的为16px,最小为12px 1em等于16px【不设置font-size大小时】 9pt=12px

    文本的字体:font-family:"字体1","字体2号",....;防止浏览器不识别

    文本的颜色:color:英文单词/16进制颜色/rgb  rgba()

    文本的粗细:font-weight:bold/bolder/normal/100~900/lighter

    文本的倾斜:font-style:italic/oblique/normal

文字水平对齐方式  text-align:left/right/center/justify

直对齐方式   下周二

行高  line-height   line-height的属性值等于height的属性值

文本修饰 text-decoration:none/underline/overline/line-through

首行缩进 text-indent:x单位  x的值可以为复述,只控制第一行

复合属性 font:weight style size/line-height family;

列表属性总结:

    操作列表

    list-style-type  设置小圆点的类型  none/circle/disc/square

    list-style-position  设置前面小圆点或者图片的位置  inside【里面】/outside【外面】

    list-style-image     将小圆点替换为图片【图片大小不可以改变】

    list-style           复合属性【简写】

边框属性总结:

    border-width       设置边框的四边 ,[从上面开始沿着顺时针的方向执行,如果值不过则执行对边的值,如果对边也没有值则执行上面的值]

    border-style       设置边框的类型 solid  实线  double  双线 dotted  点线 dashed 虚线...

    border后面跟的除了style为必填项之外其他的都是选填项【存在默认值】

    border-color       设置边框颜色

    border-left        左边框

    border-right       右边框

    border-bottom      下边框

    border-top         上边框

背景颜色:">背景图片:

    borkground-repeat    设置背景图片平铺 no-repeat/repeat/repeat-x/repeat-y

    background-position  背景图片的位置   left/right/center/top/bottom  [可以写像素]

    background-size       图片的大小  cover[层叠]contain[包含]可以写数值

    background-attachment  背景图固定  fixed固定 scroll滚动

上一篇:从零开始学前端:表单制作 --- 今天你学习了吗?(Day05)


下一篇:java学习记录day05数组