CSS text-align-last 属性

cssweb developmentfront end technology更新于 2024/3/12 6:04:17

text-align 属性用于对齐文本的最后一行。您可以尝试运行以下代码,在 CSS3 中实现 text-align-last 属性 −

示例

<!DOCTYPE html>
   <html>
      <head>
         <style>
            .mydiv {
               text-align-last: right;
            }
         </style>
      </head>
   <body>
      <h1>text-align-last Property</h1>
      <div class = "mydiv">
         <p>This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text.</p>
      </div>
   </body>
</html>

相关文章


有用资源