CSS 文本樣式
阿新 • • 發佈:2018-09-12
none right class orm -- nbsp under text size
1. 文本樣式 text
<!--文本顏色color --> .text {color:red;}
2. 文本對齊方式 text-align
<style> .text { text-align:left;/*向左對齊*/ } .text { text-align:center;/*居中*/ } .text { text-align:right;/*向右對齊*/ } .text { text-align:justify;/*兩端對齊*/} </style>
3. 文本修飾 text-decoration
.decoration { text-decoration:none;/*默認樣式*/ } .decoration { text-decoration:overline;/*上劃線*/ } .decoration { text-decoration:underline;/*下劃線*/ } .decoration { text-decoration:line-through;/*刪除線*/ }
4. 字體 font
.text{ font-family:"微軟雅黑";/*字形 微軟雅黑*/ font-size:10px;/*字體大小 10像素*/ font-style:italic;/*字體樣式 斜體 */ /*字體樣式還有 normal 正常的 oblique 傾斜體 */ }
CSS 文本樣式