zoukankan      html  css  js  c++  java
  • CSS3实现边框锯齿效果

    通过CSS3的linear-gradient实现的

    <div class="bg"></div>

    .bg{

        300px;

        height:50px;

        background:#caca8c;

        background-image:-webkit-gradient(linear,50% 0,0 100%,

                                            from(transparent),

                                            color-stop(.5,transparent),

                                            color-stop(.5,#d86707),

                                            to(#d86707)    

                        ),

                        -webkit-gradient(linear,50% 0,100% 100%,

                                            from(transparent),

                                            color-stop(.5,transparent),

                                            color-stop(.5,#d86707),

                                            to(#d86707)                                            

                        );

        background-image:-moz-linear-gradient(50% 0 -45deg,

                                    transparent,

                                    transparent 50%,

                                    #d86707 50%,

                                    #d86707                                            

                        ),-moz-linear-gradient(50% 0 -135deg,

                                    transparent,

                                    transparent 50%,

                                    #d86707 50%,

                                    #d86707                                            

                        );                                

        background-size:30px 15px;

        background-repeat:repeat-x;

        background-position:0 100%;                    

    }

  • 相关阅读:
    提高自己应用性能的总结架构篇
    iOS 开发调试技巧
    iOS (UIButton封装)仿糯米首页缩放“按钮”效果
    计算机网络中的TCP/UDP协议到底是怎么回事(二)
    计算机网络中的TCP/UDP协议到底是怎么回事(一)
    iOS一分钟学会环形进度条
    View Controller 视图管理总结
    iOS-自定义导航栏后侧滑返回功能失效
    iOS缓存框架-PINCache解读
    YYCache 设计思路
  • 原文地址:https://www.cnblogs.com/mm2015/p/5881313.html
Copyright © 2011-2022 走看看