• 文本属性和属性连写


    文本元素:
    属性:font-size:16px;
       font-weight:700;文本粗细(值从100到900)
       font-family:微软雅黑;文本的字体
       font-style:normal/italic;文字风格(normal正常默认,italic斜体)
       line-height:40px行高

    文本属性连写:
     写法:font:font-style font-weight font-size/line-height font-family;
     如 : font:italic 700 16px/40px 微软雅黑;
    注意:font:后面写属性值,一定要按照顺序写
       文本属性连写中 文字大小和文本字体  为必写项

     1 <!DOCTYPE html>
     2 <html lang="en">
     3 <head>
     4     <meta charset="UTF-8">
     5     <title>Document</title>
     6     <style type="text/css">
     7         div{
     8             /* font-size: 16px;
     9             font-weight: 700;
    10             font-family: 微软雅黑;
    11             font-style: italic;
    12             line-height: 40px; */
    13             font: italic 700 16px/40px 微软雅黑;
    14         }
    15     </style>
    16 </head>
    17 <body>
    18     <div>
    19         在这里输入你想要搜索的内容<br>
    20         练习
    21     </div>
    22 </body>
    23 </html>

    连写内容:

    1 font: italic 700 16px/40px 微软雅黑;

      

  • 相关阅读:
    MVC Form
    The way to learn english
    Test FastThree
    C#中Trim()、TrimStart()、TrimEnd()的用法
    c# Dictionary 简介
    visual studio快捷键大全
    ASP.NET MVC 中 ActionResult
    MVC4中使用 Ninject
    MVC Chapter 12 Overview of MVC Projects
    ASP.NET Razor
  • 原文地址:https://www.cnblogs.com/twinkle-/p/9060086.html
Copyright © 2020-2023  润新知