zoukankan      html  css  js  c++  java
  • 【HTML打卡】0119css 文字、图片、控制器、引入方式、初始化

    在外面浪了几天哈哈,然后今天继续学习咯。 顺便分享一只吃草少女。

                           


    一、文字

    1、分别设置

    斜正:font-style

    粗细:font-weight

    大小:font-size

    行距:line-height

    字体:font-family


    2、统一设置

    font:italic bold 20px/40px "SimHei"


    3、设置技巧

    有衬线:sans-serif

    无.衬线:serif

    设置字体,客户及其未必有。

    font-family:"微软雅黑","黑体",sans-serif;


    二、图片

    1、分别设置

    background-color:

    background-image:url();

    background-repeat:repeat-x|y  no-repeat;

    background-attachment:fixed;


    2、统一设置

    background:gray url(small.jpg) no-repeat -150px -325px;


    3、位置

    background-position:center| center top| right center;

    background-position:-150px -325px;


    三、控制器

    id 控制器             #test

    class 控制器       .test

    标签控制器          div

    派生控制器          div p


    四、引入

    head中写入<style>.......</style>

    html标签写<div style=“color:red;”></div>

    外部引入css文件,写link tab后写地址 ./css1.css

    import导入css文件,@import url(css2.css);


    无、初始化

    防止各浏览器显示不一致的情况。

  • 相关阅读:
    Matlab smooth函数原理
    Pandas中的高级索引loc、iloc、ix精简概括
    QT常见错误:"multiple definition of xxx"
    Github术语解释
    数据反转 LSB
    LSB最低有效位和MSB最高有效位
    Modbus通信CRC16校验程序
    CRC16常见几个标准的算法及C语言实现
    DB9 公头母头引脚定义及连接
    hdu 2577 How to Type(dp)
  • 原文地址:https://www.cnblogs.com/iriswang/p/11084663.html
Copyright © 2011-2022 走看看