• CSS的display、hover、overflow、&copy(版权符号)、borer-radius(边框圆角)


    一、display: none 隐藏 block显示

        visibility:hidden隐藏 visible显示

    display:none和visibility:hidden这两个属性对应的值都是隐藏对像,但是它们隐藏对像有点区别。

    display和visibility的区别:display隐藏相当于这个元素没有了,visibility的隐藏该元素所占的位置还在,只是内容隐藏了。

    二、hover:不是一个样式,用元素的ID或者CLASS之类后面跟冒号hover,代表鼠标放到此元素上显示哪些样式

    例如:

     三、overflow

    可用值

    描述
    visible The content is not clipped. It renders outside the element
    内容不会被省掉。会显示在元素的外面
    hidden The content is clipped, but the browser does not display a scroll-bar to see the rest of the content 
    内容会被省掉,但浏览器不会显示滚动条以用来查看剩余的内容(超出范围隐藏)
    scroll The content is clipped, but the browser displays a scroll-bar to see the rest of the content
    内容被省掉,但浏览器会显示滚动条以用来查看剩余的内容
    auto If the content is clipped, the browser should display a scroll-bar to see the rest of the content
    如果内容被省掉了,浏览器才会显示出滚动条

    四、borer-radius(边框圆角)

    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>无标题文档</title>
    <style type="text/css">
    
    #sub1
    {   
        200px;
        height:200px;
        border-radius:15px;
        background-color:#093
    }
    
    </style>
    </head>
    
    <body>
    <div id="parent">
        <div id="sub1"></div>
    </div>
    
    </body>

  • 相关阅读:
    [From 11.1~11.4]事件
    [From 10.1~10.5] 对象和集合初始化器(C#语法糖系列)
    [From 9.3]out和ref关键字
    [From 8.5]转换操作符方法
    将博客搬至CSDN
    QPS 与 TPS 简介
    在cenos中,通过subversion源码进行安装
    no acceptable C compiler found in $PATH
    tgz解压
    程序中的@Override是什么意思?
  • 原文地址:https://www.cnblogs.com/franky2015/p/4702608.html
Copyright © 2020-2023  润新知