zoukankan      html  css  js  c++  java
  • CSS 选择器分类

    CSS 选择器分类

       普通选择器:使用HTML元素标签座位选择器。

          如:  p{ font-size:24px; }

       派生选择器:通过依据元素在其位置的上下文关系定义样式,是标记更加简洁。

          如:  h2 strong{color:bule;}

              <h2>The strongly emphasized word in this subhead is<strong>blue</strong>.</h2>

              // h2 strong影响以上的blue文本。

       id 选择器:为标记特定id的HTML元素指定特定的样式。

          如:   #red {color:red}

               <p id="red">这个段落是红色。</p>  //id为red的元素的字符为红色。

       类选择器:类选择器以一个点号显示。

          如:      .center {text-align: center}

              <h1 class="center">This heading will be center-aligned</h1> 

               //class为“center”的多个元素都水平居中对齐

  • 相关阅读:
    wpf之依赖属性
    wpf之布局控件
    WPF之绑定
    wpf之触发器
    wpf之样式
    wpf之TreeView
    wpf(五)
    【Javaweb】poi实现通过上传excel表格批量导入数据到数据库
    Java读取批量Excel文件
    Centos上通过yum命令删除有关MySQL
  • 原文地址:https://www.cnblogs.com/lanchong/p/1781584.html
Copyright © 2011-2022 走看看