渐变
来源:互联网 发布:知乎黑莓客户端 编辑:程序博客网 时间:2024/05/01 00:41
teacher 16:19:32 (多人发送)
<!DOCTYPE html>
<html>
<head>
<title></title>
<style type="text/css">
.div1{
width: 200px;
height: 200px;
background: #aaa;
/*border: 40px solid;*/
border-width:30px;
/*-webkit-border-image: url(HE.png) 100% round round;*/
/*-webkit-border-image: url(HE.png) 65 0 0 0 round;*/
-webkit-border-image-slice: url(1.png) 30;
}
.div2{
width: 200px;
height: 200px;
background: #aaa;
margin-top: 20px;
/*渐变的类型? (linear)
渐变开始的X Y 轴坐标(0 0 – 或者left-top)
渐变结束的X Y 轴坐标(0 100% 或者left-bottom)
开始的颜色? (from(red))
结束的颜色? (to(blue))*/
background: -webkit-gradient(linear, 0% 10%, 0% 100%, from(yellow), to(blue));
}
.gd{
width: 100px;
height: 100px;
background: #faa;
}
.gd:hover{
/*width: 100px;*/
/*height: 50px;*/
-webkit-animation: 1.5s zzq infinite;
/*(forwards:一次,infinite:循环)*/
/*注意必须要使用-webkit-animation,不能用animation*/
}
@-webkit-keyframes zzq {
from { -webkit-transform: none;
/*-webkit-transform:rotate(10deg);*/}
25% { -webkit-transform:rotate(-30deg);}
/*50% { -webkit-transform:rotate(0deg);}*/
75%{ -webkit-transform:rotate(30deg);}
/*100%{ -webkit-transform:rotate(30deg);}*/
</style>
</head>
<body>
<!-- <div class="div1"></div>
<div class="div2"></div> -->
<div class="gd"></div>
</body>
</html>
<!DOCTYPE html>
<html>
<head>
<title></title>
<style type="text/css">
.div1{
width: 200px;
height: 200px;
background: #aaa;
/*border: 40px solid;*/
border-width:30px;
/*-webkit-border-image: url(HE.png) 100% round round;*/
/*-webkit-border-image: url(HE.png) 65 0 0 0 round;*/
-webkit-border-image-slice: url(1.png) 30;
}
.div2{
width: 200px;
height: 200px;
background: #aaa;
margin-top: 20px;
/*渐变的类型? (linear)
渐变开始的X Y 轴坐标(0 0 – 或者left-top)
渐变结束的X Y 轴坐标(0 100% 或者left-bottom)
开始的颜色? (from(red))
结束的颜色? (to(blue))*/
background: -webkit-gradient(linear, 0% 10%, 0% 100%, from(yellow), to(blue));
}
.gd{
width: 100px;
height: 100px;
background: #faa;
}
.gd:hover{
/*width: 100px;*/
/*height: 50px;*/
-webkit-animation: 1.5s zzq infinite;
/*(forwards:一次,infinite:循环)*/
/*注意必须要使用-webkit-animation,不能用animation*/
}
@-webkit-keyframes zzq {
from { -webkit-transform: none;
/*-webkit-transform:rotate(10deg);*/}
25% { -webkit-transform:rotate(-30deg);}
/*50% { -webkit-transform:rotate(0deg);}*/
75%{ -webkit-transform:rotate(30deg);}
/*100%{ -webkit-transform:rotate(30deg);}*/
</style>
</head>
<body>
<!-- <div class="div1"></div>
<div class="div2"></div> -->
<div class="gd"></div>
</body>
</html>
0 0
- 渐变
- 渐变
- 渐变
- 渐变
- 渐变
- 渐变
- 渐变
- 渐变
- 渐变
- 渐变
- 渐变
- 渐变
- 渐变:线性渐变、径向渐变
- css3渐变SVG渐变
- CSS3 渐变 线性渐变
- 渐变按钮、渐变边框
- CSS3-颜色渐变--线性渐变+径向渐变
- css3渐变、线性渐变和径向渐变
- 反转链表
- 【cocos2d-x游戏开发】坐标系详解
- VS调试技巧
- 测试JSON RPC远程调用(JSON客户端)
- android ndk 环境搭建 心得
- 渐变
- Android中WebView和js之间的交互
- iptables学习笔记 【思维导图】
- poj 2914(无向图最小割Stoer-Wagner算法)
- C5_多维数组
- Java 反射
- poj 1330 Nearest Common Ancestors(最近公共祖先(LCA))
- OpenMP并行程序设计——for循环并行化详解
- 数据结构实战——线性结构之静态数组表示法