CSS

CSS选择器:

1.通配符选择器: (*) : 代表选中页面所有的元素

2. 标签名  标签名{属性1:属性值;属性2:属性值;}   可以把某一类标签全部选择出来,例如所有的div标签

3. 类选择器(.class) :给某一类添加样式

4. ID选择器(#id):唯一标识

CSS常用属性:

   color: 文字的颜色     font-size:文字大小    font-family:字体      font-style:设置字体的样式 (italic normal )

   font-weight:设置是否粗体(bold normal []100-900)    background:背景色   border:设置边框(solid dashed dotted)      text-decoration:下划线(underline)   中划线line-through  上划线(overline)  none(隐藏)   text-align: 文本对齐   width:宽   height:高

font标签简写形式:

      {font: font-style  font-weight  font-size/line-height  font-family;}

color:  预定义方式  red  green  blue 

posted @ 2019-04-23 23:17  开发者社区  阅读(359)  评论(0)    收藏  举报