1、vertical-align:sub(下标) | super (上标)| 5px(往上移动) | -5px(往下移动) | top | bottom | text-bottom | text-top |middle
2、背景图位置:
background-position:纵向(top | center | bottom) 横向(left | center | right);
//注意:用此css,先需要把背景固定background-attachment:fixed;若只有一个值第二个值省略则默认为center;
如:body{background-position:top right;background-attachment:fixed;}
background简写形式:background-color | background-image | background-repeat | background-attachment | background-position
例如:
.bg01{
background-color: #FFCC66;
background-image: url("path/bgFile.gif");
background-repeat: no-repeat;
background-attachment: fixed;
background-position: left top;
}
上面可以简写为:
.bg01{background:#FFCC66 url("path/bgFile.gif") no-repeat fixed left top; }
3、list列表:
list-style-type:none|disc|circle|square|decimal|lower-roman|upper-roman|lower-alpha|upper-alpha
list-style-position:inside 清单项目较往右移|outside清单项目正常显示(默认)
简化形式:list-style:circle inside url("sdf.jpg");
4、font的简写形式:font-style | font-variant | font-weight | font-size | font-family
例如:
.fontStyle01{
font-style: italic;
font-variant: small-caps;
font-weight: bold;
font-size: 30px;
font-family: arial, sans-serif;
}
上面的样式简写为:
.fontStyle01{font:italic small-caps bold 12px arial,verdana;}
css简写 vertical-align background font
最新推荐文章于 2022-01-05 10:11:13 发布