zoukankan      html  css  js  c++  java
  • 多行文字自动换行居中--实测好用的很OK

    实测好用的很~~~

    <!DOCTYPE html>
    <html lang="en">
    
    <head>
      <meta charset="UTF-8">
      <meta name="viewport" content="width=device-width, initial-scale=1.0">
      <title>Document</title>
      <style>
        .outDiv {
          border: 1px solid black;
           200px;
          height: 200px;
          text-align: center;
          overflow: hidden;
        }
    
        .outDiv .innerDiv1 {
          display: inline-block;
          vertical-align: middle;
        }
    
        .outDiv .innerDiv-fix {
          display: inline-block;
           0;
          height: 100%;
          line-height: 100%;
          vertical-align: middle;
          visibility: hidden;
        }
      </style>
    </head>
    
    <body>
      <div class="outDiv">
        <span class="innerDiv1">多行文字自动换行居中</span><span class="innerDiv-fix">
          <!-- 此标签不能换行 --></span>
      </div>
    </body>
    
    </html>
    
  • 相关阅读:
    Senventh Week(补充完整)
    Sixth Week(补充完整)
    Fifth Week(补充完整)
    Fourth Week (补充完整)
    九大内置对象
    matlab 简单绘图
    matlab ./
    困惑
    【转】matlab中inf
    matlab x~=0
  • 原文地址:https://www.cnblogs.com/sugartang/p/14666339.html
Copyright © 2011-2022 走看看