css

 雪碧图
.div1{
    229px;
    height:186px;
外线
    outline: 1px solid darkred;
图片路径
    background-image: url("../1/img/1.jpg");
    background-size: 1000px 752px;
定位
    background-position: -18px -46px;
}
鼠标移至变色
.div1:hover{
    158px;
    height: 196px;
    outline: 1px solid darkred;
    background-image: url("../1/img/1.jpg");
    background-size: 1000px 752px;
    background-position:-315px -36px;

    cursor: pointer;
}

字体处理


字体名称:font-family(可指定多字,逗号分开)
字体倾斜:font-style
字体变体:font-variant
字重:font-weight 100-900(400一般。900最重)
字体大小:font-size

文本属性

文本缩进:text-indent:3em
对齐:text-align、(center、left、right)
文本修饰:text-decoration
文本阴影:text-shadow:red
行高:line-height
字间距:letter-spacing
词间距:word-spacing
设置文本大小写形式:text-space
空白显示形式:white-space

设置元素字体颜色及背景

前景色:color
背景色:backgroud-color
背景图像是否铺排:backgroud-repeat
背景图像随内容滚动还是固定:backgroud-attachment
背景图像显示位置:backgroud-position
设定背景图像:backgroud-image  (URL....)
大小:backgroud-size
超出部分剪掉:backgroud-cover

原文地址:https://www.cnblogs.com/paul-du/p/5285813.html